uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
|
|
@ -0,0 +1,25 @@
|
|||
diff --git a/shells/bash.go b/shells/bash.go
|
||||
index 18d608445..f158ffc0b 100644
|
||||
--- a/shells/bash.go
|
||||
+++ b/shells/bash.go
|
||||
@@ -3,6 +3,7 @@ package shells
|
||||
import (
|
||||
"bytes"
|
||||
"fmt"
|
||||
+ "os/exec"
|
||||
"path"
|
||||
"runtime"
|
||||
"strconv"
|
||||
@@ -307,7 +308,11 @@ func (b *BashShell) GetConfiguration(info common.ShellScriptInfo) (*common.Shell
|
||||
|
||||
script.Command = "su"
|
||||
if runtime.GOOS == OSLinux {
|
||||
- script.Arguments = []string{"-s", "/bin/" + b.Shell, info.User, "-c", script.CmdLine}
|
||||
+ shellPath, err := exec.LookPath(b.Shell)
|
||||
+ if err != nil {
|
||||
+ shellPath = "/bin/" + b.Shell
|
||||
+ }
|
||||
+ script.Arguments = []string{"-s", shellPath, info.User, "-c", script.CmdLine}
|
||||
} else {
|
||||
script.Arguments = []string{info.User, "-c", script.CmdLine}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue