summaryrefslogtreecommitdiff
path: root/lang/tcl-itcl-current/patches/patch-af
diff options
context:
space:
mode:
authordmcmahill <dmcmahill@pkgsrc.org>2005-04-05 01:42:46 +0000
committerdmcmahill <dmcmahill@pkgsrc.org>2005-04-05 01:42:46 +0000
commita0dfd2e4fb2bd31bd17024dfe3160099c2f30ba2 (patch)
treeb56195a3da21c8fca61a41f8b8d02623109e90f3 /lang/tcl-itcl-current/patches/patch-af
parenta118a9f747b0e4972de866267de081dfecb074ce (diff)
downloadpkgsrc-a0dfd2e4fb2bd31bd17024dfe3160099c2f30ba2.tar.gz
Pull in various tcl.m4 patches from the lang/tcl package. In particular
this makes the shared lib naming match what tcl uses with regards to dots or no dots. This includes fixes for older a.out netbsd systems and several other OS's as well.
Diffstat (limited to 'lang/tcl-itcl-current/patches/patch-af')
-rw-r--r--lang/tcl-itcl-current/patches/patch-af143
1 files changed, 143 insertions, 0 deletions
diff --git a/lang/tcl-itcl-current/patches/patch-af b/lang/tcl-itcl-current/patches/patch-af
new file mode 100644
index 00000000000..a9c96f1d9ff
--- /dev/null
+++ b/lang/tcl-itcl-current/patches/patch-af
@@ -0,0 +1,143 @@
+$NetBSD: patch-af,v 1.1 2005/04/05 01:42:46 dmcmahill Exp $
+
+--- tclconfig/tcl.m4.orig 2004-09-08 01:23:52.000000000 +0000
++++ tclconfig/tcl.m4
+@@ -796,6 +796,7 @@ AC_DEFUN(TEA_CONFIG_CFLAGS, [
+ # (and we have no CC_SEARCH_FLAGS).
+
+ do64bit_ok=no
++ TCL_LIB_SPEC_RPATH=""
+ LDFLAGS_ORIG="$LDFLAGS"
+ TCL_EXPORT_FILE_SUFFIX=""
+ UNSHARED_LIB_SUFFIX=""
+@@ -1152,6 +1153,21 @@ dnl AC_CHECK_TOOL(AR, ar, :)
+ fi
+ LD_LIBRARY_PATH_VAR="SHLIB_PATH"
+ ;;
++ Interix-3.*)
++ SHLIB_CFLAGS=""
++ SHLIB_LD='${TCL_CC} -shared'
++ SHLIB_LD_LIBS=""
++ SHLIB_SUFFIX=".so"
++ DL_OBJS="tclLoadDl.o"
++ DL_LIBS="-ldl"
++ LDFLAGS="$LDFLAGS -Wl,-E"
++ CC_SEARCH_FLAGS='-Wl,-R${LIB_RUNTIME_DIR}'
++ LD_SEARCH_FLAGS='-Wl,-R${LIB_RUNTIME_DIR}'
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so',
++ UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
++ TCL_LIB_SPEC_RPATH="-Wl,-R${exec_prefix}/lib"
++ TCL_LIB_VERSIONS_OK=nodots
++ ;;
+ IRIX-4.*)
+ SHLIB_CFLAGS="-G 0"
+ SHLIB_SUFFIX=".a"
+@@ -1171,6 +1187,9 @@ dnl AC_CHECK_TOOL(AR, ar, :)
+ DL_OBJS="tclLoadDl.o"
+ DL_LIBS=""
+ LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
++ UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++ TCL_LIB_VERSIONS_OK=nodots
+ ;;
+ IRIX-6.*|IRIX64-6.5*)
+ SHLIB_CFLAGS=""
+@@ -1195,6 +1214,9 @@ dnl AC_CHECK_TOOL(AR, ar, :)
+ esac
+ LDFLAGS="$LDFLAGS -n32"
+ fi
++ UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++ TCL_LIB_VERSIONS_OK=nodots
+ ;;
+ IRIX64-6.*)
+ SHLIB_CFLAGS=""
+@@ -1217,6 +1239,9 @@ dnl AC_CHECK_TOOL(AR, ar, :)
+ LDFLAGS="$LDFLAGS -64"
+ fi
+ fi
++ UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++ TCL_LIB_VERSIONS_OK=nodots
+ ;;
+ Linux*)
+ SHLIB_CFLAGS="-fPIC"
+@@ -1258,6 +1283,9 @@ dnl AC_CHECK_TOOL(AR, ar, :)
+ CFLAGS="$CFLAGS -fno-inline"
+ fi
+
++ UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++ TCL_LIB_VERSIONS_OK=nodots
+ ;;
+ GNU*)
+ SHLIB_CFLAGS="-fPIC"
+@@ -1301,27 +1329,34 @@ dnl AC_CHECK_TOOL(AR, ar, :)
+ LD_SEARCH_FLAGS=""
+ ;;
+ NetBSD-*|FreeBSD-[[1-2]].*)
++ if test "X${COMPILER_OPTIMIZATION_BUG}" = "XYES"; then
++ CFLAGS_OPTIMIZE=-O0
++ fi
+ # Not available on all versions: check for include file.
+ AC_CHECK_HEADER(dlfcn.h, [
+ # NetBSD/SPARC needs -fPIC, -fpic will not do.
+ SHLIB_CFLAGS="-fPIC"
+- SHLIB_LD="ld -Bshareable -x"
+ SHLIB_LD_LIBS=""
+ SHLIB_SUFFIX=".so"
+ DL_OBJS="tclLoadDl.o"
+ DL_LIBS=""
+- LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+ AC_MSG_CHECKING([for ELF])
+ AC_EGREP_CPP(yes, [
+ #ifdef __ELF__
+ yes
+ #endif
+- ],
++ ], [
+ AC_MSG_RESULT([yes])
+- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so',
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++ SHLIB_LD='${TCL_CC} -shared -Wl,-x'
++ LD_SEARCH_FLAGS='-Wl,-R${LIB_RUNTIME_DIR}'
++ ], [
+ AC_MSG_RESULT([no])
+- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
+- )
++ SHLIB_LD="ld -Bshareable -x"
++ LD_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
++ TCL_LIB_SPEC_RPATH="-R${exec_prefix}/lib"
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.0.0'
++ ])
+ ], [
+ SHLIB_CFLAGS=""
+ SHLIB_LD="echo tclLdAout $CC \{$SHLIB_CFLAGS\} | `pwd`/tclsh -r"
+@@ -1605,6 +1640,9 @@ dnl AC_CHECK_TOOL(AR, ar, :)
+ SHLIB_LD="/usr/ccs/bin/ld -G -z text"
+ LD_SEARCH_FLAGS='-R ${LIB_RUNTIME_DIR}'
+ fi
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++ UNSHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.a'
++ TCL_LIB_VERSIONS_OK=nodots
+ ;;
+ ULTRIX-4.*)
+ SHLIB_CFLAGS="-G 0"
+@@ -2982,7 +3020,7 @@ AC_DEFUN(TEA_MAKE_LIB, [
+ MAKE_STUB_LIB="\${STLIB_LD} -out:\[$]@ \$(PKG_STUB_OBJECTS)"
+ else
+ MAKE_STATIC_LIB="\${STLIB_LD} \[$]@ \$(PKG_OBJECTS)"
+- MAKE_SHARED_LIB="\${SHLIB_LD} -o \[$]@ \$(PKG_OBJECTS) \${SHLIB_LD_FLAGS} \${SHLIB_LD_LIBS}"
++ MAKE_SHARED_LIB="\${SHLIB_LD} -o \${@:C/\.so.*/.la/} \${PKG_OBJECTS:.o=.lo} \${SHLIB_LDFLAGS} \${SHLIB_LD_LIBS} -version-info 0:0"
+ MAKE_STUB_LIB="\${STLIB_LD} \[$]@ \$(PKG_STUB_OBJECTS)"
+ fi
+
+@@ -3154,7 +3192,7 @@ AC_DEFUN(TEA_PRIVATE_TCL_HEADERS, [
+
+ TCL_INCLUDES="-I${TCL_GENERIC_DIR_NATIVE} -I${TCL_PLATFORM_DIR_NATIVE}"
+ else
+- TCL_TOP_DIR_NATIVE='$(TCL_SRC_DIR)'
++ TCL_TOP_DIR_NATIVE='$(TCL_HEADER_DIR)'
+ TCL_GENERIC_DIR_NATIVE='${TCL_TOP_DIR_NATIVE}/generic'
+ TCL_UNIX_DIR_NATIVE='${TCL_TOP_DIR_NATIVE}/unix'
+ TCL_WIN_DIR_NATIVE='${TCL_TOP_DIR_NATIVE}/win'