1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-09-11 15:08:33 +01:00

nixpkgs: z3 is now MIT licensed.

It's also been moved to GitHub, meaning we can avoid some of the
hackiness in the original expression. This updates the Git revision, but
only so that it contains the proper license (it's otherwise equivalent
to Z3 v4.3.2)

Also, make sure the python API .py files exist besides the .pyc files.

Signed-off-by: Austin Seipp <aseipp@pobox.com>
This commit is contained in:
Austin Seipp 2015-03-27 17:46:35 -05:00
parent dcde8a967f
commit 75ab87edc8

View file

@ -1,24 +1,20 @@
{ stdenv, fetchurl, python, unzip }:
{ stdenv, fetchFromGitHub, python }:
stdenv.mkDerivation rec {
name = "z3-${version}";
version = "4.3.2";
src = fetchurl {
url = "http://download-codeplex.sec.s-msft.com/Download/SourceControlFileDownload.ashx\?ProjectName\=z3\&changeSetId\=cee7dd39444c9060186df79c2a2c7f8845de415b";
name = "${name}.zip";
sha256 = "0hagy7xm0m52jd6vlrbizkj24mn6c49hkb3r5p66wilvp15ivpbn";
src = fetchFromGitHub {
owner = "Z3Prover";
repo = "z3";
rev = "ac21ffebdf1512da2a77dc46c47bde87cc3850f3";
sha256 = "1y86akhpy41wx3gx7r8gvf7xbax7dj36ikj6gqh5a7p6r6maz9ci";
};
buildInputs = [ python unzip ];
buildInputs = [ python ];
enableParallelBuilding = true;
# The zip file doesn't unpack a directory, just the code itself.
unpackPhase = "mkdir ${name} && cd ${name} && unzip $src";
configurePhase = ''
python scripts/mk_make.py --prefix=$out
cd build
'';
configurePhase = "python scripts/mk_make.py --prefix=$out && cd build";
# z3's install phase is stupid because it tries to calculate the
# python package store location itself, meaning it'll attempt to
@ -32,12 +28,13 @@ stdenv.mkDerivation rec {
cp libz3${soext} $out/lib
cp libz3${soext} $out/lib/${python.libPrefix}/site-packages
cp z3*.pyc $out/lib/${python.libPrefix}/site-packages
cp ../src/api/python/*.py $out/lib/${python.libPrefix}/site-packages
'';
meta = {
description = "A high-performance theorem prover and SMT solver";
homepage = "http://z3.codeplex.com";
license = stdenv.lib.licenses.msrla;
homepage = "http://github.com/Z3Prover/z3";
license = stdenv.lib.licenses.mit;
platforms = stdenv.lib.platforms.unix;
maintainers = [ stdenv.lib.maintainers.thoughtpolice ];
};