summary refs log tree commit diff
path: root/lib
AgeCommit message (Collapse)AuthorFilesLines
2019-02-16Merge master into staging-nextFrederik Rietdijk1-1/+1
2019-02-13Merge pull request #55129 from oxij/tree/move-defaults-to-package-filesMichael Raskin1-1/+1
all-packages.nix: move defaults to package files
2019-02-03lib: tiny cleanupJan Malakhovski1-1/+1
2019-02-01Merge branch 'staging-next' into stagingVladimír Čunát5-86/+32
2019-02-01Merge branch 'master' into staging-nextVladimír Čunát5-86/+32
Comments on conflicts: - llvm: d6f401e1 vs. 469ecc70 - docs for 6 and 7 say the default is to build all targets, so we should be fine - some pypi hashes: they were equivalent, just base16 vs. base32
2019-01-31types.optionSet: deprecate and remove last usagesdanbst3-23/+3
2019-01-30lib/modules.nix: small eval optimization (foldl' + foldl' + attrNames -> ↵danbst1-12/+14
foldl' + mapAttrs)
2019-01-30lib/types.nix: small eval optimization (listToAttrs + mapAttrsToList -> ↵danbst1-2/+1
mapAttrs)
2019-01-28linux: convert hardened-config to a structured oneMatthieu Coudron2-2/+6
2019-01-28linux: ability to merge structured configsMatthieu Coudron2-49/+9
This should make the composability of kernel configurations more straigthforward. - now distinguish freeform options from tristate ones - will look for a structured config in kernelPatches too one can now access the structuredConfig from a kernel via linux_test.configfile.structuredConfig in order to reinject it into another kernel, no need to rewrite the config from scratch The following merge strategies are used in case of conflict: -- freeform items must be equal or they conflict (mergeEqualOption) -- for tristate (y/m/n) entries, I use the mergeAnswer strategy which takes the best available value, "best" being defined by the user (by default "y" > "m" > "n", e.g. if one entry is both marked "y" and "n", "y" wins) -- if one item is both marked optional/mandatory, mandatory wins (mergeFalseByDefault)
2019-01-27systems/default.nix: wasm in platform.uname.systemMatthew Bauer1-0/+1
This adds the "Wasm" system to platform.uname.system. This is used in CMake infrastructure.
2019-01-19Merge #51447: libpng: 1.6.35 -> 1.6.36, license v2Vladimír Čunát1-0/+5
(into staging)
2019-01-19Merge staging-next into stagingFrederik Rietdijk2-6/+7
2019-01-18Merge pull request #50561 from oxij/lib/setPrioMichael Raskin2-6/+7
lib: implement `setPrio`
2019-01-15Merge staging-next into stagingFrederik Rietdijk5-6/+140
2019-01-14Merge pull request #53397 from cdepillabout/aliasoptionmodule-set-priorityNicolas B. Pierron5-6/+140
lib/modules: Add function to create option alias that respects priority
2019-01-13Merge staging-next into stagingFrederik Rietdijk2-0/+5
2019-01-10Merge pull request #53754 from danbst/lib-fake-hashesJörg Thalheim2-0/+5
lib: add fake hashes
2019-01-10lib: add shortcuts for fake hashes (fakeSha256, fakeSha512)danbst2-0/+5
Fake hashes can be used as placeholders for all the places, where Nix expression requires a hash, but we don't yet have one. This should be more convenient than following: - echo|sha256sum, copy into clipboard, go to editor, paste into previously edited place - search nixpkgs for a random package, copy it's hash to cliboard, go to editor, paste into previously edited place Nix can add support for these fake hashes. In that case printed error should contain only 1 hash, so no more problem "which of two hashes from error should I use?" Idea by irc:Synthetica
2019-01-06add generic x86_32 support (#52634)Daniel Goertzen2-1/+4
* add generic x86_32 support - Add support for i386-i586. - Add `isx86_32` predicate that can replace most uses of `isi686`. - `isi686` is reinterpreted to mean "exactly i686 arch, and not say i585 or i386". - This branch was used to build working i586 kernel running on i586 hardware. * revert `isi[345]86`, remove dead code - Remove changes to dead code in `doubles.nix` and `for-meta.nix`. - Remove `isi[345]86` predicates since other cpu families don't have specific model predicates. * remove i386-linux since linux not supported on that cpu
2019-01-06Add test that shows that the aliases are able to override options.(cdep)illabout2-0/+55
2019-01-06Pull out defaultPriority to a top-level definition.(cdep)illabout1-5/+5
2019-01-05Merge branch 'master' into staging-nextVladimír Čunát1-4/+9
A few more rebuilds (~1k on x86_64-linux).
2019-01-04Merge pull request #53029 from Ericson2314/windows-ce-armJohn Ericson1-4/+9
lib: Fix Mingw on 32-bit ARM
2019-01-04lib: Fix Mingw on 32-bit ARMJohn Ericson1-4/+9
2019-01-04lib/modules: Add a function to create an option alias that respects the priority(cdep)illabout3-5/+29
This commit adds a function `mkAliasOptionModuleWithPriority`. This function will make an alias to an existing option and copy over the priority. This functionality is needed for PRs like #53041. In that case `nixos-generate-config` added an option to `hardware-configuration.nix` with `mkDefault`. That option was then changed and an alias created for the old name. The end user should be able to set the non-alias option in their `configuration.nix` and have everything work correctly. Without this function, the priority for the option won't be copied over correctly and the end-user will get a message saying they have the same option set to two different values.
2019-01-04Add a failing test for mkAliasOptionModule.(cdep)illabout2-0/+55
2018-12-31Merge master into staging-nextFrederik Rietdijk4-275/+3
2018-12-30Remove composableDerivation, closes #18763Frederik Rietdijk4-275/+3
2018-12-29libpng2: link to license, SPDX seems geared to old versionWill Dietz1-1/+1
See https://github.com/NixOS/nixpkgs/pull/51447 for some discussion.
2018-12-29libpng: 1.6.35 -> 1.6.36, license v2Will Dietz1-0/+5
2018-12-25Merge branch 'master' into stagingJan Tojnar2-26/+35
2018-12-24licenses: update SPDX IDs (#52711)Orivej Desh1-23/+32
See the bottom of https://spdx.org/licenses/ for the list of deprecations. The explicit URLs of agpl3Plus and gpl2Classpath were dropped because the default SPDX URL is correct. wxWindows ID had wrong capitalization.
2018-12-18Initial attempt to restore Android NDK cross buildingSander van der Burg1-3/+3
2018-12-18Merge branch 'staging' into make-perl-pathdvolth5-3/+28
2018-12-16Merge remote-tracking branch 'upstream/master' into stagingJan Tojnar4-2/+27
2018-12-15lib.makePerlPath -> perlPackages.makePerlPathvolth2-21/+1
2018-12-12Merge pull request #51884 from alyssais/bundlerEnv-groupsAlyssa Ross3-2/+21
bundlerEnv: improve handling of groups
2018-12-12platform.emulator: fix non-x86 systemsJörg Thalheim1-1/+1
2018-12-12ikos: init at 2.1Etienne Laurin1-0/+6
2018-12-11bundlerEnv: ensure dependencies always includedAlyssa Ross3-2/+21
Suppose I have a Gemfile like this: source "https://rubygems.org" gem "actioncable" gem "websocket-driver", group: :test The gemset.nix generated by Bundix 2.4.1 will set ActionCable's groups to [ "default" ], and websocket-driver's to [ "test" ]. This means that the generated bundlerEnv wouldn't include websocket-driver unless the test group was included, even though it's required by the default group. This is arguably a bug in Bundix (websocket-driver's groups should probably be [ "default" "test" ] or just [ "default" ]), but there's no reason bundlerEnv should omit dependencies even given such an input -- it won't necessarily come from Bundix, and it would be good for bundlerEnv to do the right thing. To fix this, filterGemset is now a recursive function, that adds dependencies of gems in the group to the filtered gemset until it stabilises on the gems that match the required groups, and all of their recursive dependencies.
2018-12-02systems/parse.nix: support eabihfMatthew Bauer2-10/+17
eabihf is an abi that can be used with ARM architectures that support the “hard float”. It should probably only be used with ARM32 when you are absolutely sure your binaries will run on ARM systems with a FPU. Also, add an example "armhf-embedded" to match the preexisting arm-embedded system. qmk_firmware needs hard float in a few places, so add them here to get that to work. Fixes #51184
2018-11-30Merge master into staging-nextFrederik Rietdijk2-5/+48
2018-11-29Merge pull request #50212 from matthewbauer/host-emulatorMatthew Bauer2-5/+48
Add "emulator" function to systems
2018-11-29treewide: add emulator to platformMatthew Bauer1-0/+40
You can use stdenv.hostPlatform.emulator to get an executable that runs cross-built binaries. This could be any emulator. For instance, we use QEMU to emulate Linux targets and Wine to emulate Windows targets. To work with qemu, we need to support custom targets. I’ve reworked the cross tests in pkgs/test/cross to use this functionality. Also, I’ve used talloc to cross-execute with the emulator. There appears to be a cross-execute for all waf builds. In the future, it would be nice to set this for all waf builds. Adds stdenv.hostPlatform.qemuArch attrbute to get the qemuArch for each platform.
2018-11-29systems/examples.nix: move riscv function to let bindingMatthew Bauer1-5/+8
Makes it easier to use mapAttrs with lib.systems.examples. Now every entry in it are legitimate systems.
2018-11-22lib: implement `setPrio`Jan Malakhovski2-6/+7
For when `hiPrio` and `lowPrio` are not enough.
2018-11-22Merge master into staging-nextFrederik Rietdijk2-0/+15
2018-11-21Merge pull request #50532 from typetetris/add-extends-exampleRobert Hensing1-0/+12
lib/fixed-points.nix: add an example for extends
2018-11-21lib/fixed-points.nix: add an example for extendsEric Wolf1-0/+12
- helped me understand how extends works, hopefully it can help others too