aboutsummaryrefslogtreecommitdiff
path: root/gdb/configure
diff options
context:
space:
mode:
authorIan Lance Taylor <ian@airs.com>1997-08-01 19:24:55 +0000
committerIan Lance Taylor <ian@airs.com>1997-08-01 19:24:55 +0000
commit9b119644fcae6fa62749747e013cbc0b3c215217 (patch)
tree5f331f8ecabadaa470b3e3b97a8aef613cd983d4 /gdb/configure
parent931cde32b14f43f734f59253f975554021592e05 (diff)
downloadgdb-9b119644fcae6fa62749747e013cbc0b3c215217.zip
gdb-9b119644fcae6fa62749747e013cbc0b3c215217.tar.gz
gdb-9b119644fcae6fa62749747e013cbc0b3c215217.tar.bz2
* gdbtk.c (Tcl_Alloc): Don't provide our own version of this if
_WIN32. (Tcl_Realloc, Tcl_Free): Likewise. * configure.in: Check for cygwin32 environment. Define and substitute WIN32LIBS and WIN32LDAPP. Always set configdir to unix; setting it to win was for an old Tcl/Tk configuration scheme. * aclocal.m4 (CY_AC_LOAD_TKCONFIG): Substitute TK_BUILD_INCLUDES. * Makefile.in (TK_CFLAGS): Add @TK_BUILD_INCLUDES@. (WIN32LDAPP, WIN32LIBS): Define. (CLIBS): Add $(WIN32LIBS). (gdb): Use $(WIN32LDAPP). * configure: Rebuild.
Diffstat (limited to 'gdb/configure')
-rwxr-xr-xgdb/configure83
1 files changed, 62 insertions, 21 deletions
diff --git a/gdb/configure b/gdb/configure
index aa00d75..0e08faf 100755
--- a/gdb/configure
+++ b/gdb/configure
@@ -2478,14 +2478,46 @@ case "$host" in
fi
-case "${target}" in
-*-cygwin32)
- configdir="win"
- ;;
-*)
- configdir="unix"
- ;;
-esac
+# In the cygwin32 environment, we need some additional flags.
+echo $ac_n "checking for cygwin32""... $ac_c" 1>&6
+echo "configure:2484: checking for cygwin32" >&5
+if eval "test \"`echo '$''{'gdb_cv_os_cygwin32'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 2489 "configure"
+#include "confdefs.h"
+
+#ifdef __CYGWIN32__
+lose
+#endif
+EOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ egrep "lose" >/dev/null 2>&1; then
+ rm -rf conftest*
+ gdb_cv_os_cygwin32=yes
+else
+ rm -rf conftest*
+ gdb_cv_os_cygwin32=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$gdb_cv_os_cygwin32" 1>&6
+
+WIN32LIBS=
+WIN32LDAPP=
+
+
+
+if test x$gdb_cv_os_cygwin32 = xyes; then
+ if test x$enable_ide = xyes; then
+ WIN32LIBS="-ladvapi32"
+ fi
+fi
+
+configdir="unix"
if test "${enable_gdbtk}" = "yes"; then
@@ -2506,7 +2538,7 @@ if test "${with_tclconfig+set}" = set; then
fi
echo $ac_n "checking for Tcl configuration""... $ac_c" 1>&6
-echo "configure:2510: checking for Tcl configuration" >&5
+echo "configure:2542: checking for Tcl configuration" >&5
if eval "test \"`echo '$''{'ac_cv_c_tclconfig'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2614,7 +2646,7 @@ if test "${with_tkconfig+set}" = set; then
fi
echo $ac_n "checking for Tk configuration""... $ac_c" 1>&6
-echo "configure:2618: checking for Tk configuration" >&5
+echo "configure:2650: checking for Tk configuration" >&5
if eval "test \"`echo '$''{'ac_cv_c_tkconfig'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2697,6 +2729,7 @@ fi
+
#
@@ -2709,7 +2742,7 @@ fi
no_tcl=true
echo $ac_n "checking for Tcl private headers. dir=${configdir}""... $ac_c" 1>&6
-echo "configure:2713: checking for Tcl private headers. dir=${configdir}" >&5
+echo "configure:2746: checking for Tcl private headers. dir=${configdir}" >&5
# Check whether --with-tclinclude or --without-tclinclude was given.
if test "${with_tclinclude+set}" = set; then
withval="$with_tclinclude"
@@ -2775,17 +2808,17 @@ fi
if test x"${ac_cv_c_tclh}" = x ; then
ac_safe=`echo "tclInt.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for tclInt.h""... $ac_c" 1>&6
-echo "configure:2779: checking for tclInt.h" >&5
+echo "configure:2812: checking for tclInt.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2784 "configure"
+#line 2817 "configure"
#include "confdefs.h"
#include <tclInt.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2789: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2822: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2845,7 +2878,7 @@ fi
#
no_tk=true
echo $ac_n "checking for Tk private headers""... $ac_c" 1>&6
-echo "configure:2849: checking for Tk private headers" >&5
+echo "configure:2882: checking for Tk private headers" >&5
# Check whether --with-tkinclude or --without-tkinclude was given.
if test "${with_tkinclude+set}" = set; then
withval="$with_tkinclude"
@@ -2911,17 +2944,17 @@ fi
if test x"${ac_cv_c_tkh}" = x ; then
ac_safe=`echo "tk.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for tk.h""... $ac_c" 1>&6
-echo "configure:2915: checking for tk.h" >&5
+echo "configure:2948: checking for tk.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2920 "configure"
+#line 2953 "configure"
#include "confdefs.h"
#include <tk.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2925: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2958: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out`
if test -z "$ac_err"; then
rm -rf conftest*
@@ -2967,7 +3000,7 @@ fi
echo $ac_n "checking for Itcl private headers. srcdir=${srcdir}""... $ac_c" 1>&6
-echo "configure:2971: checking for Itcl private headers. srcdir=${srcdir}" >&5
+echo "configure:3004: checking for Itcl private headers. srcdir=${srcdir}" >&5
if test x"${ac_cv_c_itclh}" = x ; then
for i in ${srcdir}/../itcl ${srcdir}/../../itcl ${srcdir}/../../../itcl ; do
if test -f $i/src/itcl.h ; then
@@ -2990,7 +3023,7 @@ fi
echo $ac_n "checking for Tix private headers. srcdir=${srcdir}""... $ac_c" 1>&6
-echo "configure:2994: checking for Tix private headers. srcdir=${srcdir}" >&5
+echo "configure:3027: checking for Tix private headers. srcdir=${srcdir}" >&5
if test x"${ac_cv_c_tixh}" = x ; then
for i in ${srcdir}/../tix ${srcdir}/../../tix ${srcdir}/../../../tix ; do
if test -f $i/generic/tix.h ; then
@@ -3039,6 +3072,11 @@ fi
# after Tcl/Tk.
LIBS="${LIBS} ${TCL_LIBS} ${TK_LIBS}"
CONFIG_OBS="${CONFIG_OBS} gdbtk.o"
+
+ if test x$gdb_cv_os_cygwin32 = xyes; then
+ WIN32LIBS="${WIN32LIBS} -luser32"
+ WIN32LDAPP="-Wl,--subsystem,windows"
+ fi
fi
fi
fi
@@ -3191,7 +3229,7 @@ links="${links} nm.h"
fi
# start-sanitize-gdbtk
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:3195: checking whether ln -s works" >&5
+echo "configure:3233: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -3383,6 +3421,8 @@ s%@YACC@%$YACC%g
s%@AWK@%$AWK%g
s%@CONFIG_LDFLAGS@%$CONFIG_LDFLAGS%g
s%@ENABLE_IDE@%$ENABLE_IDE%g
+s%@WIN32LIBS@%$WIN32LIBS%g
+s%@WIN32LDAPP@%$WIN32LDAPP%g
s%@TCL_VERSION@%$TCL_VERSION%g
s%@TCL_MAJOR_VERSION@%$TCL_MAJOR_VERSION%g
s%@TCL_MINOR_VERSION@%$TCL_MINOR_VERSION%g
@@ -3402,6 +3442,7 @@ s%@TCL_LIB_SPEC@%$TCL_LIB_SPEC%g
s%@TCL_LIB_VERSIONS_OK@%$TCL_LIB_VERSIONS_OK%g
s%@TK_VERSION@%$TK_VERSION%g
s%@TK_DEFS@%$TK_DEFS%g
+s%@TK_BUILD_INCLUDES@%$TK_BUILD_INCLUDES%g
s%@TK_XINCLUDES@%$TK_XINCLUDES%g
s%@TK_XLIBSW@%$TK_XLIBSW%g
s%@TK_BUILD_LIB_SPEC@%$TK_BUILD_LIB_SPEC%g