2021-02-17 13:28:31 +00:00
|
|
|
{ lib
|
|
|
|
, stdenv
|
2021-01-11 22:08:42 +00:00
|
|
|
, fetchgit
|
|
|
|
, wrapLisp
|
2021-04-11 08:21:35 +01:00
|
|
|
, sbcl_2_0_9
|
2021-01-11 22:08:42 +00:00
|
|
|
, openssl
|
|
|
|
}:
|
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "clpm";
|
2021-02-17 13:28:31 +00:00
|
|
|
version = "0.3.6";
|
2021-01-11 22:08:42 +00:00
|
|
|
|
|
|
|
src = fetchgit {
|
|
|
|
url = "https://gitlab.common-lisp.net/clpm/clpm";
|
|
|
|
rev = "v${version}";
|
|
|
|
fetchSubmodules = true;
|
2021-02-17 13:28:31 +00:00
|
|
|
sha256 = "04w46yhv31p4cfb84b6qvyfw7x5nx6lzyd4yzhd9x6qvb7p5kmfh";
|
2021-01-11 22:08:42 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [
|
2021-04-11 08:21:35 +01:00
|
|
|
(wrapLisp sbcl_2_0_9)
|
2021-01-11 22:08:42 +00:00
|
|
|
openssl
|
|
|
|
];
|
|
|
|
|
|
|
|
buildPhase = ''
|
2021-02-17 13:28:31 +00:00
|
|
|
runHook preBuild
|
|
|
|
|
2021-05-16 23:57:29 +01:00
|
|
|
ln -s ${openssl.out}/lib/libcrypto*${stdenv.hostPlatform.extensions.sharedLibrary}* .
|
|
|
|
ln -s ${openssl.out}/lib/libssl*${stdenv.hostPlatform.extensions.sharedLibrary}* .
|
2021-01-11 22:08:42 +00:00
|
|
|
common-lisp.sh --script scripts/build.lisp
|
2021-02-17 13:28:31 +00:00
|
|
|
|
|
|
|
runHook postBuild
|
2021-01-11 22:08:42 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
2021-02-17 13:28:31 +00:00
|
|
|
runHook preInstall
|
|
|
|
|
2021-01-11 22:08:42 +00:00
|
|
|
INSTALL_ROOT=$out sh install.sh
|
2021-02-17 13:28:31 +00:00
|
|
|
|
|
|
|
runHook postInstall
|
2021-01-11 22:08:42 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
# fixupPhase results in fatal error in SBCL, `Can't find sbcl.core`
|
|
|
|
dontFixup = true;
|
|
|
|
|
2021-01-23 12:26:19 +00:00
|
|
|
meta = with lib; {
|
2021-01-11 22:08:42 +00:00
|
|
|
description = "Common Lisp Package Manager";
|
|
|
|
homepage = "https://www.clpm.dev/";
|
|
|
|
license = licenses.bsd2;
|
|
|
|
maintainers = [ maintainers.petterstorvik ];
|
|
|
|
platforms = platforms.all;
|
|
|
|
};
|
|
|
|
}
|