Merge pull request #194256 from Artturin/treewides2

This commit is contained in:
Artturi 2022-10-13 00:08:01 +03:00 committed by GitHub
commit e66d2fd89d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
251 changed files with 381 additions and 363 deletions

View File

@ -378,7 +378,7 @@ rec {
attr = let attrFilter = name: value: name != "_module" && value != null;
in ind: x: libStr.concatStringsSep "\n" (lib.flatten (lib.mapAttrsToList
(name: value: lib.optional (attrFilter name value) [
(name: value: lib.optionals (attrFilter name value) [
(key "\t${ind}" name)
(expr "\t${ind}" value)
]) x));

View File

@ -261,7 +261,7 @@ in
in optional primeEnabled {
name = igpuDriver;
display = offloadCfg.enable;
modules = optional (igpuDriver == "amdgpu") [ pkgs.xorg.xf86videoamdgpu ];
modules = optionals (igpuDriver == "amdgpu") [ pkgs.xorg.xf86videoamdgpu ];
deviceSection = ''
BusID "${igpuBusId}"
${optionalString (syncCfg.enable && igpuDriver != "amdgpu") ''Option "AccelMethod" "none"''}

View File

@ -85,7 +85,7 @@ in
config = mkIf cfg.enable {
systemd.services.ethminer = {
path = optional (cfg.toolkit == "cuda") [ pkgs.cudaPackages.cudatoolkit ];
path = optionals (cfg.toolkit == "cuda") [ pkgs.cudaPackages.cudatoolkit ];
description = "ethminer ethereum mining service";
wantedBy = [ "multi-user.target" ];
after = [ "network.target" ];

View File

@ -36,7 +36,7 @@ in
};
serviceConfig = {
DynamicUser = true;
EnvironmentFile = lib.optional (cfg.passwordFile != null) [
EnvironmentFile = lib.optionals (cfg.passwordFile != null) [
cfg.passwordFile
];
ExecStart = "${pkgs.podgrab}/bin/podgrab";

View File

@ -199,7 +199,7 @@ in
environment.systemPackages = [ pkgs.hostapd ];
services.udev.packages = optional (cfg.countryCode != null) [ pkgs.crda ];
services.udev.packages = optionals (cfg.countryCode != null) [ pkgs.crda ];
systemd.services.hostapd =
{ description = "hostapd wireless AP";

View File

@ -27,7 +27,7 @@ let
${cfg.extraConfig}
'';
chronyFlags = "-n -m -u chrony -f ${configFile} ${toString cfg.extraFlags}";
chronyFlags = [ "-n" "-m" "-u" "chrony" "-f" "${configFile}" ] ++ cfg.extraFlags;
in
{
options = {
@ -166,7 +166,7 @@ in
unitConfig.ConditionCapability = "CAP_SYS_TIME";
serviceConfig =
{ Type = "simple";
ExecStart = "${chronyPkg}/bin/chronyd ${chronyFlags}";
ExecStart = "${chronyPkg}/bin/chronyd ${builtins.toString chronyFlags}";
ProtectHome = "yes";
ProtectSystem = "full";

View File

@ -25,7 +25,7 @@ let
${cfg.extraConfig}
'';
ntpFlags = "-c ${configFile} -u ntp:ntp ${toString cfg.extraFlags}";
ntpFlags = [ "-c" "${configFile}" "-u" "ntp:ntp" ] ++ cfg.extraFlags;
in
@ -137,7 +137,7 @@ in
'';
serviceConfig = {
ExecStart = "@${ntp}/bin/ntpd ntpd -g ${ntpFlags}";
ExecStart = "@${ntp}/bin/ntpd ntpd -g ${builtins.toString ntpFlags}";
Type = "forking";
};
};

View File

@ -816,13 +816,13 @@ in
always create a container/VM with a separate Tor daemon instance.
'' ++
flatten (mapAttrsToList (n: o:
optional (o.settings.HiddenServiceVersion == 2) [
optionals (o.settings.HiddenServiceVersion == 2) [
(optional (o.settings.HiddenServiceExportCircuitID != null) ''
HiddenServiceExportCircuitID is used in the HiddenService: ${n}
but this option is only for v3 hidden services.
'')
] ++
optional (o.settings.HiddenServiceVersion != 2) [
optionals (o.settings.HiddenServiceVersion != 2) [
(optional (o.settings.HiddenServiceAuthorizeClient != null) ''
HiddenServiceAuthorizeClient is used in the HiddenService: ${n}
but this option is only for v2 hidden services.

View File

@ -46,7 +46,7 @@ let
'';
})).override {
plugins = ps: ((cfg.plugins ps)
++ optional cfg.enableLdap [ ps.django-auth-ldap ]);
++ optionals cfg.enableLdap [ ps.django-auth-ldap ]);
};
netboxManageScript = with pkgs; (writeScriptBin "netbox-manage" ''
#!${stdenv.shell}

View File

@ -28,7 +28,7 @@ let
, withX11 ? false
# Extra flags to pass to gnome-desktop-testing-runner.
, testRunnerFlags ? ""
, testRunnerFlags ? []
# Extra attributes to pass to makeTest.
# They will be recursively merged into the attrset created by this function.
@ -67,7 +67,7 @@ let
'' +
''
machine.succeed(
"gnome-desktop-testing-runner ${testRunnerFlags} -d '${tested.installedTests}/share'"
"gnome-desktop-testing-runner ${escapeShellArgs testRunnerFlags} -d '${tested.installedTests}/share'"
)
'';
}

View File

@ -11,5 +11,5 @@ makeInstalledTest {
virtualisation.diskSize = 2048;
};
testRunnerFlags = "--timeout 3600";
testRunnerFlags = [ "--timeout" "3600" ];
}

View File

@ -13,5 +13,5 @@ makeInstalledTest {
virtualisation.diskSize = 3072;
};
testRunnerFlags = "--timeout 3600";
testRunnerFlags = [ "--timeout" "3600" ];
}

View File

@ -9,5 +9,5 @@ makeInstalledTest {
virtualisation.memorySize = if pkgs.stdenv.isi686 then 2047 else 4096;
};
testRunnerFlags = "--timeout 1800";
testRunnerFlags = [ "--timeout" "1800" ];
}

View File

@ -54,15 +54,15 @@ import ../make-test-python.nix ({ pkgs, lib, ... }:
role = "server";
package = pkgs.k3s;
clusterInit = true;
extraFlags = ''
--disable coredns \
--disable local-storage \
--disable metrics-server \
--disable servicelb \
--disable traefik \
--node-ip 192.168.1.1 \
--pause-image test.local/pause:local
'';
extraFlags = builtins.toString [
"--disable" "coredns"
"--disable" "local-storage"
"--disable" "metrics-server"
"--disable" "servicelb"
"--disable" "traefik"
"--node-ip" "192.168.1.1"
"--pause-image" "test.local/pause:local"
];
};
networking.firewall.allowedTCPPorts = [ 2379 2380 6443 ];
networking.firewall.allowedUDPPorts = [ 8472 ];
@ -84,15 +84,15 @@ import ../make-test-python.nix ({ pkgs, lib, ... }:
enable = true;
serverAddr = "https://192.168.1.1:6443";
clusterInit = false;
extraFlags = ''
--disable coredns \
--disable local-storage \
--disable metrics-server \
--disable servicelb \
--disable traefik \
--node-ip 192.168.1.3 \
--pause-image test.local/pause:local
'';
extraFlags = builtins.toString [
"--disable" "coredns"
"--disable" "local-storage"
"--disable" "metrics-server"
"--disable" "servicelb"
"--disable" "traefik"
"--node-ip" "192.168.1.3"
"--pause-image" "test.local/pause:local"
];
};
networking.firewall.allowedTCPPorts = [ 2379 2380 6443 ];
networking.firewall.allowedUDPPorts = [ 8472 ];
@ -112,7 +112,10 @@ import ../make-test-python.nix ({ pkgs, lib, ... }:
enable = true;
role = "agent";
serverAddr = "https://192.168.1.3:6443";
extraFlags = "--pause-image test.local/pause:local --node-ip 192.168.1.2";
extraFlags = lib.toString [
"--pause-image" "test.local/pause:local"
"--node-ip" "192.168.1.2"
];
};
networking.firewall.allowedTCPPorts = [ 6443 ];
networking.firewall.allowedUDPPorts = [ 8472 ];

View File

@ -40,15 +40,14 @@ import ../make-test-python.nix ({ pkgs, lib, ... }:
services.k3s.role = "server";
services.k3s.package = pkgs.k3s;
# Slightly reduce resource usage
services.k3s.extraFlags = ''
--disable coredns \
--disable local-storage \
--disable metrics-server \
--disable servicelb \
--disable traefik \
--pause-image \
test.local/pause:local
'';
services.k3s.extraFlags = builtins.toString [
"--disable" "coredns"
"--disable" "local-storage"
"--disable" "metrics-server"
"--disable" "servicelb"
"--disable" "traefik"
"--pause-image" "test.local/pause:local"
];
users.users = {
noprivs = {

View File

@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
buildInputs = [ libsndfile ]
++ lib.optional (!stdenv.isDarwin) alsa-lib
++ lib.optional stdenv.isDarwin [ AppKit Carbon CoreAudio CoreMIDI CoreServices Kernel ];
++ lib.optionals stdenv.isDarwin [ AppKit Carbon CoreAudio CoreMIDI CoreServices Kernel ];
patches = [ ./darwin-limits.patch ];

View File

@ -17,7 +17,7 @@ stdenv.mkDerivation rec {
buildInputs = [ fftwFloat alsa-lib zlib wavpack wxGTK31 udev ]
++ lib.optional jackaudioSupport libjack2;
cmakeFlags = lib.optional (!jackaudioSupport) [
cmakeFlags = lib.optionals (!jackaudioSupport) [
"-DRTAUDIO_USE_JACK=OFF"
"-DRTMIDI_USE_JACK=OFF"
] ++ lib.optional (!includeDemo) "-DINSTALL_DEMO=OFF";

View File

@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
aixlog popl soxr
] ++ lib.optional pulseaudioSupport libpulseaudio
++ lib.optional stdenv.isLinux alsa-lib
++ lib.optional stdenv.isDarwin [darwin.apple_sdk.frameworks.IOKit darwin.apple_sdk.frameworks.AudioToolbox];
++ lib.optionals stdenv.isDarwin [darwin.apple_sdk.frameworks.IOKit darwin.apple_sdk.frameworks.AudioToolbox];
TARGET=lib.optionalString stdenv.isDarwin "MACOS";

View File

@ -38,7 +38,7 @@ rustPlatform.buildRustPackage rec {
# Exclude some tests that don't work in the sandbox
# - Nat test requires network access
checkFlags = "--skip configuration::tests::should_resolve_external_nat_hosts";
checkFlags = [ "--skip" "configuration::tests::should_resolve_external_nat_hosts" ];
meta = with lib; {
broken = stdenv.isDarwin;

View File

@ -34,7 +34,7 @@ rustPlatform.buildRustPackage rec {
cargoSha256 = "sha256-mI8VvTlM9ynstDBC0ubQkzg3D2ZXuWqJGS/Y23D6dU0=";
buildInputs = lib.optional stdenv.isDarwin [ Security ];
buildInputs = lib.optionals stdenv.isDarwin [ Security ];
nativeBuildInputs = [ clang ];

View File

@ -85,7 +85,7 @@ in
makeWrapper
pandoc
nodejs
] ++ lib.optional (!server) [
] ++ lib.optionals (!server) [
copyDesktopItems
];
@ -118,7 +118,7 @@ in
"-DQUARTO_ENABLED=FALSE"
"-DPANDOC_VERSION=${pandoc.version}"
"-DCMAKE_INSTALL_PREFIX=${placeholder "out"}/lib/rstudio"
] ++ lib.optional (!server) [
] ++ lib.optionals (!server) [
"-DQT_QMAKE_EXECUTABLE=${qmake}/bin/qmake"
];

View File

@ -109,7 +109,7 @@ in stdenv.mkDerivation rec {
++ lib.optionals luaSupport [
"--with-lua-prefix=${lua}"
"--enable-luainterp"
] ++ lib.optional lua.pkgs.isLuaJIT [
] ++ lib.optionals lua.pkgs.isLuaJIT [
"--with-luajit"
]
++ lib.optionals pythonSupport [

View File

@ -66,7 +66,7 @@ let
buildInputs = [ libsecret libXScrnSaver libxshmfence ]
++ lib.optionals (!stdenv.isDarwin) ([ at-spi2-atk ] ++ atomEnv.packages);
runtimeDependencies = lib.optional stdenv.isLinux [ (lib.getLib systemd) fontconfig.lib libdbusmenu ];
runtimeDependencies = lib.optionals stdenv.isLinux [ (lib.getLib systemd) fontconfig.lib libdbusmenu ];
nativeBuildInputs = [ unzip ]
++ lib.optionals stdenv.isLinux [

View File

@ -676,7 +676,7 @@ in
description = "Fast MegaDrive/MegaCD/32X emulator";
license = "MAME";
dontConfigure = true;
makeFlags = lib.optional stdenv.hostPlatform.isAarch64 [ "platform=aarch64" ];
makeFlags = lib.optionals stdenv.hostPlatform.isAarch64 [ "platform=aarch64" ];
};
play = mkLibRetroCore {

View File

@ -40,8 +40,8 @@ stdenv.mkDerivation rec {
NIX_LDFLAGS = lib.optionalString stdenv.hostPlatform.isMusl "-lfts";
makeFlags = [ "PREFIX=${placeholder "out"}" ]
++ lib.optional withIcons [ "O_ICONS=1" ]
++ lib.optional withNerdIcons [ "O_NERD=1" ];
++ lib.optionals withIcons [ "O_ICONS=1" ]
++ lib.optionals withNerdIcons [ "O_NERD=1" ];
binPath = lib.makeBinPath [ file which ];

View File

@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
"-DGMT_INSTALL_MODULE_LINKS:BOOL=FALSE"
"-DLICENSE_RESTRICTED=LGPL" # "GPL" and "no" also valid
] ++ (with stdenv;
lib.optional (!isDarwin) [
lib.optionals (!isDarwin) [
"-DFFTW3_ROOT=${fftwSinglePrec.dev}"
"-DLAPACK_LIBRARY=${lapack}/lib/liblapack.so"
"-DBLAS_LIBRARY=${blas}/lib/libblas.so"

View File

@ -23,7 +23,7 @@ mkDerivationWith python3Packages.buildPythonApplication rec {
raven
];
qtWrapperArgs = lib.optional archiveSupport [ "--prefix" "PATH" ":" "${ lib.makeBinPath [ p7zip ] }" ];
qtWrapperArgs = lib.optionals archiveSupport [ "--prefix" "PATH" ":" "${ lib.makeBinPath [ p7zip ] }" ];
postFixup = ''
wrapProgram $out/bin/kcc "''${qtWrapperArgs[@]}"

View File

@ -48,7 +48,7 @@ stdenv.mkDerivation rec {
]
++ lib.optional withLua lua;
buildFlags = "translations";
buildFlags = [ "translations" ];
hardeningDisable = [ "format" ];

View File

@ -47,7 +47,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [
autoreconfHook
autoconf-archive
] ++ lib.optional enableOpusfile [
] ++ lib.optionals enableOpusfile [
# configure.ac uses pkg-config only to locate libopusfile
pkg-config
];

View File

@ -127,7 +127,7 @@ stdenv.mkDerivation rec {
# Clang doesn't support "-export-dynamic"
++ optional stdenv.cc.isClang "-DPYTHON_LINKFLAGS="
++ optional jackaudioSupport "-DWITH_JACK=ON"
++ optional cudaSupport [
++ optionals cudaSupport [
"-DWITH_CYCLES_CUDA_BINARIES=ON"
"-DWITH_CYCLES_DEVICE_OPTIX=ON"
"-DOPTIX_ROOT_DIR=${optix}"

View File

@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
[ libev librsvg libpng libjpeg libtiff openssl xz bzip2 zlib ]
++ optionals stdenv.isLinux [ gpm ]
++ optionals enableX11 [ libX11 libXau libXt ]
++ optional enableDirectFB [ directfb ];
++ optionals enableDirectFB [ directfb ];
nativeBuildInputs = [ pkg-config bzip2 ];

View File

@ -37,7 +37,7 @@ let
doCheck = true;
nativeBuildInputs = [ makeWrapper ]
++ optional (stdenv.isLinux && (nativeLibs != [ ] || libPatches != "")) [ autoPatchelfHook ];
++ optionals (stdenv.isLinux && (nativeLibs != [ ] || libPatches != "")) [ autoPatchelfHook ];
buildInputs = [ openssl ] ++ nativeLibs;
installPhase = ''

View File

@ -43,7 +43,7 @@ stdenv.mkDerivation rec {
configureFlags = [ "--localstatedir=/var"
"--disable-doc" "--disable-man"
"--disable-update-ipsets" ] ++
lib.optional onlyQOS [ "--disable-firehol" ];
lib.optionals onlyQOS [ "--disable-firehol" ];
meta = with lib; {
description = "A firewall for humans";

View File

@ -34,7 +34,7 @@ buildPythonApplication rec {
peewee
prompt-toolkit
setuptools
] ++ lib.optional enableDbusUi [
] ++ lib.optionals enableDbusUi [
dbus-python
notify2
pygobject3

View File

@ -16,7 +16,7 @@ perlPackages.buildPerlPackage rec {
};
nativeBuildInputs = [ makeWrapper ]
++ optional stdenv.isDarwin [ shortenPerlShebang ];
++ optionals stdenv.isDarwin [ shortenPerlShebang ];
buildInputs = with perlPackages; [
CryptPassphrase CryptPassphraseArgon2 CryptPassphraseBcrypt

View File

@ -15,7 +15,7 @@ with python3.pkgs; buildPythonApplication rec {
outputs = [
"out"
] ++ lib.optional withManpage [
] ++ lib.optionals withManpage [
"man"
];

View File

@ -31,7 +31,7 @@ rustPlatform.buildRustPackage rec {
checkInputs = [ file ];
buildFeatures = lib.optional withNotmuch [ "notmuch" ];
buildFeatures = lib.optionals withNotmuch [ "notmuch" ];
postInstall = ''
mkdir -p $out/share/man/man1

View File

@ -25,11 +25,11 @@ stdenv.mkDerivation rec {
gnutls
gsasl
libidn
] ++ lib.optional stdenv.isDarwin [
] ++ lib.optionals stdenv.isDarwin [
Security
];
configureFlags = lib.optional stdenv.isDarwin [
configureFlags = lib.optionals stdenv.isDarwin [
"--with-macosx-keyring"
];

View File

@ -27,7 +27,7 @@ stdenv.mkDerivation rec {
# Special flags needed on Darwin:
# https://github.com/axkibe/lsyncd/blob/42413cabbedca429d55a5378f6e830f191f3cc86/INSTALL#L51
cmakeFlags = lib.optional stdenv.isDarwin [ "-DWITH_INOTIFY=OFF" "-DWITH_FSEVENTS=ON" ];
cmakeFlags = lib.optionals stdenv.isDarwin [ "-DWITH_INOTIFY=OFF" "-DWITH_FSEVENTS=ON" ];
dontUseCmakeBuildDir = true;

View File

@ -36,8 +36,8 @@ stdenv.mkDerivation rec {
(lib.enableFeature withTcl "tcl")
(lib.withFeatureAs withTcl "tcl" "${tcl}/lib")
(lib.enableFeature withCyrus "cyrus")
] ++ optional (!withIPv6) [ "--disable-ipv6" ]
++ optional withDebug [ "--enable-debug" ];
] ++ optionals (!withIPv6) [ "--disable-ipv6" ]
++ optionals withDebug [ "--enable-debug" ];
enableParallelBuilding = true;

View File

@ -29,7 +29,7 @@ stdenv.mkDerivation rec {
buildInputs = [ libusb1 ];
cmakeFlags = lib.optional stdenv.isLinux [
cmakeFlags = lib.optionals stdenv.isLinux [
"-DINSTALL_UDEV_RULES=ON"
"-DWITH_RPC=ON"
];

View File

@ -14,7 +14,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake ];
buildInputs = [ zlib ];
cmakeFlags = lib.optional stdenv.hostPlatform.isStatic [
cmakeFlags = lib.optionals stdenv.hostPlatform.isStatic [
"-DSTATIC_BUILD=ON"
];
meta = with lib; {

View File

@ -26,7 +26,7 @@ stdenv.mkDerivation rec {
sha256 = "0f26v3qvzblcdjg7isq0m9j2q8q7x3vhmkfllv8lsr3gyj44lljf";
};
patches = (lib.optional (stdenv.isDarwin) [ ./neuron-carbon-disable.patch ]);
patches = (lib.optionals (stdenv.isDarwin) [ ./neuron-carbon-disable.patch ]);
# With LLVM 3.8 and above, clang (really libc++) gets upset if you attempt to redefine these...
postPatch = lib.optionalString stdenv.cc.isClang ''

View File

@ -32,7 +32,7 @@ stdenv.mkDerivation rec {
configureFlags = [ "--with-htslib=${htslib}" ]
++ lib.optional (ncurses == null) "--without-curses"
++ lib.optional stdenv.hostPlatform.isStatic ["--without-curses" ]
++ lib.optionals stdenv.hostPlatform.isStatic ["--without-curses" ]
;
preCheck = ''

View File

@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ cmake python3.pkgs.wrapPython ];
buildInputs = [ python3 osi ];
cmakeFlags = lib.optional osi.withCplex [ "-DDOWNWARD_CPLEX_ROOT=${cplex}/cplex" ];
cmakeFlags = lib.optionals osi.withCplex [ "-DDOWNWARD_CPLEX_ROOT=${cplex}/cplex" ];
configurePhase = ''
python build.py release

View File

@ -20,7 +20,7 @@ stdenv.mkDerivation rec {
buildInputs = [ gmp ];
makeFlags = [ "CC=${stdenv.cc.targetPrefix}cc" ];
buildFlags = lib.optional stdenv.isDarwin ["CCFLAGS2=-lgmp -lc -lm" "CCFLAGS=-UUSE_SSE"];
buildFlags = lib.optionals stdenv.isDarwin ["CCFLAGS2=-lgmp -lc -lm" "CCFLAGS=-UUSE_SSE"];
installFlags = [ "INSTALL_DIR=$(out)" ];
preInstall = ''mkdir -p "$out"/{bin,share,lib,include}'';

View File

@ -18,7 +18,7 @@ in stdenv.mkDerivation rec {
sha256 = "0km24rgll0s4ji6iz8lvy5ra76ds162s95y33w5px6697cwqkp9j";
};
buildFlags = "unix";
buildFlags = [ "unix" ];
postConfigure = ''
pushd c3270 ; ./configure ; popd

View File

@ -59,8 +59,8 @@ python3.pkgs.buildPythonApplication rec {
# python>=3.8
distro
] ++ lib.optional stdenv.hostPlatform.isWindows [ colorama ]
++ lib.optional (python3.pythonOlder "3.10") [ importlib-metadata ];
] ++ lib.optionals stdenv.hostPlatform.isWindows [ colorama ]
++ lib.optionals (python3.pythonOlder "3.10") [ importlib-metadata ];
postInstall = ''
installShellCompletion --cmd datalad \

View File

@ -72,17 +72,17 @@ python3.pkgs.buildPythonApplication rec {
typing-extensions
voluptuous
zc_lockfile
] ++ lib.optional enableGoogle [
] ++ lib.optionals enableGoogle [
gcsfs
google-cloud-storage
] ++ lib.optional enableAWS [
] ++ lib.optionals enableAWS [
aiobotocore
boto3
s3fs
] ++ lib.optional enableAzure [
] ++ lib.optionals enableAzure [
azure-identity
knack
] ++ lib.optional enableSSH [
] ++ lib.optionals enableSSH [
bcrypt
] ++ lib.optionals (pythonOlder "3.8") [
importlib-metadata

View File

@ -15,7 +15,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ makeWrapper autoreconfHook asciidoc xmlto docbook_xsl docbook_xml_dtd_45 findXMLCatalogs pkg-config ];
autoreconfFlags = "-I tools -v";
autoreconfFlags = [ "-I" "tools" "-v" ];
buildInputs = [ ncurses readline git ]
++ lib.optionals stdenv.isDarwin [ libiconv ];

View File

@ -37,7 +37,7 @@ let
railties = x.railties // {
dontBuild = false;
patches = [ ./railties-remove-yarn-install-enhancement.patch ];
patchFlags = "-p2";
patchFlags = [ "-p2" ];
};
};
groups = [

View File

@ -40,7 +40,7 @@ let
++ lib.optionals pythonBindings [ python3 py3c ]
++ lib.optional perlBindings perl
++ lib.optional saslSupport sasl
++ lib.optional stdenv.hostPlatform.isDarwin [ CoreServices Security ];
++ lib.optionals stdenv.hostPlatform.isDarwin [ CoreServices Security ];
patches = [ ./apr-1.patch ] ++ extraPatches;

View File

@ -138,7 +138,7 @@ in stdenv.mkDerivation {
lirc
mesa # for libEGL
]
++ lib.optional x11Support [
++ lib.optionals x11Support [
libX11 xorgproto libXt libXmu libXext.dev libXdmcp
libXinerama libXrandr.dev libXtst libXfixes
]
@ -158,7 +158,7 @@ in stdenv.mkDerivation {
# Not sure why ".dev" is needed here, but CMake doesn't find libxkbcommon otherwise
libxkbcommon.dev
]
++ lib.optional gbmSupport [
++ lib.optionals gbmSupport [
libxkbcommon.dev
mesa.dev
libinput.dev
@ -200,7 +200,7 @@ in stdenv.mkDerivation {
# whitelisted directories). This adds the entire nix store to the Kodi
# webserver whitelist to avoid this problem.
"-DKODI_WEBSERVER_EXTRA_WHITELIST=${builtins.storeDir}"
] ++ lib.optional waylandSupport [
] ++ lib.optionals waylandSupport [
"-DWAYLANDPP_SCANNER=${buildPackages.waylandpp}/bin/wayland-scanner++"
];

View File

@ -15,7 +15,7 @@ rec {
} // args);
mvnBuild = args: import ./maven-build.nix (
{ inherit stdenv;
{ inherit lib stdenv;
} // args);
nixBuild = args: import ./nix-build.nix (

View File

@ -1,4 +1,5 @@
{ stdenv
, lib
, name
, src
, doTest ? true
@ -12,7 +13,11 @@
} @ args :
let
mvnFlags = "-Dmaven.repo.local=$M2_REPO ${if doTest then "" else "-Dmaven.test.skip.exec=true"} ${extraMvnFlags}";
mvnFlags = lib.escapeShellArgs [
"-Dmaven.repo.local=$M2_REPO"
(lib.optionalString (!doTest) "-Dmaven.test.skip.exec=true")
"${extraMvnFlags}"
];
in
stdenv.mkDerivation ( {

View File

@ -87,7 +87,7 @@ stdenv.mkDerivation {
inherit postConfigure;
makeFlags = lib.optional stdenv.cc.isClang [ "AR=${stdenv.cc.targetPrefix}ar" "RANLIB=${stdenv.cc.targetPrefix}ranlib" ];
makeFlags = lib.optionals stdenv.cc.isClang [ "AR=${stdenv.cc.targetPrefix}ar" "RANLIB=${stdenv.cc.targetPrefix}ranlib" ];
# TODO(Profpatsch): ensure that there is always a $doc output!
postInstall = ''

View File

@ -86,7 +86,7 @@ stdenv.mkDerivation rec {
inherit extraParameters;
passAsFile = [
"extraParameters"
] ++ lib.optional (! (builtins.isString privateBuildPlan && lib.hasPrefix builtins.storeDir privateBuildPlan)) [
] ++ lib.optionals (! (builtins.isString privateBuildPlan && lib.hasPrefix builtins.storeDir privateBuildPlan)) [
"buildPlan"
];

View File

@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
configureFlags =
# fixes the "libgconfbackend-oldxml.so is not portable" error on darwin
lib.optional stdenv.isDarwin [ "--enable-static" ];
lib.optionals stdenv.isDarwin [ "--enable-static" ];
postPatch = ''
2to3 --write --nobackup gsettings/gsettings-schema-convert

View File

@ -129,7 +129,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ makeWrapper unzip which git ];
buildInputs = [ gdb curl tzdata ]
++ lib.optional stdenv.isDarwin [ Foundation gdb ];
++ lib.optionals stdenv.isDarwin [ Foundation gdb ];
osname = if stdenv.isDarwin then

View File

@ -61,7 +61,7 @@ edk2 = buildStdenv.mkDerivation {
${"GCC5_${targetArch}_PREFIX"}=stdenv.cc.targetPrefix;
makeFlags = [ "-C BaseTools" ]
++ lib.optional (stdenv.cc.isClang) [ "BUILD_CC=clang BUILD_CXX=clang++ BUILD_AS=clang" ];
++ lib.optionals (stdenv.cc.isClang) [ "BUILD_CC=clang BUILD_CXX=clang++ BUILD_AS=clang" ];
NIX_CFLAGS_COMPILE = "-Wno-return-type" + lib.optionalString (stdenv.cc.isGNU) " -Wno-error=stringop-truncation";

View File

@ -13,7 +13,7 @@ stdenv.mkDerivation {
buildInputs = [ m4 ];
configureFlags = lib.optional stdenv.isDarwin [ "--build=x86_64-apple-darwin" ];
configureFlags = lib.optionals stdenv.isDarwin [ "--build=x86_64-apple-darwin" ];
meta = {
description = "The Forth implementation of the GNU project (outdated version used to bootstrap)";

View File

@ -38,7 +38,7 @@ stdenv.mkDerivation rec {
];
buildInputs = [
zlib
] ++ lib.optional (backend == "llvm") [
] ++ lib.optionals (backend == "llvm") [
llvm
];
propagatedBuildInputs = [

View File

@ -34,7 +34,7 @@ in stdenv.mkDerivation rec {
strictDeps = true;
nativeBuildInputs = [ makeWrapper clang platformChez ]
++ lib.optional stdenv.isDarwin [ zsh ];
++ lib.optionals stdenv.isDarwin [ zsh ];
buildInputs = [ platformChez gmp ];
prePatch = ''

View File

@ -11,7 +11,7 @@ let
# is not the case with pure nix environments. Thus, we need to include zsh
# when we build for darwin in tests. While this is impure, this is also what
# we find in real darwin hosts.
nativeBuildInputs = lib.optional stdenv.isDarwin [ zsh ];
nativeBuildInputs = lib.optionals stdenv.isDarwin [ zsh ];
buildCommand = ''
set -eo pipefail

View File

@ -45,7 +45,7 @@ stdenv.mkDerivation {
"-DLIBCXX_CXX_ABI=libcxxabi"
] ++ lib.optional (stdenv.hostPlatform.isMusl || stdenv.hostPlatform.isWasi) "-DLIBCXX_HAS_MUSL_LIBC=1"
++ lib.optional (stdenv.hostPlatform.useLLVM or false) "-DLIBCXX_USE_COMPILER_RT=ON"
++ lib.optional stdenv.hostPlatform.isWasm [
++ lib.optionals stdenv.hostPlatform.isWasm [
"-DLIBCXX_ENABLE_THREADS=OFF"
"-DLIBCXX_ENABLE_FILESYSTEM=OFF"
"-DLIBCXX_ENABLE_EXCEPTIONS=OFF"

View File

@ -48,7 +48,7 @@ stdenv.mkDerivation {
"-DLIBCXX_CXX_ABI=libcxxabi"
] ++ lib.optional (stdenv.hostPlatform.isMusl || stdenv.hostPlatform.isWasi) "-DLIBCXX_HAS_MUSL_LIBC=1"
++ lib.optional (stdenv.hostPlatform.useLLVM or false) "-DLIBCXX_USE_COMPILER_RT=ON"
++ lib.optional stdenv.hostPlatform.isWasm [
++ lib.optionals stdenv.hostPlatform.isWasm [
"-DLIBCXX_ENABLE_THREADS=OFF"
"-DLIBCXX_ENABLE_FILESYSTEM=OFF"
"-DLIBCXX_ENABLE_EXCEPTIONS=OFF"

View File

@ -36,7 +36,7 @@ stdenv.mkDerivation {
"-DLIBCXX_CXX_ABI=libcxxabi"
] ++ lib.optional (stdenv.hostPlatform.isMusl || stdenv.hostPlatform.isWasi) "-DLIBCXX_HAS_MUSL_LIBC=1"
++ lib.optional (stdenv.hostPlatform.useLLVM or false) "-DLIBCXX_USE_COMPILER_RT=ON"
++ lib.optional stdenv.hostPlatform.isWasm [
++ lib.optionals stdenv.hostPlatform.isWasm [
"-DLIBCXX_ENABLE_THREADS=OFF"
"-DLIBCXX_ENABLE_FILESYSTEM=OFF"
"-DLIBCXX_ENABLE_EXCEPTIONS=OFF"

View File

@ -49,7 +49,7 @@ stdenv.mkDerivation {
"-DLIBCXX_CXX_ABI=libcxxabi"
] ++ lib.optional (stdenv.hostPlatform.isMusl || stdenv.hostPlatform.isWasi) "-DLIBCXX_HAS_MUSL_LIBC=1"
++ lib.optional (stdenv.hostPlatform.useLLVM or false) "-DLIBCXX_USE_COMPILER_RT=ON"
++ lib.optional stdenv.hostPlatform.isWasm [
++ lib.optionals stdenv.hostPlatform.isWasm [
"-DLIBCXX_ENABLE_THREADS=OFF"
"-DLIBCXX_ENABLE_FILESYSTEM=OFF"
"-DLIBCXX_ENABLE_EXCEPTIONS=OFF"

View File

@ -45,7 +45,7 @@ stdenv.mkDerivation {
"-DLIBCXX_CXX_ABI=libcxxabi"
] ++ lib.optional (stdenv.hostPlatform.isMusl || stdenv.hostPlatform.isWasi) "-DLIBCXX_HAS_MUSL_LIBC=1"
++ lib.optional (stdenv.hostPlatform.useLLVM or false) "-DLIBCXX_USE_COMPILER_RT=ON"
++ lib.optional stdenv.hostPlatform.isWasm [
++ lib.optionals stdenv.hostPlatform.isWasm [
"-DLIBCXX_ENABLE_THREADS=OFF"
"-DLIBCXX_ENABLE_FILESYSTEM=OFF"
"-DLIBCXX_ENABLE_EXCEPTIONS=OFF"

View File

@ -19,7 +19,7 @@ in stdenv.mkDerivation {
buildInputs = [ coreutils smlnj ];
autoreconfFlags = "-Iconfig -vfi";
autoreconfFlags = [ "-Iconfig" "-vfi" ];
unpackPhase = ''
mkdir -p $out

View File

@ -26,7 +26,7 @@ in stdenv.mkDerivation rec {
outputBin = "dev"; # compilation tools
mesonFlags =
optional (!buildDevDoc) [ "-Dgtk_doc=disabled" ]
optionals (!buildDevDoc) [ "-Dgtk_doc=disabled" ]
;
nativeBuildInputs = [ meson ninja ]

View File

@ -66,8 +66,8 @@ stdenv.mkDerivation rec {
flex
cmake
]
++ lib.optional enableDocumentation [ doxygen graphviz ]
++ lib.optional enableBPF [ libllvm libbpf ];
++ lib.optionals enableDocumentation [ doxygen graphviz ]
++ lib.optionals enableBPF [ libllvm libbpf ];
buildInputs = [
protobuf

View File

@ -153,7 +153,7 @@ stdenv.mkDerivation rec {
optional (!threadSupport) "sb-thread" ++
optionals disableImmobileSpace [ "immobile-space" "immobile-code" "compact-instance-header" ];
NIX_CFLAGS_COMPILE = lib.optional (lib.versionOlder version "2.1.10") [
NIX_CFLAGS_COMPILE = lib.optionals (lib.versionOlder version "2.1.10") [
# Workaround build failure on -fno-common toolchains like upstream
# clang-13. Without the change build fails as:
# duplicate symbol '_static_code_space_free_pointer' in: alloc.o traceroot.o

View File

@ -10,7 +10,7 @@ with lib; mkCoqDerivation rec {
release."0.3.1".sha256 = "sha256-DyGxO2tqmYZZluXN6Oy5Tw6fuLMyuyxonj8CCToWKkk=";
release."0.3.0".sha256 = "1ffr21dd6hy19gxnvcd4if2450iksvglvkd6q5713fajd72hmc0z";
releaseRev = v: "v${v}";
buildFlags = "NO_TEST=1";
buildFlags = [ "NO_TEST=1" ];
meta = {
description = "Library to create Coq record update functions";
maintainers = with maintainers; [ ineol ];

View File

@ -77,7 +77,7 @@ in stdenv.mkDerivation rec {
'';
preBuild = "mkdir -p $HOME";
makeFlags = "LISP=${sbcl}/bin/sbcl ACL2_MAKE_LOG=NONE";
makeFlags = [ "LISP=${sbcl}/bin/sbcl" "ACL2_MAKE_LOG=NONE" ];
doCheck = true;
checkTarget = "mini-proveall";

View File

@ -18,9 +18,9 @@ stdenv.mkDerivation rec {
sourceRoot = "source/src";
buildInputs = [ libedit zlib ncurses ]
++ lib.optional stdenv.isDarwin ([
++ lib.optionals stdenv.isDarwin ([
Accelerate
] ++ lib.optional stdenv.isx86_64 /* && isDarwin */ [
] ++ lib.optionals stdenv.isx86_64 /* && isDarwin */ [
CoreGraphics CoreVideo
]);
@ -36,7 +36,7 @@ stdenv.mkDerivation rec {
"implicit-function-declaration"
"gnu-variable-sized-type-not-at-end"
"unused-result"
] ++ lib.optional stdenv.isDarwin [ "-fcommon" ];
] ++ lib.optionals stdenv.isDarwin [ "-fcommon" ];
patchPhase = ''
substituteInPlace ./Makefile \

View File

@ -206,7 +206,7 @@ let
[ pcre2 ]
# Enable sapis
++ lib.optional pearSupport [ libxml2.dev ]
++ lib.optionals pearSupport [ libxml2.dev ]
# Misc deps
++ lib.optional apxs2Support apacheHttpd
@ -230,7 +230,7 @@ let
++ lib.optional (!cgiSupport) "--disable-cgi"
++ lib.optional (!cliSupport) "--disable-cli"
++ lib.optional fpmSupport "--enable-fpm"
++ lib.optional pearSupport [ "--with-pear" "--enable-xml" "--with-libxml" ]
++ lib.optionals pearSupport [ "--with-pear" "--enable-xml" "--with-libxml" ]
++ lib.optional pharSupport "--enable-phar"
++ lib.optional (!phpdbgSupport) "--disable-phpdbg"

View File

@ -9,7 +9,7 @@ stdenv.mkDerivation rec {
nativeBuildInputs = [ bintools-unwrapped unzip ];
# slashes are significant because upstream uses o/$(MODE)/foo.o
buildFlags = "o//third_party/python";
buildFlags = [ "o//third_party/python" ];
checkTarget = "o//third_party/python/test";
enableParallelBuilding = true;

View File

@ -166,7 +166,7 @@ let
# only works for GCC and Apple Clang. This makes distutils to call C++
# compiler when needed.
./python-2.7-distutils-C++.patch
] ++ optional (stdenv.hostPlatform != stdenv.buildPlatform) [
] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
./cross-compile.patch
];

View File

@ -20,7 +20,7 @@ rustPlatform.buildRustPackage rec {
cargoHash = "sha256-T85kiPG80oZ4mwpb8Ag40wDHKx2Aens+gM7NGXan5lM=";
# freeze the stdlib into the rustpython binary
cargoBuildFlags = "--features=freeze-stdlib";
cargoBuildFlags = [ "--features=freeze-stdlib" ];
buildInputs = lib.optionals stdenv.isDarwin [ SystemConfiguration ];

View File

@ -128,8 +128,8 @@ stdenv.mkDerivation rec {
shared = if stdenv.isDarwin then "dylib" else "shared";
configureFlags = [ "--enable-${shared}" "--enable-lt=${libtool}/bin/libtool" ]
++ lib.optional disableDocs [ "--disable-docs" ]
++ lib.optional stdenv.isDarwin [ "--enable-xonx" ];
++ lib.optionals disableDocs [ "--disable-docs" ]
++ lib.optionals stdenv.isDarwin [ "--enable-xonx" ];
configureScript = "../configure";

View File

@ -83,8 +83,8 @@ stdenv.mkDerivation rec {
shared = if stdenv.isDarwin then "dylib" else "shared";
configureFlags = [ "--enable-${shared}" "--enable-lt=${libtool}/bin/libtool" ]
++ lib.optional disableDocs [ "--disable-docs" ]
++ lib.optional stdenv.isDarwin [ "--enable-xonx" ];
++ lib.optionals disableDocs [ "--disable-docs" ]
++ lib.optionals stdenv.isDarwin [ "--enable-xonx" ];
configureScript = "../configure";

View File

@ -42,7 +42,7 @@ stdenv.mkDerivation (finalAttrs: rec {
inherit hash;
};
patches = lib.optional (lib.versionOlder version "91") [
patches = lib.optionals (lib.versionOlder version "91") [
# Fix build failure on armv7l using Debian patch
# Upstream bug: https://bugzilla.mozilla.org/show_bug.cgi?id=1526653
(fetchpatch {

View File

@ -95,7 +95,7 @@ stdenv.mkDerivation rec {
# confusingly, for gprbuild --target is autoconf --host
"TARGET=${stdenv.hostPlatform.config}"
"prefix=${placeholder "out"}"
] ++ lib.optional (component == "sqlite") [
] ++ lib.optionals (component == "sqlite") [
# link against packaged, not vendored libsqlite3
"GNATCOLL_SQLITE=external"
];

View File

@ -49,7 +49,7 @@ stdenv.mkDerivation rec {
configureFlagsArray+=("--with-installbuilddir=$dev/share/build")
'';
configureFlags = lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) [
configureFlags = lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
# For cross builds, provide answers to the configure time tests.
# These answers are valid on x86_64-linux and aarch64-linux.
"ac_cv_file__dev_zero=yes"

View File

@ -21,7 +21,7 @@ stdenv.mkDerivation rec {
outputs = [ "out" "dist" ];
# slashes are significant because upstream uses o/$(MODE)/foo.o
buildFlags = "o/cosmopolitan.h o//cosmopolitan.a o//libc/crt/crt.o o//ape/ape.o o//ape/ape.lds";
buildFlags = [ "o/cosmopolitan.h" "o//cosmopolitan.a" "o//libc/crt/crt.o" "o//ape/ape.o" "o//ape/ape.lds" ];
checkTarget = "o//test";
enableParallelBuilding = true;

View File

@ -21,10 +21,10 @@ stdenv.mkDerivation rec {
# CMake does not set CMAKE_LIBRARY_ARCHITECTURE variable in Nix, which breaks architecture-independent library path generation
patches = [ ./fix-install-path.patch ];
buildInputs = lib.optional enableUnicodeHelp [ icu.dev ];
buildInputs = lib.optionals enableUnicodeHelp [ icu.dev ];
cmakeFlags = [ "-DCXXOPTS_BUILD_EXAMPLES=OFF" ]
++ lib.optional enableUnicodeHelp "-DCXXOPTS_USE_UNICODE_HELP=TRUE";
nativeBuildInputs = [ cmake ] ++ lib.optional enableUnicodeHelp [ pkg-config ];
nativeBuildInputs = [ cmake ] ++ lib.optionals enableUnicodeHelp [ pkg-config ];
doCheck = true;

View File

@ -39,7 +39,7 @@ stdenv.mkDerivation rec {
"--enable-shared"
] ++ lib.optional enableLdap "--with-ldap=${openldap.dev}";
installFlags = lib.optional stdenv.isDarwin [ "framedir=$(out)/Library/Frameworks/SASL2.framework" ];
installFlags = lib.optionals stdenv.isDarwin [ "framedir=$(out)/Library/Frameworks/SASL2.framework" ];
passthru.tests = {
inherit (nixosTests) parsedmarc postfix;

View File

@ -37,7 +37,7 @@ stdenv.mkDerivation rec {
++ lib.optional postgresSupport postgresql
++ lib.optional redisSupport hiredis
# drogon uses mariadb for mysql (see https://github.com/drogonframework/drogon/wiki/ENG-02-Installation#Library-Dependencies)
++ lib.optional mysqlSupport [ libmysqlclient mariadb ];
++ lib.optionals mysqlSupport [ libmysqlclient mariadb ];
patches = [
# this part of the test would normally fail because it attempts to configure a CMake project that uses find_package on itself

View File

@ -34,13 +34,13 @@ stdenv.mkDerivation rec {
++ lib.optional stdenv.isDarwin llvmPackages.openmp
;
propagatedBuildInputs = lib.optional enablePython [
propagatedBuildInputs = lib.optionals enablePython [
pythonPackages.numpy
pythonPackages.cython
pythonPackages.pytest
];
checkInputs = lib.optional enablePython [ pythonPackages.scipy pythonPackages.pytest-cov ];
checkInputs = lib.optionals enablePython [ pythonPackages.scipy pythonPackages.pytest-cov ];
preConfigure = ''
mkdir -p build/external/src

View File

@ -65,7 +65,7 @@ stdenv.mkDerivation rec {
"--with-unbound-root-key-file=${dns-root-data}/root.key"
(lib.withFeature withP11-kit "p11-kit")
(lib.enableFeature cxxBindings "cxx")
] ++ lib.optional guileBindings [
] ++ lib.optionals guileBindings [
"--enable-guile"
"--with-guile-site-dir=\${out}/share/guile/site"
"--with-guile-site-ccache-dir=\${out}/share/guile/site"

View File

@ -79,7 +79,7 @@ stdenv.mkDerivation rec {
libjpeg
tremor
libGL
] ++ lib.optional (!stdenv.isDarwin) [
] ++ lib.optionals (!stdenv.isDarwin) [
libvisual
] ++ lib.optionals stdenv.isDarwin [
pango

View File

@ -24,7 +24,7 @@ stdenv.mkDerivation rec {
patchShebangs tests
'';
autoreconfFlags = "-vfi";
autoreconfFlags = [ "-vfi" ];
configureFlags = [ "--with-ui" "--with-readline" ];

View File

@ -45,7 +45,7 @@ stdenv.mkDerivation rec {
libxslt
gobject-introspection
gi-docgen
] ++ lib.optional stdenv.hostPlatform.isDarwin [
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
fixDarwinDylibNames
];

View File

@ -31,7 +31,7 @@ stdenv.mkDerivation rec {
configureFlags = [ "--localstatedir=/var/lib" ]
# krb5's ./configure does not allow passing --enable-shared and --enable-static at the same time.
# See https://bbs.archlinux.org/viewtopic.php?pid=1576737#p1576737
++ lib.optional staticOnly [ "--enable-static" "--disable-shared" ]
++ lib.optionals staticOnly [ "--enable-static" "--disable-shared" ]
++ lib.optional stdenv.isFreeBSD ''WARN_CFLAGS=""''
++ lib.optionals (stdenv.buildPlatform != stdenv.hostPlatform)
[ "krb5_cv_attr_constructor_destructor=yes,yes"

View File

@ -17,7 +17,7 @@
assert faacSupport -> enableUnfree;
let inherit (lib) optional hasPrefix enableFeature; in
let inherit (lib) optional optionals hasPrefix enableFeature; in
/* ToDo:
- more deps, inspiration: https://packages.ubuntu.com/raring/libav-tools
@ -77,7 +77,7 @@ let
(enableFeature vaapiSupport "vaapi")
(enableFeature vdpauSupport "vdpau")
(enableFeature freetypeSupport "libfreetype")
] ++ optional (stdenv.hostPlatform != stdenv.buildPlatform) [
] ++ optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
"--cross-prefix=${stdenv.cc.targetPrefix}"
"--enable-cross-compile"
];

View File

@ -12,7 +12,7 @@ stdenv.mkDerivation rec {
patches = [ ./fix-includes.patch ];
configureFlags = [ "--disable-lynx" ]
++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform)
++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform)
[ # Can't run this test while cross-compiling
"ac_cv_func_setpgrp_void=yes"
];

View File

@ -22,7 +22,7 @@ stdenv.mkDerivation rec {
substituteInPlace Makefile --replace /usr/local $out
'';
makeFlags = lib.optional stdenv.hostPlatform.isStatic [ "DISABLE_SHARED=1"];
makeFlags = lib.optionals stdenv.hostPlatform.isStatic [ "DISABLE_SHARED=1"];
nativeBuildInputs = lib.optional stdenv.hostPlatform.isDarwin fixDarwinDylibNames;

View File

@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
patches = [ ./find-shell-lib.patch ];
patchFlags = "-p0";
patchFlags = [ "-p0" ];
postPatch = ''
substituteInPlace eatmydata.in \

View File

@ -13,7 +13,7 @@ stdenv.mkDerivation rec {
};
cmakeFlags = [ "-DWITH_PROCPS=Off" ]
++ lib.optional stdenv.isAarch64 [ "-DCURVE=ALT_BN128" "-DUSE_ASM=OFF" ];
++ lib.optionals stdenv.isAarch64 [ "-DCURVE=ALT_BN128" "-DUSE_ASM=OFF" ];
# CMake is hardcoded to always build static library which causes linker
# failure for Haskell applications depending on haskellPackages.hevm on macOS.

Some files were not shown because too many files have changed in this diff Show More