Skip to content

Instantly share code, notes, and snippets.

@mogeta
Last active August 29, 2015 14:17
Show Gist options
  • Save mogeta/d704b7846070676968e5 to your computer and use it in GitHub Desktop.
Save mogeta/d704b7846070676968e5 to your computer and use it in GitHub Desktop.
gxuiインストール

gxuiのインストールを試して見てる

go get github.com/google/gxui
cd  /Users/hogehoge/go/src/github.com/google/gxui/samples
In file included from ../../../../go-gl-legacy/gl/attriblocation.go:7:
./gl.h:2:10: fatal error: 'GL/glew.h' file not found
#include <GL/glew.h>

というエラーがでます。.hファイルねーぞ!ということで

gles install

brew install glew
brew info glesでインストールパスの確認。-> includeとlibのパスを見とく

go-gl-legacyの作業

cd $GOPATH/src/github.com/go-gl-legacy/gl
CGO_CFLAGS="-I/usr/local/Cellar/glew/1.11.0/include" CGO_LDFLAGS="-L/usr/local/Cellar/glew/1.11.0/lib" go install

これでサンプルが動く

cd $GOPATH/src/github.com/google/gxui/samples/polyedit
cd polyedit
go run main.go

参考記事等

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment