git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #107126 from rb2k/rpm_update
commit80418f65eb91c808544a092c9713cc2c9ce913b5 authorJörg Thalheim <Mic92@users.noreply.github.com> dateSat 26 Dec 2020, 06:01 (6 years ago) parent8a801d408725b9
1 file changed+18−8
pkgs/tools/package-management/rpm/default.nix+18−8
pkgs/tools/package-management/rpm/default.nix+18−8
@@ -1,21 +1,22 @@
1−{ stdenv, lib
1+{ stdenv, lib, fetchpatch
22, pkgconfig, autoreconfHook
3−, fetchurl, cpio, zlib, bzip2, file, elfutils, libbfd, libarchive, nspr, nss, popt, db, xz, python, lua, llvmPackages
3+, fetchurl, cpio, zlib, bzip2, file, elfutils, libbfd, libgcrypt, libarchive, nspr, nss, popt, db, xz, python, lua, llvmPackages
4+, sqlite
45}:
56
67stdenv.mkDerivation rec {
78 pname = "rpm";
8− version = "4.15.1";
9+ version = "4.16.1.2";
910
1011 src = fetchurl {
1112 url = "http://ftp.rpm.org/releases/rpm-${lib.versions.majorMinor version}.x/rpm-${version}.tar.bz2";
12− sha256 = "0c6jwail90fhha3bpx70w4a2i8ycxwvnx6zwxm121l8wc3wlbvyx";
13+ sha256 = "1k6ank2aad7r503w12m6m494mxr6iccj52wqhwbc94pwxsf34mw3";
1314 };
1415
1516 outputs = [ "out" "dev" "man" ];
1617
1718 nativeBuildInputs = [ autoreconfHook pkgconfig ];
18− buildInputs = [ cpio zlib bzip2 file libarchive nspr nss db xz python lua ]
19+ buildInputs = [ cpio zlib bzip2 file libarchive libgcrypt nspr nss db xz python lua sqlite ]
1920 ++ lib.optionals stdenv.cc.isClang [ llvmPackages.openmp ];
2021
2122 # rpm/rpmlib.h includes popt.h, and then the pkg-config file mentions these as linkage requirements
@@ -28,14 +29,23 @@ stdenv.mkDerivation rec {
2829 "--with-external-db"
2930 "--with-lua"
3031 "--enable-python"
32+ "--enable-ndb"
33+ "--enable-sqlite"
3134 "--localstatedir=/var"
3235 "--sharedstatedir=/com"
3336 ];
3437
35− postPatch = ''
36− # For Python3, the original expression evaluates as 'python3.4' but we want 'python3.4m' here
37− substituteInPlace configure.ac --replace 'python''${PYTHON_VERSION}' ${python.executable}
38+ # Small fixes for ndb on darwin
39+ # https://github.com/rpm-software-management/rpm/pull/1465
40+ patches = [
41+ (fetchpatch {
42+ name = "darwin-support.patch";
43+ url = "https://github.com/rpm-software-management/rpm/commit/2d20e371d5e38f4171235e5c64068cad30bda557.patch";
44+ sha256 = "0p3j5q5a4hl357maf7018k3826jhcpqg6wfrnccrkv30g0ayk171";
45+ })
46+ ];
3847
48+ postPatch = ''
3949 substituteInPlace Makefile.am --replace '@$(MKDIR_P) $(DESTDIR)$(localstatedir)/tmp' ""
4050 '';
4151