diff --git a/pkgs/by-name/zl/zlib-ng/package.nix b/pkgs/by-name/zl/zlib-ng/package.nix index 154bc13acbfb..479c6cad4b98 100644 --- a/pkgs/by-name/zl/zlib-ng/package.nix +++ b/pkgs/by-name/zl/zlib-ng/package.nix @@ -45,7 +45,10 @@ stdenv.mkDerivation rec { "-DBUILD_SHARED_LIBS=ON" "-DINSTALL_UTILS=ON" ] - ++ lib.optionals withZlibCompat [ "-DZLIB_COMPAT=ON" ]; + ++ lib.optionals withZlibCompat [ "-DZLIB_COMPAT=ON" ] + ++ lib.optional ( + stdenv.hostPlatform.isWindows || stdenv.hostPlatform.isCygwin + ) "-DCMAKE_RC_COMPILER=${stdenv.cc.targetPrefix}windres"; meta = { description = "Zlib data compression library for the next generation systems";