From fb8471fb27cc941ce5ff12efe9c041be3854dd33 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Wed, 30 Nov 2016 21:34:29 -0500 Subject: [PATCH] coreutils: Update from 8.25 to 8.26 --- packages/coreutils/Makefile.in.patch | 22 ++++++++++++++++------ packages/coreutils/build.sh | 10 +++++----- packages/coreutils/src-ls.c.patch | 31 +++++++++++++------------------ 3 files changed, 34 insertions(+), 29 deletions(-) diff --git a/packages/coreutils/Makefile.in.patch b/packages/coreutils/Makefile.in.patch index 931d7ff5..0ba3bb13 100644 --- a/packages/coreutils/Makefile.in.patch +++ b/packages/coreutils/Makefile.in.patch @@ -1,9 +1,18 @@ -Use man pages generated by help2man in the host build. - -diff -u -r ../coreutils-8.25/Makefile.in ./Makefile.in ---- ../coreutils-8.25/Makefile.in 2016-01-20 05:55:18.000000000 -0500 -+++ ./Makefile.in 2016-01-20 17:47:11.033497974 -0500 -@@ -14385,32 +14385,7 @@ +diff -u -r ../coreutils-8.26/Makefile.in ./Makefile.in +--- ../coreutils-8.26/Makefile.in 2016-11-30 13:34:55.000000000 -0500 ++++ ./Makefile.in 2016-11-30 19:10:09.902334174 -0500 +@@ -5023,7 +5023,9 @@ + @CROSS_COMPILING_FALSE@cu_install_program = src/ginstall + + # Use the just-built 'ginstall', when not cross-compiling. +-@CROSS_COMPILING_TRUE@cu_install_program = @INSTALL_PROGRAM@ ++# Work around ++# "Makefile:3440: *** Recursive variable 'INSTALL' references itself (eventually). Stop." ++@CROSS_COMPILING_TRUE@cu_install_program = install + info_TEXINFOS = doc/coreutils.texi + doc_coreutils_TEXINFOS = \ + doc/perm.texi \ +@@ -14622,32 +14624,8 @@ @SINGLE_BINARY_FALSE@man/yes.1: src/yes$(EXEEXT) .x.1: @@ -33,6 +42,7 @@ diff -u -r ../coreutils-8.25/Makefile.in ./Makefile.in - && rm -rf $$t \ - && chmod a-w $@-t \ - && mv $@-t $@ ++ # Use man pages generated by help2man in the host build. + cp $(top_srcdir)/../host-build/$@ $@ .PHONY: check-root check-root: diff --git a/packages/coreutils/build.sh b/packages/coreutils/build.sh index 86d93dbd..f392a18f 100755 --- a/packages/coreutils/build.sh +++ b/packages/coreutils/build.sh @@ -1,14 +1,14 @@ -TERMUX_PKG_HOMEPAGE=http://www.gnu.org/software/coreutils/ +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_VERSION=8.25 -TERMUX_PKG_BUILD_REVISION=6 +TERMUX_PKG_VERSION=8.26 TERMUX_PKG_SRCURL=https://mirrors.kernel.org/gnu/coreutils/coreutils-${TERMUX_PKG_VERSION}.tar.xz +TERMUX_PKG_SHA256=155e94d748f8e2bc327c66e0cbebdb8d6ab265d2f37c3c928f7bf6c3beba9a8e TERMUX_PKG_EXTRA_CONFIGURE_ARGS="ac_cv_func_mkfifo=yes gl_cv_host_operating_system=Android --without-gmp --enable-single-binary=symlinks ac_cv_func_endpwent=no" # pinky has no usage on Android. -# realpath has permission denied problem with relative paths, let busybox version prevail. # df does not work either, let system binary prevail. # $PREFIX/bin/env is provided by busybox for shebangs to work directly. -TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --enable-no-install-program=pinky,realpath,df,chroot,env" +# users and who doesn't work and does not make much sense for Termux. +TERMUX_PKG_EXTRA_CONFIGURE_ARGS+=" --enable-no-install-program=pinky,df,chroot,env,users,who" TERMUX_PKG_EXTRA_HOSTBUILD_CONFIGURE_ARGS="$TERMUX_PKG_EXTRA_CONFIGURE_ARGS" TERMUX_PKG_BUILD_IN_SRC=yes # Host build for man pages generated by help2man, see makefile.patch: diff --git a/packages/coreutils/src-ls.c.patch b/packages/coreutils/src-ls.c.patch index 989acb47..1109184d 100644 --- a/packages/coreutils/src-ls.c.patch +++ b/packages/coreutils/src-ls.c.patch @@ -1,18 +1,13 @@ -diff -u -r ../coreutils-8.22/src/ls.c ./src/ls.c ---- ../coreutils-8.22/src/ls.c 2013-12-04 15:48:30.000000000 +0100 -+++ ./src/ls.c 2014-02-14 16:11:48.000000000 +0100 -@@ -2098,11 +2089,13 @@ - } - } - -+#ifndef __ANDROID__ - /* Note we leave %5b etc. alone so user widths/flags are honored. */ - if (strstr (long_time_format[0], "%b") - || strstr (long_time_format[1], "%b")) - if (!abmon_init ()) - error (0, 0, _("error initializing month strings")); -+#endif - } - - return optind; - +diff -u -r ../coreutils-8.26/src/ls.c ./src/ls.c +--- ../coreutils-8.26/src/ls.c 2016-11-22 15:04:32.000000000 -0500 ++++ ./src/ls.c 2016-11-30 20:27:28.910732105 -0500 +@@ -1749,6 +1749,9 @@ + } + } + ++ /* Termux patch: Default to colors if terminal. The --color option may override this. */ ++ print_with_color = isatty(STDOUT_FILENO); ++ + while (true) + { + int oi = -1; -- 2.11.0