Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 16.09 68 lines 2.2 kB view raw
1{ stdenv, fetchurl }: 2 3stdenv.mkDerivation rec { 4 name = "gprolog-1.4.4"; 5 6 src = fetchurl { 7 urls = [ 8 "mirror://gnu/gprolog/${name}.tar.gz" 9 "http://www.gprolog.org/${name}.tar.gz" 10 ]; 11 sha256 = "13miyas47bmijmadm68cbvb21n4s156gjafz7kfx9brk9djfkh0q"; 12 }; 13 14 hardeningDisable = stdenv.lib.optional stdenv.isi686 "pic"; 15 16 patchPhase = '' 17 sed -i -e "s|/tmp/make.log|$TMPDIR/make.log|g" src/Pl2Wam/check_boot 18 ''; 19 20 preConfigure = '' 21 cd src 22 configureFlagsArray=( 23 "--with-install-dir=$out" 24 "--without-links-dir" 25 "--with-examples-dir=$out/share/${name}/examples" 26 "--with-doc-dir=$out/share/${name}/doc" 27 ) 28 ''; 29 30 postInstall = '' 31 mv -v $out/[A-Z]* $out/gprolog.ico $out/share/${name}/ 32 ''; 33 34 doCheck = true; 35 36 meta = { 37 homepage = "http://www.gnu.org/software/gprolog/"; 38 description = "GNU Prolog, a free Prolog compiler with constraint solving over finite domains"; 39 license = stdenv.lib.licenses.lgpl3Plus; 40 41 longDescription = '' 42 GNU Prolog is a free Prolog compiler with constraint solving 43 over finite domains developed by Daniel Diaz. 44 45 GNU Prolog accepts Prolog+constraint programs and produces 46 native binaries (like gcc does from a C source). The obtained 47 executable is then stand-alone. The size of this executable can 48 be quite small since GNU Prolog can avoid to link the code of 49 most unused built-in predicates. The performances of GNU Prolog 50 are very encouraging (comparable to commercial systems). 51 52 Beside the native-code compilation, GNU Prolog offers a 53 classical interactive interpreter (top-level) with a debugger. 54 55 The Prolog part conforms to the ISO standard for Prolog with 56 many extensions very useful in practice (global variables, OS 57 interface, sockets,...). 58 59 GNU Prolog also includes an efficient constraint solver over 60 Finite Domains (FD). This opens contraint logic programming to 61 the user combining the power of constraint programming to the 62 declarativity of logic programming. 63 ''; 64 65 maintainers = [ stdenv.lib.maintainers.peti ]; 66 platforms = stdenv.lib.platforms.gnu; 67 }; 68}