git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] Makefile: build libgit-rs and libgit-sys serially

From
Kyle Lippincott <spectral@google.com>
Date
Aug 26, 2025, 18:02 UTC
Message-ID
<CAO_smViKBsfzvqAfu587V_FXp=OPgu3yeO-P8qw19jgwizuUhg@mail.gmail.com>
In-Reply-To
<014b01dc16b2$4a1dd0d0$de597270$@nexbridge.com>
On Tue, Aug 26, 2025 at 10:53 AM <rsbecker@nexbridge.com> wrote:
Show 36 quoted lines
>
> On August 26, 2025 1:45 PM, Kyle Lippincott wrote:
> >On Tue, Aug 26, 2025 at 9:04 AM David Aguilar <davvid@gmail.com> wrote:
> >>
> >> The "cargo build" invocations in contrib/ cannot be run in parallel.
> >>
> >> "make -JN" with INCLUDE_LIBGIT_RS enabled causes cargo lock warnings
> >> and can trigger ld errors during the build.
> >>
> >> The build errors are caused by two inner "make" invocations getting
> >> triggered concurrently: once inside of libgit-sys and another inside
> >> of libgit-rs.
> >>
> >> Signed-off-by: David Aguilar <davvid@gmail.com>
> >> ---
> >>  Makefile | 2 +-
> >>  1 file changed, 1 insertion(+), 1 deletion(-)
> >>
> >> diff --git a/Makefile b/Makefile
> >> index 29a53520fd..286d3ba3b2 100644
> >> --- a/Makefile
> >> +++ b/Makefile
> >> @@ -3989,7 +3989,7 @@ libgit-sys libgit-rs:
> >>                 cargo build \
> >>         )
> >>  ifdef INCLUDE_LIBGIT_RS
> >> -all:: libgit-sys libgit-rs
> >> +all:: libgit-sys .WAIT libgit-rs
> >
> >I'm not familiar enough with make or with rust, but do we need to depend on both
> >of these here? Wouldn't it be sufficient to say libgit-rs depends on libgit-sys, and
> >only explicitly depend on libgit-rs in `all::`?
>
> Not all platforms can build libgit-rs, so inserting it into as a required component is not
> a particularly friendly idea.
>

That's not what I was suggesting. This is already in an `ifdef`, and the line I was quoting was changing `all:: libgit-sys libgit-rs` to `all:: libgit-sys .WAIT libgit-rs`. I'm wondering if we can instead split the `libgit-sys libgit-rs:` from a few lines earlier into `libgit-sys:` and `libgit-rs: libgit-sys` and then change this all line to `all:: libgit-rs` (still behind `ifdef INCLUDE_LIBGIT_RS`).

Previous: rsbecker@nexbridge.comNext: rsbecker@nexbridge.com
Message 8 of 9 in “Makefile: build libgit-rs and libgit-sys serially”
  1. Makefile: build libgit-rs and libgit-sys seriallyDavid Aguilar, Aug 26, 2025
  2. Junio C HamanoAug 26, 2025
  3. Makefile: build libgit-rs and libgit-sys seriallyDavid Aguilar, Aug 26, 2025
  4. Kyle LippincottAug 26, 2025
  5. Junio C HamanoAug 27, 2025
  6. Kyle LippincottAug 26, 2025
  7. rsbecker@nexbridge.comAug 26, 2025
  8. Kyle LippincottAug 26, 2025
  9. rsbecker@nexbridge.comAug 26, 2025

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.