all: add bare-bones Cgo support

This commit is contained in:
Ayke van Laethem
2018-11-29 13:31:16 +01:00
parent b99bbc880a
commit ecf6ffa62e
11 changed files with 408 additions and 9 deletions
+1
View File
@@ -155,6 +155,7 @@ func LoadTarget(target string) (*TargetSpec, error) {
*spec = TargetSpec{
Triple: target,
BuildTags: []string{runtime.GOOS, runtime.GOARCH},
Compiler: commands["clang"],
Linker: "cc",
LDFlags: []string{"-no-pie"}, // WARNING: clang < 5.0 requires -nopie
Objcopy: "objcopy",