From d443da9d5438b183fb854863487ba5dc44ff557a Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 4 Oct 1999 12:56:01 +0000 Subject: [PATCH] -ldl only added if it exists git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3818 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- configure.in | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/configure.in b/configure.in index d028abf649..50f0a62a21 100644 --- a/configure.in +++ b/configure.in @@ -1447,7 +1447,7 @@ if test "$wxUSE_GTK" = 1; then fi TOOLKIT_INCLUDE="$GTK_CFLAGS" - GUI_TK_LIBRARY="$GTK_LIBS -ldl" + GUI_TK_LIBRARY="$GTK_LIBS" TOOLKIT=GTK GUIHEADERS=GTK_HEADERS @@ -1496,7 +1496,7 @@ if test "$wxUSE_WINE" = 1; then AC_MSG_ERROR(no) fi - GUI_TK_LINK="-lwine $MESA_LINK $XPM_LINK -lXxf86dga -lXxf86vm -lSM -lICE -lXext -lXmu -lX11 -lncurses -ldl -lm" + GUI_TK_LINK="-lwine $MESA_LINK $XPM_LINK -lXxf86dga -lXxf86vm -lSM -lICE -lXext -lXmu -lX11 -lncurses -lm" GUI_TK_LIBRARY="$GUI_TK_LIBRARY $GUI_TK_LINK" WXWINE=1 TOOLKIT=MSW @@ -1572,7 +1572,7 @@ if test "$wxUSE_MOTIF" = 1; then AC_MSG_WARN(library will be compiled without support for images in XPM format) fi - GUI_TK_LINK="-lXm $XPM_LINK -lXmu -lXt -lX11 -ldl -lm" + GUI_TK_LINK="-lXm $XPM_LINK -lXmu -lXt -lX11 -lm" GUI_TK_LIBRARY="$GUI_TK_LIBRARY $GUI_TK_LINK" TOOLKIT=MOTIF @@ -1587,6 +1587,13 @@ if test "$wxUSE_MOTIF" = 1; then GUIDIST=MOTIF_DIST fi +dnl someone explicitly added -ldl to the list of libraries for these targets - +dnl I don't know why has this been done, but let's respect this - with the +dnl exception of the systems which don't have libdl at all (VZ) +if test "$wxUSE_GTK" = 1 || test "$wxUSE_MOTIF" = 1 || test "$wxUSE_WINE" = 1; then + AC_CHECK_LIB(dl, main, GUI_TK_LIBRARY="$GUI_TK_LIBRARY -ldl") +fi + dnl the name of the directory where the files for this toolkit live TOOLKIT_DIR=`echo ${TOOLKIT} | tr "A-Z" "a-z"` -- 2.47.2