libdvdread uses internal dlfcn on W32, unconditionally
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On W32 libdvdread unconditionally uses msvc/contrib/dlfcn.c While this allows libdvdread to be compiled out of the box, it prevents it from linking to any other dlfcn implementation. Namely - to dlfcn-win32 [1] (which is somewhat more POSIX-compliant). The attached patch is very simplistic (i.e. it unconditionally requires a working libdl somewhere), but it works for me. For trunk i would suggest re-writing it like this: check for dlopen in -lc if that fails, check for dlopen in -ld if that fails AND host is mingw, modify CFLAGS to use internal dlfcn Note that LDFLAGS modification should go AFTER (!) all AC_CHECK_LIB calls, because -no-undefined is no longer valid as a compiler option. [1] http://code.google.com/p/dlfcn-win32/ -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (MingW32) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEcBAEBAgAGBQJPiFCkAAoJEOs4Jb6SI2Cwl1YH/0T2WtJHelUGJr4ne6BN+dAz fvRfThLqmWIg0c+KrMN7UYlKOiDBWraLXbzUTvmjnZGM3w0GrUIT1qSniYKog+f+ AEfa9b75dfSSpT1R1xBmr1YT9ka3CtRtbiA5pjCHNyNr/IcMOQGEn8pXEzJ7vXn7 Uo5IeqWaG2JfjJYFXouKgTAT/L4P9Uvhab2S+SBFyhYG7OHi1DbmelWvhIkBT6lB QWE69RprcIH4dueq9l2IMvkWqhqvI580S6r3RbxZIFyYESamuxRCgxdCpBdPbYPs +KU2EjqJdmohoS+Xp274l0aia2sBrvgYsC37MkyYawi2UhPtv2EnW6lIUIHczSU= =VUR/ -----END PGP SIGNATURE-----
On W32 libdvdread unconditionally uses msvc/contrib/dlfcn.c While this allows libdvdread to be compiled out of the box, it prevents it from linking to any other dlfcn implementation. Namely - to dlfcn-win32 [1] (which is somewhat more POSIX-compliant).
The attached patch is very simplistic (i.e. it unconditionally requires a working libdl somewhere), but it works for me. For trunk i would suggest re-writing it like this: check for dlopen in -lc if that fails, check for dlopen in -ld if that fails AND host is mingw, modify CFLAGS to use internal dlfcn
Note that LDFLAGS modification should go AFTER (!) all AC_CHECK_LIB calls, because -no-undefined is no longer valid as a compiler option.
I have put this patch into my tree. It would be helpful if someone who develops or builds on Windows tried out this patch, but it is highly likely that I will push this patch as is into svn. Thanks for the patch! E -- Erik Hovland erik@hovland.org http://hovland.org/
On Tue, Apr 17, 2012 at 12:44 PM, Erik Hovland <erik@hovland.org> wrote:
On W32 libdvdread unconditionally uses msvc/contrib/dlfcn.c While this allows libdvdread to be compiled out of the box, it prevents it from linking to any other dlfcn implementation. Namely - to dlfcn-win32 [1] (which is somewhat more POSIX-compliant).
The attached patch is very simplistic (i.e. it unconditionally requires a working libdl somewhere), but it works for me. For trunk i would suggest re-writing it like this: check for dlopen in -lc if that fails, check for dlopen in -ld if that fails AND host is mingw, modify CFLAGS to use internal dlfcn
Note that LDFLAGS modification should go AFTER (!) all AC_CHECK_LIB calls, because -no-undefined is no longer valid as a compiler option.
I have put this patch into my tree. It would be helpful if someone who develops or builds on Windows tried out this patch, but it is highly likely that I will push this patch as is into svn.
with mingw @60fd12cd6a854 : microe-libdvdread $ ./configure ... configure: error: dynamic linker needed make: *** [config.status] Error 1 $
participants (3)
-
Erik Hovland -
LRN -
Roger Pack