|
From: | Chris Marshall |
Subject: | Re: [Tinycc-devel] tcc compilation on MSYS2 |
Date: | Tue, 17 May 2016 16:51:22 -0400 |
--Chrisso it refers to the underlying windows locations: https://cygwin.com/ml/cygwin-cvs/2015-q2/msg00141.htmlHere is a link to the work done in cygwin to overlay the ucontext structureeip/ebp and rip/rbp could work:of rt_get_caller_pc() defined. I think an #ifdef for cygwin with the valuesmake goes well until it hits tccrun.c where there is no appropriate version@David: ./configure works out of the box.I don't mean exactly the same code but since cygwin is a flavor of posix system,it should be possible to support it the way that MacOSX, linux, and *bsd are.
make
gcc -o tccrun.o -c tccrun.c -DTCC_TARGET_X86_64 -I. -Wall -g -O0 -Wdeclaration-after-statement -Wno-deprecated-declarations -Wno-strict-aliasing -Wno-pointer-sign -Wno-sign-compare -Wno-unused-result -Wno-uninitialized -fno-strict-aliasing
tccrun.c: In function 'rt_get_caller_pc':
tccrun.c:544:33: error: 'mcontext_t {aka struct __mcontext}' has no member named 'gregs'
*paddr = uc->uc_mcontext.gregs[REG_RIP];
^
tccrun.c:544:40: error: 'REG_RIP' undeclared (first use in this function)
*paddr = uc->uc_mcontext.gregs[REG_RIP];
^
tccrun.c:544:40: note: each undeclared identifier is reported only once for each function it appears in
tccrun.c:555:29: error: 'mcontext_t {aka struct __mcontext}' has no member named 'gregs'
fp = uc->uc_mcontext.gregs[REG_RBP];
^
tccrun.c:555:36: error: 'REG_RBP' undeclared (first use in this function)
fp = uc->uc_mcontext.gregs[REG_RBP];On Mon, May 16, 2016 at 10:44 PM, David Mertens <address@hidden> wrote:_______________________________________________On Sat, May 14, 2016 at 3:27 PM, grischka <address@hidden> wrote:Chris Marshall wrote: ---
To be more specific, it should be possible to build the mingw version of tcc on cygwin (I don't know, haven't had time to try) but what I would like is the linux/unix version---if it builds on unix, it should be buildable on cygwin---as long as you don't look under the covers to find windows.
Probably you could do that. It is just that you'll find that
such (almost true) linux/unix version of tcc will produce
(entirely) true linux/unix programs. And these will not
run on windows, not even under cygwin.
-- gr
This is already the case on Macs, but we still go to some lengths to support it anyway. And, just as with Macs, even if the compiled executables cannot be run on Windows, the memory output can be run. Knowing Chris, I'm pretty sure this is what he is most interested in. :-)Chris, what happens if you run ./configure on Cygwin?David
Tinycc-devel mailing list
address@hidden
https://lists.nongnu.org/mailman/listinfo/tinycc-devel
[Prev in Thread] | Current Thread | [Next in Thread] |