It has been revealed that Clang's `__builtin_setjmp` / `__builtin_longjmp` implementation can be buggy (https://bugs.llvm.org/show_bug.cgi?id=51729). We should instead use `_setjmp` / `_longjmp` provided by Bionic libc.
The configure argument `--with-coroutine=copy` was added because in the era of version 2.7 Ruby was defaulted to using `ucontext` for coroutine implementation on ARMv7, causing a build issue (https://github.com/termux/termux-packages/pull/5025). Now this configure argument is no longer necessary because Ruby version 3.0 (or later) by default uses "native" coroutine implementation for ARMv7 (and also for other three archs supported by Android).
Furthermore, `copy` coroutine implementation has its own deficiencies and is planned to be removed from Ruby 3.1 (https://bugs.ruby-lang.org/issues/18015). I see no reason to use `copy` coroutine where a working native implementation is available.
All packages that have conffiles, and a gz compressed control.tar.gz,
currently fails to install on arm if the deb is built locally or
downloaded and then installed with `apt install
./foo_1.0_arm.deb`. The error looks like:
$ apt install ./tmp/foo.deb
Reading package lists... Error!
E: Tar checksum failed, archive corrupted
E: Could not read meta data from
/data/data/com.termux/files/home/tmp/foo.deb
E: The package lists or status file could not be parsed or opened.
If the package does not have conffiles, or if xz compression is used,
everything works. Let's change back to xz compression for all new and
updated packages for now to workaround this issue.
Even if `apt install ./foo.deb` fails the deb can still be installed
with `dpkg -i ./foo.deb` (seems dpkg does not do the same checksum
check?).
Currently there is a problem building packages that use *-config
scripts (for example gnupg), we are creating a
/bin/sh->/data/data/com.termux/files/usr/bin/sh symlink so that the
shebang for the scripts can be interpreted, but after
ecd214881a ("build-package: add new arg -c for "continue build"") the
symlink was deleted in termux_step_get_dependencies.