On 2017-11-20 21:42, Helmut Grohne wrote: > Package: libc6-dev-mips64el-cross > Version: 20 > Severity: serious > User: helm...@debian.org > Usertags: rebootstrap > > I was trying to use gcc-mips64el-linux-gnuabi64 to link a trivial > executable: > > $ echo 'int main(){return 0;}' | mips64el-linux-gnuabi64-gcc -x c - -o > /dev/null > > With libc6-dev:mips64el installed, this just works. As soon as I install > libc6-dev-mips64el-cross, it fails though: > > /usr/lib/gcc-cross/mips64el-linux-gnuabi64/7/../../../../mips64el-linux-gnuabi64/bin/ld: > cannot find /usr/mips64el-linux-gnuabi64/lib/ld.so.1 > collect2: error: ld returned 1 exit status > > This renders libc6-dev-mips64el-cross pretty much useless.
This is due to the following change, introduced in cross-toolchain-base-20: diff -Nru cross-toolchain-base-19/debian/dpkg-cross cross-toolchain-base-20/debian/dpkg-cross --- cross-toolchain-base-19/debian/dpkg-cross 2016-01-21 08:48:01.000000000 +0000 +++ cross-toolchain-base-20/debian/dpkg-cross 2017-11-19 22:01:44.000000000 +0000 @@ -1026,6 +1026,11 @@ # Skip links that are going to point to themselves next if ($lv eq $_); + # skip /usr/$(multiarch)/lib/ld.so.1 for mips n32 and 64. + # their ld.so.1 should be in lib32 and lib64. + next if ($multiarch =~ m/^mips[n32,64]/ && $_ =~ m/lib\/ld.so.1$/); + + # m/lib\/ld.so.1$/); # skip links to private modules and plugins that are not # useful or packaged in the -cross package, basically anything # in a directory beneath /usr/lib/. See #499292 I don't really see the point of this change, and why it would be different the s390x cross-libc for example, which has ld64.so.1 in /usr/s390x-linux-gnu/lib/ while the rtld directory is /lib64. Removing this file has the same effect: | $ echo 'int main(){return 0;}' | s390x-linux-gnu-gcc -x c - -o /dev/null | $ sudo rm /usr/s390x-linux-gnu/lib/ld64.so.1 | $ echo 'int main(){return 0;}' | s390x-linux-gnu-gcc -x c - -o /dev/null | /usr/lib/gcc-cross/s390x-linux-gnu/7/../../../../s390x-linux-gnu/bin/ld: cannot find /usr/s390x-linux-gnu/lib/ld64.so.1 | collect2: error: ld returned 1 exit status It therefore looks like to me that this hunk has to be reverted. Aurelien -- Aurelien Jarno GPG: 4096R/1DDD8C9B aurel...@aurel32.net http://www.aurel32.net