From 3e8242e505d96d54ccedc40444e8a6b9396cb80b Mon Sep 17 00:00:00 2001 From: Leonid Plyushch Date: Mon, 22 Jul 2019 03:43:35 +0300 Subject: [PATCH] backport changes from branch 'master' for new format of bootstraps --- packages/apt/build.sh | 25 ++++++++++++++-------- packages/bash/build.sh | 23 ++++++++++---------- packages/bash/etc-bash.bashrc | 8 ++++--- packages/bash/etc-profile | 8 +++---- packages/busybox/build.sh | 16 ++++++-------- packages/coreutils/build.sh | 11 ++++++---- packages/dash/build.sh | 4 ++-- packages/diffutils/build.sh | 6 ++++-- packages/dpkg/build.sh | 4 ++-- packages/dpkg/extract.c.patch | 19 ++++++---------- packages/dpkg/lib-dpkg-path-remove.c.patch | 9 -------- packages/findutils/build.sh | 19 +++++++++++++--- packages/gawk/build.sh | 5 +++-- packages/grep/build.sh | 5 +++-- packages/gzip/build.sh | 6 ++++-- packages/less/build.sh | 2 ++ packages/libbz2/build.sh | 2 ++ packages/libbz2/bzip2.subpackage.sh | 2 +- packages/libcurl/build.sh | 8 ++++--- packages/libcurl/curl.subpackage.sh | 2 +- packages/liblzma/build.sh | 4 +++- packages/liblzma/xz-utils.subpackage.sh | 2 +- packages/procps/build.sh | 6 ++++-- packages/psmisc/build.sh | 4 ++-- packages/sed/build.sh | 4 +++- packages/tar/build.sh | 9 ++++---- packages/termux-exec/build.sh | 4 ++-- packages/termux-tools/build.sh | 5 +++-- scripts/build/termux_create_subpackages.sh | 2 ++ 29 files changed, 125 insertions(+), 99 deletions(-) diff --git a/packages/apt/build.sh b/packages/apt/build.sh index a8bef7b91..7a0d0cb74 100644 --- a/packages/apt/build.sh +++ b/packages/apt/build.sh @@ -1,13 +1,23 @@ TERMUX_PKG_HOMEPAGE=https://packages.debian.org/apt TERMUX_PKG_DESCRIPTION="Front-end for the dpkg package manager" TERMUX_PKG_LICENSE="GPL-2.0" -TERMUX_PKG_DEPENDS="libcurl, liblzma, dpkg, gpgv, libc++, termux-exec, zlib, termux-licenses" -TERMUX_PKG_RECOMMENDS="game-repo, science-repo" -TERMUX_PKG_SUGGESTS="unstable-repo" TERMUX_PKG_VERSION=1.4.9 -TERMUX_PKG_REVISION=5 -TERMUX_PKG_SHA256=d4d65e7c84da86f3e6dcc933bba46a08db429c9d933b667c864f5c0e880bac0d +TERMUX_PKG_REVISION=6 TERMUX_PKG_SRCURL=http://ftp.debian.org/debian/pool/main/a/apt/apt_${TERMUX_PKG_VERSION}.tar.xz +TERMUX_PKG_SHA256=d4d65e7c84da86f3e6dcc933bba46a08db429c9d933b667c864f5c0e880bac0d +# apt-key requires utilities from coreutils, findutils, gpgv, grep, sed. +TERMUX_PKG_DEPENDS="coreutils, dpkg, findutils, gpgv, grep, libc++, libcurl, liblzma, sed, termux-licenses, zlib" +TERMUX_PKG_CONFLICTS="apt-transport-https" +TERMUX_PKG_REPLACES="apt-transport-https" +TERMUX_PKG_RECOMMENDS="game-repo, science-repo" +TERMUX_PKG_SUGGESTS="unstable-repo" +TERMUX_PKG_ESSENTIAL=yes + +TERMUX_PKG_CONFFILES=" +etc/apt/sources.list +etc/apt/trusted.gpg +" + TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" -DPERL_EXECUTABLE=$(which perl) -DCMAKE_INSTALL_FULL_LOCALSTATEDIR=$TERMUX_PREFIX @@ -16,10 +26,7 @@ TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" -DUSE_NLS=OFF -DWITH_DOC=OFF " -TERMUX_PKG_ESSENTIAL=yes -TERMUX_PKG_CONFFILES="etc/apt/sources.list etc/apt/trusted.gpg" -TERMUX_PKG_CONFLICTS=apt-transport-https -TERMUX_PKG_REPLACES=apt-transport-https + TERMUX_PKG_RM_AFTER_INSTALL=" bin/apt-cdrom bin/apt-extracttemplates diff --git a/packages/bash/build.sh b/packages/bash/build.sh index 42d60ad9a..70b5f8950 100644 --- a/packages/bash/build.sh +++ b/packages/bash/build.sh @@ -1,15 +1,15 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/bash/ TERMUX_PKG_DESCRIPTION="A sh-compatible shell that incorporates useful features from the Korn shell (ksh) and C shell (csh)" TERMUX_PKG_LICENSE="GPL-3.0" -TERMUX_PKG_DEPENDS="ncurses, readline (>= 8.0), libandroid-support, libiconv, termux-tools, command-not-found" _MAIN_VERSION=5.0 _PATCH_VERSION=7 -TERMUX_PKG_REVISION=2 -TERMUX_PKG_SHA256=b4a80f2ac66170b2913efbfb9f2594f1f76c7b1afd11f799e22035d63077fb4d TERMUX_PKG_VERSION=${_MAIN_VERSION}.${_PATCH_VERSION} +TERMUX_PKG_REVISION=3 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/bash/bash-${_MAIN_VERSION}.tar.gz -TERMUX_PKG_BUILD_IN_SRC=true +TERMUX_PKG_SHA256=b4a80f2ac66170b2913efbfb9f2594f1f76c7b1afd11f799e22035d63077fb4d +TERMUX_PKG_DEPENDS="command-not-found, libandroid-support, libiconv, ncurses, readline (>= 8.0), termux-tools" TERMUX_PKG_ESSENTIAL=true +TERMUX_PKG_BUILD_IN_SRC=true TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--enable-multibyte --without-bash-malloc --with-installed-readline" TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" bash_cv_job_control_missing=present" @@ -54,13 +54,12 @@ termux_step_pre_configure() { } termux_step_post_make_install() { - sed "s|@TERMUX_PREFIX@|$TERMUX_PREFIX|" $TERMUX_PKG_BUILDER_DIR/etc-profile > $TERMUX_PREFIX/etc/profile - sed "s|@TERMUX_PREFIX@|$TERMUX_PREFIX|" \ - $TERMUX_PKG_BUILDER_DIR/etc-profile | \ - sed "s|@TERMUX_HOME@|$TERMUX_ANDROID_HOME|" > \ - $TERMUX_PREFIX/etc/profile + sed -e "s|@TERMUX_PREFIX@|$TERMUX_PREFIX|" \ + -e "s|@TERMUX_HOME@|$TERMUX_ANDROID_HOME|" \ + $TERMUX_PKG_BUILDER_DIR/etc-profile > $TERMUX_PREFIX/etc/profile + # /etc/bash.bashrc - System-wide .bashrc file for interactive shells. (config-top.h in bash source, patched to enable): - sed "s|@TERMUX_PREFIX@|$TERMUX_PREFIX|" \ - $TERMUX_PKG_BUILDER_DIR/etc-bash.bashrc > \ - $TERMUX_PREFIX/etc/bash.bashrc + sed -e "s|@TERMUX_PREFIX@|$TERMUX_PREFIX|" \ + -e "s|@TERMUX_HOME@|$TERMUX_ANDROID_HOME|" \ + $TERMUX_PKG_BUILDER_DIR/etc-bash.bashrc > $TERMUX_PREFIX/etc/bash.bashrc } diff --git a/packages/bash/etc-bash.bashrc b/packages/bash/etc-bash.bashrc index e5422eb89..a36948a25 100644 --- a/packages/bash/etc-bash.bashrc +++ b/packages/bash/etc-bash.bashrc @@ -1,5 +1,7 @@ -command_not_found_handle() { - @TERMUX_PREFIX@/libexec/termux/command-not-found "$1" -} +if [ -x @TERMUX_PREFIX@/libexec/termux/command-not-found ]; then + command_not_found_handle() { + @TERMUX_PREFIX@/libexec/termux/command-not-found "$1" + } +fi PS1='\$ ' diff --git a/packages/bash/etc-profile b/packages/bash/etc-profile index 962766d50..bd5e4ca0a 100644 --- a/packages/bash/etc-profile +++ b/packages/bash/etc-profile @@ -8,11 +8,11 @@ unset i # Source etc/bash.bashrc and ~/.bashrc also for interactive bash login shells: if [ "$BASH" ]; then if [[ "$-" == *"i"* ]]; then - if [ -r /data/data/com.termux/files/usr/etc/bash.bashrc ]; then - . /data/data/com.termux/files/usr/etc/bash.bashrc + if [ -r @TERMUX_PREFIX@/etc/bash.bashrc ]; then + . @TERMUX_PREFIX@/etc/bash.bashrc fi - if [ -r /data/data/com.termux/files/home/.bashrc ]; then - . /data/data/com.termux/files/home/.bashrc + if [ -r @TERMUX_HOME@/.bashrc ]; then + . @TERMUX_HOME@/.bashrc fi fi fi diff --git a/packages/busybox/build.sh b/packages/busybox/build.sh index d863647ad..76a7f28c2 100644 --- a/packages/busybox/build.sh +++ b/packages/busybox/build.sh @@ -1,9 +1,8 @@ TERMUX_PKG_HOMEPAGE=https://busybox.net/ TERMUX_PKG_DESCRIPTION="Tiny versions of many common UNIX utilities into a single small executable" TERMUX_PKG_LICENSE="GPL-2.0" -TERMUX_PKG_ESSENTIAL=yes TERMUX_PKG_VERSION=1.30.1 -TERMUX_PKG_REVISION=2 +TERMUX_PKG_REVISION=3 TERMUX_PKG_SHA256=3d1d04a4dbd34048f4794815a5c48ebb9eb53c5277e09ffffc060323b95dfbdc TERMUX_PKG_SRCURL=https://busybox.net/downloads/busybox-${TERMUX_PKG_VERSION}.tar.bz2 TERMUX_PKG_BUILD_IN_SRC=yes @@ -29,15 +28,12 @@ termux_step_post_make_install() { if [ "$TERMUX_DEBUG" == "true" ]; then install busybox_unstripped $PREFIX/bin/busybox fi - # Create symlinks in $PREFIX/bin/applets to $PREFIX/bin/busybox + + # To assist for package upgrading after https://github.com/termux/termux-packages/issues/4070. rm -Rf $TERMUX_PREFIX/bin/applets mkdir -p $TERMUX_PREFIX/bin/applets cd $TERMUX_PREFIX/bin/applets - for f in $(cat $TERMUX_PKG_SRCDIR/busybox.links); do ln -s ../busybox $(basename $f); done - - # The 'env' applet is special in that it go into $PREFIX/bin: - cd $TERMUX_PREFIX/bin - ln -f -s busybox env + for f in diff mv rm rmdir; do ln -s ../busybox $f; done # Install busybox man page mkdir -p $TERMUX_PREFIX/share/man/man1 @@ -53,9 +49,9 @@ termux_step_post_make_install() { cd $TERMUX_PREFIX/var/service mkdir -p ftpd telnetd echo '#!/bin/sh' > ftpd/run - echo 'exec tcpsvd -vE 0.0.0.0 8021 ftpd /data/data/com.termux/files/home' >> ftpd/run + echo 'exec busybox tcpsvd -vE 0.0.0.0 8021 ftpd /data/data/com.termux/files/home' >> ftpd/run echo '#!/bin/sh' > telnetd/run - echo 'exec telnetd -F' >> telnetd/run + echo 'exec busybox telnetd -F' >> telnetd/run chmod +x */run } diff --git a/packages/coreutils/build.sh b/packages/coreutils/build.sh index 8be7cb0d6..2b56960f1 100644 --- a/packages/coreutils/build.sh +++ b/packages/coreutils/build.sh @@ -2,10 +2,13 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/coreutils/ TERMUX_PKG_DESCRIPTION="Basic file, shell and text manipulation utilities from the GNU project" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=8.31 -TERMUX_PKG_REVISION=2 -TERMUX_PKG_SHA256=ff7a9c918edce6b4f4b2725e3f9b37b0c4d193531cac49a48b56c4d0d3a9e9fd +TERMUX_PKG_REVISION=3 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/coreutils/coreutils-${TERMUX_PKG_VERSION}.tar.xz -TERMUX_PKG_DEPENDS="libiconv" +TERMUX_PKG_SHA256=ff7a9c918edce6b4f4b2725e3f9b37b0c4d193531cac49a48b56c4d0d3a9e9fd +TERMUX_PKG_DEPENDS="libandroid-support, libiconv" +TERMUX_PKG_BREAKS="busybox (<< 1.30.1-4)" +TERMUX_PKG_REPLACES="busybox (<< 1.30.1-4)" +TERMUX_PKG_ESSENTIAL=yes # pinky has no usage on Android. # df does not work either, let system binary prevail. @@ -17,7 +20,7 @@ gl_cv_host_operating_system=Android ac_cv_func_getpass=yes ac_cv_func_mbsrtowcs=no --disable-xattr ---enable-no-install-program=pinky,df,chroot,env,users,who,uptime +--enable-no-install-program=pinky,df,chroot,users,who,uptime --enable-single-binary=symlinks --without-gmp " diff --git a/packages/dash/build.sh b/packages/dash/build.sh index fbd0e807e..e147ce779 100644 --- a/packages/dash/build.sh +++ b/packages/dash/build.sh @@ -1,11 +1,11 @@ TERMUX_PKG_HOMEPAGE=http://gondor.apana.org.au/~herbert/dash/ TERMUX_PKG_DESCRIPTION="Small POSIX-compliant implementation of /bin/sh" TERMUX_PKG_LICENSE="BSD 3-Clause" -TERMUX_PKG_ESSENTIAL=yes TERMUX_PKG_VERSION=0.5.10.2 TERMUX_PKG_REVISION=1 -TERMUX_PKG_SHA256=3c663919dc5c66ec991da14c7cf7e0be8ad00f3db73986a987c118862b5f6071 TERMUX_PKG_SRCURL=http://gondor.apana.org.au/~herbert/dash/files/dash-${TERMUX_PKG_VERSION}.tar.gz +TERMUX_PKG_SHA256=3c663919dc5c66ec991da14c7cf7e0be8ad00f3db73986a987c118862b5f6071 +TERMUX_PKG_ESSENTIAL=yes termux_step_post_make_install() { # Symlink sh -> dash diff --git a/packages/diffutils/build.sh b/packages/diffutils/build.sh index 551ea4850..aaa0e9ac5 100644 --- a/packages/diffutils/build.sh +++ b/packages/diffutils/build.sh @@ -2,10 +2,12 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/diffutils/ TERMUX_PKG_DESCRIPTION="Programs (cmp, diff, diff3 and sdiff) related to finding differences between files" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=3.7 -TERMUX_PKG_REVISION=1 -TERMUX_PKG_SHA256=b3a7a6221c3dc916085f0d205abf6b8e1ba443d4dd965118da364a1dc1cb3a26 +TERMUX_PKG_REVISION=2 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/diffutils/diffutils-${TERMUX_PKG_VERSION}.tar.xz +TERMUX_PKG_SHA256=b3a7a6221c3dc916085f0d205abf6b8e1ba443d4dd965118da364a1dc1cb3a26 TERMUX_PKG_DEPENDS="libiconv" +TERMUX_PKG_ESSENTIAL=yes + TERMUX_PKG_EXTRA_CONFIGURE_ARGS="ac_cv_path_PR_PROGRAM=${TERMUX_PREFIX}/bin/pr" termux_step_pre_configure() { diff --git a/packages/dpkg/build.sh b/packages/dpkg/build.sh index 16b69c473..779c18efc 100644 --- a/packages/dpkg/build.sh +++ b/packages/dpkg/build.sh @@ -2,10 +2,11 @@ TERMUX_PKG_HOMEPAGE=https://packages.debian.org/dpkg TERMUX_PKG_DESCRIPTION="Debian package management system" TERMUX_PKG_LICENSE="GPL-2.0" TERMUX_PKG_VERSION=1.19.7 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/debian/pool/main/d/dpkg/dpkg_${TERMUX_PKG_VERSION}.tar.xz TERMUX_PKG_SHA256=4c27fededf620c0aa522fff1a48577ba08144445341257502e7730f2b1a296e8 # with the extract.c.patch we remove the -p and --warning=no-timestamp tar options so we can use busybox tar -TERMUX_PKG_DEPENDS="busybox, liblzma, zlib" +TERMUX_PKG_DEPENDS="bzip2, coreutils, diffutils, gzip, less, libbz2, liblzma, tar, xz-utils, zlib" TERMUX_PKG_ESSENTIAL=yes TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" @@ -18,7 +19,6 @@ ac_cv_lib_selinux_setexecfilecon=no dpkg_cv_c99_snprintf=yes HAVE_SETEXECFILECON_FALSE=# --host=${TERMUX_ARCH}-linux ---without-libbz2 --without-selinux " diff --git a/packages/dpkg/extract.c.patch b/packages/dpkg/extract.c.patch index a53c4df60..6f2b9a88c 100644 --- a/packages/dpkg/extract.c.patch +++ b/packages/dpkg/extract.c.patch @@ -1,16 +1,9 @@ -diff -uNr dpkg-1.19.4/dpkg-deb/extract.c dpkg-1.19.4.mod/dpkg-deb/extract.c ---- dpkg-1.19.4/dpkg-deb/extract.c 2019-01-23 04:31:39.000000000 +0200 -+++ dpkg-1.19.4.mod/dpkg-deb/extract.c 2019-05-12 21:51:55.872339882 +0300 -@@ -309,7 +309,7 @@ - if (!c3) { - struct command cmd; - -- command_init(&cmd, TAR, "tar"); -+ command_init(&cmd, "busybox", "tar"); - command_add_arg(&cmd, "tar"); - - if ((taroption & DPKG_TAR_LIST) && (taroption & DPKG_TAR_EXTRACT)) -@@ -321,14 +321,20 @@ +Remove tar options not supported by busybox tar. + +diff -u -r ../dpkg-1.17.10/dpkg-deb/extract.c ./dpkg-deb/extract.c +--- ../dpkg-1.17.10/dpkg-deb/extract.c 2014-06-04 02:02:54.000000000 +0200 ++++ ./dpkg-deb/extract.c 2014-07-01 16:40:02.785848137 +0200 +@@ -327,14 +327,20 @@ else internerr("unknown or missing tar action '%d'", taroption); diff --git a/packages/dpkg/lib-dpkg-path-remove.c.patch b/packages/dpkg/lib-dpkg-path-remove.c.patch index c8c6a4b53..7dadf256f 100644 --- a/packages/dpkg/lib-dpkg-path-remove.c.patch +++ b/packages/dpkg/lib-dpkg-path-remove.c.patch @@ -18,12 +18,3 @@ diff -u -r ../dpkg-1.18.2/lib/dpkg/path-remove.c ./lib/dpkg/path-remove.c return; if (errno == ENOTDIR) { /* Either it's a file, or one of the path components is. If -@@ -149,7 +149,7 @@ - - pid = subproc_fork(); - if (pid == 0) { -- execlp(RM, "rm", "-rf", "--", pathname, NULL); -+ execlp("@TERMUX_PREFIX@/bin/busybox", "rm", "-rf", "--", pathname, NULL); - ohshite(_("unable to execute %s (%s)"), - _("rm command for cleanup"), RM); - } diff --git a/packages/findutils/build.sh b/packages/findutils/build.sh index 8d4bb8fe8..06b2e7d46 100644 --- a/packages/findutils/build.sh +++ b/packages/findutils/build.sh @@ -2,13 +2,26 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/findutils/ TERMUX_PKG_DESCRIPTION="Utilities to find files meeting specified criteria and perform various actions on the files which are found" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=4.6.0 -TERMUX_PKG_REVISION=3 +TERMUX_PKG_REVISION=4 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/findutils/findutils-${TERMUX_PKG_VERSION}.tar.gz TERMUX_PKG_SHA256=ded4c9f73731cd48fec3b6bdaccce896473b6d8e337e9612e16cf1431bb1169d -TERMUX_PKG_EXTRA_CONFIGURE_ARGS="gl_cv_func_fflush_stdin=yes SORT_SUPPORTS_Z=yes SORT=$TERMUX_PREFIX/bin/applets/sort" TERMUX_PKG_DEPENDS="libandroid-support" +TERMUX_PKG_ESSENTIAL=yes + +TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" +gl_cv_func_fflush_stdin=yes +SORT_SUPPORTS_Z=yes +SORT=$TERMUX_PREFIX/bin/applets/sort +" + # Remove locale and updatedb which in Termux is provided by mlocate: -TERMUX_PKG_RM_AFTER_INSTALL="bin/locate bin/updatedb share/man/man1/locate.1 share/man/man1/updatedb.1 share/man/man5/locatedb.5" +TERMUX_PKG_RM_AFTER_INSTALL=" +bin/locate +bin/updatedb +share/man/man1/locate.1 +share/man/man1/updatedb.1 +share/man/man5/locatedb.5 +" termux_step_pre_configure() { # This is needed for find to implement support for the diff --git a/packages/gawk/build.sh b/packages/gawk/build.sh index 694ad49f0..818e5029f 100644 --- a/packages/gawk/build.sh +++ b/packages/gawk/build.sh @@ -1,10 +1,11 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/gawk/ TERMUX_PKG_DESCRIPTION="Programming language designed for text processing" TERMUX_PKG_LICENSE="GPL-2.0" -TERMUX_PKG_DEPENDS="libandroid-support, libmpfr, libgmp, readline" TERMUX_PKG_VERSION=5.0.1 -TERMUX_PKG_SHA256=8e4e86f04ed789648b66f757329743a0d6dfb5294c3b91b756a474f1ce05a794 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/gawk/gawk-${TERMUX_PKG_VERSION}.tar.xz +TERMUX_PKG_SHA256=8e4e86f04ed789648b66f757329743a0d6dfb5294c3b91b756a474f1ce05a794 +TERMUX_PKG_DEPENDS="libandroid-support, libgmp, libmpfr, readline" TERMUX_PKG_RM_AFTER_INSTALL="bin/gawk-* bin/igawk share/man/man1/igawk.1" termux_step_pre_configure() { diff --git a/packages/grep/build.sh b/packages/grep/build.sh index 0b4a67f39..b95a61421 100644 --- a/packages/grep/build.sh +++ b/packages/grep/build.sh @@ -1,11 +1,12 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/grep/ TERMUX_PKG_DESCRIPTION="Command which searches one or more input files for lines containing a match to a specified pattern" TERMUX_PKG_LICENSE="GPL-3.0" -TERMUX_PKG_DEPENDS="libandroid-support, pcre" TERMUX_PKG_VERSION=3.3 -TERMUX_PKG_REVISION=1 +TERMUX_PKG_REVISION=2 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/grep/grep-${TERMUX_PKG_VERSION}.tar.xz TERMUX_PKG_SHA256=b960541c499619efd6afe1fa795402e4733c8e11ebf9fafccc0bb4bccdc5b514 +TERMUX_PKG_DEPENDS="libandroid-support, pcre" +TERMUX_PKG_ESSENTIAL=yes termux_step_pre_configure() { if [ "$TERMUX_DEBUG" == "true" ]; then diff --git a/packages/gzip/build.sh b/packages/gzip/build.sh index 7b393f20b..70bbf16bf 100644 --- a/packages/gzip/build.sh +++ b/packages/gzip/build.sh @@ -2,9 +2,11 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/gzip/ TERMUX_PKG_DESCRIPTION="Standard GNU file compression utilities" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=1.10 -TERMUX_PKG_REVISION=1 -TERMUX_PKG_SHA256=8425ccac99872d544d4310305f915f5ea81e04d0f437ef1a230dc9d1c819d7c0 +TERMUX_PKG_REVISION=2 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/gzip/gzip-${TERMUX_PKG_VERSION}.tar.xz +TERMUX_PKG_SHA256=8425ccac99872d544d4310305f915f5ea81e04d0f437ef1a230dc9d1c819d7c0 +TERMUX_PKG_ESSENTIAL=yes + TERMUX_PKG_EXTRA_CONFIGURE_ARGS="ac_cv_path_GREP=grep" termux_step_pre_configure() { diff --git a/packages/less/build.sh b/packages/less/build.sh index f692dc0c6..67f3a9743 100644 --- a/packages/less/build.sh +++ b/packages/less/build.sh @@ -2,6 +2,8 @@ TERMUX_PKG_HOMEPAGE=http://www.greenwoodsoftware.com/less/ TERMUX_PKG_DESCRIPTION="Terminal pager program used to view the contents of a text file one screen at a time" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=551 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=http://www.greenwoodsoftware.com/less/less-${TERMUX_PKG_VERSION}.tar.gz TERMUX_PKG_SHA256=ff165275859381a63f19135a8f1f6c5a194d53ec3187f94121ecd8ef0795fe3d TERMUX_PKG_DEPENDS="ncurses" +TERMUX_PKG_ESSENTIAL=yes diff --git a/packages/libbz2/build.sh b/packages/libbz2/build.sh index c7537e39b..3261ff649 100644 --- a/packages/libbz2/build.sh +++ b/packages/libbz2/build.sh @@ -2,8 +2,10 @@ TERMUX_PKG_HOMEPAGE=http://www.bzip.org/ TERMUX_PKG_DESCRIPTION="BZ2 format compression library" TERMUX_PKG_LICENSE="BSD" TERMUX_PKG_VERSION=1.0.8 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/bzip2-${TERMUX_PKG_VERSION}.tar.xz TERMUX_PKG_SHA256=47fd74b2ff83effad0ddf62074e6fad1f6b4a77a96e121ab421c20a216371a1f +TERMUX_PKG_ESSENTIAL=yes TERMUX_PKG_EXTRA_MAKE_ARGS="PREFIX=$TERMUX_PREFIX" TERMUX_PKG_BUILD_IN_SRC=yes diff --git a/packages/libbz2/bzip2.subpackage.sh b/packages/libbz2/bzip2.subpackage.sh index 858ec2341..02e2ae46e 100644 --- a/packages/libbz2/bzip2.subpackage.sh +++ b/packages/libbz2/bzip2.subpackage.sh @@ -1,3 +1,3 @@ TERMUX_SUBPKG_INCLUDE="bin/ share/man/man1/" TERMUX_SUBPKG_DESCRIPTION="Tools for working with bzip2 compression" -TERMUX_SUBPKG_DEPENDS="libbz2" +TERMUX_SUBPKG_ESSENTIAL=yes diff --git a/packages/libcurl/build.sh b/packages/libcurl/build.sh index 123b7fb50..cf4dc418c 100644 --- a/packages/libcurl/build.sh +++ b/packages/libcurl/build.sh @@ -1,10 +1,12 @@ TERMUX_PKG_HOMEPAGE=https://curl.haxx.se/ TERMUX_PKG_DESCRIPTION="Easy-to-use client-side URL transfer library" TERMUX_PKG_LICENSE="MIT" -TERMUX_PKG_VERSION=7.65.1 +TERMUX_PKG_VERSION=7.65.3 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=https://curl.haxx.se/download/curl-${TERMUX_PKG_VERSION}.tar.bz2 -TERMUX_PKG_SHA256=cbd36df60c49e461011b4f3064cff1184bdc9969a55e9608bf5cadec4686e3f7 -TERMUX_PKG_DEPENDS="openssl (>= 1.1.1), libnghttp2, zlib" +TERMUX_PKG_SHA256=0a855e83be482d7bc9ea00e05bdb1551a44966076762f9650959179c89fce509 +TERMUX_PKG_DEPENDS="libnghttp2, openssl (>= 1.1.1), zlib" +TERMUX_PKG_ESSENTIAL=yes TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" --enable-ntlm-wb=$TERMUX_PREFIX/bin/ntlm_auth diff --git a/packages/libcurl/curl.subpackage.sh b/packages/libcurl/curl.subpackage.sh index 4708d90bc..2b79845c3 100644 --- a/packages/libcurl/curl.subpackage.sh +++ b/packages/libcurl/curl.subpackage.sh @@ -1,3 +1,3 @@ TERMUX_SUBPKG_INCLUDE="bin/curl share/man/man1/curl.1.gz" TERMUX_SUBPKG_DESCRIPTION="Command line tool for transferring data with URL syntax" -TERMUX_SUBPKG_DEPENDS="libcurl" +TERMUX_SUBPKG_ESSENTIAL=yes diff --git a/packages/liblzma/build.sh b/packages/liblzma/build.sh index 39848abcc..b60b71bfc 100644 --- a/packages/liblzma/build.sh +++ b/packages/liblzma/build.sh @@ -2,5 +2,7 @@ TERMUX_PKG_HOMEPAGE=https://tukaani.org/xz/ TERMUX_PKG_DESCRIPTION="XZ-format compression library" TERMUX_PKG_LICENSE="GPL-2.0" TERMUX_PKG_VERSION=5.2.4 -TERMUX_PKG_SHA256=9717ae363760dedf573dad241420c5fea86256b65bc21d2cf71b2b12f0544f4b +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/xz-${TERMUX_PKG_VERSION}.tar.xz +TERMUX_PKG_SHA256=9717ae363760dedf573dad241420c5fea86256b65bc21d2cf71b2b12f0544f4b +TERMUX_PKG_ESSENTIAL=yes diff --git a/packages/liblzma/xz-utils.subpackage.sh b/packages/liblzma/xz-utils.subpackage.sh index 6675f4a19..69edcbd17 100644 --- a/packages/liblzma/xz-utils.subpackage.sh +++ b/packages/liblzma/xz-utils.subpackage.sh @@ -1,3 +1,3 @@ TERMUX_SUBPKG_INCLUDE="bin/ share/man/man1/" TERMUX_SUBPKG_DESCRIPTION="XZ-format compression tools" -TERMUX_SUBPKG_DEPENDS="liblzma" +TERMUX_SUBPKG_ESSENTIAL=yes diff --git a/packages/procps/build.sh b/packages/procps/build.sh index 56945807f..c29a4cf16 100644 --- a/packages/procps/build.sh +++ b/packages/procps/build.sh @@ -3,9 +3,11 @@ TERMUX_PKG_DESCRIPTION="Utilities that give information about processes using th TERMUX_PKG_LICENSE="LGPL-2.0" TERMUX_PKG_VERSION=3.3.15 TERMUX_PKG_REVISION=2 -TERMUX_PKG_SHA256=10bd744ffcb3de2d591d2f6acf1a54a7ba070fdcc432a855931a5057149f0465 TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/procps-ng-$TERMUX_PKG_VERSION.tar.xz +TERMUX_PKG_SHA256=10bd744ffcb3de2d591d2f6acf1a54a7ba070fdcc432a855931a5057149f0465 +TERMUX_PKG_DEPENDS="ncurses" TERMUX_PKG_BUILD_IN_SRC=yes + # error.h and stdio_ext.h in unified headers does # not provide any functionality prior to android-23: TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" @@ -15,7 +17,7 @@ ac_cv_header_stdio_ext_h=no --enable-sigwinch --disable-modern-top " -TERMUX_PKG_DEPENDS="ncurses" + # About kill: https://bugs.launchpad.net/ubuntu/+source/coreutils/+bug/141168: # "For compatibility between distributions, can we have /bin/kill made available from coreutils?" # About uptime: Does not work on later android versions as /proc/uptime cannot be read. diff --git a/packages/psmisc/build.sh b/packages/psmisc/build.sh index 8f39dfb9c..fa859de26 100644 --- a/packages/psmisc/build.sh +++ b/packages/psmisc/build.sh @@ -1,9 +1,9 @@ TERMUX_PKG_HOMEPAGE=https://gitlab.com/psmisc/psmisc TERMUX_PKG_DESCRIPTION="Some small useful utilities that use the proc filesystem" TERMUX_PKG_LICENSE="GPL-2.0" -TERMUX_PKG_DEPENDS="ncurses" TERMUX_PKG_VERSION=23.2 -TERMUX_PKG_SHA256=4b7cbffdc9373474da49b85dc3457ae511c43dc7fa7d94513fe06f89dcb87880 TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/psmisc-$TERMUX_PKG_VERSION.tar.xz +TERMUX_PKG_SHA256=4b7cbffdc9373474da49b85dc3457ae511c43dc7fa7d94513fe06f89dcb87880 +TERMUX_PKG_DEPENDS="ncurses" TERMUX_PKG_BUILD_IN_SRC=yes TERMUX_PKG_RM_AFTER_INSTALL="bin/pstree.x11" diff --git a/packages/sed/build.sh b/packages/sed/build.sh index 99bb7a81d..c4c997050 100644 --- a/packages/sed/build.sh +++ b/packages/sed/build.sh @@ -2,8 +2,10 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/sed/ TERMUX_PKG_DESCRIPTION="GNU stream editor for filtering/transforming text" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=4.7 -TERMUX_PKG_SHA256=2885768cd0a29ff8d58a6280a270ff161f6a3deb5690b2be6c49f46d4c67bd6a +TERMUX_PKG_REVISION=1 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/sed/sed-${TERMUX_PKG_VERSION}.tar.xz +TERMUX_PKG_SHA256=2885768cd0a29ff8d58a6280a270ff161f6a3deb5690b2be6c49f46d4c67bd6a +TERMUX_PKG_ESSENTIAL=yes TERMUX_PKG_BUILD_IN_SRC=yes termux_step_pre_configure() { diff --git a/packages/tar/build.sh b/packages/tar/build.sh index 56a8f1a8a..e627844fe 100644 --- a/packages/tar/build.sh +++ b/packages/tar/build.sh @@ -2,11 +2,12 @@ TERMUX_PKG_HOMEPAGE=https://www.gnu.org/software/tar/ TERMUX_PKG_DESCRIPTION="GNU tar for manipulating tar archives" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=1.32 -TERMUX_PKG_REVISION=2 -TERMUX_PKG_SHA256=d0d3ae07f103323be809bc3eac0dcc386d52c5262499fe05511ac4788af1fdd8 +TERMUX_PKG_REVISION=3 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/tar/tar-${TERMUX_PKG_VERSION}.tar.xz -# Allow xz compression (busybox only provides xz decompression): -TERMUX_PKG_DEPENDS="libiconv, xz-utils, libandroid-glob" +TERMUX_PKG_SHA256=d0d3ae07f103323be809bc3eac0dcc386d52c5262499fe05511ac4788af1fdd8 +TERMUX_PKG_DEPENDS="libandroid-glob, libiconv" +TERMUX_PKG_ESSENTIAL=yes + # When cross-compiling configure guesses that d_ino in struct dirent only exists # if triplet matches linux*-gnu*, so we force set it explicitly: TERMUX_PKG_EXTRA_CONFIGURE_ARGS="gl_cv_struct_dirent_d_ino=yes" diff --git a/packages/termux-exec/build.sh b/packages/termux-exec/build.sh index ce4ce3fc5..4a645b239 100644 --- a/packages/termux-exec/build.sh +++ b/packages/termux-exec/build.sh @@ -1,7 +1,7 @@ TERMUX_PKG_HOMEPAGE=https://github.com/termux/termux-exec TERMUX_PKG_DESCRIPTION="An execve() wrapper to make /bin and /usr/bin shebangs work" TERMUX_PKG_LICENSE="Apache-2.0" -TERMUX_PKG_VERSION=0.3 -TERMUX_PKG_SHA256=7561fcb2ee2c5e0300047d7798d7c203509913e61607cbf650cffdca5664ae56 +TERMUX_PKG_VERSION=0.4 TERMUX_PKG_SRCURL=https://github.com/termux/termux-exec/archive/v$TERMUX_PKG_VERSION.tar.gz +TERMUX_PKG_SHA256=9a8d42d211a7d461d61dcd4e3ef984014c2c2c696cfd6394bae389af13572627 TERMUX_PKG_BUILD_IN_SRC=yes diff --git a/packages/termux-tools/build.sh b/packages/termux-tools/build.sh index 851fb54bc..c2b6dd49d 100644 --- a/packages/termux-tools/build.sh +++ b/packages/termux-tools/build.sh @@ -2,11 +2,12 @@ TERMUX_PKG_HOMEPAGE=https://termux.com/ TERMUX_PKG_DESCRIPTION="Basic system tools for Termux" TERMUX_PKG_LICENSE="GPL-3.0" TERMUX_PKG_VERSION=0.68 +TERMUX_PKG_REVISION=1 TERMUX_PKG_PLATFORM_INDEPENDENT=yes +TERMUX_PKG_DEPENDS="termux-am, termux-exec" +TERMUX_PKG_CONFLICTS="procps (<< 3.3.15-2)" TERMUX_PKG_ESSENTIAL=yes -TERMUX_PKG_DEPENDS="termux-am" TERMUX_PKG_CONFFILES="etc/motd" -TERMUX_PKG_CONFLICTS="procps (<< 3.3.15-2)" termux_step_make_install() { mkdir -p $TERMUX_PREFIX/bin/applets diff --git a/scripts/build/termux_create_subpackages.sh b/scripts/build/termux_create_subpackages.sh index 3fa564cd1..4c59e947f 100644 --- a/scripts/build/termux_create_subpackages.sh +++ b/scripts/build/termux_create_subpackages.sh @@ -24,6 +24,7 @@ termux_create_subpackages() { # Default value is same as main package, but sub package may override: local TERMUX_SUBPKG_PLATFORM_INDEPENDENT=$TERMUX_PKG_PLATFORM_INDEPENDENT local SUB_PKG_DIR=$TERMUX_TOPDIR/$TERMUX_PKG_NAME/subpackages/$SUB_PKG_NAME + local TERMUX_SUBPKG_ESSENTIAL="" local TERMUX_SUBPKG_BREAKS="" local TERMUX_SUBPKG_DEPENDS="" local TERMUX_SUBPKG_CONFLICTS="" @@ -78,6 +79,7 @@ termux_create_subpackages() { TERMUX_SUBPKG_DEPENDS+=", $TERMUX_PKG_DEPENDS" fi + test ! -z "$TERMUX_SUBPKG_ESSENTIAL" && echo "Essential: yes" >> control test ! -z "$TERMUX_SUBPKG_DEPENDS" && echo "Depends: ${TERMUX_SUBPKG_DEPENDS/#, /}" >> control test ! -z "$TERMUX_SUBPKG_BREAKS" && echo "Breaks: $TERMUX_SUBPKG_BREAKS" >> control test ! -z "$TERMUX_SUBPKG_CONFLICTS" && echo "Conflicts: $TERMUX_SUBPKG_CONFLICTS" >> control