[vlc-devel] warning and compilation errors of plugin realaudio.c svn #24668

Gilles Sabourin gilles.sabourin at free.fr
Sun Feb 3 16:09:49 CET 2008


Le Monday 28 January 2008 20:41:54 Gilles Sabourin, vous avez écrit :
> Hello,
>
> I am trying to compile vlc this evening. I got only this error on 64 bits
> platform (again....). It seems that the linker does not find anymore Libdl.
> Here are the traces :
>
> /bin/sh ../../libtool --tag=CC   --mode=compile
> gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I../..   -DSYS_LINUX -I../../include
> -I../../include `top_builddir="../.." ../../vlc-config --cflags plugin
> realaudio` -Wall -Wextra -Wsign-compare -Wundef -Wpointer-arith
> -Wbad-function-cast -Wcast-align -Wwrite-strings -Wmissing-prototypes
> -Wvolatile-register-var -MT librealaudio_plugin_la-realaudio.lo -MD -MP -MF
> .deps/librealaudio_plugin_la-realaudio.Tpo -c -o
> librealaudio_plugin_la-realaudio.lo `test -f 'realaudio.c' ||
> echo './'`realaudio.c
>
> gcc -std=gnu99 -DHAVE_CONFIG_H -I. -I../.. -DSYS_LINUX -I../../include
> -I../../include -D_FILE_OFFSET_BITS=64 -D__USE_UNIX98 -D_LARGEFILE64_SOURCE
> -D_REENTRANT -D_THREAD_SAFE -DLOCALEDIR=\"/usr/share/locale\"
> -DDATA_PATH=\"/usr/share/vlc\" -DPLUGIN_PATH=\"/usr/lib64/vlc\" -DDEBUG
> -DHAVE_RELEASE -D__LIBVLC__ -D__PLUGIN__ -DMODULE_NAME=realaudio
> -DMODULE_NAME_IS_realaudio -g -O0 -fvisibility=hidden -Wall -Wextra
> -Wsign-compare -Wundef -Wpointer-arith -Wbad-function-cast -Wcast-align
> -Wwrite-strings -Wmissing-prototypes -Wvolatile-register-var -MT
> librealaudio_plugin_la-realaudio.lo -MD -MP -MF
> .deps/librealaudio_plugin_la-realaudio.Tpo -c realaudio.c  -fPIC -DPIC -o
> .libs/librealaudio_plugin_la-realaudio.o realaudio.c:154: warning: no
> previous prototype for '__builtin_new' realaudio.c:155: warning: no
> previous prototype for '__builtin_delete' realaudio.c: In function
> 'OpenDll':
> realaudio.c:266: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:268: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:269: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:270: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:271: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:272: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:273: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:274: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:275: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:276: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:277: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:278: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:279: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:280: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:281: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c:282: warning: initialization discards qualifiers from pointer
> target type
> realaudio.c: At top level:
> realaudio.c:484: warning: unused parameter 'p_dec'
> realaudio.c:484: warning: unused parameter 'psz_path'
> realaudio.c:484: warning: unused parameter 'psz_dll'
> realaudio.c:485: warning: 'OpenWin32Dll' defined but not used
> mv -f .deps/librealaudio_plugin_la-realaudio.Tpo
> .deps/librealaudio_plugin_la-realaudio.Plo /bin/sh ../../libtool --tag=CC  
> --mode=link gcc -std=gnu99
> `top_builddir="../.." ../../vlc-config --cflags plugin
> realaudio` -Wall -Wextra -Wsign-compare -Wundef -Wpointer-arith
> -Wbad-function-cast -Wcast-align -Wwrite-strings -Wmissing-prototypes
> -Wvolatile-register-var -rpath '/usr/lib64/vlc/codec' -avoid-version
> -module -no-undefined -shrext .so -export-dynamic `top_builddir="../.."
> ../../vlc-config --ldflags plugin realaudio`  -o librealaudio_plugin.la
> librealaudio_plugin_la-realaudio.lo ../../src/libvlc.la
> `top_builddir="../.." ../../vlc-config -libs plugin realaudio`
> gcc -std=gnu99 -shared  .libs/librealaudio_plugin_la-realaudio.o 
> -Wl,--rpath -Wl,/usr/src/packages/BUILD/vlc-beta-0.9.0/src/.libs
> ../../src/.libs/libvlc.so -L/lib64 -L/usr/lib64 -lpthread -lm  -Wl,-z
> -Wl,defs -Wl,-soname -Wl,librealaudio_plugin.so -o
> .libs/librealaudio_plugin.so .libs/librealaudio_plugin_la-realaudio.o: In
> function `OpenNativeDll':
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:400:
> undefined reference to `dlopen'
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:402:
> undefined reference to `dlerror'
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:407:
> undefined reference to `dlsym'
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:408:
> undefined reference to `dlsym'
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:409:
> undefined reference to `dlsym'
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:410:
> undefined reference to `dlsym'
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:411:
> undefined reference to `dlsym'
> .libs/librealaudio_plugin_la-realaudio.o:/usr/src/packages/BUILD/vlc-beta-0
>.9.0/modules/codec/realaudio.c:412: more undefined references to `dlsym'
> follow
> .libs/librealaudio_plugin_la-realaudio.o: In function `OpenNativeDll':
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:478:
> undefined reference to `dlclose'
> .libs/librealaudio_plugin_la-realaudio.o: In function `CloseDll':
> /usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec/realaudio.c:616:
> undefined reference to `dlclose'
> collect2: ld returned 1 exit status
> make[4]: *** [librealaudio_plugin.la] Error 1
> make[4]: Leaving directory
> `/usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec'
> make[3]: *** [all-modules] Error 1
> make[3]: Leaving directory
> `/usr/src/packages/BUILD/vlc-beta-0.9.0/modules/codec'
> make[2]: *** [all-recursive] Error 1
> make[2]: Leaving directory `/usr/src/packages/BUILD/vlc-beta-0.9.0/modules'
> make[1]: *** [all-recursive] Error 1
> make[1]: Leaving directory `/usr/src/packages/BUILD/vlc-beta-0.9.0'
> make: *** [all] Error 2

After I have a closer look at this problem (still arise at svn #24798), I have 
concluded that this link error is indirectly an architecture related error. 
The missing reference to libdl has been brought by the 32 bits windows loader 
which compilation can't be enabled on 64 bits architecture.

Shortly, --enable-real needs --enable-loader to link properly.
realaudio.c is the only module where dlopen/dlclose functions are needed.

Maybe, this exception should be treated in configure.ac to have -ldl option 
added at lin time ?

regards,
Gilles Sabourin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 194 bytes
Desc: This is a digitally signed message part.
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20080203/14f5a50d/attachment.sig>


More information about the vlc-devel mailing list