Ignore:
Timestamp:
05/03/2020 09:02:51 PM (4 years ago)
Author:
Pierre Labastie <pieere@…>
Branches:
10.0, 10.0-rc1, 10.1, 10.1-rc1, 11.0, 11.0-rc1, 11.0-rc2, 11.0-rc3, 11.1, 11.1-rc1, 11.2, 11.2-rc1, 11.3, 11.3-rc1, 12.0, 12.0-rc1, 12.1, 12.1-rc1, arm, bdubbs/gcc13, ml-11.0, multilib, renodr/libudev-from-systemd, s6-init, trunk, xry111/arm64, xry111/arm64-12.0, xry111/clfs-ng, xry111/lfs-next, xry111/loongarch, xry111/loongarch-12.0, xry111/loongarch-12.1, xry111/mips64el, xry111/pip3, xry111/rust-wip-20221008, xry111/update-glibc
Children:
a715dec
Parents:
9d719e2
Message:

Make the new book

git-svn-id: http://svn.linuxfromscratch.org/LFS/branches/cross-chap5@11831 4aa44e1e-78dd-0310-a6d2-fbcd4c07a689

File:
1 edited

Legend:

Unmodified
Added
Removed
  • chapter06/strippingagain.xml

    r9d719e2 refcb393  
    5757unset LIB save_lib save_usrlib</userinput></screen>
    5858
    59   <para>Before performing the stripping, take special care to ensure that
     59<!--  <para>Before performing the stripping, take special care to ensure that
    6060  none of the binaries that are about to be stripped are running:</para>
    6161
    6262<screen role="nodump"><userinput>exec /tools/bin/bash</userinput></screen>
    6363 
    64   <!--
    65   If
    66   unsure whether the user entered chroot with the command given in
    67   <xref linkend="ch-system-chroot" role=","/> first use the version
    68   of bash we created in
    69   chroot:</para>
     64  <para>Now the binaries and libraries can be safely stripped:</para>
     65-->
     66  <para>Now the binaries and libraries can be stripped:</para>
     67<screen><userinput>find /usr/lib -type f -name \*.a \
     68   -exec strip --strip-debug {} ';'
    7069
    71 <screen role="nodump"><userinput>logout</userinput></screen>
     70find /lib /usr/lib -type f -name \*.so* ! -name \*dbg \
     71   -exec strip --strip-unneeded {} ';'
    7272
    73   <para>Then reenter it with:</para>
    74 
    75 <screen role="nodump"><userinput>chroot $LFS /tools/bin/env -i          \
    76     HOME=/root TERM=$TERM              \
    77     PS1='(lfs chroot) \u:\w\$ '        \
    78     PATH=/bin:/usr/bin:/sbin:/usr/sbin \
    79     /tools/bin/bash - -login</userinput></screen>-->
    80 
    81   <para>Now the binaries and libraries can be safely stripped:</para>
    82 
    83 <screen><userinput>/tools/bin/find /usr/lib -type f -name \*.a \
    84    -exec /tools/bin/strip --strip-debug {} ';'
    85 
    86 /tools/bin/find /lib /usr/lib -type f \( -name \*.so* -a ! -name \*dbg \) \
    87    -exec /tools/bin/strip --strip-unneeded {} ';'
    88 
    89 /tools/bin/find /{bin,sbin} /usr/{bin,sbin,libexec} -type f \
    90     -exec /tools/bin/strip --strip-all {} ';'</userinput></screen>
     73find /{bin,sbin} /usr/{bin,sbin,libexec} -type f \
     74    -exec strip --strip-all {} ';'</userinput></screen>
    9175
    9276  <para>A large number of files will be reported as having their file
Note: See TracChangeset for help on using the changeset viewer.