Date: Thu, 13 Mar 2014 13:11:51 +1030 From: "Daniel O'Connor" <doconnor@gsoft.com.au> To: tcltk@FreeBSD.org Cc: mm@FreeBSD.org Subject: Tk86 not loadable via package require Message-ID: <D68525E5-A1A1-40A6-A1C9-917E7621D502@gsoft.com.au>
next in thread | raw e-mail | index | archive | help
--Apple-Mail=_176A1B19-945B-4623-B1EE-E58057155996
Content-Type: multipart/mixed;
boundary="Apple-Mail=_1697F2AD-2E20-4CE5-B699-44E2BE6CF715"
--Apple-Mail=_1697F2AD-2E20-4CE5-B699-44E2BE6CF715
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
charset=us-ascii
Hi,
I installed tcl86 and tk86 but I can't load Tk from tclsh86, eg..
[mdtest 2:27] ~ >tclsh8.6
tclsh8.6 [/local0~]package require Tk
can't find package Tk
while evaluating {package require Tk}
It turns out that this is due to a broken =
/usr/local/lib/tk8.6/pkgIndex.tcl
It is..
if {[catch {package present Tcl 8.6.0}]} return
package ifneeded Tk 8.6.1 [list load [file normalize [file join $dir .. =
libtk86.so.1]] Tk]
but the tcl86 reports as Tcl 8.6b2 hence the package present fails and =
Tk is never loaded.
It can be worked around by changing the 8.6.0 to 8.6b2 with the attached =
patch.
--
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C
--Apple-Mail=_1697F2AD-2E20-4CE5-B699-44E2BE6CF715
Content-Disposition: attachment;
filename=fix-package-require.diff
Content-Type: application/octet-stream;
x-unix-mode=0644;
name="fix-package-require.diff"
Content-Transfer-Encoding: 7bit
diff -ur /usr/ports/x11-toolkits/tk86/files/patch-unix::Makefile.in tk86/files/patch-unix::Makefile.in
--- /usr/ports/x11-toolkits/tk86/files/patch-unix::Makefile.in 2014-02-03 11:03:15.000000000 +0000
+++ tk86/files/patch-unix::Makefile.in 2014-03-13 02:39:59.000000000 +0000
@@ -1,5 +1,5 @@
---- Makefile.in.orig 2013-09-17 14:25:13.000000000 +0200
-+++ Makefile.in 2014-02-03 12:02:57.000000000 +0100
+--- Makefile.in.orig 2013-09-17 12:25:13.000000000 +0000
++++ Makefile.in 2014-03-13 02:39:39.000000000 +0000
@@ -64,6 +64,8 @@
# Directory in which to install the include file tk.h:
@@ -59,6 +59,15 @@
@for i in "$(LIB_INSTALL_DIR)" "$(BIN_INSTALL_DIR)" \
"$(PKG_INSTALL_DIR)" "$(CONFIG_INSTALL_DIR)" ; \
do \
+@@ -727,7 +736,7 @@
+ echo "Creating package index $(PKG_INDEX)"; \
+ rm -f "$(PKG_INDEX)"; \
+ (\
+- echo "if {[catch {package present Tcl 8.6.0}]} return";\
++ echo "if {[catch {package present Tcl 8.6b2}]} return";\
+ relative=`echo | awk '{ORS=" "; split("$(TK_PKG_DIR)",a,"/"); for (f in a) {print ".."}}'`;\
+ if test "x$(DLL_INSTALL_DIR)" != "x$(BIN_INSTALL_DIR)"; then \
+ echo "package ifneeded Tk $(MAJOR_VERSION).$(MINOR_VERSION)$(PATCH_LEVEL) [list load [file normalize [file join \$$dir $${relative}$(TK_LIB_FILE)]] Tk]";\
@@ -744,6 +753,10 @@
@echo "Installing $(LIB_FILE) to $(DLL_INSTALL_DIR)/"
@@INSTALL_LIB@
--Apple-Mail=_1697F2AD-2E20-4CE5-B699-44E2BE6CF715
Content-Transfer-Encoding: 7bit
Content-Type: text/plain;
charset=us-ascii
--Apple-Mail=_1697F2AD-2E20-4CE5-B699-44E2BE6CF715--
--Apple-Mail=_176A1B19-945B-4623-B1EE-E58057155996
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
filename=signature.asc
Content-Type: application/pgp-signature;
name=signature.asc
Content-Description: Message signed with OpenPGP using GPGMail
-----BEGIN PGP SIGNATURE-----
Comment: GPGTools - http://gpgtools.org
iD8DBQFTIRrv5ZPcIHs/zowRAkQMAJwNjvYp0ypfIaoo0Y+wB+rV6O+5dgCgmK0g
fYdjscHI8+/LlbkkjX1Dz5c=
=VnHl
-----END PGP SIGNATURE-----
--Apple-Mail=_176A1B19-945B-4623-B1EE-E58057155996--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?D68525E5-A1A1-40A6-A1C9-917E7621D502>
