changeset 3727:3246cf3e564d

[xemacs-hg @ 2006-12-08 02:17:15 by vins] Added Rick Rankin's patch to support new xpm location on cygwin.
author vins
date Fri, 08 Dec 2006 02:17:16 +0000
parents 00ae2d5b2667
children 6765f2581182
files ChangeLog configure configure.ac
diffstat 3 files changed, 19 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Thu Dec 07 22:51:10 2006 +0000
+++ b/ChangeLog	Fri Dec 08 02:17:16 2006 +0000
@@ -1,3 +1,11 @@
+2006-12-07  Rick Rankin <rick.rankin@yahoo.com>
+
+	* configure.ac: Add new library name for cygwin's xpm.
+
+2006-12-07  Rick Rankin <rick.rankin@yahoo.com>
+
+	* configure.ac: Add new library name for cygwin's xpm.
+
 2006-10-30  Malcolm Purvis  <malcolmp@xemacs.org>
 	* configure.ac (XE_CDR): m4_cdr differs in autoconf 2.59 and 2.60.
 	(XE_EXPAND_COMPLEX_OPTIONS): Use XE_CDR, not m4_cdr.
--- a/configure	Thu Dec 07 22:51:10 2006 +0000
+++ b/configure	Fri Dec 08 02:17:16 2006 +0000
@@ -18704,7 +18704,7 @@
   # See if we find them without any special options.
   # Don't add to $LIBS permanently.
   ac_save_LIBS=$LIBS
-  LIBS="-lXt $LIBS"
+  LIBS="-lX11 $LIBS"
   cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
@@ -26637,6 +26637,7 @@
 
       libpath_xpm=
   incpath_xpm=
+  libname_xpm="-lXpm"
   case "$opsys" in
     cygwin*)
       cygwin_top=`eval gcc -print-search-dirs | sed -ne s'/install: //p'`
@@ -26645,6 +26646,7 @@
                 x11)  ;;
                 msw) libpath_xpm="-L${cygwin_top}/lib/noX"
              incpath_xpm="-I${cygwin_top}/include/noX"
+             libname_xpm="-lXpm-noX"
               ;;
                 gtk)  ;;
                 none) ;;
@@ -26660,7 +26662,7 @@
     LDFLAGS=""$libpath_xpm" $LDFLAGS" &&  if test "$verbose" = "yes"; then echo "    Prepending \""$libpath_xpm"\" to \$LDFLAGS"; fi
     { echo "$as_me:$LINENO: checking for Xpm - no older than 3.4f" >&5
 echo $ECHO_N "checking for Xpm - no older than 3.4f... $ECHO_C" >&6; }
-    xe_check_libs=-lXpm
+    xe_check_libs="$libname_xpm"
     if test "$cross_compiling" = yes; then
   { { echo "$as_me:$LINENO: error: cannot run test program while cross compiling
 See \`config.log' for more details." >&5
@@ -26741,12 +26743,12 @@
 _ACEOF
 
     LDFLAGS=""$libpath_xpm" $LDFLAGS" &&  if test "$verbose" = "yes"; then echo "    Prepending \""$libpath_xpm"\" to \$LDFLAGS"; fi
-    libs_x="-lXpm $libs_x" &&  if test "$verbose" = "yes"; then echo "    Prepending \"-lXpm\" to \$libs_x"; fi
+    libs_x=""$libname_xpm" $libs_x" &&  if test "$verbose" = "yes"; then echo "    Prepending \""$libname_xpm"\" to \$libs_x"; fi
     CFLAGS=""$incpath_xpm" $CFLAGS" &&  if test "$verbose" = "yes"; then echo "    Prepending \""$incpath_xpm"\" to \$CFLAGS"; fi
     XE_CFLAGS=""$incpath_xpm" $XE_CFLAGS" &&  if test "$verbose" = "yes"; then echo "    Prepending \""$incpath_xpm"\" to \$XE_CFLAGS"; fi
     { echo "$as_me:$LINENO: checking for \"FOR_MSW\" xpm" >&5
 echo $ECHO_N "checking for \"FOR_MSW\" xpm... $ECHO_C" >&6; }
-    xe_check_libs=-lXpm
+    xe_check_libs="$libname_xpm"
     cat >conftest.$ac_ext <<_ACEOF
 /* confdefs.h.  */
 _ACEOF
--- a/configure.ac	Thu Dec 07 22:51:10 2006 +0000
+++ b/configure.ac	Fri Dec 08 02:17:16 2006 +0000
@@ -3960,6 +3960,7 @@
   dnl   -- should only happen if CYGWIN && WITH_XPM && WITH_MSW && !WITH_X
   libpath_xpm=
   incpath_xpm=
+  libname_xpm="-lXpm"
   case "$opsys" in 
     cygwin*)
       cygwin_top=`eval gcc -print-search-dirs | sed -ne s'/install: //p'`
@@ -3970,6 +3971,7 @@
         dnl hardcode "standard" non-X11 xpm lib/inc dirs
         msw) libpath_xpm="-L${cygwin_top}/lib/noX"
              incpath_xpm="-I${cygwin_top}/include/noX"
+             libname_xpm="-lXpm-noX"
               ;;
         dnl not supported on cygwin (yet?)
         gtk)  ;;
@@ -3989,7 +3991,7 @@
     XE_PREPEND("$incpath_xpm", XE_CFLAGS)
     XE_PREPEND("$libpath_xpm", LDFLAGS)
     AC_MSG_CHECKING(for Xpm - no older than 3.4f)
-    xe_check_libs=-lXpm
+    xe_check_libs="$libname_xpm"
     AC_RUN_IFELSE([AC_LANG_SOURCE([#define XPM_NUMBERS
 #include <X11/xpm.h>
     int main(int c, char **v) {
@@ -4024,11 +4026,11 @@
     dnl #### but doesn't actually verify this assumption.
     AC_DEFINE(HAVE_XPM)
     XE_PREPEND("$libpath_xpm", LDFLAGS)
-    XE_PREPEND(-lXpm, libs_x)
+    XE_PREPEND("$libname_xpm", libs_x)
     XE_PREPEND("$incpath_xpm", CFLAGS)
     XE_PREPEND("$incpath_xpm", XE_CFLAGS)
     AC_MSG_CHECKING([for "FOR_MSW" xpm])
-    xe_check_libs=-lXpm
+    xe_check_libs="$libname_xpm"
     AC_LINK_IFELSE([AC_LANG_PROGRAM([],[XpmCreatePixmapFromData();])],
     [xpm_for_msw=no],
     [xpm_for_msw=yes])