← Back to team overview

cross-toolchain-base-devs team mailing list archive

Bug#883189: cross-toolchain-base: dpkg-cross correct libc.so file for mips ports

 

Some problem in the previous patch
1:  we have mipsel-* vs mipsisa32r6el-*, I was some confused by it.
2. we have o32 ld.so.1 in /usr/mipsel-linxu-gnu/lib directly, not in o32.


On Thu, Nov 30, 2017 at 9:42 PM, James Cowgill <jcowgill@xxxxxxxxxx> wrote:
> Hi,
>
> On 30/11/17 13:33, YunQiang Su wrote:
>> Package: src:cross-toolchain-base
>> Version: 20
>> X-Debbugs-CC: helmut@xxxxxxxxxx, jcowgill@xxxxxxxxxx
>>
>>
>> Hi, in the previous version, we dropped
>>     /usr/$(multiarch)/lib/ld.so.1
>> for N32 and N64, while it seems libc.so hardcode this filename,
>> Then, let's change it.
>>
>> This will fix n32 and n64 cross toolchains.
>
> YunQiang, you still haven't told me why we need to do any of these
> dpkg-cross changes (I'm referring to #881687 as well as this bug). What
> exactly was the problem that lead you to submitting #881687? I can't see
> the bug you are trying to solve.
>
> Also, should this bug have been submitted against dpkg-cross?
>
> James
>



-- 
YunQiang Su
--- cross-toolchain-base-20/debian/dpkg-cross	2017-11-20 06:01:44.000000000 +0800
+++ dpkg-cross	2017-11-30 21:24:07.376939568 +0800
@@ -632,6 +632,13 @@
 		}
 		while (<FROM>) {
 			if ($multiarch) {
+				if ($multiarch =~ m/mips(isa)?64.*-linux.*-gnuabi64.*/){
+					s:(^|[^-\w/])(/usr)?/lib/${multiarch}ld.so.1:$1$crosslib64/ld.so.1:g;
+				}elsif ($multiarch =~ m/^mips(isa)?64.*-linux.*-gnuabin32.*/){
+					s:(^|[^-\w/])(/usr)?/lib/${multiarch}ld.so.1:$1$crosslibn32/ld.so.1:g;
+				}elsif ($multiarch =~ m/^mips(isa32)?.*-linux.*-gnu.*/){
+					s:(^|[^-\w/])(/usr)?/lib/${multiarch}ld.so.1:$1$crosslib/ld.so.1:g;
+				}
 				s:(^|[^-\w/])(/usr)?/lib/$multiarch:$1$crosslib/:g;
 				s:(^|[^-\w/])(/usr)?/lib32/$multiarch:$1$crosslib32/:g;
 				s:(^|[^-\w/])(/usr)?/lib64/$multiarch:$1$crosslib64/:g;
@@ -1028,7 +1035,7 @@
 
 		# 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$/);
+		next if ($multiarch =~ m/^mips(isa)?64/ && $_ =~ m/lib\/ld.so.1$/);
 
 		# m/lib\/ld.so.1$/);
 		# skip links to private modules and plugins that are not

Follow ups

References