Don't use dummy.c for glibc sanity check in chap 5

It seems glibc creates dummy.c for its own use. This leaves some
dummy.xxx files in the directory, that may lead some users to think that
the directory is not properly cleaned up after the test (I did :)

So use a pipe so that only a.out is created
This commit is contained in:
Pierre Labastie 2022-08-25 09:24:58 +02:00
parent feed7fea36
commit b3f157c685

View File

@ -195,9 +195,8 @@ cd build</userinput></screen>
functions (compiling and linking) of the new toolchain are working as
expected. To perform a sanity check, run the following commands:</para>
<screen><userinput>echo 'int main(){}' &gt; dummy.c
$LFS_TGT-gcc dummy.c
readelf -l a.out | grep '/ld-linux'</userinput></screen>
<screen><userinput>echo 'int main(){}' | gcc -xc -
readelf -l a.out | grep ld-linux</userinput></screen>
<para>If everything is working correctly, there should be no errors,
and the output of the last command will be of the form:</para>
@ -212,9 +211,9 @@ readelf -l a.out | grep '/ld-linux'</userinput></screen>
where the problem is and correct it. This issue must be resolved before
continuing on.</para>
<para>Once all is well, clean up the test files:</para>
<para>Once all is well, clean up the test file:</para>
<screen><userinput>rm -v dummy.c a.out</userinput></screen>
<screen><userinput>rm -v a.out</userinput></screen>
</caution>