tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
Update golly
Michael Raskin
11 years ago
9ae10b2c
86772c4e
+30
-48
4 changed files
expand all
collapse all
unified
split
pkgs
applications
science
misc
golly
default.nix
default.upstream
src-for-default.nix
src-info-for-default.nix
+26
-34
pkgs/applications/science/misc/golly/default.nix
···
1
1
-
x@{builderDefsPackage,
2
2
-
wxGTK, perl, python, zlib
3
3
-
, ...}:
4
4
-
builderDefsPackage
5
5
-
(a :
1
1
+
{stdenv, fetchurl, wxGTK, perl, python, zlib}:
6
2
let
7
7
-
s = import ./src-for-default.nix;
8
8
-
helperArgNames = ["builderDefsPackage"] ++
9
9
-
[];
10
10
-
buildInputs = map (n: builtins.getAttr n x)
11
11
-
(builtins.attrNames (builtins.removeAttrs x helperArgNames));
3
3
+
s = # Generated upstream information
4
4
+
rec {
5
5
+
baseName="golly";
6
6
+
version="2.6";
7
7
+
name="${baseName}-${version}";
8
8
+
hash="1n1k3yf23ymlwq4k6p4v2g04qd29pg2rabr4l7m9bj2b2j1zkqhz";
9
9
+
url="mirror://sourceforge/project/golly/golly/golly-2.6/golly-2.6-src.tar.gz";
10
10
+
sha256="1n1k3yf23ymlwq4k6p4v2g04qd29pg2rabr4l7m9bj2b2j1zkqhz";
11
11
+
};
12
12
+
buildInputs = [
13
13
+
wxGTK perl python zlib
14
14
+
];
12
15
in
13
13
-
rec {
14
14
-
src = a.fetchUrlFromSrcInfo s;
15
15
-
16
16
-
inherit (s) name;
16
16
+
stdenv.mkDerivation {
17
17
+
inherit (s) name version;
17
18
inherit buildInputs;
18
18
-
19
19
-
/* doConfigure should be removed if not needed */
20
20
-
phaseNames = ["setVars" "doConfigure" "doMakeInstall"];
21
21
-
setVars = a.noDepEntry ''
22
22
-
export NIX_LDFLAGS="$NIX_LDFLAGS -lperl -L$(echo "${perl}"/lib/perl5/5*/*/CORE)"
23
23
-
pythonLib="$(echo "${python}"/lib/libpython*.so)"
24
24
-
pythonLib="''${pythonLib##*/lib}"
25
25
-
pythonLib="''${pythonLib%%.so}"
26
26
-
export NIX_LDFLAGS="$NIX_LDFLAGS -l$pythonLib"
27
27
-
echo "Flags: $NIX_LDFLAGS"
19
19
+
src = fetchurl {
20
20
+
inherit (s) url sha256;
21
21
+
};
22
22
+
preConfigure = ''
23
23
+
cd gui-wx/configure
28
24
'';
29
29
-
30
25
meta = {
26
26
+
inherit (s) version;
31
27
description = "Cellular automata simulation program";
32
32
-
maintainers = with a.lib.maintainers;
33
33
-
[
34
34
-
raskin
35
35
-
];
36
36
-
platforms = with a.lib.platforms;
37
37
-
linux;
38
38
-
license = with a.lib.licenses;
39
39
-
gpl2;
28
28
+
license = stdenv.lib.licenses.gpl2;
29
29
+
maintainers = [stdenv.lib.maintainers.raskin];
30
30
+
platforms = stdenv.lib.platforms.linux;
31
31
+
downloadPage = "http://sourceforge.net/projects/golly/files/golly";
40
32
};
41
41
-
}) x
33
33
+
}
+4
pkgs/applications/science/misc/golly/default.upstream
···
1
1
+
url http://sourceforge.net/projects/golly/files/golly/
2
2
+
version_link '[-][0-9.]+/$'
3
3
+
SF_version_tarball
4
4
+
SF_redirect
-9
pkgs/applications/science/misc/golly/src-for-default.nix
···
1
1
-
rec {
2
2
-
version="2.4";
3
3
-
name="golly-2.4";
4
4
-
hash="06vajm019q4q4wfy6pc1669fbjqdb4jaxcc419bk0vzky40anl9w";
5
5
-
url="mirror://sourceforge/golly/golly-2.4-src.tar.gz";
6
6
-
advertisedUrl="http://downloads.sourceforge.net/project/golly/golly/golly-2.4/golly-2.4-src.tar.gz";
7
7
-
8
8
-
9
9
-
}
-5
pkgs/applications/science/misc/golly/src-info-for-default.nix
···
1
1
-
{
2
2
-
downloadPage = "http://sourceforge.net/projects/golly/files/golly";
3
3
-
method="fetchSFdirs";
4
4
-
fileSuffix="-src.tar.gz";
5
5
-
}