View | Details | Raw Unified | Return to bug 109716 | Differences between
and this patch

Collapse All | Expand All

(-)devel/tcllib/Makefile (-15 / +53 lines)
Lines 7-30 Link Here
7
7
8
PORTNAME=		tcllib
8
PORTNAME=		tcllib
9
PORTVERSION=		1.9
9
PORTVERSION=		1.9
10
PORTREVISION=		1
10
PORTREVISION=		2
11
CATEGORIES=		devel tcl83 tcl84
11
CATEGORIES=		devel tcl84
12
MASTER_SITES=		${MASTER_SITE_SOURCEFORGE}
12
MASTER_SITES=		${MASTER_SITE_SOURCEFORGE}
13
MASTER_SITE_SUBDIR=	tcllib
13
MASTER_SITE_SUBDIR=	tcllib
14
PKGNAMESUFFIX?=		${THREADS_SUFFIX}
14
15
15
MAINTAINER=	mi@aldan.algebra.com
16
MAINTAINER=	mi@aldan.algebra.com
16
COMMENT=	A collection of utility modules for Tcl
17
COMMENT=	A collection of utility modules for Tcl
17
18
18
BUILD_DEPENDS=	tclsh${TCL_VER}:${PORTSDIR}/lang/tcl${TCL_VER:S/.//}
19
20
TCL_VER?=	8.4
21
USE_BZIP2=	yes
19
USE_BZIP2=	yes
22
GNU_CONFIGURE=	yes
20
GNU_CONFIGURE=	yes
23
ALL_TARGET=	all
21
ALL_TARGET=	all
24
MAKE_ENV+=	LANG=C
22
MAKE_ENV+=	LANG=C
25
SCRIPTS_ENV+=	TCL_VER=${TCL_VER} PATCH="${PATCH}"
26
23
27
PLIST_SUB+=	PORTVERSION=${PORTVERSION}
24
USE_TCL_VER?=	84
25
26
.if ${USE_TCL_VER} != 84 && ${USE_TCL_VER} != 85
27
IGNORE=	supported values for USE_TCL_VER are only 84 and 85
28
.endif
29
30
USE_TCL=	${USE_TCL_VER}
31
USE_TCL_BUILD=	${USE_TCL_VER}
28
32
29
MANN=	aes.n asn.n ansi_cmacros.n ansi_cctrl.n ansi_cattr.n           \
33
MANN=	aes.n asn.n ansi_cmacros.n ansi_cctrl.n ansi_cattr.n           \
30
	ansi_code.n ansi_ctrlu.n ansi_send.n autoproxy.n base32hex.n   \
34
	ansi_code.n ansi_ctrlu.n ansi_send.n autoproxy.n base32hex.n   \
Lines 58-77 Link Here
58
62
59
MANCOMPRESSED=	no
63
MANCOMPRESSED=	no
60
64
61
post-patch:
65
PLIST_SUB+=	PORTVERSION=${PORTVERSION}
62
	#
63
	# Ensure, the detailed output of vendors' self-tests is
64
	# available in addition to the pretty progress report:
65
	#
66
	${REINPLACE_CMD} -e 's,test run,test run -l testlog,' \
67
		${WRKSRC}/Makefile.in
68
66
69
.include <bsd.port.pre.mk>
67
.include <bsd.port.pre.mk>
70
68
69
. if exists(${TCLSH})
70
_TCL_IS_THREADED!=	${ECHO_CMD} 'puts [array names tcl_platform -exact threaded]' | ${TCLSH} || return 0
71
.  if !defined(TCL_WITH_THREADS) && !defined(WITH_THREADS) && !empty(_TCL_IS_THREADED)
72
TCL_WITH_THREADS=	yes
73
.  endif
74
. endif
75
76
.if defined(TCL_WITH_THREADS) || defined(WITH_THREADS)
77
. if defined(_TCL_IS_THREADED) && empty(_TCL_IS_THREADED)
78
IGNORE=	tcl with threads is required. Please install tcl with WITH_THREADS defined or from lang/tcl${USE_TCL} port and try again
79
. endif
80
THREADS_SUFFIX=		-threads
81
USE_TCL=	${USE_TCL_VER}-thread
82
USE_TCL_BUILD=	${USE_TCL_VER}-thread
83
CONFLICTS=	tcllib-1.*
84
.include "${PORTSDIR}/Mk/bsd.tcl.mk"
85
.else
86
CONFLICTS=	tcllib-threads-1.*
87
.endif
88
89
LATEST_LINK=	tcllib${THREADS_SUFFIX}
90
91
SCRIPTS_ENV+=	TCL_VER=${TCL_VER} PATCH="${PATCH}"
92
93
post-patch:
94
# Ensure that configure looks for the right tclsh
95
	@${REINPLACE_CMD} -e 's|\$$dir/tclsh\[8-9\]\*\$${EXEEXT}|${TCLSH}|g' \
96
		-e 's|\$$dir/tclsh\*\$${EXEEXT}|${TCLSH}|g' ${WRKSRC}/configure
97
#
98
# Ensure, the detailed output of vendors' self-tests is
99
# available in addition to the pretty progress report:
100
#
101
	@${REINPLACE_CMD} -e 's,test run,test run -l testlog,' \
102
		${WRKSRC}/Makefile.in
103
.for FILE in dtplite tcldocstrip page
104
	@${REINPLACE_CMD} -e 's|exec tclsh|exec ${TCLSH}|g' \
105
		${WRKSRC}/apps/${FILE}
106
.endfor
107
71
RUNTEST=	${SETENV} LANG=C DISPLAY= ${MAKE} -C ${WRKSRC} test
108
RUNTEST=	${SETENV} LANG=C DISPLAY= ${MAKE} -C ${WRKSRC} test
72
MYID	!=	${ID} -u
109
MYID	!=	${ID} -u
73
.if ${MYID} == 0
110
.if ${MYID} == 0
74
RUNTEST:=	${SU_CMD:S/root/-m nobody/} "${RUNTEST}"
111
RUNTEST:=	${SU_CMD:S/root/-m nobody/} "${RUNTEST}"
112
75
pre-build:
113
pre-build:
76
	#
114
	#
77
	# Preparing to run the tests as `nobody'
115
	# Preparing to run the tests as `nobody'
Lines 79-85 Link Here
79
	${FIND} ${WRKSRC} -type d | ${XARGS} ${CHOWN} nobody
117
	${FIND} ${WRKSRC} -type d | ${XARGS} ${CHOWN} nobody
80
.endif
118
.endif
81
119
82
test:
120
test: configure pre-build
83
	@set -x ; if ! ${RUNTEST};	\
121
	@set -x ; if ! ${RUNTEST};	\
84
	then	\
122
	then	\
85
		${AWK} '$$NF == "FAILED" { echo = 1 }	\
123
		${AWK} '$$NF == "FAILED" { echo = 1 }	\
(-)devel/tcllib/files/patch-modules-math-fuzzy.test (+24 lines)
Line 0 Link Here
1
--- modules/math/fuzzy.test	2006/01/24 05:10:01	1.5
2
+++ modules/math/fuzzy.test	2006/11/07 20:02:34	1.6
3
@@ -168,6 +168,12 @@
4
    set tol_le 0
5
    set tol_lt 0
6
 
7
+   #
8
+   # Force Tcl8.4 or earlier behaviour in expanding numbers
9
+   #
10
+   set org_tcl_precision $tcl_precision
11
+   set tcl_precision 12
12
+
13
    for { set i -1000 } { $i <= 1000 } { incr i } {
14
       if { $i == 0 } continue
15
 
16
@@ -192,6 +198,7 @@
17
          set equal 0
18
       }
19
    }
20
+   set tcl_precision $org_tcl_precision
21
    set equal
22
 } 0
23
 
24
(-)devel/tcllib/files/patch-modules-snit-snit.test (+23 lines)
Line 0 Link Here
1
--- modules/snit/snit.test.orig	Thu Mar  1 12:39:28 2007
2
+++ modules/snit/snit.test	Thu Mar  1 12:52:09 2007
3
@@ -5784,13 +5784,19 @@
4
 #-----------------------------------------------------------------------
5
 # expose statement
6
 
7
+if {[package vsatisfies [package present Tcl] 8.5]} {
8
+    set expose_msg "expose"
9
+} else {
10
+    set expose_msg "::snit::Comp.statement.expose"
11
+}
12
+
13
 test expose-1.1 {can't expose nothing} -body {
14
     type dog {
15
 	expose
16
     }
17
 } -returnCodes {
18
     error
19
-} -result [tcltest::wrongNumArgs ::snit::Comp.statement.expose {component ?as? ?methodname?} 0]
20
+} -result [tcltest::wrongNumArgs $expose_msg {component ?as? ?methodname?} 0]
21
 
22
 test expose-1.2 {expose a component that's never installed} -body {
23
     type dog {
(-)devel/tcllib/files/patch-modules-struct-sets.test (+20 lines)
Line 0 Link Here
1
--- modules/struct/sets.test.orig	Tue Jan 31 05:57:40 2006
2
+++ modules/struct/sets.test	Thu Mar  1 12:58:55 2007
3
@@ -36,10 +36,16 @@
4
 
5
 #----------------------------------------------------------------------
6
 
7
+if {[package vsatisfies [package present Tcl] 8.5]} {
8
+    set setop_msg setop
9
+} else {
10
+    set setop_msg ::struct::set::set
11
+}
12
+
13
 test set-1.0 {nothing} {
14
     catch {setop} msg
15
     set msg
16
-} [tcltest::wrongNumArgs {::struct::set::set} {cmd args} 0]
17
+} [tcltest::wrongNumArgs $setop_msg {cmd args} 0]
18
 
19
 test set-1.1 {bogus} {
20
     catch {setop foo} msg
(-)devel/tcllib/scripts/post-patch (-9 lines)
Lines 1-9 Link Here
1
#!/bin/sh
2
3
${PATCH} -f ${WRKSRC}/apps/dtplite << EOP
4
@@ -1,3 +1,1 @@
5
-#! /bin/sh
6
-# -*- tcl -*-
7
-exec tclsh "$0" ${1+"$@"}
8
+#!${PREFIX}/bin/tclsh${TCL_VER}
9
EOP

Return to bug 109716