treewide: replace substituteAll with replaceVars

Changed files
+444 -608
nixos
maintainers
modules
installer
cd-dvd
services
misc
taskserver
system
boot
loader
grub
pkgs
applications
editors
networking
dropbox
science
logic
by-name
ar
arma3-unix-launcher
br
brillo
bu
budgie-control-center
cb
fb
fbmenugen
fr
freenet
in
iniparser
me
meson
nu
nuget-to-json
nuget-to-nix
sp
speechd
us
usbutils
data
sgml+xml
stylesheets
xslt
docbook-xsl
desktops
gnome
extensions
lomiri
qml
lomiri-ui-toolkit
mate
caja-dropbox
development
compilers
crystal
dotnet
emscripten
go
ponyc
swift
compiler
swift-driver
swiftpm
vala
embedded
platformio
haskell-modules
interpreters
acl2
python
libraries
appstream
gssdp
gstreamer
gtk
libextractor
libpeas
libproxy
libqofono
libsbsms
libvirt
qgnomeplatform
qt-5
modules
science
math
or-tools
wayqt
webkitgtk
lisp-modules
lua-modules
ocaml-modules
carton
menhir
plotkicadsch
php-packages
couchbase
python-modules
aiohttp
anytree
attrs
bash-kernel
bokeh
cairocffi
cmdstanpy
debugpy
deltachat2
django
dot2tex
espeak-phonemizer
flit-gettext
gattlib
git-annex-adapter
glymur
gpuctypes
graphviz
hydra-core
imageio
imageio-ffmpeg
img2pdf
iniconfig
isal
k5test
kaldi-active-grammar
kornia-rs
libevdev
libusb1
mido
mss
netmap
nextcord
nocturne
notify-py
numba
nvidia-ml-py
objgraph
ocrmypdf
omegaconf
openai-whisper
opuslib
ots-python
pdfminer-six
phonemizer
pikepdf
protobuf
proton-client
protonvpn-nm-lib
pulsectl
pydot
pygame
pygame-ce
pygraphviz
pylama
pylddwrap
pyocr
pyogg
pypandoc
pyproj
pysaml2
pytesseract
python-magic
python-mapnik
python-matter-server
python-rapidjson
python3-gnutls
pythran
pyturbojpeg
pyvirtualdisplay
slixmpp
sounddevice
streamdeck
termplotlib
tinygrad
tpm2-pytss
vispy
wallet-py3k
wandb
wavefile
weasyprint
wxpython
xsdata
youseedee
yq
zlib-ng
rocm-modules
5
rocprofiler
6
rocprofiler
tcl-modules
by-name
ex
expect
tools
build-managers
bazel
bazel_5
bazel_6
bazel_7
ocaml
games
dwarf-fortress
dwarf-therapist
wrapper
kde
plasma
kinfocenter
plasma-workspace
os-specific
linux
udisks
servers
home-assistant
tools
inputmethods
misc
ckb-next
networking
networkmanager
+1 -2
nixos/maintainers/scripts/incus/incus-container-image.nix
···
# copy the config for nixos-rebuild
system.activationScripts.config =
let
-
config = pkgs.substituteAll {
-
src = ./incus-container-image-inner.nix;
+
config = pkgs.replaceVars ./incus-container-image-inner.nix {
stateVersion = lib.trivial.release;
};
in
+1 -2
nixos/maintainers/scripts/incus/incus-virtual-machine-image.nix
···
# copy the config for nixos-rebuild
system.activationScripts.config =
let
-
config = pkgs.substituteAll {
-
src = ./incus-virtual-machine-image-inner.nix;
+
config = pkgs.replaceVars ./incus-virtual-machine-image-inner.nix {
stateVersion = lib.trivial.release;
};
in
+1 -2
nixos/maintainers/scripts/lxd/lxd-container-image.nix
···
# copy the config for nixos-rebuild
system.activationScripts.config =
let
-
config = pkgs.substituteAll {
-
src = ./lxd-container-image-inner.nix;
+
config = pkgs.replaceVars ./lxd-container-image-inner.nix {
stateVersion = lib.trivial.release;
};
in
+1 -2
nixos/maintainers/scripts/lxd/lxd-virtual-machine-image.nix
···
# copy the config for nixos-rebuild
system.activationScripts.config =
let
-
config = pkgs.substituteAll {
-
src = ./lxd-virtual-machine-image-inner.nix;
+
config = pkgs.replaceVars ./lxd-virtual-machine-image-inner.nix {
stateVersion = lib.trivial.release;
};
in
+1 -5
nixos/modules/installer/cd-dvd/iso-image.nix
···
{ source = config.isoImage.splashImage;
target = "/isolinux/background.png";
}
-
{ source = pkgs.substituteAll {
-
name = "isolinux.cfg";
-
src = pkgs.writeText "isolinux.cfg-in" isolinuxCfg;
-
bootRoot = "/boot";
-
};
+
{ source = isolinuxCfg;
target = "/isolinux/isolinux.cfg";
}
{ source = "${pkgs.syslinux}/share/syslinux";
+1 -2
nixos/modules/services/misc/taskserver/default.nix
···
src = pkgs.runCommand "nixos-taskserver-src" { preferLocalBuild = true; } ''
mkdir -p "$out"
cat "${
-
pkgs.substituteAll {
-
src = ./helper-tool.py;
+
pkgs.replaceVars ./helper-tool.py {
inherit taskd certtool;
inherit (cfg)
dataDir
+4 -2
nixos/modules/system/boot/loader/grub/grub.nix
···
system.build.installBootLoader =
let
-
install-grub-pl = pkgs.substituteAll {
-
src = ./install-grub.pl;
+
install-grub-pl = pkgs.replaceVars ./install-grub.pl {
utillinux = pkgs.util-linux;
btrfsprogs = pkgs.btrfs-progs;
inherit (config.system.nixos) distroName;
+
# targets of a replacement in code
+
bootPath = null;
+
bootRoot = null;
};
perl = pkgs.perl.withPackages (p: with p; [
FileSlurp FileCopyRecursive
-1
pkgs/applications/editors/emacs/make-emacs.nix
···
./native-comp-driver-options-30.patch
)
{
-
backendPath = (
lib.concatStringsSep " " (
builtins.map (x: ''"-B${x}"'') (
+4 -3
pkgs/applications/networking/dropbox/cli.nix
···
{
lib,
stdenv,
-
substituteAll,
+
replaceVars,
autoreconfHook,
pkg-config,
fetchurl,
···
strictDeps = true;
patches = [
-
(substituteAll {
-
src = ./fix-cli-paths.patch;
+
(replaceVars ./fix-cli-paths.patch {
inherit dropboxd;
+
# patch context
+
DESKTOP_FILE_DIR = null;
})
];
+1 -1
pkgs/applications/science/logic/z3/default.nix
···
};
# replace @dir@ in the path of the given list of patches
-
fixupPatches = dir: map (patch: replaceVars patch { dir = dir; });
+
fixupPatches = dir: map (patch: replaceVars patch { inherit dir; });
in
{
z3_4_13 = common {
+2 -3
pkgs/by-name/ar/arma3-unix-launcher/package.nix
···
nlohmann_json,
qt5,
spdlog,
-
substituteAll,
+
replaceVars,
buildDayZLauncher ? false,
}:
stdenv.mkDerivation (finalAttrs: {
···
patches = [
# prevent CMake from trying to get libraries on the internet
-
(substituteAll {
-
src = ./dont_fetch_dependencies.patch;
+
(replaceVars ./dont_fetch_dependencies.patch {
argparse_src = fetchFromGitHub {
owner = "p-ranav";
repo = "argparse";
+4 -3
pkgs/by-name/br/brillo/package.nix
···
fetchFromGitLab,
go-md2man,
coreutils,
-
substituteAll,
+
replaceVars,
}:
stdenv.mkDerivation rec {
···
};
patches = [
-
(substituteAll {
-
src = ./udev-rule.patch;
+
(replaceVars ./udev-rule.patch {
inherit coreutils;
+
# patch context
+
group = null;
})
];
+2 -4
pkgs/by-name/bu/budgie-control-center/package.nix
···
lib,
stdenv,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
accountsservice,
adwaita-icon-theme,
budgie-desktop,
···
};
patches = [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
budgie_desktop = budgie-desktop;
gcm = gnome-color-manager;
inherit
cups
-
glibc
libgnomekbd
shadow
;
+1 -1
pkgs/by-name/cb/cbmc/0001-Do-not-download-sources-in-cmake.patch
···
download_project(PROJ cudd
- URL https://sourceforge.net/projects/cudd-mirror/files/cudd-3.0.0.tar.gz/download
- URL_MD5 4fdafe4924b81648b908881c81fe6c30
-
+ SOURCE_DIR @cudd.src@
+
+ SOURCE_DIR @cudd@
)
if(NOT EXISTS ${cudd_SOURCE_DIR}/Makefile)
+3 -4
pkgs/by-name/cb/cbmc/package.nix
···
flex,
makeWrapper,
perl,
-
substituteAll,
+
replaceVars,
cudd,
nix-update-script,
fetchpatch,
···
];
patches = [
-
(substituteAll {
-
src = ./0001-Do-not-download-sources-in-cmake.patch;
-
inherit cudd;
+
(replaceVars ./0001-Do-not-download-sources-in-cmake.patch {
+
cudd = cudd.src;
})
./0002-Do-not-download-sources-in-cmake.patch
# Fixes build with libc++ >= 19 due to the removal of std::char_traits<unsigned>.
+4 -3
pkgs/by-name/fb/fbmenugen/package.nix
···
gnused,
makeWrapper,
perlPackages,
-
substituteAll,
+
replaceVars,
xorg,
wrapGAppsHook3,
gitUpdater,
···
};
patches = [
-
(substituteAll {
-
src = ./0001-Fix-paths.patch;
+
(replaceVars ./0001-Fix-paths.patch {
xmessage = xorg.xmessage;
inherit fluxbox gnused;
+
# replaced in postPatch
+
fbmenugen = null;
})
];
+4 -3
pkgs/by-name/fr/freenet/package.nix
···
gradle_8,
bash,
coreutils,
-
substituteAll,
+
replaceVars,
nixosTests,
writeText,
}:
···
jdk
];
-
wrapper = substituteAll {
-
src = ./freenetWrapper;
+
wrapper = replaceVars ./freenetWrapper {
inherit
bash
coreutils
jre
seednodes
;
+
# replaced in installPhase
+
CLASSPATH = null;
};
mitmCache = gradle.fetchDeps {
-1
pkgs/by-name/in/iniparser/package.nix
···
(replaceVars ./remove-fetchcontent-usage.patch {
# Do not let cmake's fetchContent download unity
unitySrc = symlinkJoin {
-
name = "unity-with-iniparser-config";
paths = [
(fetchFromGitHub {
owner = "throwtheswitch";
+2 -3
pkgs/by-name/me/meson/package.nix
···
ninja,
pkg-config,
python3,
-
substituteAll,
+
replaceVars,
zlib,
}:
···
# are not as predictable, therefore we need to keep them in the RPATH.
# At the moment we are keeping the paths starting with /nix/store.
# https://github.com/NixOS/nixpkgs/issues/31222#issuecomment-365811634
-
(substituteAll {
-
src = ./001-fix-rpath.patch;
+
(replaceVars ./001-fix-rpath.patch {
inherit (builtins) storeDir;
})
+14 -12
pkgs/by-name/nu/nuget-to-json/package.nix
···
{
lib,
runtimeShell,
-
substituteAll,
+
replaceVarsWith,
nix,
coreutils,
jq,
···
cacert,
}:
-
substituteAll {
+
replaceVarsWith {
name = "nuget-to-json";
dir = "bin";
src = ./nuget-to-json.sh;
isExecutable = true;
-
inherit runtimeShell cacert;
-
binPath = lib.makeBinPath [
-
nix
-
coreutils
-
jq
-
xmlstarlet
-
curl
-
gnugrep
-
gawk
-
];
+
replacements = {
+
inherit runtimeShell cacert;
+
binPath = lib.makeBinPath [
+
nix
+
coreutils
+
jq
+
xmlstarlet
+
curl
+
gnugrep
+
gawk
+
];
+
};
meta = {
description = "Convert a nuget packages directory to a lockfile for buildDotnetModule";
+15 -13
pkgs/by-name/nu/nuget-to-nix/package.nix
···
{
lib,
runtimeShell,
-
substituteAll,
+
replaceVarsWith,
nix,
coreutils,
jq,
···
cacert,
}:
-
substituteAll {
+
replaceVarsWith {
name = "nuget-to-nix";
dir = "bin";
src = ./nuget-to-nix.sh;
isExecutable = true;
-
inherit runtimeShell cacert;
-
binPath = lib.makeBinPath [
-
nix
-
coreutils
-
jq
-
xmlstarlet
-
curl
-
gnugrep
-
gawk
-
nuget-to-json
-
];
+
replacements = {
+
inherit runtimeShell cacert;
+
binPath = lib.makeBinPath [
+
nix
+
coreutils
+
jq
+
xmlstarlet
+
curl
+
gnugrep
+
gawk
+
nuget-to-json
+
];
+
};
meta = {
description = "Convert a nuget packages directory to a lockfile for buildDotnetModule";
+6 -6
pkgs/by-name/sp/speechd/package.nix
···
{
stdenv,
lib,
-
substituteAll,
+
replaceVars,
pkg-config,
fetchurl,
python3Packages,
···
patches =
[
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
utillinux = util-linux;
+
# patch context
+
bindir = null;
})
]
++ lib.optionals (withEspeak && espeak.mbrolaSupport) [
# Replace FHS paths.
-
(substituteAll {
-
src = ./fix-mbrola-paths.patch;
-
inherit espeak mbrola;
+
(replaceVars ./fix-mbrola-paths.patch {
+
inherit mbrola;
})
];
+2 -3
pkgs/by-name/us/usbutils/package.nix
···
lib,
stdenv,
fetchurl,
-
substituteAll,
+
replaceVars,
fetchpatch,
meson,
ninja,
···
patches =
[
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
inherit hwdata;
})
]
+2 -3
pkgs/data/sgml+xml/stylesheets/xslt/docbook-xsl/default.nix
···
{
lib,
stdenv,
-
substituteAll,
+
replaceVars,
fetchurl,
fetchpatch,
findXMLCatalogs,
···
})
# Add legacy sourceforge.net URIs to the catalog
-
(substituteAll {
-
src = ./catalog-legacy-uris.patch;
+
(replaceVars ./catalog-legacy-uris.patch {
inherit legacySuffix suffix version;
})
]
+1 -3
pkgs/desktops/gnome/extensions/extensionOverrides.nix
···
, smartmontools
, replaceVars
, stdenvNoCC
-
, substituteAll
, touchegg
, util-linux
, vte
···
});
in {
patches = [
-
(substituteAll {
-
src = ./extensionOverridesPatches/lunarcal_at_ailin.nemui.patch;
+
(replaceVars ./extensionOverridesPatches/lunarcal_at_ailin.nemui.patch {
chinese_calendar_path = chinese-calendar;
})
];
+4 -3
pkgs/desktops/gnome/extensions/gsconnect/default.nix
···
{ stdenv
, lib
, fetchFromGitHub
-
, substituteAll
+
, replaceVars
, openssl
, gsound
, meson
···
patches = [
# Make typelibs available in the extension
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
gapplication = "${glib.bin}/bin/gapplication";
+
# Replaced in postPatch
+
typelibPath = null;
})
# Allow installing installed tests to a separate output
+2 -4
pkgs/desktops/gnome/extensions/taskwhisperer/default.nix
···
{
lib,
stdenv,
-
substituteAll,
+
replaceVars,
fetchFromGitHub,
taskwarrior2,
gettext,
···
];
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
task = "${taskwarrior2}/bin/task";
-
shell = runtimeShell;
})
];
+2 -4
pkgs/desktops/lomiri/qml/lomiri-ui-toolkit/default.nix
···
lib,
fetchFromGitLab,
gitUpdater,
-
substituteAll,
+
replaceVars,
testers,
dbus-test-runner,
dpkg,
···
patches = [
./2001-Mark-problematic-tests.patch
-
(substituteAll {
-
src = ./2002-Nixpkgs-versioned-QML-path.patch.in;
-
name = "2002-Nixpkgs-versioned-QML-path.patch";
+
(replaceVars ./2002-Nixpkgs-versioned-QML-path.patch.in {
qtVersion = lib.versions.major qtbase.version;
})
];
+4 -3
pkgs/desktops/mate/caja-dropbox/default.nix
···
lib,
stdenv,
fetchurl,
-
substituteAll,
+
replaceVars,
pkg-config,
gobject-introspection,
gdk-pixbuf,
···
};
patches = [
-
(substituteAll {
-
src = ./fix-cli-paths.patch;
+
(replaceVars ./fix-cli-paths.patch {
inherit dropboxd;
+
# patch context
+
DESKTOP_FILE_DIR = null;
})
];
+2 -3
pkgs/development/compilers/crystal/default.nix
···
, fetchurl
, fetchpatch
, lib
-
, substituteAll
+
, replaceVars
# Dependencies
, boehmgc
, coreutils
···
};
patches = [
-
(substituteAll {
-
src = ./tzdata.patch;
+
(replaceVars ./tzdata.patch {
inherit tzdata;
})
]
+2 -3
pkgs/development/compilers/dotnet/sign-apphost.nix
···
{
-
substituteAll,
+
replaceVars,
callPackage,
}:
let
sigtool = callPackage ./sigtool.nix { };
in
-
substituteAll {
-
src = ./sign-apphost.proj;
+
replaceVars ./sign-apphost.proj {
codesign = "${sigtool}/bin/codesign";
}
+6 -5
pkgs/development/compilers/dotnet/wrapper.nix
···
darwin,
icu,
lndir,
-
substituteAll,
+
replaceVars,
nugetPackageHook,
xmlstarlet,
}:
···
[
./dotnet-setup-hook.sh
]
-
++ lib.optional (type == "sdk") (substituteAll {
-
src = ./dotnet-sdk-setup-hook.sh;
-
inherit lndir xmlstarlet;
-
});
+
++ lib.optional (type == "sdk") (
+
replaceVars ./dotnet-sdk-setup-hook.sh {
+
inherit lndir xmlstarlet;
+
}
+
);
propagatedSandboxProfile = toString unwrapped.__propagatedSandboxProfile;
+2 -3
pkgs/development/compilers/emscripten/default.nix
···
llvmPackages,
symlinkJoin,
makeWrapper,
-
substituteAll,
+
replaceVars,
buildNpmPackage,
emscripten,
}:
···
];
patches = [
-
(substituteAll {
-
src = ./0001-emulate-clang-sysroot-include-logic.patch;
+
(replaceVars ./0001-emulate-clang-sysroot-include-logic.patch {
resourceDir = "${llvmEnv}/lib/clang/${lib.versions.major llvmPackages.llvm.version}/";
})
];
+4 -7
pkgs/development/compilers/go/1.22.nix
···
stdenv,
fetchurl,
tzdata,
-
substituteAll,
+
replaceVars,
iana-etc,
xcbuild,
mailcap,
···
'';
patches = [
-
(substituteAll {
-
src = ./iana-etc-1.17.patch;
+
(replaceVars ./iana-etc-1.17.patch {
iana = iana-etc;
})
# Patch the mimetype database location which is missing on NixOS.
# but also allow static binaries built with NixOS to run outside nix
-
(substituteAll {
-
src = ./mailcap-1.17.patch;
+
(replaceVars ./mailcap-1.17.patch {
inherit mailcap;
})
# prepend the nix path to the zoneinfo files but also leave the original value for static binaries
# that run outside a nix server
-
(substituteAll {
-
src = ./tzdata-1.19.patch;
+
(replaceVars ./tzdata-1.19.patch {
inherit tzdata;
})
./remove-tools-1.11.patch
+4 -7
pkgs/development/compilers/go/1.23.nix
···
stdenv,
fetchurl,
tzdata,
-
substituteAll,
+
replaceVars,
iana-etc,
xcbuild,
mailcap,
···
'';
patches = [
-
(substituteAll {
-
src = ./iana-etc-1.17.patch;
+
(replaceVars ./iana-etc-1.17.patch {
iana = iana-etc;
})
# Patch the mimetype database location which is missing on NixOS.
# but also allow static binaries built with NixOS to run outside nix
-
(substituteAll {
-
src = ./mailcap-1.17.patch;
+
(replaceVars ./mailcap-1.17.patch {
inherit mailcap;
})
# prepend the nix path to the zoneinfo files but also leave the original value for static binaries
# that run outside a nix server
-
(substituteAll {
-
src = ./tzdata-1.19.patch;
+
(replaceVars ./tzdata-1.19.patch {
inherit tzdata;
})
./remove-tools-1.11.patch
+4 -7
pkgs/development/compilers/go/1.24.nix
···
stdenv,
fetchurl,
tzdata,
-
substituteAll,
+
replaceVars,
iana-etc,
xcbuild,
mailcap,
···
'';
patches = [
-
(substituteAll {
-
src = ./iana-etc-1.17.patch;
+
(replaceVars ./iana-etc-1.17.patch {
iana = iana-etc;
})
# Patch the mimetype database location which is missing on NixOS.
# but also allow static binaries built with NixOS to run outside nix
-
(substituteAll {
-
src = ./mailcap-1.17.patch;
+
(replaceVars ./mailcap-1.17.patch {
inherit mailcap;
})
# prepend the nix path to the zoneinfo files but also leave the original value for static binaries
# that run outside a nix server
-
(substituteAll {
-
src = ./tzdata-1.19.patch;
+
(replaceVars ./tzdata-1.19.patch {
inherit tzdata;
})
./remove-tools-1.11.patch
+2 -3
pkgs/development/compilers/ponyc/default.nix
···
python3,
# Not really used for anything real, just at build time.
git,
-
substituteAll,
+
replaceVars,
which,
z3,
cctools,
···
./disable-networking-tests.patch
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
-
(substituteAll {
-
src = ./fix-darwin-build.patch;
+
(replaceVars ./fix-darwin-build.patch {
libSystem = darwin.Libsystem;
})
];
+3 -5
pkgs/development/compilers/swift/compiler/default.nix
···
, glibc
, libuuid
# Darwin-specific
-
, substituteAll
+
, replaceVars
, fixDarwinDylibNames
, xcbuild
, cctools # libtool
···
patch -p1 -d swift -i ${./patches/swift-linux-fix-libc-paths.patch}
patch -p1 -d swift -i ${./patches/swift-linux-fix-linking.patch}
patch -p1 -d swift -i ${./patches/swift-darwin-libcxx-flags.patch}
-
patch -p1 -d swift -i ${substituteAll {
-
src = ./patches/swift-darwin-plistbuddy-workaround.patch;
+
patch -p1 -d swift -i ${replaceVars ./patches/swift-darwin-plistbuddy-workaround.patch {
inherit swiftArch;
}}
-
patch -p1 -d swift -i ${substituteAll {
-
src = ./patches/swift-prevent-sdk-dirs-warning.patch;
+
patch -p1 -d swift -i ${replaceVars ./patches/swift-prevent-sdk-dirs-warning.patch {
inherit (builtins) storeDir;
}}
+2 -3
pkgs/development/compilers/swift/swift-driver/default.nix
···
XCTest,
sqlite,
ncurses,
-
substituteAll,
+
replaceVars,
}:
let
sources = callPackage ../sources.nix { };
···
hash = "sha256-eVBaKN6uzj48ZnHtwGV0k5ChKjak1tDCyE+wTdyGq2c=";
})
# Prevent a warning about SDK directories we don't have.
-
(substituteAll {
-
src = ./patches/prevent-sdk-dirs-warnings.patch;
+
(replaceVars ./patches/prevent-sdk-dirs-warnings.patch {
inherit (builtins) storeDir;
})
];
+3 -5
pkgs/development/compilers/swift/swiftpm/default.nix
···
pkg-config,
sqlite,
ncurses,
-
substituteAll,
+
replaceVars,
runCommandLocal,
makeWrapper,
DarwinTools, # sw_vers
···
./patches/disable-xctest.patch
./patches/fix-clang-cxx.patch
./patches/nix-pkgconfig-vars.patch
-
(substituteAll {
-
src = ./patches/fix-stdlib-path.patch;
+
(replaceVars ./patches/fix-stdlib-path.patch {
inherit (builtins) storeDir;
swiftLib = swift.swift.lib;
})
···
# Prevent a warning about SDK directories we don't have.
swiftpmMakeMutable swift-driver
patch -p1 -d .build/checkouts/swift-driver -i ${
-
substituteAll {
-
src = ../swift-driver/patches/prevent-sdk-dirs-warnings.patch;
+
replaceVars ../swift-driver/patches/prevent-sdk-dirs-warnings.patch {
inherit (builtins) storeDir;
}
}
+2 -3
pkgs/development/compilers/vala/default.nix
···
libintl,
libtool,
expat,
-
substituteAll,
+
replaceVars,
vala,
gobject-introspection,
}:
···
pname = "vala";
inherit version;
-
setupHook = substituteAll {
-
src = ./setup-hook.sh;
+
setupHook = replaceVars ./setup-hook.sh {
apiVersion = lib.versions.majorMinor version;
};
+3 -5
pkgs/development/embedded/platformio/core.nix
···
installShellFiles,
git,
spdx-license-list-data,
-
substituteAll,
+
replaceVars,
}:
with python3Packages;
···
];
patches = [
-
(substituteAll {
-
src = ./interpreter.patch;
+
(replaceVars ./interpreter.patch {
interpreter = (python3Packages.python.withPackages (_: propagatedBuildInputs)).interpreter;
})
-
(substituteAll {
-
src = ./use-local-spdx-license-list.patch;
+
(replaceVars ./use-local-spdx-license-list.patch {
spdx_license_list_data = spdx-license-list-data.json;
})
./missing-udev-rules-nixos.patch
+4 -2
pkgs/development/haskell-modules/configuration-nix.nix
···
# whatever graphviz is in PATH.
graphviz = overrideCabal (drv: {
patches = [
-
(pkgs.substituteAll {
-
src = ./patches/graphviz-hardcode-graphviz-store-path.patch;
+
(pkgs.replaceVars ./patches/graphviz-hardcode-graphviz-store-path.patch {
inherit (pkgs) graphviz;
+
# patch context
+
dot = null;
+
PATH = null;
})
] ++ (drv.patches or []);
}) super.graphviz;
+2 -3
pkgs/development/interpreters/acl2/default.nix
···
fetchpatch,
runCommandLocal,
makeWrapper,
-
substituteAll,
+
replaceVars,
sbcl,
bash,
which,
···
libipasir = callPackage ./libipasirglucose4 { };
patches = [
-
(substituteAll {
-
src = ./0001-Fix-some-paths-for-Nix-build.patch;
+
(replaceVars ./0001-Fix-some-paths-for-Nix-build.patch {
libipasir = "${libipasir}/lib/${libipasir.libname}";
libssl = "${lib.getLib openssl}/lib/libssl${stdenv.hostPlatform.extensions.sharedLibrary}";
libcrypto = "${lib.getLib openssl}/lib/libcrypto${stdenv.hostPlatform.extensions.sharedLibrary}";
+3 -5
pkgs/development/interpreters/python/pypy/default.nix
···
-
{ lib, stdenv, substituteAll, fetchurl
+
{ lib, stdenv, replaceVars, fetchurl
, zlibSupport ? true, zlib
, bzip2, pkg-config, libffi
, sqlite, openssl, ncurses, python, expat, tcl, tk, tclPackages, libX11
···
patches = [
./dont_fetch_vendored_deps.patch
-
(substituteAll {
-
src = ./tk_tcl_paths.patch;
+
(replaceVars ./tk_tcl_paths.patch {
inherit tk tcl;
tk_dev = tk.dev;
tcl_dev = tcl;
···
tcl_libprefix = tcl.libPrefix;
})
-
(substituteAll {
-
src = ./sqlite_paths.patch;
+
(replaceVars ./sqlite_paths.patch {
inherit (sqlite) out dev;
})
];
+2 -3
pkgs/development/libraries/appstream/default.nix
···
{ lib
, stdenv
-
, substituteAll
+
, replaceVars
, fetchFromGitHub
, meson
, mesonEmulatorHook
···
patches = [
# Fix hardcoded paths
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
libstemmer_includedir = "${lib.getDev libstemmer}/include";
})
+2 -3
pkgs/development/libraries/gssdp/tools.nix
···
{
stdenv,
lib,
-
substituteAll,
+
replaceVars,
meson,
ninja,
pkg-config,
···
patches = [
# Allow building tools separately from the library.
# This is needed to break the depenency cycle.
-
(substituteAll {
-
src = ./standalone-tools.patch;
+
(replaceVars ./standalone-tools.patch {
inherit version;
})
];
+2 -3
pkgs/development/libraries/gstreamer/bad/default.nix
···
, stdenv
, fetchurl
, fetchpatch
-
, substituteAll
+
, replaceVars
, meson
, ninja
, gettext
···
patches = [
# Add fallback paths for nvidia userspace libraries
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
inherit (addDriverRunpath) driverLink;
})
# Add support for newer AJA SDK from next GStreamer release
+2 -3
pkgs/development/libraries/gstreamer/good/default.nix
···
{ lib, stdenv
, fetchurl
-
, substituteAll
+
, replaceVars
, meson
, nasm
, ninja
···
# Reenable dynamic loading of libsoup on Darwin and use a different approach to do it.
./souploader-darwin.diff
# dlopen libsoup_3 with an absolute path
-
(substituteAll {
-
src = ./souploader.diff;
+
(replaceVars ./souploader.diff {
nixLibSoup3Path = "${lib.getLib libsoup_3}/lib";
})
];
+2 -3
pkgs/development/libraries/gtk/2.x.nix
···
pango,
perl,
pkg-config,
-
substituteAll,
+
replaceVars,
testers,
AppKit,
Cocoa,
···
}:
let
-
gtkCleanImmodulesCache = substituteAll {
-
src = ./hooks/clean-immodules-cache.sh;
+
gtkCleanImmodulesCache = replaceVars ./hooks/clean-immodules-cache.sh {
gtk_module_path = "gtk-2.0";
gtk_binary_version = "2.10.0";
};
+2 -3
pkgs/development/libraries/gtk/3.x.nix
···
{ lib
, stdenv
-
, substituteAll
+
, replaceVars
, fetchurl
, pkg-config
, gettext
···
let
-
gtkCleanImmodulesCache = substituteAll {
-
src = ./hooks/clean-immodules-cache.sh;
+
gtkCleanImmodulesCache = replaceVars ./hooks/clean-immodules-cache.sh {
gtk_module_path = "gtk-3.0";
gtk_binary_version = "3.0.0";
};
+2 -3
pkgs/development/libraries/gtk/4.x.nix
···
{ lib
, stdenv
, buildPackages
-
, substituteAll
+
, replaceVars
, fetchurl
, pkg-config
, docutils
···
let
-
gtkCleanImmodulesCache = substituteAll {
-
src = ./hooks/clean-immodules-cache.sh;
+
gtkCleanImmodulesCache = replaceVars ./hooks/clean-immodules-cache.sh {
gtk_module_path = "gtk-4.0";
gtk_binary_version = "4.0.0";
};
+2 -3
pkgs/development/libraries/libextractor/default.nix
···
stdenv,
fetchurl,
fetchpatch2,
-
substituteAll,
+
replaceVars,
libtool,
gettext,
zlib,
···
++ lib.optionals gstreamerSupport [
# Libraries cannot be wrapped so we need to hardcode the plug-in paths.
-
(substituteAll {
-
src = ./gst-hardcode-plugins.patch;
+
(replaceVars ./gst-hardcode-plugins.patch {
load_gst_plugins = lib.concatMapStrings (
plugin: ''gst_registry_scan_path(gst_registry_get(), "${lib.getLib plugin}/lib/gstreamer-1.0");''
) (gstPlugins gst_all_1);
+2 -3
pkgs/development/libraries/libpeas/2.x.nix
···
, buildPackages
, fetchurl
, pkgsCross
-
, substituteAll
+
, replaceVars
, pkg-config
, gi-docgen
, gobject-introspection
···
patches = [
# Make PyGObject’s gi library available.
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
pythonPaths = lib.concatMapStringsSep ", " (pkg: "'${pkg}/${python3.sitePackages}'") [
python3.pkgs.pygobject3
];
+2 -3
pkgs/development/libraries/libpeas/default.nix
···
stdenv,
lib,
fetchurl,
-
substituteAll,
+
replaceVars,
meson,
ninja,
pkg-config,
···
patches = [
# Make PyGObject’s gi library available.
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
pythonPaths = lib.concatMapStringsSep ", " (pkg: "'${pkg}/${python3.sitePackages}'") [
python3.pkgs.pygobject3
];
+2 -3
pkgs/development/libraries/libproxy/default.nix
···
ninja,
pkg-config,
stdenv,
-
substituteAll,
+
replaceVars,
vala,
}:
···
# Hardcode path to Settings schemas for GNOME & related desktops.
# Otherwise every app using libproxy would need to be wrapped individually.
-
(substituteAll {
-
src = ./hardcode-gsettings.patch;
+
(replaceVars ./hardcode-gsettings.patch {
gds = glib.getSchemaPath gsettings-desktop-schemas;
})
];
+2 -3
pkgs/development/libraries/libqofono/default.nix
···
{
lib,
-
substituteAll,
+
replaceVars,
mkDerivation,
fetchFromGitHub,
gitUpdater,
···
};
patches = [
-
(substituteAll {
-
src = ./0001-NixOS-provide-mobile-broadband-provider-info-path.patch;
+
(replaceVars ./0001-NixOS-provide-mobile-broadband-provider-info-path.patch {
mobileBroadbandProviderInfo = mobile-broadband-provider-info;
})
./0001-NixOS-Skip-tests-they-re-shock-full-of-hardcoded-FHS.patch
+2 -3
pkgs/development/libraries/libsbsms/common.nix
···
lib,
stdenv,
fetchurl,
-
substituteAll,
+
replaceVars,
pname,
version,
url,
···
patches = [
# Fix buidling on platforms other than x86
-
(substituteAll {
-
src = ./configure.patch;
+
(replaceVars ./configure.patch {
msse = lib.optionalString stdenv.hostPlatform.isx86_64 "-msse";
})
];
+2 -3
pkgs/development/libraries/libvirt/default.nix
···
, readline
, rpcsvc-proto
, stdenv
-
, substituteAll
+
, replaceVars
, xhtml1
, json_c
, writeScript
···
patches = [
./0001-meson-patch-in-an-install-prefix-for-building-on-nix.patch
] ++ lib.optionals enableZfs [
-
(substituteAll {
-
src = ./0002-substitute-zfs-and-zpool-commands.patch;
+
(replaceVars ./0002-substitute-zfs-and-zpool-commands.patch {
zfs = "${zfs}/bin/zfs";
zpool = "${zfs}/bin/zpool";
})
+2 -3
pkgs/development/libraries/qgnomeplatform/default.nix
···
gtk3,
qtbase,
qtwayland,
-
substituteAll,
+
replaceVars,
gsettings-desktop-schemas,
useQt6 ? false,
}:
···
patches = [
# Hardcode GSettings schema path to avoid crashes from missing schemas
-
(substituteAll {
-
src = ./hardcode-gsettings.patch;
+
(replaceVars ./hardcode-gsettings.patch {
gds_gsettings_path = glib.getSchemaPath gsettings-desktop-schemas;
})
+3 -5
pkgs/development/libraries/qt-5/modules/qttools.nix
···
lib,
qtbase,
qtdeclarative,
-
substituteAll,
+
replaceVars,
llvmPackages,
}:
···
patches = [
# fixQtBuiltinPaths overwrites builtin paths we should keep
-
(substituteAll {
-
src = ./qttools-QT_HOST_DATA-refs.patch;
+
(replaceVars ./qttools-QT_HOST_DATA-refs.patch {
qtbaseDev = lib.getDev qtbase;
})
-
(substituteAll {
-
src = ./qttools-libclang-main-header.patch;
+
(replaceVars ./qttools-libclang-main-header.patch {
libclangDev = lib.getDev llvmPackages.libclang;
})
];
+2 -3
pkgs/development/libraries/science/math/or-tools/default.nix
···
eigen,
ensureNewerSourcesForZipFilesHook,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
glpk,
lib,
pkg-config,
···
};
patches = [
-
(substituteAll {
-
src = ./offline.patch;
+
(replaceVars ./offline.patch {
pybind11_protobuf = "../../pybind11_protobuf";
})
];
+2 -3
pkgs/development/libraries/wayqt/default.nix
···
stdenv,
lib,
fetchFromGitLab,
-
substituteAll,
+
replaceVars,
meson,
pkg-config,
qttools,
···
patches = [
# qmake get qtbase's path, but wayqt need qtwayland
-
(substituteAll {
-
src = ./fix-qtwayland-header-path.diff;
+
(replaceVars ./fix-qtwayland-header-path.diff {
qtWaylandPath = "${qtwayland}/include";
})
];
+2 -3
pkgs/development/libraries/webkitgtk/default.nix
···
libbacktrace,
systemd,
xdg-dbus-proxy,
-
substituteAll,
+
replaceVars,
glib,
unifdef,
addDriverRunpath,
···
};
patches = lib.optionals clangStdenv.hostPlatform.isLinux [
-
(substituteAll {
-
src = ./fix-bubblewrap-paths.patch;
+
(replaceVars ./fix-bubblewrap-paths.patch {
inherit (builtins) storeDir;
inherit (addDriverRunpath) driverLink;
})
+2 -3
pkgs/development/lisp-modules/nix-cl.nix
···
;
inherit (pkgs)
-
substituteAll
+
replaceVars
;
# Stolen from python-packages.nix
···
;
};
-
buildScript = substituteAll {
-
src = ./builder.lisp;
+
buildScript = replaceVars ./builder.lisp {
asdf = "${asdfFasl}/asdf.${faslExt}";
};
+2 -3
pkgs/development/lua-modules/nfd/default.nix
···
lua,
pkg-config,
lib,
-
substituteAll,
+
replaceVars,
zenity,
AppKit,
}:
···
# use zenity because default gtk impl just crashes
patches = [
-
(substituteAll {
-
src = ./zenity.patch;
+
(replaceVars ./zenity.patch {
inherit zenity;
})
];
+2 -3
pkgs/development/ocaml-modules/carton/default.nix
···
cmdliner,
hxd,
getconf,
-
substituteAll,
+
replaceVars,
}:
buildDunePackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./carton-find-getconf.patch;
+
(replaceVars ./carton-find-getconf.patch {
getconf = "${getconf}";
})
];
+2 -3
pkgs/development/ocaml-modules/menhir/default.nix
···
{
buildDunePackage,
-
substituteAll,
+
replaceVars,
ocaml,
menhirLib,
menhirSdk,
···
];
patches = [
-
(substituteAll {
-
src = ./menhir-suggest-menhirLib.patch;
+
(replaceVars ./menhir-suggest-menhirLib.patch {
libdir = "${menhirLib}/lib/ocaml/${ocaml.version}/site-lib/menhirLib";
})
];
+2 -3
pkgs/development/ocaml-modules/plotkicadsch/default.nix
···
{
lib,
buildDunePackage,
-
substituteAll,
+
replaceVars,
base64,
cmdliner,
digestif,
···
minimalOCamlVersion = "4.09";
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
inherit coreutils imagemagick;
})
];
+2 -3
pkgs/development/php-packages/couchbase/default.nix
···
fetchFromGitHub,
libcouchbase,
zlib,
-
substituteAll,
+
replaceVars,
php,
}:
let
···
];
patches = [
-
(substituteAll {
-
src = ./libcouchbase.patch;
+
(replaceVars ./libcouchbase.patch {
inherit libcouchbase;
})
];
+2 -3
pkgs/development/python-modules/aiohttp/default.nix
···
buildPythonPackage,
fetchFromGitHub,
fetchpatch2,
-
substituteAll,
+
replaceVars,
isPy310,
isPyPy,
···
};
patches = [
-
(substituteAll {
-
src = ./unvendor-llhttp.patch;
+
(replaceVars ./unvendor-llhttp.patch {
llhttpDev = lib.getDev llhttp;
llhttpLib = lib.getLib llhttp;
})
+2 -3
pkgs/development/python-modules/anytree/default.nix
···
pytest7CheckHook,
pythonOlder,
six,
-
substituteAll,
+
replaceVars,
withGraphviz ? true,
}:
···
};
patches = lib.optionals withGraphviz [
-
(substituteAll {
-
src = ./graphviz.patch;
+
(replaceVars ./graphviz.patch {
inherit graphviz;
})
];
+2 -3
pkgs/development/python-modules/attrs/default.nix
···
buildPythonPackage,
fetchPypi,
pythonOlder,
-
substituteAll,
+
replaceVars,
hatchling,
}:
···
};
patches = [
-
(substituteAll {
+
(replaceVars ./remove-hatch-plugins.patch {
# hatch-vcs and hatch-fancy-pypi-readme depend on pytest, which depends on attrs
-
src = ./remove-hatch-plugins.patch;
inherit version;
})
];
+2 -3
pkgs/development/python-modules/bash-kernel/default.nix
···
python,
pexpect,
bashInteractive,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./bash-path.patch;
+
(replaceVars ./bash-path.patch {
bash = lib.getExe bashInteractive;
})
];
+2 -3
pkgs/development/python-modules/bokeh/default.nix
···
fetchPypi,
fetchFromGitHub,
pythonOlder,
-
substituteAll,
+
replaceVars,
colorama,
contourpy,
jinja2,
···
};
patches = [
-
(substituteAll {
-
src = ./hardcode-nodejs-npmjs-paths.patch;
+
(replaceVars ./hardcode-nodejs-npmjs-paths.patch {
node_bin = "${nodejs}/bin/node";
npm_bin = "${nodejs}/bin/npm";
})
+2 -3
pkgs/development/python-modules/cairocffi/default.nix
···
pythonOlder,
fetchPypi,
lib,
-
substituteAll,
+
replaceVars,
pikepdf,
pytestCheckHook,
cairo,
···
patches = [
# OSError: dlopen() failed to load a library: gdk-pixbuf-2.0 / gdk-pixbuf-2.0-0
-
(substituteAll {
-
src = ./dlopen-paths.patch;
+
(replaceVars ./dlopen-paths.patch {
ext = stdenv.hostPlatform.extensions.sharedLibrary;
cairo = cairo.out;
glib = glib.out;
+2 -3
pkgs/development/python-modules/cmdstanpy/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
cmdstan,
setuptools,
pandas,
···
};
patches = [
-
(substituteAll {
-
src = ./use-nix-cmdstan-path.patch;
+
(replaceVars ./use-nix-cmdstan-path.patch {
cmdstan = "${cmdstan}/opt/cmdstan";
})
];
+4 -7
pkgs/development/python-modules/debugpy/default.nix
···
pythonOlder,
pythonAtLeast,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
gdb,
lldb,
pytestCheckHook,
···
patches =
[
# Use nixpkgs version instead of versioneer
-
(substituteAll {
-
src = ./hardcode-version.patch;
+
(replaceVars ./hardcode-version.patch {
inherit version;
})
···
]
++ lib.optionals stdenv.hostPlatform.isLinux [
# Hard code GDB path (used to attach to process)
-
(substituteAll {
-
src = ./hardcode-gdb.patch;
+
(replaceVars ./hardcode-gdb.patch {
inherit gdb;
})
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# Hard code LLDB path (used to attach to process)
-
(substituteAll {
-
src = ./hardcode-lldb.patch;
+
(replaceVars ./hardcode-lldb.patch {
inherit lldb;
})
];
+2 -3
pkgs/development/python-modules/deltachat2/default.nix
···
buildPythonPackage,
deltachat-rpc-server,
setuptools-scm,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
deltachatrpcserver = lib.getExe deltachat-rpc-server;
})
];
+9 -9
pkgs/development/python-modules/django/3.nix
···
stdenv,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
geos_3_9,
gdal,
asgiref,
···
patches =
[
-
(substituteAll {
-
src = ./django_3_set_zoneinfo_dir.patch;
+
(replaceVars ./django_3_set_zoneinfo_dir.patch {
zoneinfo = tzdata + "/share/zoneinfo";
})
]
-
++ lib.optional withGdal (substituteAll {
-
src = ./django_3_set_geos_gdal_lib.patch;
-
inherit geos_3_9;
-
inherit gdal;
-
extension = stdenv.hostPlatform.extensions.sharedLibrary;
-
});
+
++ lib.optional withGdal (
+
replaceVars ./django_3_set_geos_gdal_lib.patch {
+
inherit geos_3_9;
+
inherit gdal;
+
extension = stdenv.hostPlatform.extensions.sharedLibrary;
+
}
+
);
propagatedBuildInputs = [
asgiref
+3 -5
pkgs/development/python-modules/django/4.nix
···
fetchpatch,
pythonAtLeast,
pythonOlder,
-
substituteAll,
+
replaceVars,
# build
setuptools,
···
patches =
[
-
(substituteAll {
-
src = ./django_4_set_zoneinfo_dir.patch;
+
(replaceVars ./django_4_set_zoneinfo_dir.patch {
zoneinfo = tzdata + "/share/zoneinfo";
})
# make sure the tests don't remove packages from our pythonpath
···
})
]
++ lib.optionals withGdal [
-
(substituteAll {
-
src = ./django_4_set_geos_gdal_lib.patch;
+
(replaceVars ./django_4_set_geos_gdal_lib.patch {
geos = geos;
gdal = gdal;
extension = stdenv.hostPlatform.extensions.sharedLibrary;
+3 -5
pkgs/development/python-modules/django/5.nix
···
fetchFromGitHub,
fetchpatch,
pythonOlder,
-
substituteAll,
+
replaceVars,
# build-system
setuptools,
···
patches =
[
-
(substituteAll {
-
src = ./django_5_set_zoneinfo_dir.patch;
+
(replaceVars ./django_5_set_zoneinfo_dir.patch {
zoneinfo = tzdata + "/share/zoneinfo";
})
# prevent tests from messing with our pythonpath
···
})
]
++ lib.optionals withGdal [
-
(substituteAll {
-
src = ./django_5_set_geos_gdal_lib.patch;
+
(replaceVars ./django_5_set_geos_gdal_lib.patch {
geos = geos;
gdal = gdal;
extension = stdenv.hostPlatform.extensions.sharedLibrary;
+2 -3
pkgs/development/python-modules/dot2tex/default.nix
···
lib,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
pyparsing,
graphviz,
pytestCheckHook,
···
};
patches = [
-
(substituteAll {
-
src = ./path.patch;
+
(replaceVars ./path.patch {
inherit graphviz;
})
./test.patch # https://github.com/kjellmf/dot2tex/issues/5
+2 -3
pkgs/development/python-modules/espeak-phonemizer/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
espeak-ng,
pytestCheckHook,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./cdll.patch;
+
(replaceVars ./cdll.patch {
libespeak_ng = "${lib.getLib espeak-ng}/lib/libespeak-ng.so";
})
];
+2 -3
pkgs/development/python-modules/flit-gettext/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
# build-system
flit-scm,
···
};
patches = [
-
(substituteAll {
-
src = ./msgfmt-path.patch;
+
(replaceVars ./msgfmt-path.patch {
msgfmt = lib.getExe' gettext "msgfmt";
})
];
+4 -3
pkgs/development/python-modules/gattlib/default.nix
···
buildPythonPackage,
fetchFromGitHub,
fetchpatch,
-
substituteAll,
+
replaceVars,
+
+
# build
pkg-config,
glibc,
python,
···
url = "https://github.com/oscaracena/pygattlib/commit/73a73b71cfc139e1e0a08816fb976ff330c77ea5.patch";
hash = "sha256-/Y/CZNdN/jcxWroqRfdCH2rPUxZUbug668MIAow0scs=";
})
-
(substituteAll {
-
src = ./setup.patch;
+
(replaceVars ./setup.patch {
boost_version =
let
pythonVersion = with lib.versions; "${major python.version}${minor python.version}";
+2 -3
pkgs/development/python-modules/git-annex-adapter/default.nix
···
pytestCheckHook,
pythonOlder,
setuptools,
-
substituteAll,
+
replaceVars,
util-linux,
}:
···
url = "https://github.com/alpernebbi/git-annex-adapter/commit/d0d8905965a3659ce95cbd8f8b1e8598f0faf76b.patch";
hash = "sha256-UcRTKzD3sbXGIuxj4JzZDnvjTYyWVkfeWgKiZ1rAlus=";
})
-
(substituteAll {
-
src = ./git-annex-path.patch;
+
(replaceVars ./git-annex-path.patch {
gitAnnex = "${git-annex}/bin/git-annex";
})
];
+2 -3
pkgs/development/python-modules/glymur/default.nix
···
pythonOlder,
scikit-image,
setuptools,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
url = "https://github.com/quintusdias/glymur/commit/89b159299035ebb05776c3b90278f410ca6dba64.patch";
hash = "sha256-C/Q5WZmW5YtN3U8fxKljfqwKHtFLfR2LQ69Tj8SuIWg=";
})
-
(substituteAll {
-
src = ./set-lib-paths.patch;
+
(replaceVars ./set-lib-paths.patch {
openjp2_lib = "${lib.getLib openjpeg}/lib/libopenjp2${stdenv.hostPlatform.extensions.sharedLibrary}";
tiff_lib = "${lib.getLib libtiff}/lib/libtiff${stdenv.hostPlatform.extensions.sharedLibrary}";
})
+2 -3
pkgs/development/python-modules/gpuctypes/default.nix
···
config,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
addDriverRunpath,
cudaSupport ? config.cudaSupport,
rocmSupport ? config.rocmSupport,
···
};
patches = [
-
(substituteAll {
-
src = ./0001-fix-dlopen-cuda.patch;
+
(replaceVars ./0001-fix-dlopen-cuda.patch {
inherit (addDriverRunpath) driverLink;
libnvrtc =
if cudaSupport then
+2 -3
pkgs/development/python-modules/graphviz/default.nix
···
buildPythonPackage,
pythonOlder,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
graphviz-nox,
xdg-utils,
makeFontsConf,
···
};
patches = [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
graphviz = graphviz-nox;
xdgutils = xdg-utils;
})
+2 -3
pkgs/development/python-modules/hydra-core/default.nix
···
packaging,
pytestCheckHook,
pythonOlder,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./antlr4.patch;
+
(replaceVars ./antlr4.patch {
antlr_jar = "${antlr4.out}/share/java/antlr-${antlr4.version}-complete.jar";
})
# https://github.com/facebookresearch/hydra/pull/2731
+2 -3
pkgs/development/python-modules/imageio-ffmpeg/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
ffmpeg,
# build-system
···
};
patches = [
-
(substituteAll {
-
src = ./ffmpeg-path.patch;
+
(replaceVars ./ffmpeg-path.patch {
ffmpeg = lib.getExe ffmpeg;
})
];
+2 -3
pkgs/development/python-modules/imageio/default.nix
···
buildPythonPackage,
fetchFromGitHub,
isPyPy,
-
substituteAll,
+
replaceVars,
# build-system
setuptools,
···
};
patches = lib.optionals (!stdenv.hostPlatform.isDarwin) [
-
(substituteAll {
-
src = ./libgl-path.patch;
+
(replaceVars ./libgl-path.patch {
libgl = "${libGL.out}/lib/libGL${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -3
pkgs/development/python-modules/img2pdf/default.nix
···
buildPythonPackage,
isPy27,
fetchFromGitea,
-
substituteAll,
+
replaceVars,
fetchpatch,
colord,
setuptools,
···
};
patches = [
-
(substituteAll {
-
src = ./default-icc-profile.patch;
+
(replaceVars ./default-icc-profile.patch {
srgbProfile =
if stdenv.hostPlatform.isDarwin then
"/System/Library/ColorSync/Profiles/sRGB Profile.icc"
+2 -3
pkgs/development/python-modules/iniconfig/default.nix
···
{
lib,
buildPythonPackage,
-
substituteAll,
+
replaceVars,
fetchPypi,
hatchling,
}:
···
patches = [
# Cannot use hatch-vcs, due to an inifinite recursion
-
(substituteAll {
-
src = ./version.patch;
+
(replaceVars ./version.patch {
inherit version;
})
];
+2 -3
pkgs/development/python-modules/isal/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
# build-system
setuptools,
···
};
patches = [
-
(substituteAll {
-
src = ./version.patch;
+
(replaceVars ./version.patch {
inherit version;
})
];
+2 -3
pkgs/development/python-modules/k5test/default.nix
···
krb5-c,
pythonOlder,
setuptools,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
inherit findutils;
krb5 = krb5-c;
# krb5-config is in dev output
+2 -3
pkgs/development/python-modules/kaldi-active-grammar/default.nix
···
numpy,
cffi,
openfst,
-
substituteAll,
+
replaceVars,
callPackage,
}:
···
# Uses the dependencies' binaries from $PATH instead of a specific directory
./0002-exec-path.patch
# Makes it dynamically link to the correct Kaldi library
-
(substituteAll {
-
src = ./0003-ffi-path.patch;
+
(replaceVars ./0003-ffi-path.patch {
kaldiFork = "${kaldi}/lib";
})
];
+2 -3
pkgs/development/python-modules/kornia-rs/default.nix
···
rustPlatform,
cmake,
nasm,
-
substituteAll,
+
replaceVars,
libiconv,
}:
···
# The path dependency doesn't vendor the dependencies correctly, so get kornia-rs from crates instead.
patches = [
-
(substituteAll {
-
src = ./kornia-rs-from-crates.patch;
+
(replaceVars ./kornia-rs-from-crates.patch {
inherit version;
})
];
+2 -3
pkgs/development/python-modules/libevdev/default.nix
···
buildPythonPackage,
isPy27,
fetchPypi,
-
substituteAll,
+
replaceVars,
pkgs,
pytestCheckHook,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
libevdev = lib.getLib pkgs.libevdev;
})
];
+2 -3
pkgs/development/python-modules/libusb1/default.nix
···
stdenv,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
setuptools,
libusb1,
pytestCheckHook,
···
};
patches = [
-
(substituteAll {
-
src = ./ctypes.patch;
+
(replaceVars ./ctypes.patch {
libusb = "${lib.getLib libusb1}/lib/libusb-1.0${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -3
pkgs/development/python-modules/mido/default.nix
···
lib,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
# build-system
setuptools,
···
};
patches = [
-
(substituteAll {
-
src = ./libportmidi-cdll.patch;
+
(replaceVars ./libportmidi-cdll.patch {
libportmidi = "${portmidi.out}/lib/libportmidi${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -3
pkgs/development/python-modules/mss/default.nix
···
fetchPypi,
pythonOlder,
stdenv,
-
substituteAll,
+
replaceVars,
# build-system
hatchling,
···
};
patches = lib.optionals stdenv.hostPlatform.isLinux [
-
(substituteAll {
-
src = ./linux-paths.patch;
+
(replaceVars ./linux-paths.patch {
x11 = "${xorg.libX11}/lib/libX11.so";
xfixes = "${xorg.libXfixes}/lib/libXfixes.so";
xrandr = "${xorg.libXrandr}/lib/libXrandr.so";
+2 -3
pkgs/development/python-modules/netmap/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
nmap,
python,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./nmap-path.patch;
+
(replaceVars ./nmap-path.patch {
nmap = "${lib.getBin nmap}/bin/nmap";
})
];
+2 -3
pkgs/development/python-modules/nextcord/default.nix
···
pythonAtLeast,
pythonOlder,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
ffmpeg,
libopus,
aiohttp,
···
};
patches = [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
ffmpeg = "${ffmpeg}/bin/ffmpeg";
libopus = "${libopus}/lib/libopus${stdenv.hostPlatform.extensions.sharedLibrary}";
})
+2 -3
pkgs/development/python-modules/nocturne/default.nix
···
pybind11,
pyvirtualdisplay,
sfml,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
'';
patches = [
-
(substituteAll {
-
src = ./dependencies.patch;
+
(replaceVars ./dependencies.patch {
gtest_src = gtest.src;
})
];
+3 -5
pkgs/development/python-modules/notify-py/default.nix
···
buildPythonPackage,
pythonOlder,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
alsa-utils,
libnotify,
which,
···
patches =
lib.optionals stdenv.hostPlatform.isLinux [
# hardcode paths to aplay and notify-send
-
(substituteAll {
-
src = ./linux-paths.patch;
+
(replaceVars ./linux-paths.patch {
aplay = "${alsa-utils}/bin/aplay";
notifysend = "${libnotify}/bin/notify-send";
})
]
++ lib.optionals stdenv.hostPlatform.isDarwin [
# hardcode path to which
-
(substituteAll {
-
src = ./darwin-paths.patch;
+
(replaceVars ./darwin-paths.patch {
which = "${which}/bin/which";
})
];
+2 -3
pkgs/development/python-modules/numba/default.nix
···
numpy_1,
llvmlite,
libcxx,
-
substituteAll,
+
replaceVars,
writers,
numba,
pytestCheckHook,
···
];
patches = lib.optionals cudaSupport [
-
(substituteAll {
-
src = ./cuda_path.patch;
+
(replaceVars ./cuda_path.patch {
cuda_toolkit_path = cudatoolkit;
cuda_toolkit_lib_path = lib.getLib cudatoolkit;
})
+2 -3
pkgs/development/python-modules/nvidia-ml-py/default.nix
···
lib,
fetchPypi,
buildPythonPackage,
-
substituteAll,
+
replaceVars,
addDriverRunpath,
setuptools,
cudaPackages,
···
};
patches = [
-
(substituteAll {
-
src = ./0001-locate-libnvidia-ml.so.1-on-NixOS.patch;
+
(replaceVars ./0001-locate-libnvidia-ml.so.1-on-NixOS.patch {
inherit (addDriverRunpath) driverLink;
})
];
+2 -3
pkgs/development/python-modules/objgraph/default.nix
···
isPyPy,
python,
pythonOlder,
-
substituteAll,
+
replaceVars,
setuptools,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./hardcode-graphviz-path.patch;
+
(replaceVars ./hardcode-graphviz-path.patch {
graphviz = graphvizPkgs;
})
];
+2 -3
pkgs/development/python-modules/ocrmypdf/default.nix
···
pythonOlder,
rich,
reportlab,
-
substituteAll,
+
replaceVars,
tesseract,
unpaper,
installShellFiles,
···
patches = [
./use-pillow-heif.patch
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
gs = lib.getExe ghostscript_headless;
jbig2 = lib.getExe jbig2enc;
pngquant = lib.getExe pngquant;
+2 -3
pkgs/development/python-modules/omegaconf/default.nix
···
pythonAtLeast,
pythonOlder,
pyyaml,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./antlr4.patch;
+
(replaceVars ./antlr4.patch {
antlr_jar = "${antlr4.out}/share/java/antlr-${antlr4.version}-complete.jar";
})
+2 -3
pkgs/development/python-modules/openai-whisper/default.nix
···
stdenv,
fetchFromGitHub,
buildPythonPackage,
-
substituteAll,
+
replaceVars,
# build-system
setuptools,
···
};
patches = [
-
(substituteAll {
-
src = ./ffmpeg-path.patch;
+
(replaceVars ./ffmpeg-path.patch {
ffmpeg = ffmpeg-headless;
})
];
+2 -3
pkgs/development/python-modules/opuslib/default.nix
···
pytestCheckHook,
lib,
stdenv,
-
substituteAll,
+
replaceVars,
setuptools,
}:
···
url = "https://github.com/orion-labs/opuslib/commit/87a214fc98c1dcae38035e99fe8e279a160c4a52.patch";
hash = "sha256-UoOafyTFvWLY7ErtBhkXTZSgbMZFrg5DGxjbhqEI7wo=";
})
-
(substituteAll {
-
src = ./opuslib-paths.patch;
+
(replaceVars ./opuslib-paths.patch {
opusLibPath = "${libopus}/lib/libopus${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -3
pkgs/development/python-modules/ots-python/default.nix
···
lib,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
opentype-sanitizer,
setuptools-scm,
pytestCheckHook,
···
# Invoke ots-sanitize from the opentype-sanitizer package instead of
# downloading precompiled binaries from the internet.
# (nixpkgs-specific, not upstreamable)
-
(substituteAll {
-
src = ./0001-use-packaged-ots.patch;
+
(replaceVars ./0001-use-packaged-ots.patch {
ots_sanitize = "${opentype-sanitizer}/bin/ots-sanitize";
})
];
+2 -3
pkgs/development/python-modules/pdfminer-six/default.nix
···
pythonOlder,
pytestCheckHook,
setuptools,
-
substituteAll,
+
replaceVars,
ocrmypdf,
}:
···
excludes = [ "CHANGELOG.md" ];
hash = "sha256-fsSXvN92MVtNFpAst0ctvGrbxVvoe4Nyz4wMZqJ1aw8=";
})
-
(substituteAll {
-
src = ./disable-setuptools-git-versioning.patch;
+
(replaceVars ./disable-setuptools-git-versioning.patch {
inherit version;
})
];
+2 -3
pkgs/development/python-modules/phonemizer/default.nix
···
{
lib,
stdenv,
-
substituteAll,
+
replaceVars,
buildPythonPackage,
fetchPypi,
joblib,
···
};
patches = [
-
(substituteAll {
-
src = ./backend-paths.patch;
+
(replaceVars ./backend-paths.patch {
libespeak = "${lib.getLib espeak-ng}/lib/libespeak-ng${stdenv.hostPlatform.extensions.sharedLibrary}";
# FIXME package festival
})
+2 -3
pkgs/development/python-modules/pikepdf/default.nix
···
python-xmp-toolkit,
qpdf,
setuptools,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
jbig2dec = lib.getExe' jbig2dec "jbig2dec";
mutool = lib.getExe' mupdf-headless "mutool";
})
+2 -3
pkgs/development/python-modules/protobuf/4.nix
···
protobuf,
pytestCheckHook,
pythonAtLeast,
-
substituteAll,
+
replaceVars,
tzdata,
}:
···
patches =
lib.optionals (lib.versionAtLeast protobuf.version "22") [
# Replace the vendored abseil-cpp with nixpkgs'
-
(substituteAll {
-
src = ./use-nixpkgs-abseil-cpp.patch;
+
(replaceVars ./use-nixpkgs-abseil-cpp.patch {
abseil_cpp_include_path = "${lib.getDev protobuf.abseil-cpp}/include";
})
]
+2 -3
pkgs/development/python-modules/proton-client/default.nix
···
buildPythonPackage,
fetchFromGitHub,
pythonOlder,
-
substituteAll,
+
replaceVars,
bcrypt,
pyopenssl,
python-gnupg,
···
patches = [
# Patches library by fixing the openssl path
-
(substituteAll {
-
src = ./0001-OpenSSL-path-fix.patch;
+
(replaceVars ./0001-OpenSSL-path-fix.patch {
openssl = openssl.out;
ext = stdenv.hostPlatform.extensions.sharedLibrary;
})
+2 -3
pkgs/development/python-modules/protonvpn-nm-lib/default.nix
···
buildPythonPackage,
fetchFromGitHub,
pythonOlder,
-
substituteAll,
+
replaceVars,
dbus-python,
distro,
jinja2,
···
];
patches = [
-
(substituteAll {
-
src = ./0001-Patching-GIRepository.patch;
+
(replaceVars ./0001-Patching-GIRepository.patch {
networkmanager_path = "${networkmanager}/lib/girepository-1.0";
})
];
+2 -3
pkgs/development/python-modules/pulsectl/default.nix
···
fetchPypi,
libpulseaudio,
glibc,
-
substituteAll,
+
replaceVars,
stdenv,
pulseaudio,
unittestCheckHook,
···
patches = [
# substitute library paths for libpulse and librt
-
(substituteAll {
-
src = ./library-paths.patch;
+
(replaceVars ./library-paths.patch {
libpulse = "${libpulseaudio.out}/lib/libpulse${stdenv.hostPlatform.extensions.sharedLibrary}";
librt = "${glibc.out}/lib/librt${stdenv.hostPlatform.extensions.sharedLibrary}";
})
+2 -3
pkgs/development/python-modules/pydot/default.nix
···
buildPythonPackage,
fetchPypi,
setuptools,
-
substituteAll,
+
replaceVars,
graphviz,
pytestCheckHook,
chardet,
···
];
patches = [
-
(substituteAll {
-
src = ./hardcode-graphviz-path.patch;
+
(replaceVars ./hardcode-graphviz-path.patch {
inherit graphviz;
})
];
+2 -3
pkgs/development/python-modules/pygame-ce/default.nix
···
{
stdenv,
lib,
-
substituteAll,
+
replaceVars,
fetchFromGitHub,
buildPythonPackage,
pythonOlder,
···
};
patches = [
-
(substituteAll {
-
src = ./fix-dependency-finding.patch;
+
(replaceVars ./fix-dependency-finding.patch {
buildinputs_include = builtins.toJSON (
builtins.concatMap (dep: [
"${lib.getDev dep}/"
+2 -3
pkgs/development/python-modules/pygame/default.nix
···
stdenv,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
fontconfig,
python,
···
patches = [
# Patch pygame's dependency resolution to let it find build inputs
-
(substituteAll {
-
src = ./fix-dependency-finding.patch;
+
(replaceVars ./fix-dependency-finding.patch {
buildinputs_include = builtins.toJSON (
builtins.concatMap (dep: [
"${lib.getDev dep}/"
+2 -3
pkgs/development/python-modules/pygraphviz/default.nix
···
buildPythonPackage,
pythonOlder,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
graphviz,
coreutils,
pkg-config,
···
patches = [
# pygraphviz depends on graphviz executables and wc being in PATH
-
(substituteAll {
-
src = ./path.patch;
+
(replaceVars ./path.patch {
path = lib.makeBinPath [
graphviz
coreutils
+2 -3
pkgs/development/python-modules/pylama/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
git,
eradicate,
mccabe,
···
};
patches = [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
git = "${lib.getBin git}/bin/git";
})
];
+2 -3
pkgs/development/python-modules/pylddwrap/default.nix
···
icontract,
pytestCheckHook,
pythonOlder,
-
substituteAll,
+
replaceVars,
typing-extensions,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./replace_env_with_placeholder.patch;
+
(replaceVars ./replace_env_with_placeholder.patch {
ldd_bin = "${stdenv.cc.bintools.libc_bin}/bin/ldd";
})
];
+12 -10
pkgs/development/python-modules/pyocr/default.nix
···
tesseract,
cuneiform,
isPy3k,
-
substituteAll,
+
replaceVars,
pytestCheckHook,
setuptools,
setuptools-scm,
···
patches =
[ ]
-
++ (lib.optional withTesseractSupport (substituteAll {
-
src = ./paths-tesseract.patch;
-
inherit tesseract;
-
tesseractLibraryLocation = "${tesseract}/lib/libtesseract${stdenv.hostPlatform.extensions.sharedLibrary}";
-
}))
-
++ (lib.optional stdenv.hostPlatform.isLinux (substituteAll {
-
src = ./paths-cuneiform.patch;
-
inherit cuneiform;
-
}));
+
++ (lib.optional withTesseractSupport (
+
replaceVars ./paths-tesseract.patch {
+
inherit tesseract;
+
tesseractLibraryLocation = "${tesseract}/lib/libtesseract${stdenv.hostPlatform.extensions.sharedLibrary}";
+
}
+
))
+
++ (lib.optional stdenv.hostPlatform.isLinux (
+
replaceVars ./paths-cuneiform.patch {
+
inherit cuneiform;
+
}
+
));
propagatedBuildInputs = [ pillow ];
+2 -3
pkgs/development/python-modules/pyogg/default.nix
···
libogg,
libopus,
opusfile,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
"--binary"
];
patches = [
-
(substituteAll {
-
src = ./pyogg-paths.patch;
+
(replaceVars ./pyogg-paths.patch {
flacLibPath = "${flac.out}/lib/libFLAC${stdenv.hostPlatform.extensions.sharedLibrary}";
oggLibPath = "${libogg}/lib/libogg${stdenv.hostPlatform.extensions.sharedLibrary}";
vorbisLibPath = "${libvorbis}/lib/libvorbis${stdenv.hostPlatform.extensions.sharedLibrary}";
+2 -3
pkgs/development/python-modules/pypandoc/default.nix
···
pandocfilters,
poetry-core,
pythonOlder,
-
substituteAll,
+
replaceVars,
texliveSmall,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./static-pandoc-path.patch;
+
(replaceVars ./static-pandoc-path.patch {
pandoc = "${lib.getBin pandoc}/bin/pandoc";
pandocVersion = pandoc.version;
})
+2 -3
pkgs/development/python-modules/pyproj/default.nix
···
fetchFromGitHub,
pytestCheckHook,
pythonOlder,
-
substituteAll,
+
replaceVars,
certifi,
cython,
···
# force pyproj to use ${proj}
patches = [
-
(substituteAll {
-
src = ./001.proj.patch;
+
(replaceVars ./001.proj.patch {
proj = proj;
projdev = proj.dev;
})
+2 -3
pkgs/development/python-modules/pysaml2/default.nix
···
requests,
responses,
setuptools,
-
substituteAll,
+
replaceVars,
xmlschema,
xmlsec,
zope-interface,
···
};
patches = [
-
(substituteAll {
-
src = ./hardcode-xmlsec1-path.patch;
+
(replaceVars ./hardcode-xmlsec1-path.patch {
inherit xmlsec;
})
];
+2 -3
pkgs/development/python-modules/pytesseract/default.nix
···
packaging,
pillow,
tesseract,
-
substituteAll,
+
replaceVars,
pytestCheckHook,
setuptools,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./tesseract-binary.patch;
+
(replaceVars ./tesseract-binary.patch {
drv = tesseract;
})
];
+2 -3
pkgs/development/python-modules/python-magic/default.nix
···
buildPythonPackage,
fetchFromGitHub,
fetchpatch,
-
substituteAll,
+
replaceVars,
file,
pytestCheckHook,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./libmagic-path.patch;
+
(replaceVars ./libmagic-path.patch {
libmagic = "${file}/lib/libmagic${stdenv.hostPlatform.extensions.sharedLibrary}";
})
(fetchpatch {
+2 -3
pkgs/development/python-modules/python-mapnik/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
isPyPy,
python,
setuptools,
···
patches = [
# python-mapnik seems to depend on having the mapnik src directory
# structure available at build time. We just hardcode the paths.
-
(substituteAll {
-
src = ./find-libmapnik.patch;
+
(replaceVars ./find-libmapnik.patch {
libmapnik = "${mapnik}/lib";
})
# Use `std::optional` rather than `boost::optional`
+2 -3
pkgs/development/python-modules/python-matter-server/default.nix
···
fetchFromGitHub,
pythonOlder,
stdenvNoCC,
-
substituteAll,
+
replaceVars,
# build
setuptools,
···
};
patches = [
-
(substituteAll {
-
src = ./link-paa-root-certs.patch;
+
(replaceVars ./link-paa-root-certs.patch {
paacerts = paaCerts;
})
];
+2 -3
pkgs/development/python-modules/python-rapidjson/default.nix
···
pytestCheckHook,
pytz,
setuptools,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./rapidjson-include-dir.patch;
+
(replaceVars ./rapidjson-include-dir.patch {
rapidjson = lib.getDev rapidjson;
})
];
+2 -3
pkgs/development/python-modules/python3-gnutls/default.nix
···
{
lib,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
buildPythonPackage,
isPy3k,
gnutls,
···
];
patches = [
-
(substituteAll {
-
src = ./libgnutls-path.patch;
+
(replaceVars ./libgnutls-path.patch {
gnutlslib = "${lib.getLib gnutls}/lib";
})
];
+2 -3
pkgs/development/python-modules/pythran/default.nix
···
buildPythonPackage,
fetchFromGitHub,
fetchpatch2,
-
substituteAll,
+
replaceVars,
# build-system
setuptools,
···
patches = [
# Hardcode path to mp library
-
(substituteAll {
-
src = ./0001-hardcode-path-to-libgomp.patch;
+
(replaceVars ./0001-hardcode-path-to-libgomp.patch {
gomp = "${
if stdenv.cc.isClang then openmp else (lib.getLib stdenv.cc.cc)
}/lib/libgomp${stdenv.hostPlatform.extensions.sharedLibrary}";
+2 -3
pkgs/development/python-modules/pyturbojpeg/default.nix
···
setuptools,
numpy,
python,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
};
patches = [
-
(substituteAll {
-
src = ./lib-path.patch;
+
(replaceVars ./lib-path.patch {
libturbojpeg = "${lib.getLib libjpeg_turbo}/lib/libturbojpeg${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -3
pkgs/development/python-modules/pyvirtualdisplay/default.nix
···
stdenv,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
xorg,
# build-system
···
};
patches = lib.optionals stdenv.hostPlatform.isLinux [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
xauth = lib.getExe xorg.xauth;
xdpyinfo = lib.getExe xorg.xdpyinfo;
})
+2 -3
pkgs/development/python-modules/slixmpp/default.nix
···
pyasn1,
pyasn1-modules,
pytestCheckHook,
-
substituteAll,
+
replaceVars,
pythonOlder,
}:
···
nativeCheckInputs = [ pytestCheckHook ];
patches = [
-
(substituteAll {
-
src = ./hardcode-gnupg-path.patch;
+
(replaceVars ./hardcode-gnupg-path.patch {
inherit gnupg;
})
];
+2 -3
pkgs/development/python-modules/sounddevice/default.nix
···
cffi,
numpy,
portaudio,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
pythonImportsCheck = [ "sounddevice" ];
patches = [
-
(substituteAll {
-
src = ./fix-portaudio-library-path.patch;
+
(replaceVars ./fix-portaudio-library-path.patch {
portaudio = "${portaudio}/lib/libportaudio${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -3
pkgs/development/python-modules/streamdeck/default.nix
···
stdenv,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
pkgs,
}:
···
patches = [
# substitute libusb path
-
(substituteAll {
-
src = ./hardcode-libusb.patch;
+
(replaceVars ./hardcode-libusb.patch {
libusb = "${pkgs.hidapi}/lib/libhidapi-libusb${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -3
pkgs/development/python-modules/termplotlib/default.nix
···
{
lib,
-
substituteAll,
+
replaceVars,
buildPythonPackage,
fetchFromGitHub,
pytestCheckHook,
···
propagatedBuildInputs = [ numpy ];
patches = [
-
(substituteAll {
-
src = ./gnuplot-subprocess.patch;
+
(replaceVars ./gnuplot-subprocess.patch {
gnuplot = "${gnuplot.out}/bin/gnuplot";
})
];
+2 -3
pkgs/development/python-modules/tinygrad/default.nix
···
config,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
addDriverRunpath,
cudaSupport ? config.cudaSupport,
rocmSupport ? config.rocmSupport,
···
};
patches = [
-
(substituteAll {
-
src = ./fix-dlopen-cuda.patch;
+
(replaceVars ./fix-dlopen-cuda.patch {
inherit (addDriverRunpath) driverLink;
libnvrtc =
if cudaSupport then
+2 -3
pkgs/development/python-modules/tpm2-pytss/default.nix
···
{
lib,
stdenv,
-
substituteAll,
+
replaceVars,
buildPythonPackage,
fetchPypi,
fetchpatch,
···
# when cross-compiling is turned on.
# This patch changes the call to pycparser.preprocess_file to provide the name
# of the cross-compiling cpp
-
(substituteAll {
-
src = ./cross.patch;
+
(replaceVars ./cross.patch {
crossPrefix = stdenv.hostPlatform.config;
})
];
+2 -3
pkgs/development/python-modules/vispy/default.nix
···
lib,
stdenv,
buildPythonPackage,
-
substituteAll,
+
replaceVars,
fetchPypi,
cython,
fontconfig,
···
};
patches = lib.optionals (!stdenv.hostPlatform.isDarwin) [
-
(substituteAll {
-
src = ./library-paths.patch;
+
(replaceVars ./library-paths.patch {
fontconfig = "${fontconfig.lib}/lib/libfontconfig${stdenv.hostPlatform.extensions.sharedLibrary}";
gl = "${libGL.out}/lib/libGL${stdenv.hostPlatform.extensions.sharedLibrary}";
})
+2 -3
pkgs/development/python-modules/wallet-py3k/default.nix
···
lib,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
openssl,
setuptools,
six,
···
};
patches = [
-
(substituteAll {
-
src = ./openssl-path.patch;
+
(replaceVars ./openssl-path.patch {
openssl = lib.getExe openssl;
})
];
+2 -3
pkgs/development/python-modules/wandb/default.nix
···
## wandb
buildPythonPackage,
-
substituteAll,
+
replaceVars,
# build-system
hatchling,
···
patches = [
# Replace git paths
-
(substituteAll {
-
src = ./hardcode-git-path.patch;
+
(replaceVars ./hardcode-git-path.patch {
git = lib.getExe git;
})
];
+2 -3
pkgs/development/python-modules/wavefile/default.nix
···
pyaudio,
numpy,
libsndfile,
-
substituteAll,
+
replaceVars,
}:
buildPythonPackage rec {
···
patches = [
# Fix check error
# OSError: libsndfile.so.1: cannot open shared object file: No such file or directory
-
(substituteAll {
-
src = ./libsndfile.py.patch;
+
(replaceVars ./libsndfile.py.patch {
libsndfile = "${lib.getLib libsndfile}/lib/libsndfile${stdenv.hostPlatform.extensions.sharedLibrary}";
})
];
+2 -4
pkgs/development/python-modules/weasyprint/default.nix
···
pytest-cov-stub,
pytestCheckHook,
pythonOlder,
-
substituteAll,
+
replaceVars,
tinycss2,
tinyhtml5,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./library-paths.patch;
+
(replaceVars ./library-paths.patch {
fontconfig = "${fontconfig.lib}/lib/libfontconfig${stdenv.hostPlatform.extensions.sharedLibrary}";
pangoft2 = "${pango.out}/lib/libpangoft2-1.0${stdenv.hostPlatform.extensions.sharedLibrary}";
gobject = "${glib.out}/lib/libgobject-2.0${stdenv.hostPlatform.extensions.sharedLibrary}";
pango = "${pango.out}/lib/libpango-1.0${stdenv.hostPlatform.extensions.sharedLibrary}";
-
pangocairo = "${pango.out}/lib/libpangocairo-1.0${stdenv.hostPlatform.extensions.sharedLibrary}";
harfbuzz = "${harfbuzz.out}/lib/libharfbuzz${stdenv.hostPlatform.extensions.sharedLibrary}";
harfbuzz_subset = "${harfbuzz.out}/lib/libharfbuzz-subset${stdenv.hostPlatform.extensions.sharedLibrary}";
})
+2 -3
pkgs/development/python-modules/wxpython/4.2.nix
···
buildPythonPackage,
setuptools,
fetchPypi,
-
substituteAll,
+
replaceVars,
# build
autoPatchelfHook,
···
};
patches = [
-
(substituteAll {
-
src = ./4.2-ctypes.patch;
+
(replaceVars ./4.2-ctypes.patch {
libgdk = "${gtk3.out}/lib/libgdk-3.so";
libpangocairo = "${pango}/lib/libpangocairo-1.0.so";
libcairo = "${cairo}/lib/libcairo.so";
+2 -3
pkgs/development/python-modules/xsdata/default.nix
···
buildPythonPackage,
pythonOlder,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
ruff,
click,
click-default-group,
···
};
patches = [
-
(substituteAll {
-
src = ./paths.patch;
+
(replaceVars ./paths.patch {
ruff = lib.getExe ruff;
})
];
+2 -3
pkgs/development/python-modules/youseedee/default.nix
···
lib,
buildPythonPackage,
fetchPypi,
-
substituteAll,
+
replaceVars,
setuptools,
setuptools-scm,
filelock,
···
patches = [
# Load data files from the unicode-character-database package instead of
# downloading them from the internet. (nixpkgs-specific, not upstreamable)
-
(substituteAll {
-
src = ./0001-use-packaged-unicode-data.patch;
+
(replaceVars ./0001-use-packaged-unicode-data.patch {
ucd_dir = "${unicode-character-database}/share/unicode";
})
];
+2 -3
pkgs/development/python-modules/yq/default.nix
···
pytestCheckHook,
pyyaml,
setuptools-scm,
-
substituteAll,
+
replaceVars,
tomlkit,
xmltodict,
}:
···
};
patches = [
-
(substituteAll {
-
src = ./jq-path.patch;
+
(replaceVars ./jq-path.patch {
jq = "${lib.getBin jq}/bin/jq";
})
];
+2 -3
pkgs/development/python-modules/zlib-ng/default.nix
···
lib,
buildPythonPackage,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
# build-system
cmake,
···
};
patches = [
-
(substituteAll {
-
src = ./version.patch;
+
(replaceVars ./version.patch {
inherit version;
})
];
+2 -3
pkgs/development/rocm-modules/5/rocprofiler/default.nix
···
fetchFromGitHub,
rocmUpdateScript,
symlinkJoin,
-
substituteAll,
+
replaceVars,
cmake,
clang,
clr,
···
./0000-dont-install-tests-hsaco.patch
# Fix bad paths
-
(substituteAll {
-
src = ./0001-fix-shell-scripts.patch;
+
(replaceVars ./0001-fix-shell-scripts.patch {
rocmtoolkit_merged = rocmtoolkit-merged;
})
];
+2 -3
pkgs/development/rocm-modules/6/rocprofiler/default.nix
···
fetchFromGitHub,
rocmUpdateScript,
symlinkJoin,
-
substituteAll,
+
replaceVars,
cmake,
clang,
clr,
···
./0000-dont-install-tests-hsaco.patch
# Fix bad paths
-
(substituteAll {
-
src = ./0001-fix-shell-scripts.patch;
+
(replaceVars ./0001-fix-shell-scripts.patch {
rocmtoolkit_merged = rocmtoolkit-merged;
})
+2 -3
pkgs/development/tcl-modules/by-name/ex/expect/package.nix
···
makeWrapper,
autoreconfHook,
fetchpatch,
-
substituteAll,
+
replaceVars,
}:
tcl.mkTclDerivation rec {
···
};
patches = [
-
(substituteAll {
-
src = ./fix-build-time-run-tcl.patch;
+
(replaceVars ./fix-build-time-run-tcl.patch {
tcl = "${buildPackages.tcl}/bin/tclsh";
})
# The following patches fix compilation with clang 15+
+5 -9
pkgs/development/tools/build-managers/bazel/bazel_5/default.nix
···
# Also, don't clean up environment variables (so that NIX_ environment variables are passed to compilers).
enableNixHacks ? false,
file,
-
substituteAll,
+
replaceVars,
writeTextFile,
}:
···
# This patch removes using the -fobjc-arc compiler option and makes the code
# compile without automatic reference counting. Caveat: this leaks memory, but
# we accept this fact because xcode_locator is only a short-lived process used during the build.
-
(substituteAll {
-
src = ./no-arc.patch;
+
(replaceVars ./no-arc.patch {
multiBinPatch = if stdenv.hostPlatform.system == "aarch64-darwin" then "arm64" else "x86_64";
})
···
# This is non hermetic on non-nixos systems. On NixOS, bazel cannot find the required binaries.
# So we are replacing this bazel paths by defaultShellPath,
# improving hermeticity and making it work in nixos.
-
(substituteAll {
-
src = ../strict_action_env.patch;
+
(replaceVars ../strict_action_env.patch {
strictActionEnvPatch = defaultShellPath;
})
-
(substituteAll {
-
src = ./actions_path.patch;
+
(replaceVars ./actions_path.patch {
actionsPathPatch = defaultShellPath;
})
# bazel reads its system bazelrc in /etc
# override this path to a builtin one
-
(substituteAll {
-
src = ../bazel_rc.patch;
+
(replaceVars ../bazel_rc.patch {
bazelSystemBazelRCPath = bazelRC;
})
+5 -9
pkgs/development/tools/build-managers/bazel/bazel_6/default.nix
···
# Also, don't clean up environment variables (so that NIX_ environment variables are passed to compilers).
, enableNixHacks ? false
, file
-
, substituteAll
+
, replaceVars
, writeTextFile
, writeShellApplication
, makeBinaryWrapper
···
# This patch removes using the -fobjc-arc compiler option and makes the code
# compile without automatic reference counting. Caveat: this leaks memory, but
# we accept this fact because xcode_locator is only a short-lived process used during the build.
-
(substituteAll {
-
src = ./no-arc.patch;
+
(replaceVars ./no-arc.patch {
multiBinPatch = if stdenv.hostPlatform.system == "aarch64-darwin" then "arm64" else "x86_64";
})
···
# This is non hermetic on non-nixos systems. On NixOS, bazel cannot find the required binaries.
# So we are replacing this bazel paths by defaultShellPath,
# improving hermeticity and making it work in nixos.
-
(substituteAll {
-
src = ../strict_action_env.patch;
+
(replaceVars ../strict_action_env.patch {
strictActionEnvPatch = defaultShellPath;
})
-
(substituteAll {
-
src = ./actions_path.patch;
+
(replaceVars ./actions_path.patch {
actionsPathPatch = defaultShellPath;
})
# bazel reads its system bazelrc in /etc
# override this path to a builtin one
-
(substituteAll {
-
src = ../bazel_rc.patch;
+
(replaceVars ../bazel_rc.patch {
bazelSystemBazelRCPath = bazelRC;
})
] ++ lib.optional enableNixHacks ./nix-hacks.patch;
+3 -5
pkgs/development/tools/build-managers/bazel/bazel_7/default.nix
···
fetchurl,
makeWrapper,
writeTextFile,
-
substituteAll,
+
replaceVars,
writeShellApplication,
makeBinaryWrapper,
autoPatchelfHook,
···
# This is non hermetic on non-nixos systems. On NixOS, bazel cannot find the required binaries.
# So we are replacing this bazel paths by defaultShellPath,
# improving hermeticity and making it work in nixos.
-
(substituteAll {
-
src = ../strict_action_env.patch;
+
(replaceVars ../strict_action_env.patch {
strictActionEnvPatch = defaultShellPath;
})
# bazel reads its system bazelrc in /etc
# override this path to a builtin one
-
(substituteAll {
-
src = ../bazel_rc.patch;
+
(replaceVars ../bazel_rc.patch {
bazelSystemBazelRCPath = bazelRC;
})
]
-1
pkgs/development/tools/ocaml/merlin/4.x.nix
···
in
[
(replaceVars (if old-patch then ./fix-paths.patch else ./fix-paths2.patch) {
-
dot-merlin-reader = "${dot-merlin-reader}/bin/dot-merlin-reader";
dune = "${dune_3}/bin/dune";
})
+3 -4
pkgs/development/tools/ocaml/merlin/default.nix
···
fetchurl,
fetchpatch,
buildDunePackage,
-
substituteAll,
+
replaceVars,
dot-merlin-reader,
dune_2,
yojson,
···
minimalOCamlVersion = "4.02.3";
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
-
dot_merlin_reader = "${dot-merlin-reader}/bin/dot-merlin-reader";
+
(replaceVars ./fix-paths.patch {
+
dot-merlin-reader = "${dot-merlin-reader}/bin/dot-merlin-reader";
dune = "${dune_2}/bin/dune";
})
# https://github.com/ocaml/merlin/pull/1798
+4 -3
pkgs/games/dwarf-fortress/dwarf-therapist/wrapper.nix
···
-
{ stdenv, dwarf-therapist, dwarf-fortress, substituteAll, coreutils, wrapQtAppsHook
+
{ stdenv, dwarf-therapist, dwarf-fortress, replaceVars, coreutils, wrapQtAppsHook
}:
let
···
pname = "dwarf-therapist";
inherit (dwarf-therapist) version meta;
-
wrapper = substituteAll {
-
src = ./dwarf-therapist.in;
+
wrapper = replaceVars ./dwarf-therapist.in {
stdenv_shell = "${stdenv.shell}";
rm = "${coreutils}/bin/rm";
ln = "${coreutils}/bin/ln";
···
mkdir = "${coreutils}/bin/mkdir";
dirname = "${coreutils}/bin/dirname";
therapist = "${dwarf-therapist}";
+
# replaced in buildCommand
+
install = null;
};
paths = [ dwarf-therapist ];
+2 -5
pkgs/games/dwarf-fortress/wrapper/default.nix
···
stdenv,
lib,
buildEnv,
-
substituteAll,
+
replaceVars,
makeWrapper,
runCommand,
coreutils,
···
pname = "dwarf-fortress";
version = dwarf-fortress.dfVersion;
-
dfInit = substituteAll {
-
name = "dwarf-fortress-init";
-
src = ./dwarf-fortress-init.in;
+
dfInit = replaceVars ./dwarf-fortress-init.in {
inherit env;
-
inherit (dwarf-fortress) exe;
stdenv_shell = "${stdenv.shell}";
cp = "${coreutils}/bin/cp";
rm = "${coreutils}/bin/rm";
+4 -3
pkgs/kde/plasma/kinfocenter/default.nix
···
pciutils,
pulseaudio,
qttools,
-
substituteAll,
+
replaceVars,
systemsettings,
util-linux,
vulkan-tools,
···
patches = [
# fwupdmgr is provided through NixOS' module
-
(substituteAll (
+
(replaceVars ./0001-tool-paths.patch (
{
-
src = ./0001-tool-paths.patch;
+
# @QtBinariesDir@ only appears in the *removed* lines of the diff
+
QtBinariesDir = null;
}
// tools
))
+4 -3
pkgs/kde/plasma/plasma-workspace/default.nix
···
{
lib,
mkKdeDerivation,
-
substituteAll,
+
replaceVars,
dbus,
fontconfig,
xorg,
···
pname = "plasma-workspace";
patches = [
-
(substituteAll {
-
src = ./dependency-paths.patch;
+
(replaceVars ./dependency-paths.patch {
dbusSend = lib.getExe' dbus "dbus-send";
fcMatch = lib.getExe' fontconfig "fc-match";
lsof = lib.getExe lsof;
···
xmessage = lib.getExe xorg.xmessage;
xrdb = lib.getExe xorg.xrdb;
xsetroot = lib.getExe xorg.xsetroot;
+
# @QtBinariesDir@ only appears in the *removed* lines of the diff
+
QtBinariesDir = null;
})
];
+3 -8
pkgs/os-specific/linux/udisks/2-default.nix
···
lib,
stdenv,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
pkg-config,
gnused,
autoreconfHook,
···
] ++ lib.optional (stdenv.hostPlatform == stdenv.buildPlatform) "devdoc";
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
-
bash = "${bash}/bin/bash";
+
(replaceVars ./fix-paths.patch {
false = "${coreutils}/bin/false";
mdadm = "${mdadm}/bin/mdadm";
-
mkswap = "${util-linux}/bin/mkswap";
sed = "${gnused}/bin/sed";
sh = "${bash}/bin/sh";
sleep = "${coreutils}/bin/sleep";
-
swapon = "${util-linux}/bin/swapon";
true = "${coreutils}/bin/true";
})
-
(substituteAll {
-
src = ./force-path.patch;
+
(replaceVars ./force-path.patch {
path = lib.makeBinPath [
btrfs-progs
coreutils
+2 -3
pkgs/servers/home-assistant/default.nix
···
fetchFromGitHub,
fetchPypi,
python313,
-
substituteAll,
+
replaceVars,
ffmpeg-headless,
inetutils,
nixosTests,
···
./patches/static-follow-symlinks.patch
# Patch path to ffmpeg binary
-
(substituteAll {
-
src = ./patches/ffmpeg-path.patch;
+
(replaceVars ./patches/ffmpeg-path.patch {
ffmpeg = "${lib.getExe ffmpeg-headless}";
})
];
+8 -3
pkgs/tools/inputmethods/ibus/default.nix
···
{
lib,
stdenv,
-
substituteAll,
+
replaceVars,
fetchFromGitHub,
autoreconfHook,
gettext,
···
};
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
+
(replaceVars ./fix-paths.patch {
pythonInterpreter = python3Runtime.interpreter;
pythonSitePackages = python3.sitePackages;
+
# patch context
+
prefix = null;
+
datarootdir = null;
+
localedir = null;
+
# removed line only
+
PYTHON = null;
})
./build-without-dbus-launch.patch
];
+2 -4
pkgs/tools/misc/ckb-next/default.nix
···
lib,
wrapQtAppsHook,
fetchFromGitHub,
-
substituteAll,
+
replaceVars,
udev,
stdenv,
pkg-config,
···
patches = [
./install-dirs.patch
-
(substituteAll {
-
name = "ckb-next-modprobe.patch";
-
src = ./modprobe.patch;
+
(replaceVars ./modprobe.patch {
inherit kmod;
})
];
+5 -4
pkgs/tools/networking/networkmanager/default.nix
···
{ lib
, stdenv
, fetchurl
-
, substituteAll
+
, replaceVars
, gettext
, pkg-config
, dbus
···
];
patches = [
-
(substituteAll {
-
src = ./fix-paths.patch;
-
inherit iputils openconnect ethtool gnused systemd;
+
(replaceVars ./fix-paths.patch {
+
inherit iputils openconnect ethtool gnused;
inherit runtimeShell;
+
# patch context
+
OUTPUT = null;
})
# Meson does not support using different directories during build and