-
-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some packages cannot be built 2: Electric boogaloo #21130
Comments
Fixes the current rust 1.80 build failure (#21130).
Switch from freedesktop.org to www.freedesktop.org as the former has an invalid certificate, fixing the build error noted in #21130.
Fixes the build failure in (#21130) by backporting kakoune-lsp/kakoune-lsp@bb9734c As kak-lsp does seem to have rather regular releases, another alternative could be awaiting the next release which will include this.
Fixes the current rust 1.80 build failure (#21130).
Fixes the build failure in (#21130) by backporting kakoune-lsp/kakoune-lsp@bb9734c As kak-lsp does seem to have rather regular releases, another alternative could be awaiting the next release which will include this.
Switch from freedesktop.org to www.freedesktop.org as the former has an invalid certificate, fixing the build error noted in #21130.
Started the second batch, looks like mostly simple linker problems so far. |
I know the reason for this error |
Figured it'd be quicker to just leave that one for you to figure out. |
Just finished the second batch, that officially puts us at 51 problems. |
See https://github.com/s-yata/marisa-trie/blob/master/COPYING.md Fixes build failure noted in #21130
See https://github.com/s-yata/marisa-trie/blob/master/COPYING.md Fixes build failure noted in #21130
We're up to 80 now. |
148 now. I've decided to clean up my build container, I think we get that everything that depends on |
@Maxython I can't get |
I'll do a recheck later today. |
After applying all the WIP PRs in this thread, I can now consistently reproduce that error by using Here's what the full context looks like for that error with INFO: Identifying files with nproc=32
INFO: Done ... 0s
INFO: Found 1 / 2 files
INFO: Running symbol checks on 1 files with nproc=32
INFO: Done ... 0s
termux - build of 'skate' done
done in 14 sec
Building sl... termux - building sl for arch aarch64...
Building dependency ncurses if necessary...
[email protected] built - skipping (rm /data/data/.built-packages/ncurses to force rebuild)
Downloading https://github.com/eyJhb/sl/archive/5.05.tar.gz
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
100 631k 0 631k 0 0 642k 0 --:--:-- --:--:-- --:--:-- 1280k
Applying patch: makefile.patch
aarch64-linux-android-clang -fstack-protector-strong -Oz -isystem/data/data/com.termux/files/usr/include -L/data/data/com.termux/files/usr/lib -Wl,-rpath=/data/data/com.termux/files/usr/lib -Wl,--enable-new-dtags -Wl,--as-needed -Wl,-z,relro,-z,now -o sl sl.c -lncurses
sl.c:51:10: fatal error: 'curses.h' file not found
51 | #include <curses.h>
| ^~~~~~~~~~
1 error generated.
make: *** [Makefile:12: sl] Error 1
ERROR: See /home/builder/.termux-build/_buildall-aarch64/sl.out
tacokoneko@CORSAIR ~/code/termux/electric-boogaloo/termux-packages $ scripts/run-docker.sh
Running container 'termux-package-builder' from image 'ghcr.io/termux/package-builder'...
builder@78bc2abe14fb:~/termux-packages$ ls /data/data/com.termux/files/usr/include/curses.h
ls: cannot access '/data/data/com.termux/files/usr/include/curses.h': No such file or directory
builder@78bc2abe14fb:~/tmp$ ls /data/data/com.termux/files/usr/lib/libncursesw.so.6.5
/data/data/com.termux/files/usr/lib/libncursesw.so.6.5
builder@78bc2abe14fb:~/termux-packages$ ls output/ | grep curses
ncurses_6.5.20240831-1_aarch64.deb
ncurses-static_6.5.20240831-1_aarch64.deb
ncurses-ui-libs_6.5.20240831-1_aarch64.deb
ncurses-ui-libs-static_6.5.20240831-1_aarch64.deb
ncurses-utils_6.5.20240831-1_aarch64.deb
pomodoro-curses_2.5_aarch64.deb
builder@78bc2abe14fb:~/termux-packages$ mkdir ~/tmp
builder@78bc2abe14fb:~/termux-packages$ cd ~/tmp
builder@78bc2abe14fb:~/tmp$ ar x ~/termux-packages/output/ncurses_6.5.20240831-1_aarch64.deb
builder@78bc2abe14fb:~/tmp$ tar xf data.tar.xz
builder@78bc2abe14fb:~/tmp$ ls data/data/com.termux/files/usr/include/curses.h
data/data/com.termux/files/usr/include/curses.h
builder@78bc2abe14fb:~/tmp$ ls data/data/com.termux/files/usr/lib/libncursesw.so.6.5
data/data/com.termux/files/usr/lib/libncursesw.so.6.5
builder@78bc2abe14fb:~/tmp$ I can see that Root cause found: termux-packages/packages/simulavr/build.sh Lines 31 to 38 in 4ca64f8
the Done in #21835 |
Still getting a build error with
|
It is already fixed in CI since it commits to termux-packages repo.
AFAIK it does not pop up in non-interactive shell session (CI case). |
Ah must have not fetched that on my test branch yet. |
It is weird. In package_updates workflow it is done explicitly termux-packages/.github/workflows/package_updates.yml Lines 147 to 148 in 4ca64f8
Can not find similar lines in packages workflow, possibly because it does not need to commit changes to repo. In regular CI it is done by CI itself. Can not find proof but you can check repology-metadata repo, it has commits of Github Action worker. So I assume it handles some configuration. I am not sure about Docker, |
Found a consistent way to get it to work in the local build container. diff --git a/packages/bionic-host/build.sh b/packages/bionic-host/build.sh
index 7b87cca311..a3f5286e26 100644
--- a/packages/bionic-host/build.sh
+++ b/packages/bionic-host/build.sh
@@ -60,7 +60,7 @@ termux_step_get_source() {
cd ${TERMUX_PKG_SRCDIR}
cp -f ${TERMUX_PKG_BUILDER_DIR}/LICENSE.txt ${TERMUX_PKG_SRCDIR}/LICENSE.txt
-
+
for i in libtinfo5 libncurses5 openssh-client; do
local URL="$(obtain_deb_url $i)"
wget "$URL" -O ${TERMUX_PKG_CACHEDIR}/${URL##*/}
@@ -72,10 +72,16 @@ termux_step_get_source() {
termux_download https://storage.googleapis.com/git-repo-downloads/repo ${TERMUX_PKG_CACHEDIR}/repo SKIP_CHECKSUM
chmod +x ${TERMUX_PKG_CACHEDIR}/repo
+ (
+ # Repo requires us to have a Git user name and email set.
+ # The GitHub workflow does this, but the local build container doesn't
+ [[ "$(git config --get user.name)" != '' ]] || git config --global user.name "Termux Github Actions"
+ [[ "$(git config --get user.email)" != '' ]] || git config --global user.email "[email protected]"
${TERMUX_PKG_CACHEDIR}/repo init \
-u https://android.googlesource.com/platform/manifest \
- -b main -m ${TERMUX_PKG_BUILDER_DIR}/default.xml
+ -b main -m ${TERMUX_PKG_BUILDER_DIR}/default.xml <<< 'n'
${TERMUX_PKG_CACHEDIR}/repo sync -c -j32
+ )
sed -i '1s|.*|\#!'${TERMUX_PKG_SRCDIR}'/prebuilts/python/linux-x86/2.7.5/bin/python2|' ${TERMUX_PKG_SRCDIR}/bionic/libc/fs_config_generator.py
sed -i '1s|.*|\#!'${TERMUX_PKG_SRCDIR}'/prebuilts/python/linux-x86/2.7.5/bin/python2|' ${TERMUX_PKG_SRCDIR}/external/clang/clang-version-inc.py We can just feed an |
Okay so |
Update: Reproduced with Update: Bisected to Fixes and improvements to scripts for working with cyclic dependencies #20513 Cloning a clean copy of termux/termux-packages and running its original git clone https://github.com/termux/termux-packages.git
cd termux-packages/
# while i was troubleshooting, fornwall pushed a commit to termux-am,
# so i need to temporarily do this here to retain a consistent test methodology
# see the next comment for all the results of all the same tests on termux-am
# performed on a termux-packages copy AFTER commit a7627acf5a8104ff5634330110ff9acd661c09d8
git checkout 70aa9cf1372220b6bacfc9ac51321f12b11558fa
scripts/run-docker.sh
mkdir -p ~/.termux-build/_buildall-aarch64/
echo 'termux-am packages/termux-am' > ~/.termux-build/_buildall-aarch64/buildorder.txt
echo 'procyon-decompiler packages/procyon-decompiler' >> ~/.termux-build/_buildall-aarch64/buildorder.txt
./build-all.sh ^ Result of above: success with no hang Building
If you want, it is possible to quickly reproduce the problem by applying Fixes and improvements to scripts for working with cyclic dependencies #20513 and then this temporary patch to use the --- a/build-all.sh
+++ b/build-all.sh
@@ -75,6 +75,11 @@ exec &> >(tee -a "$BUILDALL_DIR"/ALL.out)
trap 'echo ERROR: See $BUILDALL_DIR/${PKG}.out' ERR
while read -r PKG PKG_DIR; do
+ # TEMPORARY TEST
+ if [ "$PKG" != "termux-am" ] && [ "$PKG" != "procyon-decompiler" ]; then
+ continue
+ fi
+
# Check build status (grepping is a bit crude, but it works)
if [ -e "$BUILDSTATUS_FILE" ] && grep -q "^$PKG\$" "$BUILDSTATUS_FILE"; then
echo "Skipping $PKG" This is what the log looks like at the bottom when it hangs.
(Frozen)
(Frozen) I will troubleshoot this and try to find any convenient way to bypass this hang, to complete another necessary step in the process of making |
Fixes gradle hanging sometimes, see: - #21130 (comment) - gradle/gradle#14961
@robertkirkman Regarding gradle hanging, check out: gradle/gradle#14961 As it's reported there that the problem no longer exists under gradle 8.9, I've merged a PR bumping the gradle version in termux-am: #21857. Does that fix the issue reliably when you test? You're welcome to create additional PR:s for other packages, bumping gradle or (if it's not easy to bump gradle for certain packages) piping - $TERMUX_PKG_TMPDIR/gradle/gradle-$_GRADLE_VERSION/bin/gradle \
+ echo -n | $TERMUX_PKG_TMPDIR/gradle/gradle-$_GRADLE_VERSION/bin/gradle \ |
Fixes gradle hanging sometimes, see: - #21130 (comment) - gradle/gradle#14961
Fixes gradle hanging sometimes, see: - termux/termux-packages#21130 (comment) - gradle/gradle#14961
@fornwall Thank you! Eventually, i detected that the problem also consistently bisected to #20513 , so I guess it would appear there is a problematic interaction between #20513 and Gradle < 8.9. Here are my results for the same tests I did, but after your commit a7627ac instead of before.
|
TERMUX_PKG_DEPENDS="openjdk-17" |
git clone https://github.com/termux/termux-packages.git
cd termux-packages/
curl https://patch-diff.githubusercontent.com/raw/termux/termux-packages/pull/20513.diff | git apply -v
patch --ignore-whitespace << 'EOF'
--- a/build-all.sh
+++ b/build-all.sh
@@ -75,6 +75,9 @@ exec &> >(tee -a "$BUILDALL_DIR"/ALL.out)
trap 'echo ERROR: See $BUILDALL_DIR/${PKG}.out' ERR
while read -r PKG PKG_DIR; do
+ if [ "$PKG" != "procyon-decompiler" ]; then
+ continue
+ fi
# Check build status (grepping is a bit crude, but it works)
if [ -e "$BUILDSTATUS_FILE" ] && grep -q "^$PKG\$" "$BUILDSTATUS_FILE"; then
echo "Skipping $PKG"
EOF
scripts/run-docker.sh ./build-all.sh
❌ Hanging
Based on your suggestion and these results, it looks like, to continue using #20513 in its unmodified form, a separate PR should also be opened to update the Gradle versions used by the builds of procyon-decompiler
and any other packages affected by a similar situation. I will try to do that now.
plantuml
The issue is also reproducible with this final package dependent on the Gradle build tool because the current release of plantuml
, 1.2024.7, pulls in Gradle 8.2. However, I believe it might be easy to cherrypick and use this commit in the upstream development branch of plantuml
that bumps its Gradle version to 8.10, very similarly to what you did to fix the equivalent problem in termux-am
. I'll most likely try that approach for fixing plantuml
.
Yep that is expected behavior with the testing procedure outlined above as we want to verify that all packages can be "bootstrapped" without needing to rely on precompiled dependencies. Since we've already validated the dependencies in this instance you can skip that and just build ./scripts/run-docker.sh ./build-package.sh -f -I -a all termux-am Just be aware that validating "bootstrapability" is the main goal, so only use |
Well, I have explained that the problem described in the last few comments is only reproducible specifically when using the PR listed as one of those for testing in this issue, #20513 plus specifically the For example, you can see that fornwall's recent commit a7627ac does not have an observable impact on the result of the entrypoint " git clone https://github.com/termux/termux-packages.git
cd termux-packages
git checkout 70aa9cf1372220b6bacfc9ac51321f12b11558fa
./scripts/run-docker.sh ./build-package.sh -f -I -a all termux-am git clone https://github.com/termux/termux-packages.git
cd termux-packages
./scripts/run-docker.sh ./build-package.sh -f -I -a all termux-am The result in both of the examples above is exactly the same in every way other than that in the first case the resulting package built is version It is possible that maybe what you specifically mean is that I should also modify the |
Fixes gradle hanging under certain conditions in the two remaining packages where the issue could be reproduced. See: - termux#21130 (comment) - gradle/gradle#14961 - termux@a7627ac plantuml patch cherry picked from: - plantuml/plantuml@53a2a8d
Fixes gradle hanging under certain conditions in the two remaining packages where the issue could be reproduced. See: - termux#21130 (comment) - gradle/gradle#14961 - termux@a7627ac plantuml patch cherry picked from: - plantuml/plantuml@53a2a8d [no ci]
…10.2 Fixes gradle hanging under certain conditions in the two remaining packages where the issue could be reproduced. See: - termux#21130 (comment) - gradle/gradle#14961 - termux@a7627ac [no ci]
I forgot to really mention this anywhere until now that I build it again, but 1 month ago i discovered that the docker container stop termux-package-builder
docker container rm termux-package-builder
git clone https://github.com/termux/termux-packages.git
cd termux-packages/
scripts/run-docker.sh ./build-package.sh -f aalib
However, fortunately it's very easy to fix using the I think what I was wondering is, since the In order to avoid spamming PRs I will wait until after my other open PR goes through the process before I start opening a bunch more. |
That sounds reasonable to me. |
Important
Build validation should be done without use of the "fast build"
-i
/-I
flags!termux-packages/build-package.sh
Lines 417 to 418 in ed5c640
e.g.
We want to verify that every package can be "bootstrapped" without the need for pre-compiled dependencies.
./scripts/run-docker.sh ./build-all.sh
Fixes and improvements to scripts for working with cyclic dependencies #20513
toolchain: add API guard for
timezone_t
#21120 (Batch 4 onwards)List of packages that ran into build issues
Batch 1
repo
SHA256 verification #21825)termux-packages/build-all.sh
Line 91 in b2291c8
kak-lspkakoune-lsp (rust: time crate, known issue, fix(main/kak-lsp): Backport patch to fix building with rust 1.80 #21134)timezone_t
#21120)Batch 2
timezone_t
#21120)timezone_t
#21120)error: ld.lld: /data/data/com.termux/files/usr/lib/libncursesw.so is incompatible with elf64-x86-64
) (dont usebuild-all.sh
)tag rereleased, change sha256fixed by autoupdate)Batch 3 - now at commit de39934
timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)Please add -D_FILE_OFFSET_BITS=64 to your compile flags!
)Please add -D_FILE_OFFSET_BITS=64 to your compile flags!
)timezone_t
#21120)timezone_t
#21120)/bin/sh: 1: /data/data/com.termux/files/usr/bin/ccache: Exec format error
)Aborted (core dumped)
)timezone_t
#21120)libandroid-shmem
explicitly #21172)timezone_t
#21120)timezone_t
#21120)clang++: error: unsupported option '-mfpu=' for target 'aarch64-linux-android24'
)clang++: error: unsupported option '-mfpu=' for target 'aarch64-linux-android24'
)curl/curl.h
)Aborted (core dumped)
)./configure: 437: /data/data/com.termux/files/usr/bin/lua5.4: Exec format error
)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)libz
problems)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)timezone_t
#21120)Batch 4 - now at commit 51516dd + #21120 applied
-Wunused-but-set-variable
)Did not find CMake 'cmake'
)bionic-host
, pypy: bump to 7.3.16 #21197)wasn't this supposed to be fixed in pypy: fix build #21026?
ERROR: Could not find a version that satisfies the requirement numpy==1.26.5
)Download of gobject-introspection from https://packages-cf.termux.dev/apt/termux-main failed
)Batch 5 - now at commit 9016ef0 + #21120 applied
ERROR: Could not find a version that satisfies the requirement numpy==1.26.5
)hunspell
dependency is really slow to download)ERROR: Failed running '/data/data/com.termux/files/usr/bin/llvm-config', binary or interpreter not executable.
)bionic-host
)failed to execute command: "/data/data/com.termux/files/usr/bin/llvm-config" "--version"; ERROR: Exec format error (os error 8)
)cp: cannot create regular file '/etc/dbus-1/system.d/#inst.2175092#': Permission denied
)cp: cannot create regular file '/etc/dbus-1/system.d/#inst.2175092#': Permission denied
)apt
's source change,Failed to download https://mirrors.kernel.org/debian/pool/main/d/dpkg/dpkg_1.22.6.tar.xz
)configure: error: Unable to link with libxml
)ERROR: Could not find a version that satisfies the requirement numpy==1.26.5
)configure: error: invalid ltdl library directory: '/data/data/com.termux/files/usr/lib'
)hunspell
dependency is really slow to download)configure: error: Unable to locate required GL library
)hunspell
dependency is really slow to download)hunspell
dependency is really slow to download)hunspell
dependency is really slow to download)hunspell
dependency is really slow to download)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)ERROR: Could not find a version that satisfies the requirement numpy==1.26.5
)EGL/eglplatform.h
, revbump(x11/deadbeef): remove -msse3 to fix build with NDK r27 #21501)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
, bump(x11/thunderbird): 128.2.0 #21486, [Bug]: thunderbird with Segmentation fault on armv7l devices. #21511)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
, probably also valac)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)EGL/eglplatform.h
)I'll update this as I go.
The text was updated successfully, but these errors were encountered: