guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/03: gnu: selinux.scm: Use cc-for-target.


From: guix-commits
Subject: 02/03: gnu: selinux.scm: Use cc-for-target.
Date: Mon, 12 Apr 2021 10:11:15 -0400 (EDT)

efraim pushed a commit to branch core-updates
in repository guix.

commit a55f64917dc9a56d5a95de625bc3092b625df0ed
Author: Efraim Flashner <efraim@flashner.co.il>
AuthorDate: Mon Apr 12 12:09:29 2021 +0300

    gnu: selinux.scm: Use cc-for-target.
    
    * gnu/packages/selinux.scm (libsepol, checkpolicy, policycoreutils)
    [arguments]: Don't hardcode gcc.
---
 gnu/packages/selinux.scm | 20 +++++---------------
 1 file changed, 5 insertions(+), 15 deletions(-)

diff --git a/gnu/packages/selinux.scm b/gnu/packages/selinux.scm
index 7230b65..41b8fdc 100644
--- a/gnu/packages/selinux.scm
+++ b/gnu/packages/selinux.scm
@@ -63,19 +63,14 @@
      `(#:tests? #f ; tests require checkpolicy, which requires libsepol
        #:test-target "test"
        #:make-flags
-       (let ((out (assoc-ref %outputs "out"))
-             (target ,(%current-target-system)))
+       (let ((out (assoc-ref %outputs "out")))
          (list (string-append "PREFIX=" out)
                (string-append "SHLIBDIR=" out "/lib")
                (string-append "MAN3DIR=" out "/share/man/man3")
                (string-append "MAN5DIR=" out "/share/man/man5")
                (string-append "MAN8DIR=" out "/share/man/man8")
                (string-append "LDFLAGS=-Wl,-rpath=" out "/lib")
-               (string-append "CC="
-                              (if target
-                                  (string-append (assoc-ref %build-inputs 
"cross-gcc")
-                                                 "/bin/" target "-gcc")
-                                  "gcc"))))
+               (string-append "CC=" ,(cc-for-target))))
        #:phases
        (modify-phases %standard-phases
          (delete 'configure)
@@ -105,17 +100,12 @@ boolean settings).")
     (arguments
      `(#:tests? #f ; there is no check target
        #:make-flags
-       (let ((out (assoc-ref %outputs "out"))
-             (target ,(%current-target-system)))
+       (let ((out (assoc-ref %outputs "out")))
          (list (string-append "PREFIX=" out)
                (string-append "LIBSEPOLA="
                               (assoc-ref %build-inputs "libsepol")
                               "/lib/libsepol.a")
-               (string-append "CC="
-                              (if target
-                                  (string-append (assoc-ref %build-inputs 
"cross-gcc")
-                                                 "/bin/" target "-gcc")
-                                  "gcc"))))
+               (string-append "CC=" ,(cc-for-target))))
        #:phases
        (modify-phases %standard-phases
          (delete 'configure)
@@ -376,7 +366,7 @@ tools, and libraries designed to facilitate SELinux policy 
analysis.")
      `(#:test-target "test"
        #:make-flags
        (let ((out (assoc-ref %outputs "out")))
-         (list "CC=gcc"
+         (list (string-append "CC=" ,(cc-for-target))
                (string-append "PREFIX=" out)
                (string-append "LOCALEDIR=" out "/share/locale")
                (string-append "BASHCOMPLETIONDIR=" out



reply via email to

[Prev in Thread] Current Thread [Next in Thread]