diff options
author | das <das> | 2002-09-10 09:57:42 (GMT) |
---|---|---|
committer | das <das> | 2002-09-10 09:57:42 (GMT) |
commit | da6130923a43f8b2a4d9bfb93e79b0960130525a (patch) | |
tree | 2f855788a07a1ff928ef9d837440d47d934a62bf | |
parent | 4aef9a98da255c332b47645bdebb221d2c1b6bba (diff) | |
download | tcl-da6130923a43f8b2a4d9bfb93e79b0960130525a.zip tcl-da6130923a43f8b2a4d9bfb93e79b0960130525a.tar.gz tcl-da6130923a43f8b2a4d9bfb93e79b0960130525a.tar.bz2 |
* unix/Makefile.in: added DYLIB_INSTALL_DIR variable for macosx
and set it to default value ${LIB_RUNTIME_DIR}
* unix/tcl.m4 (Darwin): use DYLIB_INSTALL_DIR instead of
LIB_RUNTIME_DIR in the -install_name argument to ld.
* unix/configure: regen.
* macosx/Tcl.pbproj/project.pbxproj:
* macosx/Makefile: added support for building Tcl as an embedded
framework, i.e. using an dyld install_name containing
@executable_path/../Frameworks via the new DYLIB_INSTALL_DIR
unix/Makefile variable.
-rw-r--r-- | ChangeLog | 14 | ||||
-rw-r--r-- | macosx/Makefile | 20 | ||||
-rw-r--r-- | macosx/Tcl.pbproj/project.pbxproj | 10 | ||||
-rw-r--r-- | unix/Makefile.in | 10 | ||||
-rwxr-xr-x | unix/configure | 4 | ||||
-rw-r--r-- | unix/tcl.m4 | 4 |
6 files changed, 48 insertions, 14 deletions
@@ -1,3 +1,17 @@ +2002-09-10 Daniel Steffen <das@users.sourceforge.net> + + * unix/Makefile.in: added DYLIB_INSTALL_DIR variable for macosx + and set it to default value ${LIB_RUNTIME_DIR} + * unix/tcl.m4 (Darwin): use DYLIB_INSTALL_DIR instead of + LIB_RUNTIME_DIR in the -install_name argument to ld. + * unix/configure: regen. + + * macosx/Tcl.pbproj/project.pbxproj: + * macosx/Makefile: added support for building Tcl as an embedded + framework, i.e. using an dyld install_name containing + @executable_path/../Frameworks via the new DYLIB_INSTALL_DIR + unix/Makefile variable. + 2002-09-10 Jeff Hobbs <jeffh@ActiveState.com> *** 8.4.0 TAGGED FOR RELEASE *** diff --git a/macosx/Makefile b/macosx/Makefile index 050f482..529e2f5 100644 --- a/macosx/Makefile +++ b/macosx/Makefile @@ -3,7 +3,7 @@ # Simple makefile for building on Mac OS X with the # Project Builder command line tool 'pbxbuild' # -# RCS: @(#) $Id: Makefile,v 1.2 2002/08/31 06:09:45 das Exp $ +# RCS: @(#) $Id: Makefile,v 1.3 2002/09/10 09:57:44 das Exp $ # ################################################################################ @@ -25,12 +25,18 @@ DEPBUILD = ${BUILD} -buildstyle "${DEPBUILDSTYLE}" INSTALLOPTS = INSTALL_ROOT="${INSTALL_ROOT}" +EMBEDDEDOPTS = DYLIB_INSTALL_PATH="@executable_path/../Frameworks" + ################################################################################ all: develop deploy install: install-develop install-deploy +embedded: embedded-develop embedded-deploy + +install-embedded: install-embedded-develop install-embedded-deploy + clean: clean-develop clean-deploy ################################################################################ @@ -47,6 +53,18 @@ install-develop: install-deploy: ${DEPBUILD} install ${INSTALLOPTS} +embedded-develop: + ${DEVBUILD} ${EMBEDDEDOPTS} + +embedded-deploy: + ${DEPBUILD} ${EMBEDDEDOPTS} + +install-embedded-develop: + ${DEVBUILD} install ${INSTALLOPTS} ${EMBEDDEDOPTS} + +install-embedded-deploy: + ${DEPBUILD} install ${INSTALLOPTS} ${EMBEDDEDOPTS} + clean-develop: ${DEVBUILD} clean diff --git a/macosx/Tcl.pbproj/project.pbxproj b/macosx/Tcl.pbproj/project.pbxproj index cabab8c..27b00de 100644 --- a/macosx/Tcl.pbproj/project.pbxproj +++ b/macosx/Tcl.pbproj/project.pbxproj @@ -113,11 +113,15 @@ shouldUseHeadermap = 0; }; 00E2F84C016E8B780ACA28DC = { - buildArgumentsString = "-c \"if [ \\\"${ACTION}\\\" != \\\"clean\\\" ]; then make tclsh tcltest TCL_LIBRARY=\\\"@TCL_IN_FRAMEWORK@\\\" ${EXTRA_MAKE_FLAGS} TCL_PACKAGE_PATH=\\\"~/Library/Tcl /Library/Tcl /Network/Library/Tcl /System/Library/Tcl\\\"; else make clean; fi\""; + buildArgumentsString = "-c \"if [ \\\"${ACTION}\\\" != \\\"clean\\\" ]; then gnumake tclsh tcltest TCL_LIBRARY=\\\"@TCL_IN_FRAMEWORK@\\\" TCL_PACKAGE_PATH=\\\"~/Library/Tcl /Library/Tcl /Network/Library/Tcl /System/Library/Tcl\\\" DYLIB_INSTALL_DIR=\\\"${DYLIB_INSTALL_DIR}\\\" ${EXTRA_MAKE_FLAGS}; else gnumake clean; fi\""; buildPhases = ( ); buildSettings = { + DYLIB_INSTALL_DIR = "${DYLIB_INSTALL_PATH}/${PRODUCT_NAME}.framework/Versions/${FRAMEWORK_VERSION}"; + DYLIB_INSTALL_PATH = "${INSTALL_PATH}"; EXTRA_MAKE_FLAGS = ""; + FRAMEWORK_VERSION = 8.4; + INSTALL_PATH = /Library/Frameworks; PRODUCT_NAME = Tcl; }; buildToolPath = /bin/sh; @@ -461,7 +465,7 @@ MacOS X Port by Jim Ingham <jingham@apple.com> & Ian Reid, Copyright  ); runOnlyForDeploymentPostprocessing = 1; shellPath = /bin/sh; - shellScript = "# redo prebinding\nif [ ! -d \"${INSTALL_ROOT}/usr/lib\" ]; then ln -fs /usr/lib \"${INSTALL_ROOT}/usr/\"; RM_USRLIB=1; fi\nif [ ! -d \"${INSTALL_ROOT}/System\" ]; then ln -fs /System \"${INSTALL_ROOT}/\"; RM_SYSTEM=1; fi\nredo_prebinding -r \"${INSTALL_ROOT}\" \"${INSTALL_ROOT}/usr/bin/tclsh${FRAMEWORK_VERSION}\"\nif [ -n \"${RM_USRLIB:-}\" ]; then rm -f \"${INSTALL_ROOT}/usr/lib\"; fi\nif [ -n \"${RM_SYSTEM:-}\" ]; then rm -r ${INSTALL_ROOT}/System; fi"; + shellScript = "if [ `echo \"${DYLIB_INSTALL_PATH:-}\" | grep -c \"@executable_path\"` -gt 0 ]; then\n# if we are embedding frameworks, don't install tclsh\nrm -f \"${INSTALL_ROOT}/usr/bin/tclsh${FRAMEWORK_VERSION}\"\nrmdir -p \"${INSTALL_ROOT}/usr/bin\"\necho \"tclsh removed\"\nelse\n# redo prebinding\ncd \"${INSTALL_ROOT}\"\nif [ ! -d usr/lib ]; then mkdir -p usr; ln -fs /usr/lib usr/; RM_USRLIB=1; fi\nif [ ! -d System ]; then ln -fs /System .; RM_SYSTEM=1; fi\nredo_prebinding -r . \"./usr/bin/tclsh${FRAMEWORK_VERSION}\"\nif [ -n \"${RM_USRLIB:-}\" ]; then rm -f usr/lib; rmdir -p usr; fi\nif [ -n \"${RM_SYSTEM:-}\" ]; then rm -f System; fi\nfi"; }; F59AE5E3017AC67A01DC9062 = { buildActionMask = 8; @@ -474,7 +478,7 @@ MacOS X Port by Jim Ingham <jingham@apple.com> & Ian Reid, Copyright  ); runOnlyForDeploymentPostprocessing = 1; shellPath = /bin/sh; - shellScript = "# build html documentation\nif [ \"${BUILD_STYLE}\" = \"Deployment\" ]; then\n cd \"${TEMP_DIR}/..\"\n make html DISTDIR=\"${INSTALL_ROOT}${LIBDIR}/Resources/English.lproj/Documentation/Reference\"\n cd \"${INSTALL_ROOT}${LIBDIR}/Resources/English.lproj/Documentation/Reference\"\n ln -fs contents.htm html/index.html\n rm -f \"${PRODUCT_NAME}\"; ln -fs html \"${PRODUCT_NAME}\"\nfi"; + shellScript = "# build html documentation\nif [ \"${BUILD_STYLE}\" = \"Deployment\" ]; then\n cd \"${TEMP_DIR}/..\"\n gnumake html DISTDIR=\"${INSTALL_ROOT}${LIBDIR}/Resources/English.lproj/Documentation/Reference\"\n cd \"${INSTALL_ROOT}${LIBDIR}/Resources/English.lproj/Documentation/Reference\"\n ln -fs contents.htm html/index.html\n rm -f \"${PRODUCT_NAME}\"; ln -fs html \"${PRODUCT_NAME}\"\nfi"; }; F5A1836F018242A501DC9062 = { isa = PBXFileReference; diff --git a/unix/Makefile.in b/unix/Makefile.in index a8dc25b..5b5ea2f 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.115 2002/08/31 06:09:46 das Exp $ +# RCS: @(#) $Id: Makefile.in,v 1.116 2002/09/10 09:57:42 das Exp $ VERSION = @TCL_VERSION@ MAJOR_VERSION = @TCL_MAJOR_VERSION@ @@ -228,6 +228,9 @@ TCL_LIB_FLAG = @TCL_LIB_FLAG@ TCL_EXP_FILE = @TCL_EXP_FILE@ TCL_BUILD_EXP_FILE = @TCL_BUILD_EXP_FILE@ +# support for embedded libraries on Darwin / Mac OS X +DYLIB_INSTALL_DIR = ${LIB_RUNTIME_DIR} + #---------------------------------------------------------------- # The information below is modified by the configure script when # Makefile is generated from Makefile.in. You shouldn't normally @@ -479,11 +482,6 @@ tclsh: ${TCLSH_OBJS} ${TCL_LIB_FILE} # burned into its ld search path. This keeps tcltest from # picking up an already installed version of the Tcl library. -# Resetting the LIB_RUNTIME_DIR below is required so that -# the generated tcltest executable gets the build directory -# burned into its ld search path. This keeps tcltest from -# picking up an already installed version of the Tcl library. - tcltest: ${TCLTEST_OBJS} ${TCL_LIB_FILE} ${BUILD_DLTEST} $(MAKE) tcltest-real LIB_RUNTIME_DIR=`pwd` diff --git a/unix/configure b/unix/configure index cea947e..f005092 100755 --- a/unix/configure +++ b/unix/configure @@ -6253,8 +6253,8 @@ fi Rhapsody-*|Darwin-*) SHLIB_CFLAGS="-fno-common" SHLIB_LD="cc -dynamiclib \${LDFLAGS}" - TCL_SHLIB_LD_EXTRAS="-compatibility_version ${TCL_VERSION} -current_version \${VERSION} -install_name \${LIB_RUNTIME_DIR}/\${TCL_LIB_FILE} -prebind -seg1addr 0xa000000" - TK_SHLIB_LD_EXTRAS="-compatibility_version ${TK_VERSION} -current_version \${VERSION} -install_name \${LIB_RUNTIME_DIR}/\${TK_LIB_FILE} -prebind -seg1addr 0xb000000" + TCL_SHLIB_LD_EXTRAS="-compatibility_version ${TCL_VERSION} -current_version \${VERSION} -install_name \${DYLIB_INSTALL_DIR}/\${TCL_LIB_FILE} -prebind -seg1addr 0xa000000" + TK_SHLIB_LD_EXTRAS="-compatibility_version ${TK_VERSION} -current_version \${VERSION} -install_name \${DYLIB_INSTALL_DIR}/\${TK_LIB_FILE} -prebind -seg1addr 0xb000000" SHLIB_LD_LIBS='${LIBS}' SHLIB_SUFFIX=".dylib" DL_OBJS="tclLoadDyld.o" diff --git a/unix/tcl.m4 b/unix/tcl.m4 index 454fd6c..31f43a9 100644 --- a/unix/tcl.m4 +++ b/unix/tcl.m4 @@ -1236,8 +1236,8 @@ dnl AC_CHECK_TOOL(AR, ar, :) Rhapsody-*|Darwin-*) SHLIB_CFLAGS="-fno-common" SHLIB_LD="cc -dynamiclib \${LDFLAGS}" - TCL_SHLIB_LD_EXTRAS="-compatibility_version ${TCL_VERSION} -current_version \${VERSION} -install_name \${LIB_RUNTIME_DIR}/\${TCL_LIB_FILE} -prebind -seg1addr 0xa000000" - TK_SHLIB_LD_EXTRAS="-compatibility_version ${TK_VERSION} -current_version \${VERSION} -install_name \${LIB_RUNTIME_DIR}/\${TK_LIB_FILE} -prebind -seg1addr 0xb000000" + TCL_SHLIB_LD_EXTRAS="-compatibility_version ${TCL_VERSION} -current_version \${VERSION} -install_name \${DYLIB_INSTALL_DIR}/\${TCL_LIB_FILE} -prebind -seg1addr 0xa000000" + TK_SHLIB_LD_EXTRAS="-compatibility_version ${TK_VERSION} -current_version \${VERSION} -install_name \${DYLIB_INSTALL_DIR}/\${TK_LIB_FILE} -prebind -seg1addr 0xb000000" SHLIB_LD_LIBS='${LIBS}' SHLIB_SUFFIX=".dylib" DL_OBJS="tclLoadDyld.o" |