From 51e78b95916a045956c21b2dbf15f62094af102f Mon Sep 17 00:00:00 2001 From: mdejong Date: Thu, 3 Apr 2003 22:12:49 +0000 Subject: * unix/Makefile.in: Don't subst MATH_LIBS, LIBS, and DL_LIBS separately. Instead, just subst TCL_LIBS since it includes the others. * unix/configure: Regen. * unix/tcl.m4 (SC_CONFIG_CFLAGS, SC_TCL_LINK_LIBS): Set and subst TCL_LIBS in SC_CONFIG_CFLAGS instead of SC_TCL_LINK_LIBS. Don't subst MATH_LIBS since it is now covered by TCL_LIBS. * unix/tclConfig.sh.in: Use TCL_LIBS instead of DL_LIBS, LIBS, and MATH_LIBS. * unix/dltest/Makefile.in: Ditto. --- ChangeLog | 14 ++++++++++++++ unix/Makefile.in | 6 ++---- unix/configure | 18 ++++++++---------- unix/dltest/Makefile.in | 4 ++-- unix/tcl.m4 | 26 +++++++++++--------------- unix/tclConfig.sh.in | 4 ++-- 6 files changed, 39 insertions(+), 33 deletions(-) diff --git a/ChangeLog b/ChangeLog index d8ab4d7..7c6f359 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,17 @@ +2003-04-03 Mo DeJong + + * unix/Makefile.in: Don't subst MATH_LIBS, + LIBS, and DL_LIBS separately. Instead, just + subst TCL_LIBS since it includes the others. + * unix/configure: Regen. + * unix/tcl.m4 (SC_CONFIG_CFLAGS, SC_TCL_LINK_LIBS): + Set and subst TCL_LIBS in SC_CONFIG_CFLAGS instead + of SC_TCL_LINK_LIBS. Don't subst MATH_LIBS + since it is now covered by TCL_LIBS. + * unix/tclConfig.sh.in: Use TCL_LIBS instead + of DL_LIBS, LIBS, and MATH_LIBS. + * unix/dltest/Makefile.in: Ditto. + 2003-04-03 Don Porter * generic/tclCompCmds.c (TclCompileReturnCmd): Now that [return] diff --git a/unix/Makefile.in b/unix/Makefile.in index f78fb22..d995944 100644 --- a/unix/Makefile.in +++ b/unix/Makefile.in @@ -5,7 +5,7 @@ # "autoconf" program (constructs like "@foo@" will get replaced in the # actual Makefile. # -# RCS: @(#) $Id: Makefile.in,v 1.121 2003/01/28 11:03:52 mdejong Exp $ +# RCS: @(#) $Id: Makefile.in,v 1.122 2003/04/03 22:12:53 mdejong Exp $ VERSION = @TCL_VERSION@ MAJOR_VERSION = @TCL_MAJOR_VERSION@ @@ -107,8 +107,6 @@ PROTO_FLAGS = # following pairs of lines: MATH_FLAGS = #MATH_FLAGS = -DTCL_NO_MATH -MATH_LIBS = @MATH_LIBS@ -#MATH_LIBS = # If you use the setenv, putenv, or unsetenv procedures to modify # environment variables in your application and you'd like those @@ -288,7 +286,7 @@ STUB_CC_SWITCHES = ${CFLAGS} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \ ${AC_FLAGS} ${MATH_FLAGS} ${GENERIC_FLAGS} ${PROTO_FLAGS} ${MEM_DEBUG_FLAGS} \ ${COMPILE_DEBUG_FLAGS} ${ENV_FLAGS} -DTCL_SHLIB_EXT=\"${SHLIB_SUFFIX}\" -LIBS = @DL_LIBS@ @LIBS@ $(MATH_LIBS) +LIBS = @TCL_LIBS@ DEPEND_SWITCHES = ${CFLAGS} -I${GENERIC_DIR} -I${SRC_DIR} \ ${AC_FLAGS} ${MATH_FLAGS} \ diff --git a/unix/configure b/unix/configure index 291d50a..ac4a6a3 100755 --- a/unix/configure +++ b/unix/configure @@ -308,7 +308,7 @@ ac_includes_default="\ # include #endif" -ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS MKLINKS_FLAGS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP TCL_THREADS LIBOBJS TCL_LIBS MATH_LIBS RANLIB ac_ct_RANLIB AR DL_LIBS DL_OBJS PLAT_OBJS CFLAGS_DEBUG CFLAGS_OPTIMIZE CFLAGS_WARNING EXTRA_CFLAGS LDFLAGS_DEBUG LDFLAGS_OPTIMIZE CC_SEARCH_FLAGS LD_SEARCH_FLAGS STLIB_LD SHLIB_LD TCL_SHLIB_LD_EXTRAS TK_SHLIB_LD_EXTRAS SHLIB_LD_FLAGS SHLIB_LD_LIBS SHLIB_CFLAGS SHLIB_SUFFIX MAKE_LIB MAKE_STUB_LIB INSTALL_LIB INSTALL_STUB_LIB CFLAGS_DEFAULT LDFLAGS_DEFAULT TCL_VERSION TCL_MAJOR_VERSION TCL_MINOR_VERSION TCL_PATCH_LEVEL TCL_LIB_FILE TCL_LIB_FLAG TCL_LIB_SPEC TCL_STUB_LIB_FILE TCL_STUB_LIB_FLAG TCL_STUB_LIB_SPEC TCL_STUB_LIB_PATH TCL_INCLUDE_SPEC TCL_BUILD_STUB_LIB_SPEC TCL_BUILD_STUB_LIB_PATH TCL_SRC_DIR TCL_DBGX CFG_TCL_SHARED_LIB_SUFFIX CFG_TCL_UNSHARED_LIB_SUFFIX CFG_TCL_EXPORT_FILE_SUFFIX TCL_SHARED_BUILD LD_LIBRARY_PATH_VAR TCL_BUILD_LIB_SPEC TCL_NEEDS_EXP_FILE TCL_BUILD_EXP_FILE TCL_EXP_FILE TCL_LIB_VERSIONS_OK TCL_SHARED_LIB_SUFFIX TCL_UNSHARED_LIB_SUFFIX TCL_HAS_LONGLONG BUILD_DLTEST TCL_PACKAGE_PATH LTLIBOBJS' +ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS MKLINKS_FLAGS CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP TCL_THREADS LIBOBJS RANLIB ac_ct_RANLIB AR TCL_LIBS DL_LIBS DL_OBJS PLAT_OBJS CFLAGS_DEBUG CFLAGS_OPTIMIZE CFLAGS_WARNING EXTRA_CFLAGS LDFLAGS_DEBUG LDFLAGS_OPTIMIZE CC_SEARCH_FLAGS LD_SEARCH_FLAGS STLIB_LD SHLIB_LD TCL_SHLIB_LD_EXTRAS TK_SHLIB_LD_EXTRAS SHLIB_LD_FLAGS SHLIB_LD_LIBS SHLIB_CFLAGS SHLIB_SUFFIX MAKE_LIB MAKE_STUB_LIB INSTALL_LIB INSTALL_STUB_LIB CFLAGS_DEFAULT LDFLAGS_DEFAULT TCL_VERSION TCL_MAJOR_VERSION TCL_MINOR_VERSION TCL_PATCH_LEVEL TCL_LIB_FILE TCL_LIB_FLAG TCL_LIB_SPEC TCL_STUB_LIB_FILE TCL_STUB_LIB_FLAG TCL_STUB_LIB_SPEC TCL_STUB_LIB_PATH TCL_INCLUDE_SPEC TCL_BUILD_STUB_LIB_SPEC TCL_BUILD_STUB_LIB_PATH TCL_SRC_DIR TCL_DBGX CFG_TCL_SHARED_LIB_SUFFIX CFG_TCL_UNSHARED_LIB_SUFFIX CFG_TCL_EXPORT_FILE_SUFFIX TCL_SHARED_BUILD LD_LIBRARY_PATH_VAR TCL_BUILD_LIB_SPEC TCL_NEEDS_EXP_FILE TCL_BUILD_EXP_FILE TCL_EXP_FILE TCL_LIB_VERSIONS_OK TCL_SHARED_LIB_SUFFIX TCL_UNSHARED_LIB_SUFFIX TCL_HAS_LONGLONG BUILD_DLTEST TCL_PACKAGE_PATH LTLIBOBJS' ac_subst_files='' # Initialize some variables set by options. @@ -10353,13 +10353,6 @@ fi fi - # Don't perform the eval of the libraries here because DL_LIBS - # won't be set until we call SC_CONFIG_CFLAGS - - TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}' - - - # Add the threads support libraries @@ -12459,8 +12452,14 @@ fi; INSTALL_STUB_LIB='$(INSTALL_LIBRARY) $(STUB_LIB_FILE) $(LIB_INSTALL_DIR)/$(STUB_LIB_FILE) ; (cd $(LIB_INSTALL_DIR) ; $(RANLIB) $(STUB_LIB_FILE))' fi + # Define TCL_LIBS now that we know what DL_LIBS is. + TCL_LIBS="${DL_LIBS} ${LIBS} ${MATH_LIBS}" + # FIXME: This subst was left in only because the TCL_DL_LIBS + # entry in tclConfig.sh uses it. It is not clear why someone + # would use TCL_DL_LIBS instead of TCL_LIBS. + @@ -13721,11 +13720,10 @@ s,@CPP@,$CPP,;t t s,@EGREP@,$EGREP,;t t s,@TCL_THREADS@,$TCL_THREADS,;t t s,@LIBOBJS@,$LIBOBJS,;t t -s,@TCL_LIBS@,$TCL_LIBS,;t t -s,@MATH_LIBS@,$MATH_LIBS,;t t s,@RANLIB@,$RANLIB,;t t s,@ac_ct_RANLIB@,$ac_ct_RANLIB,;t t s,@AR@,$AR,;t t +s,@TCL_LIBS@,$TCL_LIBS,;t t s,@DL_LIBS@,$DL_LIBS,;t t s,@DL_OBJS@,$DL_OBJS,;t t s,@PLAT_OBJS@,$PLAT_OBJS,;t t diff --git a/unix/dltest/Makefile.in b/unix/dltest/Makefile.in index f9dd775..bd30298 100644 --- a/unix/dltest/Makefile.in +++ b/unix/dltest/Makefile.in @@ -1,11 +1,11 @@ # This Makefile is used to create several test cases for Tcl's load # command. It also illustrates how to take advantage of configuration # exported by Tcl to set up Makefiles for shared libraries. -# RCS: @(#) $Id: Makefile.in,v 1.11 2002/07/16 22:44:43 mdejong Exp $ +# RCS: @(#) $Id: Makefile.in,v 1.12 2003/04/03 22:13:00 mdejong Exp $ TCL_DBGX = @TCL_DBGX@ CC = @CC@ -LIBS = @TCL_BUILD_STUB_LIB_SPEC@ @DL_LIBS@ @LIBS@ @MATH_LIBS@ +LIBS = @TCL_BUILD_STUB_LIB_SPEC@ @TCL_LIBS@ AC_FLAGS = @EXTRA_CFLAGS@ SHLIB_CFLAGS = @SHLIB_CFLAGS@ SHLIB_LD = @SHLIB_LD@ diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 10f9a06..448562a 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -705,6 +705,9 @@ AC_DEFUN(SC_CONFIG_MANPAGES, [ # The name of the built export / import file which # should be used to link to the Tcl shared library. # Empty if Tcl is unshared. +# TCL_LIBS - +# Libs to use when linking Tcl shell or some other +# shell that includes Tcl libs. # CFLAGS_DEBUG - # Flags used when running the compiler in debug mode # CFLAGS_OPTIMIZE - @@ -1739,7 +1742,13 @@ dnl esac INSTALL_STUB_LIB='$(INSTALL_LIBRARY) $(STUB_LIB_FILE) $(LIB_INSTALL_DIR)/$(STUB_LIB_FILE) ; (cd $(LIB_INSTALL_DIR) ; $(RANLIB) $(STUB_LIB_FILE))' fi + # Define TCL_LIBS now that we know what DL_LIBS is. + TCL_LIBS="${DL_LIBS} ${LIBS} ${MATH_LIBS}" + AC_SUBST(TCL_LIBS) + # FIXME: This subst was left in only because the TCL_DL_LIBS + # entry in tclConfig.sh uses it. It is not clear why someone + # would use TCL_DL_LIBS instead of TCL_LIBS. AC_SUBST(DL_LIBS) AC_SUBST(DL_OBJS) @@ -2274,19 +2283,13 @@ AC_DEFUN(SC_BUGGY_STRTOD, [ # -lnsl) are dealt with here. # # Arguments: -# Requires the following vars to be set in the Makefile: -# DL_LIBS -# LIBS -# MATH_LIBS +# None. # # Results: # -# Subst's the following var: -# TCL_LIBS -# MATH_LIBS -# # Might append to the following vars: # LIBS +# MATH_LIBS # # Might define the following vars: # HAVE_NET_ERRNO_H @@ -2343,13 +2346,6 @@ AC_DEFUN(SC_TCL_LINK_LIBS, [ fi AC_CHECK_FUNC(gethostbyname, , [AC_CHECK_LIB(nsl, gethostbyname, [LIBS="$LIBS -lnsl"])]) - - # Don't perform the eval of the libraries here because DL_LIBS - # won't be set until we call SC_CONFIG_CFLAGS - - TCL_LIBS='${DL_LIBS} ${LIBS} ${MATH_LIBS}' - AC_SUBST(TCL_LIBS) - AC_SUBST(MATH_LIBS) ]) #-------------------------------------------------------------------- diff --git a/unix/tclConfig.sh.in b/unix/tclConfig.sh.in index 2ff0af5..2d74fd3 100644 --- a/unix/tclConfig.sh.in +++ b/unix/tclConfig.sh.in @@ -9,7 +9,7 @@ # # The information in this file is specific to a single platform. # -# RCS: @(#) $Id: tclConfig.sh.in,v 1.17 2002/07/28 03:15:11 mdejong Exp $ +# RCS: @(#) $Id: tclConfig.sh.in,v 1.18 2003/04/03 22:13:00 mdejong Exp $ # Tcl's version number. TCL_VERSION='@TCL_VERSION@' @@ -51,7 +51,7 @@ TCL_NEEDS_EXP_FILE=@TCL_NEEDS_EXP_FILE@ TCL_EXPORT_FILE_SUFFIX='@CFG_TCL_EXPORT_FILE_SUFFIX@' # Additional libraries to use when linking Tcl. -TCL_LIBS='@DL_LIBS@ @LIBS@ @MATH_LIBS@' +TCL_LIBS='@TCL_LIBS@' # Top-level directory in which Tcl's platform-independent files are # installed. -- cgit v0.12