Hello,
I reproduced the FTBFS with GNU make shuffle mode
(MAKEFLAGS=--shuffle=reverse).
The failure happened because the PNG verification step was executed
before the test programs ran.
The PNG files are created only when the tests are executed, but under
shuffle mode the check could run first due to missing ordering.
I fixed this by removing the custom check rule and moving the PNG
verification to check-local, with an explicit dependency on check-TESTS,
so the tests always run before the PNG check.
--- giza-1.5.0.orig/test/F90/Makefile.am
+++ giza-1.5.0/test/F90/Makefile.am
@@ -10,13 +10,10 @@ TESTS = $(ftests)
check_PROGRAMS = $(ftests)
AM_DEFAULT_SOURCE_EXT = .f90
-# Ensure that the tests are built as part of the 'check' target
-check: $(ftests) check_output_files
-
test_output_files = giza-test.png giza-test-2D.png
# Custom target to check for the existence of expected output files
from the Fortran tests
-check_output_files: $(ftests)
+check-local: check-TESTS
@echo "Checking for required png files..."
@for i in $(test_output_files); do \
if [ ! -s $$i ]; then \
@@ -26,4 +23,6 @@ check_output_files: $(ftests)
echo "$$i exists"; \
fi; \
done
- @echo "All required png files exist."
\ No newline at end of file
+ @echo "All required png files exist."
+
+
With this change, the package builds successfully under shuffle mode on
ppc64el
I have attached a patch that fixes the issue described above. I would
appreciate a review.
Thanks,
Trupti
Description: Fix test ordering under make shuffle mode
The PNG output files are generated only when the test programs are run.
Under GNU make shuffle mode, the PNG verification step could run before
the tests, causing build failures.
This patch makes the PNG check run after test execution by using
Automake's check-local hook with an explicit dependency on check-TESTS.
Bug-Debian: https://bugs.debian.org/1105355
Forwarded: no
Author: Trupti Shirsat <[email protected]>
Last-Update: 2026-02-05
--- giza-1.5.0.orig/test/F90/Makefile.am
+++ giza-1.5.0/test/F90/Makefile.am
@@ -10,13 +10,10 @@ TESTS = $(ftests)
check_PROGRAMS = $(ftests)
AM_DEFAULT_SOURCE_EXT = .f90
-# Ensure that the tests are built as part of the 'check' target
-check: $(ftests) check_output_files
-
test_output_files = giza-test.png giza-test-2D.png
# Custom target to check for the existence of expected output files from the Fortran tests
-check_output_files: $(ftests)
+check-local: check-TESTS
@echo "Checking for required png files..."
@for i in $(test_output_files); do \
if [ ! -s $$i ]; then \
@@ -26,4 +23,6 @@ check_output_files: $(ftests)
echo "$$i exists"; \
fi; \
done
- @echo "All required png files exist."
\ No newline at end of file
+ @echo "All required png files exist."
+
+