Hacker News new | past | comments | ask | show | jobs | submit login

perhaps Go could have been a good solution for simple, cross-compiled code.





from what i looked at, go was a bit more complicated than rust for cross compilation. but it was still a lot less complicated than sorting it out for python. dunno. was at least two years since i looked at it, but i remember rust coming out on top in my mind.

unfortunately the same maintenance issue applied -- it was a python / R shop so no-one else would have been able to change the code once i left.


AFAIK Go has one of, if not the easiest cross compilation stories.

This is all it takes to build a linux arm64 binary:

  env GOOS=linux GOARCH=arm64 go build your_program
You can even run that from Windows and it will just work.

This is how you list all possible targets:

  go tool dist list
If you want to generate binaries for many linux distros, you can even use a simple bash script:

  #!/usr/bin/bash
  archs=(amd64 arm64 ppc64le ppc64 s390x)

  for arch in ${archs[@]}
  do
    env GOOS=linux GOARCH=${arch} go build -o your_program_${arch}
  done

thats definitely not the commands the guide i looked at had lol

looks on par with rust then. go is the next one for me to dive into when im doing fiddling with rust audio stuff.

regardless, wouldn’t have worked at last job as no-one knew go either. would have been easier probably to get someone in, but i spent a year trying to get one new hire to no avail, so doubtful.


fair enough

Asterisk: As long as it is pure Go code.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: