[vlc-devel] [vlc-commits] src: fixed build when compiling for Apple platforms with dynamic plugins

Felix Kühne fkuehne.videolan at googlemail.com
Sat Mar 24 19:49:02 CET 2012


On Fri, Mar 23, 2012 at 7:38 AM, Rafaël Carré <funman at videolan.org> wrote:
> Le 2012-03-22 21:39, Felix Paul Kühne a écrit :
>> vlc | branch: master | Felix Paul Kühne <fkuehne at videolan.org> | Fri Mar 23 02:30:47 2012 +0100| [c01855ebfb251f4a52560c9f8cb0639d47d7147d] | committer: Felix Paul Kühne
>>
>> src: fixed build when compiling for Apple platforms with dynamic plugins
>>
>>> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=c01855ebfb251f4a52560c9f8cb0639d47d7147d
>> ---
>>
>>  src/modules/bank.c |    2 +-
>>  1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/src/modules/bank.c b/src/modules/bank.c
>> index 43e6e67..0328ea9 100644
>> --- a/src/modules/bank.c
>> +++ b/src/modules/bank.c
>> @@ -69,7 +69,7 @@ static void module_StoreBank (module_t *module)
>>      modules.head = module;
>>  }
>>
>> -#if defined(__ELF__) || defined(__APPLE__)
>> +#if defined(__ELF__) || (defined(__APPLE__) && !HAVE_DYNAMIC_PLUGINS)
>>  # ifdef __GNUC__
>>  __attribute__((weak))
>>  # else
>
> What does this fix exactly ?

Sorry for the late response. It fixes this linking problem, when
compiling VLC for Darwin with dynamic plugins (read OS X):
  CCLD   libvlccore.la
Undefined symbols for architecture x86_64:
  "_vlc_static_modules", referenced from:
      _module_InitBank in bank.o
ld: symbol(s) not found for architecture x86_64

For reproduction: I'm using OS X 10.7.3 with Xcode 4.3.1 (4E1019).

Thus, I don't really like to revert this commit as suggested by you on
IRC yesterday evening, unless you propose a cleaner fix.


Best regards,

Felix



More information about the vlc-devel mailing list