OSDN Git Service

* dll_init.cc (dll_global_dtors): Add an additional test to avoid walking the
[pf3gnuchains/pf3gnuchains4x.git] / gdb / gdbtk / plugins / configure.ac
1 AC_INIT(Make-rules)
2 AC_CONFIG_AUX_DIR(../../..)
3 AM_INIT_AUTOMAKE(insight, 1.0)
4 AM_MAINTAINER_MODE
5 AC_PROG_MAKE_SET
6 AC_CANONICAL_HOST
7 AC_PROG_CC
8 AC_OBJEXT
9 AC_EXEEXT
10
11 # Find Tcl, Tk, etc
12 SC_PATH_TCLCONFIG
13 SC_LOAD_TCLCONFIG
14 SC_PATH_TKCONFIG
15 SC_LOAD_TKCONFIG
16
17 # Special in-tree hackery
18 here=`pwd`
19 cd ${srcdir}/../../..
20 topdir=`pwd`
21 cd ${here}
22
23 if test "${TCL_SRC_DIR}" = "${topdir}/tcl"; then
24   TCL_INCLUDES="-I${TCL_SRC_DIR}/generic"
25   TCL_LIBRARY="${TCL_BUILD_LIB_SPEC}"
26 else
27   TCL_INCLUDES="${TCL_INCLUDE_SPEC}"
28   TCL_LIBRARY="${TCL_LIB_SPEC}"
29 fi
30
31 AC_SUBST(TCL_DBGX)
32 AC_SUBST(TCL_SHLIB_CFLAGS)
33 AC_SUBST(TCL_SHLIB_LD)
34 AC_SUBST(TCL_SHLIB_SUFFIX)
35 AC_SUBST(TCL_INCLUDES)
36 AC_SUBST(TCL_LIBRARY)
37
38 # Make sure TCL_SHLIB_SUFFIX is set
39 if test x$TCL_SHLIB_SUFFIX = x ; then
40   case "${host}" in
41     *cygwin*) TCL_SHLIB_SUFFIX=".dll" ;;
42     *) TCL_SHILB_SUFFIX=".so" ;;
43   esac
44 fi
45 AC_SUBST(TCL_SHLIB_SUFFIX)
46
47 # Since we're not using autoconf > 2.1x, we cannot use AC_CONFIG_FILES.
48 make_subdirs=""
49
50 # See if -mwin32 works for cygwin
51 case "${host}" in
52   *cygwin*)
53     ocflags=${CFLAGS}
54     CFLAGS="${CFLAGS} -mwin32"
55     AC_TRY_COMPILE(,,,CFLAGS="${ocflags}")
56     ;;
57   *) ;;
58 esac
59
60 # note toplevel plugin build directory
61 plugin_builddir=`pwd`
62
63 #
64 # Plugins
65 #
66
67 # Supported hosts
68
69 # Only supported/tested on linux, solaris, cygwin
70 supported=yes
71 case "${host}" in
72   *cygwin*) ;;
73   *solaris*) ;;
74   *linux*) ;;
75   *) supported=no ;;
76 esac
77
78 # Host-specific configury
79 case "${host}" in
80   *cygwin*)
81     AC_CHECK_TOOL(NM, nm, nm)
82     AC_CHECK_TOOL(AS, as, as)
83     AC_CHECK_TOOL(LD, ld, ld)
84     AC_MSG_CHECKING("for libcygwin.a")
85     LIBCYGWIN_A=`$CC -print-file-name=libcygwin.a`
86     AC_MSG_RESULT($LIBCYGWIN_A)
87     AC_SUBST(LIBCYGWIN_A)
88     AC_CHECK_TOOL(DLLTOOL, dlltool)
89     ;;
90 esac
91
92 # Plugins supported by this configuration
93 if test x${supported} = xyes; then
94   plugins="rhabout"
95   case "${target}" in
96     *cygwin*) ;;
97     *linux*) ;;
98     *i?86*)
99       plugins="${plugins} intel-pentium"
100       ;;
101   esac
102
103   for i in $plugins ; do
104     make_subdirs="${make_subdirs} $i"
105   done
106 fi
107
108 AC_SUBST(make_subdirs)
109 AC_SUBST(plugin_builddir)
110
111 AC_OUTPUT(Makefile rhabout/Makefile:rhabout/Makefile.in:Make-rules rhabout/rhabout.tcl intel-pentium/Makefile:intel-pentium/Makefile.in:Make-rules intel-pentium/intel-pentium.tcl)