Commit Graph

5448 Commits

Author SHA1 Message Date
Jan Tojnar
d1b77f990f Merge branch 'staging-next' into staging
Conflicts:
	pkgs/applications/networking/browsers/firefox/common.nix between f6c5761935 and a373324120.
2022-05-15 07:08:29 +02:00
Ivv
5f721cfb1c
Merge pull request #169121 from ashkitten/xivlauncher
xivlauncher: init at 1.0.0.4
2022-05-14 22:53:35 +02:00
7c6f434c
cd6eea51c4
Merge pull request #171083 from ehmry/wrapCCWith-nixSuport
wrapCCWith: structured argument for wrapper flags
2022-05-14 15:05:25 +00:00
adisbladis
fb222e0086
Merge pull request #172820 from alyssais/compressed-firmware
Compressed firmware
2022-05-14 02:38:48 +08:00
Alyssa Ross
8aa8e0ce7f
nixos/udev: compress all firmware if supported
This should be a significant disk space saving for most NixOS
installations.  This method is a bit more complicated than doing it in
the postInstall for the firmware derivations, but this way it's
automatic, so each firmware package doesn't have to separately
implement its compression.

Currently, only xz compression is supported, but it's likely that
future versions of Linux will additionally support zstd, so I've
written the code in such a way that it would be very easy to implement
zstd compression for those kernels when they arrive, falling back to
xz for older (current) kernels.

I chose the highest possible level of compression (xz -9) because even
at this level, decompression time is negligible.  Here's how long it took
to decompress every firmware file my laptop uses:

	i915/kbl_dmc_ver1_04.bin                  	2ms
	regulatory.db                             	4ms
	regulatory.db.p7s                         	3ms
	iwlwifi-7265D-29.ucode                    	62ms
	9d71-GOOGLE-EVEMAX-0-tplg.bin             	22ms
	intel/dsp_fw_kbl.bin                      	65ms
	dsp_lib_dsm_core_spt_release.bin          	6ms
	intel/ibt-hw-37.8.10-fw-22.50.19.14.f.bseq	7ms

And since booting NixOS is a parallel process, it's unlikely (but
difficult to measure) that the time to user interaction was held up at
all by most of these.

Fixes (partially?) #148197
2022-05-13 14:36:34 +00:00
github-actions[bot]
814126147f
Merge staging-next into staging 2022-05-13 12:02:03 +00:00
Vincent Laporte
1f11888116 Revert "coqPackages: etc"
This reverts commit 7e589a45ef.
2022-05-13 06:47:14 +02:00
github-actions[bot]
d79af4efe4
Merge staging-next into staging 2022-05-13 00:03:35 +00:00
sternenseemann
357da6c296 buildRustPackage: make cargoDeps logic easier to follow
The old logic flow had the structure

  if ( … ) {
    if ( … ) {
      …
    } else {
      …
    }
  } else {
    …
  }

which is quite hard to follow in Nix. Instead we ensure that no if
expression is inside a then branch.

This change is zero rebuild, as no logic was changed.
2022-05-13 08:18:39 +10:00
Thiago Kenji Okada
5c5187646d
Merge pull request #172366 from ncfavier/wrappers-cleanup
make{,Binary}Wrapper: some cleanups
2022-05-12 22:17:34 +01:00
Naïm Favier
3e385d9a82
makeBinaryWrapper: add comment 2022-05-12 15:23:38 +02:00
Cyril Cohen
7e589a45ef coqPackages: etc
- use propagatedBuildInputs to make sure ocaml plugin stuff is in path
- updated coqPackage.heq (broken url)
- fixed use of `DESTDIR` and `COQMF_COQLIB` in mkCoqDerivation
- adding `COQCORELIB` environement variable to put ocaml plugin files in the right place
- make metaFetch available from `coqPackages`
2022-05-12 06:11:43 +02:00
Naïm Favier
88369997e1
makeBinaryWrapper: add extractCmd
A small shell script that can be used to extract a binary wrapper's
makeCWrapper call from its embedded docstring, without depending on
makeBinaryWrapper.
2022-05-12 01:44:02 +02:00
Naïm Favier
2ae69114a1
makeWrapper: implement --inherit-argv0
For symmetry/interoperability with makeBinaryWrapper. Implemented as
--argv0 '$0'
2022-05-10 22:07:57 +02:00
Naïm Favier
8b79ef2cb6
makeBinaryWrapper: remove cc from deps
Fixes https://github.com/NixOS/nixpkgs/issues/172249
2022-05-10 22:07:57 +02:00
Naïm Favier
81b9c712ce
wrapGAppsHook: rename argument to makeWrapper
...and pass it makeBinaryWrapper in all-packages.nix
2022-05-10 22:07:56 +02:00
Naïm Favier
62245943aa
makeWrapper,makeBinaryWrapper: introduce explicitly named functions
Because both versions might end up in a derivation's build inputs, it
might be useful to be able to explicitly select which function to use.
2022-05-10 22:07:56 +02:00
Naïm Favier
0d6bcb513b
makeBinaryWrapper: move into its own folder
The derivation is complex enough to warrant moving out of
all-packages.nix
2022-05-10 22:07:56 +02:00
ash lea
e530db9baf buildDotnetModule: fix args 2022-05-10 11:40:59 -04:00
Alyssa Ross
6592d3fbc7
skawarePackages.buildPackage: fix typo in comment 2022-05-09 15:52:56 +00:00
Robert Hensing
c3bbe1d9c7 testers.nixosTest: Remove redundant system.stateVersion = lib.trivial.release;
Already present in nixos/modules/testing/test-instrumentation.nix,
which is imported by the test framework.
2022-05-09 14:33:49 +02:00
Robert Hensing
ebf0465d09 Merge remote-tracking branch 'upstream/master' into testers 2022-05-09 14:27:13 +02:00
Robert Hensing
93abb7bef7 tests.testers.nixosTest-example: move from tests.nixos-functions.nixosTest-test
And improve the test a bit, to assert correct wiring of `pkgs`.
2022-05-09 14:21:56 +02:00
Robert Hensing
ae172a2bb4 treewide: nixosTest -> testers.nixosTest 2022-05-09 14:16:06 +02:00
Naïm Favier
d4aa650608
makeBinaryWrapper: really unset NIX_CFLAGS
f8cc8ff575
fails to unset the variables in the environment due to a Bash quirk,
so set them to the empty string instead.
2022-05-06 17:03:52 +02:00
Naïm Favier
42a4c05dd0
makeBinaryWrapper: add -Wno-overlength-strings
The generated C code contains large string literals that are longer than
the maximum length specified by the standard.

However, GCC has no trouble dealing with those strings, so we can just
add -Wno-overlength-strings.

https://gcc.gnu.org/onlinedocs/gcc/Warning-Options.html#index-Woverlength-strings
2022-05-06 16:12:57 +02:00
github-actions[bot]
b962dee3e7
Merge master into staging-next 2022-05-06 00:02:16 +00:00
ilkecan
d6bd313f07 buildRustCrate: set meta.mainProgram to crateName 2022-05-05 14:25:27 +00:00
Robert Hensing
7edb414660 testers.nixosTest: Move from top-level and improve docs 2022-05-05 12:48:47 +02:00
Robert Hensing
c071530ca5 testers.invalidateFetcherByDrvHash: Move from top-level 2022-05-05 12:08:50 +02:00
github-actions[bot]
00dc0eecc7
Merge staging-next into staging 2022-05-03 12:01:45 +00:00
Janne Heß
2edce50847
Merge pull request #171134 from helsinki-systems/feat/make-initrd-ng-strip
makeInitrdNG: Strip more and remove output
2022-05-03 09:41:22 +02:00
Vladimír Čunát
9478ec747c
Merge branch 'staging-next-2022-04-23'
Close #169965: the PR and real 'staging-next' branch contained
extra systemd rebuild that I wanted to avoid in this iteration.
(to save Hydra's work)
2022-05-02 09:12:51 +02:00
github-actions[bot]
677697c12f
Merge staging-next into staging 2022-05-01 18:01:35 +00:00
github-actions[bot]
da9b549e31
Merge master into staging-next 2022-05-01 18:01:03 +00:00
David Scherer
13a9006ec3 Fix determinism by defaulting codegenUnits to 1, not NIX_BUILD_CORES 2022-05-01 11:48:32 -04:00
Mateusz Kowalczyk
f6897d23f4 buildRustCrate: make codegen-units configurable
This parameter is being set to `$NIX_BUILD_CORES` by default. This is a
standard practice but there's a suspicion that this can produce broken
builds. For some details see
https://github.com/cargo2nix/cargo2nix/issues/184 . As a
work-around/test, it'd be good if codegen-units can be set to something
constant, such as `1`. This PR allows it.

Note that the default of `$NIX_BUILD_CORES` is preserved so this MR
causes no change in default behaviour and no rebuilds.
2022-05-01 11:48:32 -04:00
Janne Heß
e5995b2235
makeInitrdNG: Strip more and remove output
This strips all elf files as far as possible and removes a lot of
unnecessary output. Also wrap in the binaries instead of relying on
$PATH.
2022-05-01 17:06:14 +02:00
Vladimír Čunát
cec6e7362c
Merge branch 'master' into staging-next-2022-04-23 2022-05-01 14:26:52 +02:00
github-actions[bot]
676b5fba35
Merge staging-next into staging 2022-05-01 06:01:47 +00:00
github-actions[bot]
dc0ace8d6e
Merge master into staging-next 2022-05-01 06:01:14 +00:00
Emery Hemingway
89a0dd2414 wrapCCWith: structured argument for wrapper flags
Take a "nixSupport" argument that is an attrset of lists to append
to "$out/nix-support/${name}" where name is the name of the
attribute. This attrset is available from the passthru of the
wrapped compiler.

This is an alternative to imperatively issuing flags with
extraBuildCommands and makes it possible to append or filter
flags with an override.
2022-04-30 21:21:41 -05:00
Ivar Scholten
e3c19ba57e nuget-to-nix: include required dependencies 2022-04-30 18:24:48 -07:00
=
f0af1ef49c buildDotnetModule: properly inherit arguments from drv
Previously buildDotnetModule did not properly inherit some arguments from
derivations, take for example this expression:

dotnetFlags = [
    "--runtime linux-x64"
];

It would error out as follows: "MSBUILD : error MSB1001: Unknown switch.".
Setting the same flag from bash would work fine. This fixes that, all
arguments should now be properly interpreted :)
2022-04-30 18:24:48 -07:00
=
f69de108fb buildDotnetModule: nuget source cleanup
There used to be a few issues with the way we generate the nuget source:

* The derivation generated for the deps would have "nuget-deps" in them twice:
  /nix/store/...-foo-1.0-nuget-deps-nuget-deps

* We always tried to generate the dependencies for "projectReferences"
  even when it wasn't set, causing a warning.

This fixes those issues :)
2022-04-30 18:24:48 -07:00
=
38419c65ce mkNugetSource: fix bug in metadata generation
This improves the metadata generation, previously it would take any
"license" entry from the nuspec, and tried to match it to an spdx ID from
"lib.licenses".

Sometimes however licenses are provided in plain-text, which we
obviously cannot cleanly resolve. This resulted in in useless information
("LICENSE.txt") being written to "meta.license".
2022-04-30 18:24:48 -07:00
Vladimír Čunát
c480cc2895
Merge branch 'master' into staging-next-2022-04-23 2022-04-30 23:02:28 +02:00
github-actions[bot]
03ecebd53a
Merge staging-next into staging 2022-04-29 00:03:11 +00:00
github-actions[bot]
619828db66
Merge master into staging-next 2022-04-29 00:02:35 +00:00
Yusuf Bera Ertan
e2a3a3c690
default-crate-overrides: only add Security to propagatedBuildInputs on darwin for security-framework-sys 2022-04-28 21:24:46 +03:00