Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x/mobile: macos catalina compile err #37317

Open
hyperorchid opened this issue Feb 20, 2020 · 2 comments
Open

x/mobile: macos catalina compile err #37317

hyperorchid opened this issue Feb 20, 2020 · 2 comments

Comments

@hyperorchid
Copy link

@hyperorchid hyperorchid commented Feb 20, 2020

What version of Go are you using (go version)?

$ go version
go version go1.13.8 darwin/amd64

Does this issue reproduce with the latest release?

yes

What operating system and processor architecture are you using (go env)?

go env Output
$ go env

GO111MODULE=""
GOARCH="amd64"
GOBIN="/Users/hyperorchid/gowork/bin"
GOCACHE="/Users/hyperorchid/Library/Caches/go-build"
GOENV="/Users/hyperorchid/Library/Application Support/go/env"
GOEXE=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="darwin"
GONOPROXY=""
GONOSUMDB=""
GOOS="darwin"
GOPATH="/Users/hyperorchid/gowork"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/Cellar/go/1.13.8/libexec"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/Cellar/go/1.13.8/libexec/pkg/tool/darwin_amd64"
GCCGO="gccgo"
AR="ar"
CC="clang"
CXX="clang++"
CGO_ENABLED="1"
GOMOD=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/pd/zfbdf6sj5w53r8lwf723pfgw0000gn/T/go-build898659371=/tmp/go-build -gno-record-gcc-switches -fno-common"
hyperorchid@192 go-lib %

What did you do?

gomobile bind -v -o bin/iosLib.framework -target=ios github.com/hyperorchid/go-lib/ios

What did you expect to see?

get framework file

What did you see instead?

github.com/elastic/gosigar

/Users/hyperorchid/gowork/src/github.com/elastic/gosigar/sigar_darwin.go:12:10: fatal error: 'libproc.h' file not found
#include <libproc.h>
^~~~~~~~~~~
1 error generated.
github.com/ethereum/go-ethereum/rpc
gomobile: darwin-arm: go build -tags ios -v -buildmode=c-archive -o /var/folders/pd/zfbdf6sj5w53r8lwf723pfgw0000gn/T/gomobile-work-353082488/iosLib-arm.a ./gobind failed: exit status 2

make: *** [i] Error 1

@hyperorchid

This comment has been minimized.

Copy link
Author

@hyperorchid hyperorchid commented Feb 20, 2020

export CPATH=/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include

gomobile bind -v -o bin/iosLib.framework -target=ios github.com/hyperorchid/go-lib/ios
runtime/cgo

runtime/cgo

In file included from cgo-builtin-prolog:1:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stddef.h:64:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/_types.h:27:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/_types.h:32:
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:807:2: error: Unsupported architecture
#error Unsupported architecture
^

@toothrot toothrot changed the title macos catalina compile err x/mobile: macos catalina compile err Feb 20, 2020
@gopherbot gopherbot added this to the Unreleased milestone Feb 20, 2020
@gopherbot gopherbot added the mobile label Feb 20, 2020
@toothrot

This comment has been minimized.

Copy link
Contributor

@toothrot toothrot commented Feb 20, 2020

/cc @hyangah

@dmitshur dmitshur added the OS-Darwin label Feb 21, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
4 participants
You can’t perform that action at this time.