4 ms·
I have the same experiences with Go regarding xplat. I was particularly amazed that I could trivially cross compile by simply setting the GOOS and GOARCH env va
by weberc2 9y ago
I have the same experiences with Go regarding xplat. I was particularly amazed that I could trivially cross compile by simply setting the GOOS and GOARCH env vars to the correct operating system and CPU architecture and then running `go build`.
EDIT: Curious why people are downvoting this. Is it really so taboo to suggest that Go could be nearly as pleasant as Rust at something? Do I really need to roll out my Rust fanboy creds every time I participate in a thread on the language?
- vvanders 9y agohttps://crates.io/crates/gcc https://crates.io/crates/gcc is even more amazing, it will cross-compile your C dependencies(assuming you have the right compilers setup, which is mostly handled already via rustup or base install). For Android all I had to do was point it to the NDK(for both Rust and the crate) and I got all my C dependencies for basically free. Anyone who's had to work with the NDK knows how nice that is. That's also with zero changes to my build script/code/ifdefs/whatever.
- mastax 9y agoI upvoted you, but perhaps bringing up Go (or Nim, etc.) In every Rust thread is as annoying as bringing up Rust in every Go thread. This article is about comparing languages more or less, though.
- weberc2 9y agoThanks; I used Go because it was specifically referenced in the article. I don’t personally mind people bringing up Rust in Go threads; I do mind pretending there aren’t trade offs, however.