I’ve already checked out this: How to add extra build input to linux kernel?
I’m trying to install dwm-flexipatch, my config on it and all.
I tried a couple methods so far:
- overrideAttrs (works for changing source to my location of the source, does not work for adding an extra build input)
- override (I don’t know how this works)
- overrideDerivation (this is the only one that doesn’t give me an error when rebuilding NixOS for syntax, but it gives the following error).
## OVERLAYS
nixpkgs.overlays = [
#(final: prev:{
#dwm = prev.dwm.overrideAttrs (old: {
#src = /home/amon/proj/home/clones/dwm-flexipatch;
##buildInputs = prev.buildInputs ++ [ pkgs.imlib2 ];
#});
#})
(final: prev: {
dwm = prev.dwm.overrideDerivation (drv: {
src = /home/amon/proj/home/clones/dwm-flexipatch;
buildInputs = (drv.buildInputs or []) ++ [ pkgs.imlib2 ];
});
}
)
];
copying path '/nix/store/na4iw08x9qxmvdsbvmb46109wbp3f7cx-imlib2-1.12.1-bin' from 'https://cache.nixos.org'...
building '/nix/store/992vccp0iw07sr15ayqrwl7q1m5bskp2-dwm-6.4.drv'...
Running phase: unpackPhase
unpacking source archive /nix/store/bsmjxiik8ld2rg7428f37caajzb6y06g-dwm-flexipatch
source root is dwm-flexipatch
Running phase: patchPhase
Running phase: updateAutotoolsGnuConfigScriptsPhase
Running phase: configurePhase
no configure script, doing nothing
Running phase: buildPhase
build flags: SHELL=/nix/store/r9h133c9m8f6jnlsqzwf89zg9w0w78s8-bash-5.2-p15/bin/bash CC=cc
cc -c -std=c99 -pedantic -Wall -Wno-unused-function -Wno-deprecated-declarations -Os -I/usr/X11R6/include -I/usr/include/freetype2 -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700L -DVERSION=\"6.4\" -DXINERAMA drw.c
cc -c -std=c99 -pedantic -Wall -Wno-unused-function -Wno-deprecated-declarations -Os -I/usr/X11R6/include -I/usr/include/freetype2 -D_DEFAULT_SOURCE -D_BSD_SOURCE -D_XOPEN_SOURCE=700L -DVERSION=\"6.4\" -DXINERAMA dwm.c
In file included from patch/include.h:52,
from dwm.c:749:
patch/bar_winicon.h:1:10: fatal error: Imlib2.h: No such file or directory
1 | #include <Imlib2.h>
| ^~~~~~~~~~
compilation terminated.
make: *** [Makefile:18: dwm.o] Error 1
error: builder for '/nix/store/992vccp0iw07sr15ayqrwl7q1m5bskp2-dwm-6.4.drv' failed with exit code 2
error: 1 dependencies of derivation '/nix/store/ca2da8z8j5qfpf9fqb33s98kvdkd2pqa-system-path.drv' failed to build
error: 1 dependencies of derivation '/nix/store/pqi8d7707yyp0lvly2yf8mx67isq5hn1-nixos-system-nixos-23.11.4976.79baff8812a0.drv' failed to build