I was wondering whether it would be possible to cross-compile with gcc instead of clang, to avoid the need for libclang_rt?
The context is, I am attempting to cross-compile for ppc64le, where there is a sysroot but no libclang_rt. [1]
I added a gcc_toolchain("ppc64le") section to build/toolchain/linux/BUILD.gn and manually set the right sysroot path in GN config, but am ending up with the error below.
I wonder, is that because the code really doesn't support cross-compilation with gcc, or am I just missing something here, like a system dependency, or another config that needs to be set?
```
[1/993] CC obj/third_party/libjpeg_turbo/libjpeg12/jcapistd.o
FAILED: obj/third_party/libjpeg_turbo/libjpeg12/jcapistd.o
powerpc64le-linux-gnu-gcc -MD -MF obj/third_party/libjpeg_turbo/libjpeg12/jcapistd.o.d -DNO_GETENV -DNO_PUTENV -DBITS_IN_JSAMPLE=12 -DUSE_UDEV -DUSE_AURA=1 -DUSE_OZONE=1 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D_FORTIFY_SOURCE=2 -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_EXTENSIVE -D_LIBCPP_DISABLE_VISIBILITY_ANNOTATIONS -D_LIBCXXABI_DISABLE_VISIBILITY_ANNOTATIONS -D_LIBCPP_INSTRUMENTED_WITH_ASAN=0 -DCR_LIBCXX_REVISION=f034fd5662d033c281ab6a9b45164066ddd18809 -DCR_SYSROOT_KEY=20250129T203412Z-1 -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DMANGLE_JPEG_NAMES -I../.. -Igen -I../../buildtools/third_party/libc++ -I../../third_party/libjpeg_turbo/src -Wall -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations -Wno-comments -Wno-packed-not-aligned -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -fno-strict-overflow -fno-ident -fno-strict-aliasing -fstack-protector -funwind-tables -fPIC -pipe -pthread -Wno-builtin-macro-redefined -D__DATE__= -D__TIME__= -D__TIMESTAMP__= -O2 -fdata-sections -ffunction-sections -fno-math-errno -fno-omit-frame-pointer -g0 -fno-builtin-abs -fvisibility=hidden -std=gnu11 --sysroot=../../build/linux/debian_bullseye_ppc64el-sysroot -c ../../third_party/libjpeg_turbo/src/jcapistd.c -o obj/third_party/libjpeg_turbo/libjpeg12/jcapistd.o
In file included from /usr/lib/gcc/powerpc64le-linux-gnu/12/include/stdint.h:9,
from ../../third_party/libjpeg_turbo/src/jconfigint.h:41,
from ../../third_party/libjpeg_turbo/src/jinclude.h:26,
from ../../third_party/libjpeg_turbo/src/jcapistd.c:21:
../../build/linux/debian_bullseye_ppc64el-sysroot/usr/include/stdint.h:26:10: fatal error: bits/libc-header-start.h: No such file or directory
26 | #include <bits/libc-header-start.h>
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
```
I also tried target_cpu = "arm" to rule out it's due to unhandled architecture, but am running into the same issue when is_clang = false is set. With default is_clang = true it works, though.