[Pcsclite-cvs-commit] r6572 - in /trunk/PCSC: configure.ac src/Makefile.am src/spy/Makefile.am

rousseau at users.alioth.debian.org rousseau at users.alioth.debian.org
Sat Mar 16 14:29:50 UTC 2013


Author: rousseau
Date: Sat Mar 16 14:29:49 2013
New Revision: 6572

URL: http://svn.debian.org/wsvn/pcsclite/?sc=1&rev=6572
Log:
Fix OpenBSD 5.2 compilation regarding dlopen

1) dlopen search in configure.ac, as guided in [1]. Removes this
warning:
* Warning: linker path does not have real file for library -ldl.
* I have the capability to make that library automatically link in when
* you link to this library.  But I can only do this if you have a
* shared version of the library, which you do not appear to have
* because I did check the linker path looking for a file starting
* with libdl but no candidates were found. (...for regex pattern test)
* The inter-library dependencies that have been dropped here will be
* automatically added whenever a program is linked with this library
* or is declared to -dlopen it.

[1] http://www.flameeyes.eu/autotools-mythbuster/autoconf/finding.html

Thanks to Martin Paljak for the patch
http://lists.alioth.debian.org/pipermail/pcsclite-muscle/Week-of-Mon-20130311/000016.html

Modified:
    trunk/PCSC/configure.ac
    trunk/PCSC/src/Makefile.am
    trunk/PCSC/src/spy/Makefile.am

Modified: trunk/PCSC/configure.ac
URL: http://svn.debian.org/wsvn/pcsclite/trunk/PCSC/configure.ac?rev=6572&op=diff
==============================================================================
--- trunk/PCSC/configure.ac (original)
+++ trunk/PCSC/configure.ac Sat Mar 16 14:29:49 2013
@@ -128,8 +128,9 @@
 CFLAGS="$saved_CFLAGS"
 AC_SUBST(SYMBOL_VISIBILITY)
 
-AC_SUBST(LIBDL)
-AC_CHECK_LIB(dl, dlopen, [LIBDL="$LIBDL -ldl" ac_cv_func_dlopen_ldl=yes], ac_cv_func_dlopen_ldl=no)
+AC_SEARCH_LIBS([dlopen], [dl dld], [], [
+  AC_MSG_ERROR([unable to find the dlopen() function])
+])
 
 # Use 'uname' output as an architecture define
 PCSC_ARCH=`uname | sed -e s,/,_,`

Modified: trunk/PCSC/src/Makefile.am
URL: http://svn.debian.org/wsvn/pcsclite/trunk/PCSC/src/Makefile.am?rev=6572&op=diff
==============================================================================
--- trunk/PCSC/src/Makefile.am (original)
+++ trunk/PCSC/src/Makefile.am Sat Mar 16 14:29:49 2013
@@ -90,7 +90,7 @@
 pcscd_LDFLAGS = $(LDFLAGS) -export-dynamic
 pcscd_LDADD = \
 	$(PTHREAD_LIBS) $(COREFOUNDATION) \
-	$(LIBUSB_LIBS) $(LIBDL) $(IOKIT) $(LIBUDEV_LIBS) \
+	$(LIBUSB_LIBS) $(IOKIT) $(LIBUDEV_LIBS) \
 	$(PTHREAD_LIBS) $(PTHREAD_CFLAGS)
 
 fix-rights: install-sbinPROGRAMS

Modified: trunk/PCSC/src/spy/Makefile.am
URL: http://svn.debian.org/wsvn/pcsclite/trunk/PCSC/src/spy/Makefile.am?rev=6572&op=diff
==============================================================================
--- trunk/PCSC/src/spy/Makefile.am (original)
+++ trunk/PCSC/src/spy/Makefile.am Sat Mar 16 14:29:49 2013
@@ -5,7 +5,6 @@
 
 libpcscspy_la_SOURCES = \
 	libpcscspy.c
-libpcscspy_la_LIBADD = -ldl
 
 man_MANS = pcsc-spy.1
 




More information about the Pcsclite-cvs-commit mailing list