diff -urN twelf.orig/Makefile twelf/Makefile --- twelf.orig/Makefile 2014-07-05 12:27:03.000000000 -0700 +++ twelf/Makefile 2014-07-15 00:17:25.000000000 -0700 @@ -2,41 +2,59 @@ # $FreeBSD: head/lang/twelf/Makefile 360810 2014-07-05 19:27:03Z olgeni $ PORTNAME= twelf -PORTVERSION= 1.5R1 -PORTREVISION= 5 -CATEGORIES= lang -MASTER_SITES= http://www-2.cs.cmu.edu/~twelf/dist/ http://www.cs.cmu.edu/~twelf/dist/ -DISTNAME= twelf-1-5R1 +PORTVERSION= 1.7.1 +CATEGORIES= lang math +MASTER_SITES= http://twelf.plparty.org/releases/ \ + http://www-2.cs.cmu.edu/~twelf/dist/ http://www.cs.cmu.edu/~twelf/dist/ +DISTNAME= ${PORTNAME}-src-${PORTVERSION} -MAINTAINER= ports@FreeBSD.org +MAINTAINER= beyert@cs.ucr.edu COMMENT= Meta-logical framework for deductive systems -.if defined(WITH_MLTON) +LICENSE= BSD2CLAUSE +LICENSE_FILE= ${WRKSRC}/LICENSE + RUN_DEPENDS= mlton:${PORTSDIR}/lang/mlton BUILD_DEPENDS= mlton:${PORTSDIR}/lang/mlton -.elif defined(WITH_SML_NJ_DEVEL) -RUN_DEPENDS= sml:${PORTSDIR}/lang/sml-nj-devel -BUILD_DEPENDS= sml:${PORTSDIR}/lang/sml-nj-devel -.else -RUN_DEPENDS= sml:${PORTSDIR}/lang/sml-nj -BUILD_DEPENDS= sml:${PORTSDIR}/lang/sml-nj -.endif +USES= gmake +ALL_TARGET= mlton +PLIST_FILES= bin/${PORTNAME}-server +PORTDATA= emacs examples examples-clp examples-delphin tex vim README +PORTDOCS= dvi html info pdf ps + +.include + +.if ${PORT_OPTIONS:MDOCS} USE_TEX= tex:build +USES+= makeinfo +BUILD_DEPENDS+= texinfo.tex:${PORTSDIR}/print/texinfo +.endif -.if defined(WITH_MLTON) -MAKEFILE= mlton/Makefile -.elif defined(WITH_SML_NJ_DEVEL) -MAKEFILE= smlnj/Makefile +post-patch: +.if ${PORT_OPTIONS:MDOCS} + @${REINPLACE_CMD} 's|-number|-number-sections|g' \ + ${WRKSRC}/doc/guide/Makefile + @${REINPLACE_CMD} 's|twelf_\*.html|twelf/\*.html|g' \ + ${WRKSRC}/doc/guide/Makefile .endif -WRKSRC= ${WRKDIR}/twelf -INFO= twelf +post-build: +.if ${PORT_OPTIONS:MDOCS} + cd ${WRKSRC}/doc/guide && ${MAKE} all ${INSTALL_TARGET} +.endif -RESTRICTED= License is currently indeterminate (expected to be GPL) +do-install: + ${INSTALL_PROGRAM} ${WRKSRC}/bin/${PORTNAME}-server \ + ${STAGEDIR}${PREFIX}/bin + ${MKDIR} ${STAGEDIR}${DATADIR} + cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDATA}" ${STAGEDIR}${DATADIR} +.if ${PORT_OPTIONS:MDOCS} + @${MKDIR} ${STAGEDIR}${DOCSDIR} + cd ${WRKSRC}/doc && ${COPYTREE_SHARE} "${PORTDOCS}" ${STAGEDIR}${DOCSDIR} +.endif -NO_STAGE= yes -post-patch: - @${REINPLACE_CMD} -e "s|%%PREFIX%%|${PREFIX}|g" ${WRKSRC}/Makefile +WRKSRC= ${WRKDIR}/twelf +INFO= twelf .include diff -urN twelf.orig/distinfo twelf/distinfo --- twelf.orig/distinfo 2014-01-22 07:30:13.000000000 -0800 +++ twelf/distinfo 2014-07-08 19:33:22.000000000 -0700 @@ -1,2 +1,2 @@ -SHA256 (twelf-1-5R1.tar.gz) = d20473493cd39e111ce3585f8c32eefc79de4099ae4e97bfe2eb7695d6987564 -SIZE (twelf-1-5R1.tar.gz) = 1157430 +SHA256 (twelf-src-1.7.1.tar.gz) = 91b0d4d8c2e54452a042da0ff642f3b46b25efb36a84497aa8b96598f49a213a +SIZE (twelf-src-1.7.1.tar.gz) = 1147610 diff -urN twelf.orig/files/patch-FreeBSD.mk twelf/files/patch-FreeBSD.mk --- twelf.orig/files/patch-FreeBSD.mk 2014-01-22 09:40:44.000000000 -0800 +++ twelf/files/patch-FreeBSD.mk 1969-12-31 16:00:00.000000000 -0800 @@ -1,170 +0,0 @@ ---- FreeBSD.mk.orig 2009-02-12 21:33:04.000000000 -0500 -+++ FreeBSD.mk 2009-02-12 21:48:54.000000000 -0500 -@@ -0,0 +1,82 @@ -+# --------------------------------------------------------------- -+# Executables -+# --------------------------------------------------------------- -+ -+arch != uname -p -+ -+.if ${arch} == "i386" -+smlarch = x86 -+.else -+smlarch = ${arch} -+.endif -+ -+prefix = ${PREFIX} -+bindir = ${prefix}/bin -+infodir = ${prefix}/info -+twelfexecdir = ${prefix}/libexec/twelf -+twelfsharedir = ${prefix}/share/twelf -+ -+runfile = bin/twelf-server -+heapfile = bin/.heap/twelf-server.${smlarch}-bsd -+ -+# --------------------------------------------------------------- -+# Documentation -+# --------------------------------------------------------------- -+ -+htmlnodes = toc abt 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 -+ -+dvifile = doc/dvi/twelf.dvi -+htmlfiles := doc/html/index.html ${htmlnodes:%=doc/html/twelf_%.html} -+infofile = doc/info/twelf.info -+pdffile = doc/pdf/twelf.pdf -+psfile = doc/ps/twelf.ps -+ -+docfiles = ${dvifile} ${htmlfiles} ${infofile} ${pdffile} ${psfile} -+ -+.for file in ${docfiles} -+${file}: -+ (cd doc/guide; make; make install) -+.endfor -+ -+all: ${runfile} ${heapfile} ${docfiles} -+ -+# --------------------------------------------------------------- -+# Installation -+# --------------------------------------------------------------- -+ -+sharefiles != (echo README HISTORY; \ -+ echo ${docfiles}; \ -+ find emacs -type f -not -path '*/CVS/*'; \ -+ find examples -type f -not -path '*/CVS/*'; \ -+ find examples-clp -type f -not -path '*/CVS/*'; \ -+ find exercises -type f -not -path '*/CVS/*'; \ -+ find tex -type f -not -path '*/CVS/*'; \ -+ find vim -type f -not -path '*/CVS/*' ) -+ -+installfiles := ${bindir}/twelf-server \ -+ ${twelfsharedir}/${runfile} \ -+ ${twelfexecdir}/${heapfile} \ -+ ${infodir}/twelf.info \ -+ ${sharefiles:%=$(twelfsharedir)/%} -+ -+${bindir}/twelf-server: ${twelfsharedir}/${runfile} -+ ln -s $? $@ -+ -+${twelfsharedir}/${runfile}: ${runfile} -+ @install -d -o root -g wheel -m 0755 ${@D} -+ install -o root -g wheel -m 0555 $? $@ -+ -+${twelfexecdir}/${heapfile}: ${heapfile} -+ @install -d -o root -g wheel -m 0755 ${@D} -+ install -o root -g wheel -m 0444 $? $@ -+ -+${infodir}/twelf.info: doc/info/twelf.info -+ install -o root -g wheel -m 0444 $? $@ -+ -+.for file in ${sharefiles} -+${twelfsharedir}/${file}: ${file} -+ @install -d -o root -g wheel -m 0755 ${@D} -+ install -o root -g wheel -m 0644 $? $@ -+.endfor -+ -+install: ${installfiles} ---- FreeBSD.mk.orig 2009-02-12 21:33:04.000000000 -0500 -+++ FreeBSD.mk 2009-02-12 21:48:54.000000000 -0500 -@@ -0,0 +1,82 @@ -+# --------------------------------------------------------------- -+# Executables -+# --------------------------------------------------------------- -+ -+arch != uname -p -+ -+.if ${arch} == "i386" -+smlarch = x86 -+.else -+smlarch = ${arch} -+.endif -+ -+prefix = ${PREFIX} -+bindir = ${prefix}/bin -+infodir = ${prefix}/info -+twelfexecdir = ${prefix}/libexec/twelf -+twelfsharedir = ${prefix}/share/twelf -+ -+runfile = bin/twelf-server -+heapfile = bin/.heap/twelf-server.${smlarch}-bsd -+ -+# --------------------------------------------------------------- -+# Documentation -+# --------------------------------------------------------------- -+ -+htmlnodes = toc abt 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 -+ -+dvifile = doc/dvi/twelf.dvi -+htmlfiles := doc/html/index.html ${htmlnodes:%=doc/html/twelf_%.html} -+infofile = doc/info/twelf.info -+pdffile = doc/pdf/twelf.pdf -+psfile = doc/ps/twelf.ps -+ -+docfiles = ${dvifile} ${htmlfiles} ${infofile} ${pdffile} ${psfile} -+ -+.for file in ${docfiles} -+${file}: -+ (cd doc/guide; make; make install) -+.endfor -+ -+all: ${runfile} ${heapfile} ${docfiles} -+ -+# --------------------------------------------------------------- -+# Installation -+# --------------------------------------------------------------- -+ -+sharefiles != (echo README HISTORY; \ -+ echo ${docfiles}; \ -+ find emacs -type f -not -path '*/CVS/*'; \ -+ find examples -type f -not -path '*/CVS/*'; \ -+ find examples-clp -type f -not -path '*/CVS/*'; \ -+ find exercises -type f -not -path '*/CVS/*'; \ -+ find tex -type f -not -path '*/CVS/*'; \ -+ find vim -type f -not -path '*/CVS/*' ) -+ -+installfiles := ${bindir}/twelf-server \ -+ ${twelfsharedir}/${runfile} \ -+ ${twelfexecdir}/${heapfile} \ -+ ${infodir}/twelf.info \ -+ ${sharefiles:%=$(twelfsharedir)/%} -+ -+${bindir}/twelf-server: ${twelfsharedir}/${runfile} -+ ln -s $? $@ -+ -+${twelfsharedir}/${runfile}: ${runfile} -+ @install -d -o root -g wheel -m 0755 ${@D} -+ install -o root -g wheel -m 0555 $? $@ -+ -+${twelfexecdir}/${heapfile}: ${heapfile} -+ @install -d -o root -g wheel -m 0755 ${@D} -+ install -o root -g wheel -m 0444 $? $@ -+ -+${infodir}/twelf.info: doc/info/twelf.info -+ install -o root -g wheel -m 0444 $? $@ -+ -+.for file in ${sharefiles} -+${twelfsharedir}/${file}: ${file} -+ @install -d -o root -g wheel -m 0755 ${@D} -+ install -o root -g wheel -m 0644 $? $@ -+.endfor -+ -+install: ${installfiles} diff -urN twelf.orig/files/patch-Makefile twelf/files/patch-Makefile --- twelf.orig/files/patch-Makefile 2014-01-22 09:40:44.000000000 -0800 +++ twelf/files/patch-Makefile 1969-12-31 16:00:00.000000000 -0800 @@ -1,26 +0,0 @@ ---- Makefile.orig 2005-03-08 15:49:53.000000000 -0500 -+++ Makefile 2009-02-12 22:07:33.000000000 -0500 -@@ -32,16 +32,20 @@ - version = "1.5" - delphinversion = "0.1" - -+.include "FreeBSD.mk" -+ - default : twelf-server twelf-emacs - --all : twelf-server twelf-sml twelf-emacs -+#all : twelf-server twelf-sml twelf-emacs - --twelf-server: ; -+${runfile}: ; - @echo "*************************************************" - @echo "Twelf $(version): Server" - @echo "*************************************************" - $(sml) < twelf-server.sml ; -- bin/.mkexec "$(sml)" "$(twelfdir)" twelf-server "$(twelfserver)" ; -+ bin/.mkexec "$(sml)" "$(twelfdir)" twelf-server "$(twelfserver)" "$(twelfexecdir)" ; -+ -+${heapfile}: ${runfile} - - twelf-sml: ; - @echo "*************************************************" diff -urN twelf.orig/files/patch-bin-mkexec twelf/files/patch-bin-mkexec --- twelf.orig/files/patch-bin-mkexec 2014-01-22 09:40:44.000000000 -0800 +++ twelf/files/patch-bin-mkexec 1969-12-31 16:00:00.000000000 -0800 @@ -1,13 +0,0 @@ ---- bin/.mkexec.orig 2003-01-21 01:03:32.000000000 -0500 -+++ bin/.mkexec 2009-02-12 21:24:27.000000000 -0500 -@@ -7,8 +7,9 @@ - # $2 = Twelf root directory - # $3 = Type of executable (e.g. twelf-server, twelf-sml) - # $4 = Name of executable (e.g. twelf-server, twelf-sml) -+# $5 = Twelf installation directory (e.g. /usr/local/libexec/twelf) - cat > "$2/bin/$4" <