diff options
author | Zheng Junjie <z572@z572.online> | 2025-06-22 09:55:50 +0800 |
---|---|---|
committer | Zheng Junjie <z572@z572.online> | 2025-06-26 21:31:38 +0800 |
commit | 8d39268b5f42d2fad8063724da0857a303b9702f (patch) | |
tree | 67ffda00259cc019708bd53be23d74f3641d3fcf | |
parent | b8c464af7bed363f45bd845824a2b45a49ce11aa (diff) |
gnu: xorriso: Fix cross-compiling to riscv64-linux.
Fixes: guix/guix#740
* gnu/packages/cdrom.scm (xorriso)[native-inputs]: When target riscv64-linux,
add config.
[arguments]: When native-inputs have CONFIG, add update-config-scripts phase.
Change-Id: I1943c88abf5e6aeee4fb24b171c8732f5e9a58f0
-rw-r--r-- | gnu/packages/cdrom.scm | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/gnu/packages/cdrom.scm b/gnu/packages/cdrom.scm index cdfb938606..06c43c1dd9 100644 --- a/gnu/packages/cdrom.scm +++ b/gnu/packages/cdrom.scm @@ -14,7 +14,7 @@ ;;; Copyright © 2018, 2019 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2019 Eric Bavier <bavier@member.fsf.org> ;;; Copyright © 2020 Timotej Lazar <timotej.lazar@araneo.si> -;;; Copyright © 2023 Zheng Junjie <873216071@qq.com> +;;; Copyright © 2023, 2025 Zheng Junjie <z572@z572.online> ;;; Copyright © 2024 Julian Flake <flake@uni-koblenz.de> ;;; Copyright © 2025 Yovan Naumovski <yovan@gorski.stream> ;;; Copyright © 2025 André Batista <nandre@riseup.net> @@ -180,6 +180,17 @@ libcdio.") (arguments `(#:phases (modify-phases %standard-phases + ,@(if (this-package-native-input "config") + `((add-after 'unpack 'update-config-scripts + (lambda* (#:key inputs native-inputs #:allow-other-keys) + ;; Replace outdated config.guess and config.sub. + (for-each (lambda (file) + (install-file + (search-input-file + (or native-inputs inputs) + (string-append "/bin/" file)) ".")) + '("config.guess" "config.sub"))))) + '()) (add-after 'install 'install-frontends (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) @@ -199,6 +210,12 @@ libcdio.") "/share/man/man1/xorriso-tcltk.1")) (wrap-program (string-append gui "/bin/xorriso-tcltk") `("PATH" ":" prefix (,(string-append out "/bin")))))))))) + (native-inputs + (append (if (and (%current-target-system) + (target-riscv64?)) + (list config) + '()) + (list))) (inputs (list acl bash-minimal readline tk zlib)) (home-page "https://www.gnu.org/software/xorriso/") |