Re:Go and Assembly
by car54whereareu on Thursday February 07, 2013 @12:54PM
(#5183497)
Actually if you import "net" go links to libc.so and some others.
[ Parent
| on HN ]
Re:Go and Assembly
by stock_toaster on Thursday February 07, 2013 @01:09PM
(#5183581)
I believe "net" does so for native dns lookups. You can disable that by building go with 'CGO_ENABLED=0', if desired.
That is correct. It uses libc for resolving names because systems might be configured to use NIS or LDAP before DNS. With cgo disabled it defaults to using its own DNS resolver and resolv.conf.
Re:Go and Assembly
by papsosouid on Thursday February 07, 2013 @01:33PM
(#5183707)
Ah, if the original bulletpoints for go are wrong then ghc may be more comparable than I figured. Can you statically link go binaries? As in, if I am using a go postgresql binding, can I build a binary with libpq (the postgresql C library) linked in statically, so it can be deployed on servers with no postgresql libraries installed?