tinycc-devel
[Top][All Lists]
Advanced

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

Re: [Tinycc-devel] test failure on Linux


From: Thomas Preud'homme
Subject: Re: [Tinycc-devel] test failure on Linux
Date: Wed, 13 Feb 2013 22:15:22 +0100
User-agent: KMail/1.13.7 (Linux/3.2.0-4-amd64; KDE/4.8.4; x86_64; ; )

Le mercredi 13 février 2013 21:29:04, grischka a écrit :
> Thomas Preud'homme wrote:
> > I suggest we include it and then release tomorrow once people checked I
> > didn't break something with my last patches.
> > 
> > +if ! $cc -o print_env_info print_env_info.c 2>/dev/null ; then
> > 
> >      echo big/little test failed
> 
> Actually maybe:
>         echo "You don't have an usable compiler"
> 
> If we cannot compile that file then how could we compile TCC.

Sure.

> 
> > print_env_info
> 
> I'd suggest something "config-...", config-info/print/env or some such.
> That it sorts near to configure in directory listing.

Ok.

> 
> > if test -n "$multiarch_triplet" ; then
> > 
> >   echo "#define CONFIG_MULTIARCHDIR \"$multiarch_triplet\"" >> $TMPH
> > 
> > fi
> > if test -n "$lddir" ; then
> > 
> >   echo "#define CONFIG_LDDIR \"$lddir\"" >> $TMPH
> > 
> > fi
> 
> If #defined unconditionally overriding on the compiler command line
> doesn't work any more.  Maybe you can use configure:print_var2().

Ok, I didn't thought about that use case.

> 
> > #ifndef CONFIG_LDDIR
> > -# ifdef CONFIG_MULTIARCHDIR
> > -#  define CONFIG_LDDIR "lib/" CONFIG_MULTIARCHDIR
> > -# else
> > -#  define CONFIG_LDDIR "lib"
> > -# endif
> > -#endif
> 
> CONFIG_LDDIR is now undefined in tcc.  Leaving "lib" as default
> cannot hurt IMO (even if it's just to keep the section readable).

I thought it was useless since it's always defined in configure. But ok, why 
not.

> 
> > for opt do
> > 
> >   eval opt=$opt
> >   case "$opt" in
> 
> The eval messes up with ./configure --extra-cflags="-Os -Wall"
> 
> >  libc_dir="$(ldd ./print_env_info | grep libc.so | sed
> >  's|[^/]*/\(.*/\)[^/]*|\1|')"
> 
> ldd doesn't work on my MSYS. I cannot complain because I just have
> the downstripped version for git, but maybe you can use
>       gcc -print-file-name=crt1.o
> or such.

Indeed, for now we already need gcc for compiling a few files in tcc but that 
would be nice to be able to compile only with cc. Isn't there something 
similar with the MSYS tools?

> 
> Thanks,
> 
> --- grischka

Best regards,

Thomas

Attachment: signature.asc
Description: This is a digitally signed message part.


reply via email to

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