nix: streamline packaging
Signed-off-by: NotAShelf <raf@notashelf.dev> Change-Id: I4643ed2c8e6f8ceb5e722612cc67a74e6a6a6964
This commit is contained in:
parent
5df01492ec
commit
4d10074181
1 changed files with 14 additions and 3 deletions
|
|
@ -15,7 +15,7 @@
|
||||||
in
|
in
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
pname = "chroma";
|
pname = "chroma";
|
||||||
version = "1.0.0";
|
version = "1.0.1";
|
||||||
|
|
||||||
src = fs.toSource {
|
src = fs.toSource {
|
||||||
root = s;
|
root = s;
|
||||||
|
|
@ -23,8 +23,11 @@ in
|
||||||
(s + /include)
|
(s + /include)
|
||||||
(s + /protocols)
|
(s + /protocols)
|
||||||
(s + /src)
|
(s + /src)
|
||||||
|
|
||||||
(s + /Makefile)
|
(s + /Makefile)
|
||||||
|
|
||||||
|
# For testing
|
||||||
|
(s + /lib)
|
||||||
|
(s + /tests)
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -49,9 +52,17 @@ in
|
||||||
|
|
||||||
makeFlags = [
|
makeFlags = [
|
||||||
"PREFIX=$(out)"
|
"PREFIX=$(out)"
|
||||||
"SYSTEMD_DIR=$(out)/lib/systemd/system"
|
"SYSTEMD_DIR=$(out)/lib/systemd/system" # FIXME: this is an user service, actually
|
||||||
];
|
];
|
||||||
|
|
||||||
|
checkPhase = ''
|
||||||
|
runHook preCheck
|
||||||
|
|
||||||
|
make test
|
||||||
|
|
||||||
|
runHook postCheck
|
||||||
|
'';
|
||||||
|
|
||||||
postInstall = ''
|
postInstall = ''
|
||||||
install -Dm755 ${../chroma.conf.sample} $out/share/chroma.conf.sample
|
install -Dm755 ${../chroma.conf.sample} $out/share/chroma.conf.sample
|
||||||
'';
|
'';
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue