This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug go/64595] cgo installed into wrong directory
- From: "ian at airs dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 14 Jan 2015 15:17:38 +0000
- Subject: [Bug go/64595] cgo installed into wrong directory
- Auto-submitted: auto-generated
- References: <bug-64595-4 at http dot gcc dot gnu dot org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64595
--- Comment #4 from Ian Lance Taylor <ian at airs dot com> ---
To invoke cgo, put this code in a file foo.go and type "go run foo.go" (or "go
build foo.go && ./foo").
package main
// #include <stdio.h>
// void cprintln(const char *s) { puts(s); }
import "C"
func main() {
C.cprintln(C.CString("Hello, world"))
}