mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 14:54:29 +01:00
Fix patchShebangs on SmartOS
Tail is very picky about the space after -c when compiled by Nix on Illumos (no idea why).
This commit is contained in:
parent
b19116f688
commit
f9134ca9df
1 changed files with 2 additions and 2 deletions
|
@ -19,12 +19,12 @@ patchShebangs() {
|
|||
local newInterpreterLine
|
||||
|
||||
find "$dir" -type f -perm -0100 | while read f; do
|
||||
if [ "$(head -1 "$f" | head -c +2)" != '#!' ]; then
|
||||
if [ "$(head -1 "$f" | head -c+2)" != '#!' ]; then
|
||||
# missing shebang => not a script
|
||||
continue
|
||||
fi
|
||||
|
||||
oldInterpreterLine=$(head -1 "$f" | tail -c +3)
|
||||
oldInterpreterLine=$(head -1 "$f" | tail -c+3)
|
||||
read -r oldPath arg0 args <<< "$oldInterpreterLine"
|
||||
|
||||
if $(echo "$oldPath" | grep -q "/bin/env$"); then
|
||||
|
|
Loading…
Reference in a new issue