ikiwiki: Patch shebangs in plugins

Since the checkPhase runs before fixupPhase, we must manually patch
shebangs for plugins that are executed during tests.

Specifically, when docutilsSupport is enabled. The tests for the rst
plugin failed.
This commit is contained in:
Michal Sojka 2021-10-28 11:23:35 +02:00
parent a2e7a452be
commit 4007e03a20

View File

@ -50,6 +50,9 @@ stdenv.mkDerivation rec {
# State the gcc dependency, and make the cgi use our wrapper
sed -i -e 's@$0@"'$out/bin/ikiwiki'"@' \
-e "s@'cc'@'${stdenv.cc}/bin/gcc'@" IkiWiki/Wrapper.pm
# Without patched plugin shebangs, some tests like t/rst.t fail
# (with docutilsSupport enabled)
patchShebangs plugins/*
'';
configurePhase = "perl Makefile.PL PREFIX=$out";