Skip to content

Commit 7268a64

Browse files
fluhussbinet
authored andcommitted
bind: fix IncDir to work with forward slashes
On Windows it is populated with backslashes, which GCC doesn't like. This fix should make it work on windows. Fixes #193.
1 parent 0e4a864 commit 7268a64

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

bind/utils.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import (
1111
"go/types"
1212
"os"
1313
"os/exec"
14+
"path/filepath"
1415
"regexp"
1516
"strconv"
1617
"strings"
@@ -136,6 +137,7 @@ print(json.dumps({
136137
return cfg, errors.Wrapf(err, "could not decode JSON script output")
137138
}
138139

140+
raw.IncDir = filepath.ToSlash(raw.IncDir)
139141
if strings.HasSuffix(raw.LibPy, ".a") {
140142
raw.LibPy = raw.LibPy[:len(raw.LibPy)-len(".a")]
141143
}

gopy

7.01 MB
Binary file not shown.

0 commit comments

Comments
 (0)