:: [DNG] gcc can link garbage into an …
Página Principal
Delete this message
Reply to this message
Autor: Edward Bartolo
Data:  
Para: dng
Assunto: [DNG] gcc can link garbage into an executable.
Hi,

While dissecting the sysvinits (/sbin/init) internals I found that gcc
can link garbage into an executable file. Attempting to run the
resultant garbage results in unknown executable format or something
similar.

I used the -c directive directly on the source code. The command is this:
gcc -ansi -O2 -W -Wall -D_GNU_SOURCE -c startos.init.c -o startos.init

Edward