tinycc-devel
[Top][All Lists]
Advanced

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

Re: [Tinycc-devel] TCC fails to build on FreeBSD/amd64


From: Carlos Jacobo Puga Medina
Subject: Re: [Tinycc-devel] TCC fails to build on FreeBSD/amd64
Date: Fri, 24 Jul 2015 01:50:20 +0200

El mié, 22-07-2015 a las 03:25 +0200, Carlos Jacobo Puga Medina
escribió:
> El mar, 21-07-2015 a las 18:47 +0200, Carlos Jacobo Puga Medina
> escribió:
> > El mar, 21-07-2015 a las 14:14 +0200, Carlos Jacobo Puga Medina
> > escribió:
> > > El mar, 21-07-2015 a las 08:34 +0100, Edmund Grimley Evans 
> > > escribió:
> > > > > ../tcc -B.. -c bcheck.c -o x86_64/bcheck.o -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 -fPIC -DTCC_TARGET_X86_64
> > > > > In file included from bcheck.c:21:
> > > > > /usr/include/stdio.h:63: error: ';' expected (got "va_list")
> > > > > Makefile:116: recipe for target 'x86_64/bcheck.o' failed
> > > > > gmake[1]: *** [x86_64/bcheck.o] Error 1
> > > > > gmake[1]: Leaving directory 
> > > > > '/usr/home/cjpm/github/tinycc/lib'
> > > > > Makefile:259: recipe for target 'libtcc1.a' failed
> > > > > gmake: *** [libtcc1.a] Error 2
> > > > > 
> > > > > Any thoughts about how to handle this?
> > > > 
> > > > Take a look at the preprocessed source, bcheck.i, generated by:
> > > > 
> > > > ../tcc -B.. -E bcheck.c -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 
> > > > -fPIC
> > > > -DTCC_TARGET_X86_64 -o bcheck.i
> > > 
> > > Yes, I checked it.
> > > 
> > > It builds fine on i386, but I'm not sure why it spits out this 
> > > error 
> > > on
> > > amd64:
> > > 
> > > In file included from bcheck.c:22:
> > > In file included from /usr/include/stdarg.h:6:
> > > /usr/include/x86/stdarg.h:74: error: #error this file needs to be
> > > ported to your compiler
> > > 
> > I tried on FreeBSD/i386 and it also fails to compile properly with 
> > the
> > above error.
> > 
> > Note that last time that TCC worked like a charm was on FreeBSD
> > -9.1/i386 release.
> > 
> Finally I compiled TCC on amd64
> 
> tcc version 0.9.26 (x86-64)
> install: /usr/local/lib/tcc/
> crt:
>   /usr/lib
> libraries:
>   /usr/lib
>   /lib
>   /usr/local/lib
> include:
>   /usr/local/include
>   /usr/include
>   /usr/local/lib/tcc/include
> elfinterp:
>   /libexec/ld-elf.so.1
> 
> Trying to compile hello.c
> % tcc -o hello hello.c
> In file included from hello.c:1:
> /usr/include/stdio.h:63: error: ';' expected (got "va_list")
> 

hello.c
=======
extern int printf(char *, ...);
int main(){
        printf("hello, world!\n);
        return 0;
}
=======

% tcc -run hello.c
hello, world!

It seems that stdio.h is the culprit.




reply via email to

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