On Sun, Jan 8, 2012 at 6:15 AM, Stuart Hughes
<address@hidden> wrote:
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 '
- address@hidden = grep { `file $_` =~ m,ASCII C program text, } @ARGV;
+ address@hidden = 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
>>
>
>
>