Thomas Preud'homme wrote:
Here is a first version of the patch. Granted, detecting multiarch at configure time and specifying the triplet in tcc.h is better but the result is quite ugly for now.

What about adding a small C file that we compile at configure
time and can run with various arguments.  Such as:

int main(int argc, char **argv)
{
    switch(argc == 1 ? argv[1][0] : 0) {
        case 'v': <print __GNUC__>
        case 'm': <print __GNUC_MINOR__>
        case 'a': <print [MULTI_]ARCH_TRIPLE>
        case 'e': <print endian-ness>
        ...

and use as:
        gcc_major=`our-config-tool v`
etc...

That way configure would look better without that inline C code.

--- grischka


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

Reply via email to