Ken Moffat wrote:
On Tue, May 02, 2017 at 05:51:49PM +0100, Ken Moffat wrote:
On Tue, May 02, 2017 at 12:08:21AM -0500, Bruce Dubbs wrote:
Are you sure you escaped everything? I know you said you copy/pasted the
line but the (-name entry above is suspicious.
I copied it into my script, but it sounds like insufficient
escaping: I can remember having to add extra backslashes to sed
commands in the past when I put them in scripts. I'll check
later. Thanks.
It was the first line of command you pointed to, but the problem is
the lack of spaces around ( and ). First I changed it to
/tools/bin/find /lib /usr/lib -type f \( -name \*.so* -a ! -name
\*dbg\) \
but then I got
/tools/bin/strip:/usr/lib/libm.a: File format not recognized
/tools/bin/find: invalid expression; I was expecting to find a ')'
somewhere but did not see one.
After I changed it to -name \*dbg \) it got through the shared
objects.
Now, it segfaults in ld-2.25.so while stripping the programs.
I'm surprised that the first part ran for you.
I'll add the spaces.
Note that we can also use
/tools/bin/find /lib /usr/lib -type f \
'(' -name \*.so* -a ! -name \*dbg ')'
or
/tools/bin/find /lib /usr/lib -type f \
'(' -name '*.so*' -a ! -name '*dbg' ')'
Did you get the segfault in chroot?
For non chroot, we could use:
find /lib /usr/lib -type f \
'(' -name \*.so* -a ! -name \*dbg -a ! -name ld-2.25.so ')'
-- Bruce
--
http://lists.linuxfromscratch.org/listinfo/lfs-dev
FAQ: http://www.linuxfromscratch.org/faq/
Unsubscribe: See the above information page