diff options
author | tdb <tdb@FreeBSD.org> | 2006-01-16 19:14:42 +0800 |
---|---|---|
committer | tdb <tdb@FreeBSD.org> | 2006-01-16 19:14:42 +0800 |
commit | 35fbd36e80d588a060f44f93185fecb88b8f167c (patch) | |
tree | c2e3a7096a3dcd384941be117cb7e530de501e8b /lang | |
parent | 5141e5101e9d13b11ab65abd0db3bcba23639ebd (diff) | |
download | freebsd-ports-gnome-35fbd36e80d588a060f44f93185fecb88b8f167c.tar.gz freebsd-ports-gnome-35fbd36e80d588a060f44f93185fecb88b8f167c.tar.zst freebsd-ports-gnome-35fbd36e80d588a060f44f93185fecb88b8f167c.zip |
Add kroc 1.4.0, the Kent Retargettable occam-pi Compiler.
Diffstat (limited to 'lang')
-rw-r--r-- | lang/Makefile | 1 | ||||
-rw-r--r-- | lang/kroc/Makefile | 68 | ||||
-rw-r--r-- | lang/kroc/distinfo | 3 | ||||
-rw-r--r-- | lang/kroc/files/patch-build | 25 | ||||
-rw-r--r-- | lang/kroc/files/patch-src__ccsp-1.6__common__rtsmain.c | 21 | ||||
-rw-r--r-- | lang/kroc/files/patch-src__kroc-1.4__Makefile.in | 11 | ||||
-rw-r--r-- | lang/kroc/files/patch-src__kroc-1.4__kroc.conf.5 | 10 | ||||
-rw-r--r-- | lang/kroc/files/patch-src__kroc-1.4__kroc.in | 22 | ||||
-rw-r--r-- | lang/kroc/pkg-descr | 13 | ||||
-rw-r--r-- | lang/kroc/pkg-plist | 116 |
10 files changed, 290 insertions, 0 deletions
diff --git a/lang/Makefile b/lang/Makefile index 4cf43a389df6..bb985106e76b 100644 --- a/lang/Makefile +++ b/lang/Makefile @@ -122,6 +122,7 @@ SUBDIR += kawa SUBDIR += klogoturtle SUBDIR += klone + SUBDIR += kroc SUBDIR += lafontaine SUBDIR += libjit SUBDIR += librep diff --git a/lang/kroc/Makefile b/lang/kroc/Makefile new file mode 100644 index 000000000000..af4e2536551f --- /dev/null +++ b/lang/kroc/Makefile @@ -0,0 +1,68 @@ +# New ports collection makefile for: kroc +# Date created: 15 January 2006 +# Whom: Tim Bishop <tdb@FreeBSD.org> +# +# $FreeBSD$ +# + +PORTNAME= kroc +PORTVERSION= 1.4.0 +CATEGORIES= lang +MASTER_SITES= http://www.cs.kent.ac.uk/projects/ofa/kroc/ \ + http://www.frmb.org/download/ + +MAINTAINER= tdb@FreeBSD.org +COMMENT= The Kent Retargettable occam-pi Compiler + +BUILD_DEPENDS= bash:${PORTSDIR}/shells/bash + +USE_BZIP2= yes +USE_SDL= sdl +USE_REINPLACE= yes + +MAN1= cputimerutil.1 mkoccdeps.1 occ21.1 kroc.1 kmakef.1 +MAN3= libconvert-inmos.3 libhostio-inmos.3 libmath-inmos.3 \ + libstreamio-inmos.3 libstring-inmos.3 libsock.3 \ + libfile.3 libproc.3 libcourse-cycles.3 libcourse-nets.3 \ + libcourse-utils.3 libsdlraster.3 +MAN5= kroc.conf.5 + +FAKEDIR= ${WRKDIR}/fake + +RE_FILES= build src/ccsp-1.6/common/rtsmain.c \ + src/kroc-1.4/kroc.in src/kroc-1.4/kroc.conf.5 + +post-patch: +.for i in ${RE_FILES} + @${REINPLACE_CMD} \ + -e 's|%%PREFIX%%|${PREFIX}|' \ + -e 's|%%FAKEDIR%%|${FAKEDIR}|' \ + ${WRKSRC}/$i +.endfor + +# Path options to build are inconsistent +do-build: + cd ${WRKSRC} && \ + SDL_CONFIG=${SDL_CONFIG} \ + ./build \ + --prefix=${FAKEDIR} \ + --configdir=${FAKEDIR}/etc \ + --mandir=/man + +FAKEDIR_FILES= bin/kroc etc/kroc.conf + +pre-install: +.ifdef(NOPORTDOCS) + @cd ${FAKEDIR} && ${RM} -Rf share/kroc/doc +.endif +.for i in ${FAKEDIR_FILES} + @${REINPLACE_CMD} \ + -e 's|${FAKEDIR}|${PREFIX}|' \ + ${FAKEDIR}/$i + @${RM} ${FAKEDIR}/$i.bak +.endfor + +do-install: + cd ${FAKEDIR} && ${TAR} -cf - . | ${TAR} -xf - -C ${PREFIX} + +.include <bsd.port.mk> diff --git a/lang/kroc/distinfo b/lang/kroc/distinfo new file mode 100644 index 000000000000..a66e6e3ca896 --- /dev/null +++ b/lang/kroc/distinfo @@ -0,0 +1,3 @@ +MD5 (kroc-1.4.0.tar.bz2) = 19201dd8c657ec8e282a22bc98572fbf +SHA256 (kroc-1.4.0.tar.bz2) = 9da66e581978dfa27abb237bc1caa0b20c677e265d9818ca793905fdce095629 +SIZE (kroc-1.4.0.tar.bz2) = 4401164 diff --git a/lang/kroc/files/patch-build b/lang/kroc/files/patch-build new file mode 100644 index 000000000000..792ff5ea32fd --- /dev/null +++ b/lang/kroc/files/patch-build @@ -0,0 +1,25 @@ +--- ./build.orig Sat Jan 14 17:08:23 2006 ++++ ./build Sun Jan 15 13:54:53 2006 +@@ -1905,18 +1905,14 @@ + if [ "$HAVE_CPUTIMERS_SUPPORT" != "" ]; then + # if we can, put kroc_clock in etc + CAN_WRITE_ETC= +- if [ -w /etc ] || [ -w /etc/kroc_clock ]; then ++ if [ -w %%FAKEDIR%%/etc ] || [ -w %%FAKEDIR%%/etc/kroc_clock ]; then + CAN_WRITE_ETC=1 + fi + + if [ "$CAN_WRITE_ETC" = "1" ]; then +- printf '%s: putting CPU clock speed in /etc/kroc_clock\n' "$0" | tee -a "$DUMPOUT" +- cputimerutil > /etc/kroc_clock +- KROC_CLOCK_FILE=/etc/kroc_clock +- else +- printf '%s: putting CPU clock speed in %s/.kroc_clock\n' "$0" "$HOME" | tee -a "$DUMPOUT" +- cputimerutil > "$HOME"/.kroc_clock +- KROC_CLOCK_FILE="$HOME"/.kroc_clock ++ printf '%s: putting CPU clock speed in %%FAKEDIR%%/etc/kroc_clock\n' "$0" | tee -a "$DUMPOUT" ++ cputimerutil > %%FAKEDIR%%/etc/kroc_clock ++ KROC_CLOCK_FILE=%%FAKEDIR%%/etc/kroc_clock + fi + fi + ;; diff --git a/lang/kroc/files/patch-src__ccsp-1.6__common__rtsmain.c b/lang/kroc/files/patch-src__ccsp-1.6__common__rtsmain.c new file mode 100644 index 000000000000..ce352ca0e9a8 --- /dev/null +++ b/lang/kroc/files/patch-src__ccsp-1.6__common__rtsmain.c @@ -0,0 +1,21 @@ +--- ./src/ccsp-1.6/common/rtsmain.c.orig Mon Oct 24 01:10:31 2005 ++++ ./src/ccsp-1.6/common/rtsmain.c Sun Jan 15 13:56:15 2006 +@@ -256,6 +256,9 @@ + if (!fp) { + fp = fopen ("/etc/kroc_clock", "r"); + } ++ if (!fp) { ++ fp = fopen ("%%PREFIX%%/etc/kroc_clock", "r"); ++ } + if (fp) { + if (fscanf (fp, "%lf", &cpumhz) != 1) { + fprintf (stderr, "KRoC: error reading clock speed\n"); +@@ -266,7 +269,7 @@ + fp = fopen("/proc/cpuinfo", "r"); + + if (!fp) { +- fprintf (stderr, "KRoC: unable to find clock file (.kroc_clock, /etc/kroc_clock or /proc/cpuinfo)\n"); ++ fprintf (stderr, "KRoC: unable to find clock file (.kroc_clock, /etc/kroc_clock, %%PREFIX%%/etc/kroc_clock or /proc/cpuinfo)\n"); + restore_tty_state (); + exit (1); + } diff --git a/lang/kroc/files/patch-src__kroc-1.4__Makefile.in b/lang/kroc/files/patch-src__kroc-1.4__Makefile.in new file mode 100644 index 000000000000..d452031349a7 --- /dev/null +++ b/lang/kroc/files/patch-src__kroc-1.4__Makefile.in @@ -0,0 +1,11 @@ +--- ./src/kroc-1.4/Makefile.in.orig Thu Jan 5 00:11:51 2006 ++++ ./src/kroc-1.4/Makefile.in Sun Jan 15 13:54:00 2006 +@@ -181,7 +181,7 @@ + target_os = @target_os@ + target_vendor = @target_vendor@ + AUTOMAKE_OPTIONS = foreign no-dependencies +-bin_SCRIPTS = kroc kmakef setup.sh setup.csh ++bin_SCRIPTS = kroc kmakef + dist_man1_MANS = kroc.1 kmakef.1 + dist_man5_MANS = kroc.conf.5 + DISTCLEANFILES = kroc setup.sh setup.csh kroc.conf diff --git a/lang/kroc/files/patch-src__kroc-1.4__kroc.conf.5 b/lang/kroc/files/patch-src__kroc-1.4__kroc.conf.5 new file mode 100644 index 000000000000..b8d6af88e1e1 --- /dev/null +++ b/lang/kroc/files/patch-src__kroc-1.4__kroc.conf.5 @@ -0,0 +1,10 @@ +--- ./src/kroc-1.4/kroc.conf.5.orig Sun Jan 15 14:00:02 2006 ++++ ./src/kroc-1.4/kroc.conf.5 Sun Jan 15 14:00:09 2006 +@@ -5,6 +5,7 @@ + .SH SYNOPSIS + .B ~/.kroc.conf + .B /etc/kroc.conf ++.B %%PREFIX%%/etc/kroc.conf + .SH DESCRIPTION + .PP + The kroc.conf file is a shell-script (sourced by the kroc driver program) diff --git a/lang/kroc/files/patch-src__kroc-1.4__kroc.in b/lang/kroc/files/patch-src__kroc-1.4__kroc.in new file mode 100644 index 000000000000..f071df4b28c5 --- /dev/null +++ b/lang/kroc/files/patch-src__kroc-1.4__kroc.in @@ -0,0 +1,22 @@ +--- ./src/kroc-1.4/kroc.in.orig Sun Jan 15 13:59:56 2006 ++++ ./src/kroc-1.4/kroc.in Sun Jan 15 14:00:09 2006 +@@ -66,7 +66,7 @@ + # .kroc.conf + # <config-dir>/{kroc.conf,.kroc.conf} + # /etc/kroc.conf +-# /usr/local/etc/kroc.conf ++# %%PREFIX%%/etc/kroc.conf + # + + if [ -r "./.kroc.conf" ]; then +@@ -77,8 +77,8 @@ + KROCCONFIG="$KROC_CONFIGDIR/.kroc.conf" + elif [ -r "/etc/kroc.conf" ]; then + KROCCONFIG="/etc/kroc.conf" +-elif [ -r "/usr/local/etc/kroc.conf" ]; then +- KROCCONFIG="/usr/local/etc/kroc.conf" ++elif [ -r "%%PREFIX%%/etc/kroc.conf" ]; then ++ KROCCONFIG="%%PREFIX%%/etc/kroc.conf" + fi + + diff --git a/lang/kroc/pkg-descr b/lang/kroc/pkg-descr new file mode 100644 index 000000000000..0e144c98ec6b --- /dev/null +++ b/lang/kroc/pkg-descr @@ -0,0 +1,13 @@ +KRoC, the Kent Retargettable occam-pi Compiler, is a collection +of programs/libraries which facilitates the execution of occam-pi +programs on various platforms. The main components are: + + * occ21, the Inmos occam compiler + * tranx86, a translator from extended transputer code (ETC) to + intel i386 object code + * CCSP, the run-time kernel, providing the virtual transputer + +As well as these are various libraries, example programs, fun +animations, etc. + +WWW: http://www.cs.kent.ac.uk/projects/ofa/kroc/ diff --git a/lang/kroc/pkg-plist b/lang/kroc/pkg-plist new file mode 100644 index 000000000000..054b4dd2a866 --- /dev/null +++ b/lang/kroc/pkg-plist @@ -0,0 +1,116 @@ +@comment $FreeBSD$ +bin/cputimerutil +bin/ilibr +bin/kmakef +bin/kroc +bin/mkoccdeps +bin/occ21 +bin/tranx86 +etc/kroc.conf +etc/kroc_clock +include/kroc/cifccsp.h +include/kroc/dmem_if.h +include/kroc/mobproc.h +include/kroc/spunixhdr.h +include/kroc/typedesc.h +include/kroc/udc.h +lib/kroc/libcif.so +lib/kroc/libconvert.so +lib/kroc/libcourse.so +lib/kroc/libcspdrv.so +lib/kroc/libdblmath.so +lib/kroc/libfile.so +lib/kroc/libhostio.so +lib/kroc/libhostsp.so +lib/kroc/libhttp.so +lib/kroc/libkroc.so +lib/kroc/liboccam8.so +lib/kroc/liboccamutl.so +lib/kroc/libproc.so +lib/kroc/libsdlraster.so +lib/kroc/libsnglmath.so +lib/kroc/libsock.so +lib/kroc/libss.so +lib/kroc/libstream.so +lib/kroc/libstring.so +lib/kroc/libudc.so +%%DATADIR%%/vtinclude/barrier.inc +%%DATADIR%%/vtinclude/bucket.inc +%%DATADIR%%/vtinclude/cifccsp.inc +%%DATADIR%%/vtinclude/consts.inc +%%DATADIR%%/vtinclude/crew.inc +%%DATADIR%%/vtinclude/cspdrvlib.inc +%%DATADIR%%/vtinclude/filelib.inc +%%DATADIR%%/vtinclude/hostio.inc +%%DATADIR%%/vtinclude/httplib.inc +%%DATADIR%%/vtinclude/mathhdr.inc +%%DATADIR%%/vtinclude/mathvals.inc +%%DATADIR%%/vtinclude/proclib.inc +%%DATADIR%%/vtinclude/sdlraster.inc +%%DATADIR%%/vtinclude/semaphore.inc +%%DATADIR%%/vtinclude/shared_screen.inc +%%DATADIR%%/vtinclude/socklib.inc +%%DATADIR%%/vtinclude/udc.inc +%%DATADIR%%/vtlib/convert.lib +%%DATADIR%%/vtlib/course.lib +%%DATADIR%%/vtlib/cspdrv.lib +%%DATADIR%%/vtlib/dblmath.lib +%%DATADIR%%/vtlib/file.lib +%%DATADIR%%/vtlib/hostio.lib +%%DATADIR%%/vtlib/hostsp.lib +%%DATADIR%%/vtlib/http.lib +%%DATADIR%%/vtlib/occam8.lib +%%DATADIR%%/vtlib/occamutl.lib +%%DATADIR%%/vtlib/proc.lib +%%DATADIR%%/vtlib/sdlraster.lib +%%DATADIR%%/vtlib/snglmath.lib +%%DATADIR%%/vtlib/sock.lib +%%DATADIR%%/vtlib/ss.lib +%%DATADIR%%/vtlib/stream.lib +%%DATADIR%%/vtlib/string.lib +%%DATADIR%%/vtlib/udc.lib +%%PORTDOCS%%%%DATADIR%%/doc/html/kroc-faq.html +%%PORTDOCS%%%%DATADIR%%/doc/html/occ21-extensions.html +%%PORTDOCS%%%%DATADIR%%/doc/html/udo.html +%%PORTDOCS%%%%DATADIR%%/doc/lib/blackboard.inc +%%PORTDOCS%%%%DATADIR%%/doc/lib/college.lbb +%%PORTDOCS%%%%DATADIR%%/doc/lib/control_info.inc +%%PORTDOCS%%%%DATADIR%%/doc/lib/controller.occ +%%PORTDOCS%%%%DATADIR%%/doc/lib/crew_test.occ +%%PORTDOCS%%%%DATADIR%%/doc/lib/display.inc +%%PORTDOCS%%%%DATADIR%%/doc/lib/display.occ +%%PORTDOCS%%%%DATADIR%%/doc/lib/philosopher.occ +%%PORTDOCS%%%%DATADIR%%/doc/lib/timekeeper.occ +%%PORTDOCS%%%%DATADIR%%/doc/ps/blocking-native.ps +%%PORTDOCS%%%%DATADIR%%/doc/ps/bsclib.ps +%%PORTDOCS%%%%DATADIR%%/doc/ps/native-call.ps +%%PORTDOCS%%%%DATADIR%%/doc/ps/o2cl.ps +%%PORTDOCS%%%%DATADIR%%/doc/ps/udc.ps +%%PORTDOCS%%%%DATADIR%%/doc/ps/udo.ps +%%PORTDOCS%%%%DATADIR%%/doc/sc/blackboard.inc +%%PORTDOCS%%%%DATADIR%%/doc/sc/control_info.inc +%%PORTDOCS%%%%DATADIR%%/doc/sc/controller.occ +%%PORTDOCS%%%%DATADIR%%/doc/sc/crew_test.occ +%%PORTDOCS%%%%DATADIR%%/doc/sc/display.inc +%%PORTDOCS%%%%DATADIR%%/doc/sc/display.occ +%%PORTDOCS%%%%DATADIR%%/doc/sc/philosopher.occ +%%PORTDOCS%%%%DATADIR%%/doc/sc/timekeeper.occ +%%PORTDOCS%%%%DATADIR%%/doc/txt/AUTHORS +%%PORTDOCS%%%%DATADIR%%/doc/txt/OLD-AUTHORS +%%PORTDOCS%%%%DATADIR%%/doc/txt/about-kroc.txt +%%PORTDOCS%%%%DATADIR%%/doc/txt/essentially-kroc.txt +%%PORTDOCS%%%%DATADIR%%/doc/txt/hlps.txt +%%PORTDOCS%%%%DATADIR%%/doc/txt/hostio.txt +%%PORTDOCS%%%%DATADIR%%/doc/txt/o2cl.txt +%%PORTDOCS%%%%DATADIR%%/doc/txt/pragma.txt +%%PORTDOCS%%@unexec rmdir %D/%%DATADIR%%/doc/txt 2>/dev/null || true +%%PORTDOCS%%@unexec rmdir %D/%%DATADIR%%/doc/sc 2>/dev/null || true +%%PORTDOCS%%@unexec rmdir %D/%%DATADIR%%/doc/ps 2>/dev/null || true +%%PORTDOCS%%@unexec rmdir %D/%%DATADIR%%/doc/lib 2>/dev/null || true +%%PORTDOCS%%@unexec rmdir %D/%%DATADIR%%/doc/html 2>/dev/null || true +%%PORTDOCS%%@unexec rmdir %D/%%DATADIR%%/doc 2>/dev/null || true +@unexec rmdir %D/%%DATADIR%%/vtlib 2>/dev/null || true +@unexec rmdir %D/%%DATADIR%%/vtinclude 2>/dev/null || true +@unexec rmdir %D/%%DATADIR%% 2>/dev/null || true +@unexec rmdir %D/lib/kroc 2>/dev/null || true +@unexec rmdir %D/include/kroc 2>/dev/null || true |