1dnl This file is an input file used by the GNU "autoconf" program to 2dnl generate the file "configure", which is run during Tcl installation 3dnl to configure the system for the local environment. 4AC_INIT(../generic/tcl.h) 5# SCCS: @(#) configure.in 1.133 97/01/22 08:49:02 6 7TCL_VERSION=8.0 8TCL_MAJOR_VERSION=8 9TCL_MINOR_VERSION=0 10TCL_PATCH_LEVEL=a2 11VERSION=${TCL_VERSION} 12 13if test "${prefix}" = "NONE"; then 14 prefix=/usr/local 15fi 16if test "${exec_prefix}" = "NONE"; then 17 exec_prefix=$prefix 18fi 19TCL_SRC_DIR=`cd $srcdir/..; pwd` 20 21AC_PROG_RANLIB 22AC_ARG_ENABLE(gcc, [ --enable-gcc allow use of gcc if available], 23 [tcl_ok=$enableval], [tcl_ok=no]) 24if test "$tcl_ok" = "yes"; then 25 AC_PROG_CC 26else 27 CC=${CC-cc} 28AC_SUBST(CC) 29fi 30AC_C_CROSS 31 32#-------------------------------------------------------------------- 33# Supply substitutes for missing POSIX library procedures, or 34# set flags so Tcl uses alternate procedures. 35#-------------------------------------------------------------------- 36 37AC_REPLACE_FUNCS(getcwd opendir strstr) 38AC_REPLACE_FUNCS(strtol tmpnam waitpid) 39AC_CHECK_FUNC(strerror, , AC_DEFINE(NO_STRERROR)) 40AC_CHECK_FUNC(getwd, , AC_DEFINE(NO_GETWD)) 41AC_CHECK_FUNC(wait3, , AC_DEFINE(NO_WAIT3)) 42AC_CHECK_FUNC(uname, , AC_DEFINE(NO_UNAME)) 43 44#-------------------------------------------------------------------- 45# On a few very rare systems, all of the libm.a stuff is 46# already in libc.a. Set compiler flags accordingly. 47# Also, Linux requires the "ieee" library for math to work 48# right (and it must appear before "-lm"). 49#-------------------------------------------------------------------- 50 51AC_CHECK_FUNC(sin, MATH_LIBS="", MATH_LIBS="-lm") 52AC_CHECK_LIB(ieee, main, [MATH_LIBS="-lieee $MATH_LIBS"]) 53 54#-------------------------------------------------------------------- 55# On AIX systems, libbsd.a has to be linked in to support 56# non-blocking file IO. This library has to be linked in after 57# the MATH_LIBS or it breaks the pow() function. The way to 58# insure proper sequencing, is to add it to the tail of MATH_LIBS. 59# This library also supplies gettimeofday. 60#-------------------------------------------------------------------- 61libbsd=no 62if test "`uname -s`" = "AIX" ; then 63 AC_CHECK_LIB(bsd, gettimeofday, libbsd=yes) 64 if test $libbsd = yes; then 65 MATH_LIBS="$MATH_LIBS -lbsd" 66 fi 67fi 68 69#-------------------------------------------------------------------- 70# Supply substitutes for missing POSIX header files. Special 71# notes: 72# - stdlib.h doesn't define strtol, strtoul, or 73# strtod insome versions of SunOS 74# - some versions of string.h don't declare procedures such 75# as strstr 76#-------------------------------------------------------------------- 77 78AC_MSG_CHECKING(dirent.h) 79AC_TRY_LINK([#include <sys/types.h> 80#include <dirent.h>], [ 81#ifndef _POSIX_SOURCE 82# ifdef __Lynx__ 83 /* 84 * Generate compilation error to make the test fail: Lynx headers 85 * are only valid if really in the POSIX environment. 86 */ 87 88 missing_procedure(); 89# endif 90#endif 91DIR *d; 92struct dirent *entryPtr; 93char *p; 94d = opendir("foobar"); 95entryPtr = readdir(d); 96p = entryPtr->d_name; 97closedir(d); 98], tcl_ok=yes, tcl_ok=no) 99if test $tcl_ok = no; then 100 AC_DEFINE(NO_DIRENT_H) 101fi 102AC_MSG_RESULT($tcl_ok) 103AC_CHECK_HEADER(errno.h, , AC_DEFINE(NO_ERRNO_H)) 104AC_CHECK_HEADER(float.h, , AC_DEFINE(NO_FLOAT_H)) 105AC_CHECK_HEADER(limits.h, , AC_DEFINE(NO_LIMITS_H)) 106AC_CHECK_HEADER(stdlib.h, tcl_ok=1, tcl_ok=0) 107AC_EGREP_HEADER(strtol, stdlib.h, , tcl_ok=0) 108AC_EGREP_HEADER(strtoul, stdlib.h, , tcl_ok=0) 109AC_EGREP_HEADER(strtod, stdlib.h, , tcl_ok=0) 110if test $tcl_ok = 0; then 111 AC_DEFINE(NO_STDLIB_H) 112fi 113AC_CHECK_HEADER(string.h, tcl_ok=1, tcl_ok=0) 114AC_EGREP_HEADER(strstr, string.h, , tcl_ok=0) 115AC_EGREP_HEADER(strerror, string.h, , tcl_ok=0) 116if test $tcl_ok = 0; then 117 AC_DEFINE(NO_STRING_H) 118fi 119AC_CHECK_HEADER(sys/wait.h, , AC_DEFINE(NO_SYS_WAIT_H)) 120AC_CHECK_HEADER(dlfcn.h, , AC_DEFINE(NO_DLFCN_H)) 121AC_HAVE_HEADERS(unistd.h) 122 123#--------------------------------------------------------------------------- 124# Determine which interface to use to talk to the serial port. 125# Note that #include lines must begin in leftmost column for 126# some compilers to recognize them as preprocessor directives. 127#--------------------------------------------------------------------------- 128 129AC_MSG_CHECKING([termios vs. termio vs. sgtty]) 130AC_TRY_RUN([ 131#include <termios.h> 132 133main() 134{ 135 struct termios t; 136 if (tcgetattr(0, &t) == 0) { 137 cfsetospeed(&t, 0); 138 t.c_cflag |= PARENB | PARODD | CSIZE | CSTOPB; 139 return 0; 140 } 141 return 1; 142}], tk_ok=termios, tk_ok=no, tk_ok=no) 143if test $tk_ok = termios; then 144 AC_DEFINE(USE_TERMIOS) 145else 146AC_TRY_RUN([ 147#include <termio.h> 148 149main() 150{ 151 struct termio t; 152 if (ioctl(0, TCGETA, &t) == 0) { 153 t.c_cflag |= CBAUD | PARENB | PARODD | CSIZE | CSTOPB; 154 return 0; 155 } 156 return 1; 157}], tk_ok=termio, tk_ok=no, tk_ok=no) 158if test $tk_ok = termio; then 159 AC_DEFINE(USE_TERMIO) 160else 161AC_TRY_RUN([ 162#include <sgtty.h> 163 164main() 165{ 166 struct sgttyb t; 167 if (ioctl(0, TIOCGETP, &t) == 0) { 168 t.sg_ospeed = 0; 169 t.sg_flags |= ODDP | EVENP | RAW; 170 return 0; 171 } 172 return 1; 173}], tk_ok=sgtty, tk_ok=none, tk_ok=none) 174if test $tk_ok = sgtty; then 175 AC_DEFINE(USE_SGTTY) 176fi 177fi 178fi 179AC_MSG_RESULT($tk_ok) 180 181#-------------------------------------------------------------------- 182# Include sys/select.h if it exists and if it supplies things 183# that appear to be useful and aren't already in sys/types.h. 184# This appears to be true only on the RS/6000 under AIX. Some 185# systems like OSF/1 have a sys/select.h that's of no use, and 186# other systems like SCO UNIX have a sys/select.h that's 187# pernicious. If "fd_set" isn't defined anywhere then set a 188# special flag. 189#-------------------------------------------------------------------- 190 191AC_MSG_CHECKING([fd_set and sys/select]) 192AC_TRY_COMPILE([#include <sys/types.h>], 193 [fd_set readMask, writeMask;], tk_ok=yes, tk_ok=no) 194if test $tk_ok = no; then 195 AC_HEADER_EGREP(fd_mask, sys/select.h, tk_ok=yes) 196 if test $tk_ok = yes; then 197 AC_DEFINE(HAVE_SYS_SELECT_H) 198 fi 199fi 200AC_MSG_RESULT($tk_ok) 201if test $tk_ok = no; then 202 AC_DEFINE(NO_FD_SET) 203fi 204 205#------------------------------------------------------------------------------ 206# Find out all about time handling differences. 207#------------------------------------------------------------------------------ 208 209AC_CHECK_HEADERS(sys/time.h) 210AC_HEADER_TIME 211AC_STRUCT_TIMEZONE 212 213AC_MSG_CHECKING([tm_tzadj in struct tm]) 214AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_tzadj;], 215 [AC_DEFINE(HAVE_TM_TZADJ) 216 AC_MSG_RESULT(yes)], 217 AC_MSG_RESULT(no)) 218 219AC_MSG_CHECKING([tm_gmtoff in struct tm]) 220AC_TRY_COMPILE([#include <time.h>], [struct tm tm; tm.tm_gmtoff;], 221 [AC_DEFINE(HAVE_TM_GMTOFF) 222 AC_MSG_RESULT(yes)], 223 AC_MSG_RESULT(no)) 224 225# 226# Its important to include time.h in this check, as some systems (like convex) 227# have timezone functions, etc. 228# 229have_timezone=no 230AC_MSG_CHECKING([long timezone variable]) 231AC_TRY_COMPILE([#include <time.h>], 232 [extern long timezone; 233 timezone += 1; 234 exit (0);], 235 [have_timezone=yes 236 AC_DEFINE(HAVE_TIMEZONE_VAR) 237 AC_MSG_RESULT(yes)], 238 AC_MSG_RESULT(no)) 239 240# 241# On some systems (eg IRIX 6.2), timezone is a time_t and not a long. 242# 243if test "$have_timezone" = no; then 244 AC_MSG_CHECKING([time_t timezone variable]) 245 AC_TRY_COMPILE([#include <time.h>], 246 [extern time_t timezone; 247 timezone += 1; 248 exit (0);], 249 [AC_DEFINE(HAVE_TIMEZONE_VAR) 250 AC_MSG_RESULT(yes)], 251 AC_MSG_RESULT(no)) 252fi 253 254# 255# AIX does not have a timezone field in struct tm. When the AIX bsd 256# library is used, the timezone global and the gettimeofday methods are 257# to be avoided for timezone deduction instead, we deduce the timezone 258# by comparing the localtime result on a known GMT value. 259# 260if test $libbsd = yes; then 261 AC_DEFINE(USE_DELTA_FOR_TZ) 262fi 263 264#-------------------------------------------------------------------- 265# On some systems strstr is broken: it returns a pointer even 266# even if the original string is empty. 267#-------------------------------------------------------------------- 268 269AC_MSG_CHECKING([proper strstr implementation]) 270AC_TRY_RUN([ 271extern int strstr(); 272int main() 273{ 274 exit(strstr("\0test", "test") ? 1 : 0); 275} 276], tcl_ok=yes, tcl_ok=no, tcl_ok=no) 277if test $tcl_ok = yes; then 278 AC_MSG_RESULT(yes) 279else 280 AC_MSG_RESULT([broken, using substitute]) 281 LIBOBJS="$LIBOBJS strstr.o" 282fi 283 284#-------------------------------------------------------------------- 285# Check for strtoul function. This is tricky because under some 286# versions of AIX strtoul returns an incorrect terminator 287# pointer for the string "0". 288#-------------------------------------------------------------------- 289 290AC_CHECK_FUNC(strtoul, tcl_ok=1, tcl_ok=0) 291AC_TRY_RUN([ 292extern int strtoul(); 293int main() 294{ 295 char *string = "0"; 296 char *term; 297 int value; 298 value = strtoul(string, &term, 0); 299 if ((value != 0) || (term != (string+1))) { 300 exit(1); 301 } 302 exit(0); 303}], , tcl_ok=0, tcl_ok=0) 304if test "$tcl_ok" = 0; then 305 test -n "$verbose" && echo " Adding strtoul.o." 306 LIBOBJS="$LIBOBJS strtoul.o" 307fi 308 309#-------------------------------------------------------------------- 310# Check for the strtod function. This is tricky because in some 311# versions of Linux strtod mis-parses strings starting with "+". 312#-------------------------------------------------------------------- 313 314AC_CHECK_FUNC(strtod, tcl_ok=1, tcl_ok=0) 315AC_TRY_RUN([ 316extern double strtod(); 317int main() 318{ 319 char *string = " +69"; 320 char *term; 321 double value; 322 value = strtod(string, &term); 323 if ((value != 69) || (term != (string+4))) { 324 exit(1); 325 } 326 exit(0); 327}], , tcl_ok=0, tcl_ok=0) 328if test "$tcl_ok" = 0; then 329 test -n "$verbose" && echo " Adding strtod.o." 330 LIBOBJS="$LIBOBJS strtod.o" 331fi 332 333#-------------------------------------------------------------------- 334# Under Solaris 2.4, strtod returns the wrong value for the 335# terminating character under some conditions. Check for this 336# and if the problem exists use a substitute procedure 337# "fixstrtod" that corrects the error. 338#-------------------------------------------------------------------- 339 340AC_CHECK_FUNC(strtod, tcl_strtod=1, tcl_strtod=0) 341if test "$tcl_strtod" = 1; then 342 AC_MSG_CHECKING([for Solaris strtod bug]) 343 AC_TRY_RUN([ 344extern double strtod(); 345int main() 346{ 347 char *string = "NaN"; 348 char *term; 349 strtod(string, &term); 350 if ((term != string) && (term[-1] == 0)) { 351 exit(1); 352 } 353 exit(0); 354}], tcl_ok=1, tcl_ok=0, tcl_ok=0) 355 if test $tcl_ok = 1; then 356 AC_MSG_RESULT(ok) 357 else 358 AC_MSG_RESULT(buggy) 359 LIBOBJS="$LIBOBJS fixstrtod.o" 360 AC_DEFINE(strtod, fixstrtod) 361 fi 362fi 363 364#-------------------------------------------------------------------- 365# Check for various typedefs and provide substitutes if 366# they don't exist. 367#-------------------------------------------------------------------- 368 369AC_TYPE_MODE_T 370AC_TYPE_PID_T 371AC_TYPE_SIZE_T 372AC_TYPE_UID_T 373AC_C_BIGENDIAN 374 375#-------------------------------------------------------------------- 376# If a system doesn't have an opendir function (man, that's old!) 377# then we have to supply a different version of dirent.h which 378# is compatible with the substitute version of opendir that's 379# provided. This version only works with V7-style directories. 380#-------------------------------------------------------------------- 381 382AC_CHECK_FUNC(opendir, , AC_DEFINE(USE_DIRENT2_H)) 383 384#-------------------------------------------------------------------- 385# The check below checks whether <sys/wait.h> defines the type 386# "union wait" correctly. It's needed because of weirdness in 387# HP-UX where "union wait" is defined in both the BSD and SYS-V 388# environments. Checking the usability of WIFEXITED seems to do 389# the trick. 390#-------------------------------------------------------------------- 391 392AC_MSG_CHECKING([union wait]) 393AC_TRY_LINK([#include <sys/types.h> 394#include <sys/wait.h>], [ 395union wait x; 396WIFEXITED(x); /* Generates compiler error if WIFEXITED 397 * uses an int. */ 398], tcl_ok=yes, tcl_ok=no) 399AC_MSG_RESULT($tcl_ok) 400if test $tcl_ok = no; then 401 AC_DEFINE(NO_UNION_WAIT) 402fi 403 404#-------------------------------------------------------------------- 405# Check to see whether the system supports the matherr function 406# and its associated type "struct exception". 407#-------------------------------------------------------------------- 408 409AC_MSG_CHECKING([matherr support]) 410AC_TRY_COMPILE([#include <math.h>], [ 411struct exception x; 412x.type = DOMAIN; 413x.type = SING; 414], tcl_ok=yes, tcl_ok=no) 415AC_MSG_RESULT($tcl_ok) 416if test $tcl_ok = yes; then 417 AC_DEFINE(NEED_MATHERR) 418fi 419 420#-------------------------------------------------------------------- 421# Check to see whether the system provides a vfork kernel call. 422# If not, then use fork instead. Also, check for a problem with 423# vforks and signals that can cause core dumps if a vforked child 424# resets a signal handler. If the problem exists, then use fork 425# instead of vfork. 426#-------------------------------------------------------------------- 427 428AC_CHECK_FUNC(vfork, tcl_ok=1, tcl_ok=0) 429if test "$tcl_ok" = 1; then 430 AC_MSG_CHECKING([vfork/signal bug]); 431 AC_TRY_RUN([ 432#include <stdio.h> 433#include <signal.h> 434#include <sys/wait.h> 435int gotSignal = 0; 436sigProc(sig) 437 int sig; 438{ 439 gotSignal = 1; 440} 441main() 442{ 443 int pid, sts; 444 (void) signal(SIGCHLD, sigProc); 445 pid = vfork(); 446 if (pid < 0) { 447 exit(1); 448 } else if (pid == 0) { 449 (void) signal(SIGCHLD, SIG_DFL); 450 _exit(0); 451 } else { 452 (void) wait(&sts); 453 } 454 exit((gotSignal) ? 0 : 1); 455}], tcl_ok=1, tcl_ok=0, tcl_ok=0) 456 if test "$tcl_ok" = 1; then 457 AC_MSG_RESULT(ok) 458 else 459 AC_MSG_RESULT([buggy, using fork instead]) 460 fi 461fi 462rm -f core 463if test "$tcl_ok" = 0; then 464 AC_DEFINE(vfork, fork) 465fi 466 467#-------------------------------------------------------------------- 468# Check whether there is an strncasecmp function on this system. 469# This is a bit tricky because under SCO it's in -lsocket and 470# under Sequent Dynix it's in -linet. 471#-------------------------------------------------------------------- 472 473AC_CHECK_FUNC(strncasecmp, tcl_ok=1, tcl_ok=0) 474if test "$tcl_ok" = 0; then 475 AC_CHECK_LIB(socket, strncasecmp, tcl_ok=1, tcl_ok=0) 476fi 477if test "$tcl_ok" = 0; then 478 AC_CHECK_LIB(inet, strncasecmp, tcl_ok=1, tcl_ok=0) 479fi 480if test "$tcl_ok" = 0; then 481 LIBOBJS="$LIBOBJS strncasecmp.o" 482fi 483 484#-------------------------------------------------------------------- 485# The code below deals with several issues related to gettimeofday: 486# 1. Some systems don't provide a gettimeofday function at all 487# (set NO_GETTOD if this is the case). 488# 2. SGI systems don't use the BSD form of the gettimeofday function, 489# but they have a BSDgettimeofday function that can be used instead. 490# 3. See if gettimeofday is declared in the <sys/time.h> header file. 491# if not, set the GETTOD_NOT_DECLARED flag so that tclPort.h can 492# declare it. 493#-------------------------------------------------------------------- 494 495AC_CHECK_FUNC(BSDgettimeofday, AC_DEFINE(HAVE_BSDGETTIMEOFDAY), 496 AC_CHECK_FUNC(gettimeofday, , AC_DEFINE(NO_GETTOD))) 497AC_MSG_CHECKING([for gettimeofday declaration]) 498AC_EGREP_HEADER(gettimeofday, sys/time.h, AC_MSG_RESULT(present), [ 499 AC_MSG_RESULT(missing) 500 AC_DEFINE(GETTOD_NOT_DECLARED) 501]) 502 503#-------------------------------------------------------------------- 504# Interactive UNIX requires -linet instead of -lsocket, plus it 505# needs net/errno.h to define the socket-related error codes. 506#-------------------------------------------------------------------- 507 508AC_CHECK_LIB(inet, main, [LIBS="$LIBS -linet"]) 509AC_CHECK_HEADER(net/errno.h, AC_DEFINE(HAVE_NET_ERRNO_H)) 510 511#-------------------------------------------------------------------- 512# The following code checks to see whether it is possible to get 513# signed chars on this platform. This is needed in order to 514# properly generate sign-extended ints from character values. 515#-------------------------------------------------------------------- 516 517AC_C_CHAR_UNSIGNED 518AC_MSG_CHECKING([signed char declarations]) 519AC_TRY_COMPILE(, [ 520signed char *p; 521p = 0; 522], tcl_ok=yes, tcl_ok=no) 523AC_MSG_RESULT($tcl_ok) 524if test $tcl_ok = yes; then 525 AC_DEFINE(HAVE_SIGNED_CHAR) 526fi 527 528#-------------------------------------------------------------------- 529# Check for the existence of the -lsocket and -lnsl libraries. 530# The order here is important, so that they end up in the right 531# order in the command line generated by make. Here are some 532# special considerations: 533# 1. Use "connect" and "accept" to check for -lsocket, and 534# "gethostbyname" to check for -lnsl. 535# 2. Use each function name only once: can't redo a check because 536# autoconf caches the results of the last check and won't redo it. 537# 3. Use -lnsl and -lsocket only if they supply procedures that 538# aren't already present in the normal libraries. This is because 539# IRIX 5.2 has libraries, but they aren't needed and they're 540# bogus: they goof up name resolution if used. 541# 4. On some SVR4 systems, can't use -lsocket without -lnsl too. 542# To get around this problem, check for both libraries together 543# if -lsocket doesn't work by itself. 544#-------------------------------------------------------------------- 545 546tcl_checkBoth=0 547AC_CHECK_FUNC(connect, tcl_checkSocket=0, tcl_checkSocket=1) 548if test "$tcl_checkSocket" = 1; then 549 AC_CHECK_LIB(socket, main, LIBS="$LIBS -lsocket", tcl_checkBoth=1) 550fi 551if test "$tcl_checkBoth" = 1; then 552 tk_oldLibs=$LIBS 553 LIBS="$LIBS -lsocket -lnsl" 554 AC_CHECK_FUNC(accept, tcl_checkNsl=0, [LIBS=$tk_oldLibs]) 555fi 556AC_CHECK_FUNC(gethostbyname, , AC_CHECK_LIB(nsl, main, [LIBS="$LIBS -lnsl"])) 557 558#-------------------------------------------------------------------- 559# The statements below define a collection of symbols related to 560# dynamic loading and shared libraries: 561# 562# DL_OBJS - Name of the object file that implements dynamic 563# loading for Tcl on this system. 564# DL_LIBS - Library file(s) to include in tclsh and other base 565# applications in order for the "load" command to work. 566# LD_FLAGS - Flags to pass to the compiler when linking object 567# files into an executable application binary such 568# as tclsh. 569# LD_SEARCH_FLAGS-Flags to pass to ld, such as "-R /usr/local/tcl/lib", 570# that tell the run-time dynamic linker where to look 571# for shared libraries such as libtcl.so. Depends on 572# the variable LIB_RUNTIME_DIR in the Makefile. 573# MAKE_LIB - Command to execute to build the Tcl library; 574# differs depending on whether or not Tcl is being 575# compiled as a shared library. 576# SHLIB_CFLAGS - Flags to pass to cc when compiling the components 577# of a shared library (may request position-independent 578# code, among other things). 579# SHLIB_LD - Base command to use for combining object files 580# into a shared library. 581# SHLIB_LD_LIBS - Dependent libraries for the linker to scan when 582# creating shared libraries. This symbol typically 583# goes at the end of the "ld" commands that build 584# shared libraries. The value of the symbol is 585# "${LIBS}" if all of the dependent libraries should 586# be specified when creating a shared library. If 587# dependent libraries should not be specified (as on 588# SunOS 4.x, where they cause the link to fail, or in 589# general if Tcl and Tk aren't themselves shared 590# libraries), then this symbol has an empty string 591# as its value. 592# SHLIB_SUFFIX - Suffix to use for the names of dynamically loadable 593# extensions. An empty string means we don't know how 594# to use shared libraries on this platform. 595# TCL_LIB_FILE - Name of the file that contains the Tcl library, such 596# as libtcl7.8.so or libtcl7.8.a. 597# TCL_LIB_SUFFIX -Specifies everything that comes after the "libtcl" 598# in the shared library name, using the $VERSION variable 599# to put the version in the right place. This is used 600# by platforms that need non-standard library names. 601# Examples: ${VERSION}.so.1.1 on NetBSD, since it needs 602# to have a version after the .so, and ${VERSION}.a 603# on AIX, since the Tcl shared library needs to have 604# a .a extension whereas shared objects for loadable 605# extensions have a .so extension. Defaults to 606# ${VERSION}${SHLIB_SUFFIX}. 607#-------------------------------------------------------------------- 608 609# Step 1: set the variable "system" to hold the name and version number 610# for the system. This can usually be done via the "uname" command, but 611# there are a few systems, like Next, where this doesn't work. 612 613AC_MSG_CHECKING([system version (for dynamic loading)]) 614if test -f /usr/lib/NextStep/software_version; then 615 system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` 616else 617 system=`uname -s`-`uname -r` 618 if test "$?" -ne 0 ; then 619 AC_MSG_RESULT([unknown (can't find uname command)]) 620 system=unknown 621 else 622 # Special check for weird MP-RAS system (uname returns weird 623 # results, and the version is kept in special file). 624 625 if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then 626 system=MP-RAS-`awk '{print $3}' /etc/.relid'` 627 fi 628 if test "`uname -s`" = "AIX" ; then 629 system=AIX-`uname -v`.`uname -r` 630 fi 631 AC_MSG_RESULT($system) 632 fi 633fi 634 635# Step 2: check for existence of -ldl library. This is needed because 636# Linux can use either -ldl or -ldld for dynamic loading. 637 638AC_CHECK_LIB(dl, dlopen, have_dl=yes, have_dl=no) 639 640# Step 3: set configuration options based on system name and version. 641 642fullSrcDir=`cd $srcdir; pwd` 643AIX=no 644TCL_SHARED_LIB_SUFFIX="" 645TCL_UNSHARED_LIB_SUFFIX="" 646TCL_LIB_VERSIONS_OK=ok 647case $system in 648 AIX-*) 649 SHLIB_CFLAGS="" 650 SHLIB_LD="$fullSrcDir/ldAix /bin/ld -bhalt:4 -bM:SRE -bE:lib.exp -H512 -T512" 651 SHLIB_LD_LIBS='${LIBS}' 652 SHLIB_SUFFIX=".so" 653 DL_OBJS="tclLoadDl.o tclLoadAix.o" 654 DL_LIBS="-lld" 655 LD_FLAGS="" 656 LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 657 AIX=yes 658 TCL_SHARED_LIB_SUFFIX='${VERSION}.a' 659 ;; 660 BSD/OS-2.1*|BSD/OS-3*) 661 SHLIB_CFLAGS="" 662 SHLIB_LD="ld -r" 663 SHLIB_LD_FLAGS="" 664 SHLIB_SUFFIX=".so" 665 DL_OBJS="tclLoadDl.o" 666 DL_LIBS="-ldl" 667 LD_FLAGS="" 668 LD_SEARCH_FLAGS="" 669 ;; 670 HP-UX-*.08.*|HP-UX-*.09.*|HP-UX-*.10.*) 671 AC_CHECK_LIB(dld, shl_load, tcl_ok=yes, tcl_ok=no) 672 if test "$tcl_ok" = yes; then 673 SHLIB_CFLAGS="+z" 674 SHLIB_LD="ld -b" 675 SHLIB_LD_LIBS="" 676 SHLIB_SUFFIX=".sl" 677 DL_OBJS="tclLoadShl.o" 678 DL_LIBS="-ldld" 679 LD_FLAGS="-Wl,-E" 680 LD_SEARCH_FLAGS='-Wl,+b,${LIB_RUNTIME_DIR}:.' 681 fi 682 ;; 683 IRIX-4.*) 684 SHLIB_CFLAGS="-G 0" 685 SHLIB_SUFFIX="..o" 686 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" 687 SHLIB_LD_LIBS='${LIBS}' 688 DL_OBJS="tclLoadAout.o" 689 DL_LIBS="" 690 LD_FLAGS="-Wl,-D,08000000" 691 LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 692 TCL_SHARED_LIB_SUFFIX='${VERSION}.a' 693 ;; 694 IRIX-5.*|IRIX-6.*) 695 SHLIB_CFLAGS="" 696 SHLIB_LD="ld -shared -rdata_shared" 697 SHLIB_LD_LIBS="" 698 SHLIB_SUFFIX=".so" 699 DL_OBJS="tclLoadDl.o" 700 DL_LIBS="" 701 LD_FLAGS="" 702 LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 703 ;; 704 IRIX64-6.*) 705 SHLIB_CFLAGS="" 706 SHLIB_LD="ld -32 -shared -rdata_shared -rpath /usr/local/lib" 707 SHLIB_LD_LIBS="" 708 SHLIB_SUFFIX=".so" 709 DL_OBJS="tclLoadDl.o" 710 DL_LIBS="" 711 LD_FLAGS="" 712 LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 713 ;; 714 Linux*) 715 SHLIB_CFLAGS="-fPIC" 716 SHLIB_LD_LIBS="" 717 SHLIB_SUFFIX=".so" 718 if test "$have_dl" = yes; then 719 SHLIB_LD="${CC} -shared" 720 DL_OBJS="tclLoadDl.o" 721 DL_LIBS="-ldl" 722 LD_FLAGS="-rdynamic" 723 LD_SEARCH_FLAGS="" 724 else 725 AC_CHECK_HEADER(dld.h, [ 726 SHLIB_LD="ld -shared" 727 DL_OBJS="tclLoadDld.o" 728 DL_LIBS="-ldld" 729 LD_FLAGS="" 730 LD_SEARCH_FLAGS=""]) 731 fi 732 ;; 733 MP-RAS-02*) 734 SHLIB_CFLAGS="-K PIC" 735 SHLIB_LD="cc -G" 736 SHLIB_LD_LIBS="" 737 SHLIB_SUFFIX=".so" 738 DL_OBJS="tclLoadDl.o" 739 DL_LIBS="-ldl" 740 LD_FLAGS="" 741 LD_SEARCH_FLAGS="" 742 ;; 743 MP-RAS-*) 744 SHLIB_CFLAGS="-K PIC" 745 SHLIB_LD="cc -G" 746 SHLIB_LD_LIBS="" 747 SHLIB_SUFFIX=".so" 748 DL_OBJS="tclLoadDl.o" 749 DL_LIBS="-ldl" 750 LD_FLAGS="-Wl,-Bexport" 751 LD_SEARCH_FLAGS="" 752 ;; 753 NetBSD-*|FreeBSD-*|OpenBSD-*) 754 # Not available on all versions: check for include file. 755 AC_CHECK_HEADER(dlfcn.h, [ 756 SHLIB_CFLAGS="-fpic" 757 SHLIB_LD="ld -Bshareable -x" 758 SHLIB_LD_LIBS="" 759 SHLIB_SUFFIX=".so" 760 DL_OBJS="tclLoadDl.o" 761 DL_LIBS="" 762 LD_FLAGS="" 763 LD_SEARCH_FLAGS="" 764 TCL_SHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.so.1.0' 765 ], [ 766 SHLIB_CFLAGS="" 767 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" 768 SHLIB_LD_LIBS='${LIBS}' 769 SHLIB_SUFFIX="..o" 770 DL_OBJS="tclLoadAout.o" 771 DL_LIBS="" 772 LD_FLAGS="" 773 LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 774 TCL_SHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.a' 775 ]) 776 777 # FreeBSD doesn't handle version numbers with dots. 778 779 TCL_UNSHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.a' 780 TCL_LIB_VERSIONS_OK=nodots 781 ;; 782 NEXTSTEP-*) 783 SHLIB_CFLAGS="" 784 SHLIB_LD="cc -nostdlib -r" 785 SHLIB_LD_LIBS="" 786 SHLIB_SUFFIX=".so" 787 DL_OBJS="tclLoadNext.o" 788 DL_LIBS="" 789 LD_FLAGS="" 790 LD_SEARCH_FLAGS="" 791 ;; 792 OSF1-1.0|OSF1-1.1|OSF1-1.2) 793 # OSF/1 1.[012] from OSF, and derivatives, including Paragon OSF/1 794 SHLIB_CFLAGS="" 795 # Hack: make package name same as library name 796 SHLIB_LD='ld -R -export $@:' 797 SHLIB_LD_LIBS="" 798 SHLIB_SUFFIX=".so" 799 DL_OBJS="tclLoadOSF.o" 800 DL_LIBS="" 801 LD_FLAGS="" 802 LD_SEARCH_FLAGS="" 803 ;; 804 OSF1-1.*) 805 # OSF/1 1.3 from OSF using ELF, and derivatives, including AD2 806 SHLIB_CFLAGS="-fpic" 807 SHLIB_LD="ld -shared" 808 SHLIB_LD_LIBS="" 809 SHLIB_SUFFIX=".so" 810 DL_OBJS="tclLoadDl.o" 811 DL_LIBS="" 812 LD_FLAGS="" 813 LD_SEARCH_FLAGS="" 814 ;; 815 OSF1-V*) 816 # Digital OSF/1 817 SHLIB_CFLAGS="" 818 SHLIB_LD='ld -shared -expect_unresolved "*"' 819 SHLIB_LD_LIBS="" 820 SHLIB_SUFFIX=".so" 821 DL_OBJS="tclLoadDl.o" 822 DL_LIBS="" 823 LD_FLAGS="" 824 LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}' 825 ;; 826 RISCos-*) 827 SHLIB_CFLAGS="-G 0" 828 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" 829 SHLIB_LD_LIBS='${LIBS}' 830 SHLIB_SUFFIX="..o" 831 DL_OBJS="tclLoadAout.o" 832 DL_LIBS="" 833 LD_FLAGS="-Wl,-D,08000000" 834 LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 835 TCL_SHARED_LIB_SUFFIX='${VERSION}.a' 836 ;; 837 SCO_SV-3.2*) 838 # Note, dlopen is available only on SCO 3.2.5 and greater. However, 839 # this test works, since "uname -s" was non-standard in 3.2.4 and 840 # below. 841 SHLIB_CFLAGS="-Kpic -belf" 842 SHLIB_LD="ld -G" 843 SHLIB_LD_LIBS="" 844 SHLIB_SUFFIX=".so" 845 DL_OBJS="tclLoadDl.o" 846 DL_LIBS="" 847 LD_FLAGS="-belf -Wl,-Bexport" 848 LD_SEARCH_FLAGS="" 849 ;; 850 SINIX*5.4*) 851 SHLIB_CFLAGS="-K PIC" 852 SHLIB_LD="cc -G" 853 SHLIB_LD_LIBS="" 854 SHLIB_SUFFIX=".so" 855 DL_OBJS="tclLoadDl.o" 856 DL_LIBS="-ldl" 857 LD_FLAGS="" 858 LD_SEARCH_FLAGS="" 859 ;; 860 SunOS-4*) 861 SHLIB_CFLAGS="-PIC" 862 SHLIB_LD="ld" 863 SHLIB_LD_LIBS="" 864 SHLIB_SUFFIX=".so" 865 DL_OBJS="tclLoadDl.o" 866 DL_LIBS="-ldl" 867 LD_FLAGS="" 868 LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 869 870 # SunOS can't handle version numbers with dots in them in library 871 # specs, like -ltcl7.5, so use -ltcl75 instead. Also, it 872 # requires an extra version number at the end of .so file names. 873 # So, the library has to have a name like libtcl75.so.1.0 874 875 TCL_SHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.so.1.0' 876 TCL_UNSHARED_LIB_SUFFIX='`echo ${VERSION} | tr -d .`.a' 877 TCL_LIB_VERSIONS_OK=nodots 878 ;; 879 SunOS-5*) 880 SHLIB_CFLAGS="-KPIC" 881 SHLIB_LD="/usr/ccs/bin/ld -G -z text" 882 SHLIB_LD_LIBS="" 883 SHLIB_SUFFIX=".so" 884 DL_OBJS="tclLoadDl.o" 885 DL_LIBS="-ldl" 886 LD_FLAGS="" 887 LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}' 888 ;; 889 ULTRIX-4.*) 890 SHLIB_CFLAGS="-G 0" 891 SHLIB_SUFFIX="..o" 892 SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r -G 0" 893 SHLIB_LD_LIBS='${LIBS}' 894 DL_OBJS="tclLoadAout.o" 895 DL_LIBS="" 896 LD_FLAGS="-Wl,-D,08000000" 897 LD_SEARCH_FLAGS='-L${LIB_RUNTIME_DIR}' 898 TCL_SHARED_LIB_SUFFIX='${VERSION}.a' 899 ;; 900 UNIX_SV*) 901 SHLIB_CFLAGS="-KPIC" 902 SHLIB_LD="cc -G" 903 SHLIB_LD_LIBS="" 904 SHLIB_SUFFIX=".so" 905 DL_OBJS="tclLoadDl.o" 906 DL_LIBS="-ldl" 907 # Some UNIX_SV* systems (unixware 1.1.2 for example) have linkers 908 # that don't grok the -Bexport option. Test that it does. 909 hold_ldflags=$LDFLAGS 910 AC_MSG_CHECKING(for ld accepts -Bexport flag) 911 LDFLAGS="${LDFLAGS} -Wl,-Bexport" 912 AC_TRY_LINK(, [int i;], found=yes, found=no) 913 LDFLAGS=$hold_ldflags 914 AC_MSG_RESULT($found) 915 if test $found = yes; then 916 LD_FLAGS="-Wl,-Bexport" 917 else 918 LD_FLAGS="" 919 fi 920 LD_SEARCH_FLAGS="" 921 ;; 922esac 923 924# Step 4: If pseudo-static linking is in use (see K. B. Kenny, "Dynamic 925# Loading for Tcl -- What Became of It?". Proc. 2nd Tcl/Tk Workshop, 926# New Orleans, LA, Computerized Processes Unlimited, 1994), then we need 927# to determine which of several header files defines the a.out file 928# format (a.out.h, sys/exec.h, or sys/exec_aout.h). At present, we 929# support only a file format that is more or less version-7-compatible. 930# In particular, 931# - a.out files must begin with `struct exec'. 932# - the N_TXTOFF on the `struct exec' must compute the seek address 933# of the text segment 934# - The `struct exec' must contain a_magic, a_text, a_data, a_bss 935# and a_entry fields. 936# The following compilation should succeed if and only if either sys/exec.h 937# or a.out.h is usable for the purpose. 938# 939# Note that the modified COFF format used on MIPS Ultrix 4.x is usable; the 940# `struct exec' includes a second header that contains information that 941# duplicates the v7 fields that are needed. 942 943if test "x$DL_OBJS" = "xtclLoadAout.o" ; then 944 AC_MSG_CHECKING(sys/exec.h) 945 AC_TRY_COMPILE([#include <sys/exec.h>],[ 946 struct exec foo; 947 unsigned long seek; 948 int flag; 949#if defined(__mips) || defined(mips) 950 seek = N_TXTOFF (foo.ex_f, foo.ex_o); 951#else 952 seek = N_TXTOFF (foo); 953#endif 954 flag = (foo.a_magic == OMAGIC); 955 return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; 956], tcl_ok=usable, tcl_ok=unusable) 957 AC_MSG_RESULT($tcl_ok) 958 if test $tcl_ok = usable; then 959 AC_DEFINE(USE_SYS_EXEC_H) 960 else 961 AC_MSG_CHECKING(a.out.h) 962 AC_TRY_COMPILE([#include <a.out.h>],[ 963 struct exec foo; 964 unsigned long seek; 965 int flag; 966#if defined(__mips) || defined(mips) 967 seek = N_TXTOFF (foo.ex_f, foo.ex_o); 968#else 969 seek = N_TXTOFF (foo); 970#endif 971 flag = (foo.a_magic == OMAGIC); 972 return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; 973 ], tcl_ok=usable, tcl_ok=unusable) 974 AC_MSG_RESULT($tcl_ok) 975 if test $tcl_ok = usable; then 976 AC_DEFINE(USE_A_OUT_H) 977 else 978 AC_MSG_CHECKING(sys/exec_aout.h) 979 AC_TRY_COMPILE([#include <sys/exec_aout.h>],[ 980 struct exec foo; 981 unsigned long seek; 982 int flag; 983#if defined(__mips) || defined(mips) 984 seek = N_TXTOFF (foo.ex_f, foo.ex_o); 985#else 986 seek = N_TXTOFF (foo); 987#endif 988 flag = (foo.a_midmag == OMAGIC); 989 return foo.a_text + foo.a_data + foo.a_bss + foo.a_entry; 990 ], tcl_ok=usable, tcl_ok=unusable) 991 AC_MSG_RESULT($tcl_ok) 992 if test $tcl_ok = usable; then 993 AC_DEFINE(USE_SYS_EXEC_AOUT_H) 994 else 995 DL_OBJS="" 996 fi 997 fi 998 fi 999fi 1000 1001# Step 5: disable dynamic loading if requested via a command-line switch. 1002 1003AC_ARG_ENABLE(load, [ --disable-load disallow dynamic loading and "load" command], 1004 [tcl_ok=$enableval], [tcl_ok=yes]) 1005if test "$tcl_ok" = "no"; then 1006 DL_OBJS="" 1007fi 1008 1009if test "x$DL_OBJS" != "x" ; then 1010 BUILD_DLTEST="\$(DLTEST_TARGETS)" 1011else 1012 echo "Can't figure out how to do dynamic loading or shared libraries" 1013 echo "on this system." 1014 SHLIB_CFLAGS="" 1015 SHLIB_LD="" 1016 SHLIB_SUFFIX="" 1017 DL_OBJS="tclLoadNone.o" 1018 DL_LIBS="" 1019 LD_FLAGS="" 1020 LD_SEARCH_FLAGS="" 1021 BUILD_DLTEST="" 1022fi 1023 1024# If we're running gcc, then change the C flags for compiling shared 1025# libraries to the right flags for gcc, instead of those for the 1026# standard manufacturer compiler. 1027 1028if test "$DL_OBJS" != "tclLoadNone.o" ; then 1029 if test "$CC" = "gcc" -o `$CC -v 2>&1 | grep -c gcc` != "0" ; then 1030 case $system in 1031 AIX-*) 1032 ;; 1033 BSD/OS*) 1034 ;; 1035 IRIX*) 1036 ;; 1037 NetBSD-*|FreeBSD-*|OpenBSD-*) 1038 ;; 1039 RISCos-*) 1040 ;; 1041 ULTRIX-4.*) 1042 ;; 1043 *) 1044 SHLIB_CFLAGS="-fPIC" 1045 ;; 1046 esac 1047 fi 1048fi 1049 1050#-------------------------------------------------------------------- 1051# The statements below check for systems where POSIX-style 1052# non-blocking I/O (O_NONBLOCK) doesn't work or is unimplemented. 1053# On these systems (mostly older ones), use the old BSD-style 1054# FIONBIO approach instead. 1055#-------------------------------------------------------------------- 1056 1057AC_CHECK_HEADERS(sys/ioctl.h) 1058AC_CHECK_HEADERS(sys/filio.h) 1059AC_MSG_CHECKING([FIONBIO vs. O_NONBLOCK for nonblocking I/O]) 1060if test -f /usr/lib/NextStep/software_version; then 1061 system=NEXTSTEP-`awk '/3/,/3/' /usr/lib/NextStep/software_version` 1062else 1063 system=`uname -s`-`uname -r` 1064 if test "$?" -ne 0 ; then 1065 system=unknown 1066 else 1067 # Special check for weird MP-RAS system (uname returns weird 1068 # results, and the version is kept in special file). 1069 1070 if test -r /etc/.relid -a "X`uname -n`" = "X`uname -s`" ; then 1071 system=MP-RAS-`awk '{print $3}' /etc/.relid'` 1072 fi 1073 if test "`uname -s`" = "AIX" ; then 1074 system=AIX-`uname -v`.`uname -r` 1075 fi 1076 fi 1077fi 1078case $system in 1079 AIX-*) 1080 AC_DEFINE(USE_FIONBIO) 1081 AC_MSG_RESULT(FIONBIO) 1082 ;; 1083 OSF*) 1084 AC_DEFINE(USE_FIONBIO) 1085 AC_MSG_RESULT(FIONBIO) 1086 ;; 1087 SunOS-4*) 1088 AC_DEFINE(USE_FIONBIO) 1089 AC_MSG_RESULT(FIONBIO) 1090 ;; 1091 ULTRIX-4.*) 1092 AC_DEFINE(USE_FIONBIO) 1093 AC_MSG_RESULT(FIONBIO) 1094 ;; 1095 *) 1096 AC_MSG_RESULT(O_NONBLOCK) 1097 ;; 1098esac 1099 1100#-------------------------------------------------------------------- 1101# The statements below define a collection of symbols related to 1102# building libtcl as a shared library instead of a static library. 1103#-------------------------------------------------------------------- 1104 1105realRanlib=$RANLIB 1106if test "$TCL_SHARED_LIB_SUFFIX" = "" ; then 1107 TCL_SHARED_LIB_SUFFIX='${VERSION}${SHLIB_SUFFIX}' 1108fi 1109if test "$TCL_UNSHARED_LIB_SUFFIX" = "" ; then 1110 TCL_UNSHARED_LIB_SUFFIX='${VERSION}.a' 1111fi 1112AC_ARG_ENABLE(shared, 1113 [ --enable-shared build libtcl as a shared library], 1114 [tcl_ok=$enableval], [tcl_ok=no]) 1115if test "$tcl_ok" = "yes" -a "${SHLIB_SUFFIX}" != "" \ 1116 -a "${DL_OBJS}" != "tclLoadAout.o" ; then 1117 TCL_SHLIB_CFLAGS="${SHLIB_CFLAGS}" 1118 TCL_LD_SEARCH_FLAGS="${LD_SEARCH_FLAGS}" 1119 eval "TCL_LIB_FILE=libtcl${TCL_SHARED_LIB_SUFFIX}" 1120 MAKE_LIB="\${SHLIB_LD} -o ${TCL_LIB_FILE} \${OBJS} ${SHLIB_LD_LIBS}" 1121 RANLIB=":" 1122else 1123 if test "$AIX" = "no" ; then 1124 SHLIB_LD_LIBS="" 1125 fi 1126 TCL_SHLIB_CFLAGS="" 1127 TCL_LD_SEARCH_FLAGS="" 1128 eval "TCL_LIB_FILE=libtcl${TCL_UNSHARED_LIB_SUFFIX}" 1129 MAKE_LIB="ar cr ${TCL_LIB_FILE} \${OBJS}" 1130fi 1131 1132# Note: in the following variable, it's important to use the absolute 1133# path name of the Tcl directory rather than "..": this is because 1134# AIX remembers this path and will attempt to use it at run-time to look 1135# up the Tcl library. 1136 1137if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then 1138 TCL_BUILD_LIB_SPEC="-L`pwd` -ltcl${VERSION}" 1139 TCL_LIB_SPEC="-L${exec_prefix}/lib -ltcl${VERSION}" 1140else 1141 TCL_BUILD_LIB_SPEC="-L`pwd` -ltcl`echo ${VERSION} | tr -d .`" 1142 TCL_LIB_SPEC="-L${exec_prefix}/lib -ltcl`echo ${VERSION} | tr -d .`" 1143fi 1144 1145#-------------------------------------------------------------------- 1146# The statements below define the symbol TCL_PACKAGE_PATH, which 1147# gives a list of directories that may contain packages. The list 1148# consists of one directory for machine-dependent binaries and 1149# another for platform-independent scripts. 1150#-------------------------------------------------------------------- 1151 1152if test "$prefix" != "$exec_prefix"; then 1153 TCL_PACKAGE_PATH="${exec_prefix}/lib ${prefix}/lib" 1154else 1155 TCL_PACKAGE_PATH="${prefix}/lib" 1156fi 1157 1158AC_SUBST(BUILD_DLTEST) 1159AC_SUBST(DL_LIBS) 1160AC_SUBST(DL_OBJS) 1161AC_SUBST(LD_FLAGS) 1162AC_SUBST(MAKE_LIB) 1163AC_SUBST(MATH_LIBS) 1164AC_SUBST(SHLIB_CFLAGS) 1165AC_SUBST(SHLIB_LD) 1166AC_SUBST(SHLIB_LD_LIBS) 1167AC_SUBST(SHLIB_SUFFIX) 1168AC_SUBST(TCL_BUILD_LIB_SPEC) 1169AC_SUBST(TCL_LD_SEARCH_FLAGS) 1170AC_SUBST(TCL_LIB_FILE) 1171AC_SUBST(TCL_LIB_SPEC) 1172AC_SUBST(TCL_LIB_VERSIONS_OK) 1173AC_SUBST(TCL_MAJOR_VERSION) 1174AC_SUBST(TCL_MINOR_VERSION) 1175AC_SUBST(TCL_PACKAGE_PATH) 1176AC_SUBST(TCL_PATCH_LEVEL) 1177AC_SUBST(TCL_SHARED_LIB_SUFFIX) 1178AC_SUBST(TCL_SHLIB_CFLAGS) 1179AC_SUBST(TCL_SRC_DIR) 1180AC_SUBST(TCL_UNSHARED_LIB_SUFFIX) 1181AC_SUBST(TCL_VERSION) 1182 1183AC_OUTPUT(Makefile tclConfig.sh) 1184