the environment variable GOROOT doesn't load for work with go

66 views
Skip to first unread message

Dorian ROSSE

unread,
Oct 6, 2023, 12:49:46 PM10/6/23
to golang-nuts
hello,


the environment variable GOROOT doesn't load for work with go so i can't use any go thus the environment set and put in c:/windows/system32/go/bin/go.exe doesn't work,

thanks you in advance to brig to myself the fully using of my variable envirnments GOROOT and GOPATH,

regards.


Dorian ROSSE.

Roland Müller

unread,
Oct 6, 2023, 2:42:13 PM10/6/23
to golan...@googlegroups.com

Hello,

the path of the go.exe binary is quite suspicious. C:\Windows is the windows system folder and system32 - as far as I know - contains some partly legacy stuff.

Valid locatios for programs are "C:\Program Files" or "C:\Program Files(32)" (out of my memory - since I am sitting in front of a Linux box @moment)

To what locations do your GOROOT and GOPATH put?

BR,

Roland

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/ca6c5b7a-b4c8-46cf-b955-f51bceb746a6n%40googlegroups.com.

Dorian ROSSE

unread,
Oct 7, 2023, 10:24:54 AM10/7/23
to golan...@googlegroups.com

hello,



on system windows there are both kind of installing to set up and put :

1) download and install the go exe for install in the default folder c:/programs
2) download and install the sources files of go for put it in c:/windows/system32 for the GOROOT
3) download and install the sources files of go for put it in the current folder of the user so for my install this is the following : c/:users/ghisl/ thus this is GOPATH
4) copy and paste go.exe and gofmt.exe from c:/programs/go/bin/ for create the folder /bin in both sources files GOROOT and GOPATH
5) finally my GOROOT is c:/windows/system32/go/bin/go.exe and my GOPATH is c/:users/ghisl/go/bin/go.exe

after this explaining i wait a real help for my problem therefore thanks you in advance to help myself fully use my GOROOT and my GOPATH,

Regards.


Dorian ROSSE.
You received this message because you are subscribed to a topic in the Google Groups "golang-nuts" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/golang-nuts/QQLKTkp-gqk/unsubscribe.
To unsubscribe from this group and all its topics, send an email to golang-nuts...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/golang-nuts/bf68319f-b104-3c97-57c2-9c97fd4ac1b3%40gmail.com.

Dorian ROSSE

unread,
Oct 7, 2023, 10:24:54 AM10/7/23
to golan...@googlegroups.com

I have too of course set up the environment variable by type in the start button env then i open the botton more environement variable where i have set up the GOROOT and the GOPATH following my setup needing,


thanks you in advance to help myself fully use my GOROOT and my GOPATH,


Regards.



Dorian ROSSE.

TheDiveO

unread,
Oct 7, 2023, 11:54:29 AM10/7/23
to golang-nuts
please simply follow the official installation instructions here, https://go.dev/doc/install, and select the Windows tab. This will set up everything correctly, avoiding the trouble you might have gotten into by installing individual bits and pieces into directories there they do not belong to (windows system, etc). Please note that there are multiple binaries required for a working toolchain.
Reply all
Reply to author
Forward
0 new messages