Commit Graph

8782 Commits

Author SHA1 Message Date
Domen Kožar
9888edd1e7
buildGraalvm: fix build on x86_64-darwin (#360254) 2024-12-02 22:47:28 +00:00
György Kurucz
66d5895913 buildFHSEnv: fix cross compilation
In particular, steam aarch64-linux -> x86_64-linux cross did not compile
before.
2024-12-02 20:52:27 +01:00
Jörg Thalheim
1af9e10973
nixos/dockerTools: fixup proot/fakeroot code - exclude also dev (#308603) 2024-12-02 09:46:17 +01:00
Philip Taron
7df32823cc
buildFHSEnv: symlink libexec into the FHS tree (#328685) 2024-12-01 16:33:50 -08:00
Nathan Regner
551230b7a9 buildGraalvmNativeImage: fix build on darwin-x86_64 2024-12-01 10:05:39 -07:00
Philip Taron
a1ed41a112
appimageTools: use version (#359930) 2024-12-01 08:12:40 -08:00
K900
10f06c512e
fetchurl: clean up KDE mirrors (#360523) 2024-12-01 14:28:54 +03:00
Sefa Eyeoglu
7779a86836
Fix Codeql findings in update scripts (#342541) 2024-12-01 12:17:24 +01:00
Felix Buehler
0e6cb950cf appimageTools: deprecate name & version 2024-12-01 11:13:43 +01:00
Maximilian Bosch
eecda1aa70
Merge: runInLinuxVM: refactor structuredAttrs support, fix disko (#360413) 2024-12-01 00:35:02 +01:00
K900
07af3c1768 fetchurl: clean up KDE mirrors
Use download.kde.org as recommended by upstream, keep funet as fallback.
2024-11-30 21:41:35 +03:00
Wolfgang Walther
d2593f01e1
runInLinuxVM: pass .attrs.sh explicitly instead of whole /build directory
The approach taken in [1] breaks down as soon as vmRunCommand is
manually called with an overriden TMPDIR, like disko does it. /build
will just not be available.

By moving the .attrs.sh file into the xchg folder explicitly, we can all
the "exchange infrastructure" the same as before, thus avoid more
breakage.

This reverts some parts of [1].

[1]: 97ed6b4565
2024-11-30 13:46:45 +01:00
Wolfgang Walther
58570e75d9
runInLinuxVM: refactor vmRunCommand
This makes it simpler to copy more files to xchg for the structuredAttrs
case in the next commit.
2024-11-30 13:40:27 +01:00
Wolfgang Walther
437e6dbbb0
runInLinuxVM: load stdenv/setup with fixed environment in stage2Init
In [1] we started sourcing stdenv/setup in stage2Init to allow for
structuredAttrs. We failed to take the changed NIX_BUILD_TOP etc.
variables into account. We need to load stdenv/setup after changing
them, because the structuredAttrs startup code makes use of it.

[1]: 97ed6b4565
2024-11-30 13:40:26 +01:00
Wolfgang Walther
9f6b99e1ef
runInLinuxVM: minimize saved-env
The export to saved-env was very intentionally done at the very
beginning of vmRunCommand, even jumping through extra hoops just to
avoid the PATH variable from polluting the saved variable.

In 26eba25577 we loaded stdenv in the
wrong place, we should do it after saving the previous environment. This
is also more consistent with the order of how we load those values back
in stage2Init.
2024-11-30 13:40:26 +01:00
Wolfgang Walther
3952f870fc
runInLinuxVM: clean up
Those were left-over after 97ed6b4565.

This also cleans up some confusion around TMPDIR. We had the following
lines:

  mkdir xchg
  ...
  cd $TMPDIR
  ...
  path=$TMPDIR/xchg

Those only worked because the **current directory** is the same as
$TMPDIR. Both are /build by default. To refer to the same directory in
two different ways is very confusing at best.
2024-11-30 13:39:58 +01:00
Wolfgang Walther
de7867c226
runInLinuxVM: add simple structuredAttrs test 2024-11-30 12:26:26 +01:00
Tim Schumacher
3cf4fac925 buildFHSEnv: symlink libexec into the FHS tree 2024-11-30 12:21:54 +01:00
Stefan Frijters
8a667a5213
buildFHSEnv: fix cross compilation
rootfs-builder is executed at build time and thus needs to be
built for the build machine architecture.
2024-11-30 11:02:48 +01:00
tomberek
4703b8d2c7
pkgs.dockertools.buildLayeredImage: customisable layering strategy (#122608) 2024-11-29 22:39:21 -05:00
Adrian Gierakowski
266283bec3 build-support/docker: use runCommand in make-layers.nix 2024-11-29 21:59:36 +00:00
Jörg Thalheim
a4308aba72
buildGoModule: no longer filter out vendorSha256 (#359798) 2024-11-28 12:17:46 +01:00
Philip Taron
fe1509dc6c
buildFHSEnv: void ldconfig warnings (#359080) 2024-11-27 15:15:36 -08:00
Will Fancher
357a340019
various: remove left-over rtc_cmos rootModule (#359416) 2024-11-27 15:49:12 -05:00
Jörg Thalheim
1b02ba59aa
treewide: hide more deprecated stuff if allowAliases is false (#354709) 2024-11-27 21:44:06 +01:00
jopejoe1
2e2c7f54fd treewide: hide more deprecated stuff if allowAliases is false 2024-11-27 20:51:46 +01:00
Emily
3426d4110f
desktopToDarwinBundle: fix 16x, 32x app icons (#358247) 2024-11-27 19:37:17 +00:00
Yueh-Shun Li
7542b942a4 buildGoModule: no longer filter out vendorSha256 2024-11-28 00:11:33 +08:00
Aleksana
69251dc99c
buildRustPackage: fix passing depsExtraArgs to fetchCargoVendor (#359211) 2024-11-27 19:36:58 +08:00
Wolfgang Walther
d232880c20
various: remove left-over rtc_cmos rootModule
This is not needed anymore after
65a50ea453.
2024-11-26 22:02:46 +01:00
Maximilian Bosch
6f3d8a72ea
runInLinuxVM: remove hwclock -s invocation
Commit 97ed6b4565 broke the systemd-boot
tests (among others) because of the `hwclock -s` invocation. This was
broken for a while, but not noticed because we didn't have a `set -e`
before.

The error

    hwclock: select() to /dev/rtc0 to wait for clock tick timed out

MAY be related to an open QEMU bug[1]: I can't reproduce the error on
aarch64-linux and x86_64-linux with `partitionTableType = "legacy";`.
Also, the issue disappears on x86_64-linux when adding `--directisa`.

However, the invocation was added in f73ff0529e
10 years ago which didn't give any reasoning or pointer to what KVM bug
this may be. Given that this must have happened on an ancient version,
we agreed on removing it altogether[2].

[1] https://gitlab.com/qemu-project/qemu/-/issues/1762
[2] https://github.com/NixOS/nixpkgs/pull/354535#issuecomment-2500791222
2024-11-26 15:51:11 +01:00
TomaSajt
455241a036
buildRustPackage: fix passing depsExtraArgs to fetchCargoVendor 2024-11-26 08:48:06 +01:00
Philip Taron
87f46ee633
fetchsvn: add system certificate authorities bundle (#356829) 2024-11-25 15:58:58 -08:00
Sandro Jäckel
756c907d41 buildFHSEnv: void ldconfig warnings 2024-11-25 19:57:11 +01:00
Philip Taron
62742e9d5e
singularity-tools: enable __structuredAttrs and pass contents directly (#358723) 2024-11-25 10:05:42 -08:00
Someone
40f086a50e
Revert "singularity-tools: don't preserve store content ownership" (#358817) 2024-11-25 14:15:13 +00:00
Wolfgang Walther
c4461bbe1c
singularity-tools: remove deprecated shellScript and mkLayer
Scheduled for 25.05.
2024-11-24 21:09:34 +01:00
Emily
49d9ef16b1
treewide: remove deprecations up until 24.11 (#356732) 2024-11-24 19:46:12 +00:00
Yueh-Shun Li
f663b14524 Revert "singularity-tools: don't preserve store content ownership"
Use `cp -ar` instead of `cp -r` to preserve symbolic links
and other attributes whenever possible.

This reverts commit c2eb0aa56e.
2024-11-25 02:21:45 +08:00
Yueh-Shun Li
eff53a2135 singularity-tools: enable __structuredAttrs and pass contents directly 2024-11-24 22:19:31 +08:00
Maximilian Bosch
4e2ce1ba94
apptainer.tests.image-hello-cowsay: remove obsolete rmdir "$out" 2024-11-24 14:25:09 +01:00
Maximilian Bosch
26eba25577
runInLinuxVM: re-add sourcing of stdenv & .attrs.sh
This is required for `preVM` which can be arbitrary code: e.g.
`vmTools.createEmptyImage` assumes the presence of `$out` in its default
configuration.

Also, before this patch, `preVM` wasn't even set in the
`__structuredAttrs` case.
2024-11-24 14:24:37 +01:00
Karolis Stasaitis
3b52cd4c1b desktopToDarwinBundle: fix 16x, 32x app icons
Changes the script to produce rgb+mask images for 16x and 32x icons
instead of png.

Using icns files containing 16x and 32x png images for app bundles
results in Finder misrendering icons for these sizes (even though the
icns files are rendered correctly when viewed by themselves)
2024-11-23 15:55:09 +01:00
Maximilian Bosch
6deea16edc
Merge: runInLinuxVM: fix for structured attrs (#354535) 2024-11-23 09:35:18 +01:00
Wolfgang Walther
6646eeb500
makeSetupHook: remove deprecated deps argument
This had been scheduled for removal in 23.11.
2024-11-22 21:01:53 +01:00
Wolfgang Walther
51da8b6b00
writeReferencesToFile: remove
Had been deprecated and scheduled for removal in 24.11.
2024-11-22 21:01:53 +01:00
Maximilian Bosch
97ed6b4565
runInLinuxVM: fix for structured attrs
Closes #334705
Addresses #205690

The main issue was that the output variable (i.e. `$out` and friends)
didn't exist. I figured the easiest way to add those is to source
`stdenv` here. Given that we build another derivation in this builder,
it's pretty likely that `stdenv` gets pulled already, so I don't expect
a real overhead here.

Also, this mounts `/build` into the VM: this is required to make sure
`.attrs.json` & `.attrs.sh` are available. Dropped the mount of `xchg`
into `/tmp` now since it's also part of `/build`.
2024-11-22 20:02:22 +01:00
Robert Schütz
6c4d710b94 rustPlatform.buildRustPackage: allow specifying cargoDeps 2024-11-19 10:47:22 -08:00
Jörg Thalheim
bf20efd03c
rustPlatform.fetchCargoVendor: retry fetching tarballs (#357262) 2024-11-19 16:54:43 +01:00
Aleksana
0ecc88f77d
buildGoPackage: remove (#349478) 2024-11-19 22:41:50 +08:00