diff options
| author | Atemu <atemu.main@gmail.com> | 2023-07-01 06:36:05 +0200 |
|---|---|---|
| committer | Bjørn Forsman <bjorn.forsman@gmail.com> | 2023-10-19 19:02:31 +0200 |
| commit | 0a01ebbe700139993ba3a7e243ba9203622da92b (patch) | |
| tree | 9de8dbdcf6f261528a38d5660f27d49c1c64b108 | |
| parent | buildFHSEnv: cleanup (diff) | |
| download | nixpkgs-0a01ebbe700139993ba3a7e243ba9203622da92b.tar.gz | |
buildFHSEnv: add multiArch flag
The intention is to allow the user control over whether 32bit deps are supposed
to be included in the fhsenv
(cherry picked from commit 62b2adc753eaec8c3b3b10593055e96450c82b36)
| -rw-r--r-- | doc/builders/special/fhs-environments.section.md | 2 | ||||
| -rw-r--r-- | pkgs/build-support/build-fhsenv-bubblewrap/buildFHSEnv.nix | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/doc/builders/special/fhs-environments.section.md b/doc/builders/special/fhs-environments.section.md index 5a248e4ead92..8145fbd730f7 100644 --- a/doc/builders/special/fhs-environments.section.md +++ b/doc/builders/special/fhs-environments.section.md @@ -11,6 +11,8 @@ Accepted arguments are: Packages to be installed for the main host's architecture (i.e. x86_64 on x86_64 installations). Along with libraries binaries are also installed. - `multiPkgs` Packages to be installed for all architectures supported by a host (i.e. i686 and x86_64 on x86_64 installations). Only libraries are installed by default. +- `multiArch` + Whether to install 32bit multiPkgs into the FHSEnv in 64bit environments - `extraBuildCommands` Additional commands to be executed for finalizing the directory structure. - `extraBuildCommandsMulti` diff --git a/pkgs/build-support/build-fhsenv-bubblewrap/buildFHSEnv.nix b/pkgs/build-support/build-fhsenv-bubblewrap/buildFHSEnv.nix index f4fcc79b3936..15504916af63 100644 --- a/pkgs/build-support/build-fhsenv-bubblewrap/buildFHSEnv.nix +++ b/pkgs/build-support/build-fhsenv-bubblewrap/buildFHSEnv.nix @@ -12,6 +12,7 @@ , profile ? "" , targetPkgs ? pkgs: [] , multiPkgs ? pkgs: [] +, multiArch ? true # Whether to include 32bit packages , extraBuildCommands ? "" , extraBuildCommandsMulti ? "" , extraOutputsToInstall ? [] @@ -35,8 +36,8 @@ let inherit (stdenv) is64bit; - # use of glibc_multi is only supported on x86_64-linux - isMultiBuild = stdenv.system == "x86_64-linux"; + # "use of glibc_multi is only supported on x86_64-linux" + isMultiBuild = multiArch && stdenv.system == "x86_64-linux"; isTargetBuild = !isMultiBuild; # list of packages (usually programs) which are only be installed for the |
