···77, profiledCompiler ? false
88, langJit ? false
99, staticCompiler ? false
1010-, enableShared ? true
1010+, # N.B. the defult is intentionally not from an `isStatic`. See
1111+ # https://gcc.gnu.org/install/configure.html - this is about target
1212+ # platform libraries not host platform ones unlike normal. But since
1313+ # we can't rebuild those without also rebuilding the compiler itself,
1414+ # we opt to always build everything unlike our usual policy.
1515+ enableShared ? true
1116, enableLTO ? true
1217, texinfo ? null
1318, perl ? null # optional, for texi2pod (then pod2man)
···137142 )
138143 else "")
139144 + stdenv.lib.optionalString targetPlatform.isAvr ''
140140- makeFlagsArray+=(
141141- 'LIMITS_H_TEST=false'
142142- )
143143- '';
145145+ makeFlagsArray+=(
146146+ 'LIMITS_H_TEST=false'
147147+ )
148148+ '';
144149145150 inherit noSysDirs staticCompiler crossStageStatic
146151 libcCross crossMingw;
+6-1
pkgs/development/compilers/gcc/4.8/default.nix
···77, profiledCompiler ? false
88, langJit ? false
99, staticCompiler ? false
1010-, enableShared ? true
1010+, # N.B. the defult is intentionally not from an `isStatic`. See
1111+ # https://gcc.gnu.org/install/configure.html - this is about target
1212+ # platform libraries not host platform ones unlike normal. But since
1313+ # we can't rebuild those without also rebuilding the compiler itself,
1414+ # we opt to always build everything unlike our usual policy.
1515+ enableShared ? true
1116, enableLTO ? true
1217, texinfo ? null
1318, perl ? null # optional, for texi2pod (then pod2man); required for Java
+6-1
pkgs/development/compilers/gcc/4.9/default.nix
···77, profiledCompiler ? false
88, langJit ? false
99, staticCompiler ? false
1010-, enableShared ? true
1010+, # N.B. the defult is intentionally not from an `isStatic`. See
1111+ # https://gcc.gnu.org/install/configure.html - this is about target
1212+ # platform libraries not host platform ones unlike normal. But since
1313+ # we can't rebuild those without also rebuilding the compiler itself,
1414+ # we opt to always build everything unlike our usual policy.
1515+ enableShared ? true
1116, enableLTO ? true
1217, texinfo ? null
1318, perl ? null # optional, for texi2pod (then pod2man); required for Java
+6-1
pkgs/development/compilers/gcc/6/default.nix
···88, profiledCompiler ? false
99, langJit ? false
1010, staticCompiler ? false
1111-, enableShared ? true
1111+, # N.B. the defult is intentionally not from an `isStatic`. See
1212+ # https://gcc.gnu.org/install/configure.html - this is about target
1313+ # platform libraries not host platform ones unlike normal. But since
1414+ # we can't rebuild those without also rebuilding the compiler itself,
1515+ # we opt to always build everything unlike our usual policy.
1616+ enableShared ? true
1217, enableLTO ? true
1318, texinfo ? null
1419, flex
+6-1
pkgs/development/compilers/gcc/7/default.nix
···66, profiledCompiler ? false
77, langJit ? false
88, staticCompiler ? false
99-, enableShared ? true
99+, # N.B. the defult is intentionally not from an `isStatic`. See
1010+ # https://gcc.gnu.org/install/configure.html - this is about target
1111+ # platform libraries not host platform ones unlike normal. But since
1212+ # we can't rebuild those without also rebuilding the compiler itself,
1313+ # we opt to always build everything unlike our usual policy.
1414+ enableShared ? true
1015, enableLTO ? true
1116, texinfo ? null
1217, perl ? null # optional, for texi2pod (then pod2man)
+10-5
pkgs/development/compilers/gcc/8/default.nix
···66, profiledCompiler ? false
77, langJit ? false
88, staticCompiler ? false
99-, enableShared ? true
99+, # N.B. the defult is intentionally not from an `isStatic`. See
1010+ # https://gcc.gnu.org/install/configure.html - this is about target
1111+ # platform libraries not host platform ones unlike normal. But since
1212+ # we can't rebuild those without also rebuilding the compiler itself,
1313+ # we opt to always build everything unlike our usual policy.
1414+ enableShared ? true
1015, enableLTO ? true
1116, texinfo ? null
1217, perl ? null # optional, for texi2pod (then pod2man)
···134139 )
135140 else "")
136141 + stdenv.lib.optionalString targetPlatform.isAvr ''
137137- makeFlagsArray+=(
138138- 'LIMITS_H_TEST=false'
139139- )
140140- '';
142142+ makeFlagsArray+=(
143143+ 'LIMITS_H_TEST=false'
144144+ )
145145+ '';
141146142147 inherit noSysDirs staticCompiler crossStageStatic
143148 libcCross crossMingw;
+6-1
pkgs/development/compilers/gcc/9/default.nix
···88, profiledCompiler ? false
99, langJit ? false
1010, staticCompiler ? false
1111-, enableShared ? true
1111+, # N.B. the defult is intentionally not from an `isStatic`. See
1212+ # https://gcc.gnu.org/install/configure.html - this is about target
1313+ # platform libraries not host platform ones unlike normal. But since
1414+ # we can't rebuild those without also rebuilding the compiler itself,
1515+ # we opt to always build everything unlike our usual policy.
1616+ enableShared ? true
1217, enableLTO ? true
1318, texinfo ? null
1419, perl ? null # optional, for texi2pod (then pod2man)
···3838 #
3939 # There might be a more sensible way to do this with autotools, but I am not
4040 # smart enough to discover it.
4141- preBuild = lib.optionalString stdenv.targetPlatform.isStatic ''
4141+ preBuild = lib.optionalString stdenv.hostPlatform.isStatic ''
4242 make -C libaudiofile $makeFlags
4343 sed -i "s/dependency_libs=.*/dependency_libs=' -lstdc++'/" libaudiofile/libaudiofile.la
4444 '';
···11{ stdenv, fetchurl, m4
22, cxx ? !stdenv.hostPlatform.useAndroidPrebuilt && !stdenv.hostPlatform.isWasm
33, buildPackages
44-, withStatic ? false }:
44+, withStatic ? stdenv.hostPlatform.isStatic
55+}:
5667# Note: this package is used for bootstrapping fetchurl, and thus
78# cannot use fetchpatch! All mutable patches (generated by GitHub or
···11{ stdenv
22, fetchurl
33-# Note: If `{ static = false; shared = false; }`, upstream's default is used
44-# (which is building both static and shared as of zlib 1.2.11).
55-, shared ? true
33+, shared ? !stdenv.hostPlatform.isStatic
64, static ? true
75# If true, a separate .static ouput is created and the .a is moved there.
86# In this case `pkg-config` auto detection does not currently work if the
97# .static output is given as `buildInputs` to another package (#66461), because
108# the `.pc` file lists only the main output's lib dir.
119# If false, and if `{ static = true; }`, the .a stays in the main output.
1212-, splitStaticOutput ? static
1010+, splitStaticOutput ? shared && static
1311}:
1212+1313+# Without either the build will actually still succeed because the build
1414+# system makes an arbitrary choice, but we shouldn't be so indecisive.
1515+assert shared || static;
14161517# Note: this package is used for bootstrapping fetchurl, and thus
1618# cannot use fetchpatch! All mutable patches (generated by GitHub or
···11-{ stdenv, fetchurl, enableStatic ? false }:
11+{ stdenv, fetchurl
22+, enableStatic ? stdenv.hostPlatform.isStatic
33+}:
2435# Note: this package is used for bootstrapping fetchurl, and thus
46# cannot use fetchpatch! All mutable patches (generated by GitHub or
···11-{ stdenv, fetchurl, libpng, static ? false
11+{ stdenv, fetchurl, libpng
22+, static ? stdenv.hostPlatform.isStatic
23}:
3445# This package comes with its own copy of zlib, libpng and pngxtern