From 5c6f159cd50c5f4ed390c706dd508cc4e8eee6f3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Domen=20Ko=C5=BEar?= Date: Sun, 10 May 2015 11:39:42 +0200 Subject: [PATCH] subunit: split package into everything and python lib --- .../development/libraries/subunit/default.nix | 26 +++++++++++++++++++ pkgs/servers/samba/4.x.nix | 4 +-- pkgs/top-level/all-packages.nix | 3 ++- pkgs/top-level/python-packages.nix | 21 +++------------ 4 files changed, 34 insertions(+), 20 deletions(-) create mode 100644 pkgs/development/libraries/subunit/default.nix diff --git a/pkgs/development/libraries/subunit/default.nix b/pkgs/development/libraries/subunit/default.nix new file mode 100644 index 000000000000..fa007da7d9cc --- /dev/null +++ b/pkgs/development/libraries/subunit/default.nix @@ -0,0 +1,26 @@ +{ stdenv, fetchurl, pkgconfig, check, cppunit, perl, pythonPackages }: + +# NOTE: for subunit python library see pkgs/top-level/python-packages.nix + +stdenv.mkDerivation rec { + name = "subunit-${version}"; + version = "1.0.0"; + + src = fetchurl { + url = "https://launchpad.net/subunit/trunk/${version}/+download/${name}.tar.gz"; + sha256 = "1fnhrrwww90746an2nz2kn9qdf9pklmaf5lm22gssl6648f2rp2m"; + }; + + buildInputs = [ pkgconfig check cppunit perl pythonPackages.wrapPython ]; + + propagatedBuildInputs = with pythonPackages; [ testtools testscenarios ]; + + postFixup = "wrapPythonPrograms"; + + meta = with stdenv.lib; { + description = "A streaming protocol for test results"; + homepage = https://launchpad.net/subunit; + license = licenses.asl20; + platforms = platforms.linux; + }; +} diff --git a/pkgs/servers/samba/4.x.nix b/pkgs/servers/samba/4.x.nix index 49b81794f044..c785d76ddce7 100644 --- a/pkgs/servers/samba/4.x.nix +++ b/pkgs/servers/samba/4.x.nix @@ -1,6 +1,6 @@ { stdenv, fetchurl, python, pkgconfig, perl, libxslt, docbook_xsl , docbook_xml_dtd_42, docbook_xml_dtd_45, readline, talloc, ntdb, tdb, tevent -, ldb, popt, iniparser, pythonPackages, libbsd, nss_wrapper, socket_wrapper +, ldb, popt, iniparser, subunit, libbsd, nss_wrapper, socket_wrapper , uid_wrapper, libarchive # source3/wscript optionals @@ -65,7 +65,7 @@ stdenv.mkDerivation rec { buildInputs = [ python pkgconfig perl libxslt docbook_xsl docbook_xml_dtd_42 docbook_xml_dtd_45 readline talloc ntdb tdb tevent ldb popt iniparser - pythonPackages.subunit libbsd nss_wrapper socket_wrapper uid_wrapper + subunit libbsd nss_wrapper socket_wrapper uid_wrapper libarchive kerberos zlib openldap cups pam avahi acl libaio fam libceph glusterfs diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 80ff1ced0d80..d5bd3d71c956 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8770,7 +8770,6 @@ let samba4 = callPackage ../servers/samba/4.x.nix { python = python2; - pythonPackages = python2Packages; kerberos = heimdal; gnutls = gnutls33; cups = if stdenv.isDarwin then null else cups; @@ -12184,6 +12183,8 @@ let pythonBindings = true; }); + subunit = callPackage ../development/libraries/subunit { }; + surf = callPackage ../applications/misc/surf { webkit = webkitgtk2; }; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index f346b0a2b21c..2e9469160546 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -12085,26 +12085,13 @@ let }; }; - subunit = stdenv.mkDerivation rec { - name = "subunit-${version}"; - version = "1.0.0"; - - src = pkgs.fetchurl { - url = "https://launchpad.net/subunit/trunk/${version}/+download/${name}.tar.gz"; - sha256 = "1fnhrrwww90746an2nz2kn9qdf9pklmaf5lm22gssl6648f2rp2m"; - }; - - buildInputs = (with pkgs; [ pkgconfig check cppunit perl ]) ++ [ self.wrapPython ]; + subunit = buildPythonPackage rec { + name = pkgs.subunit.name; + src = pkgs.subunit.src; propagatedBuildInputs = with self; [ testtools testscenarios ]; - postFixup = "wrapPythonPrograms"; - - meta = { - description = "A streaming protocol for test results"; - homepage = https://launchpad.net/subunit; - license = licenses.asl20; - }; + meta = pkgs.subunit.meta; };