tinycc-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Tinycc-devel] tcc compilation on MSYS2


From: Chris Marshall
Subject: Re: [Tinycc-devel] tcc compilation on MSYS2
Date: Thu, 19 May 2016 10:33:28 -0400

Thanks for the help.

I've got tcc building but the bcheck.c compile is failing
when the stdlib.h is pulled in.  My next step is to try
the same with the latest tcc git.  I'm not sure what the
best way to proceed woud be.  The top level gcc build
can correctly (for cygwin) process the various system
include files.  It is only when tcc tries to process those
same files that the problems start.  Maybe there is a
wayto use the gcc step to generate a tcc version of the
include files.


--Chris

On Wed, May 18, 2016 at 1:55 AM, avih <address@hidden> wrote:
Also, with this patch, I believe that it will prevent enabling bcheck when creating a cross compiler tcc from cygwin for a platform which does support bcheck, since I _think_ this will set tcc to define __CYGWIN__ when compiling [cross] tcc itself.

I might be wrong here though, I didn't check much of the surrounding code.


On Wednesday, May 18, 2016 7:31 AM, Sergey Korshunoff <address@hidden> wrote:


> However, since the
> preprocessing is being done by tcc the __CYGWIN__ macro is not defined
> and I can't figure out where that would go.
iff --git a/libtcc.c b/libtcc.c
index 7d9a058..a5ec7f3 100644

--- a/libtcc.c
+++ b/libtcc.c
@@ -1170,6 +1170,8 @@ LIBTCCAPI TCCState *tcc_new(void)
# ifdef TCC_TARGET_X86_64
    tcc_define_symbol(s, "_WIN64", NULL);
# endif
+#elif defined(__CYGWIN__)

+    tcc_define_symbol(s, "__CYGWIN__", NULL);
#else
    tcc_define_symbol(s, "__unix__", NULL);
    tcc_define_symbol(s, "__unix", NULL);


_______________________________________________
Tinycc-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/tinycc-devel



_______________________________________________
Tinycc-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/tinycc-devel



reply via email to

[Prev in Thread] Current Thread [Next in Thread]