Commit graph

329 commits

Author SHA1 Message Date
Eelco Dolstra
e4a2a08b04 Merge remote-tracking branch 'origin/master' into nixpkgs-22.11 2022-11-30 13:09:45 +01:00
Linus Heckemann
9c90452f9d bump nixpkgs to 22.11 beta 2022-11-29 12:06:57 +01:00
Eelco Dolstra
f1b5c6876b Add tests for auto-uid-allocation, uid-range and cgroups 2022-11-27 16:38:34 +01:00
Eelco Dolstra
dfc3a9afc3
Merge pull request #7043 from edolstra/installer-test
Add an installer test
2022-09-26 17:34:23 +02:00
Théophane Hufschmitt
6a64820cb4
Merge pull request #7082 from rapenne-s/ccache
add ccacheStdenv
2022-09-24 12:45:27 +02:00
Solène Rapenne
e04b38f789 add ccacheStdenv
when using ccache, rebuild time has been measured
89% faster while not slowing the speed of cold builds
2022-09-23 11:21:19 +02:00
Eelco Dolstra
fae3b4fe8a
Add an installer test
This runs the installer in a QEMU VM. Unlike the old installer test
that ran inside a declaratively built RedHat/Debian image, this uses
an image from Vagrant.
2022-09-14 15:41:11 +02:00
Théophane Hufschmitt
3fca5f6c69 Installer: Reset the timestamps in the tarball
Otherwise it isn't reproducible.

Fix https://github.com/NixOS/nix/issues/7001
2022-09-05 14:44:01 +02:00
Domen Kožar
99208bb8cc curl: patch for netrc regression in Nix 2022-07-14 17:45:02 -05:00
Eelco Dolstra
c364e0b098 Fix buildStatic.aarch64-linux
Commit 925b975224 accidentally enabled
use of the gold linker on aarch64-linux, which apparently doesn't work.

https://hydra.nixos.org/build/183500621
2022-07-11 20:57:29 +02:00
Eelco Dolstra
749d914d10
Add reminder to remove nix-static testing hack
https://github.com/NixOS/nix/pull/6708#issuecomment-1165912951
2022-06-24 23:14:56 +02:00
Eelco Dolstra
925b975224 Embed the sandbox shell into the statically linked 'nix' binary
With this, Nix will write a copy of the sandbox shell to /bin/sh in
the sandbox rather than bind-mounting it from the host filesystem.
This makes /bin/sh work out of the box with nix-static, i.e. you no
longer get

  /nix/store/qa36xhc5gpf42l3z1a8m1lysi40l9p7s-bootstrap-stage4-stdenv-linux/setup: ./configure: /bin/sh: bad interpreter: No such file or directory
2022-06-23 04:08:28 +02:00
Eelco Dolstra
8bbbb6e737 Enable/fix tests in nix-static
pkgsStatic is apparently considered a cross environment, so checkPhase
and installCheckPhase are disabled even when we ask for them.
2022-06-22 23:33:15 +02:00
Eelco Dolstra
12e86c0735
Merge pull request #6630 from edolstra/boost-dylib
Remove ${boost}/lib from the RPATH
2022-06-08 17:55:21 +02:00
Eelco Dolstra
4a3f217bde
Remove ${boost}/lib from the RPATH 2022-06-08 15:51:35 +02:00
Théophane Hufschmitt
694b12052a
Merge pull request #6624 from NixOS/new-flake-style
flake.nix: Convert to new naming convention
2022-06-08 13:34:09 +02:00
Eelco Dolstra
faf80fa920
Convert to new flake style
https://github.com/NixOS/nix/issues/5532
2022-06-07 14:36:23 +02:00
Eelco Dolstra
0f8754cd30
Fix 22.05 eval warnings 2022-06-07 14:27:10 +02:00
Eelco Dolstra
5a9d83aa59
Disable cross builds on platforms other than x86_64-linux
Needed because evaluation was broken on x86_64-darwin.
2022-06-07 14:27:06 +02:00
Cole Helbling
bd0192d0bb flake: update to 22.05
The static build works now :)
2022-05-31 11:51:17 -07:00
Eelco Dolstra
403201e011
Merge pull request #6537 from cole-h/update-flake
flake: use github: reference to nixpkgs
2022-05-31 08:30:42 +02:00
Eelco Dolstra
452dba510d
Mark nix-perl as a Perl module
The call to perl.withPackages in nix-serve expects this.
2022-05-30 14:10:26 +02:00
Eelco Dolstra
948515efb7
Set meta.platforms
'nix-serve' in nixpkgs expects the nix package to set this.
2022-05-30 13:35:28 +02:00
Eelco Dolstra
d67a2ae52d
Merge branch 'doc-redirects' of https://github.com/jtojnar/nix 2022-05-27 11:12:41 +02:00
Jan Tojnar
3272afa17b doc: Port anchors preprocessor to jq script
Python is only pulled into the build closure by Mercurial, which might end up being removed.
Let’s port the script to jq, which is more likely to stay.
2022-05-26 18:17:21 +02:00
Eelco Dolstra
5b27040203
Remove unused Perl dependency 2022-05-26 14:49:17 +02:00
Cole Helbling
685107c6c8 flake: use github: reference to nixpkgs
This allows flakes that don't override the Nixpkgs input and also have a
different flake registry.
2022-05-16 11:46:44 -07:00
Eelco Dolstra
cb5361628d Add libcxxStdenv devshell 2022-04-28 14:36:48 +02:00
Gabriel Fontes
770f3af31d
add sourcehut integration test 2022-02-23 11:58:09 -03:00
Eelco Dolstra
d2f9a081b8 flake.nix: Fix indent 2022-02-11 14:45:46 +01:00
regnat
7bd85a3bf6 Use the nix command (and flakes) in the CI
Apart from a slight simplification and a bit of dogfooding, this also
make the cache behavior more predictable.
For example `nix build .` and `nix build nix/$(git rev-parse HEAD)` will
yield the exact same path, while their “intuitive” non-flake equivalents
(`nix-build` and
`nix-build https://github.com/nixos/nix/archives/$(git rev-parse HEAD).tar.gz`)
don’t.

This was a pain for example in https://github.com/NixOS/nix/pull/5059

Also, the `bar-with-logs` log format is imho nicer (even in an
non-interactive context) because prefixing each log line with the name
of the derivation that produced it makes it much easier to follow what’s
going on.
2022-01-26 16:41:37 +01:00
Eelco Dolstra
9691f86ff7 Stop vendoring nlohmann_json 2022-01-26 11:50:53 +01:00
Eelco Dolstra
0a70b37b56 flake.nix: Fix indentation 2022-01-25 01:28:44 +01:00
Eelco Dolstra
9ce2511206 Add regression / performance tests against a fixed revision of Nixpkgs 2022-01-25 00:07:30 +01:00
Rok Garbas
a078a645da
Merge remote-tracking branch 'origin/master' into push-docker-image-to-docker-hub 2022-01-21 14:31:17 +01:00
regnat
dd3aa1e515 Remove the references to boost on darwin 2022-01-15 11:34:15 +01:00
regnat
de4489a672 Forbid runtime references to boost
We explicitly hack around to remove them, so might as well check that
the hack is useful.

(Introduced because I feared that the changes of
https://github.com/NixOS/nix/pull/5906#discussion_r784810238 would bring
back some runtime references)
2022-01-14 15:41:14 +01:00
Rok Garbas
2267c773f0
Push docker image (only x86_64-linux right now) to hub.docker.com 2022-01-11 18:51:58 +01:00
Eelco Dolstra
0a7c1da9f3 Make bash completion for 'nix' work in a devshell 2021-12-22 13:21:45 +01:00
Eelco Dolstra
f66923efde pkgconfig -> pkg-config 2021-12-15 19:13:06 +01:00
Eelco Dolstra
1b6adfe18f Revert "update flake.nix to 21.11"
This reverts commit ad9322a48f because
it breaks hydraJobs.buildStatic.* and the evaluation of some tests.
2021-12-15 13:49:05 +01:00
Jörg Thalheim
ad9322a48f update flake.nix to 21.11 2021-12-03 18:46:09 +01:00
regnat
e588f4c655 Add a matrix of stdenvs to the flake
For a (currently hardcoded and limited) list of stdenvs,
make `.#$nix-${stdenvName}` correspond to a Nix built with the
corresponding stdenv.

For example, `.#nix-${clang11Stdenv}` is Nix built with clang11.

Likewise, `devShells.x86_64-linux.clang11StdenvPackages` is a development
shell for Nix with clang11, that can be used with

```shell
nix develop .#clang11StdenvPackages
```

Fix #4129

/cc @pamplemousse
2021-11-26 10:04:13 +01:00
Eelco Dolstra
329b18711e flake.nix: Only have checks.*.dockerImage on supported systems 2021-11-25 14:45:47 +01:00
Rok Garbas
e7906ffd0e
Add dockerImage to the checks 2021-11-24 09:19:29 +01:00
Rok Garbas
52c84c15e5
Don't copy, to reduce store size 2021-11-24 09:18:33 +01:00
Rok Garbas
cd72a8c346
Make docker image downloadable in Hydra UI 2021-11-23 11:35:05 +01:00
Jan Tojnar
f68699963c
flake: Do not use aliases
gmock is not available with `nixpkgs.config.allowAliases = false`.
2021-11-22 17:57:30 +01:00
Rok Garbas
93f7fb6e74
Docker image with Nix inside 2021-11-11 16:07:01 +01:00
Eelco Dolstra
a7d4f3411e Merge remote-tracking branch 'origin/master' into non-blocking-gc 2021-10-28 14:56:55 +02:00
Benoit de Chezelles
ec9c1286ad Fix devShell build on non-NixOS with a different boost version 2021-10-23 15:32:48 +02:00
Eelco Dolstra
be35569a6e Run installTests on Hydra 2021-10-15 12:36:29 +02:00
Arthur Gautier
e33f74495b Adds a test for nss preload mechanism
This tests for the fix implemented in #5224

Signed-off-by: Arthur Gautier <baloo@superbaloo.net>
2021-10-07 17:25:41 +00:00
Eelco Dolstra
faeab0d5d5 Make Mercurial optional for the flakes tests 2021-10-06 18:29:20 +02:00
Eelco Dolstra
4d28cf836a Disable testing against nixUnstable on macOS
This is failing randomly at the moment which isn't very helpful.
2021-10-06 13:17:39 +02:00
Eelco Dolstra
223ab254c2 Compatibility 2021-10-05 14:50:55 +02:00
Eelco Dolstra
08cc572f89 Revert "Shorten the test drv name"
This reverts commit 5ec873b127.
2021-10-05 10:41:17 +02:00
Eelco Dolstra
32669a6bc9 Use separate lowdown
Overriding the lowdown in nixpkgs can break nixUnstable.
2021-09-27 10:31:13 +02:00
Eelco Dolstra
aedbc7b683 Use latest lowdown
This improves list rendering
(https://github.com/kristapsdz/lowdown/issues/73).
2021-09-24 15:22:51 +02:00
regnat
81ed6ee201 flake: Use the real nixUnstable from nixpkgs
Don’t let it pick our overriden lowdown as that would cause it not to be
cached in cache.nixos.org
2021-09-20 14:37:09 +02:00
Eelco Dolstra
e664270c2b
Merge pull request #5246 from edolstra/faster-check
Speed up 'nix flake check'
2021-09-14 12:22:28 +02:00
Eelco Dolstra
2cf8110f5a flake.nix: Don't do cross builds in 'nix flake check'
'nix flake check' should be relatively fast, so it's not the best
place to do cross-builds. We're already doing that in Hydra.
2021-09-14 11:34:32 +02:00
Eelco Dolstra
6ff19ce137 nix-tests: Run 'make installcheck' in parallel 2021-09-14 11:34:17 +02:00
Eelco Dolstra
14205debb2 lowdown: Update to 0.8.6 2021-09-13 14:45:21 +02:00
Eelco Dolstra
307977963c nlohmann_json: Update to 3.9.1, fix use of internal copy 2021-07-15 12:25:53 +02:00
Matthew Bauer
2200f315da Disable -pie on static nix
This should resolve the failing build.

See https://github.com/NixOS/nixpkgs/pull/128674 for a better fix.
2021-06-29 21:48:07 -05:00
Matthew Bauer
7351656b82 Only cross compile from x86_64-linux
This is broken on aarch64-linux / x86_64-darwin, so might as well just disable it for now.
2021-06-29 21:47:35 -05:00
Eelco Dolstra
f14c3b6f68
Merge pull request #4944 from hercules-ci/fix-gc-crash
Fix gc crash
2021-06-29 13:52:14 +02:00
Matthew Bauer
6c13a3f735 Support binaryTarballCross in gha 2021-06-28 15:08:17 -05:00
Matthew Bauer
580583e0b3 Build cross-compilation in gha 2021-06-26 00:14:54 -05:00
Matthew Bauer
c906d6530d Support cross-compiling binaryTarball 2021-06-26 00:12:03 -05:00
Matthew Bauer
c3a929349f Merge remote-tracking branch 'origin/master' into cross-jobs 2021-06-25 15:51:02 -05:00
Robert Hensing
57409244ec boehmgc: Crude support for coroutines
Fixes the problem where a stack pointer outside the original
thread causes the collector to crash.

It could be made more accurate by recording the stack pointer
every time we switch to a coroutine. We can use this information
to update our own coroutine stacks like normal data. When the
stack pointer is on a thread, we can add a field to GC_thread
"fallback_sp" to be used when the thread sp is outside the original
thread range.
2021-06-24 18:17:03 +02:00
Domen Kožar
9676c9f6a3
perlBindings: fix build on aarch64-darwin 2021-06-21 19:40:51 +02:00
Finn Behrens
9f1a7f9d37 Include aarch64-darwin in installer
Co-authored-by: Matthew Bauer <mjbauer95@gmail.com>
2021-06-01 09:48:35 +02:00
Finn Behrens
1fefe808f6 enable aarch64-darwin build
disable lowdown sandbox on aarch64-darwin
2021-06-01 09:45:14 +02:00
Domen Kožar
1f390922d0
Build for aarch64-darwin 2021-05-29 19:40:56 +02:00
Eelco Dolstra
788008385e Use lowdown 0.8.4 2021-04-23 14:20:32 +02:00
Eelco Dolstra
76980a1f3d Merge branch 'build-with-strictDeps' of https://github.com/hercules-ci/nix 2021-04-15 14:15:21 +02:00
Eelco Dolstra
15f4d4fd43 Drop libbz2 / zlib / lzma dependency + style fixes 2021-04-15 13:55:22 +02:00
Robert Hensing
ff1a2143aa flake.nix: Make the sandbox tests work again 2021-03-31 08:31:30 +02:00
Robert Hensing
f66fb5fb5b flake.nix: Build nix with strictDeps = true 2021-03-31 08:30:12 +02:00
Eelco Dolstra
3ab5e8a391
Merge pull request #4239 from tweag/test-against-old-daemon
Add a CI check to ensure compatibility with an old daemon
2021-03-29 16:15:36 +02:00
Eelco Dolstra
ce791535f6 nixpkgs/master compatibility 2021-03-29 14:54:05 +02:00
regnat
5ec873b127 Shorten the test drv name
To prevent the OSX build to fail because of a too long socket path
2021-03-16 16:44:42 +01:00
regnat
a0866c8ea4 Make the tests (optionnally) run in another derivation
That way we can run them without rebuilding Nix
2021-03-16 14:21:39 +01:00
regnat
5716345adf Add a test ensuring compatibility with an old daemon
This requires adding `nix` to its own closure which is a bit unfortunate,
but as it is optional (the test will be disabled if `OUTER_NIX` is unset) it
shouldn't be too much of an issue.

(Ideally this should go in another derivation so that we can build Nix and run
the test independently, but as the tests are running in the same derivation
as the build it's a bit complicated to do so).
2021-03-16 14:20:41 +01:00
Matthew Bauer
d5fd0f4745
Merge branch 'master' into cross-jobs 2021-03-09 11:40:16 -06:00
Eelco Dolstra
c189031e8b
Merge pull request #4549 from NixOS/installer-artifact
Test macos/linux installer script for each push
2021-02-25 16:08:43 +01:00
Daniël de Kok
2de232d2b3 Add x86_64 compute levels as additional system types
When performing distributed builds of machine learning packages, it
would be nice if builders without the required SIMD instructions can
be excluded as build nodes.

Since x86_64 has accumulated a large number of different instruction
set extensions, listing all possible extensions would be unwieldy.
AMD, Intel, Red Hat, and SUSE have recently defined four different
microarchitecture levels that are now part of the x86-64 psABI
supplement and will be used in glibc 2.33:

https://gitlab.com/x86-psABIs/x86-64-ABI
https://lwn.net/Articles/844831/

This change uses libcpuid to detect CPU features and then uses them to
add the supported x86_64 levels to the additional system types. For
example on a Ryzen 3700X:

$ ~/aps/bin/nix -vv --version | grep "Additional system"
Additional system types: i686-linux, x86_64-v1-linux, x86_64-v2-linux, x86_64-v3-linux
2021-02-22 09:11:15 +01:00
Domen Kožar
ae4260f0a7
Generate installer script for each PR/push
This works by using Cachix feature of serving a file from
a store path.
2021-02-21 15:51:49 +00:00
sternenseemann
d0e34c85f8 libcmd/markdown: handle allocation errors in lowdown_term_rndr
We upgrade to lowdown 0.8.0 [1] which contains a fix/improvement to a
behavior mentioned in this issue thread [2] where a big part of
lowdown's API would just call exit(1) on allocation errors since that
is a satisfying behavior for the lowdown binary.

Now lowdown_term_rndr returns 0 if an allocation error occurred which we
check for in libcmd/markdown.cc.

Also the extern "C" { } wrapper around lowdown.h has been removed as it
is not necessary.

[1]: 6ca7c855a0/versions.xml (L987-L1006)
[2]: https://github.com/kristapsdz/lowdown/issues/45#issuecomment-756681153
2021-02-06 13:14:57 +01:00
Matthew Bauer
4fefe26717 Re-enable armv6l support
This fixes the libatomic detection.
2021-02-05 18:22:34 -06:00
Matthew Bauer
c6d878609d Merge remote-tracking branch 'origin/master' into cross-jobs 2021-02-05 18:07:48 -06:00
Eelco Dolstra
271eedb837
Merge pull request #4495 from Infinisil/perl-bindings-passthru
Use passthru for perl-bindings, allows Nix patching for Hydra
2021-02-05 12:22:52 +01:00
Silvan Mosberger
d5acc4865c
Use passthru for perl-bindings, allows Nix patching for Hydra
This allows patching Nix for Hydra with additional overlays, because
`.overrideAttrs` and co. will persist the passthru's
2021-01-29 18:31:40 +01:00
Eelco Dolstra
f15f0b8e83 Update to lowdown 0.7.9 2021-01-26 10:47:40 +01:00
Matthew Bauer
be09af8002 Include static "nix" binary in Hydra build products
This allows users to get Nix from Hydra via a stable url like
https://hydra.nixos.org/build/132078238/download/1/nix
2020-12-03 18:05:18 -06:00
zimbatm
233b61d3d6
installer: simplify the per-build installation
The goal is to allow the installation and testing of arbitrary Nix
versions. Extend the base installer to accept a `--tarball-url-prefix
<url>` to change where the Nix tarball is getting downloaded from.

Once this is merged it should allow to:
1. Pick an evaluation at https://hydra.nixos.org/jobset/nix/master that
   looks healthy
2. Select the installedScript build and find the store path.

Now equipped with all of this, use an instance of nar-serve to fetch the
install script and release tarballs:

    curl -sfL https://nar-serve.numtide.com/nix/store/rkv4yh7pym941bhj0849zqdkg2546bdv-installer-script/install \
      | sh --tarball-url-prefix https://nar-serve.numtide.com/nix/store

Or with cachix, strip the /nix/store and derivation name and then:

    curl -sfL https://mycache.cachix.org/serve/rkv4yh7pym941bhj0849zqdkg2546bdv/install \
      | sh --tarball-url-prefix https://mycache.cachix.org/serve

Fixes #4047
2020-11-21 19:56:46 +01:00
Eelco Dolstra
3daa256728 Remove tests.binaryTarball
This test no longer works on Hydra because import-from-derivation is
no longer allowed.
2020-11-17 15:26:39 +01:00
Maximilian Bosch
3a63fc6cd5
Allow substituting paths when building remotely using ssh-ng://
Until now, it was not possible to substitute missing paths from e.g.
`https://cache.nixos.org` on a remote server when building on it using
the new `ssh-ng` protocol.

This is because every store implementation except legacy `ssh://`
ignores the substitution flag passed to `Store::queryValidPaths` while
the `legacy-ssh-store` substitutes the remote store using
`cmdQueryValidPaths` when the remote store is opened with `nix-store
--serve`.

This patch slightly modifies the daemon protocol to allow passing an
integer value suggesting whether to substitute missing paths during
`wopQueryValidPaths`. To implement this on the daemon-side, the
substitution logic from `nix-store --serve` has been moved into a
protected method named `Store::substitutePaths` which gets currently
called from `LocalStore::queryValidPaths` and `Store::queryValidPaths`
if `maybeSubstitute` is `true`.

Fixes #2770
2020-11-05 20:12:37 +01:00
John Ericson
82e4d2a82e No x86_32 static nix jobs for now
Fixes #4175
2020-10-28 05:13:18 +00:00
Domen Kožar
e0ca98c207
Merge pull request #3996 from abathur/macos_big_sur_fixes
Macos big sur installer fixes
2020-10-20 12:18:23 +02:00
Travis A. Everett
3a8699ac4f restore create-darwin-volume to release tarball
The move from release.nix to flake.nix appears to have lost some
changes from #3628 / 1c56f18a8122b605c28000e295d5e223f272cccd, leaving
create-darwin-volume.sh out of the release tarball.

Under the assumption that this was just an accident/byproduct of when
flake.nix split off and not intentional, I am restoring those edits.
2020-10-19 12:25:52 -05:00
Eelco Dolstra
c27fcd94ce Remove buildStatic from checks
checks should be relatively fast, but buildStatic depends on a lot of
stuff that isn't in the binary cache (e.g. musl builds of Git and
Mercurial that we probably don't need since we don't link against
them...).
2020-10-18 21:44:07 +02:00
Eelco Dolstra
62cf1d815a Switch to Nixpkgs 20.09 2020-10-18 21:31:27 +02:00
John Ericson
f6ed1a96b3 build-static -> buildStatic in Nix's flake 2020-10-15 18:54:36 +00:00
John Ericson
39de73550d Merge remote-tracking branch 'upstream/master' into fix-and-ci-static-builds 2020-10-09 18:26:47 +00:00
regnat
21639b2d17 Use gold as the linker on Linux
Saves ~7s in the linking phase
2020-09-23 16:10:31 +02:00
Eelco Dolstra
d110fdd03f Disable precompiled headers in 'nix develop'
They're still enabled in regular builds though.
2020-09-21 13:30:05 +02:00
regnat
9aa0dafe20 Update lowdown version
Fix #4042

According to 8aef9e9290, we shouldn't need to use a fork anymore so we can switch back to upstream
2020-09-21 13:11:31 +02:00
John Ericson
ec14465a00 Separate lowdown lib and bin to be more precise 2020-09-04 02:43:56 +00:00
John Ericson
25f7ff16fa Merge remote-tracking branch 'upstream/master' into fix-and-ci-static-builds 2020-09-04 02:40:36 +00:00
John Ericson
e12bcabdcb Remove duplicate buildInputs 2020-09-04 02:30:12 +00:00
Eelco Dolstra
50f46836f3
Merge remote-tracking branch 'origin/master' into markdown 2020-09-01 09:48:08 +02:00
Eelco Dolstra
ebb8e076eb Restore some of the shellHook 2020-08-31 16:39:54 +02:00
Eelco Dolstra
84f5cabbea Merge remote-tracking branch 'origin/master' into markdown 2020-08-31 14:24:26 +02:00
Eelco Dolstra
3156560d41 nix develop: Set output paths to writable locations
Currently, they're set to $(pwd)/outputs/$outputName. This allows
commands like 'make install' to work.
2020-08-28 18:16:03 +02:00
Eelco Dolstra
f5219f8d84 Fix perlBindings job 2020-08-25 10:33:41 +02:00
Eelco Dolstra
b42789f013
Fix clang build 2020-08-24 21:13:39 +02:00
Eelco Dolstra
b4ef3d7078
Revert "Add a separate manual job"
This reverts commit 5e3ad1dde0. Manual
generation now depends on the 'nix' command.
2020-08-19 21:00:57 +02:00
Eelco Dolstra
1d0a7b54fa
Enable syntax highlighting 2020-07-31 15:43:25 +02:00
Matthew Bauer
3537670fef Only enable static on linux 2020-07-30 15:53:49 -05:00
Matthew Bauer
13ef7a07b9 Fix build 2020-07-30 15:49:45 -05:00
Matthew Bauer
d7ffe327ae Merge remote-tracking branch 'origin/master' into fix-and-ci-static-builds 2020-07-30 14:59:57 -05:00
Eelco Dolstra
5e3ad1dde0
Add a separate manual job 2020-07-23 18:27:20 +02:00
Eelco Dolstra
e0ea3c82ca
Use mdbook 2020-07-23 18:26:48 +02:00
Eelco Dolstra
650ae14ced
Markdown test 2020-07-23 18:26:48 +02:00
Eelco Dolstra
1524752c17 Merge remote-tracking branch 'origin/master' into flakes 2020-06-17 10:26:52 +02:00
Eelco Dolstra
e938add10d flake.nix: Remove edition 2020-06-09 11:23:23 +02:00
Eelco Dolstra
17ca997fc6 Merge remote-tracking branch 'origin/master' into flakes 2020-05-28 12:55:24 +02:00
Eelco Dolstra
1ad71bc62c Remove support for old lockfiles and the epoch/uri attributes 2020-05-06 17:48:18 +02:00
Eelco Dolstra
e5ea01c1a8
Remove flake 'edition' field
Future editions of flakes or the Nix language can be supported by
renaming flake.nix (e.g. flake-v2.nix). This avoids a bootstrap
problem where we don't know which grammar to use to parse
flake*.nix. It also allows a project to support multiple flake
editions, in theory.
2020-04-10 10:24:09 +02:00
Eelco Dolstra
e35d83d1fc Fix job name 2020-04-03 20:11:14 +02:00
Eelco Dolstra
bf70a047a0 Publish a tarball containing the crates we depend on
This is needed since we no longer produce a source tarball.
2020-04-03 20:06:26 +02:00
Eelco Dolstra
bb39f2bb8a Temporary backward compatibility hack 2020-04-02 19:12:14 +02:00
Eelco Dolstra
ab47868639 Change lastModified to the number of seconds in the epoch
'lastModifiedDate' is now a string representing the equivalent
date/time.
2020-04-02 18:39:41 +02:00
Eelco Dolstra
36c34c3b1f Set version properly 2020-04-01 00:20:12 +02:00
Eelco Dolstra
5f75d56c9b flake.nix: Support Nixpkgs 19.09 2020-03-28 16:51:10 +01:00
Eelco Dolstra
bc5d4843a9 Fix coverage job 2020-03-20 13:39:39 +01:00
Eelco Dolstra
1e6e673eb7 flake.nix: Switch to 20.03 2020-03-20 13:09:20 +01:00
Eelco Dolstra
7304f9f145 Merge remote-tracking branch 'origin/master' into flakes 2020-03-13 18:36:47 +01:00
Eelco Dolstra
db34445c5e Build vendoredCrates in the overlay
This makes it build on non-x86_64-linux systems (needed in GitHub
actions).
2020-03-13 18:31:16 +01:00
Eelco Dolstra
3e1abf4f05 Merge remote-tracking branch 'origin/master' into flakes 2020-03-13 18:28:01 +01:00
Eelco Dolstra
dd032f624c ggRevert "Use Nixpkgs 20.03"
This reverts commit 5921ca89f9.
2020-02-18 22:11:52 +01:00
Eelco Dolstra
5921ca89f9
Use Nixpkgs 20.03 2020-02-18 16:21:13 +01:00
Eelco Dolstra
6529490cc1 nix eval-hydra-jobs: Support job names as aggregate constituents
Fixes https://github.com/NixOS/hydra/issues/715.
2020-02-17 15:53:59 +01:00
Eelco Dolstra
144bb3ef7d Build with large config Boehm GC 2020-02-15 21:48:28 +01:00
Eelco Dolstra
7072b8649a Enable debug symbols 2020-02-15 21:30:26 +01:00
Eelco Dolstra
fa467de090 Update flake.lock 2020-02-03 18:59:29 +01:00
Eelco Dolstra
9f4d8c6170 Pluggable fetchers
Flakes are now fetched using an extensible mechanism. Also lots of
other flake cleanups.
2020-01-21 22:56:04 +01:00
Eelco Dolstra
6fadb3fc03 Merge remote-tracking branch 'origin/master' into flakes 2020-01-21 21:18:52 +01:00
Eelco Dolstra
c7866733d7 Merge remote-tracking branch 'origin/master' into flakes 2019-12-20 12:45:58 +01:00
Eelco Dolstra
ad6b738ed8 Merge remote-tracking branch 'origin/master' into flakes 2019-12-16 20:17:21 +01:00
Eelco Dolstra
90d2cf6ff9 Fix evaluation 2019-12-04 01:04:40 +01:00
Eelco Dolstra
c3c23a52ee Merge remote-tracking branch 'origin/master' into flakes 2019-12-04 00:31:09 +01:00
Eelco Dolstra
0bc0d35b6b
Merge remote-tracking branch 'origin/master' into flakes 2019-11-08 14:29:10 +01:00
Eelco Dolstra
f730841db4
Merge remote-tracking branch 'origin/master' into flakes 2019-11-07 11:44:02 +01:00
Eelco Dolstra
f01304b573
Fix build 2019-11-06 14:47:58 +01:00
Eelco Dolstra
88c452d160
Merge remote-tracking branch 'origin/master' into flakes 2019-11-06 10:56:33 +01:00
Eelco Dolstra
9cac895406 Use upstream nlohmann_json 2019-10-22 20:12:23 +02:00
Eelco Dolstra
7d38060a0d Support non-x86_64-linux system types in flakes
A command like

  $ nix run nixpkgs#hello

will now build the attribute 'packages.${system}.hello' rather than
'packages.hello'. Note that this does mean that the flake needs to
export an attribute for every system type it supports, and you can't
build on unsupported systems. So 'packages' typically looks like this:

  packages = nixpkgs.lib.genAttrs ["x86_64-linux" "i686-linux"] (system: {
    hello = ...;
  });

The 'checks', 'defaultPackage', 'devShell', 'apps' and 'defaultApp'
outputs similarly are now attrsets that map system types to
derivations/apps. 'nix flake check' checks that the derivations for
all platforms evaluate correctly, but only builds the derivations in
'checks.${system}'.

Fixes #2861. (That issue also talks about access to ~/.config/nixpkgs
and --arg, but I think it's reasonable to say that flakes shouldn't
support those.)

The alternative to attribute selection is to pass the system type as
an argument to the flake's 'outputs' function, e.g. 'outputs = { self,
nixpkgs, system }: ...'. However, that approach would be at odds with
hermetic evaluation and make it impossible to enumerate the packages
provided by a flake.
2019-10-15 18:16:29 +02:00
Eelco Dolstra
d343c03edb
Temporary compatibility hack 2019-10-08 20:05:16 +02:00
Eelco Dolstra
21304c11f9
uri -> url for consistency 2019-10-08 17:00:55 +02:00
Eelco Dolstra
ce2c755d2a
Add a "dev" output to the 'nix' package
This is to ensure that references like 'nix.dev' in dwarffs work
regardless of whether we're using the 'nix' package from this overlay
or from Nixpkgs.
2019-10-07 14:02:52 +02:00
Eelco Dolstra
21e2088c1b
nix-perl -> nix.perl-bindings 2019-10-04 17:25:59 +02:00
Eelco Dolstra
204291f059
Merge release.nix, shell.nix and release-common.nix into flake.nix
Also provide a Nixpkgs overlay, memoize Nixpkgs evaluation and fit the
githubFlakes test.
2019-10-04 10:45:33 +02:00
Eelco Dolstra
1f631ac85b
flake.nix: Remove VM tests from 'checks' 2019-09-10 17:39:34 +02:00
Eelco Dolstra
80c36d4562 Remove 'name' attribute from flakes
This is no longer needed since flakes are given an identity in the
'inputs' attribute.
2019-08-30 16:38:27 +02:00
Eelco Dolstra
d749f5132b Update flake.{nix,lock} 2019-08-30 13:06:48 +02:00
Eelco Dolstra
13604318ad
epoch -> edition 2019-07-26 20:06:03 +02:00
Nick Van den Broeck
d9a6a75ed2 Made epochs more fine-grained
Fixes #2894
2019-06-03 14:47:47 +02:00
Eelco Dolstra
094539ef4a
Rename requires -> inputs, provides -> outputs
Issue #2828.
2019-05-31 09:59:48 +02:00
Eelco Dolstra
b70fc8f30c
flake.nix: Add more checks 2019-05-29 22:22:28 +02:00
Eelco Dolstra
e0aaf05f4f
Add 'nix flake check' command
This evaluates all the 'provides' of a flake and builds the 'check'
attributes.
2019-05-29 17:25:41 +02:00
Eelco Dolstra
2919c496ea nix dev-shell: Use 'provides.devShell' by default
Thus

  $ nix dev-shell

will now build the 'provides.devShell' attribute from the flake in the
current directory. If it doesn't exist, it falls back to
'provides.defaultPackage'.
2019-05-02 21:10:13 +02:00
Eelco Dolstra
939bee06cd Pass a flake to itself as "self" 2019-04-16 16:29:44 +02:00
Eelco Dolstra
c996e04aca Allow relative paths in flakerefs
Also allow "." as an installable to refer to the flake in the current
directory. E.g.

  $ nix build .

will build 'provides.defaultPackage' in the flake in the current
directory.
2019-04-08 23:52:09 +02:00
Eelco Dolstra
a9ceeeb4b0 Add a flake.nix 2019-04-08 23:09:18 +02:00