diff options
author | Carlos Castillo <cookieo9@gmail.com> | 2014-02-13 10:11:44 -0800 |
---|---|---|
committer | Carlos Castillo <cookieo9@gmail.com> | 2014-02-13 10:11:44 -0800 |
commit | e08f64f3a4142e6066b4b015d82744e0a9b030fd (patch) | |
tree | db715e5e77ed6684fdd042f534b5f84e33c9ba32 /src/cmd/go/list.go | |
parent | 14bb8cf4fac319a53f92f2e907d1582e61ed4e36 (diff) | |
download | go-e08f64f3a4142e6066b4b015d82744e0a9b030fd.tar.gz |
cmd/go, go/build: support .m files
go/build is changed to list the .m files in a package, and match them for build constraints, adding them to a new field: Package.MFiles.
The go tool is changed to support building .m files and linking in the results during CGO and SWIG builds. This means packages that create a C interface to calls Objective-C code from go are now go-gettable without producing and distributing .syso files. This change is analogous to the one in Go 1.2 made to support C++ built code.
This change doesn't support .mm files (Objective C++).
Also added support for these MFiles to go list's -json mode.
Fixes issue 6536.
LGTM=iant
R=golang-codereviews, iant
CC=golang-codereviews
https://codereview.appspot.com/60590044
Committer: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/cmd/go/list.go')
-rw-r--r-- | src/cmd/go/list.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/cmd/go/list.go b/src/cmd/go/list.go index f56ebed38..2cd8e5fa7 100644 --- a/src/cmd/go/list.go +++ b/src/cmd/go/list.go @@ -47,6 +47,7 @@ which calls strings.Join. The struct being passed to the template is: IgnoredGoFiles []string // .go sources ignored due to build constraints CFiles []string // .c source files CXXFiles []string // .cc, .cxx and .cpp source files + MFiles []string // .m source files HFiles []string // .h, .hh, .hpp and .hxx source files SFiles []string // .s source files SwigFiles []string // .swig files |