summary refs log tree commit diff
path: root/doc/stdenv
Commit message (Collapse)AuthorAge
* doc: avoid 'simply' (#266434)Arnout Engelen2023-11-09
| | | | | | | | | While the word 'simply' is usually added to encourage readers, it often has the opposite effect and may even appear condescending, especially when the reader runs into trouble trying to apply the suggestions from the documentation. It is almost always an improvement to simply drop the word from the sentence. (there are more possible improvements like this, we can apply those in separate PRs)
* doc: rename sub-section Recursive attributes in stdenv -> Fixed-point ↵Yueh-Shun Li2023-11-07
| | | | | | arguments in stdenv Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
* doc/stdenv: rewrite manual build procedure to be closer to an auto-build ↵Jade Lovelace2023-10-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (#262137) * doc/stdenv: rewrite manual build procedure to be closer to an auto-build This is based on <https://jade.fyi/blog/building-nix-derivations-manually/> plus some more original research. The previous version of this section did not work for your choice of simple Haskell package, e.g. haskellPackages.hscolour, due to things like `compileBuildDriverPhase` and other custom phases that it does not address at all. It seems more correct to use genericBuild in development to harmonize it with what is actually done. I feel a little bit like I am committing a sin by suggesting using the experimental CLI in the manual (afaict I am the first to do this), but I have given the old version of the command, and there are justifiable reasons to do it: * The noted limitations with env-vars are fixed. The one with the non-empty temp directory was one I ran into myself and oh boy was that not fun to debug. * Additionally the outputs are set *before* sourcing `setup.sh`: there is an issue with nix-shell where the original version of `$out` winds up in `NIX_LDFLAGS` due to _addRpathPrefix, which means that resulting executables may not run properly. It is sad that `nix develop` propagates a wrong value of `SHELL` to builders, though. It is equally sad that `nix-shell` is essentially abandoned upstream, with undocumented and not insignificant differences from `nix develop`. For the exact script differences: https://github.com/NixOS/nix/blob/17e6b85d05b3d32df244b1d4e89aa41fd8bdcae8/src/nix-build/nix-build.cc#L516-L551 https://github.com/NixOS/nix/blob/db026103b18fb8b5a719594502edd0f89eb9c268/src/nix/get-env.sh Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
* nixpkgs manual: add an alternative example in stdenv-separateDebugInfo (#257861)Alejandro Sánchez Medina2023-09-29
| | | | | | | | * nixpkgs manual: add an alternative example in stdenv-separateDebugInfo This change gets rid of the indirect reference to `nix-env -i` usage and shows how to achieve the same goal with a shell expression. Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
* doc: fix wrong flag in description of `bindnow`Felix Yan2023-09-27
| | | `-z bindnow` doesn't exist. The actual flag added is `-z now`.
* remove the misleading warning on using `nix-env` for split outputs (#255947)Valentin Gagarin2023-09-25
| | | | | | | | | | | | | | | | | | | | The text was originally added [0] following an apparently incomplete research on how everything plays together. In fact, Nix propagates `outputs` to the corresponding nested derivations, and there is some messy behavior in Nixpkgs that only seems to propagate `meta.outputsToInstall` in `buildEnv`[1]. This change moves the hints on how to use NixOS specifics to NixOS module documentation (which is hopefully easier to find through search.nixos.org), describes the default behavior in Nixpkgs (updating a the link to the source), and removes the confusing mention of `nix-env`. the last of them should not be there to begin with. we don't want beginners to use `nix-env`, as this is known to run them into trouble eventually. [0]: https://github.com/NixOS/nixpkgs/pull/76794 [1]: https://github.com/NixOS/nixpkgs/blob/1774d07242995050d2d8a91cb4da0855eac2e472/pkgs/build-support/buildenv/default.nix#L66
* Merge pull request #254967 from nbraud/sha256-to-hash/top-levelMaciej Krüger2023-09-15
|\
| * doc: Replace `sha256` with `hash` where appropriatenicoo2023-09-13
| |
* | doc: link, instead of just mentioning, Nix manual (#255126)asymmetric2023-09-14
| | | | | | | | Instead of just telling the reader to go find the relevant section of the Nix manual, let's just link to it. Yay hypertext!
* | Link to usage of pkg description instead of referring to nix-env (#255127)Maximilian Ehlers2023-09-14
| | | | | | | | | | | | | | * Updates meta.chapter.md with a reference link to the usage of the package description field instead of referring to nix-env --------- Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
* | Merge pull request #218783 from timbertson/stripExcludeExtensionsArtturi2023-09-05
|\ \ | |/ |/|
| * setup-hooks/strip: add stripExcludeTim Cuthbertson2023-09-03
| |
* | Merge pull request #245583 from galenhuntington/doc-fixArtturi2023-08-29
|\ \ | |/ |/|
| * doc/stdenv: Minor syntax fix.Galen Huntington2023-07-26
| |
* | doc/stdenv/stdenv.chapter.md: add information about nix-update-script and ↵Nick Hu2023-08-15
| | | | | | | | nixpkgs-update
* | treewide: update mainProgram docsArtturin2023-08-04
| |
* | doc: make `sourceRoot` and `setSourceRoot` documentation match the ↵Jan Malakhovski2023-08-03
|/ | | | implementation, fix examples
* doc: render nixpkgs manual with nrdpennae2023-07-01
| | | | | | also updates nixdoc to 2.3.0. the nixdoc update is not a separate commit because that would leave the manual build broken for one commit, potentially breaking bisects and rebases.
* Merge pull request #237068 from pennae/manual-normalizationValentin Gagarin2023-06-13
|\
| * doc: normalize markdown for nixos-render-docspennae2023-06-10
| | | | | | | | | | | | pandoc recognizes `::: note` admonitions, nixos-render-docs only recognizes `::: {.note}`. surprisingly pandoc also emits the correct docbook tags for `[](#xref)`s, so we can use that too.
* | doc: correct typos and spelling (#237098)Andrew2023-06-11
|/
* doc: clarify that meta.timeout is only for HydraAlyssa Ross2023-05-30
| | | | | | I read this and expected it to be a timeout that was always applied when building the derivation, but it's actually a Hydra-specific thing.
* doc: fix typoNicolas Benes2023-05-20
|
* doc/stdenv/Dependencies: fix inference rule var nameJan Tojnar2023-05-18
| | | t0 is mentioned in the conclusion so we cannot use placeholder in the premise.
* doc/stdenv/meta.chapter.md: document meta.badPlatforms (#225276)Adam Joseph2023-04-24
| | | | | | | * doc/stdenv/meta.chapter.md: document meta.badPlatforms We don't have any documentation for the `meta.badPlatforms` attribute. This commit adds documentation for it.
* Merge pull request #225272 from amjoseph-nixpkgs/pr/docs/broken-vs-badPlatformsAdam Joseph2023-04-24
|\ | | | | doc/stdenv/meta.chapter.md: explain difference between broken and badPlatforms
| * remove trailing whitespaceAdam Joseph2023-04-23
| |
| * Update doc/stdenv/meta.chapter.mdAdam Joseph2023-04-24
| | | | | | Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
| * Update doc/stdenv/meta.chapter.mdAdam Joseph2023-04-24
| | | | | | Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
| * doc/stdenv/meta.chapter.md: explain difference between broken and badPlatformsAdam Joseph2023-04-11
| | | | | | | | | | | | | | | | | | | | | | There has been a longstanding ambiguity between `broken` and `badPlatforms`, which seem to serve overlapping purposes. This commit adds to the documentation two examples of constraints which cannot be expressed by `platforms` and `badPlatforms`. This commit also mentions `NIXPKGS_ALLOW_BROKEN=1` for overriding `broken`.
* | doc/stdenv: don't use name in examples, highlight preferring pnamegilice2023-04-15
|/
* doc: assign ids to many headingspennae2023-03-27
| | | | | | | | | | without stable ids on headings we cannot generate stable links to these headings. nrd complains about this, but the current docbook workflow does not. a few generated ids remain, mostly in examples and footnotes. most of the examples are generated by nixdoc (which has since gained MD export functions, and the MD export does generate IDs).
* Merge pull request #200951 from jtojnar/docs-update-script-commit-featureValentin Gagarin2023-03-21
|\ | | | | docs/stdenv: Document updateScript features
| * docs/stdenv: Document updateScript featuresJan Tojnar2023-03-21
| | | | | | | | | | This was removed in https://github.com/NixOS/nixpkgs/commit/c1b05442ffd6cf3cf529cad469bebe8169b156e9 for stabilization but it has worked quite well.
| * docs/stdenv: Document updateScript executionJan Tojnar2023-03-21
| |
* | doc/stdenv: add quotes to run phases with newlinesArnout Engelen2023-03-17
| | | | | | | | | | Without quotes newlines in environment variables get converted to spaces, so any overridden phases would not work.
* | treewide: manual fixups forArtturin2023-02-22
| | | | | | | | | | treewide: use toString on list NIX_CFLAGS_COMPILE treewide: move NIX_CFLAGS_COMPILE to the env attrset
* | docs: Building a stdenv package in nix-shell (#216650)milahu2023-02-16
| | | | | | * docs: Building a stdenv package in nix-shell
* | doc: add a simpler explanation of dependencies (#213403)Guillaume Girol2023-02-10
| | | | | | | | | | Co-authored-by: Jan Tojnar <jtojnar@gmail.com> Co-authored-by: pennae <82953136+pennae@users.noreply.github.com> Co-authored-by: Valentin Gagarin <valentin.gagarin@tweag.io>
* | doc/stdenv: fixup #212642Naïm Favier2023-02-07
| |
* | Merge master into staging-nextgithub-actions[bot]2023-01-26
|\ \
| * | doc/stdenv: clarify default check targetNaïm Favier2023-01-25
| | |
* | | Merge branch 'nativeCheckInputs' into staging-nativeCheckInputsGuillaume Girol2023-01-21
|\| |
| * | doc: adapt to nativeCheckInputsGuillaume Girol2023-01-21
| | |
| * | cross-compilation.chapter.md: correct doCheck conditionalArtturin2023-01-20
| | |
* | | multi-outputs.sh: Improve _assignFirst error messageRobert Hensing2023-01-16
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Closes #16182 This improves the error message Error: _assignFirst found no valid variant! which occurred when the set of outputs was not sufficient to set the various outputDev, outputBin, etc variables. Specifically, this would mean that "out" is not among the outputs, which is valid for a derivation. This changes the message to something like error: _assignFirst: could not find a non-empty variable to assign to outputDev. The following variables were all unset or empty: dev out. If you did not define an "out" output, make sure to define all the specific required outputs: define an output for one of the unset variables. While this isn't a full explanation of what stdenv can and can not do, I think it's vast improvement over the 0 bits of information that it used to provide. This at least gives a clue as to what's going on, and even suggests a fix, although probably multiple such fixes are required in an instance where someone starts with a no-out derivation from scratch (and decide to persist).
* | Merge remote-tracking branch 'origin/master' into staging-nextMartin Weinelt2023-01-11
|\ \
| * \ Merge pull request #208252 from helsinki-systems/doc/doDistValentin Gagarin2023-01-10
| |\ \ | | | | | | | | doc/stdenv: Add information about the doDist variable
| | * | doc/stdenv: Add information about the doDist variableMax Hausch2023-01-09
| | | |
* | | | Merge master into staging-nextgithub-actions[bot]2023-01-09
|\| | |