[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: broken build environment - explanation and fix
From: |
Bruno Haible |
Subject: |
Re: broken build environment - explanation and fix |
Date: |
Sun, 19 Feb 2023 16:19:08 +0100 |
Arsen Arsenović wrote:
> IIRC, the JITTER executable is not built in the cross case from
> dists. Do you know if this still work with this dependency added?
> (i.e. run distcheck and build a cross-compiled poke from the new dist)
Good point. When cross-compiling, the JITTER (= jitter/bin/jitter)
executable does get built, but it cannot be executed:
make[3]: Entering directory '/POKE/poke/build-arm64/libpoke'
/POKE/poke/build-arm64/jitter/bin/jitter ../../libpoke/pvm.jitter --output . \
&& { test . = ../../libpoke \
|| { mv pvm-vm.h ../../libpoke/pvm-vm.h \
&& mv pvm-vm1.c ../../libpoke/pvm-vm1.c \
&& mv pvm-vm2.c ../../libpoke/pvm-vm2.c; \
}; \
} \
|| { rm -f pvm-vm.h pvm-vm1.c pvm-vm2.c; false; }
/bin/bash: line 1: /POKE/poke/build-arm64/jitter/bin/jitter: cannot execute
binary file: Exec format error
make[3]: *** [Makefile:3572: generate-vm-files] Error 1
So, with the patch I proposed yesterday, the ability to cross-compile
would get lost. Here's a revised patch. It emits a
warning: not regenerating pvm-vm.h, pvm-vm[12].c since we are cross-compiling
instead.
The warning is justified, because if pvm-vm.h, pvm-vm[12].c are outdated
(like it was for me yesterday) we would not know, and the build might
continue but produce broken binaries.
New proposed patch is attached.
0001-build-Regenerate-pvm-vm.h-pvm-vm1.c-pvm-vm2.c-when-j.patch
Description: Text Data