Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 10 Aug 2024 11:51:33 +0100
From:      Nuno Teixeira <eduardo@freebsd.org>
To:        Jan Beich <jbeich@freebsd.org>
Cc:        ports-committers@freebsd.org, dev-commits-ports-all@freebsd.org,  dev-commits-ports-main@freebsd.org
Subject:   Re: git: 84ce872284e3 - main - devel/cargo-c: unbreak build with libgit2 1.8.1
Message-ID:  <CAFDf7UJDhKgzNSHdUn_E-kd9_iYo2R5cZnB0gFG0aHLaAtRB5A@mail.gmail.com>
In-Reply-To: <202408100042.47A0g2sI025873@gitrepo.freebsd.org>

index | next in thread | previous in thread | raw e-mail

[-- Attachment #1 --]
Hello Jan!

This is the solution that I was looking for.
I will use this patch on failing ports from same PR and check results.

Thanks,

Jan Beich <jbeich@freebsd.org> escreveu (sábado, 10/08/2024 à(s) 01:42):

> The branch main has been updated by jbeich:
>
> URL:
> https://cgit.FreeBSD.org/ports/commit/?id=84ce872284e30424e2691199d40023a852b13563
>
> commit 84ce872284e30424e2691199d40023a852b13563
> Author:     Jan Beich <jbeich@FreeBSD.org>
> AuthorDate: 2024-08-09 23:12:27 +0000
> Commit:     Jan Beich <jbeich@FreeBSD.org>
> CommitDate: 2024-08-10 00:41:35 +0000
>
>     devel/cargo-c: unbreak build with libgit2 1.8.1
>
>     warning: libgit2-sys@0.16.2+1.7.2: failed to probe system libgit2:
>     [...]
>     warning: libgit2-sys@0.16.2+1.7.2:
> libgit2/src/libgit2/transports/ssh.c:11:10: fatal error: 'libssh2.h' file
> not found
>     warning: libgit2-sys@0.16.2+1.7.2:    11 | #include <libssh2.h>
>     warning: libgit2-sys@0.16.2+1.7.2:       |          ^~~~~~~~~~~
>     warning: libgit2-sys@0.16.2+1.7.2: 1 error generated.
>
>     PR:             280706
>     Reported by:    eduardo
> ---
>  devel/cargo-c/files/patch-libgit2-1.8.x | 13 +++++++++++++
>  1 file changed, 13 insertions(+)
>
> diff --git a/devel/cargo-c/files/patch-libgit2-1.8.x
> b/devel/cargo-c/files/patch-libgit2-1.8.x
> new file mode 100644
> index 000000000000..b0ec8036a466
> --- /dev/null
> +++ b/devel/cargo-c/files/patch-libgit2-1.8.x
> @@ -0,0 +1,13 @@
> +https://github.com/rust-lang/git2-rs/commit/b534e13f38c6
> +
> +--- cargo-crates/libgit2-sys-0.16.2+1.7.2/build.rs.orig        2006-07-24
> 01:21:28 UTC
> ++++ cargo-crates/libgit2-sys-0.16.2+1.7.2/build.rs
> +@@ -7,7 +7,7 @@ fn try_system_libgit2() -> Result<pkg_config::Library,
> + /// Tries to use system libgit2 and emits necessary build script
> instructions.
> + fn try_system_libgit2() -> Result<pkg_config::Library,
> pkg_config::Error> {
> +     let mut cfg = pkg_config::Config::new();
> +-    match cfg.range_version("1.7.2".."1.8.0").probe("libgit2") {
> ++    match cfg.range_version("1.7.2".."1.9.0").probe("libgit2") {
> +         Ok(lib) => {
> +             for include in &lib.include_paths {
> +                 println!("cargo:root={}", include.display());
>


-- 
Nuno Teixeira
FreeBSD UNIX:  <eduardo@FreeBSD.org>   Web:  https://FreeBSD.org

[-- Attachment #2 --]
<div dir="ltr"><div>Hello Jan!</div><div><br></div><div>This is the solution that I was looking for.<br></div><div>I will use this patch on failing ports from same PR and check results.<br><br></div><div>Thanks,<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">Jan Beich &lt;<a href="mailto:jbeich@freebsd.org">jbeich@freebsd.org</a>&gt; escreveu (sábado, 10/08/2024 à(s) 01:42):<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">The branch main has been updated by jbeich:<br>
<br>
URL: <a href="https://cgit.FreeBSD.org/ports/commit/?id=84ce872284e30424e2691199d40023a852b13563" rel="noreferrer" target="_blank">https://cgit.FreeBSD.org/ports/commit/?id=84ce872284e30424e2691199d40023a852b13563</a><br>;
<br>
commit 84ce872284e30424e2691199d40023a852b13563<br>
Author:     Jan Beich &lt;jbeich@FreeBSD.org&gt;<br>
AuthorDate: 2024-08-09 23:12:27 +0000<br>
Commit:     Jan Beich &lt;jbeich@FreeBSD.org&gt;<br>
CommitDate: 2024-08-10 00:41:35 +0000<br>
<br>
    devel/cargo-c: unbreak build with libgit2 1.8.1<br>
<br>
    warning: libgit2-sys@0.16.2+1.7.2: failed to probe system libgit2:<br>
    [...]<br>
    warning: libgit2-sys@0.16.2+1.7.2: libgit2/src/libgit2/transports/ssh.c:11:10: fatal error: &#39;libssh2.h&#39; file not found<br>
    warning: libgit2-sys@0.16.2+1.7.2:    11 | #include &lt;libssh2.h&gt;<br>
    warning: libgit2-sys@0.16.2+1.7.2:       |          ^~~~~~~~~~~<br>
    warning: libgit2-sys@0.16.2+1.7.2: 1 error generated.<br>
<br>
    PR:             280706<br>
    Reported by:    eduardo<br>
---<br>
 devel/cargo-c/files/patch-libgit2-1.8.x | 13 +++++++++++++<br>
 1 file changed, 13 insertions(+)<br>
<br>
diff --git a/devel/cargo-c/files/patch-libgit2-1.8.x b/devel/cargo-c/files/patch-libgit2-1.8.x<br>
new file mode 100644<br>
index 000000000000..b0ec8036a466<br>
--- /dev/null<br>
+++ b/devel/cargo-c/files/patch-libgit2-1.8.x<br>
@@ -0,0 +1,13 @@<br>
+<a href="https://github.com/rust-lang/git2-rs/commit/b534e13f38c6" rel="noreferrer" target="_blank">https://github.com/rust-lang/git2-rs/commit/b534e13f38c6</a><br>;
+<br>
+--- cargo-crates/libgit2-sys-0.16.2+1.7.2/build.rs.orig        2006-07-24 01:21:28 UTC<br>
++++ cargo-crates/libgit2-sys-0.16.2+1.7.2/<a href="http://build.rs" rel="noreferrer" target="_blank">build.rs</a><br>
+@@ -7,7 +7,7 @@ fn try_system_libgit2() -&gt; Result&lt;pkg_config::Library,<br>
+ /// Tries to use system libgit2 and emits necessary build script instructions.<br>
+ fn try_system_libgit2() -&gt; Result&lt;pkg_config::Library, pkg_config::Error&gt; {<br>
+     let mut cfg = pkg_config::Config::new();<br>
+-    match cfg.range_version(&quot;1.7.2&quot;..&quot;1.8.0&quot;).probe(&quot;libgit2&quot;) {<br>
++    match cfg.range_version(&quot;1.7.2&quot;..&quot;1.9.0&quot;).probe(&quot;libgit2&quot;) {<br>
+         Ok(lib) =&gt; {<br>
+             for include in &amp;lib.include_paths {<br>
+                 println!(&quot;cargo:root={}&quot;, include.display());<br>
</blockquote></div><br clear="all"><br><span class="gmail_signature_prefix">-- </span><br><div dir="ltr" class="gmail_signature"><div dir="ltr"><div><font color="#888888">Nuno Teixeira</font></div><div><div><font color="#888888">
FreeBSD UNIX:  &lt;eduardo@FreeBSD.org&gt;   Web:  <a href="https://FreeBSD.org" rel="noreferrer" target="_blank">https://FreeBSD.org</a><br></font></div></div></div></div>;
home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAFDf7UJDhKgzNSHdUn_E-kd9_iYo2R5cZnB0gFG0aHLaAtRB5A>