From 3a83a8bbc9db217f0112a2b774e90d176c7b7d1f Mon Sep 17 00:00:00 2001 From: Mike McQuaid Date: Tue, 8 Oct 2013 08:39:04 +0100 Subject: [PATCH] go: build cgo with clang for devel versions. Closes Homebrew/homebrew#23119. --- Formula/go.rb | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/Formula/go.rb b/Formula/go.rb index 2c9868a925f..8da5f440d1e 100644 --- a/Formula/go.rb +++ b/Formula/go.rb @@ -23,10 +23,7 @@ class Go < Formula sha1 '9f39106e06f552e9bf6d15d201c4663c051d4f89' end - # the cgo module cannot build with clang - # NOTE it is ridiculous that we put this stuff in the class - # definition, it needs to be in a pre-install test function! - if build.with? 'cgo' + if build.with? 'cgo' and not build.devel? depends_on 'apple-gcc42' if MacOS.version >= :mountain_lion fails_with :clang do @@ -96,13 +93,7 @@ class Go < Formula when $GOPATH and $GOROOT are set to the same value. More information here: http://golang.org/doc/code.html#GOPATH - - FYI: We probably didn't build the cgo module because it doesn't build with - clang. EOS - # NOTE I would have the cgo caveat only show if we didn't build it but the - # state matrix for that seems inconclusive, ENV.compiler doesn't actually - # mean for sure that we used that compiler. end test do