lol

guile 1.8: rename and reformat

+53 -32
+52 -30
pkgs/development/interpreters/guile/1.8.nix
··· 1 - { lib, stdenv, pkgsBuildBuild, buildPackages 2 - , fetchurl, makeWrapper, gawk, pkg-config 3 - , libtool, readline, gmp 1 + { lib 2 + , stdenv 3 + , fetchurl 4 + , buildPackages 5 + , gawk 6 + , gmp 7 + , libtool 8 + , makeWrapper 9 + , pkg-config 10 + , pkgsBuildBuild 11 + , readline 4 12 }: 5 13 6 14 stdenv.mkDerivation rec { 7 - name = "guile-1.8.8"; 15 + pname = "guile"; 16 + version = "1.8.8"; 8 17 9 18 src = fetchurl { 10 - url = "mirror://gnu/guile/${name}.tar.gz"; 19 + url = "mirror://gnu/${pname}/${pname}-${version}.tar.gz"; 11 20 sha256 = "0l200a0v7h8bh0cwz6v7hc13ds39cgqsmfrks55b1rbj5vniyiy3"; 12 21 }; 13 22 ··· 15 24 setOutputFlags = false; # $dev gets into the library otherwise 16 25 17 26 # GCC 4.6 raises a number of set-but-unused warnings. 18 - configureFlags = [ "--disable-error-on-warning" ] 19 - # Guile needs patching to preset results for the configure tests about 20 - # pthreads, which work only in native builds. 21 - ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) 22 - "--with-threads=no"; 23 - 24 - depsBuildBuild = [ buildPackages.stdenv.cc ] 25 - ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) 26 - pkgsBuildBuild.guile_1_8; 27 - nativeBuildInputs = [ makeWrapper gawk pkg-config ]; 28 - buildInputs = [ readline libtool ]; 27 + configureFlags = [ 28 + "--disable-error-on-warning" 29 + ] 30 + # Guile needs patching to preset results for the configure tests about 31 + # pthreads, which work only in native builds. 32 + ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) 33 + "--with-threads=no"; 29 34 35 + depsBuildBuild = [ 36 + buildPackages.stdenv.cc 37 + ] 38 + ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) 39 + pkgsBuildBuild.guile_1_8; 40 + nativeBuildInputs = [ 41 + gawk 42 + makeWrapper 43 + pkg-config 44 + ]; 45 + buildInputs = [ 46 + libtool 47 + readline 48 + ]; 30 49 propagatedBuildInputs = [ 31 50 gmp 32 51 ··· 38 57 ]; 39 58 40 59 patches = [ 60 + # Fix doc snarfing with GCC 4.5. 41 61 ./cpp-4.5.patch 62 + # Self explanatory 42 63 ./CVE-2016-8605.patch 43 64 ]; 44 65 ··· 46 67 sed -e '/lt_dlinit/a lt_dladdsearchdir("'$out/lib'");' -i libguile/dynl.c 47 68 ''; 48 69 49 - 50 70 postInstall = '' 51 71 wrapProgram $out/bin/guile-snarf --prefix PATH : "${gawk}/bin" 52 72 '' 53 - # XXX: See http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/18903 for 54 - # why `--with-libunistring-prefix' and similar options coming from 55 - # `AC_LIB_LINKFLAGS_BODY' don't work on NixOS/x86_64. 73 + # XXX: See http://thread.gmane.org/gmane.comp.lib.gnulib.bugs/18903 for 74 + # why `--with-libunistring-prefix' and similar options coming from 75 + # `AC_LIB_LINKFLAGS_BODY' don't work on NixOS/x86_64. 56 76 + '' 57 77 sed -i "$out/lib/pkgconfig/guile"-*.pc \ 58 78 -e "s|-lltdl|-L${libtool.lib}/lib -lltdl|g" ··· 65 85 doCheck = false; 66 86 doInstallCheck = doCheck; 67 87 68 - setupHook = ./setup-hook.sh; 88 + setupHook = ./setup-hook-1.8.sh; 69 89 70 - meta = { 90 + meta = with lib; { 91 + homepage = "https://www.gnu.org/software/guile/"; 71 92 description = "Embeddable Scheme implementation"; 72 - homepage = "https://www.gnu.org/software/guile/"; 73 - license = lib.licenses.lgpl2Plus; 74 - maintainers = [ lib.maintainers.ludo ]; 75 - platforms = lib.platforms.unix; 76 - 77 93 longDescription = '' 78 - GNU Guile is an interpreter for the Scheme programming language, 79 - packaged as a library that can be embedded into programs to make 80 - them extensible. It supports many SRFIs. 94 + GNU Guile is an implementation of the Scheme programming language, with 95 + support for many SRFIs, packaged for use in a wide variety of 96 + environments. In addition to implementing the R5RS Scheme standard and a 97 + large subset of R6RS, Guile includes a module system, full access to POSIX 98 + system calls, networking support, multiple threads, dynamic linking, a 99 + foreign function call interface, and powerful string processing. 81 100 ''; 101 + license = licenses.lgpl3Plus; 102 + maintainers = with maintainers; [ ludo ]; 103 + platforms = platforms.all; 82 104 }; 83 105 }
+1 -2
pkgs/development/interpreters/guile/setup-hook.sh pkgs/development/interpreters/guile/setup-hook-1.8.sh
··· 1 1 addGuileLibPath () { 2 - if test -d "$1/share/guile/site" 3 - then 2 + if test -d "$1/share/guile/site"; then 4 3 export GUILE_LOAD_PATH="${GUILE_LOAD_PATH-}${GUILE_LOAD_PATH:+:}$1/share/guile/site" 5 4 fi 6 5 }