Commit Graph

2004 Commits

Author SHA1 Message Date
Matthew Bauer
8652631b13 systems/doubles.nix: add mingw doubles
this makes it easier to show what supports windows vs. unix.
2018-10-16 21:56:58 -05:00
Matthew Bauer
0e0894c37d lib/systems: add uname attrs 2018-10-16 21:48:43 -05:00
Léo Gaspard
455e0ed885 generators: make toPretty handle floats correctly 2018-10-15 14:03:16 +02:00
Moritz Kiefer
6738033727
alt-ergo: 1.30->2.2.0, ocplib-simplex: 0.3->0.4 2018-10-13 17:45:45 +00:00
Ryan Mulligan
1bde5ec7e0
Merge pull request #48251 from samueldr/feature/separated-string-description
lib/types: enhances separatedString's description.
2018-10-12 16:41:21 -07:00
Samuel Dionne-Riel
0808c7cd31 lib/types: enhances separatedString's description
The previous description "string" is misleading in the full options
manual pages; they are actually concatenated strings, with a specific
character.

The empty string version ("types.string") has been special-cased to
provide a better message.
2018-10-12 19:11:16 -04:00
Bas van Dijk
fceab3ec62 lib: fix wording of the overrideScope warning 2018-10-11 17:23:47 +02:00
John Ericson
dd428b8f5f
Merge pull request #47980 from lopsided98/armv7l-system-config
lib/systems: use correct config for armv7l-hf-multiplatform
2018-10-09 20:59:50 -04:00
Ben Wolsieffer
50e947f529 lib/systems: use correct config for armv7l-hf-multiplatform 2018-10-06 01:01:07 -04:00
Graham Christensen
4312cfdbda
version.nix: extract revision-fetching function 2018-10-05 11:06:28 -04:00
Graham Christensen
62b3e55923
Merge pull request #47683 from NixOS/docs-lib-options
docs: lib/options.nix function documentation
2018-10-02 17:34:07 -04:00
Tobias Pflug
d5166027e2 docs: lib/options.nix function documentation 2018-10-02 22:05:57 +02:00
Tobias Pflug
1d68b5ee84 docs: documentation for cleanSource 2018-10-02 22:05:06 +02:00
John Ericson
22ce614112
Merge pull request #47238 from obsidiansystems/overrideScope-order
lib: Deprecate `overrideScope` in lieu of `overrideScope'` taking arguments in the conventional order
2018-09-24 18:04:18 -04:00
John Ericson
b9dce11712 lib: Make overrideScope' which takes arguments in the conventional order
The `overrideScope` bound by `makeScope` (via special `callPackage`)
took an override in the form `super: self { … }`. But this is
dangerously close to the `self: super { … }` form used by *everything*
else, even other definitions of `overrideScope`! Since that
implementation did not even share any code either until I changed it
recently in 3cf43547f4be03d1d6eb0bbfc557e2dbc13b4095, this inconsistency
is almost certainly an oversight and not intentional.

Unfortunately, just as the inconstency is hard to debug if one just
assumes the conventional order, any sudden fix would break existing
overrides in the same hard-to-debug way. So instead of changing the
definition a new `overrideScope'` with the conventional order is added,
and old `overrideScope` deprecated with a warning saying to use
`overrideScope'` instead. That will hopefully get people to stop using
`overrideScope`, freeing our hand to change or remove it in the future.
2018-09-24 17:50:11 -04:00
Jörg Thalheim
83d89edc6e
Merge pull request #46336 from Infinisil/overrideExisting
lib: Improve overrideExisting implementation
2018-09-18 11:37:30 +01:00
John Ericson
226d574870 Merge remote-tracking branch 'upstream/master' into darwin-android-ndk-for-master 2018-09-17 22:48:25 -04:00
John Ericson
6769437186 androidndk: Add Darwin support
Also switch Linux to using the official sha1 hashes for consistency.
They are gotten from https://developer.android.com/ndk/downloads/.
2018-09-17 22:34:37 -04:00
Silvan Mosberger
c7104d97c8
lib.overrideExisting: Better example 2018-09-17 23:28:47 +02:00
Silvan Mosberger
afd8620621
lib/tests: Add overrideExisting tests 2018-09-17 22:40:08 +02:00
Graham Christensen
4c7f0714c9
Merge pull request #36287 from shlevy/lib-tests-default
lib/tests: Add check-eval.nix to run simple tests.
2018-09-16 18:38:47 -04:00
Maximilian Bosch
6d6cbd316d pythonmagick: fix build (#46469)
The original build broke with the following linker issue:

```
  CXXLD    _PythonMagick.la
/nix/store/h0lbngpv6ln56hjj59i6l77vxq25flbz-binutils-2.30/bin/ld: cannot find -l-L/nix/store/4gh6ynzsd5ndx37hmkl62xa8z30k43y1-imagemagick-6.9.9-34/lib
collect2: error: ld returned 1 exit status
```

This happens since `BOOST_PYTHON_LIB` wasn't set properly, however
`_PythonMagick.la` was linked with `-l$(BOOST_PYTHON_LIB)
$(MAGICK_LIBS)`. With an empty `BOOST_PYTHON_LIB` the linker got
confused.

To work around this, the `boost` library directory needs to be specified
explicitly. To ensure that the changes take effect, the original
`configure` script shipped with `$src` needs to be removed and recreated
using the `autoreconfHook`.

Additionally the `imagemagick` license (https://spdx.org/licenses/ImageMagick.html)
needs to be added to `lib/licenses.nix` to document the proper license
of `pythonmagick` in the meta section.
2018-09-10 11:59:51 +02:00
Silvan Mosberger
5cfdec6e94
lib: Improve overrideExisting implementation 2018-09-07 21:00:14 +02:00
Profpatsch
efdf618330 lib: move assertMsg and assertOneOf to their own library file
Since the `assertOneOf` uses `lib.generators`, they are not really trivial
anymore and should go into their own library file.
2018-09-06 18:14:27 +02:00
Profpatsch
3e45b61a99 lib/trivial: add a few examples of usage of assertMsg/assertOneOf 2018-09-06 18:14:27 +02:00
Profpatsch
320cdecd16 lib/trivial: add assertOneOf 2018-09-06 18:14:27 +02:00
Profpatsch
0e2aa97f3a lib/trivial: add assertMsg 2018-09-06 18:14:27 +02:00
Shea Levy
18337f3ece
Merge branch 'no-toPath' 2018-09-06 08:09:53 -04:00
xeji
c23ec2794d
Merge pull request #46011 from markuskowa/homepages-2
Cleanup homepage links
2018-09-03 23:32:52 +02:00
Markus Kowalewski
7422953eb0
lsof: add license + update homepage
lib/licenses: add purdue style BSD license
2018-09-03 22:36:27 +02:00
Vladimír Čunát
608730af44
lib/trivial.nix: fix missing parens
Broken in 62dca7c9a; the tricky thing is that it depends on nix version.
Explanation: https://github.com/NixOS/nix/issues/629
2018-09-03 14:18:26 +02:00
Silvan Mosberger
9113696051
Merge pull request #45038 from symphorien/optopt
module system: rework module merging
2018-08-30 20:08:45 +02:00
Jan Tojnar
7d1968c0e3
Nix minimal version: 1.11 -> 2.0
Placeholders are just too convenient.
2018-08-30 08:09:54 -04:00
Jörg Thalheim
9efffe0135 hurd: cleanup unmaintained target
This has been not touched in 6 years. Let's remove it to cause less
problems when adding new cross-compiling infrastructure.
This also simplify gcc significantly.
2018-08-28 22:18:02 +01:00
Symphorien Gibol
526d604670 module system: rework module merging
The asymptotic complexity is now much lower.
2018-08-27 17:11:58 +02:00
Matthew Bauer
379fc894de Merge remote-tracking branch 'origin/master' into staging 2018-08-21 15:41:53 -05:00
CrystalGamma
72d161f548 [RFC] ppc64le enablement (#45340)
* ppc64le enablement

* gcc, glibc: properly handle __float128

* lib/systems, stdenv: syntax cleanup

* gcc7: remove ugly hack

* gcc: add/update __float128 flags

* stdenv: add another pair of quotes for consistency

* gcc: move __float128 flag for ppc64le-glibc into common/platform-flags.nix
2018-08-21 15:31:34 -04:00
Aaron Andersen
343e10aaa6 function rewritten by @Infinisil 2018-08-21 20:11:28 +02:00
Aaron Andersen
74d446176e as requested:
- moved function into strings.nix
- renamed function from makePerl5Lib
- removed duplicates entries in the resulting value
- rewrote the function from scratch after learning a few things (much cleaner now)
2018-08-21 20:11:28 +02:00
John Ericson
3cf43547f4
lib: Use lib.fixed-points.extends to avoid repetition
Another attempt after my sloppy 48ccdf322d.

@Infinisil, thanks again, reverted in 4794aa5de2 and explained my mistakes in 48ccdf322d (commitcomment-29678643). I start with their work and provide this proof of this commit's correctness:
```nix
(lib.fixedPoints.extends (lib.flip g) f) # now
((f: rattrs: self: let super = rattrs self; in super // f self super) (lib.flip g) f) # inline extends
(self: let super = f self; in super // (lib.flip g) self super) # beta reduce
(self: let super = f self; in super // g super self)  # beta reduce
(self_: let super = f self_; in super // g super self_)  # alpha rename
(self_: let super = f self_; in super // g super self_) # original, same
```

Eventually we might harmonize `overrideScope`'s `g` parameter with the general pattern, but I leave that breaking change as a separate step. Best not to refactor and break at once, and at least the abstractions make the oddity clearer.
2018-08-20 13:09:15 -04:00
Markus Kowalewski
6d95b55d3c
xfig: 3.2.5b -> 3.2.7a
init fig2dev as separate package (3.2.7a).
fig2dev was included in xfig in the previous version.
2018-08-20 00:43:11 +02:00
Markus Kowalewski
17702d0416
curl: add license 2018-08-16 21:38:59 +02:00
zimbatm
9976f37c77
Merge pull request #44896 from cdepillabout/vbox-extpack
add derivation for the virtualbox oracle extension pack
2018-08-15 18:05:07 +01:00
Profpatsch
d817452e29 lib/recursiveUpdateUntil: add a test & release note for fix 2018-08-15 17:16:56 +02:00
Mathijs Kwik
b63ec64521 lib/recursiveUpdateUntil: fix code to match documentation
$ nix repl lib
Welcome to Nix version 2.0.2. Type :? for help.

Loading 'lib'...
Added 350 variables.

-- this is the exact example from the function's documentation:
nix-repl> recursiveUpdateUntil (path: l: r: path == ["foo"]) {
                   # first attribute set
                   foo.bar = 1;
                   foo.baz = 2;
                   bar = 3;
                 } {
                   #second attribute set
                   foo.bar = 1;
                   foo.quz = 2;
                   baz = 4;
                 }
{ bar = 3; baz = 4; foo = { bar = 1; baz = 2; quz = 2; }; }

-- although the documentation says:
{
    foo.bar = 1; # 'foo.*' from the second set
    foo.quz = 2; #
    bar = 3;     # 'bar' from the first set
    baz = 4;     # 'baz' from the second set
}
2018-08-15 17:16:56 +02:00
(cdep)illabout
18869d85f9
Add the virtualbox-puel license to the licenses file. 2018-08-08 23:21:18 +09:00
Matthew Bauer
a22797d356 systems: fix netbsd triple parsing
binutils expects x86_64-unknown-netbsd<version> (only 3 parts!). Any other combo seems to fail.

Also handle darwin versions similarly.

/cc @Ericson2314
2018-07-28 19:54:09 -04:00
Bas van Dijk
ebcdb822f8 elk: 6.2.4 -> 6.3.2
* The ELK stack is upgraded to 6.3.2.

* `elasticsearch6`, `logstash6` and `kibana6` now come with X-Pack which is
  a suite of additional features. These are however licensed under the unfree
  "Elastic License".

* Fortunately they also provide OSS versions which are now packaged
  under: `elasticsearch6-oss`, `logstash6-oss` and `kibana6-oss`.
  Note that the naming of the attributes is consistent with upstream.

* The test `nix-build nixos/tests/elk.nix -A ELK-6` will test the OSS
  version by default. You can also run the test on the unfree ELK using:
  `NIXPKGS_ALLOW_UNFREE=1 nix-build nixos/tests/elk.nix -A ELK-6 --arg enableUnfree true`
2018-07-28 00:01:31 +02:00
Profpatsch
62dca7c9ab lib/trivial: move zipIntBits to its own file
The amount of implementation detail really should not be the first thing in a
prominent file called `trivial.nix`.
2018-07-26 20:36:45 +02:00
Profpatsch
af10842940 lib/trivial: unify & improve docstrings
- add section headers
- unify comment syntax
- add examples

Tested with:
nix-instantiate --strict --eval ./lib/tests/misc.nix
2018-07-26 20:36:45 +02:00