22  lib , 
33  stdenv , 
44  fetchurl , 
5+   versionCheckHook , 
56} :
67
78stdenv . mkDerivation { 
89  pname =  "prover9" ; 
9-   version =  "2009-11a " ; 
10+   version =  "2009-11A " ; 
1011
1112  src =  fetchurl { 
1213    url =  "https://www.cs.unm.edu/~mccune/mace4/download/LADR-2009-11A.tar.gz" ; 
13-     sha256 =  "1l2i3d3h5z7nnbzilb6z92r0rbx0kh6yaxn2c5qhn3000xcfsay3 " ; 
14+     hash =  "sha256-wyvtWAcADAtxYcJ25Q2coK8MskjfLBr/svb8AkcbUdA= " ; 
1415  } ; 
1516
1617  hardeningDisable =  [  "format"  ] ; 
@@ -20,31 +21,54 @@ stdenv.mkDerivation {
2021    MV=$(type -tp mv) 
2122    CP=$(type -tp cp) 
2223    for f in Makefile */Makefile; do 
23-       substituteInPlace $f --replace "/bin/rm" "$RM" \ 
24-         --replace "/bin/mv" "$MV" \ 
25-         --replace "/bin/cp" "$CP"; 
24+       substituteInPlace $f --replace-quiet  "/bin/rm" "$RM" \ 
25+         --replace-quiet  "/bin/mv" "$MV" \ 
26+         --replace-quiet  "/bin/cp" "$CP"; 
2627    done 
2728  '' ; 
2829
2930  buildFlags =  [  "all"  ] ; 
3031
31-   checkPhase =  "make test1" ; 
32+   # Fails the build on clang-16 and gcc-14. 
33+   env . NIX_CFLAGS_COMPILE =  "-Wno-error=implicit-int" ; 
34+ 
35+   doCheck =  true ; 
36+   checkPhase =  '' 
37+     runHook preCheck 
38+ 
39+     make test1 
40+     make test2 
41+     make test3 
42+ 
43+     runHook postCheck 
44+   '' ; 
3245
3346  installPhase =  '' 
47+     runHook preInstall 
3448    mkdir -p $out/bin 
35-     cp bin/* $out/bin 
49+     for f in mace4 prover9 fof-prover9 autosketches4 newauto newsax ladr_to_tptp tptp_to_ladr; do 
50+       install -Dm555 bin/$f $out/bin/$f; 
51+     done 
52+     install -Dm644 -t $out/share/man/man1 manpages/*.1 
53+     runHook postInstall 
3654  '' ; 
3755
38-   meta =  with  lib ;  { 
56+   nativeInstallCheckInputs =  [ 
57+     versionCheckHook 
58+   ] ; 
59+   doInstallCheck =  true ; 
60+ 
61+   meta =  { 
3962    homepage =  "https://www.cs.unm.edu/~mccune/mace4/" ; 
40-     license =  licenses . gpl2Only ; 
63+     license =  lib . licenses . gpl2Only ; 
4164    description =  "Automated theorem prover for first-order and equational logic" ; 
4265    longDescription =  '' 
4366      Prover9 is a resolution/paramodulation automated theorem prover 
4467      for first-order and equational logic. Prover9 is a successor of 
4568      the Otter Prover. This is the LADR command-line version. 
4669    '' ; 
47-     platforms =  platforms . linux ; 
70+     mainProgram =  "prover9" ; 
71+     platforms =  lib . platforms . linux ; 
4872    maintainers =  [  ] ; 
4973  } ; 
5074} 
0 commit comments