summary refs log tree commit diff
path: root/pkgs/stdenv/generic
Commit message (Collapse)AuthorAge
...
* | | | | Merge pull request #217568 from trofi/stdenv-parallel-installMartin Weinelt2023-03-15
|\ \ \ \ \ | |/ / / / |/| | | | stdenv/generic/setup.sh: enable parallel installs for parallel builds
| * | | | stdenv/generic/setup.sh: enable parallel installs by defaultSergei Trofimovich2023-02-26
| |/ / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The primary motivating example is openssl: Before the change full package build took 1m54s minutes. After the change full package build takes 59s. About a 2x speedup. The difference is visible because openssl builds hundreds of manpages spawning a perl process per manual in `install` phase. Such a workload is very easy to parallelize. Another example would be `autotools`+`libtool` based build system where install step requires relinking. The more binaries there are to relink the more gain it will be to do it in parallel. The change enables parallel installs by default only for buiilds that already have parallel builds enabled. There is a high chance those build systems already handle parallelism well but some packages will fail. Consistently propagated the enableParallelBuilding to: - cmake (enabled by default, similar to builds) - ninja (set parallelism explicitly, don't rely on default) - bmake (enable when requested) - scons (enable when requested) - meson (set parallelism explicitly, don't rely on default) - waf (set parallelism explicitly, don't rely on default) - qmake-4/5/6 (enable by default, similar to builds) - xorg (always enable, similar to builds)
* | | | mkDerivation: do not disable `separateDebugInfo` on LLVM stdenvsRahul Butani2023-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was disabled here: https://github.com/NixOS/nixpkgs/commit/b86e62d30d4635ef3294d9c1c308f9c8b0061045#diff-282a02cc3871874f16401347d8fadc90d59d7ab11f6a99eaa5173c3867e1a160 h/t to @teh: https://github.com/NixOS/nixpkgs/commit/b86e62d30d4635ef3294d9c1c308f9c8b0061045#commitcomment-77916294 for pointing out that the failure that @matthewbauer was seeing was caused by the `separate-debug-info.sh` `build-id` length requirement that #146275 will relax `lld` has had `--build-id` support dating back to LLVM4: https://reviews.llvm.org/D18091 This predates every `llvmPackages_` version currently in nixpkgs (and certainly every version actually still used in `useLLVM` stdenvs) so with the previous commit (asking `ld` for sufficiently long SHA1 hashes) I think we can safely enable `separateDebugInfo` when using LLVM bintools.
* | | | Merge pull request #212498 from risicle/ris-fortify3Robert Scott2023-02-16
|\ \ \ \ | |/ / / |/| | | hardening flags: add `FORTIFY_SOURCE=3` support
| * | | mkDerivation: add support for fortify3 hardening flagRobert Scott2023-01-24
| | | |
* | | | Merge staging-next into staginggithub-actions[bot]2023-02-15
|\ \ \ \ | | |_|/ | |/| |
| * | | treewide: use lib.optionalsFelix Buehler2023-02-14
| | | |
* | | | Merge staging-next into staginggithub-actions[bot]2023-02-15
|\| | |
| * | | treewide: use optionalStringFelix Buehler2023-02-13
| | | |
* | | | Merge staging-next into staginggithub-actions[bot]2023-02-13
|\| | |
| * | | Merge master into staging-nextgithub-actions[bot]2023-02-13
| |\ \ \
| | * | | make-derivation.nix: Support inputDerivation on disallowedReferencesRobert Hensing2023-02-07
| | | | |
* | | | | stdenv: allow propagating propagated dependencies separately from theArtturin2023-02-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | fixup phase for makeSetupHook
* | | | | Merge pull request #214937 from hercules-ci/support-NIX_ATTRS-envsArtturi2023-02-06
|\ \ \ \ \
| * | | | | stdenv/setup.sh: Allow NIX_ATTRS_{JSON,SH}_FILE to be set correctly by NixRobert Hensing2023-02-06
| | | | | |
* | | | | | Merge staging-next into staginggithub-actions[bot]2023-02-06
|\ \ \ \ \ \ | |/ / / / / |/| / / / / | |/ / / /
| * | | | Merge master into staging-nextgithub-actions[bot]2023-02-06
| |\| | |
| | * | | Merge pull request #214304 from obsidiansystems/pkg-config-metaJohn Ericson2023-02-06
| | |\ \ \ | | | | | | | | | | | | meta.pkgConfigModules: Init convention
| | | * | | meta.pkgConfigModules: Init conventionJohn Ericson2023-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See docs. Follow-up work: - Existing packages should be converted - `defaultPkgConfigPackages` should assert on `meta.pkgConfigModules` and let `tests.pkg-config` alone test the build results. CC @sternenseemann Co-authored-by: Robert Hensing <roberth@users.noreply.github.com>
* | | | | | Merge staging-next into staginggithub-actions[bot]2023-02-05
|\| | | | |
| * | | | | Merge master into staging-nextgithub-actions[bot]2023-02-05
| |\| | | |
| | * | | | Merge pull request #213633 from alyssais/mkDerivation-meson-exoticsuperherointj2023-02-04
| | |\ \ \ \ | | | |/ / / | | |/| | | stdenv.mkDerivation: fix meson for some archs
| | | * | | stdenv.mkDerivation: fix meson for some archsAlyssa Ross2023-01-30
| | | | |/ | | | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | platform.uname.processor seems to be what we want in many more cases than what we were using before — it does the right thing for aarch64, x86_64, riscv32, riscv64, mips, mips64, powerpc, and powerpc64 (the latter three of which were broken before). This fixes cross-compilation of systemd for PowerPC/POWER platforms.
* | | | | Merge pull request #211685 from Artturin/splicingstuff1-splitArtturi2023-02-03
|\ \ \ \ \ | |/ / / / |/| | | |
| * | | | stdenv.mkDerivation: Make overrideAttrs overridableRobert Hensing2023-01-15
| | | | | | | | | | | | | | | | | | | | (cherry picked from commit 43c8b43f808f48fd5600afcad5503eaeaf6d71b7)
* | | | | Merge pull request #211783 from R-VdP/fix_disallowed_referencesArtturi2023-01-31
|\ \ \ \ \ | | | | | | | | | | | | stdenv: don't include drvs in disallowedRefs as build-time deps.
| * | | | | stdenv: don't include drvs in disallowedRefs as build-time deps.R-VdP2023-01-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Derivations listed as disallowedReferences or disallowedRequisites, currently end up as build-time dependencies. This is problematic since the disallowed derivations will be built by nix as build-time dependencies, while those derivations might take a very long time to build, or might not even build successfully on the platform used. However, in order to scan for disallowed references in the final output, knowing the out path is sufficient, and the out path can be calculated from the derivation without needing to build it, saving time and resources. While the problem is less severe for allowedReferences and allowedRequisites, since we want the derivation to be built eventually, we would still like to get the error early and without having to wait while nix builds a derivation that might not be used (e.g. if we listed the wrong one).
* | | | | | Merge staging-next into staginggithub-actions[bot]2023-01-31
|\ \ \ \ \ \ | |/ / / / / |/| | / / / | | |/ / / | |/| | |
| * | | | Merge master into staging-nextgithub-actions[bot]2023-01-31
| |\ \ \ \ | | |_|_|/ | |/| | |
| | * | | Revert "lib/meta.nix: platformMatch: allow predicate functions"Adam Joseph2023-01-27
| | | |/ | | |/| | | | | | | | | This reverts commit b7d097438b9b0f782a707f3295d320d824810864.
* | | | Merge pull request #211910 from tejing1/srcs-name-collisionSergei Trofimovich2023-01-29
|\ \ \ \ | |/ / / |/| | | stdenv: Improve error from `stdenv` when `srcs` is used with colliding directories
| * | | improve error when srcs is used with directories with the same post-hash nameJeff Huffman2023-01-29
| | | |
* | | | Merge master into staging-nextgithub-actions[bot]2023-01-22
|\ \ \ \ | | |/ / | |/| |
| * | | lib/meta.nix: platformMatch: allow predicate functionsAdam Joseph2023-01-22
| | | |
* | | | Merge branch 'nativeCheckInputs' into staging-nativeCheckInputsGuillaume Girol2023-01-21
|\| | | | |/ / |/| |
| * | mkDerivation: introduce native checkInputs and nativeCheckInputsGuillaume Girol2023-01-21
| |/ | | | | | | | | When strictDeps is set, only nativeCheckInputs are added to PATH and only checkInputs can be linked against. See https://github.com/NixOS/nixpkgs/issues/161570
* | stdenv: don't clobber useArray and type in {prepend,append}ToVarAndrew Childs2023-01-18
| | | | | | | | | | | | | | | | | | | | Some other packages, for example ruby gems via buildRubyGem, use a variable called "type" internally, which is overwritten here and causes failures like: failure: $gempkg path unspecified Fix for changes in 11c3127e38dafdf95ca71a85b1591a29b67e0c09.
* | stdenv: disable shellcheck rule SC2068 & SC1091Artturin2023-01-16
| | | | | | | | | | | | | | | | | | | | | | | | this is intentional to support both structuredAttrs and non In pkgs/stdenv/generic/setup.sh line 614: for pkg in ${depsBuildBuild[@]} ${depsBuildBuildPropagated[@]}; do ^------------------^ SC2068 (error): Double quote array expansions to avoid re-splitting elements. In pkgs/stdenv/generic/setup.sh line 521: local varRef="$varVar[$((targetOffset - hostOffset))]" ^-- SC1087 (error): Use braces when expanding arrays, e.g. ${array[idx]} (or ${var}[.. to quiet).
* | stdenv: fix SC2242Artturin2023-01-16
| | | | | | | | | | | | | | | | | | exit -1 == exit 255 but we don't have a reason to use 255 In pkgs/stdenv/generic/setup.sh line 518: (( hostOffset <= targetOffset )) || exit -1 ^-- SC2242 (error): Can only exit with status 0-255. Other data should be wri tten to stdout/stderr.
* | stdenv: disable shellcheck rule SC2048Artturin2023-01-16
| | | | | | | | | | | | | | | | we use [*] to support structuredAttrs and non In pkgs/stdenv/generic/setup.sh line 1542: for curPhase in ${phases[*]}; do ^----------^ SC2048 (warning): Use "${array[@]}" (with quotes) to prevent whitespace problems.
* | stdenv: disable shellcheck rulesArtturin2023-01-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In pkgs/stdenv/generic/setup.sh line 101: source "$hookName" ^---------^ SC1090 (warning): ShellCheck can't follow non-constant source. Use a directive to specify location. In pkgs/stdenv/generic/setup.sh line 166: mkdir -p "$out/nix-support" ^--^ SC2154 (warning): out is referenced but not assigned. In pkgs/stdenv/generic/setup.sh line 407: PATH= ^--^ SC2123 (warning): PATH is the shell search path. Use another name. In pkgs/stdenv/generic/setup.sh line 452: declare -a pkgBuildAccumVars=(pkgsBuildBuild pkgsBuildHost pkgsBuildTarget) ^---------------^ SC2034 (warning): pkgBuildAccumVars appears unused. Verify use (or export if used e xternally). because pkgBuildAccumVars is used In pkgs/stdenv/generic/setup.sh line 235: nameref="$* ${nameref-}" ^-----^ SC2178 (warning): Variable was used as an array but is now assigned a string. because we theres a useArray conditional
* | stdenv: fix SC2004 & SC2086Artturin2023-01-16
| | | | | | | | | | SC2004 (style): $/${} is unnecessary on arithmetic variables. SC2086 (info): Double quote to prevent globbing and word splitting.
* | stdenv: fix SC2223Artturin2023-01-16
| | | | | | | | | | | | In pkgs/stdenv/generic/setup.sh line 36: : ${outputs:=out} ^-------------^ SC2223 (info): This default assignment may cause DoS due to globbing. Quote it.
* | stdenv: drop remove unnecessary env varArtturin2023-01-15
| | | | | | | | | | | | and the associated obsolete functions support for log nesting was removed in 2017 https://github.com/nixos/nixpkgs/commit/6669a3b47711dc967df0ea8ff93fa9857aad015d
* | Merge pull request #209371 from Artturin/gzipreproArtturi2023-01-15
|\ \ | | | | | | gzip: make reproducible when GZIP_NO_TIMESTAMPS is set
| * | gzip: make reproducible when GZIP_NO_TIMESTAMPS is setArtturin2023-01-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | the logic can be tested with ``` $ GZIP_NO_TIMESTAMPS=1 && echo "${GZIP_NO_TIMESTAMPS:+-n }" -n $ unset GZIP_NO_TIMESTAMPS && echo "${GZIP_NO_TIMESTAMPS:+-n }" ```
* | | Merge staging-next into staginggithub-actions[bot]2023-01-11
|\ \ \ | | |/ | |/|
| * | Merge master into staging-nextgithub-actions[bot]2023-01-11
| |\ \
| | * | check-meta(hasUnsupportedPlatform): use lib.meta.availableOnAdam Joseph2023-01-11
| | |/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `hasUnsupportedPlatform` was not updated with #37395, so it does not understand attrsets in `meta.[bad]platforms`. In particular, attrsets in `meta.badPlatforms` will "fail open" and be ignored. Let's use `lib.meta.availableOn` instead of duplicating its logic. Thanks to @alyssais for [noticing][1]. [1][https://github.com/NixOS/nixpkgs/pull/194148#discussion_r990817610] Co-authored-by: sternenseemann <sternenseemann@systemli.org>
* | / stdenv: don't fail installPhase on missing makefileArtturin2023-01-06
|/ / | | | | | | | | | | | | | | | | otherwise the build just fails with 'make: *** No rule to make target 'install'. Stop.' and update buildPhase message i don't know if the 'makefile may have been created in buildPhase' is true but i guess it might be possible