From 1ee018abc5e58bec44db7801a2f00f76a3285d90 Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Wed, 1 Nov 2017 16:13:21 +0100 Subject: [PATCH] zsh: Fix /usr/local in $fpath (#1730) --- packages/zsh/build.sh | 8 +++++++- packages/zsh/configure.patch | 27 +++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 1 deletion(-) create mode 100644 packages/zsh/configure.patch diff --git a/packages/zsh/build.sh b/packages/zsh/build.sh index a6c015dff..b01de5df2 100644 --- a/packages/zsh/build.sh +++ b/packages/zsh/build.sh @@ -1,12 +1,18 @@ TERMUX_PKG_HOMEPAGE=https://www.zsh.org TERMUX_PKG_DESCRIPTION="Shell with lots of features" TERMUX_PKG_VERSION=5.4.2 +TERMUX_PKG_REVISION=1 TERMUX_PKG_SHA256=62f5d034d5f4bbaa7a6b08f49aeb16a9c7dc327fd9b3d5a8017d08c66b1beb92 TERMUX_PKG_SRCURL=https://fossies.org/linux/misc/zsh-${TERMUX_PKG_VERSION}.tar.xz # Remove hard link to bin/zsh as Android does not support hard links: TERMUX_PKG_RM_AFTER_INSTALL="bin/zsh-${TERMUX_PKG_VERSION}" TERMUX_PKG_DEPENDS="libandroid-support, ncurses, termux-tools, command-not-found" -TERMUX_PKG_EXTRA_CONFIGURE_ARGS="--enable-etcdir=$TERMUX_PREFIX/etc --disable-gdbm --disable-pcre ac_cv_header_utmp_h=no" +TERMUX_PKG_EXTRA_CONFIGURE_ARGS=" +ac_cv_header_utmp_h=no +--disable-gdbm +--disable-pcre +--enable-etcdir=$TERMUX_PREFIX/etc +" TERMUX_PKG_CONFFILES="etc/zshrc" termux_step_post_configure () { diff --git a/packages/zsh/configure.patch b/packages/zsh/configure.patch new file mode 100644 index 000000000..dca301d7a --- /dev/null +++ b/packages/zsh/configure.patch @@ -0,0 +1,27 @@ +diff -u -r ../zsh-5.4.2/configure ./configure +--- ../zsh-5.4.2/configure 2017-06-30 22:36:56.000000000 +0200 ++++ ./configure 2017-11-01 16:00:08.601290902 +0100 +@@ -2888,21 +2888,8 @@ + fi + + +-if test X$sitefndir = X/usr/local/share/zsh/site-functions || \ +- test X$sitefndir = Xno +-then fixed_sitefndir='' +-elif test X$prefix != X/usr/local; then +- if test X$prefix = XNONE && test X$ac_default_prefix = X/usr/local; then +- if test X$tzsh_name != Xzsh +- then fixed_sitefndir=/usr/local/share/zsh/site-functions +- else fixed_sitefndir='' +- fi +- else fixed_sitefndir=/usr/local/share/zsh/site-functions +- fi +-elif test X$tzsh_name != Xzsh +-then fixed_sitefndir=/usr/local/share/zsh/site-functions +-else fixed_sitefndir='' +-fi ++# Do not use /usr/local/share/zsh/site-functions (#1730): ++fixed_sitefndir='' + + + # Check whether --enable-function-subdirs was given.