[patch] gpg 1.2.3, USE_DYNAMIC_LINKING undefined

ls+gnupg.devel.gnupg.org at gambit.com.ru ls+gnupg.devel.gnupg.org at gambit.com.ru
Mon Oct 27 00:04:21 CET 2003


> What should I check to find out, why USE_DYNAMIC_LINKING
> is undefined under FreeBSD 4.9-PRERELEASE x86?
> Configure said, that dlopen is "yes".

Problem found: when dlopen does not require -ldl, found_dlopen variable
is not set. Therefore USE_DYNAMIC_LINKING macro remains undefined.

This patch fixes the problem in configure.ac:

--- configure.ac	Thu Aug 21 23:45:43 2003
+++ configure.ac	Sun Oct 26 23:54:01 2003
@@ -522,11 +522,14 @@
 fi
 
 if test "$try_dynload" = yes ; then
-  AC_CHECK_FUNC(dlopen,,AC_CHECK_LIB(dl,dlopen,found_dlopen=yes))
+  AC_CHECK_FUNC(dlopen,found_dlopen=yes,AC_CHECK_LIB(dl,dlopen,found_dlopen=yes
+  need_libdl=yes))
   if test x"$found_dlopen" = "xyes" ; then
     AC_DEFINE(USE_DYNAMIC_LINKING,1,[define to enable the use of extensions])
     AC_DEFINE(HAVE_DL_DLOPEN,1,
               [Defined when the dlopen function family is available])
+  fi
+  if test x"$need_libdl" = "xyes" ; then
     AC_SUBST(DLLIBS,"-ldl")
   fi
 else

If you don't have the autoconf or use FreeBSD ports,
here is the patch for configure:

--- configure	Thu Aug 21 23:50:00 2003
+++ configure	Sun Oct 26 23:57:48 2003
@@ -9208,7 +9208,7 @@
 echo "$as_me:$LINENO: result: $ac_cv_func_dlopen" >&5
 echo "${ECHO_T}$ac_cv_func_dlopen" >&6
 if test $ac_cv_func_dlopen = yes; then
-  :
+  found_dlopen=yes
 else
   echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
 echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
@@ -9266,6 +9266,7 @@
 echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
 if test $ac_cv_lib_dl_dlopen = yes; then
   found_dlopen=yes
+  need_libdl=yes
 fi
 
 fi
@@ -9281,6 +9282,8 @@
 #define HAVE_DL_DLOPEN 1
 _ACEOF
 
+  fi
+  if test x"$need_libdl" = "xyes" ; then
     DLLIBS="-ldl"
 
   fi

Kuriyama-sun, please add patch for configure to
ports/security/gnupg/, this will fix ports/security/gnupg-idea/.

-- 
Do you know a good mixmaster replacement?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 155 bytes
Desc: not available
Url : /pipermail/attachments/20031027/adc68b8a/attachment.bin


More information about the Gnupg-devel mailing list