neoidiosyn/zlib.nix
2024-11-21 01:07:39 +01:00

32 lines
787 B
Nix

{ lib, stdenv, fetchurl, zlib-ng, ... }:
assert zlib-ng.version == "2.2.2";
stdenv.mkDerivation (finalAttrs: {
inherit (zlib-ng) pname version;
src = fetchurl {
url = "https://github.com/zlib-ng/zlib-ng/archive/refs/tags/${finalAttrs.version}.tar.gz";
hash = "sha256-/LQd1Zo/FwAq6xuyHwRpbJtyFASJC7lFxas50stpZUw=";
};
outputs = [ "out" "dev" "man" ];
env = {
CHOST = stdenv.hostPlatform.config;
CROSS_PREFIX = stdenv.cc.targetPrefix;
};
setOutputFlags = false;
dontAddDisableDepTrack = true;
configurePlatforms = [ ];
configureFlags = [
"--libdir=${placeholder "dev"}/lib"
"--sharedlibdir=${placeholder "out"}/lib"
"--includedir=${placeholder "dev"}/include"
"--zlib-compat"
];
makeFlags = [ "mandir=$(man)/share/man" ];
})