tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
lol
0
fork
atom
overview
issues
pulls
pipelines
z3: use python2
Frederik Rietdijk
9 years ago
8963dae3
6b724f06
+18
-14
2 changed files
expand all
collapse all
unified
split
pkgs
applications
science
logic
z3
default.nix
z3_opt
default.nix
+9
-7
pkgs/applications/science/logic/z3/default.nix
···
1
-
{ stdenv, fetchFromGitHub, python }:
2
3
-
stdenv.mkDerivation rec {
0
0
4
name = "z3-${version}";
5
version = "4.4.1";
6
···
14
buildInputs = [ python ];
15
enableParallelBuilding = true;
16
17
-
configurePhase = "python scripts/mk_make.py --prefix=$out && cd build";
18
19
# z3's install phase is stupid because it tries to calculate the
20
# python package store location itself, meaning it'll attempt to
21
# write files into the nix store, and fail.
22
soext = if stdenv.system == "x86_64-darwin" then ".dylib" else ".so";
23
installPhase = ''
24
-
mkdir -p $out/bin $out/lib/${python.libPrefix}/site-packages $out/include
25
cp ../src/api/z3*.h $out/include
26
cp ../src/api/c++/z3*.h $out/include
27
cp z3 $out/bin
28
cp libz3${soext} $out/lib
29
-
cp libz3${soext} $out/lib/${python.libPrefix}/site-packages
30
-
cp z3*.pyc $out/lib/${python.libPrefix}/site-packages
31
-
cp ../src/api/python/*.py $out/lib/${python.libPrefix}/site-packages
32
'';
33
34
meta = {
···
1
+
{ stdenv, fetchFromGitHub, python2 }:
2
3
+
let
4
+
python = python2;
5
+
in stdenv.mkDerivation rec {
6
name = "z3-${version}";
7
version = "4.4.1";
8
···
16
buildInputs = [ python ];
17
enableParallelBuilding = true;
18
19
+
configurePhase = "${python.interpreter} scripts/mk_make.py --prefix=$out && cd build";
20
21
# z3's install phase is stupid because it tries to calculate the
22
# python package store location itself, meaning it'll attempt to
23
# write files into the nix store, and fail.
24
soext = if stdenv.system == "x86_64-darwin" then ".dylib" else ".so";
25
installPhase = ''
26
+
mkdir -p $out/bin $out/${python.sitePackages} $out/include
27
cp ../src/api/z3*.h $out/include
28
cp ../src/api/c++/z3*.h $out/include
29
cp z3 $out/bin
30
cp libz3${soext} $out/lib
31
+
cp libz3${soext} $out/${python.sitePackages}
32
+
cp z3*.pyc $out/${python.sitePackages}
33
+
cp ../src/api/python/*.py $out/${python.sitePackages}
34
'';
35
36
meta = {
+9
-7
pkgs/applications/science/logic/z3_opt/default.nix
···
1
-
{ stdenv, fetchFromGitHub, python }:
2
3
# Copied shamelessly from the normal z3 .nix
4
5
-
stdenv.mkDerivation rec {
0
0
6
name = "z3_opt-${version}";
7
version = "4.3.2";
8
···
16
buildInputs = [ python ];
17
enableParallelBuilding = true;
18
19
-
configurePhase = "python scripts/mk_make.py --prefix=$out && cd build";
20
21
# z3's install phase is stupid because it tries to calculate the
22
# python package store location itself, meaning it'll attempt to
23
# write files into the nix store, and fail.
24
soext = if stdenv.system == "x86_64-darwin" then ".dylib" else ".so";
25
installPhase = ''
26
-
mkdir -p $out/bin $out/lib/${python.libPrefix}/site-packages $out/include
27
cp ../src/api/z3*.h $out/include
28
cp ../src/api/c++/z3*.h $out/include
29
cp z3 $out/bin
30
cp libz3${soext} $out/lib
31
-
cp libz3${soext} $out/lib/${python.libPrefix}/site-packages
32
-
cp z3*.pyc $out/lib/${python.libPrefix}/site-packages
33
-
cp ../src/api/python/*.py $out/lib/${python.libPrefix}/site-packages
34
'';
35
36
meta = {
···
1
+
{ stdenv, fetchFromGitHub, python2 }:
2
3
# Copied shamelessly from the normal z3 .nix
4
5
+
let
6
+
python = python2;
7
+
in stdenv.mkDerivation rec {
8
name = "z3_opt-${version}";
9
version = "4.3.2";
10
···
18
buildInputs = [ python ];
19
enableParallelBuilding = true;
20
21
+
configurePhase = "${python.interpreter} scripts/mk_make.py --prefix=$out && cd build";
22
23
# z3's install phase is stupid because it tries to calculate the
24
# python package store location itself, meaning it'll attempt to
25
# write files into the nix store, and fail.
26
soext = if stdenv.system == "x86_64-darwin" then ".dylib" else ".so";
27
installPhase = ''
28
+
mkdir -p $out/bin $out/${python.sitePackages} $out/include
29
cp ../src/api/z3*.h $out/include
30
cp ../src/api/c++/z3*.h $out/include
31
cp z3 $out/bin
32
cp libz3${soext} $out/lib
33
+
cp libz3${soext} $out/${python.sitePackages}
34
+
cp z3*.pyc $out/${python.sitePackages}
35
+
cp ../src/api/python/*.py $out/${python.sitePackages}
36
'';
37
38
meta = {