This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: New GCC port/retarget
- From: Hendrik Greving <hendrik dot greving dot intel at gmail dot com>
- To: Ian Lance Taylor <iant at google dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: Tue, 23 Jul 2013 10:23:59 -0700
- Subject: Re: New GCC port/retarget
- References: <CANc4vhqfSH2AJuDwSCZXizEGPO1VQFPJ7YVCxzg4YB_Lm_KxcA at mail dot gmail dot com> <CAKOQZ8x5k5duWKDfOr8380BuGxnwVtPhBJZJXgm6BLbnR0o0NA at mail dot gmail dot com>
On Tue, Jul 23, 2013 at 9:58 AM, Hendrik Greving
<hendrik.greving.intel@gmail.com> wrote:
> If I set use_gcc_stdint=wrap, does tm.h suppose to include
> config/glibc-stdint.h?
> Please reply to the mailing list, not just to me. Thanks.
> If you are using glibc, you shoud add glibc-stdint.h to tm_file in
> gcc/config.gcc; see many existing examples. If you aren't using
> glibc, you may still want to do that, but you should make sure it is
> correct for your target. Or you may need to define the same macros
> that glibc-stdint.h defines, only with the values appropriate for your
> target.
I am copy'ing the email I accidently sent to Ian privately, so the
answer will get properly archived in the mailing list.
May I ask 2 follow-ups:
1. The new compiler doesn't seem to find /usr/include/stdint.h when
compiling a sample test-case. The old one (old GCC version that had
same target) did. I supposed this is related. Is this expected?
2. It is still a little unclear what use_gcc_stdint is for. I
understand that GCC apparently need some stdint definitions. That's
why I (can-) include glibc-stdint.h in tm.h by adding it in
config.gcc. What role plays use_gcc_stdint then?
On Mon, Jul 22, 2013 at 9:39 PM, Ian Lance Taylor <iant@google.com> wrote:
> On Mon, Jul 22, 2013 at 8:28 PM, Hendrik Greving
> <hendrik.greving.intel@gmail.com> wrote:
>> After porting/re-targeting a very old backend (own target) to GCC
>> 4.8.1, I am getting this when compiling:
>>
>> Fixing headers into /path/to/objdir/gcc/include-fixed for
>> moon-unknown-none target
>> No forbidden identifiers defined by this target
>> echo timestamp > stmp-fixinc
>> make[2]: *** No rule to make target
>> `../../../../src/tools/fsf_4_8_1/gcc/ginclude/stdint.h', needed by
>> `stmp-int-hdrs'. Stop.
>> make[2]: Leaving directory `/path/to/objdir/gcc'
>> make[1]: *** [all-gcc] Error 2
>> make[1]: Leaving directory `/path/to/objdir'
>> make: *** [all] Error 2
>>
>> Anybody knows what that is?
>
> Set use_gcc_stdint in gcc/config.gcc. Make sure your tm.h file
> defines INT8_TYPE and friends one way or another. Look at
> config/glibc-stdint.h.
>
> Ian