Commit Graph

34 Commits

Author SHA1 Message Date
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
Leonid Pliushch cc34b645d8 build-package.sh: fix problem when built packages are not being checked 2019-08-13 22:05:52 +03:00
Leonid Pliushch c14b5e7334 build-package.sh: more fixes for variable checking 2019-08-13 18:44:10 +03:00
Leonid Pliushch d08dc0fa13 build-package.sh: use text-based comparsion in conditionals instead of exit-code based 2019-08-13 02:03:47 +03:00
Leonid Pliushch c352216c63 packages: standardize values of several control variables for build.sh
Variables

 TERMUX_PKG_PLATFORM_INDEPENDENT
 TERMUX_DEBUG
 TERMUX_PKG_HAS_DEBUG
 TERMUX_PKG_ESSENTIAL
 TERMUX_SUBPKG_ESSENTIAL
 TERMUX_PKG_NO_STATICSPLIT
 TERMUX_PKG_BUILD_IN_SRC
 TERMUX_PKG_FORCE_CMAKE
 TERMUX_PKG_HOSTBUILD

should not accept arbitrary values for marking them "enabled". Instead
they should accept boolean values which makes them easier to handle and
also makes their meaning clear.

build-package.sh should make decision based on variable's value but not on
whether it is set or empty.

%ci:no-build
2019-08-12 18:49:13 +03:00
Leonid Pliushch e303212ae5 enable on-device builds
Partial compatibility for on-device builds.

There is no guarantee that it will be possible to build all available
packages and built packages will have same reliability that cross-compiled
but should solve "self-hosting" problems as much as possible.
2019-08-08 16:58:34 +03:00
Leonid Pliushch 06f048b540 build-package.sh: fix typo
Chmod has to be called recursively.
2019-07-04 14:44:48 +03:00
Leonid Pliushch 225b1c471f clean.sh & build-package.sh: avoid errors in case chmod's target dir is not exist 2019-07-04 14:29:06 +03:00
Leonid Pliushch f45ed59766 build-package.sh: fix rm problems when builddir/srcdir contains RO files 2019-07-04 14:09:44 +03:00
its-pointless 5eada22838 ndk-20 update 2019-06-19 20:26:31 +03:00
Henrik Grimler 9c0fd0513f build-package: licenses->LICENSES 2019-05-19 21:36:30 +03:00
Henrik Grimler 117ecbfb88 build-package: install licenses to $PREFIX/share/$PKG/LICENSE 2019-05-19 21:36:30 +03:00
Tom Yan d4d8aaeac9 build-package: fix unwind symbols hiding
Apparently because libgcc.a is now a linker script, `--exclude-libs libgcc.a` doesn't seem to do a thing. Also hiding symbols from libunwind.a.
2019-05-14 17:53:00 +03:00
Leonid Pliushch 9dda444a87 new package: libiconv 2019-05-05 21:29:36 +02:00
Leonid Pliushch b5ab2097ae Fast build fixes (#3696)
* Do not re=download release files.

* Efficiently handle dependencies: do not try to download \*.deb files when they already downloaded, do not try to extract them more than one time.
2019-04-21 18:05:39 +03:00
Leonid Pliushch 16aa9acb5d termux-elf-cleaner: update to v1.6
No changes if API level is >= 23.
2019-04-15 18:39:38 +03:00
Tom Yan dab21ee7b7 zlib-dev: breaks and replaces old ndk-sysroot
also bump toolchain version for z{lib,conf}.h removal
2019-04-14 16:00:23 +03:00
Tom Yan 5170610f52 zlib: add package 2019-04-14 16:00:23 +03:00
Fredrik Fornwall 2b4652804f Remove sys/capability.h from the NDK sysroot
The sys/capability.h file will be provided by libcap-dev.
2019-03-24 23:15:44 +01:00
Tom Yan bc217587fb build-package: handle -dev package download from buildorder.py 2019-03-23 17:31:40 +02:00
Leonid Pliushch c091cdc962 termux-elf-cleaner: update to v1.5
Now it no longer removes GNU version sections.
2019-03-12 14:20:07 +02:00
Leonid Pliushch 44d28f9f88 build-package.sh: prevent parallel runs in the same environment
Avoid corruption of the build environment if build-package.sh was
executed in 2 parallel sessions.
2019-03-06 17:01:19 +02:00
Leonid Pliushch 858c73d75a termux-elf-cleaner: update to v1.4
Provides fix for Android 5.
2019-03-04 14:58:10 +02:00
Henrik Grimler 2273e3f2a2 build-package: stop build if buildorder.py returns error 2019-03-03 13:27:47 +02:00
Henrik Grimler 531956ce02 build-package: call termux_get_repo_files in termux_step start_build
Prevents unnecessary re-downloads of repo files.
2019-03-03 13:27:47 +02:00
Henrik Grimler 530eddf30a build-package: add new env. var. TERMUX_PACKAGES_DIRECTORIES
Can be set to the path to packages/ directories in other repos (like
unstable-package/packages/, termux-root-packages/packages/,
..). buildorder.py then searches these directories for packages and
dependencies
2019-03-03 01:40:22 +02:00
Henrik Grimler 10fdf172d5 build-package: download dependencies recursively when fast-building
Use scripts/buildorder.py with a new -i flag to get all dependencies
(including subpackages). The script now also spits out both package
name and package dir, to make it easier to build packages from another
repo.
2019-03-03 01:40:22 +02:00
Henrik Grimler a5956bf91e termux_step_start_build: handle failed subpackage downloads
Build parent package instead of trying to build the subpackage.
2019-03-01 14:21:42 +02:00
Henrik Grimler 0b9109238a build-package: mv termux_step_start_build to scripts/build/ 2019-02-27 21:59:08 +02:00