| 1 | #! /bin/bash -norc |
|---|
| 2 | # This file is an input file used by the GNU "autoconf" program to |
|---|
| 3 | # generate the file "configure", which is run during Tcl installation |
|---|
| 4 | # to configure the system for the local environment. |
|---|
| 5 | # |
|---|
| 6 | # RCS: @(#) $Id: configure.in,v 1.104 2008/03/28 17:31:48 dgp Exp $ |
|---|
| 7 | |
|---|
| 8 | AC_INIT(../generic/tcl.h) |
|---|
| 9 | AC_PREREQ(2.59) |
|---|
| 10 | |
|---|
| 11 | # The following define is needed when building with Cygwin since newer |
|---|
| 12 | # versions of autoconf incorrectly set SHELL to /bin/bash instead of |
|---|
| 13 | # /bin/sh. The bash shell seems to suffer from some strange failures. |
|---|
| 14 | SHELL=/bin/sh |
|---|
| 15 | |
|---|
| 16 | TCL_VERSION=8.5 |
|---|
| 17 | TCL_MAJOR_VERSION=8 |
|---|
| 18 | TCL_MINOR_VERSION=5 |
|---|
| 19 | TCL_PATCH_LEVEL=".2" |
|---|
| 20 | VER=$TCL_MAJOR_VERSION$TCL_MINOR_VERSION |
|---|
| 21 | |
|---|
| 22 | TCL_DDE_VERSION=1.3 |
|---|
| 23 | TCL_DDE_MAJOR_VERSION=1 |
|---|
| 24 | TCL_DDE_MINOR_VERSION=3 |
|---|
| 25 | TCL_DDE_PATCH_LEVEL="2" |
|---|
| 26 | DDEVER=$TCL_DDE_MAJOR_VERSION$TCL_DDE_MINOR_VERSION |
|---|
| 27 | |
|---|
| 28 | TCL_REG_VERSION=1.2 |
|---|
| 29 | TCL_REG_MAJOR_VERSION=1 |
|---|
| 30 | TCL_REG_MINOR_VERSION=2 |
|---|
| 31 | TCL_REG_PATCH_LEVEL="1" |
|---|
| 32 | REGVER=$TCL_REG_MAJOR_VERSION$TCL_REG_MINOR_VERSION |
|---|
| 33 | |
|---|
| 34 | #------------------------------------------------------------------------ |
|---|
| 35 | # Handle the --prefix=... option |
|---|
| 36 | #------------------------------------------------------------------------ |
|---|
| 37 | |
|---|
| 38 | if test "${prefix}" = "NONE"; then |
|---|
| 39 | prefix=/usr/local |
|---|
| 40 | fi |
|---|
| 41 | if test "${exec_prefix}" = "NONE"; then |
|---|
| 42 | exec_prefix=$prefix |
|---|
| 43 | fi |
|---|
| 44 | # libdir must be a fully qualified path (not ${exec_prefix}/lib) |
|---|
| 45 | eval libdir="$libdir" |
|---|
| 46 | |
|---|
| 47 | #------------------------------------------------------------------------ |
|---|
| 48 | # Standard compiler checks |
|---|
| 49 | #------------------------------------------------------------------------ |
|---|
| 50 | |
|---|
| 51 | # If the user did not set CFLAGS, set it now to keep |
|---|
| 52 | # the AC_PROG_CC macro from adding "-g -O2". |
|---|
| 53 | if test "${CFLAGS+set}" != "set" ; then |
|---|
| 54 | CFLAGS="" |
|---|
| 55 | fi |
|---|
| 56 | |
|---|
| 57 | AC_PROG_CC |
|---|
| 58 | AC_C_INLINE |
|---|
| 59 | AC_HEADER_STDC |
|---|
| 60 | |
|---|
| 61 | # To properly support cross-compilation, one would |
|---|
| 62 | # need to use these tool checks instead of |
|---|
| 63 | # the ones below and reconfigure with |
|---|
| 64 | # autoconf 2.50. You can also just set |
|---|
| 65 | # the CC, AR, RANLIB, and RC environment |
|---|
| 66 | # variables if you want to cross compile. |
|---|
| 67 | dnl AC_CHECK_TOOL(AR, ar) |
|---|
| 68 | dnl AC_CHECK_TOOL(RANLIB, ranlib) |
|---|
| 69 | dnl AC_CHECK_TOOL(RC, windres) |
|---|
| 70 | |
|---|
| 71 | if test "${GCC}" = "yes" ; then |
|---|
| 72 | AC_CHECK_PROG(AR, ar, ar) |
|---|
| 73 | AC_CHECK_PROG(RANLIB, ranlib, ranlib) |
|---|
| 74 | AC_CHECK_PROG(RC, windres, windres) |
|---|
| 75 | |
|---|
| 76 | if test "${AR}" = "" ; then |
|---|
| 77 | AC_MSG_ERROR([Required archive tool 'ar' not found on PATH.]) |
|---|
| 78 | fi |
|---|
| 79 | if test "${RANLIB}" = "" ; then |
|---|
| 80 | AC_MSG_ERROR([Required archive index tool 'ranlib' not found on PATH.]) |
|---|
| 81 | fi |
|---|
| 82 | if test "${RC}" = "" ; then |
|---|
| 83 | AC_MSG_ERROR([Required resource tool 'windres' not found on PATH.]) |
|---|
| 84 | fi |
|---|
| 85 | fi |
|---|
| 86 | |
|---|
| 87 | #-------------------------------------------------------------------- |
|---|
| 88 | # Checks to see if the make program sets the $MAKE variable. |
|---|
| 89 | #-------------------------------------------------------------------- |
|---|
| 90 | |
|---|
| 91 | AC_PROG_MAKE_SET |
|---|
| 92 | |
|---|
| 93 | #-------------------------------------------------------------------- |
|---|
| 94 | # Perform additinal compiler tests. |
|---|
| 95 | #-------------------------------------------------------------------- |
|---|
| 96 | |
|---|
| 97 | dnl Currently AC_CYGWIN is disabled since it invokes AC_CANONICAL_HOST |
|---|
| 98 | dnl under autoconf 2.5X. |
|---|
| 99 | dnl |
|---|
| 100 | dnl AC_CYGWIN |
|---|
| 101 | |
|---|
| 102 | AC_CACHE_CHECK(for Cygwin version of gcc, |
|---|
| 103 | ac_cv_cygwin, |
|---|
| 104 | AC_TRY_COMPILE([ |
|---|
| 105 | #ifdef __CYGWIN__ |
|---|
| 106 | #error cygwin |
|---|
| 107 | #endif |
|---|
| 108 | ], |
|---|
| 109 | [], |
|---|
| 110 | ac_cv_cygwin=no, |
|---|
| 111 | ac_cv_cygwin=yes) |
|---|
| 112 | ) |
|---|
| 113 | if test "$ac_cv_cygwin" = "yes" ; then |
|---|
| 114 | AC_MSG_ERROR([Compiling under Cygwin is not currently supported. |
|---|
| 115 | A maintainer for the Cygwin port of Tcl/Tk is needed. See the README |
|---|
| 116 | file for information about building with Mingw.]) |
|---|
| 117 | fi |
|---|
| 118 | |
|---|
| 119 | |
|---|
| 120 | AC_CACHE_CHECK(for SEH support in compiler, |
|---|
| 121 | tcl_cv_seh, |
|---|
| 122 | AC_TRY_RUN([ |
|---|
| 123 | #define WIN32_LEAN_AND_MEAN |
|---|
| 124 | #include <windows.h> |
|---|
| 125 | #undef WIN32_LEAN_AND_MEAN |
|---|
| 126 | |
|---|
| 127 | int main(int argc, char** argv) { |
|---|
| 128 | int a, b = 0; |
|---|
| 129 | __try { |
|---|
| 130 | a = 666 / b; |
|---|
| 131 | } |
|---|
| 132 | __except (EXCEPTION_EXECUTE_HANDLER) { |
|---|
| 133 | return 0; |
|---|
| 134 | } |
|---|
| 135 | return 1; |
|---|
| 136 | } |
|---|
| 137 | ], |
|---|
| 138 | tcl_cv_seh=yes, |
|---|
| 139 | tcl_cv_seh=no, |
|---|
| 140 | tcl_cv_seh=no) |
|---|
| 141 | ) |
|---|
| 142 | if test "$tcl_cv_seh" = "no" ; then |
|---|
| 143 | AC_DEFINE(HAVE_NO_SEH, 1, |
|---|
| 144 | [Defined when mingw does not support SEH]) |
|---|
| 145 | fi |
|---|
| 146 | |
|---|
| 147 | # |
|---|
| 148 | # Check to see if the excpt.h include file provided contains the |
|---|
| 149 | # definition for EXCEPTION_DISPOSITION; if not, which is the case |
|---|
| 150 | # with Cygwin's version as of 2002-04-10, define it to be int, |
|---|
| 151 | # sufficient for getting the current code to work. |
|---|
| 152 | # |
|---|
| 153 | AC_CACHE_CHECK(for EXCEPTION_DISPOSITION support in include files, |
|---|
| 154 | tcl_cv_eh_disposition, |
|---|
| 155 | AC_TRY_COMPILE([ |
|---|
| 156 | #define WIN32_LEAN_AND_MEAN |
|---|
| 157 | #include <windows.h> |
|---|
| 158 | #undef WIN32_LEAN_AND_MEAN |
|---|
| 159 | ], |
|---|
| 160 | [ |
|---|
| 161 | EXCEPTION_DISPOSITION x; |
|---|
| 162 | ], |
|---|
| 163 | tcl_cv_eh_disposition=yes, |
|---|
| 164 | tcl_cv_eh_disposition=no) |
|---|
| 165 | ) |
|---|
| 166 | if test "$tcl_cv_eh_disposition" = "no" ; then |
|---|
| 167 | AC_DEFINE(EXCEPTION_DISPOSITION, int, |
|---|
| 168 | [Defined when cygwin/mingw does not support EXCEPTION DISPOSITION]) |
|---|
| 169 | fi |
|---|
| 170 | |
|---|
| 171 | |
|---|
| 172 | # Check to see if the winsock2.h include file provided contains |
|---|
| 173 | # typedefs like LPFN_ACCEPT and friends. |
|---|
| 174 | # |
|---|
| 175 | AC_CACHE_CHECK(for LPFN_ACCEPT support in winsock2.h, |
|---|
| 176 | tcl_cv_lpfn_decls, |
|---|
| 177 | AC_TRY_COMPILE([ |
|---|
| 178 | #define WIN32_LEAN_AND_MEAN |
|---|
| 179 | #include <windows.h> |
|---|
| 180 | #undef WIN32_LEAN_AND_MEAN |
|---|
| 181 | #include <winsock2.h> |
|---|
| 182 | ], |
|---|
| 183 | [ |
|---|
| 184 | LPFN_ACCEPT accept; |
|---|
| 185 | ], |
|---|
| 186 | tcl_cv_lpfn_decls=yes, |
|---|
| 187 | tcl_cv_lpfn_decls=no) |
|---|
| 188 | ) |
|---|
| 189 | if test "$tcl_cv_lpfn_decls" = "no" ; then |
|---|
| 190 | AC_DEFINE(HAVE_NO_LPFN_DECLS, 1, |
|---|
| 191 | [Defined when cygwin/mingw does not support LPFN_ACCEPT and friends.]) |
|---|
| 192 | fi |
|---|
| 193 | |
|---|
| 194 | # Check to see if winnt.h defines CHAR, SHORT, and LONG |
|---|
| 195 | # even if VOID has already been #defined. The win32api |
|---|
| 196 | # used by mingw and cygwin is known to do this. |
|---|
| 197 | |
|---|
| 198 | AC_CACHE_CHECK(for winnt.h that ignores VOID define, |
|---|
| 199 | tcl_cv_winnt_ignore_void, |
|---|
| 200 | AC_TRY_COMPILE([ |
|---|
| 201 | #define VOID void |
|---|
| 202 | #define WIN32_LEAN_AND_MEAN |
|---|
| 203 | #include <windows.h> |
|---|
| 204 | #undef WIN32_LEAN_AND_MEAN |
|---|
| 205 | ], |
|---|
| 206 | [ |
|---|
| 207 | CHAR c; |
|---|
| 208 | SHORT s; |
|---|
| 209 | LONG l; |
|---|
| 210 | ], |
|---|
| 211 | tcl_cv_winnt_ignore_void=yes, |
|---|
| 212 | tcl_cv_winnt_ignore_void=no) |
|---|
| 213 | ) |
|---|
| 214 | if test "$tcl_cv_winnt_ignore_void" = "yes" ; then |
|---|
| 215 | AC_DEFINE(HAVE_WINNT_IGNORE_VOID, 1, |
|---|
| 216 | [Defined when cygwin/mingw ignores VOID define in winnt.h]) |
|---|
| 217 | fi |
|---|
| 218 | |
|---|
| 219 | # Check to see if malloc.h is missing the alloca function |
|---|
| 220 | # declaration. This is known to be a problem with Mingw. |
|---|
| 221 | # If we compiled without the function declaration, it |
|---|
| 222 | # would work but we would get a warning message from gcc. |
|---|
| 223 | # If we add the function declaration ourselves, it |
|---|
| 224 | # would not compile correctly because the _alloca |
|---|
| 225 | # function expects the argument to be passed in a |
|---|
| 226 | # register and not on the stack. Instead, we just |
|---|
| 227 | # call it from inline asm code. |
|---|
| 228 | |
|---|
| 229 | AC_CACHE_CHECK(for alloca declaration in malloc.h, |
|---|
| 230 | tcl_cv_malloc_decl_alloca, |
|---|
| 231 | AC_TRY_COMPILE([ |
|---|
| 232 | #include <malloc.h> |
|---|
| 233 | ], |
|---|
| 234 | [ |
|---|
| 235 | size_t arg = 0; |
|---|
| 236 | void* ptr; |
|---|
| 237 | ptr = alloca; |
|---|
| 238 | ptr = alloca(arg); |
|---|
| 239 | ], |
|---|
| 240 | tcl_cv_malloc_decl_alloca=yes, |
|---|
| 241 | tcl_cv_malloc_decl_alloca=no) |
|---|
| 242 | ) |
|---|
| 243 | if test "$tcl_cv_malloc_decl_alloca" = "no" && |
|---|
| 244 | test "${GCC}" = "yes" ; then |
|---|
| 245 | AC_DEFINE(HAVE_ALLOCA_GCC_INLINE, 1, |
|---|
| 246 | [Defined when gcc should use inline ASM to call alloca.]) |
|---|
| 247 | fi |
|---|
| 248 | |
|---|
| 249 | # See if the compiler supports casting to a union type. |
|---|
| 250 | # This is used to stop gcc from printing a compiler |
|---|
| 251 | # warning when initializing a union member. |
|---|
| 252 | |
|---|
| 253 | AC_CACHE_CHECK(for cast to union support, |
|---|
| 254 | tcl_cv_cast_to_union, |
|---|
| 255 | AC_TRY_COMPILE([], |
|---|
| 256 | [ |
|---|
| 257 | union foo { int i; double d; }; |
|---|
| 258 | union foo f = (union foo) (int) 0; |
|---|
| 259 | ], |
|---|
| 260 | tcl_cv_cast_to_union=yes, |
|---|
| 261 | tcl_cv_cast_to_union=no) |
|---|
| 262 | ) |
|---|
| 263 | if test "$tcl_cv_cast_to_union" = "yes"; then |
|---|
| 264 | AC_DEFINE(HAVE_CAST_TO_UNION, 1, |
|---|
| 265 | [Defined when compiler supports casting to union type.]) |
|---|
| 266 | fi |
|---|
| 267 | |
|---|
| 268 | |
|---|
| 269 | # See if declarations like FINDEX_INFO_LEVELS are |
|---|
| 270 | # missing from winbase.h. This is known to be |
|---|
| 271 | # a problem with VC++ 5.2. |
|---|
| 272 | |
|---|
| 273 | AC_CACHE_CHECK(for FINDEX_INFO_LEVELS in winbase.h, |
|---|
| 274 | tcl_cv_findex_enums, |
|---|
| 275 | AC_TRY_COMPILE([ |
|---|
| 276 | #define WIN32_LEAN_AND_MEAN |
|---|
| 277 | #include <windows.h> |
|---|
| 278 | #undef WIN32_LEAN_AND_MEAN |
|---|
| 279 | ], |
|---|
| 280 | [ |
|---|
| 281 | FINDEX_INFO_LEVELS i; |
|---|
| 282 | FINDEX_SEARCH_OPS j; |
|---|
| 283 | ], |
|---|
| 284 | tcl_cv_findex_enums=yes, |
|---|
| 285 | tcl_cv_findex_enums=no) |
|---|
| 286 | ) |
|---|
| 287 | if test "$tcl_cv_findex_enums" = "no"; then |
|---|
| 288 | AC_DEFINE(HAVE_NO_FINDEX_ENUMS, 1, |
|---|
| 289 | [Defined when enums are missing from winbase.h]) |
|---|
| 290 | fi |
|---|
| 291 | |
|---|
| 292 | # See if MWMO_ALERTABLE is missing from winuser.h |
|---|
| 293 | # This is known to be a problem with Mingw. |
|---|
| 294 | |
|---|
| 295 | AC_CACHE_CHECK(for MWMO_ALERTABLE in winuser.h, |
|---|
| 296 | tcl_cv_mwmo_alertable, |
|---|
| 297 | AC_TRY_COMPILE([ |
|---|
| 298 | #define WIN32_LEAN_AND_MEAN |
|---|
| 299 | #include <windows.h> |
|---|
| 300 | #undef WIN32_LEAN_AND_MEAN |
|---|
| 301 | ], |
|---|
| 302 | [ |
|---|
| 303 | int i = MWMO_ALERTABLE; |
|---|
| 304 | ], |
|---|
| 305 | tcl_cv_mwmo_alertable=yes, |
|---|
| 306 | tcl_cv_mwmo_alertable=no) |
|---|
| 307 | ) |
|---|
| 308 | if test "$tcl_cv_mwmo_alertable" = "no"; then |
|---|
| 309 | AC_DEFINE(HAVE_NO_MWMO_ALERTABLE, 1, |
|---|
| 310 | [Defined when MWMO_ALERTABLE is missing from winuser.h]) |
|---|
| 311 | fi |
|---|
| 312 | |
|---|
| 313 | #-------------------------------------------------------------------- |
|---|
| 314 | # Determines the correct binary file extension (.o, .obj, .exe etc.) |
|---|
| 315 | #-------------------------------------------------------------------- |
|---|
| 316 | |
|---|
| 317 | AC_OBJEXT |
|---|
| 318 | AC_EXEEXT |
|---|
| 319 | |
|---|
| 320 | #-------------------------------------------------------------------- |
|---|
| 321 | # Check whether --enable-threads or --disable-threads was given. |
|---|
| 322 | #-------------------------------------------------------------------- |
|---|
| 323 | |
|---|
| 324 | SC_ENABLE_THREADS |
|---|
| 325 | |
|---|
| 326 | #------------------------------------------------------------------------ |
|---|
| 327 | # Embedded configuration information, encoding to use for the values, TIP #59 |
|---|
| 328 | #------------------------------------------------------------------------ |
|---|
| 329 | |
|---|
| 330 | SC_TCL_CFG_ENCODING |
|---|
| 331 | |
|---|
| 332 | #-------------------------------------------------------------------- |
|---|
| 333 | # The statements below define a collection of symbols related to |
|---|
| 334 | # building libtcl as a shared library instead of a static library. |
|---|
| 335 | #-------------------------------------------------------------------- |
|---|
| 336 | |
|---|
| 337 | SC_ENABLE_SHARED |
|---|
| 338 | |
|---|
| 339 | #-------------------------------------------------------------------- |
|---|
| 340 | # The statements below define a collection of compile flags. This |
|---|
| 341 | # macro depends on the value of SHARED_BUILD, and should be called |
|---|
| 342 | # after SC_ENABLE_SHARED checks the configure switches. |
|---|
| 343 | #-------------------------------------------------------------------- |
|---|
| 344 | |
|---|
| 345 | SC_CONFIG_CFLAGS |
|---|
| 346 | |
|---|
| 347 | #-------------------------------------------------------------------- |
|---|
| 348 | # Set the default compiler switches based on the --enable-symbols |
|---|
| 349 | # option. This macro depends on C flags, and should be called |
|---|
| 350 | # after SC_CONFIG_CFLAGS macro is called. |
|---|
| 351 | #-------------------------------------------------------------------- |
|---|
| 352 | |
|---|
| 353 | SC_ENABLE_SYMBOLS |
|---|
| 354 | |
|---|
| 355 | TCL_DBGX=${DBGX} |
|---|
| 356 | |
|---|
| 357 | #------------------------------------------------------------------------ |
|---|
| 358 | # tclConfig.sh refers to this by a different name |
|---|
| 359 | #------------------------------------------------------------------------ |
|---|
| 360 | |
|---|
| 361 | TCL_SHARED_BUILD=${SHARED_BUILD} |
|---|
| 362 | |
|---|
| 363 | #-------------------------------------------------------------------- |
|---|
| 364 | # Perform final evaluations of variables with possible substitutions. |
|---|
| 365 | #-------------------------------------------------------------------- |
|---|
| 366 | |
|---|
| 367 | TCL_SHARED_LIB_SUFFIX="\${NODOT_VERSION}${DLLSUFFIX}" |
|---|
| 368 | TCL_UNSHARED_LIB_SUFFIX="\${NODOT_VERSION}${LIBSUFFIX}" |
|---|
| 369 | TCL_EXPORT_FILE_SUFFIX="\${NODOT_VERSION}${LIBSUFFIX}" |
|---|
| 370 | |
|---|
| 371 | eval "TCL_SRC_DIR=\"`cd $srcdir/..; pwd`\"" |
|---|
| 372 | |
|---|
| 373 | eval "TCL_DLL_FILE=tcl${VER}${DLLSUFFIX}" |
|---|
| 374 | |
|---|
| 375 | eval "TCL_LIB_FILE=${LIBPREFIX}tcl$VER${LIBSUFFIX}" |
|---|
| 376 | |
|---|
| 377 | eval "TCL_LIB_FLAG=\"-ltcl${VER}${LIBFLAGSUFFIX}\"" |
|---|
| 378 | eval "TCL_BUILD_LIB_SPEC=\"-L`pwd` ${TCL_LIB_FLAG}\"" |
|---|
| 379 | eval "TCL_LIB_SPEC=\"-L${libdir} ${TCL_LIB_FLAG}\"" |
|---|
| 380 | |
|---|
| 381 | eval "TCL_STUB_LIB_FILE=\"${LIBPREFIX}tclstub${VER}${LIBSUFFIX}\"" |
|---|
| 382 | eval "TCL_STUB_LIB_FLAG=\"-ltclstub${VER}${LIBFLAGSUFFIX}\"" |
|---|
| 383 | eval "TCL_BUILD_STUB_LIB_SPEC=\"-L`pwd` ${TCL_STUB_LIB_FLAG}\"" |
|---|
| 384 | eval "TCL_STUB_LIB_SPEC=\"-L${libdir} ${TCL_STUB_LIB_FLAG}\"" |
|---|
| 385 | eval "TCL_BUILD_STUB_LIB_PATH=\"`pwd`/${TCL_STUB_LIB_FILE}\"" |
|---|
| 386 | eval "TCL_STUB_LIB_PATH=\"${libdir}/${TCL_STUB_LIB_FILE}\"" |
|---|
| 387 | |
|---|
| 388 | # Install time header dir can be set via --includedir |
|---|
| 389 | eval "TCL_INCLUDE_SPEC=\"-I${includedir}\"" |
|---|
| 390 | |
|---|
| 391 | |
|---|
| 392 | eval "DLLSUFFIX=${DLLSUFFIX}" |
|---|
| 393 | eval "LIBPREFIX=${LIBPREFIX}" |
|---|
| 394 | eval "LIBSUFFIX=${LIBSUFFIX}" |
|---|
| 395 | eval "EXESUFFIX=${EXESUFFIX}" |
|---|
| 396 | |
|---|
| 397 | CFG_TCL_SHARED_LIB_SUFFIX=${TCL_SHARED_LIB_SUFFIX} |
|---|
| 398 | CFG_TCL_UNSHARED_LIB_SUFFIX=${TCL_UNSHARED_LIB_SUFFIX} |
|---|
| 399 | CFG_TCL_EXPORT_FILE_SUFFIX=${TCL_EXPORT_FILE_SUFFIX} |
|---|
| 400 | |
|---|
| 401 | #-------------------------------------------------------------------- |
|---|
| 402 | # Adjust the defines for how the resources are built depending |
|---|
| 403 | # on symbols and static vs. shared. |
|---|
| 404 | #-------------------------------------------------------------------- |
|---|
| 405 | |
|---|
| 406 | if test ${SHARED_BUILD} = 0 ; then |
|---|
| 407 | if test "${DBGX}" = "g"; then |
|---|
| 408 | RC_DEFINES="${RC_DEFINE} STATIC_BUILD ${RC_DEFINE} DEBUG" |
|---|
| 409 | else |
|---|
| 410 | RC_DEFINES="${RC_DEFINE} STATIC_BUILD" |
|---|
| 411 | fi |
|---|
| 412 | else |
|---|
| 413 | if test "${DBGX}" = "g"; then |
|---|
| 414 | RC_DEFINES="${RC_DEFINE} DEBUG" |
|---|
| 415 | else |
|---|
| 416 | RC_DEFINES="" |
|---|
| 417 | fi |
|---|
| 418 | fi |
|---|
| 419 | |
|---|
| 420 | #-------------------------------------------------------------------- |
|---|
| 421 | # The statements below define the symbol TCL_PACKAGE_PATH, which |
|---|
| 422 | # gives a list of directories that may contain packages. The list |
|---|
| 423 | # consists of one directory for machine-dependent binaries and |
|---|
| 424 | # another for platform-independent scripts. |
|---|
| 425 | #-------------------------------------------------------------------- |
|---|
| 426 | |
|---|
| 427 | if test "$prefix/lib" != "$libdir"; then |
|---|
| 428 | TCL_PACKAGE_PATH="${libdir} ${prefix}/lib" |
|---|
| 429 | else |
|---|
| 430 | TCL_PACKAGE_PATH="${prefix}/lib" |
|---|
| 431 | fi |
|---|
| 432 | |
|---|
| 433 | AC_SUBST(TCL_VERSION) |
|---|
| 434 | AC_SUBST(TCL_MAJOR_VERSION) |
|---|
| 435 | AC_SUBST(TCL_MINOR_VERSION) |
|---|
| 436 | AC_SUBST(TCL_PATCH_LEVEL) |
|---|
| 437 | |
|---|
| 438 | AC_SUBST(TCL_LIB_FILE) |
|---|
| 439 | AC_SUBST(TCL_LIB_FLAG) |
|---|
| 440 | # empty on win |
|---|
| 441 | AC_SUBST(TCL_LIB_SPEC) |
|---|
| 442 | AC_SUBST(TCL_STUB_LIB_FILE) |
|---|
| 443 | AC_SUBST(TCL_STUB_LIB_FLAG) |
|---|
| 444 | AC_SUBST(TCL_STUB_LIB_SPEC) |
|---|
| 445 | AC_SUBST(TCL_STUB_LIB_PATH) |
|---|
| 446 | AC_SUBST(TCL_INCLUDE_SPEC) |
|---|
| 447 | AC_SUBST(TCL_BUILD_STUB_LIB_SPEC) |
|---|
| 448 | AC_SUBST(TCL_BUILD_STUB_LIB_PATH) |
|---|
| 449 | AC_SUBST(TCL_DLL_FILE) |
|---|
| 450 | |
|---|
| 451 | AC_SUBST(TCL_SRC_DIR) |
|---|
| 452 | AC_SUBST(TCL_BIN_DIR) |
|---|
| 453 | AC_SUBST(TCL_DBGX) |
|---|
| 454 | AC_SUBST(CFG_TCL_SHARED_LIB_SUFFIX) |
|---|
| 455 | AC_SUBST(CFG_TCL_UNSHARED_LIB_SUFFIX) |
|---|
| 456 | AC_SUBST(CFG_TCL_EXPORT_FILE_SUFFIX) |
|---|
| 457 | |
|---|
| 458 | # win/tcl.m4 doesn't set (CFLAGS) |
|---|
| 459 | AC_SUBST(CFLAGS_DEFAULT) |
|---|
| 460 | AC_SUBST(EXTRA_CFLAGS) |
|---|
| 461 | AC_SUBST(CYGPATH) |
|---|
| 462 | AC_SUBST(DEPARG) |
|---|
| 463 | AC_SUBST(CC_OBJNAME) |
|---|
| 464 | AC_SUBST(CC_EXENAME) |
|---|
| 465 | |
|---|
| 466 | # win/tcl.m4 doesn't set (LDFLAGS) |
|---|
| 467 | AC_SUBST(LDFLAGS_DEFAULT) |
|---|
| 468 | AC_SUBST(LDFLAGS_DEBUG) |
|---|
| 469 | AC_SUBST(LDFLAGS_OPTIMIZE) |
|---|
| 470 | AC_SUBST(LDFLAGS_CONSOLE) |
|---|
| 471 | AC_SUBST(LDFLAGS_WINDOW) |
|---|
| 472 | AC_SUBST(AR) |
|---|
| 473 | AC_SUBST(RANLIB) |
|---|
| 474 | |
|---|
| 475 | AC_SUBST(STLIB_LD) |
|---|
| 476 | AC_SUBST(SHLIB_LD) |
|---|
| 477 | AC_SUBST(SHLIB_LD_LIBS) |
|---|
| 478 | AC_SUBST(SHLIB_CFLAGS) |
|---|
| 479 | AC_SUBST(SHLIB_SUFFIX) |
|---|
| 480 | AC_SUBST(TCL_SHARED_BUILD) |
|---|
| 481 | |
|---|
| 482 | AC_SUBST(LIBS) |
|---|
| 483 | AC_SUBST(LIBS_GUI) |
|---|
| 484 | AC_SUBST(DLLSUFFIX) |
|---|
| 485 | AC_SUBST(LIBPREFIX) |
|---|
| 486 | AC_SUBST(LIBSUFFIX) |
|---|
| 487 | AC_SUBST(EXESUFFIX) |
|---|
| 488 | AC_SUBST(LIBRARIES) |
|---|
| 489 | AC_SUBST(MAKE_LIB) |
|---|
| 490 | AC_SUBST(POST_MAKE_LIB) |
|---|
| 491 | AC_SUBST(MAKE_DLL) |
|---|
| 492 | AC_SUBST(MAKE_EXE) |
|---|
| 493 | |
|---|
| 494 | # empty on win, but needs sub'ing |
|---|
| 495 | AC_SUBST(TCL_BUILD_LIB_SPEC) |
|---|
| 496 | AC_SUBST(TCL_LD_SEARCH_FLAGS) |
|---|
| 497 | AC_SUBST(TCL_NEEDS_EXP_FILE) |
|---|
| 498 | AC_SUBST(TCL_BUILD_EXP_FILE) |
|---|
| 499 | AC_SUBST(TCL_EXP_FILE) |
|---|
| 500 | AC_SUBST(DL_LIBS) |
|---|
| 501 | AC_SUBST(TCL_LIB_VERSIONS_OK) |
|---|
| 502 | AC_SUBST(TCL_PACKAGE_PATH) |
|---|
| 503 | |
|---|
| 504 | # win only |
|---|
| 505 | AC_SUBST(TCL_DDE_VERSION) |
|---|
| 506 | AC_SUBST(TCL_DDE_MAJOR_VERSION) |
|---|
| 507 | AC_SUBST(TCL_DDE_MINOR_VERSION) |
|---|
| 508 | AC_SUBST(TCL_DDE_PATCH_LEVEL) |
|---|
| 509 | AC_SUBST(TCL_REG_VERSION) |
|---|
| 510 | AC_SUBST(TCL_REG_MAJOR_VERSION) |
|---|
| 511 | AC_SUBST(TCL_REG_MINOR_VERSION) |
|---|
| 512 | AC_SUBST(TCL_REG_PATCH_LEVEL) |
|---|
| 513 | |
|---|
| 514 | AC_SUBST(RC) |
|---|
| 515 | AC_SUBST(RC_OUT) |
|---|
| 516 | AC_SUBST(RC_TYPE) |
|---|
| 517 | AC_SUBST(RC_INCLUDE) |
|---|
| 518 | AC_SUBST(RC_DEFINE) |
|---|
| 519 | AC_SUBST(RC_DEFINES) |
|---|
| 520 | AC_SUBST(RES) |
|---|
| 521 | |
|---|
| 522 | AC_OUTPUT(Makefile tclConfig.sh tcl.hpj) |
|---|