Github messages for voidlinux
 help / color / mirror / Atom feed
From: kruceter <kruceter@users.noreply.github.com>
To: ml@inbox.vuxu.org
Subject: Re: ne: update to 3.3.2.
Date: Tue, 24 Jan 2023 06:50:54 +0100	[thread overview]
Message-ID: <20230124055054.9KXETscAtrSCiuTMMtI8olwNERWUnr1VVSZ5Wz4VGB0@z> (raw)
In-Reply-To: <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-40354@inbox.vuxu.org>

[-- Attachment #1: Type: text/plain, Size: 4128 bytes --]

New comment by kruceter on void-packages repository

https://github.com/void-linux/void-packages/pull/40354#issuecomment-1401427502

Comment:
Failing `armv6l-musl` is just a coincidence. From what I see in CI logs, it tries to generate headers while using gcc parallelly when generation had not yet been finished.

To prove my point, here is the extrace output:

```sh
/usr/bin/perl /usr/bin/makeinfo -D autohelp ne.texinfo
/usr/bin/perl /usr/bin/makeinfo -D autohelp ne.texinfo
/usr/bin/perl /usr/bin/makeinfo -D autohelp ne.texinfo
/bin/bash /builddir/.xbps-ne/wrappers/arm-linux-musleabihf-gcc -fstack-clash-protection '-D_FORTIFY_SOURCE=2' -O2 -pipe '-march=armv6' '-mfpu=vfp' '-mfloat-abi=hard' '-std=c99' -D_GNU_SOURCE -I/usr/arm-linux-musleabihf/usr/include '-ffile-prefix-map=/builddir/ne-3.3.2=.' -c -o ansi.o ansi.c
/usr/bin/arm-linux-musleabihf-gcc -fstack-clash-protection '-D_FORTIFY_SOURCE=2' -O2 -pipe '-march=armv6' '-mfpu=vfp' '-mfloat-abi=hard' '-std=c99' -D_GNU_SOURCE -I/usr/arm-linux-musleabihf/usr/include '-ffile-prefix-map=/builddir/ne-3.3.2=.' -c -o ansi.o ansi.c
/usr/lib/gcc/arm-linux-musleabihf/12.2.0/cc1 -quiet -I /usr/arm-linux-musleabihf/usr/include -D '_FORTIFY_SOURCE=2' -D _GNU_SOURCE ansi.c -quiet -dumpbase ansi.c -dumpbase-ext .c '-mfpu=vfp' '-mfloat-abi=hard' '-mtls-dialect=gnu' -marm '-mlibarch=armv6+fp' '-march=armv6+fp' -O2 '-std=c99' -fstack-clash-protection '-ffile-prefix-map=/builddir/ne-3.3.2=.' -o -
/usr/lib/gcc/arm-linux-musleabihf/12.2.0/../../../../arm-linux-musleabihf/bin/as -I /usr/arm-linux-musleabihf/usr/include '-march=armv6+fp' '-mfloat-abi=hard' '-mfpu=vfp' '-meabi=5' -o ansi.o
perl info2src.pl
/bin/sh -c 'rm -f ne.info*'
rm -f ne.info
perl info2src.pl
perl info2src.pl
```

And the relevant part of makefile for comparison:

```makefile
enums.h names.c names.h hash.c hash.h help.c help.h ext.c: ne.texinfo version.texinfo info2src.pl
	makeinfo -D autohelp ne.texinfo
	perl info2src.pl
	rm -f ne.info*
```

This recipe was supposed to be executed once to generate all of the listed target files, not by the amount of dedicated cpu cores.

Basically I see two ways to resolve this race: either generate headers and docs separately before `do_build`:

```diff
diff --git a/srcpkgs/ne/template b/srcpkgs/ne/template
index a2a33a66cf..85d06659a0 100644
--- a/srcpkgs/ne/template
+++ b/srcpkgs/ne/template
@@ -1,6 +1,6 @@
 # Template file for 'ne'
 pkgname=ne
-version=3.3.1
+version=3.3.2
 revision=1
 build_style=gnu-makefile
 hostmakedepends="perl texinfo"
@@ -11,8 +11,12 @@ license="GPL-3.0-only"
 homepage="http://ne.di.unimi.it/"
 changelog="https://raw.githubusercontent.com/vigna/ne/master/NEWS"
 distfiles="https://github.com/vigna/ne/archive/refs/tags/${version}.tar.gz"
-checksum=931f01380b48e539b06d65d80ddf313cce67aab6d7b62462a548253ab9b3e10a
+checksum=9b8b757db22bd8cb783cf063f514143a8c325e5c321af31901e0f76e77455417
 
-do_build() {
-	make CFLAGS="$CFLAGS -std=c99 -D_GNU_SOURCE" CC=$CC ${makejobs}
+CFLAGS="-std=c99 -D_GNU_SOURCE"
+
+pre_build() {
+	# docs and headers should be generated sequently before building
+	make -C doc
+	make -C src enums.h
 }
```

or disable parallel builds entirely by using `disable_parallel_build=yes`:

```diff
diff --git a/srcpkgs/ne/template b/srcpkgs/ne/template
index a2a33a66cf..f52de77d8b 100644
--- a/srcpkgs/ne/template
+++ b/srcpkgs/ne/template
@@ -1,6 +1,6 @@
 # Template file for 'ne'
 pkgname=ne
-version=3.3.1
+version=3.3.2
 revision=1
 build_style=gnu-makefile
 hostmakedepends="perl texinfo"
@@ -11,8 +11,7 @@ license="GPL-3.0-only"
 homepage="http://ne.di.unimi.it/"
 changelog="https://raw.githubusercontent.com/vigna/ne/master/NEWS"
 distfiles="https://github.com/vigna/ne/archive/refs/tags/${version}.tar.gz"
-checksum=931f01380b48e539b06d65d80ddf313cce67aab6d7b62462a548253ab9b3e10a
+checksum=9b8b757db22bd8cb783cf063f514143a8c325e5c321af31901e0f76e77455417
+disable_parallel_build=yes
 
-do_build() {
-	make CFLAGS="$CFLAGS -std=c99 -D_GNU_SOURCE" CC=$CC ${makejobs}
-}
+CFLAGS="-std=c99 -D_GNU_SOURCE"
```

  reply	other threads:[~2023-01-24  5:50 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-11-06  7:25 [PR PATCH] " mobinmob
2023-01-24  5:50 ` kruceter [this message]
2023-01-28 11:08 ` [PR PATCH] [Updated] " mobinmob
2023-01-28 11:09 ` mobinmob
2023-01-28 15:14 ` [PR PATCH] [Merged]: " Johnnynator
  -- strict thread matches above, loose matches on Subject: below --
2022-10-04 11:01 [PR PATCH] ne: update to 3.2 tpar2911
2022-10-04 18:28 ` ne: update to 3.3.2 tpar2911
2022-10-04 18:28 ` tpar2911
2022-10-04 18:33 ` Duncaen
2022-10-04 18:35 ` tpar2911
2022-10-04 20:38 ` tpar2911
2022-10-04 20:45 ` Duncaen
2022-10-04 21:10 ` tpar2911
2022-10-04 21:14 ` Duncaen
2022-10-04 21:16 ` tpar2911

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230124055054.9KXETscAtrSCiuTMMtI8olwNERWUnr1VVSZ5Wz4VGB0@z \
    --to=kruceter@users.noreply.github.com \
    --cc=ml@inbox.vuxu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).