summaryrefslogtreecommitdiff
path: root/lang/scm
diff options
context:
space:
mode:
authoragc <agc@pkgsrc.org>2003-10-04 20:31:23 +0000
committeragc <agc@pkgsrc.org>2003-10-04 20:31:23 +0000
commit60447ef6f1c1cbd39c3b9a66eff6f22df075250e (patch)
tree08ce81b6a8e222381b6cc1688cd08b111e34ca6f /lang/scm
parentf9ba2593c6c6be6239470cefa676c037b42b8f71 (diff)
downloadpkgsrc-60447ef6f1c1cbd39c3b9a66eff6f22df075250e.tar.gz
You can never have enough scheme interpreters.
Initial import of scm-5d8 into the NetBSD Packages Collection. Provided in PR 22186 by David S., modified slighly by myself. Scm is a portable R5RS Scheme implementation written in C. * Support for SICP, R2RS, R3RS, and R5RS scheme code. * Is fully documented in TeXinfo form, allowing documentation to be generated in info, TeX, html, nroff, and troff formats. * Supports inexact real and complex numbers, 30 bit immediate integers and large precision integers. * Many Common Lisp functions: logand, logor, logxor, lognot, ash, logcount, integer-length, bit-extract, defmacro, macroexpand, macroexpand1, gentemp, defvar, force-output, software-type, get-decoded-time, get-internal-run-time, get-internal-real-time, delete-file, rename-file, copy-tree, acons, and eval. * Char-code-limit, most-positive-fixnum, most-negative-fixnum, and internal-time-units-per-second constants. *Features* and *load-pathname* variables. * Arrays and bit-vectors. String ports and software emulation ports. I/O extensions providing ANSI C and POSIX.1 facilities. * Interfaces to standard libraries * Available add-on packages including an interactive debugger, database, X-window graphics, BGI graphics, Motif, and Open-Windows packages. * A compiler (HOBBIT) and dynamic linking of compiled modules. * User definable responses to interrupts and errors, Process-syncronization primitives. Setable levels of monitoring and timing information printed interactively (the verbose function).
Diffstat (limited to 'lang/scm')
-rw-r--r--lang/scm/DESCR23
-rw-r--r--lang/scm/Makefile44
-rw-r--r--lang/scm/PLIST35
-rw-r--r--lang/scm/distinfo6
-rw-r--r--lang/scm/files/buildscm.sh23
-rw-r--r--lang/scm/files/require.scm2
-rw-r--r--lang/scm/patches/patch-aa49
-rw-r--r--lang/scm/patches/patch-ab13
8 files changed, 195 insertions, 0 deletions
diff --git a/lang/scm/DESCR b/lang/scm/DESCR
new file mode 100644
index 00000000000..1785b44651c
--- /dev/null
+++ b/lang/scm/DESCR
@@ -0,0 +1,23 @@
+Scm is a portable R5RS Scheme implementation written in C.
+ * Support for SICP, R2RS, R3RS, and R5RS scheme code.
+ * Is fully documented in TeXinfo form, allowing documentation to be
+ generated in info, TeX, html, nroff, and troff formats.
+ * Supports inexact real and complex numbers, 30 bit immediate integers
+ and large precision integers.
+ * Many Common Lisp functions: logand, logor, logxor, lognot, ash,
+ logcount, integer-length, bit-extract, defmacro, macroexpand,
+ macroexpand1, gentemp, defvar, force-output, software-type,
+ get-decoded-time, get-internal-run-time, get-internal-real-time,
+ delete-file, rename-file, copy-tree, acons, and eval.
+ * Char-code-limit, most-positive-fixnum, most-negative-fixnum, and
+ internal-time-units-per-second constants. *Features* and
+ *load-pathname* variables.
+ * Arrays and bit-vectors. String ports and software emulation ports.
+ I/O extensions providing ANSI C and POSIX.1 facilities.
+ * Interfaces to standard libraries
+ * Available add-on packages including an interactive debugger, database,
+ X-window graphics, BGI graphics, Motif, and Open-Windows packages.
+ * A compiler (HOBBIT) and dynamic linking of compiled modules.
+ * User definable responses to interrupts and errors,
+ Process-syncronization primitives. Setable levels of monitoring
+ and timing information printed interactively (the verbose function).
diff --git a/lang/scm/Makefile b/lang/scm/Makefile
new file mode 100644
index 00000000000..3adae16c8b5
--- /dev/null
+++ b/lang/scm/Makefile
@@ -0,0 +1,44 @@
+# $NetBSD: Makefile,v 1.1.1.1 2003/10/04 20:31:23 agc Exp $
+#
+
+DISTNAME= scm5d8
+PKGNAME= scm-5d8
+CATEGORIES= lang
+MASTER_SITES= http://swissnet.ai.mit.edu/ftpdir/scm/
+EXTRACT_SUFX= .zip
+
+MAINTAINER= davids@idiom.com
+HOMEPAGE= http://www.swiss.ai.mit.edu/~jaffer/SCM.html
+COMMENT= Portable scheme interpreter
+
+DEPENDS+= slib>=2.4.6:../../devel/slib
+
+USE_GMAKE= # defined
+USE_X11= # defined
+
+WRKSRC= ${WRKDIR}/scm
+
+ALL_TARGET= scmlit libscm.a
+INSTALL_TARGET= install installlib
+
+INFO_FILES= scm.info hobbit.info Xlibscm.info
+
+post-patch:
+ ${SED} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
+ < ${FILESDIR}/require.scm > ${WRKSRC}/require.scm
+
+post-build:
+ ${CAT} ${FILESDIR}/buildscm.sh \
+ | ${SED} -e 's|%%PREFIX%%|${PREFIX}|g' \
+ | ${SED} -e 's|%%LOCALBASE%%|${LOCALBASE}|g' \
+ > ${WRKSRC}/buildscm.sh
+ cd ${WRKSRC} && ${SH} ./buildscm.sh
+
+post-install:
+ ${INSTALL_DATA} ${WRKSRC}/slibcat ${PREFIX}/share/scm
+ for f in ${INFO_FILES}; do \
+ ${INSTALL_DATA} ${WRKSRC}/$$f ${PREFIX}/info; \
+ done
+
+.include "../../devel/ncurses/buildlink2.mk"
+.include "../../mk/bsd.pkg.mk"
diff --git a/lang/scm/PLIST b/lang/scm/PLIST
new file mode 100644
index 00000000000..9e005efa80b
--- /dev/null
+++ b/lang/scm/PLIST
@@ -0,0 +1,35 @@
+@comment $NetBSD: PLIST,v 1.1.1.1 2003/10/04 20:31:23 agc Exp $
+bin/scm
+bin/scmlit
+include/patchlvl.h
+include/scm.h
+include/scmfig.h
+include/scmflags.h
+include/scmhob.h
+info/Xlibscm.info
+info/hobbit.info
+info/scm.info
+lib/libscm.a
+man/man1/scm.1
+share/scm/COPYING
+share/scm/Iedline.scm
+share/scm/Init5d8.scm
+share/scm/Link.scm
+share/scm/Macexp.scm
+share/scm/Macro.scm
+share/scm/Transcen.scm
+share/scm/Tscript.scm
+share/scm/build
+share/scm/build.scm
+share/scm/compile.scm
+share/scm/hobbit.scm
+share/scm/keysymdef.scm
+share/scm/mkimpcat.scm
+share/scm/r4rstest.scm
+share/scm/require.scm
+share/scm/scmhob.scm
+share/scm/slibcat
+share/scm/x11.scm
+share/scm/xatoms.scm
+share/scm/xevent.scm
+@dirrm share/scm
diff --git a/lang/scm/distinfo b/lang/scm/distinfo
new file mode 100644
index 00000000000..80a701f270c
--- /dev/null
+++ b/lang/scm/distinfo
@@ -0,0 +1,6 @@
+$NetBSD: distinfo,v 1.1.1.1 2003/10/04 20:31:23 agc Exp $
+
+SHA1 (scm5d8.zip) = cf2b6120d5096e7f4cb0c8fffb9d83cc6022216f
+Size (scm5d8.zip) = 835040 bytes
+SHA1 (patch-aa) = 8a47d342097d3030f7f31d0248b2f31a89b048ff
+SHA1 (patch-ab) = d6c19134cb99d6f4d847ff53c2d73f7ba847becd
diff --git a/lang/scm/files/buildscm.sh b/lang/scm/files/buildscm.sh
new file mode 100644
index 00000000000..88c4e3c23bf
--- /dev/null
+++ b/lang/scm/files/buildscm.sh
@@ -0,0 +1,23 @@
+#! /bin/sh
+# unix (unix) script created by SLIB/batch Thu Jul 17 21:20:04 2003
+# ================ Write file with C defines
+rm -f scmflags.h
+echo '#define IMPLINIT "%%PREFIX%%/share/scm/Init5d8.scm"'>>scmflags.h
+echo '#define INITS init_sc2();init_ramap();init_gsubr();init_ioext();init_posix();init_record();init_rgx();init_socket();init_unix();'>>scmflags.h
+echo '#define COMPILED_INITS init_edline();'>>scmflags.h
+echo '#define ARRAYS'>>scmflags.h
+echo '#define BIGNUMS'>>scmflags.h
+echo '#define CAUTIOUS'>>scmflags.h
+echo '#define CHEAP_CONTINUATIONS'>>scmflags.h
+echo '#define CAN_DUMP'>>scmflags.h
+echo '#define ENGNOT'>>scmflags.h
+echo '#define FLOATS'>>scmflags.h
+echo '#define MACRO'>>scmflags.h
+echo '#define CCLO'>>scmflags.h
+echo '#define TICKS'>>scmflags.h
+# ================ Compile C source files
+cc -O -c -Wall sc2.c ramap.c dynl.c edline.c gsubr.c ioext.c posix.c record.c rgx.c socket.c unix.c continue.c scm.c scmmain.c findexec.c script.c time.c repl.c scl.c eval.c sys.c subr.c debug.c unif.c rope.c unexelf.c
+# ================ Link C object files
+mv -f scm scm~
+cc -o scm sc2.o ramap.o dynl.o edline.o gsubr.o ioext.o posix.o record.o rgx.o socket.o unix.o continue.o scm.o scmmain.o findexec.o script.o time.o repl.o scl.o eval.o sys.o subr.o debug.o unif.o rope.o unexelf.o -lm -ledit -ltermcap
+
diff --git a/lang/scm/files/require.scm b/lang/scm/files/require.scm
new file mode 100644
index 00000000000..537e08ee4a0
--- /dev/null
+++ b/lang/scm/files/require.scm
@@ -0,0 +1,2 @@
+(define (library-vicinity) "%%LOCALBASE%%/share/slib/")
+(load (in-vicinity (library-vicinity) "require"))
diff --git a/lang/scm/patches/patch-aa b/lang/scm/patches/patch-aa
new file mode 100644
index 00000000000..0d45bffe3f3
--- /dev/null
+++ b/lang/scm/patches/patch-aa
@@ -0,0 +1,49 @@
+$NetBSD: patch-aa,v 1.1.1.1 2003/10/04 20:31:23 agc Exp $
+
+--- Makefile.orig 2003-06-17 20:25:30.000000000 -0700
++++ Makefile
+@@ -92,7 +92,9 @@ ofiles = scm.o time.o repl.o scl.o sys.o
+ # ramap.o
+ ifiles = Init$(VERSION).scm Transcen.scm Link.scm Macro.scm Macexp.scm \
+ Tscript.scm compile.scm
+-hobfiles = hobbit.scm scmhob.scm scmhob.h
++hobsrcs = hobbit.scm scmhob.scm
++hobincs = scmhob.h
++hobfiles = $(hobsrcs) $(hobincs)
+ xafiles = xatoms.scm x11.scm xevent.scm keysymdef.scm
+ xfiles = x.c x.h xgen.scm xevent.h inc2scm $(xafiles)
+
+@@ -341,12 +343,12 @@ $(PREVDOCS)scm.info: srcdir.mk Makefile
+
+ rpm_prefix=/usr/src/redhat/
+
+-prefix = /usr/local/
++prefix = $(PREFIX)/
+ exec_prefix = $(prefix)
+ # directory where `make install' will put executable.
+ bindir = $(exec_prefix)bin/
+ libdir = $(exec_prefix)lib/
+-libscmdir = $(libdir)scm/
++libscmdir = $(prefix)share/scm/
+ # directory where `make install' will put manual page.
+ mandir = $(prefix)man/
+ man1dir = $(mandir)man1/
+@@ -407,15 +409,15 @@ install: scm.1
+ -cp scm.1 $(man1dir)
+ test -d $(libdir) || mkdir $(libdir)
+ test -d $(libscmdir) || mkdir $(libscmdir)
+- -cp $(ifiles) $(hobfiles) COPYING r4rstest.scm $(libscmdir)
++ -cp $(ifiles) $(hobsrcs) COPYING r4rstest.scm $(libscmdir)
+ test -f $(libscmdir)require.scm || \
+ cp requires.scm $(libscmdir)require.scm
+- -cp build build.scm mkimpcat.scm Iedline.scm *.sl *.so patchlvl.h\
++ -cp build build.scm mkimpcat.scm Iedline.scm *.sl *.so \
+ $(xafiles) $(libscmdir)
+
+ installlib:
+ test -d $(includedir) || mkdir $(includedir)
+- cp scm.h scmfig.h scmflags.h $(includedir)
++ cp scm.h scmfig.h scmflags.h patchlvl.h $(hobincs) $(includedir)
+ test -d $(libdir) || mkdir $(libdir)
+ cp libscm.a $(libdir)libscm.a
+
diff --git a/lang/scm/patches/patch-ab b/lang/scm/patches/patch-ab
new file mode 100644
index 00000000000..99548dcf44a
--- /dev/null
+++ b/lang/scm/patches/patch-ab
@@ -0,0 +1,13 @@
+$NetBSD: patch-ab,v 1.1.1.1 2003/10/04 20:31:23 agc Exp $
+
+--- socket.c.orig 2003-01-02 11:44:31.000000000 -0800
++++ socket.c
+@@ -146,7 +146,7 @@ SCM l_hostinfo(name)
+ struct in_addr inad;
+ char **argv;
+ int i = 0;
+-#ifndef linux
++#if !(defined(linux) || defined(__NetBSD__))
+ if UNBNDP(name) {
+ DEFER_INTS;
+ SYSCALL(entry = gethostent(););