Hi, when I apply my patch and then modify my Makefile to also say:
CPPFLAGS += -I${HOME}/.guix-profile/avr/include -L${HOME}/.guix-profile/avr/lib/avr5 -L${HOME}/.guix-profile/avr/lib -B${HOME}/.guix-profile/avr/lib CPPFLAGS += -I.. then for Arduino (after applying my patch) I still get: PluggableUSB.cpp:(.text._Z12PluggableUSBv+0xc): undefined reference to `__cxa_guard_acquire' PluggableUSB.cpp:(.text._Z12PluggableUSBv+0x2c): undefined reference to `__cxa_guard_release' This is because it uses (see <https://github.com/arduino/Arduino/blob/master/hardware/arduino/avr/cores/arduino/PluggableUSB.cpp#L102>): PluggableUSB_& PluggableUSB() { static PluggableUSB_ obj; /* editor's note: uh oh!! */ return obj; } It works just fine (it also links fine; everything OK) when I change it to: static PluggableUSB_ obj; PluggableUSB_& PluggableUSB() { return obj; } Should that have worked as-is? Also, why is avr-gcc also setting native-search-paths (even though it's a cross compiler)? Doesn't seem to make a difference and is also rather strange... What does the search-paths form do? Does it set environment variables in the profile as well?