X-Git-Url: http://git.chise.org/gitweb/?p=chise%2Fxemacs-chise.git.1;a=blobdiff_plain;f=configure.in;h=a2cd2fbd5a44e132ed17d4cb1ef19b56953fcddf;hp=4642dcd8630b3114d1a5c1753199465a71aecbed;hb=444774f2a4344be1585198435abff6c14224bb22;hpb=a44bbbfd0a7d2ff5a023d0448d65fe338384a7fc diff --git a/configure.in b/configure.in index 4642dcd..a2cd2fb 100644 --- a/configure.in +++ b/configure.in @@ -1899,9 +1899,9 @@ dnl We only cope with headers in mingw, not mingw32: no previous version of dnl XEmacs supported mingw and cygnus have made this incompatible change dnl so we just go with the flow. case "$opsys" in mingw* | cygwin*) - cygwin_include=`eval "gcc -print-file-name=libc.a"` ; - cygwin_include=`eval "dirname $cygwin_include"` ; - cygwin_include="-I$cygwin_include/../include" ; + cygwin_include=`eval gcc -print-search-dirs | sed -ne s'/install: //p'` + cygwin_include=`eval "cd $cygwin_include/../../../..; pwd"` + cygwin_include="-I$cygwin_include/include" ; extra_includes="$cygwin_include/mingw $cygwin_include" ; case "$opsys" in mingw*) XE_APPEND($extra_includes, c_switch_system) ;; @@ -2747,7 +2747,7 @@ if test "$with_x11" != "no"; then if test "$x_libraries" = "NONE"; then for dir in "/usr/X11/lib" "/usr/X11R6/lib" "/usr/lib/X11R6"; do - if test -r "$dir/libX11.a"; then x_libraries="$dir"; break; fi + if test -r "$dir/libX11.a" -o -r "$dir/libX11.dylib"; then x_libraries="$dir"; break; fi done fi @@ -3363,17 +3363,18 @@ if test "$window_system" != "none"; then 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-file-name=libc.a"` ; - cygwin_top=`eval "dirname ${cygwin_top}"`; - cygwin_top="${cygwin_top}/.."; + cygwin_top=`eval gcc -print-search-dirs | sed -ne s'/install: //p'` + cygwin_top=`eval "cd $cygwin_top/../../../..; pwd"` case "$window_system" in dnl use "standard" search pattern x11) ;; 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) ;; @@ -3392,7 +3393,7 @@ if test "$window_system" != "none"; then XE_PREPEND("$incpath_xpm", 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_TRY_RUN([#define XPM_NUMBERS #include int main(int c, char **v) { @@ -3427,10 +3428,10 @@ if test "$window_system" != "none"; then 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) AC_MSG_CHECKING(for \"FOR_MSW\" xpm) - xe_check_libs=-lXpm + xe_check_libs="$libname_xpm" AC_TRY_LINK(, [XpmCreatePixmapFromData()], [xpm_for_msw=no], [xpm_for_msw=yes])