This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Multiple cc's, one gcc -- is it possible?
- From: Richard Biener <richard dot guenther at gmail dot com>
- To: Konstantin Vladimirov <konstantin dot vladimirov at gmail dot com>
- Cc: GCC Development <gcc at gcc dot gnu dot org>
- Date: Thu, 17 Apr 2014 13:11:35 +0200
- Subject: Re: Multiple cc's, one gcc -- is it possible?
- Authentication-results: sourceware.org; auth=none
- References: <CADn89gTD1QXoJa9crRpquhyv6x425Wcz7BA3XHvEsnhdP5XZ8w at mail dot gmail dot com>
On Thu, Apr 17, 2014 at 12:39 PM, Konstantin Vladimirov
<konstantin.vladimirov@gmail.com> wrote:
> Hi,
>
> I want to support, say arch1 and arch2 in custom gcc in the way
>
> gcc -march1 test.c
>
> calls
>
> ${INSTALL}/libexec/gcc/arch1/4.8.2/cc1
>
> and
>
> gcc -march2 test.c
>
> calls
>
> ${INSTALL}/libexec/gcc/arch2/4.8.2/cc1
>
> Are there any way to do it? Maybe not exactly as I outlined, but the
> whole idea is clear, I think. I looked through multilib and multiarch
> options, but it seems to be nothing like this.
>
> I may correct anything in build system and arch1 and arch2 backends,
> but I don't want to change any core gcc code, say inside gcc.c. Is it
> possible? Are there examples how is it possible?
Only via -B. We used to have -V to select between different versions
(that was removed), a similar switch to select between different
target triplets could in theory be added.
But note that the driver needs to understand a (subset) of target specific
options for specs processing so even the driver is somewhat target
specific and cannot really be shared.
Richard.
> ---
> With best regards, Konstantin