Closed yourabi closed 14 years ago
Actually I misread the info / it is poorly phrased. The way I read it made it seem that the environment variables were only needed to run ( a la ANT) not compile go (though it did use the word compile in the next sentence, my bad)
I'll tweak the verbiage and send a pull request
The tests will fail if the mac firewall is running. Should probably be noted in info.
But even if the firewall is disabled go still fails. I might take a stab at doing my own build and seeing if that fails as well.
--- cd pkg/sync /usr/local/Cellar/go/HEAD/bin/gotest rm -f _test/sync.a gotest.6 /usr/local/Cellar/go/HEAD/bin/6g -o gotest.6 mutex.go rwmutex.go xadd_test.go rm -f _test/sync.a /usr/local/Cellar/go/HEAD/bin/gopack grc _test/sync.a gotest.6 asm_amd64.6
PASS
--- cd cmd/gofmt ./test.sh "/usr/local/Cellar/go/HEAD"/src/pkg/go/parser/parser.go
PASSED (2 tests)
real 0m0.796s user 0m0.715s sys 0m0.045s
--- cd cmd/ebnflint /usr/local/Cellar/go/HEAD/bin/ebnflint -start="SourceFile" "/usr/local/Cellar/go/HEAD"/doc/go_spec.html
real 0m0.020s user 0m0.012s sys 0m0.006s
--- cd ../misc/cgo/stdio rm -rf _.o .a .[568vq] [568vq].out hello fib chain run.out .cgo1.go .cgo2.c _cgo_defun.c _cgo_gotypes.go _cgoexport. *.so _obj _test _testmain.go CGOPKGPATH= /usr/local/Cellar/go/HEAD/bin/cgo -- align.go file.go test.go Error running gcc: $ 6c -m64 -E -dM -xc - <<EOF
typedef struct { char p; int n; } GoString; GoString GoString(char p); char *CString(GoString);
include
typedef unsigned char Uint8; typedef unsigned short Uint16;
typedef enum { MOD1 = 0x0000, MODX = 0x8000 } SDLMod;
typedef enum { A = 1, B = 322, SDLK_LAST } SDLKey;
typedef struct SDL_keysym { Uint8 scancode; SDLKey sym; SDLMod mod; Uint16 unicode; } SDL_keysym;
typedef struct SDL_KeyboardEvent { Uint8 typ; Uint8 which; Uint8 state; SDL_keysym keysym; } SDL_KeyboardEvent;
void makeEvent(SDL_KeyboardEvent event) { unsigned char p; int i;
p = (unsigned char)event; for (i=0; i<sizeof event; i++) { p[i] = i; } }
int same(SDL_KeyboardEvent* e, Uint8 typ, Uint8 which, Uint8 state, Uint8 scan, SDLKey sym, SDLMod mod, Uint16 uni) { return e->typ == typ && e->which == which && e->state == state && e->keysym.scancode == scan && e->keysym.sym == sym && e->keysym.mod == mod && e->keysym.unicode == uni; }
void cTest(SDL_KeyboardEvent *event) { printf("C: %#x %#x %#x %#x %#x %#x %#x\n", event->typ, event->which, event->state, event->keysym.scancode, event->keysym.sym, event->keysym.mod, event->keysym.unicode); fflush(stdout); }
EOF make: *\ [_cgo_defun.c] Error 2 Exit status: 2
http://github.com/mxcl/homebrew/blob/master/Library/Formula/go.rb#L34
==> Environment HOMEBREW_VERSION: 0.6 HEAD: c28c0fc576a34b543ecc5bdf331af9a68e063d63 HOMEBREW_PREFIX: /usr/local HOMEBREW_CELLAR: /usr/local/Cellar HOMEBREW_CACHE: /Users/yourabi/Library/Caches/Homebrew HOMEBREW_REPOSITORY: /usr/local HOMEBREW_LIBRARY_PATH: /usr/local/Library/Homebrew Hardware: dual-core 64-bit penryn OS X: 10.6.4 Kernel Architecture: i386 Ruby: 1.8.7-174 GCC-4.0: build 5494 (5493 or newer recommended) GCC-4.2: build 5664 (5659 or newer recommended) LLVM: build 2326 (2207 or newer recommended) MacPorts or Fink? false X11 installed? true
==> Build Flags CC: /usr/bin/cc => /usr/bin/gcc-4.2 CXX: /usr/bin/c++ => /usr/bin/c++-4.2 LD: /usr/bin/cc => /usr/bin/gcc-4.2 CFLAGS: -O3 -march=core2 -msse4.1 -w -pipe CXXFLAGS: -O3 -march=core2 -msse4.1 -w -pipe Error: Failure while executing: ./all.bash Please report this bug at http://github.com/mxcl/homebrew/issues These existing issues may help you: http://github.com/mxcl/homebrew/issues/#issue/1915 http://github.com/mxcl/homebrew/issues/#issue/1998