forked from shuttle-hq/synth
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdefault.nix
46 lines (41 loc) · 832 Bytes
/
default.nix
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
{
naersk
, nix-gitignore
, makeWrapper
, stdenv
, pkgconfig
, sqlite
, openssl
, ncurses6
, libiconv
, darwin
, synthSrc ? null
, release ? true
}:
let
version = "0.5.3";
darwinBuildInputs =
stdenv.lib.optionals stdenv.hostPlatform.isDarwin (with darwin.apple_sdk.frameworks; [
libiconv
IOKit
Security
AppKit
]);
gitignoreSource = filter: src: nix-gitignore.gitignoreSource filter src;
synth = naersk.buildPackage {
name = "synth${suffix}";
inherit version;
src = if synthSrc == null then ./. else synthSrc;
preferLocalBuild = true;
doCheck = true;
inherit release;
buildInputs = [
makeWrapper
pkgconfig
ncurses6.dev
sqlite.dev
openssl.dev
] ++ darwinBuildInputs;
};
suffix = if release then "" else "-debug";
in synth