aboutsummaryrefslogtreecommitdiff
path: root/development/chicken/chicken.SlackBuild
diff options
context:
space:
mode:
authorErik Falor <ewfalor@gmail.com>2013-10-26 18:54:28 -0500
committerRobby Workman <rworkman@slackbuilds.org>2013-10-27 23:38:56 -0500
commit7009dc6a71a257db0d29bd8ae7d7d3e03c99fc71 (patch)
treed2e027e4f8b47543d0ef8fc9c8a08868e2fbdf1a /development/chicken/chicken.SlackBuild
parent21963f3ca7bca854cc4adc0e7136510cd4db4d5a (diff)
development/chicken: Updated for version 4.8.0.4.
Signed-off-by: Robby Workman <rworkman@slackbuilds.org>
Diffstat (limited to 'development/chicken/chicken.SlackBuild')
-rw-r--r--development/chicken/chicken.SlackBuild27
1 files changed, 22 insertions, 5 deletions
diff --git a/development/chicken/chicken.SlackBuild b/development/chicken/chicken.SlackBuild
index 02a153c2ba7c3..af53a7f16fb66 100644
--- a/development/chicken/chicken.SlackBuild
+++ b/development/chicken/chicken.SlackBuild
@@ -1,12 +1,12 @@
#!/bin/sh
-# Slackware build script for Chicken
+# Slackware build script for Chicken Scheme
-# Written by Patrick Pippen (dabittweiler@gmail.com)
+# Written by Erik Falor (ewfalor@gmail.com)
PRGNAM=chicken
-VERSION=${VERSION:-4.6.0}
-BUILD=${BUILD:-2}
+VERSION=${VERSION:-4.8.0.4}
+BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
# Automatically determine the architecture we're building on:
@@ -59,13 +59,30 @@ for f in defaults.make Makefile.linux rules.make
sed "s,ARCH,zARCH," -i ${f}
done
+# Due to the way Chicken generates C code from Scheme sources, it is expensive
+# to apply a patch to the generated C files. Instead, we first build an
+# unpatched bootstrap Chicken compiler - this will allow us to apply the
+# security patches to the Scheme source code of Chicken itself, allowing us to
+# rebuild Chicken from scratch.
+
+make boot-chicken \
+ C_COMPILER_OPTIMIZATION_OPTIONS="$SLKCFLAGS" \
+ PLATFORM=linux \
+ PREFIX=/usr
+
+# Apply the security patches to Chicken's Scheme sources
+for P in $CWD/patches/* ; do patch -p1 -i $P ; done
+
+# Build Chicken anew using the bootstrapping compiler to generate new C files
+# from our patched code
make \
C_COMPILER_OPTIMIZATION_OPTIONS="$SLKCFLAGS" \
PLATFORM=linux \
PREFIX=/usr \
LIBDIR=/usr/lib${LIBDIRSUFFIX} \
TOPMANDIR=/usr/man \
- DOCDIR=/usr/doc/$PRGNAM-$VERSION
+ DOCDIR=/usr/doc/$PRGNAM-$VERSION \
+ CHICKEN=./chicken-boot
make install \
C_COMPILER_OPTIMIZATION_OPTIONS="$SLKCFLAGS" \