aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--devel/tcllib/Makefile4
-rw-r--r--devel/tcllib/pkg-plist1
-rw-r--r--devel/tcllib/scripts/post-patch9
3 files changed, 13 insertions, 1 deletions
diff --git a/devel/tcllib/Makefile b/devel/tcllib/Makefile
index 6bfcf9c99c50..2b8727711387 100644
--- a/devel/tcllib/Makefile
+++ b/devel/tcllib/Makefile
@@ -14,12 +14,14 @@ MASTER_SITE_SUBDIR= tcllib
MAINTAINER= mi@aldan.algebra.com
COMMENT= A collection of utility modules for Tcl
-BUILD_DEPENDS= tclsh:${PORTSDIR}/lang/tcl84
+BUILD_DEPENDS= tclsh:${PORTSDIR}/lang/tcl${TCL_VER:S/.//}
+TCL_VER?= 8.4
USE_BZIP2= yes
GNU_CONFIGURE= yes
ALL_TARGET= all
MAKE_ENV+= LANG=C
+SCRIPTS_ENV+= TCL_VER=${TCL_VER} PATCH="${PATCH}"
PLIST_SUB+= PORTVERSION=${PORTVERSION}
diff --git a/devel/tcllib/pkg-plist b/devel/tcllib/pkg-plist
index 1bfe3414bf65..f982afa20354 100644
--- a/devel/tcllib/pkg-plist
+++ b/devel/tcllib/pkg-plist
@@ -1,3 +1,4 @@
+bin/dtplite
lib/tcllib%%PORTVERSION%%/pkgIndex.tcl
lib/tcllib%%PORTVERSION%%/asn/asn.tcl
lib/tcllib%%PORTVERSION%%/asn/pkgIndex.tcl
diff --git a/devel/tcllib/scripts/post-patch b/devel/tcllib/scripts/post-patch
new file mode 100644
index 000000000000..3ff853ec0461
--- /dev/null
+++ b/devel/tcllib/scripts/post-patch
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+${PATCH} -f ${WRKSRC}/apps/dtplite << EOP
+@@ -1,3 +1,1 @@
+-#! /bin/sh
+-# -*- tcl -*-
+-exec tclsh "$0" ${1+"$@"}
++#!${PREFIX}/bin/tclsh${TCL_VER}
+EOP