diff options
author | Zheng Junjie <873216071@qq.com> | 2023-07-28 21:33:52 +0800 |
---|---|---|
committer | Mathieu Othacehe <othacehe@gnu.org> | 2023-10-26 15:21:35 +0200 |
commit | dd3b9e84b9b0db53def58a2888827acbaccf4944 (patch) | |
tree | bb49f0cd89edb4b00073c010a8ecf9c483ab9104 | |
parent | 486dcafb4569224ad0c17df7d5bebb210b7be075 (diff) | |
download | guix-dd3b9e84b9b0db53def58a2888827acbaccf4944.tar.gz guix-dd3b9e84b9b0db53def58a2888827acbaccf4944.zip |
utils: Add 'strip-for-target'.
* guix/utils.scm (strip-for-target): New procedure.
Signed-off-by: Mathieu Othacehe <othacehe@gnu.org>
-rw-r--r-- | guix/utils.scm | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/guix/utils.scm b/guix/utils.scm index e9af33bdeb..7a42b49df2 100644 --- a/guix/utils.scm +++ b/guix/utils.scm @@ -18,6 +18,7 @@ ;;; Copyright © 2022 Antero Mejr <antero@mailbox.org> ;;; Copyright © 2023 Philip McGrath <philip@philipmcgrath.com> ;;; Copyright © 2023 Janneke Nieuwenhuizen <janneke@gnu.org> +;;; Copyright © 2023 Zheng Junjie <873216071@qq.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -111,6 +112,7 @@ cxx-for-target ld-for-target pkg-config-for-target + strip-for-target version-compare version>? @@ -784,6 +786,11 @@ architecture (x86_64)?" (string-append target "-pkg-config") "pkg-config")) +(define* (strip-for-target #:optional (target (%current-target-system))) + (if target + (string-append target "-strip") + "strip")) + (define version-compare (let ((strverscmp (let ((sym (or (dynamic-func "strverscmp" (dynamic-link)) |