Can Go compiler be installed on Windows?

user208987 picture user208987 · Nov 11, 2009 · Viewed 34.3k times · Source

I've been looking on golang.org for a Windows compiler, but I can't seem to find it. I can only see Linux and OS X compilers. Does anyone know if Go programming can be done on Windows, or is it something that Google hasn't implemented yet?

Update: appears that as of now (Nov. 2012) golang.org has official binary releases for windows 32/x86_64.

Answer

Jonas picture Jonas · Jul 24, 2010

There are now installers for Windows, see Go under Windows

HelloWorld.go

package main

func main() {
    println("Hello World!");
}

Compile with 8g, link with 8l and then execute. Example:

8g HelloWorld.go
8l -o HelloWorld.exe HelloWorld.8
HelloWorld