diff options
23 files changed, 65 insertions, 54 deletions
diff --git a/pkgs/applications/networking/remote/freerdp/default.nix b/pkgs/applications/networking/remote/freerdp/default.nix index d072a03c0b478..58c22375af47c 100644 --- a/pkgs/applications/networking/remote/freerdp/default.nix +++ b/pkgs/applications/networking/remote/freerdp/default.nix @@ -156,7 +156,7 @@ stdenv.mkDerivation rec { WITH_X11 = true; }; - NIX_CFLAGS_COMPILE = lib.optional stdenv.isDarwin [ + NIX_CFLAGS_COMPILE = lib.optionals stdenv.isDarwin [ "-DTARGET_OS_IPHONE=0" "-DTARGET_OS_WATCH=0" "-include AudioToolbox/AudioToolbox.h" diff --git a/pkgs/applications/networking/sniffers/kismet/default.nix b/pkgs/applications/networking/sniffers/kismet/default.nix index 1e4bb853742ea..b0feaf38ecc49 100644 --- a/pkgs/applications/networking/sniffers/kismet/default.nix +++ b/pkgs/applications/networking/sniffers/kismet/default.nix @@ -71,25 +71,27 @@ stdenv.mkDerivation rec { ] ++ lib.optionals withNetworkManager [ networkmanager glib - ] ++ lib.optional withSensors [ + ] ++ lib.optionals withSensors [ lm_sensors ]; propagatedBuildInputs = [ - ] ++ lib.optional withPython (python3.withPackages (ps: [ - ps.numpy - ps.protobuf - ps.pyserial - ps.setuptools - ps.websockets - ])); + ] ++ lib.optionals withPython [ + (python3.withPackages (ps: [ + ps.numpy + ps.protobuf + ps.pyserial + ps.setuptools + ps.websockets + ])) + ]; configureFlags = [ - ] ++ lib.optional (!withNetworkManager) [ + ] ++ lib.optionals (!withNetworkManager) [ "--disable-libnm" - ] ++ lib.optional (!withPython) [ + ] ++ lib.optionals (!withPython) [ "--disable-python-tools" - ] ++ lib.optional (!withSensors) [ + ] ++ lib.optionals (!withSensors) [ "--disable-lmsensors" ]; diff --git a/pkgs/applications/office/libreoffice/default.nix b/pkgs/applications/office/libreoffice/default.nix index e88ae758d2ad2..cc40237d1552a 100644 --- a/pkgs/applications/office/libreoffice/default.nix +++ b/pkgs/applications/office/libreoffice/default.nix @@ -119,7 +119,7 @@ let flatten flip concatMapStrings concatStringsSep getDev getLib - optional optionals optionalString; + optionals optionalString; jre' = jre17_minimal.override { modules = [ "java.base" "java.desktop" "java.logging" "java.sql" ]; @@ -195,7 +195,7 @@ in tar -xf ${srcs.translations} ''; - patches = optional (variant == "still") [ ./skip-failed-test-with-icu70.patch ./gpgme-1.18.patch ] + patches = optionals (variant == "still") [ ./skip-failed-test-with-icu70.patch ./gpgme-1.18.patch ] ; ### QT/KDE diff --git a/pkgs/applications/virtualization/docker/default.nix b/pkgs/applications/virtualization/docker/default.nix index c8d3de79f1556..fff9200285aa4 100644 --- a/pkgs/applications/virtualization/docker/default.nix +++ b/pkgs/applications/virtualization/docker/default.nix @@ -48,7 +48,7 @@ rec { }; buildInputs = oldAttrs.buildInputs - ++ lib.optional withSeccomp [ libseccomp ]; + ++ lib.optionals withSeccomp [ libseccomp ]; }); docker-tini = tini.overrideAttrs (oldAttrs: { diff --git a/pkgs/development/libraries/gtk-frdp/default.nix b/pkgs/development/libraries/gtk-frdp/default.nix index a76805d8d1fbd..acd2cae6abfce 100644 --- a/pkgs/development/libraries/gtk-frdp/default.nix +++ b/pkgs/development/libraries/gtk-frdp/default.nix @@ -44,7 +44,7 @@ stdenv.mkDerivation rec { }; }; - NIX_CFLAGS_COMPILE = lib.optional stdenv.isDarwin [ + NIX_CFLAGS_COMPILE = lib.optionals stdenv.isDarwin [ "-DTARGET_OS_IPHONE=0" "-DTARGET_OS_WATCH=0" ]; diff --git a/pkgs/development/libraries/smokegen/default.nix b/pkgs/development/libraries/smokegen/default.nix index 643ae1064db72..2a93965aeb39f 100644 --- a/pkgs/development/libraries/smokegen/default.nix +++ b/pkgs/development/libraries/smokegen/default.nix @@ -1,16 +1,18 @@ -{ pkgs, lib, ... }: +{ stdenv, lib, cmake, qt4, fetchzip }: -pkgs.stdenv.mkDerivation rec { +stdenv.mkDerivation rec { pname = "smokegen"; - version = "v4.14.3"; - src = pkgs.fetchzip { - url = "https://invent.kde.org/unmaintained/${pname}/-/archive/${version}/${pname}-${version}.tar.gz"; + version = "4.14.3"; + + src = fetchzip { + url = "https://invent.kde.org/unmaintained/${pname}/-/archive/v${version}/${pname}-v${version}.tar.gz"; hash = "sha256-finsoruPeJZLawIjNUJ25Pq54eaCByfALVraNQJPk7c="; }; - buildInputs = [ pkgs.cmake pkgs.qt4 ]; - buildPhase = '' - cmake . - ''; + + strictDeps = true; + nativeBuildInputs = [ cmake qt4 ]; + buildInputs = [ qt4 ]; + meta = with lib; { description = "A general purpose C++ parser with a plugin infrastructure"; homepage = "https://invent.kde.org/unmaintained/smokegen"; diff --git a/pkgs/development/libraries/smokeqt/default.nix b/pkgs/development/libraries/smokeqt/default.nix index 145a9f243bb35..1c427b8abb70f 100644 --- a/pkgs/development/libraries/smokeqt/default.nix +++ b/pkgs/development/libraries/smokeqt/default.nix @@ -1,16 +1,22 @@ -{ pkgs, lib, ... }: +{ stdenv, lib, cmake, qt4, smokegen, fetchzip }: -pkgs.stdenv.mkDerivation rec { +stdenv.mkDerivation rec { pname = "smokeqt"; - version = "v4.14.3"; - src = pkgs.fetchzip { - url = "https://invent.kde.org/unmaintained/${pname}/-/archive/${version}/${pname}-${version}.tar.gz"; + version = "4.14.3"; + + src = fetchzip { + url = "https://invent.kde.org/unmaintained/${pname}/-/archive/v${version}/${pname}-v${version}.tar.gz"; hash = "sha256-8FiEGF8gduVw5I/bi2wExGUWmjIjYEhWpjpXKJGBNMg="; }; + + strictDeps = true; + nativeBuildInputs = [ cmake smokegen ]; + buildInputs = [ qt4 ]; + cmakeFlags = [ "-DCMAKE_CXX_STANDARD=98" ]; - buildInputs = [ pkgs.cmake pkgs.qt4 pkgs.smokegen ]; + meta = with lib; { description = "Bindings for the Qt libraries"; homepage = "https://invent.kde.org/unmaintained/smokeqt"; diff --git a/pkgs/development/ocaml-modules/lambda-term/default.nix b/pkgs/development/ocaml-modules/lambda-term/default.nix index 239cbca429860..c073ddf39cd29 100644 --- a/pkgs/development/ocaml-modules/lambda-term/default.nix +++ b/pkgs/development/ocaml-modules/lambda-term/default.nix @@ -26,7 +26,7 @@ buildDunePackage rec { }; propagatedBuildInputs = [ zed lwt_log lwt_react mew_vi ] - ++ lib.optional (lib.versionAtLeast version "3.3.1") [ uucp logs ] ; + ++ lib.optionals (lib.versionAtLeast version "3.3.1") [ uucp logs ] ; meta = { description = "Terminal manipulation library for OCaml"; diff --git a/pkgs/development/python-modules/bundlewrap/default.nix b/pkgs/development/python-modules/bundlewrap/default.nix index e4eae0d3fe75f..75e3cd4f4b3bf 100644 --- a/pkgs/development/python-modules/bundlewrap/default.nix +++ b/pkgs/development/python-modules/bundlewrap/default.nix @@ -32,7 +32,7 @@ buildPythonPackage rec { nativeBuildInputs = [ setuptools ]; propagatedBuildInputs = [ cryptography jinja2 Mako passlib pyyaml requests tomlkit librouteros - ] ++ lib.optional (pythonOlder "3.11") [ rtoml ]; + ] ++ lib.optionals (pythonOlder "3.11") [ rtoml ]; pythonImportsCheck = [ "bundlewrap" ]; diff --git a/pkgs/development/python-modules/jupyterlab_server/default.nix b/pkgs/development/python-modules/jupyterlab_server/default.nix index c7a294eef44f8..cc709c4f47a35 100644 --- a/pkgs/development/python-modules/jupyterlab_server/default.nix +++ b/pkgs/development/python-modules/jupyterlab_server/default.nix @@ -40,7 +40,7 @@ buildPythonPackage rec { babel jupyter_server tomli - ] ++ lib.optional (pythonOlder "3.10") [ + ] ++ lib.optionals (pythonOlder "3.10") [ importlib-metadata ]; diff --git a/pkgs/development/python-modules/protobuf/default.nix b/pkgs/development/python-modules/protobuf/default.nix index 4061edfc5ae41..cd1fb4806f185 100644 --- a/pkgs/development/python-modules/protobuf/default.nix +++ b/pkgs/development/python-modules/protobuf/default.nix @@ -37,7 +37,7 @@ buildPythonPackage { buildPackages."protobuf${lib.versions.major protobuf.version}_${lib.versions.minor protobuf.version}" ]; - setupPyGlobalFlags = "--cpp_implementation"; + setupPyGlobalFlags = [ "--cpp_implementation" ]; pythonImportsCheck = [ "google.protobuf" diff --git a/pkgs/development/python-modules/pyshark/default.nix b/pkgs/development/python-modules/pyshark/default.nix index c7b469dbf7604..b33a1bd9f3854 100644 --- a/pkgs/development/python-modules/pyshark/default.nix +++ b/pkgs/development/python-modules/pyshark/default.nix @@ -35,7 +35,7 @@ buildPythonPackage rec { ]; # `stripLen` does not seem to work here - patchFlags = "-p2"; + patchFlags = [ "-p2" ]; sourceRoot = "${src.name}/src"; diff --git a/pkgs/development/python-modules/python-lsp-server/default.nix b/pkgs/development/python-modules/python-lsp-server/default.nix index 4c9cf5003cce3..62e6ce951bdea 100644 --- a/pkgs/development/python-modules/python-lsp-server/default.nix +++ b/pkgs/development/python-modules/python-lsp-server/default.nix @@ -133,7 +133,7 @@ buildPythonPackage rec { # https://github.com/python-lsp/python-lsp-server/issues/243 "test_numpy_completions" "test_workspace_loads_pycodestyle_config" - ] ++ lib.optional (stdenv.isDarwin && stdenv.isAarch64) [ + ] ++ lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ # pyqt5 is broken on aarch64-darwin "test_pyqt_completion" ]; diff --git a/pkgs/development/tools/godot/4/default.nix b/pkgs/development/tools/godot/4/default.nix index 177e2448cc31f..13ccfcc809643 100644 --- a/pkgs/development/tools/godot/4/default.nix +++ b/pkgs/development/tools/godot/4/default.nix @@ -91,7 +91,7 @@ stdenv.mkDerivation rec { enableParallelBuilding = true; - sconsFlags = "platform=linuxbsd target=editor production=true"; + sconsFlags = [ "platform=linuxbsd target=editor production=true" ]; preConfigure = '' sconsFlags+=" ${ lib.concatStringsSep " " diff --git a/pkgs/development/tools/poetry2nix/poetry2nix/overrides/default.nix b/pkgs/development/tools/poetry2nix/poetry2nix/overrides/default.nix index cff0b459d64b8..6a140ca252891 100644 --- a/pkgs/development/tools/poetry2nix/poetry2nix/overrides/default.nix +++ b/pkgs/development/tools/poetry2nix/poetry2nix/overrides/default.nix @@ -397,7 +397,7 @@ lib.composeManyExtensions [ ( old: { nativeBuildInputs = (old.nativeBuildInputs or [ ]) - ++ lib.optional (lib.versionAtLeast old.version "3.4") [ self.setuptools-rust ] + ++ lib.optionals (lib.versionAtLeast old.version "3.4") [ self.setuptools-rust ] ++ lib.optional (!self.isPyPy) pyBuildPackages.cffi ++ lib.optional (lib.versionAtLeast old.version "3.5" && !isWheel) (with pkgs.rustPlatform; [ cargoSetupHook rust.cargo rust.rustc ]); @@ -1078,9 +1078,9 @@ lib.composeManyExtensions [ buildInputs = old.buildInputs or [ ] ++ [ pkgs.which - ] ++ lib.optional enableGhostscript [ + ] ++ lib.optionals enableGhostscript [ pkgs.ghostscript - ] ++ lib.optional stdenv.isDarwin [ + ] ++ lib.optionals stdenv.isDarwin [ Cocoa ]; @@ -1097,7 +1097,7 @@ lib.composeManyExtensions [ nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ pkg-config - ] ++ lib.optional (lib.versionAtLeast super.matplotlib.version "3.5.0") [ + ] ++ lib.optionals (lib.versionAtLeast super.matplotlib.version "3.5.0") [ self.setuptools-scm self.setuptools-scm-git-archive ]; @@ -2111,8 +2111,8 @@ lib.composeManyExtensions [ if old.format != "wheel" then { nativeBuildInputs = (old.nativeBuildInputs or [ ]) ++ [ pkgs.gfortran ] ++ - lib.optional (lib.versionAtLeast super.scipy.version "1.7.0") [ self.pythran ] ++ - lib.optional (lib.versionAtLeast super.scipy.version "1.9.0") [ self.meson-python pkg-config ]; + lib.optionals (lib.versionAtLeast super.scipy.version "1.7.0") [ self.pythran ] ++ + lib.optionals (lib.versionAtLeast super.scipy.version "1.9.0") [ self.meson-python pkg-config ]; propagatedBuildInputs = (old.propagatedBuildInputs or [ ]) ++ [ self.pybind11 ]; setupPyBuildFlags = [ "--fcompiler='gnu95'" ]; enableParallelBuilding = true; diff --git a/pkgs/os-specific/linux/wireguard/default.nix b/pkgs/os-specific/linux/wireguard/default.nix index 244092441b24d..8d8342cce980b 100644 --- a/pkgs/os-specific/linux/wireguard/default.nix +++ b/pkgs/os-specific/linux/wireguard/default.nix @@ -22,7 +22,7 @@ stdenv.mkDerivation rec { buildFlags = [ "module" ]; makeFlags = [ "ARCH=${stdenv.hostPlatform.linuxArch}" - ] ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform) [ + ] ++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [ "CROSS_COMPILE=${stdenv.cc.targetPrefix}" ]; diff --git a/pkgs/servers/libreddit/default.nix b/pkgs/servers/libreddit/default.nix index 0209102eb8d9c..2aa7159a5f99d 100644 --- a/pkgs/servers/libreddit/default.nix +++ b/pkgs/servers/libreddit/default.nix @@ -19,7 +19,7 @@ rustPlatform.buildRustPackage rec { cargoSha256 = "sha256-uIr8aUDErHVUKML2l6nITSBpOxqg3h1Md0948BxvutI="; - buildInputs = lib.optional stdenv.isDarwin [ + buildInputs = lib.optionals stdenv.isDarwin [ Security ]; diff --git a/pkgs/servers/monitoring/uptime-kuma/default.nix b/pkgs/servers/monitoring/uptime-kuma/default.nix index 45d9e2c19f3aa..515e4e2edaf4c 100644 --- a/pkgs/servers/monitoring/uptime-kuma/default.nix +++ b/pkgs/servers/monitoring/uptime-kuma/default.nix @@ -1,4 +1,4 @@ -{ pkgs, lib, stdenv, fetchFromGitHub, fetchzip, substituteAll, nixosTests, iputils }: +{ pkgs, lib, stdenv, fetchFromGitHub, fetchzip, nixosTests, iputils, nodejs, makeWrapper }: let deps = import ./composition.nix { inherit pkgs; }; in @@ -28,7 +28,7 @@ stdenv.mkDerivation (finalAttrs: { --replace "/sbin/ping" "${iputils}/bin/ping" ''; - buildInputs = [ pkgs.makeWrapper ]; + nativeBuildInputs = [ makeWrapper ]; installPhase = '' mkdir -p $out/share/ @@ -41,7 +41,7 @@ stdenv.mkDerivation (finalAttrs: { ''; postFixup = '' - makeWrapper ${pkgs.nodejs}/bin/node $out/bin/uptime-kuma-server \ + makeWrapper ${nodejs}/bin/node $out/bin/uptime-kuma-server \ --add-flags $out/share/server/server.js \ --chdir $out/share/ ''; diff --git a/pkgs/servers/photoprism/default.nix b/pkgs/servers/photoprism/default.nix index 678f30c372d06..a33d3d1830042 100644 --- a/pkgs/servers/photoprism/default.nix +++ b/pkgs/servers/photoprism/default.nix @@ -42,7 +42,7 @@ in stdenv.mkDerivation { inherit pname version; - buildInputs = [ + nativeBuildInputs = [ makeWrapper ]; diff --git a/pkgs/servers/search/elasticsearch/6.x.nix b/pkgs/servers/search/elasticsearch/6.x.nix index f14138ca08971..87750f196f3fc 100644 --- a/pkgs/servers/search/elasticsearch/6.x.nix +++ b/pkgs/servers/search/elasticsearch/6.x.nix @@ -38,7 +38,7 @@ stdenv.mkDerivation (rec { nativeBuildInputs = [ makeWrapper ]; buildInputs = [ jre_headless util-linux ] - ++ optional enableUnfree [ zlib libxcrypt ]; + ++ optionals enableUnfree [ zlib libxcrypt ]; installPhase = '' mkdir -p $out diff --git a/pkgs/shells/zsh/default.nix b/pkgs/shells/zsh/default.nix index 782c2fb2bea3b..5a003b889a04a 100644 --- a/pkgs/shells/zsh/default.nix +++ b/pkgs/shells/zsh/default.nix @@ -44,7 +44,7 @@ stdenv.mkDerivation { "--enable-pcre" "--enable-zprofile=${placeholder "out"}/etc/zprofile" "--disable-site-fndir" - ] ++ lib.optional (stdenv.hostPlatform != stdenv.buildPlatform && !stdenv.hostPlatform.isStatic) [ + ] ++ lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform && !stdenv.hostPlatform.isStatic) [ # Also see: https://github.com/buildroot/buildroot/commit/2f32e668aa880c2d4a2cce6c789b7ca7ed6221ba "zsh_cv_shared_environ=yes" "zsh_cv_shared_tgetent=yes" diff --git a/pkgs/tools/misc/wwcd/default.nix b/pkgs/tools/misc/wwcd/default.nix index d18c72a25eeb6..41c66d945f40a 100644 --- a/pkgs/tools/misc/wwcd/default.nix +++ b/pkgs/tools/misc/wwcd/default.nix @@ -17,11 +17,12 @@ stdenv.mkDerivation rec { sha256 = "sha256-laf1DEtdEs7q+rtp5Y5rb+7AGsKUv5T413CFWJiURWw="; }; - autoreconfFlags = "-if"; nativeBuildInputs = [ autoreconfHook pkg-config check ]; + autoreconfFlags = [ "-if" ]; + meta = with lib; { description = "What would cron do? Read crontab entries from stdin and print time of next execution(s)"; homepage = "https://git.sr.ht/~bitfehler/wwcd"; diff --git a/pkgs/tools/wayland/waynergy/default.nix b/pkgs/tools/wayland/waynergy/default.nix index c6b10c293bfdb..fce7ac6605af9 100644 --- a/pkgs/tools/wayland/waynergy/default.nix +++ b/pkgs/tools/wayland/waynergy/default.nix @@ -25,8 +25,8 @@ stdenv.mkDerivation rec { }; depsBuildBuild = [ pkg-config ]; - buildInputs = [ libdrm wayland wayland-protocols wl-clipboard libxkbcommon cmake libressl ]; nativeBuildInputs = [ meson ninja ]; + buildInputs = [ libdrm wayland wayland-protocols wl-clipboard libxkbcommon libressl ]; postPatch = '' substituteInPlace waynergy.desktop --replace "Exec=/usr/bin/waynergy" "Exec=$out/bin/waynergy" |