Fix CI build failures on Ubuntu 15.04 and Mac OS X (#13)
Fix CI build failures on Ubuntu 15.04 and Mac OS X (#13)

* Workaround for a bug of ld(1) in older XCode

Fix a linkage error: "ld: internal error: atom not found in symbolIndex
(__ZNSt3__111char_traitsIcE11eq_int_typeEii) for architecture x86_64".

c.f. http://ci.bazel.io/job/rules_go/BAZEL_VERSION=HEAD,PLATFORM_NAME=darwin-x86_64/39/console

* Fix a linkage error with newer GNU ld(1)

ld 2.24.90 does not support -l:relative/path. So it fails to locate
C/C++ libraries.
Made the link process with cgo more similar to cc_binary to avoid the
issue.

linuxerwang/rules_go,linuxerwang/rules_go,linuxerwang/rules_go,bazelbuild/rules_go,bazelbuild/rules_go,bazelbuild/rules_go,bazelbuild/rules_go,Xjs/rules_go,linuxerwang/rules_go,bazelbuild/rules_go,Xjs/rules_go,linuxerwang/rules_go,Xjs/rules_go,Xjs/rules_go,Xjs/rules_go