On Wed, 30 Mar 2016 at 13:27 Lihe Wang <wanglihe.program...@gmail.com> wrote:
> #~ rustc hello.rs > error: linking with `cc` failed: exit code: 1 > note: "cc" "-Wl,--as-needed" "-m64" "-L" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib" "hello.0.o" "-o" "hello" > "-Wl,--gc-sections" "-pie" "-nodefaultlibs" "-L" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib" "-Wl,-Bstatic" > "-Wl,-Bdynamic" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libstd-6a154fe0.rlib" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcollections-6a154fe0.rlib" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/librustc_unicode-6a154fe0.rlib" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/librand-6a154fe0.rlib" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc-6a154fe0.rlib" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc_jemalloc-6a154fe0.rlib" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/liblibc-6a154fe0.rlib" > "/usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/libcore-6a154fe0.rlib" "-l" > "dl" "-l" "pthread" "-l" "gcc_s" "-l" "pthread" "-l" "c" "-l" "m" "-l" "rt" > "-l" "compiler-rt" > note: /usr/bin/ld: > /usr/lib/rustlib/x86_64-unknown-linux-gnu/lib/liballoc_jemalloc-6a154fe0.rlib(jemalloc.pic.o): > unrecognized relocation (0x2a) in section `.text.malloc_conf_init' > /usr/bin/ld: final link failed: Bad value > collect2: error: ld returned 1 exit status > It looks like this is a change in recent binutils (see discussion in Bug#808205) - which I _think_ means our static libraries (librust-std-dev) need to depend on binutils >= 2.25.90.20151209-1. I note in the glibc-dev case, however, the decision was "I therefore don't think we need to fix that at the glibc level. Either we just ignore the problem saying we don't support partial upgrades or we try to find a global way to fix the dependencies for all libraries." Lihe: The short version for you is if you're trying to run a mixed stable/testing system(*), then you will also need to install binutils from testing. (*) rather than rebuild rustc.deb from source for stable. If we had enough man-power, it would probably make sense for us to maintain a rustc.deb for stable-backports. - Gus