Closed rizo closed 2 years ago
stdenv
only applies patchShebangs
to the output of the derivation during fixupPhase
, while we need to run it on the derivation source during the configurePhase
. However, it is important that we can disable it (for cases like yours), so it is controlled with dontPatchShebangsEarly
:)
Oh, I see. I didn't know that patchShebangs
was applied after, but I guess it makes sense.
This is more of a question than an issue but why does opam-nix use
dontPatchShebangsEarly
instead of a more common namedontPatchShebangs
?As part of our build process we run
dune subst
which will invoke git to obtain the current revision, settingdontPatchShebangsEarly
is important to avoid the-dirty
suffix in the version. I spent a few hours debugging this until realised that the builder in opam-nix does not usedontPatchShebangs
.