ltib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Ltib] skipping incompatible /lib/libc.so.6


From: Stuart Hughes
Subject: Re: [Ltib] skipping incompatible /lib/libc.so.6
Date: Sun, 08 Jan 2012 11:15:44 +0000
User-agent: Mozilla/5.0 (X11; Linux i686; rv:8.0) Gecko/20111124 Thunderbird/8.0

Hi James,

This is what I ended up checking-in to CVS for base_libs.spec and
glibc.spec (not tested, I rarely build this).

 # remove absolute paths from text search files (if they exist)
 perl -w -e '
-    @ARGV = grep { `file $_` =~ m,ASCII C program text, } @ARGV;
+    @ARGV = grep { `file $_` =~ m,ASCII\s+.*text, } @ARGV;


Regards, Stuart

On 03/01/12 14:38, James Newell wrote:
> 
> On Tue, Jan 3, 2012 at 3:44 AM, Stuart Hughes <address@hidden
> <mailto:address@hidden>> wrote:
> 
>     __
>     Hi Jim,
> 
>     base_libs.spec is the one you probably need to get fixed (it's rare
>     to actually build glibc, the preference is to use the components out
>     of the toolchain).
> 
>     Anyhow, can you try changing the expression to:
> 
> Hi Staurt,
> 
> Yes.  That works, but I used just 'text' instead in my patch.  The test
> is really just a safety check to make sure its a text file.  Only a hand
> full of files are explicitly being manipulated in each of the two spec
> file.  A broader check would make it a bit more future proof in case
> some one decides to tweak the magic file description again.  
> Regards,
> Jim
>  
> 
>     perl -w -e '
>         @ARGV = grep { `file $_` =~ m,ASCII (?:C program|English) text,
>     } @ARGV;
>         exit(0) unless @ARGV;
>         $^I = ".bak";
>         while(<>) {
>             s,[\S/]+/,,g if m,^GROUP,;
>             print;
>         }
> 
>     Let me know if this works.
> 
>     Regards, Stuart
> 
>     On 02/01/12 20:09, James Newell wrote:
>>     PS.  I forgot it's in the dist/lfs-5.1/base_libs/base_libs.spec
>>     file too.
>>
>>     On Mon, Jan 2, 2012 at 2:53 PM, James Newell <address@hidden
>>     <mailto:address@hidden>> wrote:
>>
>>         I started to have this issue when I moved from RedHat 4.x to
>>         Fedora 16.  I found a couple different archived emails about
>>         it but they never seemed to track down the real issue.  If it
>>         was resolved, then please forgive the email.
>>
>>         /nim2/ltib/rootfs/lib:/home/jnewell/work/nim2/ltib/rootfs/usr/lib
>>         -Wall hello.c -o hello
>>         
>> /home/opt/sdk/cs/ppc-gnu-2010q4/bin/../lib/gcc/powerpc-linux-gnu/4.5.1/../../../../powerpc-linux-gnu/bin/ld:
>>         skipping incompatible /lib/libc.so.6 when searching for
>>         /lib/libc.so.6
>>         
>> /home/opt/sdk/cs/ppc-gnu-2010q4/bin/../lib/gcc/powerpc-linux-gnu/4.5.1/../../../../powerpc-linux-gnu/bin/ld:
>>         cannot find /lib/libc.so.6
>>         
>> /home/opt/sdk/cs/ppc-gnu-2010q4/bin/../lib/gcc/powerpc-linux-gnu/4.5.1/../../../../powerpc-linux-gnu/bin/ld:
>>         skipping incompatible /usr/lib/libc_nonshared.a when searching
>>         for /usr/lib/libc_nonshared.a
>>         
>> /home/opt/sdk/cs/ppc-gnu-2010q4/bin/../lib/gcc/powerpc-linux-gnu/4.5.1/../../../../powerpc-linux-gnu/bin/ld:
>>         cannot find /usr/lib/libc_nonshared.a
>>         
>> /home/opt/sdk/cs/ppc-gnu-2010q4/bin/../lib/gcc/powerpc-linux-gnu/4.5.1/../../../../powerpc-linux-gnu/bin/ld:
>>         cannot find /lib/ld.so.1
>>         collect2: ld returned 1 exit status
>>
>>         I tracked it to dist/lfs-5.1/glibc/glibc.spec:
>>         perl -w -e '
>>             @ARGV = grep { `file $_` =~ m,ASCII C program text, } @ARGV;
>>             exit(0) unless @ARGV;
>>             $^I = ".bak";
>>             while(<>) {
>>                 s,[\S/]+/,,g if m,^GROUP,;
>>                 print;
>>             }
>>         ...
>>
>>         The 'file' command returns different results for these platforms:
>>         RedHat Enterprise 4.x:  $ file rootfs/usr/lib/libpthread.so  
>>         rootfs/usr/lib/libpthread.so: ASCII C program text
>>         Fedora 16: $ file rootfs/usr/lib/libpthread.so 
>>         rootfs/usr/lib/libpthread.so: ASCII English text
>>
>>         The above code therefore doesn't match on the Fedora 16 and
>>         never removes any of the offending absolute paths from the
>>         text search files.
>>
>>         Regards,
>>
>>         Jim
>>
> 
> 
> 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]