all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#39794: AVR-Toolchain-5 avr/io not found
@ 2020-02-25 22:12 Ekaitz Zarraga
  2020-02-26  8:44 ` Ekaitz Zarraga
  0 siblings, 1 reply; 11+ messages in thread
From: Ekaitz Zarraga @ 2020-02-25 22:12 UTC (permalink / raw)
  To: 39794

Hi,

I've been trying to debug AVR toolchain errors found in here:

https://lists.gnu.org/archive/html/help-guix/2020-02/msg00204.html

I'm not experienced enough to know all that's going on here and I need some assistance to make everything work.


I'm working on QMK-Firmware (helix keyboard specifically, that is an Atmega32u4) has and I'm able to make it compile with avr-gcc@4.9 but when I try with 5 first it fails because it doesn't find `avr/io.h`.

Exporting a new CPATH variable fixes it:

`export CPATH=$CPATH:/gnu/store/.../avr/include`

Once the export is done it fails because it's unable to find `gnu/stubs-32.h` and I don't know which package carries that. Can you point me to it?
Should it be added to avr-gcc dependencies?

If someone has the time to help me make it work I'll make the patches and the tests needed, but now I don't know what else to do.

First I'd say the package for avr-gcc@5 should not inherit from avr-gcc@4.9 because 4.9 uses CROSS_* variables and works correctly but 5 doesn't use them like that. So these changes solve that issue:

diff --git a/gnu/packages/avr.scm b/gnu/packages/avr.scm
index 1f99f636e0..74caec5b94 100644
--- a/gnu/packages/avr.scm
+++ b/gnu/packages/avr.scm
@@ -76,7 +76,15 @@
   (package
     (inherit avr-gcc-4.9)
     (version (package-version gcc-5))
-    (source (package-source gcc-5))))
+    (source (package-source gcc-5))
+    (native-search-paths
+      (list (search-path-specification
+              (variable "CPATH")
+              (files '("avr/include")))
+            (search-path-specification
+              (variable "LIBRARY_PATH")
+              (files '("avr/lib")))))))
+

 (define (avr-libc avr-gcc)
   (package


But I don't see how to solve the `gnu/stubs-32.h` error.
Can anyone help me a little on this?

Thanks,

ElenQ Technology
Ethical Innovation

^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2020-03-01  7:08 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-02-25 22:12 bug#39794: AVR-Toolchain-5 avr/io not found Ekaitz Zarraga
2020-02-26  8:44 ` Ekaitz Zarraga
2020-02-28 22:42   ` Ekaitz Zarraga
2020-02-29 15:06     ` Arun Isaac
2020-02-29 15:46       ` Ekaitz Zarraga
2020-02-29 15:58         ` Ekaitz Zarraga
2020-02-29 19:14         ` Arun Isaac
2020-02-29 19:26           ` Ekaitz Zarraga
2020-02-29 20:42             ` Arun Isaac
2020-02-29 21:19               ` Ekaitz Zarraga
2020-03-01  7:07                 ` Arun Isaac

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.