Mathieu Othacehe <m.othac...@gmail.com> writes: > > --8<---------------cut here---------------start------------->8--- > (native-inputs > `(,@(if (not (string-prefix? "i686" (%current-system))) > `(("cross-gcc" ,(cross-gcc "i686-unknown-linux-gnu")) > ("cross-binutils" ,(cross-binutils "i686-unknown-linux-gnu"))) > '()))) > --8<---------------cut here---------------end--------------->8--- > > that uses the current gcc if you're already building on an i686 system, > or define and use a cross-gcc targeting i686 systems otherwise.
This snippet might make a lot of sense to seasoned schemers/guixfolk, with the multiple levels of (un)quoting and what not. It does not seem like what somebody with little experience in either would think of by themselves. Would it make sense to have a section/stub in the cookbook about cross compilation? - Jelle