nixpkgs/pkgs/development/compilers/abcl/default.nix

40 lines
1.3 KiB
Nix
Raw Normal View History

2016-12-13 15:25:04 +00:00
{stdenv, fetchurl, ant, jre, jdk}:
stdenv.mkDerivation rec {
pname = "abcl";
2019-11-25 10:45:31 +00:00
version = "1.6.0";
2016-12-13 15:25:04 +00:00
# or fetchFromGitHub(owner,repo,rev) or fetchgit(rev)
src = fetchurl {
url = "https://common-lisp.net/project/armedbear/releases/${version}/${pname}-src-${version}.tar.gz";
2019-11-25 10:45:31 +00:00
sha256 = "0hvbcsffr8n2xwdixc8wyw1bfl9fxn2gyy0c4nma7j9zbn0wwgw9";
2016-12-13 15:25:04 +00:00
};
configurePhase = ''
mkdir nix-tools
export PATH="$PWD/nix-tools:$PATH"
echo "echo nix-builder.localdomain" > nix-tools/hostname
chmod a+x nix-tools/*
hostname
'';
buildPhase = ''
ant
'';
installPhase = ''
mkdir -p "$out"/{bin,share/doc/abcl,lib/abcl}
cp -r README COPYING CHANGES examples/ "$out/share/doc/abcl/"
cp -r dist/*.jar contrib/ "$out/lib/abcl/"
echo "#! ${stdenv.shell}" >> "$out/bin/abcl"
echo "${jre}/bin/java -cp \"$out/lib/abcl/abcl.jar:$out/lib/abcl/abcl-contrib.jar:\$CLASSPATH\" org.armedbear.lisp.Main \"\$@\"" >> "$out/bin/abcl"
chmod a+x "$out"/bin/*
'';
buildInputs = [jre ant jdk jre];
meta = {
inherit version;
description = ''A JVM-based Common Lisp implementation'';
license = stdenv.lib.licenses.gpl3 ;
maintainers = [stdenv.lib.maintainers.raskin];
platforms = stdenv.lib.platforms.linux;
homepage = https://common-lisp.net/project/armedbear/;
2016-12-13 15:25:04 +00:00
};
}