pico-sdk and tinyusb fail to build with GCC 11.2 #780
Labels
No labels
bazel
bluetooth
board settings
boot_stage2
bug
build
c++
can't reproduce
clang
clib-interface
cmsis
code cleanliness
code size
compiler version issues
cyw43_driver
debug
discussion
documentation
duplicate
dynamic_clock
elf2uf2
enhancement
errata
filesystem
flash layout
floating point
FreeRTOS
hardware_adc
hardware_claim
hardware_clocks
hardware_dma
hardware_exception
hardware_flash
hardware_gpio
hardware_i2c
hardware_irq
hardware_pio
hardware_pwm
hardware_rcp
hardware_rtc
hardware_spi
hardware_sync
hardware_uart
hardware_vreg
hardware_watchdog
hardware_xosc
help wanted
host
IAR
installation
invalid
linker scripts
lto
lwip
mbedtls
missing API
needs reporter detail
networking
newlib
newlib-multicore
non-c
non-cmake
non-gcc
openocd
orphan PR
OS integration
pico_async_context
pico_base
pico_binary_info
pico_flash
picolibc
pico_lwip
pico_malloc
pico_multicore
pico_printf
pico_runtime
pico_stdio
pico_stdio_usb
pico_sync
pico_time
pico_util
pioasm
port
question
review
review2
rtos interop
runtime init
static library
svd
test
tinyusb
vscode
wifi integration
wontfix
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-raspberrypi/pico-sdk#780
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
I'm not sure exactly where the problem is, so pinging @kilograham @liamfraser and @hathach
If I build just
pico-sdkwith GCC 11.2 from https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/downloads then it builds fine, but if I also clone the tinyusb sumbodule, then when I try to build it fails with:😢
To reproduce:
(I'm doing everything inside docker just to rule out any other part of the system interfering with things)
and then inside docker:
I'm happy to provide any other info and/or do any other testing that might be needed.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99578 (haven't read it all yet)
ah; fixed in GCC 11.3; we can probably suppress it in 11.2 if we really want as we already have code to suppress tinyusb warnings
Probably worth doing - who knows how long it'll be until ARM provide an updated "Arm GNU Toolchain" ? 🤷
That's quite a thread. Someone wants to change 40 years of embedded programming practice by warning about it, and get everyone to change their code to get rid of the warning. Only about a billion lines of code. Nice. At least sense was seen.
yeah, i'm surprised ARM built an embedded toolchain (actually i guess this is now not just an embedded toolchain - i was going to the old page which is why i hadn't seen 11.2) which is likely to give warnings on all embedded projects (I'm surprised they didn't hit it in testing)
FYI: the latest tinyusb already surpresses -Warray-bounds with a #pragma in code, but -Wstringop-overflow isn't surpressed (yet).
For what it's worth, I added this ugly hack to my copy which adds no actual code bytes, but suppresses the warning:
Example on compiler explorer: https://godbolt.org/z/9xYGjdEx5
merged into develop
Just for the record, the instructions in my first post above now all work on the
developbranch of pico-sdk in docker containers for all combinations of:tinyusbsubmoduleand for both
pico-sdkandpico-examples. 🎉Confirming as well that the
developbranch now compiles cleanly with Fedora 35.This
gcc-arm-none-eabireportsgcc version 11.1.0 (Fedora 11.1.0-2.fc35)