[strace/strace] Compiling with tcc (TinyC Compiler) (#132)

esyr notifications at github.com
Mon Apr 20 06:20:25 UTC 2020


On Mon, Apr 20, 2020 at 8:07 AM James Mills <notifications at github.com> wrote:
>
> Okay I added this to the. build and now I get the original error I was trying to show here before:
>
> mv native_printer_defs.h-t native_printer_defs.h
> tcc -E -P -DHAVE_CONFIG_H    -I./linux/x86_64 -I./linux/x86_64 -I./linux -I./linux -I. -I.  -include config.h linux/x86_64/syscallent.h -o syscallent.i
> tcc: error: unrecognized file type

It seems that tcc treats the input file as binary[1][2], and it does
so because file type detection[3] (which is in place for some reason)
doesn't treat *.h as a C source. Since the command in question
explicitly has the -E option, I'd say it's a bug on tcc's part.

[1] https://repo.or.cz/tinycc.git/blob/HEAD:/libtcc.c#l1055
[2] https://repo.or.cz/tinycc.git/blob/HEAD:/libtcc.c#l1101
[3] https://repo.or.cz/tinycc.git/blob/HEAD:/libtcc.c#l1126

-- 
Eugene Syromyatnikov
mailto:evgsyr at gmail.com
xmpp:esyr at jabber.{ru|org}


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/strace/strace/issues/132#issuecomment-616335726
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.strace.io/pipermail/strace-devel/attachments/20200419/3a48aa7b/attachment.html>


More information about the Strace-devel mailing list