Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

zlib: don't really override CC at ay point #1

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions pkgs/development/libraries/zlib/default.nix
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
{ stdenv, fetchurl, static ? false }:
{ stdenv
, fetchurl
, buildPlatform, hostPlatform
, static ? false
}:

let version = "1.2.11"; in

Expand All @@ -24,7 +28,9 @@ stdenv.mkDerivation rec {
setOutputFlags = false;
outputDoc = "dev"; # single tiny man3 page

preConfigure = ''
# TODO(@Dridus) CC set by cc-wrapper setup-hook, so just empty out the preConfigure script when cross building, but leave the old incorrect script when not
# cross building to avoid hash breakage. Once hash breakage is acceptable, remove preConfigure entirely.
preConfigure = stdenv.lib.optionalString (hostPlatform == buildPlatform) ''
if test -n "$crossConfig"; then
export CC=$crossConfig-gcc
fi
Expand Down