diff mbox series

[bug#66263,v1,13/22] gnu: cross-gcc: Only C and C++ for AVR.

Message ID 20231128113510.11214-13-jean@foundationdevices.com
State New
Headers show
Series None | expand

Commit Message

Jean-Pierre De Jesus DIAZ Nov. 28, 2023, 11:34 a.m. UTC
* gnu/packages/cross-base.scm (cross-gcc-arguments)
  <configure-flags> [target-avr?]: Add --enable-languages=c,c++.

Change-Id: I1d63bb1b0a3074b9ff8650c5afb93777183c0ea4
---
 gnu/packages/cross-base.scm | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/gnu/packages/cross-base.scm b/gnu/packages/cross-base.scm
index 58c37e43c1..72f786dc35 100644
--- a/gnu/packages/cross-base.scm
+++ b/gnu/packages/cross-base.scm
@@ -200,13 +200,18 @@  (define (cross-gcc-arguments target xgcc libc)
                                                   "/" #$target "/lib"))
                                 #~())
 
+
                          #$@(if (target-avr? target)
                                 #~("--enable-multilib")
                                 #~())
 
 
                          #$@(if (and libc (target-avr? target))
-                                #~((string-append "--with-native-system-header-dir="
+                                #~(;; By default GCC will attemp to compile
+                                   ;; some libraries for other languages (objc,
+                                   ;; fortran) but compilation fails for AVR.
+                                   "--enable-languages=c,c++"
+                                   (string-append "--with-native-system-header-dir="
                                                   #$libc "/" #$target "/include"))
                                 #~()))