diff options
author | Efraim Flashner <efraim@flashner.co.il> | 2020-11-16 12:43:57 +0200 |
---|---|---|
committer | Efraim Flashner <efraim@flashner.co.il> | 2020-11-16 13:03:00 +0200 |
commit | 6cc86492dbec84a3d50ea395395332ed864de2ae (patch) | |
tree | 881d9165a4196b7bb9b418911378057b02ae3ca8 /gnu/packages | |
parent | afcf90c60f8a39cfe34bd796f91dde8d1e6e5da2 (diff) | |
download | guix-6cc86492dbec84a3d50ea395395332ed864de2ae.tar.gz guix-6cc86492dbec84a3d50ea395395332ed864de2ae.zip |
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.
Diffstat (limited to 'gnu/packages')
-rw-r--r-- | gnu/packages/bootloaders.scm | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/gnu/packages/bootloaders.scm b/gnu/packages/bootloaders.scm index e3e49288ad..3c30395ef4 100644 --- a/gnu/packages/bootloaders.scm +++ b/gnu/packages/bootloaders.scm @@ -425,7 +425,7 @@ menu to select one of the installed operating systems.") `(("python" ,python))) (arguments `(#:make-flags - (list "CC=gcc" + (list (string-append "CC=" ,(cc-for-target)) ;; /bin/fdt{get,overlay,put} need help finding libfdt.so.1. (string-append "LDFLAGS=-Wl,-rpath=" @@ -436,6 +436,15 @@ menu to select one of the installed operating systems.") "INSTALL=install") #: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 (home-page "https://www.devicetree.org") (synopsis "Compiles device tree source files") |