1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-01 05:45:45 +00:00
freebsd-ports/lang/tclX/Makefile
Pietro Cerutti 4e23c21fc1 Add "tea" argument to USES=tcl to facilitate porting of TEA-based extensions.
Quoting https://tcl.tk/doc/tea:

"The Tcl Extension Architecture, or TEA, by John Ousterhout and others, is a
set of guidelines and techniques for the distribution, configuration,
compilation, and installation of Tcl extensions. TEA also provides a set of
utilities that operate accordingly. Many Tcl extensions leverage the TEA
utilities, which are designed to be easily customizable."

To facilitate the porting of TEA-based extensions, I have added the new "tea"
argument to USES=tcl. This argument prepares the autoconf environment by
setting GNU_CONFIGURE and sets some commonly used CONFIGURE_ARGS. Also, it
tries to figure out the correct extension name, sets TCL_PKG accordingly, and
adds it to PLIST_SUB.

I have modified a few ports to take advantage of this. More will come.
2016-04-19 14:20:01 +00:00

62 lines
1.8 KiB
Makefile

# Created by: jkh
# $FreeBSD$
PORTNAME= tclX
PORTVERSION= 8.4.1
CATEGORIES= lang tcl devel
MASTER_SITES= SF/${PORTNAME:tl}/TclX/${PORTVERSION}
DISTNAME= tclx${PORTVERSION}
MAINTAINER= mi@aldan.algebra.com
COMMENT= Extended TCL
LICENSE= TclTk
LICENSE_NAME= Tcl/Tk License
LICENSE_FILE= ${WRKSRC}/license.terms
LICENSE_PERMS= dist-mirror dist-sell pkg-mirror pkg-sell auto-accept
WRKSRC= ${WRKDIR}/${PORTNAME:tl}${PORTVERSION:R}
USES= autoreconf alias tcl:tea tar:bzip2
USE_LDCONFIG= ${PREFIX}/lib/tclx${PORTVERSION:R}
CONFIGURE_ARGS+=--enable-shared \
--with-help=Help
PLIST_SUB= TCLX_VER=${PORTVERSION:R}
ALL_TARGET= binaries libraries
INSTALL_TARGET= install-binaries install-libraries
.include <bsd.port.pre.mk>
.if ${TCL_VER} > 8.4
EXTRA_PATCHES+= ${FILESDIR}/tcl85-test-patch
.endif
.if ${TCL_VER} > 8.5
EXTRA_PATCHES+= ${FILESDIR}/tcl86-test-patch
.endif
post-configure:
# Disabling the failing help.test
${MV} ${WRKSRC}/tests/help.test ${WRKSRC}/tests/help.test.dis
post-install:
${INSTALL_DATA} ${WRKSRC}/doc/TclX.n ${STAGEDIR}${PREFIX}/man/mann
.for l in CmdWrite Handles Keylist ObjCmdWrite TclXInit
${INSTALL_DATA} ${WRKSRC}/doc/${l}.3 ${STAGEDIR}${PREFIX}/man/man3
.endfor
${LN} -s CmdWrite.3.gz ${STAGEDIR}${PREFIX}/man/man3/TclCommandWriting.3.gz
${LN} -s KeyList.3.gz ${STAGEDIR}${PREFIX}/man/man3/TclX_NewKeyedListObj.3.gz
.for l in Delete Get GetKeys Set TclX_Main TclX_NewKeyedListObj
${LN} -s KeyList.3.gz ${STAGEDIR}${PREFIX}/man/man3/TclX_KeyedList${l}.3.gz
.endfor
.for l in Alloc Free TblInit TblRelease TblUseCount Walk Xlate
${LN} -s Handles.3.gz ${STAGEDIR}${PREFIX}/man/man3/TclX_Handle${l}.3.gz
.endfor
.for l in Tclxcmd_Init TclX_Main Tkx_Init TkX_Main
${LN} -s TclXInit.3.gz ${STAGEDIR}${PREFIX}/man/man3/${l}.3.gz
.endfor
regression-test test: build
${SETENV} ${MAKE_ENV} ${MAKE} -C ${WRKSRC} test
.include <bsd.port.post.mk>