4 ms·
Well, first of all, I'd point to you http://arewewebyet.com/ http://arewewebyet.com/ ;) Different linking options are found here: http://static.rust-lang.org/d
by steveklabnik 12y ago
Well, first of all, I'd point to you http://arewewebyet.com/ http://arewewebyet.com/ ;)
Different linking options are found here: http://static.rust-lang.org/doc/master/rust.html#linkage http://static.rust-lang.org/doc/master/rust.html#linkage
Basically, as of right now, when you link statically, Rust will not build in glibc (and jemalloc, IIRC). So, you'll need to make sure that your glibc versions line up. My understanding is that glibc isn't able to be statically linked in without breaking things.
You can use `objdump -T` to see these dependencies. On my system, compiling 'Hello world,' I get symbols for glibc and gcc.
(Go gets away with this by reimplementing the world, rather than relying on glibc. The benefit is a wholly-contained binary, as you've seen. The downside is compatibility bugs, like https://code.google.com/p/go/issues/detail?id=1435 https://code.google.com/p/go/issues/detail?id=1435)