tree-wide: various cleanups

It's mainly refactoring and mass-rebuild simplifications without any
real impact (besides better readability).
wip/yesman
Vladimír Čunát 9 years ago
parent 072da541de
commit 1878ac9335
  1. 2
      pkgs/development/libraries/expat/default.nix
  2. 3
      pkgs/development/libraries/kerberos/heimdal.nix
  3. 4
      pkgs/development/libraries/kerberos/krb5.nix
  4. 14
      pkgs/development/libraries/libedit/default.nix
  5. 15
      pkgs/development/libraries/libiconv/default.nix
  6. 2
      pkgs/development/libraries/libossp-uuid/default.nix
  7. 4
      pkgs/tools/networking/miniupnpc/default.nix
  8. 8
      pkgs/top-level/perl-packages.nix

@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
patches = [ ./CVE-2015-1283.patch ];
configureFlags = stdenv.lib.optionalString stdenv.isFreeBSD "--with-pic";
configureFlags = stdenv.lib.optional stdenv.isFreeBSD "--with-pic";
meta = with stdenv.lib; {
homepage = http://www.libexpat.org/;

@ -23,7 +23,8 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ autoreconfHook pkgconfig python perl yacc flex ]
++ (with perlPackages; [ JSON ])
++ optional (!libOnly) texinfo;
buildInputs = (if (!stdenv.isFreeBSD) then [ libcap_ng db ] else []) ++ [ sqlite openssl libedit ]
buildInputs = optionals (!stdenv.isFreeBSD) [ libcap_ng db ]
++ [ sqlite openssl libedit ]
++ optionals (!libOnly) [ openldap pam ];
## ugly, X should be made an option

@ -18,11 +18,11 @@ stdenv.mkDerivation rec {
sha256 = "1sgr61cnkgc5xazijaww6wpn5fnxl9vyj9ixk3r3y7ikv3x0gnyf";
};
configureFlags = stdenv.lib.optionalString stdenv.isFreeBSD ''WARN_CFLAGS=""'';
configureFlags = optional stdenv.isFreeBSD ''WARN_CFLAGS=""'';
nativeBuildInputs = [ pkgconfig perl yacc ]
# Provides the mig command used by the build scripts
++ stdenv.lib.optional stdenv.isDarwin bootstrap_cmds;
++ optional stdenv.isDarwin bootstrap_cmds;
buildInputs = [ openssl ]
++ optionals (!libOnly) [ openldap libedit ];

@ -11,23 +11,21 @@ stdenv.mkDerivation rec {
# Have `configure' avoid `/usr/bin/nroff' in non-chroot builds.
NROFF = "${groff}/bin/nroff";
patches = if stdenv.isCygwin then [
./01-cygwin.patch
] else [ ] ++ [ ./freebsd-wchar.patch ];
patches = [ ./01-cygwin.patch ./freebsd-wchar.patch ];
propagatedBuildInputs = [ ncurses ];
configureFlags = [ "--enable-widec" ];
postInstall = ''
find $out/lib -type f | grep '\.\(la\|pc\)''$' | xargs sed -i \
-e 's,-lncurses[a-z]*,-L${ncurses}/lib -lncursesw,g'
'';
configureFlags = [ "--enable-widec" ];
propagatedBuildInputs = [ ncurses ];
meta = with stdenv.lib; {
homepage = "http://www.thrysoee.dk/editline/";
description = "A port of the NetBSD Editline library (libedit)";
license = licenses.bsd3;
license = licenses.bsd3;
platforms = platforms.all;
};
}

@ -1,4 +1,4 @@
{ fetchurl, stdenv }:
{ fetchurl, stdenv, lib }:
assert (!stdenv.isLinux);
@ -10,17 +10,18 @@ stdenv.mkDerivation rec {
sha256 = "04q6lgl3kglmmhw59igq1n7v3rp1rpkypl366cy1k1yn2znlvckj";
};
patches = if stdenv.isCygwin then [
patches = lib.optionals stdenv.isCygwin [
./libiconv-1.14-reloc.patch
./libiconv-1.14-wchar.patch
] else null;
];
configureFlags =
# On Cygwin, Libtool produces a `.dll.a', which is not a "real" DLL
# (Windows' linker would need to be used somehow to produce an actual
# DLL.) Thus, build the static library too, and this is what Gettext
# will actually use.
configureFlags = if stdenv.isCygwin then [ "--enable-static" ] else
if stdenv.isFreeBSD then [ "--with-pic" ] else null;
lib.optional stdenv.isCygwin "--enable-static"
++ lib.optional stdenv.isFreeBSD "--with-pic";
crossAttrs = {
# Disable stripping to avoid "libiconv.a: Archive has no index" (MinGW).
@ -42,11 +43,11 @@ stdenv.mkDerivation rec {
'';
homepage = http://www.gnu.org/software/libiconv/;
license = stdenv.lib.licenses.lgpl2Plus;
license = lib.licenses.lgpl2Plus;
maintainers = [ ];
# This library is not needed on GNU platforms.
hydraPlatforms = stdenv.lib.platforms.cygwin ++ stdenv.lib.platforms.darwin ++ stdenv.lib.platforms.freebsd;
hydraPlatforms = with lib.platforms; cygwin ++ darwin ++ freebsd;
};
}

@ -10,7 +10,7 @@ stdenv.mkDerivation {
sha256= "11a615225baa5f8bb686824423f50e4427acd3f70d394765bdff32801f0fd5b0";
};
configureFlags = stdenv.lib.optionalString stdenv.isFreeBSD "--with-pic";
configureFlags = stdenv.lib.optional stdenv.isFreeBSD "--with-pic";
meta = with stdenv.lib; {
homepage = http://www.ossp.org/pkg/lib/uuid/;

@ -10,7 +10,7 @@ stdenv.mkDerivation rec {
name = "${name}.tar.gz";
};
patches = stdenv.lib.optional stdenv.isFreeBSD [ ./freebsd.patch ];
patches = stdenv.lib.optional stdenv.isFreeBSD ./freebsd.patch;
doCheck = !stdenv.isFreeBSD;
@ -20,6 +20,6 @@ stdenv.mkDerivation rec {
inherit version;
homepage = http://miniupnp.free.fr/;
description = "A client that implements the UPnP Internet Gateway Device (IGD) specification";
platforms = stdenv.lib.platforms.linux ++ stdenv.lib.platforms.freebsd;
platforms = with stdenv.lib.platforms; linux ++ freebsd;
};
}

@ -6339,7 +6339,7 @@ let self = _self // overrides; _self = with self; {
LocaleGettext = buildPerlPackage {
name = "LocaleGettext-1.05";
buildInputs = stdenv.lib.optional (stdenv.isFreeBSD || stdenv.isDarwin || stdenv.isCygwin) pkgs.gettext;
NIX_CFLAGS_LINK = if (stdenv.isFreeBSD || stdenv.isDarwin || stdenv.isCygwin) then "-lintl" else null;
NIX_CFLAGS_LINK = stdenv.lib.optional (stdenv.isFreeBSD || stdenv.isDarwin || stdenv.isCygwin) "-lintl";
src = fetchurl {
url = mirror://cpan/authors/id/P/PV/PVANDRY/gettext-1.05.tar.gz;
sha256 = "15262a00vx714szpx8p2z52wxkz46xp7acl72znwjydyq4ypydi7";
@ -6552,10 +6552,10 @@ let self = _self // overrides; _self = with self; {
};
patches = [ ../development/perl-modules/lwp-test-with-localhost.patch ];
propagatedBuildInputs = [ EncodeLocale FileListing HTMLParser HTTPCookies HTTPDaemon HTTPDate HTTPMessage HTTPNegotiate LWPMediaTypes NetHTTP URI WWWRobotRules ];
meta = {
meta = with stdenv.lib; {
description = "The World-Wide Web library for Perl";
license = with stdenv.lib.licenses; [ artistic1 gpl1Plus ];
platforms = stdenv.lib.platforms.linux ++ stdenv.lib.platforms.darwin ++ stdenv.lib.platforms.illumos ++ stdenv.lib.platforms.freebsd;
license = with licenses; [ artistic1 gpl1Plus ];
platforms = platforms.unix;
};
};

Loading…
Cancel
Save