[Bug 272142] devel/xtensa-esp32-elf: Request lang/gcc as default

From: <bugzilla-noreply_at_freebsd.org>
Date: Fri, 23 Jun 2023 14:01:36 UTC
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=272142

--- Comment #3 from O. Hartmann <ohartmann@walstatt.org> ---
My skills of understanding the design of the toolset is limited. I stumbled
into this problem regarding gcc, since my CURRENT boxes are on "default gcc",
which is lang/gcc (which is lang/gcc12 ). It takes a significant amount of time
on my oldish hardware to compile gcc.

First: lang/gcc12 (as other compilers) have backward compatibility knobs, like 

-std=c++11

I tried to apply those knobs via "CXXFLAGS+=-std=c++11" in the Makefile to get
rid of the c++17 warning (treated as error) when compiling with gcc12, but no
success - I guess the configure part via (gnu) autotools isn't run properly to
deploy the CXXFLAGS knob or, more likely, the set of options is fixed in the
sources and need to be patched.

Second: I did not understand the concept of this port, on the one hand we use
gcc10 to compile the "port", on the other hand, gcc5.2 is included as the cross
compiler(?) to deliver Xtensa binary code. Reasons unknown.

Third: I checked whether the FreeBSD base compiler, LLVM (LLVM16 now in
CURRENT) supports the target Xtensa - and it seems, following this 

https://www.esp32.com/viewtopic.php?t=9226

reveals that LLVM already supports the target in some way - I did not
investigate the state of efficiency yet.

At the end I'd like to have a development environment ready to compile and
deploy some code on ESP32 MCUs.

-- 
You are receiving this mail because:
You are the assignee for the bug.