Package: src:ck
Version: 0.7.1-10
Severity: important
Tags: patch
Dear maintainer:
During a mass rebuild of all packages in bookworm, this
package failed to build in this way:
[...]
barrier_centralized
Creating threads (barrier)...done
Waiting for threads to finish correctness regression...WARNING: Could not
affine thread: Invalid argument
E: Build killed with signal TERM after 60 minutes of inactivity
My machine has a single CPU, but I expect this to work, because
build-essential does not imply multicore.
To fix this, I first tried to change --cores=2 to --cores=1
in debian/rules, but that didn't work.
[ Note: I understand that this package is related to parallel processing,
and at this point you might be wondering why do I want to build it
on a single CPU system at all. Well, because Debian is based on
binary packages ("we are not Gentoo"), and the system on which the
package is finally used does not have to be the same as the system
on which the package was initially built ].
Anyway, I believe the right fix in this case is to disable the
test suite on systems on which we know the test suite will
hang the machine, as in the attached patch.
To reproduce the hang, just try GRUB_CMDLINE_LINUX="nr_cpus=1"
in /etc/default/grub.
Thanks.commit fbad1ce77ea0410d14b015e3cf2a8e0c72ba78cc
Author: Santiago Vila <[email protected]>
Date: Thu Nov 2 11:09:41 2023 +0100
Skip tests when DEB_BUILD_OPTIONS has parallel=1, because the machine hangs
in such case.
diff --git a/debian/rules b/debian/rules
index 70667c5..e91561b 100755
--- a/debian/rules
+++ b/debian/rules
@@ -15,6 +15,12 @@ ifeq ($(DEB_HOST_ARCH), i386)
PLATFORM = --disable-sse
endif
+ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
+ NUMJOBS = $(patsubst parallel=%,%,$(filter
parallel=%,$(DEB_BUILD_OPTIONS)))
+else
+ NUMJOBS = 1
+endif
+
%:
dh ${@}
@@ -37,5 +43,7 @@ override_dh_auto_configure:
override_dh_auto_test:
ifneq (,$(filter $(DEB_HOST_ARCH), amd64 arm64 i386))
+ifneq ($(NUMJOBS), 1)
$(MAKE) -j1 check
endif
+endif