gnu: libgit2: Update to 1.4.3.
* gnu/packages/version-control.scm (libgit2): Update to 1.4.3. [source]: Adjust snippet to comment out the "10 years ago" test, which was changed in 1.4.3 but is still problematic. [arguments]: Add "-DUSE_SSH=ON". Remove 'fix-hardcoded-paths' phase. Adjust 'check' phase for new executable name. (libgit2-1.3): New variable. (libgit2-1.1): Inherit from 'libgit2-1.3'; inherit from its origin too. * gnu/packages/crates-io.scm (rust-git2-0.13)[inputs]: Use LIBGIT2-1.3. * gnu/packages/python-xyz.scm (python-pygit2)[propagated-inputs]: Likewise. Co-authored-by: Maxime Devos <maximedevos@telenet.be>
parent
d24ad39491
commit
e764b89a52
|
@ -25048,7 +25048,7 @@ dirty state into your program.")
|
||||||
`(("pkg-config" ,pkg-config)
|
`(("pkg-config" ,pkg-config)
|
||||||
("git" ,git-minimal))) ;for a single test
|
("git" ,git-minimal))) ;for a single test
|
||||||
(inputs
|
(inputs
|
||||||
(list libgit2 libssh2 openssl zlib))
|
(list libgit2-1.3 libssh2 openssl zlib))
|
||||||
(home-page "https://github.com/rust-lang/git2-rs")
|
(home-page "https://github.com/rust-lang/git2-rs")
|
||||||
(synopsis "Rust bindings to libgit2")
|
(synopsis "Rust bindings to libgit2")
|
||||||
(description
|
(description
|
||||||
|
|
|
@ -6137,7 +6137,7 @@ readable format.")
|
||||||
(arguments
|
(arguments
|
||||||
'(#:tests? #f)) ; tests don't run correctly in our environment
|
'(#:tests? #f)) ; tests don't run correctly in our environment
|
||||||
(propagated-inputs
|
(propagated-inputs
|
||||||
(list python-cached-property python-cffi libgit2))
|
(list python-cached-property python-cffi libgit2-1.3))
|
||||||
(native-inputs
|
(native-inputs
|
||||||
(list python-pytest))
|
(list python-pytest))
|
||||||
(home-page "https://github.com/libgit2/pygit2")
|
(home-page "https://github.com/libgit2/pygit2")
|
||||||
|
|
|
@ -44,6 +44,7 @@
|
||||||
;;; Copyright © 2021 jgart <jgart@dismail.de>
|
;;; Copyright © 2021 jgart <jgart@dismail.de>
|
||||||
;;; Copyright © 2021 Foo Chuan Wei <chuanwei.foo@hotmail.com>
|
;;; Copyright © 2021 Foo Chuan Wei <chuanwei.foo@hotmail.com>
|
||||||
;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com>
|
;;; Copyright © 2022 Jai Vetrivelan <jaivetrivelan@gmail.com>
|
||||||
|
;;; Copyright © 2022 Maxime Devos <maximedevos@telenet.be>
|
||||||
;;;
|
;;;
|
||||||
;;; This file is part of GNU Guix.
|
;;; This file is part of GNU Guix.
|
||||||
;;;
|
;;;
|
||||||
|
@ -789,7 +790,7 @@ to GitHub contributions calendar.")
|
||||||
(define-public libgit2
|
(define-public libgit2
|
||||||
(package
|
(package
|
||||||
(name "libgit2")
|
(name "libgit2")
|
||||||
(version "1.3.0")
|
(version "1.4.3")
|
||||||
(source (origin
|
(source (origin
|
||||||
;; Since v1.1.1, release artifacts are no longer offered (see:
|
;; Since v1.1.1, release artifacts are no longer offered (see:
|
||||||
;; https://github.com/libgit2/libgit2/discussions/5932#discussioncomment-1682729).
|
;; https://github.com/libgit2/libgit2/discussions/5932#discussioncomment-1682729).
|
||||||
|
@ -800,18 +801,18 @@ to GitHub contributions calendar.")
|
||||||
(file-name (git-file-name name version))
|
(file-name (git-file-name name version))
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"0vgpb2175a5dhqiy1iwywwppahgqhi340i8bsvafjpvkw284vazd"))
|
"02x1a4zrzpzjd0yxnsi8njh5hgihc1iy1v4r0fnl8m4ckcgp6x2s"))
|
||||||
(modules '((guix build utils)))
|
(modules '((guix build utils)))
|
||||||
(snippet
|
(snippet
|
||||||
'(begin
|
'(begin
|
||||||
(delete-file-recursively "deps")
|
(delete-file-recursively "deps")
|
||||||
|
|
||||||
;; The "refs:revparse::date" test is time-dependent: it
|
;; The "refs:revparse::date" test is time-dependent: it
|
||||||
;; assumes "HEAD@{10 years ago}" doesn't match anything,
|
;; assumes "HEAD@{10 years ago}" matches a specific commit.
|
||||||
;; which is no longer true. Adjust that test.
|
;; See <https://github.com/libgit2/libgit2/pull/6299>.
|
||||||
(substitute* "tests/refs/revparse.c"
|
(substitute* "tests/refs/revparse.c"
|
||||||
(("10 years ago")
|
(("test_object.*10 years ago.*" all)
|
||||||
"100 years ago"))))))
|
(string-append "// " all "\n")))))))
|
||||||
(build-system cmake-build-system)
|
(build-system cmake-build-system)
|
||||||
(outputs '("out" "debug"))
|
(outputs '("out" "debug"))
|
||||||
(arguments
|
(arguments
|
||||||
|
@ -819,6 +820,7 @@ to GitHub contributions calendar.")
|
||||||
(list "-DUSE_NTLMCLIENT=OFF" ;TODO: package this
|
(list "-DUSE_NTLMCLIENT=OFF" ;TODO: package this
|
||||||
"-DREGEX_BACKEND=pcre2"
|
"-DREGEX_BACKEND=pcre2"
|
||||||
"-DUSE_HTTP_PARSER=system"
|
"-DUSE_HTTP_PARSER=system"
|
||||||
|
"-DUSE_SSH=ON" ; cmake fails to find libssh if this is missing
|
||||||
,@(if (%current-target-system)
|
,@(if (%current-target-system)
|
||||||
`((string-append
|
`((string-append
|
||||||
"-DPKG_CONFIG_EXECUTABLE="
|
"-DPKG_CONFIG_EXECUTABLE="
|
||||||
|
@ -829,18 +831,11 @@ to GitHub contributions calendar.")
|
||||||
'()))
|
'()))
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(add-after 'unpack 'fix-hardcoded-paths
|
|
||||||
(lambda _
|
|
||||||
(substitute* "tests/repo/init.c"
|
|
||||||
(("#!/bin/sh") (string-append "#!" (which "sh"))))
|
|
||||||
(substitute* "tests/clar/fs.h"
|
|
||||||
(("/bin/cp") (which "cp"))
|
|
||||||
(("/bin/rm") (which "rm")))))
|
|
||||||
;; Run checks more verbosely, unless we are cross-compiling.
|
;; Run checks more verbosely, unless we are cross-compiling.
|
||||||
(replace 'check
|
(replace 'check
|
||||||
(lambda* (#:key (tests? #t) #:allow-other-keys)
|
(lambda* (#:key (tests? #t) #:allow-other-keys)
|
||||||
(if tests?
|
(if tests?
|
||||||
(invoke "./libgit2_clar" "-v" "-Q")
|
(invoke "./libgit2_tests" "-v" "-Q")
|
||||||
;; Tests may be disabled if cross-compiling.
|
;; Tests may be disabled if cross-compiling.
|
||||||
(format #t "Test suite not run.~%")))))))
|
(format #t "Test suite not run.~%")))))))
|
||||||
(inputs
|
(inputs
|
||||||
|
@ -859,12 +854,39 @@ write native speed custom Git applications in any language with bindings.")
|
||||||
;; GPLv2 with linking exception
|
;; GPLv2 with linking exception
|
||||||
(license license:gpl2)))
|
(license license:gpl2)))
|
||||||
|
|
||||||
(define-public libgit2-1.1
|
(define-public libgit2-1.3
|
||||||
(package
|
(package
|
||||||
(inherit libgit2)
|
(inherit libgit2)
|
||||||
(name "libgit2")
|
(version "1.3.0")
|
||||||
|
(source (origin
|
||||||
|
(inherit (package-source libgit2))
|
||||||
|
(method git-fetch)
|
||||||
|
(uri (git-reference
|
||||||
|
(url "https://github.com/libgit2/libgit2")
|
||||||
|
(commit (string-append "v" version))))
|
||||||
|
(file-name (git-file-name "libgit2" version))
|
||||||
|
(sha256
|
||||||
|
(base32
|
||||||
|
"0vgpb2175a5dhqiy1iwywwppahgqhi340i8bsvafjpvkw284vazd"))))
|
||||||
|
(arguments
|
||||||
|
(substitute-keyword-arguments (package-arguments libgit2)
|
||||||
|
((#:phases _ '%standard-phases)
|
||||||
|
`(modify-phases %standard-phases
|
||||||
|
;; Run checks more verbosely, unless we are cross-compiling.
|
||||||
|
(replace 'check
|
||||||
|
(lambda* (#:key (tests? #t) #:allow-other-keys)
|
||||||
|
(if tests?
|
||||||
|
(invoke "./libgit2_clar" "-v" "-Q")
|
||||||
|
;; Tests may be disabled if cross-compiling.
|
||||||
|
(format #t "Test suite not run.~%"))))))))))
|
||||||
|
|
||||||
|
(define-public libgit2-1.1
|
||||||
|
(package
|
||||||
|
(inherit libgit2-1.3)
|
||||||
(version "1.1.0")
|
(version "1.1.0")
|
||||||
(source (origin
|
(source (origin
|
||||||
|
(inherit (package-source libgit2-1.3))
|
||||||
|
(file-name #f) ;use the default name
|
||||||
(method url-fetch)
|
(method url-fetch)
|
||||||
(uri (string-append "https://github.com/libgit2/libgit2/"
|
(uri (string-append "https://github.com/libgit2/libgit2/"
|
||||||
"releases/download/v" version
|
"releases/download/v" version
|
||||||
|
@ -872,17 +894,7 @@ write native speed custom Git applications in any language with bindings.")
|
||||||
(sha256
|
(sha256
|
||||||
(base32
|
(base32
|
||||||
"1fjdglkh04qv3b4alg621pxa689i0wlf8m7nf2755zawjr2zhwxd"))
|
"1fjdglkh04qv3b4alg621pxa689i0wlf8m7nf2755zawjr2zhwxd"))
|
||||||
(patches (search-patches "libgit2-mtime-0.patch"))
|
(patches (search-patches "libgit2-mtime-0.patch"))))))
|
||||||
(snippet '(begin
|
|
||||||
(delete-file-recursively "deps")
|
|
||||||
|
|
||||||
;; The "refs:revparse::date" test is time-dependent: it
|
|
||||||
;; assumes "HEAD@{10 years ago}" doesn't match anything,
|
|
||||||
;; which is no longer true. Adjust that test.
|
|
||||||
(substitute* "tests/refs/revparse.c"
|
|
||||||
(("10 years ago")
|
|
||||||
"100 years ago"))))
|
|
||||||
(modules '((guix build utils)))))))
|
|
||||||
|
|
||||||
(define-public git-crypt
|
(define-public git-crypt
|
||||||
(package
|
(package
|
||||||
|
|
Reference in New Issue