2009-05-31 08:07:25 +02:00
|
|
|
a :
|
|
|
|
let
|
|
|
|
fetchurl = a.fetchurl;
|
2012-11-04 20:52:19 +01:00
|
|
|
s= # Generated upstream information
|
|
|
|
rec {
|
|
|
|
baseName="sbcl";
|
2014-03-08 18:06:36 +01:00
|
|
|
version="1.1.16";
|
2013-01-06 22:35:44 +01:00
|
|
|
name="${baseName}-${version}";
|
2014-03-08 18:06:36 +01:00
|
|
|
hash="04631klj02crs82b1i21rpddcgh9x6nnarj5avavy9c7zgvr8cnw";
|
|
|
|
url="mirror://sourceforge/project/sbcl/sbcl/1.1.16/sbcl-1.1.16-source.tar.bz2";
|
|
|
|
sha256="04631klj02crs82b1i21rpddcgh9x6nnarj5avavy9c7zgvr8cnw";
|
2012-11-04 20:52:19 +01:00
|
|
|
};
|
2009-05-31 08:07:25 +02:00
|
|
|
buildInputs = with a; [
|
|
|
|
clisp makeWrapper
|
|
|
|
];
|
|
|
|
in
|
|
|
|
rec {
|
2009-11-06 00:30:23 +01:00
|
|
|
src = a.fetchUrlFromSrcInfo s;
|
2009-05-31 08:07:25 +02:00
|
|
|
|
|
|
|
inherit buildInputs;
|
|
|
|
configureFlags = [];
|
|
|
|
|
|
|
|
/* doConfigure should be removed if not needed */
|
2013-02-24 18:20:57 +01:00
|
|
|
phaseNames = ["setVars" "doFixNewer" "doFixTests" "setVersion" "doPatch" "doBuild" "doInstall" "doWrap"];
|
|
|
|
|
2009-05-31 08:07:25 +02:00
|
|
|
setVars = a.fullDepEntry (''
|
|
|
|
export INSTALL_ROOT=$out
|
2010-08-02 13:37:23 +02:00
|
|
|
mkdir test-home
|
|
|
|
export HOME=$PWD/test-home
|
2009-05-31 08:07:25 +02:00
|
|
|
'') ["minInit"];
|
|
|
|
|
2009-06-03 09:07:01 +02:00
|
|
|
setVersion = a.fullDepEntry (''
|
2009-11-06 00:30:23 +01:00
|
|
|
echo '"${s.version}.nixos"' > version.lisp-expr
|
2009-06-03 09:07:01 +02:00
|
|
|
echo "
|
|
|
|
(lambda (features)
|
|
|
|
(flet ((enable (x)
|
|
|
|
(pushnew x features))
|
|
|
|
(disable (x)
|
|
|
|
(setf features (remove x features))))
|
|
|
|
(enable :sb-thread))) " > customize-target-features.lisp
|
|
|
|
'') ["minInit" "doUnpack"];
|
|
|
|
|
2009-07-07 16:50:37 +02:00
|
|
|
/* SBCL checks whether files are up-to-date in many places.. Unfortunately, same timestamp
|
|
|
|
is not good enought
|
|
|
|
*/
|
2009-06-03 09:07:01 +02:00
|
|
|
doFixNewer = a.fullDepEntry(''
|
2010-08-02 21:02:47 +02:00
|
|
|
pwd
|
2009-08-10 09:14:28 +02:00
|
|
|
|
2009-06-03 09:07:01 +02:00
|
|
|
sed -e 's@> x y@>= x y@' -i contrib/sb-aclrepl/repl.lisp
|
2009-07-07 16:50:37 +02:00
|
|
|
sed -e '/(date)/i((= date 2208988801) 2208988800)' -i contrib/asdf/asdf.lisp
|
|
|
|
sed -i src/cold/slam.lisp -e \
|
|
|
|
'/file-write-date input/a)'
|
|
|
|
sed -i src/cold/slam.lisp -e \
|
|
|
|
'/file-write-date output/i(or (and (= 2208988801 (file-write-date output)) (= 2208988801 (file-write-date input)))'
|
|
|
|
sed -i src/code/target-load.lisp -e \
|
|
|
|
'/date defaulted-fasl/a)'
|
|
|
|
sed -i src/code/target-load.lisp -e \
|
|
|
|
'/date defaulted-source/i(or (and (= 2208988801 (file-write-date defaulted-source-truename)) (= 2208988801 (file-write-date defaulted-fasl-truename)))'
|
2009-06-03 09:07:01 +02:00
|
|
|
'') ["minInit" "doUnpack"];
|
|
|
|
|
2009-05-31 08:07:25 +02:00
|
|
|
doWrap = a.fullDepEntry (''
|
|
|
|
wrapProgram "$out/bin/sbcl" --set "SBCL_HOME" "$out/lib/sbcl"
|
|
|
|
'') ["minInit" "addInputs"];
|
|
|
|
|
|
|
|
doFixTests = a.fullDepEntry (''
|
2010-02-17 09:24:02 +01:00
|
|
|
sed -e '/deftest pwent/inil' -i contrib/sb-posix/posix-tests.lisp
|
|
|
|
sed -e '/deftest grent/inil' -i contrib/sb-posix/posix-tests.lisp
|
|
|
|
sed -e '/deftest .*ent.non-existing/,+5d' -i contrib/sb-posix/posix-tests.lisp
|
|
|
|
sed -e '/deftest \(pw\|gr\)ent/,+3d' -i contrib/sb-posix/posix-tests.lisp
|
2010-02-17 11:40:25 +01:00
|
|
|
|
|
|
|
sed -e '5,$d' -i contrib/sb-bsd-sockets/tests.lisp
|
|
|
|
sed -e '5,$d' -i contrib/sb-simple-streams/*test*.lisp
|
2009-05-31 08:07:25 +02:00
|
|
|
'') ["minInit" "doUnpack"];
|
|
|
|
|
|
|
|
doBuild = a.fullDepEntry (''
|
|
|
|
sh make.sh clisp
|
|
|
|
'') ["minInit" "doUnpack" "addInputs"];
|
|
|
|
|
|
|
|
doInstall = a.fullDepEntry (''
|
|
|
|
sh install.sh
|
|
|
|
'') ["doBuild" "minInit" "addInputs"];
|
|
|
|
|
2009-11-06 00:30:23 +01:00
|
|
|
inherit(s) name;
|
2012-11-04 20:52:19 +01:00
|
|
|
inherit(s) version;
|
2009-05-31 08:07:25 +02:00
|
|
|
meta = {
|
|
|
|
description = "Lisp compiler";
|
2009-11-06 00:30:23 +01:00
|
|
|
homepage = "http://www.sbcl.org";
|
|
|
|
license = "bsd";
|
2009-07-07 17:05:15 +02:00
|
|
|
maintainers = [a.lib.maintainers.raskin];
|
2009-11-06 00:30:23 +01:00
|
|
|
platforms = with a.lib.platforms; all;
|
2012-11-04 20:52:19 +01:00
|
|
|
inherit(s) version;
|
2009-05-31 08:07:25 +02:00
|
|
|
};
|
|
|
|
}
|