Re: dllimport, dllexport attributes
Re: dllimport, dllexport attributes
- Subject: Re: dllimport, dllexport attributes
- From: Jean-Daniel Dupas <email@hidden>
- Date: Wed, 18 Jun 2008 09:13:21 +0200
Le 18 juin 08 à 02:08, James Walker a écrit :
I know that __attribute__((dllexport)) and
__attribute__((dllimport)) are legal in GCC, but do they actually
serve any purpose on the Mac? When I've tried them, they don't seem
to do anything but produce warnings. I get the impression that in
cases where I might expect to use __attribute__((dllexport)), I
should use __attribute__((visibility("default"))) instead, and in
cases where I might expect to use __attribute__((dllimport)), I
don't need anything special. Is that right?
Yes, that's it. Except that by default, GCC exports all functions that
are not explicitly marked as private
( __attribute__((visibility("hidden"))) ). If you want to expose only
the functions that have the "default" visibility attribute, you can
use the -fvisibility=hidden gcc parameter (or the "Symbols hidden by
default" build setting in Xcode).
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden