1
0
mirror of https://github.com/termux/termux-packages synced 2024-06-18 22:57:07 +00:00
Commit Graph

78 Commits

Author SHA1 Message Date
Henrik Grimler
ccf6ab9292
updpkg(main/termux-elf-cleaner): update to 2.2.1 2023-12-26 10:25:40 +01:00
Henrik Grimler
552a504c8b
bump(main/termux-elf-cleaner): update to 2.2.0
Now we can clean packages in multiple threads!
2023-12-16 13:26:10 +01:00
Ivan Max
a46e3e9357
build-package.sh: adding compilation based on glibc (#16901)
[skip ci]
2023-08-30 23:40:08 +03:00
Henrik Grimler
af18f1dac0
scripts: start_build: create libpthread and librt as well
Their functionality is included in libc, but some packages anyways
searches for libpthread.so and librt.so.  Provide these files so that
such configure steps succeed.
2023-02-10 13:52:30 +01:00
Henrik Grimler
9063e5919f
scripts: move libutil.so creation to termux_step_start_build
Instead of in termux_setup_toolchain_XX.  This helper lib does really
not have anything to do with our toolchain so it does not belong in
termux_setup_toolchain.

It is also good to only modify $TERMUX_PREFIX (for other things than
make install) before termux_step_create_timestamp_file has been run,
and termux_step_start_build fits that criteria.
2023-02-10 13:52:28 +01:00
Maxython
d97b8c353b scripts: add termux_setup_python_pip function
It replaces termux_setup_python_crossenv and can be used when
compiling python packages.  Packages should specify their python
dependencies in TERMUX_PKG_PYTHON_TARGET_DEPS,
TERMUX_PKG_PYTHON_BUILD_DEPS, and TERMUX_PKG_PYTHON_COMMON_DEPS.
2023-01-16 09:29:47 +03:00
Ivan Max
83f6e7acfd
build-package.sh: fix bug with TERMUX_FORCE_BUILD and add new flag -F (TERMUX_FORCE_BUILD_DEPENDENCIES) (#13861)
This add-on requires careful review and testing, but this will not interfere with compiling packages.

Co-authored-by: agnostic-apollo <agnosticapollo@gmail.com>

%ci:no-build
2023-01-03 18:04:40 +03:00
Tee KOBAYASHI
3f1be51372 Append share/pkgconfig to PKG_CONFIG_LIBDIR 2022-11-09 08:19:05 +00:00
Henrik Grimler
5df676bf3a
scripts(setup_toolchain): keep toolchain revision in setup function
Having it in termux_step_start_build is confusing, have it next to
related code instead.
2022-08-13 12:19:54 +02:00
Henrik Grimler
146a5fb9c8
scripts(start_build): fix typo
Fixes 8129569eef ("scripts: fix for building on device")
2022-07-31 19:00:35 +02:00
Li Chong Yun
8129569eef
scripts: fix for building on device
The pre-built binary cannot execute on device. Use the one from repo instead.
2022-07-31 18:56:55 +02:00
Henrik Grimler
5d07daf772
scripts(start_build.sh): download pre-compiled termux-elf-cleaner
CI now compiles the program on every release, so lets download that
instead of the source in termux_step_start_build.sh.
2022-07-30 16:44:05 +02:00
Henrik Grimler
5be1ac63f0
ci(setup-android-sdk.sh): update to ndk r23c 2022-06-23 20:29:28 +02:00
agnostic-apollo
0275d9bff3 changed(scripts|main/termux-tools): Use TERMUX_APP_PACKAGE_MANAGER instead of TERMUX_MAIN_PACKAGE_FORMAT
Make changes as per new design implemented in termux/termux-app@b950efec and termux/termux-app#2740

The package build and termux-tools scripts use current package manager for custom logic. The `termux-tools/termux-setup-package-manager` script has been added that will now be used to provide backward compatibility for termux-app `< 0.119.0` (when its released) and validate the package manager. It will also ensure the variable in not unset to prevent `unbound variable` errors if `set -u` is being used by calling scripts.

Closes #10782
2022-05-23 12:14:55 +05:00
Tee KOBAYASHI
2a1524d67c ndk-patches: Don't declare sem_{open,close,unlink}
but instead declare `libandroid_sem_{open,close,unlink}` defined in
`libandroid-posix-semaphore`.
2022-03-26 00:02:59 +09:00
Henrik Grimler
7502d684d8
build-package: create $PREFIX/bin/sh->/bin/sh symlink later
We need to run it after termux_step_get_dependencies, or else the
symlink might be overridden if dash is a dependency, since it contains
a sh->dash symlink.

termux_step_override_config_scripts is run right after
termux_step_get_dependencies, and feels seems like a logical place to
create the symlink (since symlink is used to make config scripts
executable).
2022-03-13 13:58:37 +01:00
Henrik Grimler
0e9c95fd90
toolchain/ndk-sysroot: let mesa provide KHR/khrplatform.h
The headers are nearly identical, use the one from mesa to ensure
compatibility with mesa.
2022-03-09 09:28:40 +01:00
Henrik Grimler
3879280345
ndk-patches: remove wait3 patch from sys/wait.h
It was added specifically for busybox, and busybox > 1.33 now
implements its own workaround, so should hopefully be no need for this
patch anymore.
2022-03-01 21:45:47 +01:00
Maxython
465159a72e
build-package.sh: change logic for package manager selection to be more stable
termux_step_setup_variables: added logic with TERMUX_PACKAGE_FORMAT
for easier compilation.
2022-02-11 22:38:40 +01:00
Ivan Max
ece5419863
build-package.sh: setting up to work with pacman (#8451) 2022-01-14 15:16:37 +02:00
Yaksh Bariya
c15b7f17bf
ndk-sysroot: bump revision after removing patch for mntent.h
Also bump toolchain version
2022-01-03 19:21:36 +05:30
Yaksh Bariya
dd647ac3c7 toolchain: bump revision 2021-12-12 10:07:41 +05:30
Tee KOBAYASHI
e4f761f9da toolchain: Bump version 2021-12-05 11:52:23 +02:00
Lucy Phipps
369d15f4ef
ndk-patches: disable AT_EACCESS
https://android.googlesource.com/platform/bionic.git/+/refs/tags/ndk-r23b/libc/bionic/faccessat.cpp#50
2021-11-29 07:58:58 +00:00
xtkoba
7c228b846e
ndk-patches: Add IFTODT and DTTOIF to dirent.h (#8041)
ndk-patches: Add IFTODT and DTTOIF to dirent.h
2021-11-23 10:12:17 +01:00
Henrik Grimler
d5ba6ecc6b toolchain: fix broken as symlinks in r23b
r23b was suppose to fix so that -fno-integrated-as worked again (which
libx265 needs for example), but the symlinks added point towards an
absolute path in /buildbot/src/android/ndk-release-r23 instead of to
../../bin/. Re-create symlinks with correct destination.
2021-10-23 15:57:11 +02:00
Lucy Phipps
2a62732791
termux-elf-cleaner: update to 1.10 2021-10-23 09:47:06 +01:00
Henrik Grimler
a465f14c90 Update to use android-ndk r23 2021-10-22 23:05:45 +02:00
Henrik Grimler
26da480d36 build-package: mv code for creating llvm-config
After https://github.com/termux/termux-packages/commit/e34ae5da030d,
llvm-config was created before termux_step_get_dependencies, meaning
that it gets overwritten if libllvm is installed.

Fix this by creating llvm-config in a new function
termux_step_override_config_scripts, that is run right after
termux_step_get_dependencies.
2021-09-17 12:02:53 +02:00
Henrik Grimler
b782c7da0e toolchain: add -fPIC to CPPFLAGS for i686
When adding this, we go from compiling with

  /home/builder/.termux-build/_cache/android-r21d-api-24-v4/bin/clang++ [...] -mrelocation-model pic -pic-level 2 -pic-is-pie [...]

to

  /home/builder/.termux-build/_cache/android-r21d-api-24-v5/bin/clang++ [...] -mrelocation-model pic -pic-level 2 [...]

Before, we got a warning when compiling libandroid-spawn:

  /home/builder/.termux-build/_cache/android-r21d-api-24-v4/bin/../lib/gcc/i686-linux-android/4.9.x/../../../../i686-linux-android/bin/ld: warning: shared library text segment is not shareable

and trying to use a program linked against libandroid-spawn gave an
error, see
https://github.com/termux/termux-packages/issues/7215#issuecomment-906154438
the Without this, libraries might end up with text relocations. For
some reason it does not seem to be an issue on the other arches.

%ci:no-build
2021-08-27 10:02:20 +02:00
Henrik Grimler
6445645d7e build-package: mv code for setting up src and build to to its own function
%ci:no-build
2021-08-24 21:40:46 +02:00
Henrik Grimler
12e395d3a9 step_configure_cmake: mv cmake and ninja setup functions to step_configure
Only keep actual configure steps in termux_step_configure_cmake. This
way we can skip termux_step_configure_cmake on a continued build.
2021-08-24 21:40:46 +02:00
Henrik Grimler
3407018962 build-package: error if hostbuilt tools are missing 2021-08-24 21:40:46 +02:00
Henrik Grimler
ecd214881a build-package: add new arg -c for "continue build"
As replacement for TERMUX_PKG_QUICK_REBUILD. Running
./build-package.sh -c <package> starts a build for <package>, but does
not extract and patch the source from scratch. Instead it sets up the
build variables and starts from termux_step_make.

When working on a big package that can take hours to build it is
convenient to be able to build until there is an error, then apply
some new patch (manually) to the source, and then continue from where
the build failed.
2021-08-24 21:40:46 +02:00
Henrik Grimler
23530a540c build-package: create timestamp file after get_dependencies
Fixes issue introduced in e34ae5da03.
2021-08-21 22:37:51 +02:00
Henrik Grimler
23e760143b termux_step_start_build: get llvm version in standard way
And fix indentation, and remove echo of llvm version.
2021-08-21 21:04:43 +02:00
Henrik Grimler
0c8a398d0e termux_step_start_build: remove some extra spaces 2021-08-21 20:59:24 +02:00
Henrik Grimler
e34ae5da03 build-package: mv code for getting deps out of step_start_build
Into new function termux_step_get_dependencies.
2021-08-21 20:59:24 +02:00
Henrik Grimler
2c70621a98 build-package: rename TERMUX_DEBUG to TERMUX_DEBUG_BUILD
To make it more self-explanatory.
2021-08-21 20:55:57 +02:00
Henrik Grimler
bd6bc93daf termux_step_start_build: strip prefixed ./ if found
All, or at least most, of our debs contain "./" as a folder. This
causes problems when extracting on some systems, as ./ then is the
system root directory /, and tar cannot change the permissions of this
folder.  Trying to build on arch for example gives:

    tar: .: Cannot change mode to rwxr-xr-x: Operation not permitted
    tar: Exiting with failure status due to previous errors

The issue appeared on arch somewhat recently, maybe with tar 1.33. To
avoid having to rebuild all packages we now handle both data.tar.xz
types, with prefixed ./, and without.

Also remove some indentation levels while we are at it.
2021-08-17 15:22:18 +02:00
Henrik Grimler
54975d7db5 ndk-headers: fix paths in utmp.h
And bump toolchain and ndk-sysroot. Also update patch offsets while we
are at it.
2021-05-07 08:28:05 +02:00
Henrik Grimler
12163bb879 termux_step_start_build: convert spaces to tabs 2021-02-03 16:57:04 +01:00
Butta
fb6c106c22 termux_step_start_build: define TERMUX_STANDALONE_TOOLCHAIN before sourcing the package's build script, so the host build can use it if wanted 2020-04-09 13:09:38 +03:00
buttaface
faf325b6d0 TERMUX_PKG_QUICK_REBUILD: disable reapplying the host build patches too (#5110) 2020-04-02 21:32:31 +02:00
Butta
3af25bc2a9 Introduce TERMUX_PKG_QUICK_REBUILD
This new variable is extremely useful when iterating on creating a large package,
as otherwise you have to wipe the source and rebuild each time you make a mistake
with the patches or build.sh script.

Simply set TERMUX_PKG_QUICK_REBUILD=true in build.sh if a build fails and then the
TERMUX_PKG_SRCDIR and TERMUX_PKG_BUILDDIR will not be touched when you rebuild,
including that the patches will not be applied again. When you're done iterating,
diff for any new patches, save them, and remove this variable before rebuilding
from scratch, hopefully for the last time. ;)

An example is shown for the giant libllvm package, where other modifications are
also excluded if this variable is set.
2020-02-15 13:38:30 +05:30
Fredrik Fornwall
b34c8fb32b Force toolchain update after ifaddrs.h and syslog.h changes 2019-12-29 23:53:09 +01:00
its-pointless
b6980935d4 experiment generating llvm-config 2019-10-26 16:46:24 +11:00
Fredrik Fornwall
937b78d0c4 Define __TERMUX__ and __TERMUX_PREFIX__
By defining __TERMUX__ and __TERMUX_PREFIX__ in <sys/cdefs.h> (which is
basically always included) one can more easily target Termux
specifically, both when cross-compiling packages and when code is built
on-device.
2019-09-19 21:34:04 +02:00
Leonid Pliushch
1a33848a02 termux-elf-cleaner: update to v1.7 2019-08-15 21:48:07 +03:00
Leonid Pliushch
5493481c5c build-package.sh: better support for metapackages 2019-08-14 20:29:58 +03:00