What setup do you use for your shells regarding the Go variables like
GOOS? Do you have a bash function to toggle between linux and akaros
or something along those lines?
I'm in the market for updating my stuff, and figured I'd ask on the list
in case others are curious.
https://github.com/klueska/akaros-devel-docker/blob/master/docker/home/.bash_akaros
With these variables in place, you will always use the go-akaros
toolchain for any go development you do, but the toolchain works for
compiling both akaros and linux code, depending on your settings for
GOOS and GOARCH. I typically just export these manually for akaros
(GOOS=akaros, GOARCH=amd64) and then unset them if I want to build for
linux (which is rare, but I leave this as my default because I like to
explicitly set these variables myself). I could see a use case for
also setting the following bash functions though:
function go-akaros-toolchain() {
# sets the go command to work with the go-akaros toolchain
}
function go-system-toolchain() {
# sets the go command to work with the system installed toolchain
}
function go-akaros-export() {
# Export the GOOS and GOARCH variables for akaros
}
function go-system-export() {
# unset GOOS and GOARCH so the system defaults will be used
}
I can put these together relatively soon if it will help.
Kevin
--
~Kevin