gnu: dtc: Cross compile.
* gnu/packages/bootloaders.scm (dtc)[arguments]: Use cc-for-target in make-flags. Add custom phase to use correct pkg-config for target.master
parent
afcf90c60f
commit
6cc86492db
|
@ -425,7 +425,7 @@ menu to select one of the installed operating systems.")
|
||||||
`(("python" ,python)))
|
`(("python" ,python)))
|
||||||
(arguments
|
(arguments
|
||||||
`(#:make-flags
|
`(#:make-flags
|
||||||
(list "CC=gcc"
|
(list (string-append "CC=" ,(cc-for-target))
|
||||||
|
|
||||||
;; /bin/fdt{get,overlay,put} need help finding libfdt.so.1.
|
;; /bin/fdt{get,overlay,put} need help finding libfdt.so.1.
|
||||||
(string-append "LDFLAGS=-Wl,-rpath="
|
(string-append "LDFLAGS=-Wl,-rpath="
|
||||||
|
@ -436,6 +436,15 @@ menu to select one of the installed operating systems.")
|
||||||
"INSTALL=install")
|
"INSTALL=install")
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
|
(add-after 'unpack 'patch-pkg-config
|
||||||
|
(lambda _
|
||||||
|
(substitute* '("Makefile"
|
||||||
|
"tests/run_tests.sh")
|
||||||
|
(("pkg-config")
|
||||||
|
(or (which "pkg-config")
|
||||||
|
(string-append ,(%current-target-system)
|
||||||
|
"-pkg-config"))))
|
||||||
|
#t))
|
||||||
(delete 'configure)))) ; no configure script
|
(delete 'configure)))) ; no configure script
|
||||||
(home-page "https://www.devicetree.org")
|
(home-page "https://www.devicetree.org")
|
||||||
(synopsis "Compiles device tree source files")
|
(synopsis "Compiles device tree source files")
|
||||||
|
|
Reference in New Issue