9 stdenv.mkDerivation rec {
14 url = "mirror://mozilla/nspr/releases/v${version}/src/nspr-${version}.tar.gz";
15 hash = "sha256-fqMpfqWWm10lpd2NR/JEPNqI6e50YwH24eFCb4pqvI8=";
19 ./0001-Makefile-use-SOURCE_DATE_EPOCH-for-reproducibility.patch
22 outputs = [ "out" "dev" ];
27 '' + lib.optionalString stdenv.isDarwin ''
28 substituteInPlace configure --replace '@executable_path/' "$out/lib/"
29 substituteInPlace configure.in --replace '@executable_path/' "$out/lib/"
33 depsBuildBuild = [ buildPackages.stdenv.cc ];
37 ] ++ lib.optional stdenv.is64bit "--enable-64bit";
40 find $out -name "*.a" -delete
41 moveToOutput share "$dev" # just aclocal
44 buildInputs = lib.optionals stdenv.isDarwin [ CoreServices ];
46 enableParallelBuilding = true;
49 inherit (nixosTests) firefox firefox-esr-91 firefox-esr-102;
53 homepage = "https://developer.mozilla.org/en-US/docs/Mozilla/Projects/NSS/Reference/NSPR_functions";
54 description = "Netscape Portable Runtime, a platform-neutral API for system-level and libc-like functions";
55 maintainers = with maintainers; [ ajs124 hexa ];
56 platforms = platforms.all;
57 license = licenses.mpl20;