When I use
user@ubuntu:/home$ clang -cc1 -triple mips64el-unknown-linux-gnu
-ccc-clang-archs mips64el -mabi=n64 a.c
I get a error:
error: unknown argument: '-ccc-clang-archs'
error: unknown argument: '-mabi=n64'
So I use
user@ubuntu:/home$ clang -ccc-host-triple mips64el-unknown-linux-gnu
-mabi=n64 a.c
I get s error like:
clang: warning: unknown platform, assuming -mfloat-abi=soft
In file included from a.c:1:
In file included from /usr/include/stdio.h:28:
In file included from /usr/include/features.h:388:
/usr/include/gnu/stubs.h:7:11: fatal error: 'gnu/stubs-32.h' file not found
# include <gnu/stubs-32.h>
You're using the "right" triplet. However:
1. Your system is unknown to driver (as shown in the warning)
2. You need to "teach" driver to look for paths to the includes for
your platform
> 1. Your system is unknown to driver (as shown in the warning)
I'm looking into it.
> 2. You need to "teach" driver to look for paths to the includes for
> your platform
I think what Anton means is you should modify clang source
to include path to system header.
Yes, Simon is looking into modifying the clang and llvm driver so that we can use it for end to end compilation.
We have our own driver that I wrote in python. That is what we use now.
It's very easy to add new hosts/ports to it whereas it seems to be an overly complex process to understand and make changes to the clang driver. In the end, many things are hard coded into the clang front end that should be configurable without making source changes and this was very disturbing to me. I didn't have the bandwidth to sort all of that out and we urgently needed a gcc compatible driver that could work with normal open source make files.
Please have him send the ideas you’re working on to the list. I wrote up a very long list of the directions I think it should go a while back in a conversation with the ARM folks (Mr. Malloy) as well.
I'm ahead of you actually Eric and already contacted Reed about it!
I fully intend to put forward a set of patches that implement what we discussed very shortly (in the next 2 weeks). I must admit that after our discussion I feel there was some miscommunication as to who had the action to actually implement the spec - it was only after a prolonged silence that I realised it was me!
For the list's benefit, the discussion was based around a set of patches I supplied a few months back to ease the cross compilation story and tablegen up the Clang driver to get rid of those horrible switch/cases and -ccc-host-triple. Myself and Eric agreed on pretty much everything, but I want to implement the patch much better so I'm writing from scratch.
I can forward the related emails if there is interest.
I'm ahead of you actually Eric and already contacted Reed about it!
Excellent.
I fully intend to put forward a set of patches that implement what we discussed very shortly (in the next 2 weeks). I must admit that after our discussion I feel there was some miscommunication as to who had the action to actually implement the spec - it was only after a prolonged silence that I realised it was me!
Sorry, I've ended up being terribly busy
For the list's benefit, the discussion was based around a set of patches I supplied a few months back to ease the cross compilation story and tablegen up the Clang driver to get rid of those horrible switch/cases and -ccc-host-triple. Myself and Eric agreed on pretty much everything, but I want to implement the patch much better so I'm writing from scratch.
Whee! If you can make it somewhat incremental and a series of patches that'd be awesome. Otherwise I'll still review it - it may just take longer