Bug#649094: fix 64bit biarch linker scripts

2012-12-19 Thread Legion Fox
Thanks for your help !
I will try it and response on my question!
:- )


2012/12/18 Matthias Klose d...@ubuntu.com

 tags 649094 + patch
 thanks

 at least for 64bit biarch

 dpkg-cross (2.6.9ubuntu2) raring; urgency=low

   * Handle biarch linker scripts - LP: #1090800

  -- Marcin Juszkiewicz marcin.juszkiew...@linaro.org   Mon, 17 Dec 2012
 15:01:29 +0100




Bug#649094: fix 64bit biarch linker scripts

2012-12-17 Thread Matthias Klose
tags 649094 + patch
thanks

at least for 64bit biarch

dpkg-cross (2.6.9ubuntu2) raring; urgency=low

  * Handle biarch linker scripts - LP: #1090800

 -- Marcin Juszkiewicz marcin.juszkiew...@linaro.org   Mon, 17 Dec 2012
15:01:29 +0100

--- dpkg-cross  2012-08-21 11:01:32.0 +0200
+++ /usr/bin/dpkg-cross 2012-12-17 14:07:54.848879084 +0100
@@ -628,6 +628,8 @@
}
while (FROM) {
s:(^|[^-\w/])(/usr)?/lib/$multiarch:$1$crosslib/:g;
+   s:(^|[^-\w/])(/usr)?/lib64/$multiarch:$1$crosslib64/:g;
+   s:(^|[^-\w/])(/usr)?/lib64/:$1$crosslib64/:g;
print TO;
}
close(FROM);
@@ -798,6 +800,13 @@
} elsif ((m:^/emul/ia32-linux/usr/lib/([^/]+\.[ao])$:)) {
# regular .a or .o file under /emul/ia32-linux/ for 
#463588
link_file($src$_, $dst$crosslib32/$1) or goto fail;
+   } elsif (m:^(/usr)?/lib64/($multiarch)?([^/]+\.so[^/]*)$:) {
+   # regular .so* file under /lib64, /usr/lib64, 
/lib64/triplet, /usr/lib64/triplet
+   if (is_ldscript($src$_)) {
+   fix_ldscript($src$_, $dst$crosslib64/$3) or 
goto fail;
+   } else {
+   link_file($src$_, $dst$crosslib64/$3) or 
goto fail;
+   }
} elsif (m:^(/usr)?/lib/($multiarch)?([^/]+\.so[^/]*)$:) {
# regular .so* file under /lib, /usr/lib, 
/lib/triplet, /usr/lib/triplet
if (is_ldscript($src$_)) {