fastdownward: 2019-05-13 -> 19.12
- Use supplied build.py mechanism instead of working around it - Freeze release location into resulting Python so fast-downward script actually works
This commit is contained in:
parent
1058f8f8cf
commit
af76ba6c57
1 changed files with 15 additions and 8 deletions
|
@ -1,12 +1,13 @@
|
||||||
{ stdenv, lib, fetchhg, cmake, which, python3, osi, cplex }:
|
{ stdenv, lib, fetchhg, cmake, which, python3, osi, cplex }:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
name = "fast-downward-2019-05-13";
|
version = "19.12";
|
||||||
|
pname = "fast-downward";
|
||||||
|
|
||||||
src = fetchhg {
|
src = fetchhg {
|
||||||
url = "http://hg.fast-downward.org/";
|
url = "http://hg.fast-downward.org/";
|
||||||
rev = "090f5df5d84a";
|
rev = "41688a4f16b3";
|
||||||
sha256 = "14pcjz0jfzx5269axg66iq8js7lm2w3cnqrrhhwmz833prjp945g";
|
sha256 = "08m4k1mkx4sz7c2ab7xh7ip6b67zxv7kl68xrvwa83xw1yigqkna";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake which ];
|
nativeBuildInputs = [ cmake which ];
|
||||||
|
@ -17,19 +18,22 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
enableParallelBuilding = true;
|
||||||
|
|
||||||
|
configurePhase = ''
|
||||||
|
python build.py release
|
||||||
|
'';
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
cd src
|
|
||||||
# Needed because the package tries to be too smart.
|
# Needed because the package tries to be too smart.
|
||||||
export CC="$(which $CC)"
|
export CC="$(which $CC)"
|
||||||
export CXX="$(which $CXX)"
|
export CXX="$(which $CXX)"
|
||||||
'';
|
'';
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
install -Dm755 bin/downward $out/libexec/fast-downward/downward
|
install -Dm755 builds/release/bin/downward $out/libexec/fast-downward/downward
|
||||||
cp -r ../translate $out/libexec/fast-downward/
|
cp -r builds/release/bin/translate $out/libexec/fast-downward/
|
||||||
install -Dm755 ../../fast-downward.py $out/bin/fast-downward
|
install -Dm755 fast-downward.py $out/bin/fast-downward
|
||||||
mkdir -p $out/${python3.sitePackages}
|
mkdir -p $out/${python3.sitePackages}
|
||||||
cp -r ../../driver $out/${python3.sitePackages}
|
cp -r driver $out/${python3.sitePackages}
|
||||||
|
|
||||||
wrapPythonProgramsIn $out/bin "$out $pythonPath"
|
wrapPythonProgramsIn $out/bin "$out $pythonPath"
|
||||||
wrapPythonProgramsIn $out/libexec/fast-downward/translate "$out $pythonPath"
|
wrapPythonProgramsIn $out/libexec/fast-downward/translate "$out $pythonPath"
|
||||||
|
@ -43,6 +47,9 @@ stdenv.mkDerivation {
|
||||||
echo "Moving $i to $dest"
|
echo "Moving $i to $dest"
|
||||||
mv "$i" "$dest"
|
mv "$i" "$dest"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
substituteInPlace $out/${python3.sitePackages}/driver/arguments.py \
|
||||||
|
--replace 'args.build = "release"' "args.build = \"$out/libexec/fast-downward\""
|
||||||
'';
|
'';
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
|
|
Loading…
Reference in a new issue