summaryrefslogtreecommitdiff
path: root/x11
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2001-05-24 02:58:29 +0000
committerjlam <jlam@pkgsrc.org>2001-05-24 02:58:29 +0000
commita3dca94481b4f4289cf1e29784946a3694778c99 (patch)
treee807b25bd304fbda8171eb77bdf58b5641c44fab /x11
parent18fc23567b080026a9fe0aed328c1e70025802b2 (diff)
downloadpkgsrc-a3dca94481b4f4289cf1e29784946a3694778c99.tar.gz
Fix the installed tkConfig.sh so it's possible to use its values to generate
a shared library that depends on libtk83.so. Patch the configure script to set TK_LIB_SPEC to include -Wl,-rpath,... or -R... depending on whether we are ELF or a.out. Bump version number to 8.3.2nb1.
Diffstat (limited to 'x11')
-rw-r--r--x11/tk/Makefile4
-rw-r--r--x11/tk/distinfo8
-rw-r--r--x11/tk/patches/patch-aa4
-rw-r--r--x11/tk/patches/patch-ab106
-rw-r--r--x11/tk/patches/patch-ac68
-rw-r--r--x11/tk/patches/patch-ad44
6 files changed, 206 insertions, 28 deletions
diff --git a/x11/tk/Makefile b/x11/tk/Makefile
index 3c3e5a5ee66..93785f98248 100644
--- a/x11/tk/Makefile
+++ b/x11/tk/Makefile
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.7 2001/02/25 04:18:28 hubertf Exp $
+# $NetBSD: Makefile,v 1.8 2001/05/24 02:58:29 jlam Exp $
DISTNAME= tk8.3.2
-PKGNAME= tk-8.3.2
+PKGNAME= tk-8.3.2nb1
CATEGORIES= x11
MASTER_SITES= ftp://ftp.scriptics.com/pub/tcl/tcl8_3/ \
ftp://ftp.informatik.uni-hamburg.de/pub/soft/lang/tcl/tcl8_3/
diff --git a/x11/tk/distinfo b/x11/tk/distinfo
index f78574d77be..cf72e67e89f 100644
--- a/x11/tk/distinfo
+++ b/x11/tk/distinfo
@@ -1,6 +1,8 @@
-$NetBSD: distinfo,v 1.2 2001/04/18 18:15:41 jwise Exp $
+$NetBSD: distinfo,v 1.3 2001/05/24 02:58:29 jlam Exp $
SHA1 (tk8.3.2.tar.gz) = a573d33fa76ca64a7148d3cc6b7b18906c311dab
Size (tk8.3.2.tar.gz) = 2529172 bytes
-SHA1 (patch-aa) = 647f6253cc821b0bbf69c4cc69e53dc4cbce1ec3
-SHA1 (patch-ab) = 79aa30a26172953653d651aa2b7fb31fca32bc79
+SHA1 (patch-aa) = 0867d35fdc70dff1585552f07202d9da244f24db
+SHA1 (patch-ab) = 57af1fc87d4d5a901ae2bd0fd57c8ce0c751989a
+SHA1 (patch-ac) = 222832f6f71f9914f01f51a21b1366ca08aae96a
+SHA1 (patch-ad) = ec0c859b9561e94c9cbf7d9b78920fe2f0004329
diff --git a/x11/tk/patches/patch-aa b/x11/tk/patches/patch-aa
index 8bac842bde7..e95456a2bca 100644
--- a/x11/tk/patches/patch-aa
+++ b/x11/tk/patches/patch-aa
@@ -1,4 +1,4 @@
-$NetBSD: patch-aa,v 1.3 2000/12/11 16:40:43 jlam Exp $
+$NetBSD: patch-aa,v 1.4 2001/05/24 02:58:29 jlam Exp $
--- Makefile.in.orig Tue Aug 8 15:19:31 2000
+++ Makefile.in
@@ -36,7 +36,7 @@ $NetBSD: patch-aa,v 1.3 2000/12/11 16:40:43 jlam Exp $
# The values of the symbolis normally set by the configure script.
-SHLIB_LD = @SHLIB_LD@
-+SHLIB_LD = ${LIBTOOL} --mode=link @CC@
++SHLIB_LD = ${LIBTOOL} --mode=link @CC@ -rpath ${PREFIX}/lib
SHLIB_LD_LIBS = @SHLIB_LD_LIBS@
# Additional search flags needed to find the various shared libraries
diff --git a/x11/tk/patches/patch-ab b/x11/tk/patches/patch-ab
index f1f73e7abad..a6cc15c16a7 100644
--- a/x11/tk/patches/patch-ab
+++ b/x11/tk/patches/patch-ab
@@ -1,45 +1,100 @@
-$NetBSD: patch-ab,v 1.5 2001/04/18 18:15:41 jwise Exp $
+$NetBSD: patch-ab,v 1.6 2001/05/24 02:58:30 jlam Exp $
---- configure.orig Tue Aug 8 19:19:32 2000
+--- configure.orig Tue Aug 8 15:19:32 2000
+++ configure
-@@ -1873,6 +1873,7 @@
- SHLIB_LD="ld -Bshareable -x"
+@@ -1581,6 +1581,7 @@
+
+ do64bit_ok=no
+ fullSrcDir=`cd $srcdir; pwd`
++ RPATH_FLAG=""
+ EXTRA_CFLAGS=""
+ TCL_EXPORT_FILE_SUFFIX=""
+ UNSHARED_LIB_SUFFIX=""
+@@ -1870,7 +1871,6 @@
+
+ # NetBSD/SPARC needs -fPIC, -fpic will not do.
+ SHLIB_CFLAGS="-fPIC"
+- SHLIB_LD="ld -Bshareable -x"
SHLIB_LD_LIBS=""
SHLIB_SUFFIX=".so"
-+ SHARED_LIB_SUFFIX=".so"
DL_OBJS="tclLoadDl.o"
- DL_LIBS=""
- LDFLAGS=""
-@@ -3338,7 +3339,7 @@
+@@ -1891,13 +1891,23 @@
+ if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ egrep "yes" >/dev/null 2>&1; then
+ rm -rf conftest*
+- echo "$ac_t""yes" 1>&6
++
++ echo "$ac_t""yes" 1>&6
++ SHLIB_LD='${TCL_CC} -shared -Wl,-x'
++ RPATH_FLAG='-Wl,-rpath,'
++ LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
+ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++
+ else
+ rm -rf conftest*
+- echo "$ac_t""no" 1>&6
++
++ echo "$ac_t""no" 1>&6
++ SHLIB_LD="ld -Bshareable -x"
++ RPATH_FLAG='-R'
++ LD_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
+ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
+
++
+ fi
+ rm -f conftest*
+
+@@ -3332,13 +3342,17 @@
+
+ if test "$no_x" = yes; then
+ echo $ac_n "checking for X11 libraries""... $ac_c" 1>&6
+-echo "configure:3336: checking for X11 libraries" >&5
++echo "configure:3346: checking for X11 libraries" >&5
+ XLIBSW=nope
+ dirs="/usr/unsupported/lib /usr/local/lib /usr/X386/lib /usr/X11R6/lib /usr/X11R5/lib /usr/lib/X11R5 /usr/lib/X11R4 /usr/openwin/lib /usr/X11/lib /usr/sww/X11/lib"
for i in $dirs ; do
if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
echo "$ac_t""$i" 1>&6
- XLIBSW="-L$i -lX11"
-+ XLIBSW="-L$i -Wl,-R$i -lX11"
++ if test "${RPATH_FLAG}" != ""; then
++ XLIBSW="-L$i ${RPATH_FLAG}$i -lX11"
++ else
++ XLIBSW="-L$i -lX11"
++ fi
x_libraries="$i"
break
fi
-@@ -3347,7 +3348,7 @@
+@@ -3347,12 +3361,16 @@
if test "$x_libraries" = ""; then
XLIBSW=-lX11
else
- XLIBSW="-L$x_libraries -lX11"
-+ XLIBSW="-L$x_libraries -Wl,-R$x_libraries -lX11"
++ if test "${RPATH_FLAG}" != ""; then
++ XLIBSW="-L$x_libraries ${RPATH_FLAG}$x_libraries -lX11"
++ else
++ XLIBSW="-L$x_libraries -lX11"
++ fi
fi
fi
if test "$XLIBSW" = nope ; then
-@@ -3415,8 +3416,8 @@
- if test "x${x_libraries}" != "x"; then
- LIB_RUNTIME_DIR="${LIB_RUNTIME_DIR}:${x_libraries}"
+ echo $ac_n "checking for XCreateWindow in -lXwindow""... $ac_c" 1>&6
+-echo "configure:3356: checking for XCreateWindow in -lXwindow" >&5
++echo "configure:3374: checking for XCreateWindow in -lXwindow" >&5
+ ac_lib_var=`echo Xwindow'_'XCreateWindow | sed 'y%./+-%__p_%'`
+ if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+@@ -3417,6 +3435,10 @@
fi
--if test "${TCL_LD_SEARCH_FLAGS}" = '-L${LIB_RUNTIME_DIR}'; then
-- LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -L/g'`
-+if test "${TCL_LD_SEARCH_FLAGS}" = '-Wl,-rpath,${LIB_RUNTIME_DIR}'; then
+ if test "${TCL_LD_SEARCH_FLAGS}" = '-L${LIB_RUNTIME_DIR}'; then
+ LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -L/g'`
++elif test "${TCL_LD_SEARCH_FLAGS}" = '-R${LIB_RUNTIME_DIR}'; then
++ LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -R/g'`
++elif test "${TCL_LD_SEARCH_FLAGS}" = '-Wl,-rpath,${LIB_RUNTIME_DIR}'; then
+ LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -Wl,-rpath,/g'`
fi
# The statement below is very tricky! It actually *evaluates* the
-@@ -4088,7 +4089,7 @@
+@@ -4088,7 +4110,7 @@
if test "${SHARED_BUILD}" = "1" -a "${SHLIB_SUFFIX}" != ""; then
TK_SHLIB_CFLAGS="${SHLIB_CFLAGS}"
TK_LIB_FILE=libtk${TK_SHARED_LIB_SUFFIX}
@@ -48,14 +103,23 @@ $NetBSD: patch-ab,v 1.5 2001/04/18 18:15:41 jwise Exp $
RANLIB=":"
# TCL_STUB_FLAGS="-DUSE_TCL_STUBS"
-@@ -4114,8 +4115,8 @@
+@@ -4111,11 +4133,17 @@
+ if test "$SHARED_BUILD" = 0 -o $TCL_NEEDS_EXP_FILE = 0; then
+ if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
+ eval TK_LIB_FLAG="-ltk${VERSION}\${TK_DBGX}"
++ eval TK_BUILD_LIB_SPEC="libtk${VERSION}\${TK_DBGX}.la"
else
eval TK_LIB_FLAG="-ltk`echo ${VERSION} | tr -d .`\${TK_DBGX}"
++ eval TK_BUILD_LIB_SPEC="libtk`echo ${VERSION} | tr -d .`\${TK_DBGX}.la"
++ fi
++ if test "${RPATH_FLAG}" != ""; then
++ TK_LIB_SPEC_RPATH="${RPATH_FLAG}${exec_prefix}/lib"
++ else
++ TK_LIB_SPEC_RPATH=""
fi
- TK_BUILD_LIB_SPEC="-L`pwd` ${TK_LIB_FLAG}"
- TK_LIB_SPEC="-L${exec_prefix}/lib ${TK_LIB_FLAG}"
-+ TK_BUILD_LIB_SPEC=libtk83.la
-+ TK_LIB_SPEC="-L${exec_prefix}/lib -Wl,-R${exec_prefix}/lib ${TK_LIB_FLAG}"
++ TK_LIB_SPEC="-L${exec_prefix}/lib ${TK_LIB_SPEC_RPATH} ${TK_LIB_FLAG}"
TK_BUILD_EXP_FILE=""
TK_EXP_FILE=""
else
diff --git a/x11/tk/patches/patch-ac b/x11/tk/patches/patch-ac
new file mode 100644
index 00000000000..8314df79558
--- /dev/null
+++ b/x11/tk/patches/patch-ac
@@ -0,0 +1,68 @@
+$NetBSD: patch-ac,v 1.1 2001/05/24 02:58:30 jlam Exp $
+
+--- aclocal.m4.orig Tue Aug 8 15:19:32 2000
++++ aclocal.m4
+@@ -580,6 +580,7 @@
+
+ do64bit_ok=no
+ fullSrcDir=`cd $srcdir; pwd`
++ RPATH_FLAG=""
+ EXTRA_CFLAGS=""
+ TCL_EXPORT_FILE_SUFFIX=""
+ UNSHARED_LIB_SUFFIX=""
+@@ -769,7 +770,6 @@
+ 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"
+@@ -781,11 +781,19 @@
+ #ifdef __ELF__
+ yes
+ #endif
+- ],
++ ], [
+ AC_MSG_RESULT(yes)
+- SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so',
++ SHLIB_LD='${TCL_CC} -shared -Wl,-x'
++ RPATH_FLAG='-Wl,-rpath,'
++ LD_SEARCH_FLAGS='-Wl,-rpath,${LIB_RUNTIME_DIR}'
++ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so'
++ ], [
+ AC_MSG_RESULT(no)
++ SHLIB_LD="ld -Bshareable -x"
++ RPATH_FLAG='-R'
++ LD_SEARCH_FLAGS='-R${LIB_RUNTIME_DIR}'
+ SHARED_LIB_SUFFIX='${TCL_TRIM_DOTS}\$\{DBGX\}.so.1.0'
++ ]
+ )
+ ], [
+ SHLIB_CFLAGS=""
+@@ -1383,7 +1391,11 @@
+ for i in $dirs ; do
+ if test -r $i/libX11.a -o -r $i/libX11.so -o -r $i/libX11.sl; then
+ AC_MSG_RESULT($i)
+- XLIBSW="-L$i -lX11"
++ if test "${RPATH_FLAG}" != ""; then
++ XLIBSW="-L$i ${RPATH_FLAG}$i -lX11"
++ else
++ XLIBSW="-L$i -lX11"
++ fi
+ x_libraries="$i"
+ break
+ fi
+@@ -1392,7 +1404,11 @@
+ if test "$x_libraries" = ""; then
+ XLIBSW=-lX11
+ else
+- XLIBSW="-L$x_libraries -lX11"
++ if test "${RPATH_FLAG}" != ""; then
++ XLIBSW="-L$x_libraries ${RPATH_FLAG}$x_libraries -lX11"
++ else
++ XLIBSW="-L$x_libraries -lX11"
++ fi
+ fi
+ fi
+ if test "$XLIBSW" = nope ; then
diff --git a/x11/tk/patches/patch-ad b/x11/tk/patches/patch-ad
new file mode 100644
index 00000000000..b5f7b2837bb
--- /dev/null
+++ b/x11/tk/patches/patch-ad
@@ -0,0 +1,44 @@
+$NetBSD: patch-ad,v 1.1 2001/05/24 02:58:30 jlam Exp $
+
+--- configure.in.orig Tue Aug 8 15:19:32 2000
++++ configure.in
+@@ -205,6 +205,10 @@
+ fi
+ if test "${TCL_LD_SEARCH_FLAGS}" = '-L${LIB_RUNTIME_DIR}'; then
+ LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -L/g'`
++elif test "${TCL_LD_SEARCH_FLAGS}" = '-R${LIB_RUNTIME_DIR}'; then
++ LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -R/g'`
++elif test "${TCL_LD_SEARCH_FLAGS}" = '-Wl,-rpath,${LIB_RUNTIME_DIR}'; then
++ LIB_RUNTIME_DIR=`echo ${LIB_RUNTIME_DIR} |sed -e 's/:/ -Wl,-rpath,/g'`
+ fi
+
+ # The statement below is very tricky! It actually *evaluates* the
+@@ -334,7 +338,7 @@
+ if test "${SHARED_BUILD}" = "1" -a "${SHLIB_SUFFIX}" != ""; then
+ TK_SHLIB_CFLAGS="${SHLIB_CFLAGS}"
+ TK_LIB_FILE=libtk${TK_SHARED_LIB_SUFFIX}
+- MAKE_LIB="\${SHLIB_LD} -o \${TK_LIB_FILE} \${OBJS} \$(TK_LD_SEARCH_FLAGS) ${TCL_STUB_LIB_SPEC} \${LIBS}"
++ MAKE_LIB="\${SHLIB_LD} -o \${TK_LIB_FILE:C/\.so.*/.la/} \${OBJS:.o=.lo} \$(TK_LD_SEARCH_FLAGS) ${TCL_STUB_LIB_SPEC} \${LIBS} -version-info 1:0"
+ RANLIB=":"
+
+ # TCL_STUB_FLAGS="-DUSE_TCL_STUBS"
+@@ -357,11 +361,17 @@
+ if test "$SHARED_BUILD" = 0 -o $TCL_NEEDS_EXP_FILE = 0; then
+ if test "${TCL_LIB_VERSIONS_OK}" = "ok"; then
+ eval TK_LIB_FLAG="-ltk${VERSION}\${TK_DBGX}"
++ eval TK_BUILD_LIB_SPEC="libtk${VERSION}\${TK_DBGX}.la"
+ else
+ eval TK_LIB_FLAG="-ltk`echo ${VERSION} | tr -d .`\${TK_DBGX}"
++ eval TK_BUILD_LIB_SPEC="libtk`echo ${VERSION} | tr -d .`\${TK_DBGX}.la"
+ fi
+- TK_BUILD_LIB_SPEC="-L`pwd` ${TK_LIB_FLAG}"
+- TK_LIB_SPEC="-L${exec_prefix}/lib ${TK_LIB_FLAG}"
++ if test "${RPATH_FLAG}" != ""; then
++ TK_LIB_SPEC_RPATH="${RPATH_FLAG}${exec_prefix}/lib"
++ else
++ TK_LIB_SPEC_RPATH=""
++ fi
++ TK_LIB_SPEC="-L${exec_prefix}/lib ${TK_LIB_SPEC_RPATH} ${TK_LIB_FLAG}"
+ TK_BUILD_EXP_FILE=""
+ TK_EXP_FILE=""
+ else