summary refs log tree commit diff
path: root/pkgs/stdenv/adapters.nix
Commit message (Collapse)AuthorAge
* ~/.nixpkgs -> ~/.config/nixpkgsEelco Dolstra2017-02-01
| | | | | | The former is still respected as a fallback for config.nix for backwards compatibility (but not for overlays because they're a new feature).
* stdenv: Add updateAutoconfGnuConfigScriptsHook for aarch64Tuomas Tynkkynen2017-01-25
| | | | | | | | | | | This is required for Aarch64 since a lot of source tarballs ship with outdated configure scripts that don't recognize aarch64. Simply replacing the config.guess and config.sub with new versions from upstream makes them build again. This same approach is used by at least Buildroot and Fedora. In principle this could be enabled for all architectures but conditionalizing this on aarch64 avoids a mass rebuild on x86.
* cross-stdenv: Inline useless bindings and reindentJohn Ericson2017-01-24
| | | | Semantics should be unchanged
* top-level: Lay the groundwork for `{build,host,target}Platform`John Ericson2017-01-24
| | | | | | | | | | | | The long term goal is a big replace: { inherit system platform; } => buildPlatform crossSystem => hostPlatform stdenv.cross => targetPlatform And additionally making sure each is defined even when not cross compiling. This commit refactors the bootstrapping code along that vision, but leaves the old identifiers with their null semantics in place so packages can be modernized incrementally.
* top-level: Introduce `buildPackages` for resolving build-time depsJohn Ericson2017-01-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [N.B., this package also applies to the commits that follow it in the same PR.] In most cases, buildPackages = pkgs so things work just as before. For cross compiling, however, buildPackages is resolved as the previous bootstrapping stage. This allows us to avoid the mkDerivation hacks cross compiling currently uses today. To avoid a massive refactor, callPackage will splice together both package sets. Again to avoid churn, it uses the old `nativeDrv` vs `crossDrv` to do so. So now, whether cross compiling or not, packages with get a `nativeDrv` and `crossDrv`---in the non-cross-compiling case they are simply the same derivation. This is good because it reduces the divergence between the cross and non-cross dataflow. See `pkgs/top-level/splice.nix` for a comment along the lines of the preceding paragraph, and the code that does this splicing. Also, `forceNativeDrv` is replaced with `forceNativePackages`. The latter resolves `pkgs` unless the host platform is different from the build platform, in which case it resolves to `buildPackages`. Note that the target platform is not important here---it will not prevent `forcedNativePackages` from resolving to `pkgs`. -------- Temporarily, we make preserve some dubious decisions in the name of preserving hashes: Most importantly, we don't distinguish between "host" and "target" in the autoconf sense. This leads to the proliferation of *Cross derivations currently used. What we ought to is resolve native deps of the cross "build packages" (build = host != target) package set against the "vanilla packages" (build = host = target) package set. Instead, "build packages" uses itself, with (informally) target != build in all cases. This is wrong because it violates the "sliding window" principle of bootstrapping stages that shifting the platform triple of one stage to the left coincides with the next stage's platform triple. Only because we don't explicitly distinguish between "host" and "target" does it appear that the "sliding window" principle is preserved--indeed it is over the reductionary "platform double" of just "build" and "host/target". Additionally, we build libc, libgcc, etc in the same stage as the compilers themselves, which is wrong because they are used at runtime, not build time. Fixing this is somewhat subtle, and the solution and problem will be better explained in the commit that does fix it. Commits after this will solve both these issues, at the expense of breaking cross hashes. Native hashes won't be broken, thankfully. -------- Did the temporary ugliness pan out? Of the packages that currently build in `release-cross.nix`, the only ones that have their hash changed are `*.gcc.crossDrv` and `bootstrapTools.*.coreutilsMinimal`. In both cases I think it doesn't matter. 1. GCC when doing a `build = host = target = foreign` build (maximally cross), still defines environment variables like `CPATH`[1] with packages. This seems assuredly wrong because whether gcc dynamically links those, or the programs built by gcc dynamically link those---I have no idea which case is reality---they should be foreign. Therefore, in all likelihood, I just made the gcc less broken. 2. Coreutils (ab)used the old cross-compiling infrastructure to depend on a native version of itself. When coreutils was overwritten to be built with fewer features, the native version it used would also be overwritten because the binding was tight. Now it uses the much looser `BuildPackages.coreutils` which is just fine as a richer build dep doesn't cause any problems and avoids a rebuild. So, in conclusion I'd say the conservatism payed off. Onward to actually raking the muck in the next PR! [1]: https://gcc.gnu.org/onlinedocs/gcc/Environment-Variables.html
* Remove more dead code: `stdenvDarwinNaked` no longer existsJohn Ericson2016-06-20
|
* Remove dead code in stdenvCross adaptorJohn Ericson2016-06-20
|
* stdenv on mingw: fix 64-bin DLL detection in some casesVladimír Čunát2016-04-23
| | | | | In particular, this makes 64-bit libpng create DLL now, and thus depending packages won't fail anymore (e.g. freetype).
* useOldCXXAbi: Change into a setup hookEelco Dolstra2016-04-01
| | | | Stdenv adapters considered weird.
* stdenvAdapters.useOldCXXAbi: add new adapterNikolay Amiantov2016-03-31
|
* enableDebugging: use more suitable gcc flagsVladimír Čunát2015-08-10
| | | | | -ggdb is supposed to provide better symbol information when used with gdb -Og is the recommended optimization level for debugging purposes
* useGoldLinker: Fix appending to $NIX_CFLAGS_LINKEelco Dolstra2015-05-04
|
* Fix cross compiling regression due to gcc->cc renaming.Ambroz Bizjak2015-02-05
|
* rename gcc-wrapper to cc-wrapper.Eric Seidel2015-01-14
| | | | also makes cc-wrapper compatible with clang in the darwin fork.
* Restore accidentally-dropped stdenv adapterShea Levy2014-12-26
|
* Change occurrences of gcc to the more general ccJohn Wiegley2014-12-26
| | | | | This is done for the sake of Yosemite, which does not have gcc, and yet this change is also compatible with Linux.
* Merge remote-tracking branch 'origin/glibc-2.20' into stagingEelco Dolstra2014-11-16
|\
| * Remove obsolete useKlibc stdenv adapterEelco Dolstra2014-10-29
| |
| * Remove obsolete useDietLibC stdenv adapterEelco Dolstra2014-10-29
| |
* | useGoldLinker: Don't set dontStripEelco Dolstra2014-11-12
| | | | | | | | Probably caused by a bad cut&paste...
* | gcc-wrapper: Wrap ld.goldEelco Dolstra2014-10-10
| | | | | | | | This ensures that gcc's ‘-fuse-ld=gold’ flag works.
* | Merge remote-tracking branch 'origin/staging' into darwin-clang-stdenvEelco Dolstra2014-10-09
|\| | | | | | | | | Conflicts: pkgs/tools/security/gnupg/default.nix
| * stdenv-linux: Turn allowedRequisites back onEelco Dolstra2014-10-06
| |
* | fix even more clang buildsJoel Taylor2014-09-09
|/
* Typo/commentEelco Dolstra2014-04-22
|
* Move generation of coverage reports from nixos/lib/testing to releaseToolsEelco Dolstra2014-03-03
| | | | Also, turn some stdenv adapters into setup hooks.
* Turn the coverage analysis stdenv adapters into setup hooksEelco Dolstra2014-02-05
| | | | | | | Stdenv adapters are kinda weird and un-idiomatic (especially when they don't actually change stdenv). It's more idiomatic to say buildInputs = [ makeCoverageAnalysisReport ];
* addCoverageInstrumentation: Set NIX_CFLAGS_COMPILE as an attributeEelco Dolstra2014-02-05
| | | | This allows it to show up in nix-shell.
* Apply makeOverridable to stdenvEelco Dolstra2014-02-05
| | | | | | This removes the need for hacks like stdenv.regenerate. It also ensures that overrideGCC is now stackable (so ‘stdenv = useGoldLinker clangStdenv’ works).
* Add a stdenv adapter ‘useGoldLinker’ to force use of GoldEelco Dolstra2014-02-05
|
* More renamesEelco Dolstra2012-12-28
|
* More random cleanupEelco Dolstra2012-12-28
|
* Random cleanup: use "or" in adapters.nixEelco Dolstra2012-12-28
|
* Rename buildNativeInputs -> nativeBuildInputsEelco Dolstra2012-12-28
| | | | | Likewise for propagatedBuildNativeInputs, etc. "buildNativeInputs" sounds like an imperative rather than a noun phrase.
* Rename hostDrv -> crossDrv, buildDrv -> nativeDrvEelco Dolstra2012-12-28
| | | | | | This is for consistency with terminology in stdenv (and the terms "hostDrv" and "buildDrv" are not very intuitive, even if they're consistent with GNU terminology).
* Add a stdenv adapter ‘keepDebugInfo’ to make a debug buildEelco Dolstra2012-10-31
| | | | | | | | | This adapter causes the resulting binaries to have debug info and no optimisations. Example use (in all-packages.nix): foo = callPackage ./foo.nix { stdenv = keepDebugInfo stdenv; };
* * "ensureDir" -> "mkdir -p". "ensureDir" is a rather pointlessEelco Dolstra2012-01-18
| | | | | | function, so obsolete it. svn path=/nixpkgs/branches/stdenv-updates/; revision=31644
* * Streamline the stdenv bootstrap and resulting closure by removingEelco Dolstra2011-12-14
| | | | | | | | | | | some redundant builds (e.g., GMP was built three times). * Updated GMP to 5.0.2. * Updated PPL to 0.11.2. * Remove ad hoc flags to build GCC's dependencies statically. Instead, use the ‘makeStaticLibraries’ stdenv adapter. * Build GMP with C++ support by default. svn path=/nixpkgs/branches/stdenv-updates/; revision=30891
* validateLicenses: Warn about derivations lacking licensing information.Ludovic Courtès2011-11-20
| | | | svn path=/nixpkgs/trunk/; revision=30496
* stdenv adapters: Use `toString' instead of `exprToString'.Ludovic Courtès2011-11-20
| | | | svn path=/nixpkgs/trunk/; revision=30494
* Bootstrap clang with itselfShea Levy2011-10-19
| | | | svn path=/nixpkgs/trunk/; revision=29901
* * Typo.Eelco Dolstra2011-07-01
| | | | svn path=/nixpkgs/trunk/; revision=27569
* * makeStaticBinaries: handle the case where configureFlags isEelco Dolstra2011-01-20
| | | | | | an array. svn path=/nixpkgs/trunk/; revision=25641
* Making the addCoverageInformation stdenv adapter better in the sense that itLluís Batlle i Rossell2010-11-30
| | | | | | | | | | does not override NIX_CFLAGS_COMPILE anymore in the mkDerivation parameter attributes. This way, apacheHttpd can be built properly with coverage information. An indication of this problem came from the nixos tests.subversion failure. svn path=/nixpkgs/branches/stdenv-updates/; revision=24938
* Updating from trunkLluís Batlle i Rossell2010-08-07
|\ | | | | | | svn path=/nixpkgs/branches/stdenv-updates/; revision=23027
| * TyposYury G. Kudryashov2010-08-06
| | | | | | | | svn path=/nixpkgs/trunk/; revision=23011
* | Making gcc cross-buildable, at least for glibc.Lluís Batlle i Rossell2010-03-06
|/ | | | svn path=/nixpkgs/branches/stdenv-updates/; revision=20454
* Fixing the cross build stdenv adapter so it tolerates buildInputs with ↵Lluís Batlle i Rossell2010-03-04
| | | | | | 'null' elements. svn path=/nixpkgs/trunk/; revision=20381
* Adding a new special attribute for mkDerivation: crossAttrs. It sits next toLluís Batlle i Rossell2010-02-27
| | | | | | | | | "meta" and "passthru", and these attributes will be appended to the usual mkDerivation attributes only if the package is cross built. This allows putting some of the cross-building logic in the mkDerivation nix parameters, and not only in the final builder script, as it was until now. svn path=/nixpkgs/trunk/; revision=20272
* * Fix splashutils.Eelco Dolstra2010-01-26
| | | | svn path=/nixpkgs/branches/stdenv-updates/; revision=19662