ps3dev / ps3toolchain

A script to autobuild an open source toolchain for the PS3.
BSD 2-Clause "Simplified" License
283 stars 92 forks source link

stdatomic.h error #97

Closed crystalct closed 4 years ago

crystalct commented 4 years ago

/usr/local/ps3dev/ppu/lib/gcc/powerpc64-ps3-elf/7.2.0/include/stdatomic.h:63:17: error: unknown type name 'INT_FAST8_TYPE' typedef _Atomic INT_FAST8_TYPE atomic_int_fast8_t; /usr/local/ps3dev/ppu/lib/gcc/powerpc64-ps3-elf/7.2.0/include/stdatomic.h:57:17: error: unknown type name 'INT_LEAST8_TYPE' typedef _Atomic INT_LEAST8_TYPE atomic_int_least8_t;

calling:

crystal@DESKTOP-2FII39V /usr/local/ps3dev
$ gcc -dM -E -x c /dev/null | grep __UINT_LEAST8_TYPE__
#define __UINT_LEAST8_TYPE__ unsigned char

calling:

crystal@DESKTOP-2FII39V /usr/local/ps3dev
$ ppu-gcc -dM -E -x c /dev/null | grep INT_LEAST8_TYPE

crystal@DESKTOP-2FII39V /usr/local/ps3dev
$ 

Is it correct?

zeldin commented 4 years ago

We probably need to add newlib-stdint.h to tm_file, like it is done for powerpc-*-elf*.

zeldin commented 4 years ago

The SPU toolchain already has newlib-stdint.h in its tm_file, and there it looks ok:

hakua:/tmp/ps3toolchain% echo "" | spu-gcc -dD -E -x c - | grep INT_LEAST8_TYPE
#define __INT_LEAST8_TYPE__ signed char
#define __UINT_LEAST8_TYPE__ unsigned char
hakua:/tmp/ps3toolchain% 
zeldin commented 4 years ago

There we go:

hakua:~% echo "" | ppu-gcc -dD -E -x c - | grep INT_LEAST8_TYPE
#define __INT_LEAST8_TYPE__ signed char
#define __UINT_LEAST8_TYPE__ unsigned char
hakua:~% 

@crystalct Please try again with latest toolchain now. (Just rerunning ./toolchain.sh 002 is fine.)

crystalct commented 4 years ago

Great! I'll try.