summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVincent Blut <vincent.debian@free.fr>2024-04-25 15:23:51 +0200
committerVincent Blut <vincent.debian@free.fr>2024-04-25 15:23:51 +0200
commitfcd2251e01cf4eb0fe9ff3890185d2d82f4cef7a (patch)
tree4274b12b9759d387f593d67d0abe5fefde2d89cf
parent6bccc54251415cace2c4d47ec1d63acc2dcbb5a6 (diff)
d/t/upstream-simulation-test-suite: Build clknetsim with extra CFLAGS on armel and armhf
clknetsim needs to use the same time_t as the chronyd binary.
-rw-r--r--debian/tests/upstream-simulation-test-suite10
1 files changed, 9 insertions, 1 deletions
diff --git a/debian/tests/upstream-simulation-test-suite b/debian/tests/upstream-simulation-test-suite
index 427c710..cc3e6a8 100644
--- a/debian/tests/upstream-simulation-test-suite
+++ b/debian/tests/upstream-simulation-test-suite
@@ -17,6 +17,7 @@ export CLKNETSIM_PATH="$AUTOPKGTEST_TMP"
export CLKNETSIM_RANDOM_SEED=24508
DEB_HOST_MULTIARCH=$(dpkg-architecture -qDEB_HOST_MULTIARCH)
+DEB_BUILD_ARCH=$(dpkg-architecture -qDEB_BUILD_ARCH)
# The simulation tests are only supported on Linux.
dpkg-architecture -ilinux-any || exit 77
@@ -27,7 +28,14 @@ prepare_clknetsim() {
-C "$CLKNETSIM_PATH" --strip-components=1 2>&1 || exit 77
if [ ! -x "$CLKNETSIM_PATH/clknetsim" ] && [ ! -e "$CLKNETSIM_PATH/clknetsim.so" ]; then
- make -C "$CLKNETSIM_PATH" 2>&1
+ case "$DEB_BUILD_ARCH" in
+ armel|armhf)
+ CFLAGS="-D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -D_TIME_BITS=64" make -C "$CLKNETSIM_PATH" 2>&1
+ ;;
+ *)
+ make -C "$CLKNETSIM_PATH" 2>&1
+ ;;
+ esac
fi
}