diff options
Diffstat (limited to 'scm.spec')
-rw-r--r-- | scm.spec | 80 |
1 files changed, 49 insertions, 31 deletions
@@ -1,7 +1,9 @@ %define name scm -%define version 5d9 +%define version 5e1 %define release 1 %define implpath %{prefix}/lib/scm +%define slibpath %{prefix}/lib/slib +%define dumparch setarch i386 # rpm seems to require all on one line, bleah. %define features cautious bignums arrays inexact dump dynamic-linking macro engineering-notation @@ -17,8 +19,8 @@ Provides: scm Requires: slib Summary: SCM Scheme implementation. -Source: ftp://swissnet.ai.mit.edu/pub/scm/scm%{version}.zip -URL: http://swissnet.ai.mit.edu/~jaffer/SCM +Source: ftp://swiss.csail.mit.edu/pub/scm/scm%{version}.zip +URL: http://swiss.csail.mit.edu/~jaffer/SCM BuildRoot: %{_tmppath}/%{name}%{version} Prefix: /usr @@ -43,10 +45,10 @@ unzip $RPM_SOURCE_DIR/scm%{version}.zip # SLIB is required to build SCM. if [ -n "$SCHEME_LIBRARY_PATH" ]; then echo using SLIB $SCHEME_LIBRARY_PATH -elif [ -d /usr/share/slib ]; then - export SCHEME_LIBRARY_PATH=/usr/share/slib/ -elif [ -d /usr/lib/slib ]; then - export SCHEME_LIBRARY_PATH=/usr/lib/slib/ +elif [ -d %{slibpath} ]; then + export SCHEME_LIBRARY_PATH=%{slibpath}/ +elif [ -d %{prefix}/share/slib ]; then + export SCHEME_LIBRARY_PATH=%{prefix}/share/slib/ fi make scmlit make clean @@ -59,11 +61,20 @@ make check # Build dlls make x.so -./build -h system -F curses -t dll --compiler-options="-O3" -./build -h system -t dll -c sc2.c rgx.c record.c gsubr.c ioext.c posix.c \ - unix.c socket.c ramap.c --compiler-options="-O3" -./build -h system -F edit-line -t dll --compiler-options="-O3" -./build -h system -F x -t dll --compiler-options="-O3" +./build -h system -t dll -F curses --compiler-options="-O3" +./build -h system -t dll -c differ.c --compiler-options="-O3" +./build -h system -t dll -c sc2.c --compiler-options="-O3" +./build -h system -t dll -c rgx.c --compiler-options="-O3" +./build -h system -t dll -c record.c --compiler-options="-O3" +./build -h system -t dll -c gsubr.c --compiler-options="-O3" +./build -h system -t dll -c ioext.c --compiler-options="-O3" +./build -h system -t dll -c posix.c --compiler-options="-O3" +./build -h system -t dll -c unix.c --compiler-options="-O3" +./build -h system -t dll -c socket.c --compiler-options="-O3" +./build -h system -t dll -c ramap.c --compiler-options="-O3" +./build -h system -t dll -c byte.c --compiler-options="-O3" +./build -h system -t dll -F edit-line --compiler-options="-O3" +./build -h system -t dll -F x --compiler-options="-O3" # Build libscm.a static library ./build -h system -F cautious bignums arrays inexact dynamic-linking -t lib \ @@ -78,9 +89,9 @@ make prefix=${RPM_BUILD_ROOT}%{prefix}/ installlib rm -f ${RPM_BUILD_ROOT}%{prefix}/bin/scm cp udscm5 ${RPM_BUILD_ROOT}%{prefix}/bin/ -# Assume SLIB is in /usr/share/slib, as installed by the slib rpm. +# Assume SLIB is in %{slibpath}, as installed by the slib rpm. cat > ${RPM_BUILD_ROOT}%{prefix}/lib/scm/require.scm <<EOF -(set! library-vicinity (lambda () "%{prefix}/share/slib/")) +(set! library-vicinity (lambda () "%{slibpath}/")) EOF mkdir -p ${RPM_BUILD_ROOT}%{prefix}/info/ @@ -91,13 +102,13 @@ cp *.info.gz ${RPM_BUILD_ROOT}%{prefix}/info/ rm -rf $RPM_BUILD_ROOT %post -/sbin/install-info /usr/info/scm.info.gz /usr/info/dir -/sbin/install-info /usr/info/hobbit.info.gz /usr/info/dir -/sbin/install-info /usr/info/Xlibscm.info.gz /usr/info/dir -echo "(quit)" | %{prefix}/bin/udscm5 -no-init-file -r5 -o %{prefix}/bin/scm -ln -s %{prefix}/bin/scm /usr/local/bin/scm -ln -s %{prefix}/lib/scm /usr/local/lib/ -/usr/bin/scm -c "(require 'new-catalog)" +/sbin/install-info %{prefix}/info/scm.info.gz %{prefix}/info/dir +/sbin/install-info %{prefix}/info/hobbit.info.gz %{prefix}/info/dir +/sbin/install-info %{prefix}/info/Xlibscm.info.gz %{prefix}/info/dir +echo "(quit)" | %{dumparch} %{prefix}/bin/udscm5 -no-init-file -r5 -o %{prefix}/bin/scm +ln -s %{prefix}/bin/scm %{prefix}/local/bin/scm +ln -s %{prefix}/lib/scm %{prefix}/local/lib/ +%{prefix}/bin/scm -c "(require 'new-catalog)" %verifyscript cp -f %{prefix}/lib/scm/r4rstest.scm /tmp/ @@ -106,13 +117,13 @@ cp -f %{prefix}/lib/scm/r4rstest.scm /tmp/ %preun rm -f %{prefix}/lib/scm/slibcat %{prefix}/lib/scm/implcat -if [ -L /usr/local/bin/scm ] && \ - ls -l /usr/local/bin/scm | grep -q "> %{prefix}/bin/scm"; then - rm -f /usr/local/bin/scm +if [ -L %{prefix}/local/bin/scm ] && \ + ls -l %{prefix}/local/bin/scm | grep -q "> %{prefix}/bin/scm"; then + rm -f %{prefix}/local/bin/scm fi -if [ -L /usr/local/lib/scm ] && \ - ls -l /usr/local/lib/scm | grep -q "> %{prefix}/lib/scm"; then - rm -f /usr/local/lib/scm +if [ -L %{prefix}/local/lib/scm ] && \ + ls -l %{prefix}/local/lib/scm | grep -q "> %{prefix}/lib/scm"; then + rm -f %{prefix}/local/lib/scm fi rm -f %{prefix}/bin/scm @@ -149,16 +160,23 @@ rm -f %{prefix}/bin/scm %{prefix}/lib/scm/build %{prefix}/lib/scm/Iedline.scm %{prefix}/lib/scm/edline.so +%{prefix}/lib/scm/Idiffer.scm +%{prefix}/lib/scm/differ.so %{prefix}/lib/scm/x.so %{prefix}/lib/scm/xevent.scm %{prefix}/lib/scm/xatoms.scm %{prefix}/lib/scm/x11.scm %{prefix}/lib/scm/keysymdef.scm %{prefix}/lib/scm/r4rstest.scm -/usr/info/Xlibscm.info.gz -/usr/info/hobbit.info.gz -/usr/info/scm.info.gz -/usr/man/man1/scm.1.gz +%{prefix}/lib/scm/byte.so +%{prefix}/lib/scm/db.so +%{prefix}/lib/scm/wbtab.scm +%{prefix}/lib/scm/rwb-isam.scm +%{prefix}/lib/scm/COPYING +%{prefix}/info/Xlibscm.info.gz +%{prefix}/info/hobbit.info.gz +%{prefix}/info/scm.info.gz +%{prefix}/man/man1/scm.1.gz %{prefix}/lib/libscm.a %{prefix}/include/scm.h |