GNU bug report logs - #36477
Add Guix System cross-compilation support

Previous Next

Package: guix-patches;

Reported by: Mathieu Othacehe <m.othacehe <at> gmail.com>

Date: Tue, 2 Jul 2019 15:19:02 UTC

Severity: normal

Done: Mathieu Othacehe <m.othacehe <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Marius Bakke <mbakke <at> fastmail.com>
To: Mathieu Othacehe <m.othacehe <at> gmail.com>, 36477 <at> debbugs.gnu.org
Cc: Mathieu Othacehe <m.othacehe <at> gmail.com>
Subject: [bug#36477] [PATCH 13/31] gnu: libgit2: Fix cross compilation.
Date: Mon, 08 Jul 2019 19:49:56 +0200
[Message part 1 (text/plain, inline)]
Mathieu Othacehe <m.othacehe <at> gmail.com> writes:

> * gnu/packages/version-control.scm (libgit2)[arguments]: Set
> PKG_CONFIG_EXECUTABLE variable when cross-compiling.
> Also do not run test suite if cross-compiling.
> ---
>  gnu/packages/version-control.scm | 16 +++++++++++++---
>  1 file changed, 13 insertions(+), 3 deletions(-)
>
> diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm
> index 8effe1d502..ca5a019105 100644
> --- a/gnu/packages/version-control.scm
> +++ b/gnu/packages/version-control.scm
> @@ -545,7 +545,14 @@ everything from small to very large projects with speed and efficiency.")
>      (build-system cmake-build-system)
>      (outputs '("out" "debug"))
>      (arguments
> -     `(#:configure-flags '("-DUSE_SHA1DC=ON") ; SHA-1 collision detection
> +     `(#:configure-flags
> +       (list "-DUSE_SHA1DC=ON"  ; SHA-1 collision detection
> +             ,@(if (%current-target-system)
> +                   `((string-append
> +                      "-DPKG_CONFIG_EXECUTABLE="
> +                      (assoc-ref %build-inputs "pkg-config")
> +                      "/bin/" ,(%current-target-system) "-pkg-config"))
> +                   '()))
>         #:phases
>         (modify-phases %standard-phases
>           (add-after 'unpack 'fix-hardcoded-paths
> @@ -560,9 +567,12 @@ everything from small to very large projects with speed and efficiency.")
>             (lambda _
>               (for-each make-file-writable (find-files "."))
>               #t))
> -         ;; Run checks more verbosely.
> +         ;; Run checks more verbosely, unless we are cross-compiling.
>           (replace 'check
> -           (lambda _ (invoke "./libgit2_clar" "-v" "-Q"))))))
> +           (lambda _
> +             ,@(if (%current-target-system)
> +                   '(#t)

Maybe print "test suite not run" or something like that.  Otherwise LGTM.

> +                   '((invoke "./libgit2_clar" "-v" "-Q"))))))))
>      (inputs
>       `(("libssh2" ,libssh2)
>         ("http-parser" ,http-parser)))
> -- 
> 2.17.1
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 5 years and 270 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.