* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2016-09-15 5:03 Tim Harder
0 siblings, 0 replies; 15+ messages in thread
From: Tim Harder @ 2016-09-15 5:03 UTC (permalink / raw
To: gentoo-commits
commit: 6f4b37f25304dad59516b6b65ba6d0f0b2301167
Author: Tim Harder <radhermit <AT> gentoo <DOT> org>
AuthorDate: Thu Sep 15 05:03:11 2016 +0000
Commit: Tim Harder <radhermit <AT> gentoo <DOT> org>
CommitDate: Thu Sep 15 05:03:31 2016 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=6f4b37f2
app-shells/zsh: remove old
app-shells/zsh/Manifest | 6 -
.../zsh/files/zsh-5.0.7-fix-cvs-completion.patch | 19 --
app-shells/zsh/files/zsh-5.0.7-pid-ns.patch | 39 ----
app-shells/zsh/zsh-5.0.7-r1.ebuild | 173 -----------------
app-shells/zsh/zsh-5.0.7-r2.ebuild | 174 -----------------
app-shells/zsh/zsh-5.0.8.ebuild | 210 --------------------
app-shells/zsh/zsh-5.1.1.ebuild | 213 ---------------------
7 files changed, 834 deletions(-)
diff --git a/app-shells/zsh/Manifest b/app-shells/zsh/Manifest
index c4c636c..6cf2604 100644
--- a/app-shells/zsh/Manifest
+++ b/app-shells/zsh/Manifest
@@ -1,10 +1,4 @@
DIST zsh-5.0.5-doc.tar.bz2 2940018 SHA256 e4f22bafaa8410bbc2d83f2d748ca4764365752c46f7e1099be54f2a62c492f2 SHA512 341e4a62c7c2367d17c54c5133b7c0a74e6c0becfaddd3c1f5dbe782300bbd74b0fc2066e892776cb52ce11cd0600739bfd5a7dd067eaae8a1d11b1b2aa0c3b0 WHIRLPOOL 48e021bc2caf840d048888faf5cafea5ce698968479e1c8791f33dc36f9b0f60db16ff481e88ce8c903480d905b728eb9ff9dfc8fbcb066d3698cc0cc3a02d8a
DIST zsh-5.0.5.tar.bz2 3104375 SHA256 6624d2fb6c8fa4e044d2b009f86ed1617fe8583c83acfceba7ec82826cfa8eaf SHA512 34d69bed190cbc476bcdaa4b703fee1caaeae7e011fe7ea595b29bbd31df57bbe4d19b5940618e0c89a0a4b6c476f9ef03ce9829b4fb3735c1aedf309b0225a5 WHIRLPOOL bf02ca194261e15e88a9e26212644aa7be1afcc8e73cd6bb18ffb8e1c1d46a8742fee109d92a3b455c418258df9ae74dece21a05ff0e54e8c370af094512af16
-DIST zsh-5.0.7-doc.tar.bz2 3005587 SHA256 43e8665ba9d9eca8370c64e2d4846e84f9111c628e5792f2aa639a7fb209fcf1 SHA512 5a8bdf00bb646bb844a2d953aed85de802fe2e8fa05a76382d3baeba8a0108fa2d0b137b7d9bf88eeeb77ea06843fe1c56ec1fece1389b502e39a16dd31f208c WHIRLPOOL 0364f134997e4df63e7d6e9b6c81030dcf96ce30bb329b353fccf682ab5e20964d028e6667d836ff1a4c70e27331632cc96c7871ba69afc611c7bbdd09c8508b
-DIST zsh-5.0.7.tar.bz2 3181030 SHA256 544e27de81740286b916d1d77c9f48ad7c26ad7943ed96d278abee67cf6704b3 SHA512 e309863b41c9f92996fb9301d96d1aa43270ef8a04626c946703675b16a0a2ac9fddc959184cd8c639bd061fc2dd21902b21515550f639faacccdabd59e256e5 WHIRLPOOL f7cfbc41a2c990f702fee4ee158db79ebaad794479a62ff0ccd1d466077556e93b5e563575f9fd25dde1cb5e3c3610a14c997155ea76d86293d0a08168a3a418
-DIST zsh-5.0.8-doc.tar.bz2 3204865 SHA256 0ee5088c47fa5ceac6e087c7e00f2ede3f5920a03d32220772342ce980339e40 SHA512 86f75cfa16a2d0acbd75dc11d16a9bd4813ea2f0c6e323ed6fd73e66250420333fe0be2dbd62171a36aa479b5b5b423777f7ca369afb29d0f456fb7ed68926f6 WHIRLPOOL 1b25a455e7617cf624f8656eef2064e35a3c7798aec3d2822522bb89cad11441e1658966c467ecd758fa9e02ffcc235ee036830fd00757a04c3ff8e1b21fc434
-DIST zsh-5.0.8.tar.bz2 3250542 SHA256 8079cf08cb8beff22f84b56bd72bb6e6962ff4718d816f3d83a633b4c9e17d23 SHA512 79e438e32802c030749fd1bfff07fb3e5e7f7864e5106233c6f51ea477aa5a8471449e22f262f03bf69f42e66bf39e3b8a93295a247436ce97c66409b582ceae WHIRLPOOL 3ed95b2763bd3e486104a9f935efc89fd9ff1b3d745c1c3a93181a511c2986246e4f14c6d15fd88dd735c006127523ce423150813147250343871c9e2f40f413
-DIST zsh-5.1.1-doc.tar.xz 3061616 SHA256 f5944f29ec77100afdc3634f0bb8ffc4328a2d03147f23d1aa6280b6aa7d622f SHA512 868444662ca9b1cc91f2ecff56ce0944e5e75fc5f5a349eb538ca23a8eb8fb4ebaa8efc2ba1d8581424f25b0009305ed7a6f08ca06db1ecde467eeb5d6b71621 WHIRLPOOL c72760d754e19e7fe1f501bd395becc13877d4b0ba20fbf1f08855be5affb78aac07e2c14e779c1b554e21e29d8bfd5203dd41da5d3f21020dac7033510a4662
-DIST zsh-5.1.1.tar.xz 2788676 SHA256 74e9453b5470b3c0970f9f93cfd603d241c3d7b1968adc0e4b3951073e8d3dec SHA512 732f183a03125e83da11a38c638ca54a667326a23ca19418b0df27b1d5b3b1f360383d84f66bde064911effaa2ce9cbb9b6ab86deddb92f80e8f601af8a82b3e WHIRLPOOL 55199e45557c2667e8f9b7564af44b32b610fe09db451493bd64642c2987e12a638b2b96d6530a16427ba17a6ca8c20e73f88013cf47996eea24e5e1595691e7
DIST zsh-5.2-doc.tar.xz 3108600 SHA256 328352cf3d5d0ec4b6e31dcefd25ff5b4c0e6b8077d1fe84448ebb50d6ada52a SHA512 a2e6b95c293546011e1697e0a2f66a3740092ef61904fa3b469f33e8af0ced6028fac77cd51ebe9ee4cb168403d9af7c72fd071a15ba3dc273243bd71fa714a0 WHIRLPOOL a6b023af9e3d94d31b56aba688c2bf3c16ff6ed1dc9db34dd970c4bf0461e24b7aab0b9113cc5f16bd87ab2ca9d973a990a3721c08500cbcd45fa2fe2d43a260
DIST zsh-5.2.tar.xz 2820108 SHA256 f17916320ffaa844bbd7ce48ceeb5945fc5f3eff64b149b4229bbfbdf3795a9d SHA512 9938af95e09203a0a313f441e0c23279136806f6f087475ca9a66c678c57ecffc87f73ece8133a36700af8de7cb5d1bec8559eabdec2b66102062e64026c2e72 WHIRLPOOL 5348ce11026a4e50d0ecf118cb379e9765cb98fcf32563489fd860ad0234c3f3aefb7f3fe28d18a97f2ddba54dc2b2cf9909b81cdc0e213f26f599ba68fd8833
diff --git a/app-shells/zsh/files/zsh-5.0.7-fix-cvs-completion.patch b/app-shells/zsh/files/zsh-5.0.7-fix-cvs-completion.patch
deleted file mode 100644
index 5beb7ec..00000000
--- a/app-shells/zsh/files/zsh-5.0.7-fix-cvs-completion.patch
+++ /dev/null
@@ -1,19 +0,0 @@
-http://www.zsh.org/mla/workers/2014/msg01191.html
-
-diff --git a/Completion/Base/Utility/_call_program b/Completion/Base/Utility/_call_program
-index b657648..010e094 100644
---- a/Completion/Base/Utility/_call_program
-+++ b/Completion/Base/Utility/_call_program
-@@ -2,8 +2,8 @@
-
- local tmp err_fd=-1
-
--if (( ${debug_fd:--1} > 2 ))
--then exec {err_fd}>&2 # debug_fd is saved stderr, 2 is log file
-+if (( ${debug_fd:--1} > 2 )) || [[ ! -t 2 ]]
-+then exec {err_fd}>&2 # debug_fd is saved stderr, 2 is trace or redirect
- else exec {err_fd}>/dev/null
- fi
-
-
---
diff --git a/app-shells/zsh/files/zsh-5.0.7-pid-ns.patch b/app-shells/zsh/files/zsh-5.0.7-pid-ns.patch
deleted file mode 100644
index 701d087..00000000
--- a/app-shells/zsh/files/zsh-5.0.7-pid-ns.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-zsh and pid namespaces don't play very well together. Specifically, when zsh is
-launched inside a new pid namespace, it doesn't take ownership of the process
-group, causing things like SIGINT to be sent to the parent process. Upstream
-bug report here: http://www.zsh.org/mla/workers/2014/msg01769.html.
-
-The first chunk of this diff fixes this problem and has already been applied
-upstream:
-https://sourceforge.net/p/zsh/code/ci/0c4cb0cc1b527f4341f1a39a10f4120aa7c7d594/.
-
-The second chunk is a suggested fix for the warning that zsh prints when
-exiting: http://www.zsh.org/mla/workers/2014/msg01779.html.
-
-diff --git a/Src/jobs.c b/Src/jobs.c
-index a668b07..c6e1bce 100644
---- a/Src/jobs.c
-+++ b/Src/jobs.c
-@@ -2734,7 +2734,7 @@ acquire_pgrp(void)
- long ttpgrp;
- sigset_t blockset, oldset;
-
-- if ((mypgrp = GETPGRP()) > 0) {
-+ if ((mypgrp = GETPGRP()) >= 0) {
- long lastpgrp = mypgrp;
- sigemptyset(&blockset);
- sigaddset(&blockset, SIGTTIN);
-@@ -2779,8 +2779,11 @@ void
- release_pgrp(void)
- {
- if (origpgrp != mypgrp) {
-- attachtty(origpgrp);
-- setpgrp(0, origpgrp);
-+ /* in linux pid namespaces, origpgrp may never have been set */
-+ if (origpgrp) {
-+ attachtty(origpgrp);
-+ setpgrp(0, origpgrp);
-+ }
- mypgrp = origpgrp;
- }
- }
diff --git a/app-shells/zsh/zsh-5.0.7-r1.ebuild b/app-shells/zsh/zsh-5.0.7-r1.ebuild
deleted file mode 100644
index 96c41c4..00000000
--- a/app-shells/zsh/zsh-5.0.7-r1.ebuild
+++ /dev/null
@@ -1,173 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib prefix
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="http://www.zsh.org/"
-SRC_URI="http://www.zsh.org/pub/${P}.tar.bz2
- doc? ( http://www.zsh.org/pub/${P}-doc.tar.bz2 )"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? ( >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] ) )
- gdbm? ( sys-libs/gdbm )
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-
-src_prepare() {
- # fix zshall problem with soelim
- ln -s Doc man1
- mv Doc/zshall.1 Doc/zshall.1.soelim
- soelim Doc/zshall.1.soelim > Doc/zshall.1
-
- epatch "${FILESDIR}"/${PN}-init.d-gentoo-r1.diff
-
- cp "${FILESDIR}"/zprofile-1 "${T}"/zprofile || die
- eprefixify "${T}"/zprofile || die
- if use prefix ; then
- sed -i -e 's|@ZSH_PREFIX@||' -e '/@ZSH_NOPREFIX@/d' "${T}"/zprofile || die
- else
- sed -i -e 's|@ZSH_NOPREFIX@||' -e '/@ZSH_PREFIX@/d' -e 's|""||' "${T}"/zprofile || die
- fi
-
- # fix cvs completion
- epatch "${FILESDIR}"/${P}-fix-cvs-completion.patch
-}
-
-src_configure() {
- local myconf=
-
- if use static ; then
- myconf+=" --disable-dynamic"
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=" \
- --enable-zsh-debug \
- --enable-zsh-mem-debug \
- --enable-zsh-mem-warning \
- --enable-zsh-secure-free \
- --enable-zsh-hash-debug"
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=" --enable-libs=-liconv"
- append-ldflags -Wl,-x
- fi
-
- econf \
- --bindir="${EPREFIX}"/bin \
- --libdir="${EPREFIX}"/usr/$(get_libdir) \
- --enable-etcdir="${EPREFIX}"/etc/zsh \
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help \
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions \
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions \
- --enable-function-subdirs \
- --with-tcsetpgrp \
- $(use_enable maildir maildir-support) \
- $(use_enable pcre) \
- $(use_enable caps cap) \
- $(use_enable unicode multibyte) \
- $(use_enable gdbm ) \
- ${myconf}
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -i \
- -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install install.info
-
- insinto /etc/zsh
- doins "${T}"/zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- # install miscellaneous scripts; bug #54520
- local i
- sed -i -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" "${S}"/{Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dohtml -r Doc/*
- insinto /usr/share/doc/${PF}
- doins Doc/zsh.{dvi,pdf}
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- # should link to https://www.gentoo.org/doc/en/zsh.xml
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- fi
-}
diff --git a/app-shells/zsh/zsh-5.0.7-r2.ebuild b/app-shells/zsh/zsh-5.0.7-r2.ebuild
deleted file mode 100644
index 5436178..00000000
--- a/app-shells/zsh/zsh-5.0.7-r2.ebuild
+++ /dev/null
@@ -1,174 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib prefix
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="http://www.zsh.org/"
-SRC_URI="http://www.zsh.org/pub/${P}.tar.bz2
- doc? ( http://www.zsh.org/pub/${P}-doc.tar.bz2 )"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? ( >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] ) )
- gdbm? ( sys-libs/gdbm )
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-
-src_prepare() {
- # fix zshall problem with soelim
- ln -s Doc man1
- mv Doc/zshall.1 Doc/zshall.1.soelim
- soelim Doc/zshall.1.soelim > Doc/zshall.1
-
- epatch "${FILESDIR}"/${PN}-init.d-gentoo-r1.diff
- epatch "${FILESDIR}"/${P}-pid-ns.patch
-
- cp "${FILESDIR}"/zprofile-1 "${T}"/zprofile || die
- eprefixify "${T}"/zprofile || die
- if use prefix ; then
- sed -i -e 's|@ZSH_PREFIX@||' -e '/@ZSH_NOPREFIX@/d' "${T}"/zprofile || die
- else
- sed -i -e 's|@ZSH_NOPREFIX@||' -e '/@ZSH_PREFIX@/d' -e 's|""||' "${T}"/zprofile || die
- fi
-
- # fix cvs completion
- epatch "${FILESDIR}"/${P}-fix-cvs-completion.patch
-}
-
-src_configure() {
- local myconf=
-
- if use static ; then
- myconf+=" --disable-dynamic"
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=" \
- --enable-zsh-debug \
- --enable-zsh-mem-debug \
- --enable-zsh-mem-warning \
- --enable-zsh-secure-free \
- --enable-zsh-hash-debug"
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=" --enable-libs=-liconv"
- append-ldflags -Wl,-x
- fi
-
- econf \
- --bindir="${EPREFIX}"/bin \
- --libdir="${EPREFIX}"/usr/$(get_libdir) \
- --enable-etcdir="${EPREFIX}"/etc/zsh \
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help \
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions \
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions \
- --enable-function-subdirs \
- --with-tcsetpgrp \
- $(use_enable maildir maildir-support) \
- $(use_enable pcre) \
- $(use_enable caps cap) \
- $(use_enable unicode multibyte) \
- $(use_enable gdbm ) \
- ${myconf}
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -i \
- -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install install.info
-
- insinto /etc/zsh
- doins "${T}"/zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- # install miscellaneous scripts; bug #54520
- local i
- sed -i -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" "${S}"/{Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dohtml -r Doc/*
- insinto /usr/share/doc/${PF}
- doins Doc/zsh.{dvi,pdf}
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- # should link to https://www.gentoo.org/doc/en/zsh.xml
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- fi
-}
diff --git a/app-shells/zsh/zsh-5.0.8.ebuild b/app-shells/zsh/zsh-5.0.8.ebuild
deleted file mode 100644
index 90f8bbe..00000000
--- a/app-shells/zsh/zsh-5.0.8.ebuild
+++ /dev/null
@@ -1,210 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3 autotools
- EGIT_REPO_URI="git://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="http://www.zsh.org/pub/${P}.tar.bz2
- doc? ( http://www.zsh.org/pub/${P}-doc.tar.bz2 )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="http://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? ( >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] ) )
- gdbm? ( sys-libs/gdbm )
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == 9999* ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-src_prepare() {
- # fix zshall problem with soelim
- ln -s Doc man1
- mv Doc/zshall.1 Doc/zshall.1.soelim
- soelim Doc/zshall.1.soelim > Doc/zshall.1
-
- epatch "${FILESDIR}"/${PN}-init.d-gentoo-r1.diff
-
- cp "${FILESDIR}"/zprofile-1 "${T}"/zprofile || die
- eprefixify "${T}"/zprofile || die
- if use prefix ; then
- sed -i -e 's|@ZSH_PREFIX@||' -e '/@ZSH_NOPREFIX@/d' "${T}"/zprofile || die
- else
- sed -i -e 's|@ZSH_NOPREFIX@||' -e '/@ZSH_PREFIX@/d' -e 's|""||' "${T}"/zprofile || die
- fi
-
- if [[ ${PV} == 9999* ]] ; then
- sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
- eautoreconf
- fi
-}
-
-src_configure() {
- local myconf=()
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf \
- --bindir="${EPREFIX}"/bin \
- --libdir="${EPREFIX}"/usr/$(get_libdir) \
- --enable-etcdir="${EPREFIX}"/etc/zsh \
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help \
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions \
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions \
- --enable-function-subdirs \
- --with-tcsetpgrp \
- $(use_enable maildir maildir-support) \
- $(use_enable pcre) \
- $(use_enable caps cap) \
- $(use_enable unicode multibyte) \
- $(use_enable gdbm ) \
- "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == 9999* ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install install.info
-
- insinto /etc/zsh
- doins "${T}"/zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dohtml -r Doc/*
- insinto /usr/share/doc/${PF}
- doins Doc/zsh.{dvi,pdf}
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
diff --git a/app-shells/zsh/zsh-5.1.1.ebuild b/app-shells/zsh/zsh-5.1.1.ebuild
deleted file mode 100644
index 295b2ca..00000000
--- a/app-shells/zsh/zsh-5.1.1.ebuild
+++ /dev/null
@@ -1,213 +0,0 @@
-# Copyright 1999-2015 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id$
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3 autotools
- EGIT_REPO_URI="git://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="http://www.zsh.org/pub/${P}.tar.xz
- doc? ( http://www.zsh.org/pub/${P}-doc.tar.xz )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="http://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1:0
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? (
- >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] )
- )
- gdbm? ( sys-libs/gdbm )
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == 9999* ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-src_prepare() {
- # fix zshall problem with soelim
- ln -s Doc man1
- mv Doc/zshall.1 Doc/zshall.1.soelim
- soelim Doc/zshall.1.soelim > Doc/zshall.1
-
- epatch "${FILESDIR}"/${PN}-init.d-gentoo-r1.diff
- epatch "${FILESDIR}"/${PN}-5.1.0-gcc-5.patch #547950
-
- cp "${FILESDIR}"/zprofile-1 "${T}"/zprofile || die
- eprefixify "${T}"/zprofile || die
- if use prefix ; then
- sed -i -e 's|@ZSH_PREFIX@||' -e '/@ZSH_NOPREFIX@/d' "${T}"/zprofile || die
- else
- sed -i -e 's|@ZSH_NOPREFIX@||' -e '/@ZSH_PREFIX@/d' -e 's|""||' "${T}"/zprofile || die
- fi
-
- if [[ ${PV} == 9999* ]] ; then
- sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
- eautoreconf
- fi
-}
-
-src_configure() {
- local myconf=()
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf \
- --bindir="${EPREFIX}"/bin \
- --libdir="${EPREFIX}"/usr/$(get_libdir) \
- --enable-etcdir="${EPREFIX}"/etc/zsh \
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help \
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions \
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions \
- --enable-function-subdirs \
- --with-tcsetpgrp \
- $(use_enable maildir maildir-support) \
- $(use_enable pcre) \
- $(use_enable caps cap) \
- $(use_enable unicode multibyte) \
- $(use_enable gdbm ) \
- "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == 9999* ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install install.info
-
- insinto /etc/zsh
- doins "${T}"/zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dohtml -r Doc/*
- insinto /usr/share/doc/${PF}
- doins Doc/zsh.{dvi,pdf}
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2018-03-19 11:02 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2018-03-19 11:02 UTC (permalink / raw
To: gentoo-commits
commit: 8ec36bf177b47b498c7c270db72a32992877850c
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon Mar 19 11:01:02 2018 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon Mar 19 11:01:02 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=8ec36bf1
app-shells/zsh: Removed old.
Package-Manager: Portage-2.3.24, Repoman-2.3.6
app-shells/zsh/Manifest | 2 -
app-shells/zsh/files/zsh-5.1.0-gcc-5.patch | 16 --
app-shells/zsh/files/zsh-init.d-gentoo-r1.diff | 30 ----
app-shells/zsh/zsh-5.2.ebuild | 212 -------------------------
4 files changed, 260 deletions(-)
diff --git a/app-shells/zsh/Manifest b/app-shells/zsh/Manifest
index 3451a647c63..4d8f8bdd00b 100644
--- a/app-shells/zsh/Manifest
+++ b/app-shells/zsh/Manifest
@@ -1,5 +1,3 @@
-DIST zsh-5.2-doc.tar.xz 3108600 BLAKE2B ee8bf9d27f51093adc89fe2a14a93ba2d88b34a81d6214fca2d072ced954bf4b3d334fb17e132a9a5eac8ec18ca0251caa37f0370a7f6a3d4ef463b37e36f69e SHA512 a2e6b95c293546011e1697e0a2f66a3740092ef61904fa3b469f33e8af0ced6028fac77cd51ebe9ee4cb168403d9af7c72fd071a15ba3dc273243bd71fa714a0
-DIST zsh-5.2.tar.xz 2820108 BLAKE2B 53a1c7c1954abc0c533d650805d024e63fefae47163d64442cdc59b7867f994ea2e020d91bb1bf594ffa75af8f8437937f396a9d8f9e1b7de9cac1437b97f3b4 SHA512 9938af95e09203a0a313f441e0c23279136806f6f087475ca9a66c678c57ecffc87f73ece8133a36700af8de7cb5d1bec8559eabdec2b66102062e64026c2e72
DIST zsh-5.3.1-doc.tar.xz 3161408 BLAKE2B dc14f7b6136b73d5cfe8462fe67e20b92ee04741ad8f8a0f8d40bd1f8658261569722b156a075d7b723f2d38d41fc725e227c995eefebde433ea172399b90210 SHA512 27f9d50094c21a77b36fe3309a9ab81a2ccf6570139b11038bbebe9fff2d0701f0bccf9163f5bf47d51ce7b978df621a4cb9089c33e9179a61636fcc94a9fb9c
DIST zsh-5.3.1.tar.xz 2928832 BLAKE2B b561629f8641dac70a5b35e12333fb3b214c83ebd90d432c302e8b8e6fb1baa288ec4d32fdb7f917c2f1a845b96a6c676ab4e15a014a8b9474792cb77e2afea0 SHA512 25f723c76d2779c3cb53de2e0dbb1163ec289f76282bec49757880d0ce32bf64a001a6b40c54c290d342aa09f92319af5c597bff99de8dbd1fc895c11836f304
DIST zsh-5.4.2-doc.tar.xz 3198880 BLAKE2B 9ef3c6690251025b669a1cb46d3903d26a7407bc9fc0463c6d3678db57180b690f11302b202346a67afde16f6177fc8a597edca53bf55aaa835a5208e205b75e SHA512 5dcf561380ec46358754a0a03224152cb0db197d8a1558c6457342a6fd0ec6ea43bc3c1c1a79390a2a6034e09e0e668466962462ab14e90807170436a36f82b7
diff --git a/app-shells/zsh/files/zsh-5.1.0-gcc-5.patch b/app-shells/zsh/files/zsh-5.1.0-gcc-5.patch
deleted file mode 100644
index 74756d2946c..00000000000
--- a/app-shells/zsh/files/zsh-5.1.0-gcc-5.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-https://bugs.gentoo.org/547950
-http://www.zsh.org/mla/workers/2015/msg02660.html
-
-fix building w/gcc-5
-
---- a/Src/Modules/system.mdd
-+++ b/Src/Modules/system.mdd
-@@ -15,7 +15,7 @@
- touch errtmp.out; \
- else \
- $(AWK) -f $(sdir)/errnames1.awk @ERRNO_H@ >errtmp.c; \
-- $(CPP) errtmp.c >errtmp.out; \
-+ $(CPP) -P errtmp.c >errtmp.out; \
- fi
- $(AWK) -f $(sdir)/errnames2.awk errtmp.out > $@
- rm -f errtmp.c errtmp.out
diff --git a/app-shells/zsh/files/zsh-init.d-gentoo-r1.diff b/app-shells/zsh/files/zsh-init.d-gentoo-r1.diff
deleted file mode 100644
index 9597a733c90..00000000000
--- a/app-shells/zsh/files/zsh-init.d-gentoo-r1.diff
+++ /dev/null
@@ -1,30 +0,0 @@
---- zsh-4.3.11/Completion/Unix/Command/_init_d
-+++ zsh-4.3.11/Completion/Unix/Command/_init_d
-@@ -1,6 +1,6 @@
- #compdef -p */(init|rc[0-9S]#).d/*
-
--local cmds script
-+local cmds script opts
-
- _compskip=all
-
-@@ -83,10 +83,17 @@
-
- script=$words[1]
- [[ $script = */* ]] || script="$(_init_d_fullpath "$script")"
-+[[ ! -f $script ]] &&
-+ { _message "${words[1]:t} is not an init script" && return }
-
- cmds=( $(_init_d_get_cmds) ) || return
-
--(( $#cmds )) || zstyle -a ":completion:${curcontext}:commands" commands cmds ||
-- cmds=(start stop)
-+(( $#cmds )) || zstyle -a ":completion:${curcontext}:commands" commands cmds
-+opts=(start stop restart pause zap status ineed iuse needsme usesme broken)
-+
-+# If we didn't get $cmds from a zstyle, then read init script for opts.
-+# If script doesn't specify opts, then default to the standard opts.
-+(( $#cmds )) || cmds=( ${(eQz)${(M)${(f)"$( <$script)"}:#[[:blank:]]#opts=*}#*=} )
-+(( $#cmds )) || cmds=($opts)
-
- _sub_commands $cmds
diff --git a/app-shells/zsh/zsh-5.2.ebuild b/app-shells/zsh/zsh-5.2.ebuild
deleted file mode 100644
index 4f604601c84..00000000000
--- a/app-shells/zsh/zsh-5.2.ebuild
+++ /dev/null
@@ -1,212 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=5
-
-inherit eutils flag-o-matic multilib prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3 autotools
- EGIT_REPO_URI="git://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="alpha amd64 arm ~arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="http://www.zsh.org/pub/${P}.tar.xz
- doc? ( http://www.zsh.org/pub/${P}-doc.tar.xz )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="http://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1:0=
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? (
- >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] )
- )
- gdbm? ( sys-libs/gdbm:= )
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == 9999* ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-src_prepare() {
- # fix zshall problem with soelim
- ln -s Doc man1
- mv Doc/zshall.1 Doc/zshall.1.soelim
- soelim Doc/zshall.1.soelim > Doc/zshall.1
-
- epatch "${FILESDIR}"/${PN}-init.d-gentoo-r1.diff
- epatch "${FILESDIR}"/${PN}-5.1.0-gcc-5.patch #547950
-
- cp "${FILESDIR}"/zprofile-1 "${T}"/zprofile || die
- eprefixify "${T}"/zprofile || die
- if use prefix ; then
- sed -i -e 's|@ZSH_PREFIX@||' -e '/@ZSH_NOPREFIX@/d' "${T}"/zprofile || die
- else
- sed -i -e 's|@ZSH_NOPREFIX@||' -e '/@ZSH_PREFIX@/d' -e 's|""||' "${T}"/zprofile || die
- fi
-
- if [[ ${PV} == 9999* ]] ; then
- sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
- eautoreconf
- fi
-}
-
-src_configure() {
- local myconf=()
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf \
- --bindir="${EPREFIX}"/bin \
- --libdir="${EPREFIX}"/usr/$(get_libdir) \
- --enable-etcdir="${EPREFIX}"/etc/zsh \
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help \
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions \
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions \
- --enable-function-subdirs \
- --with-tcsetpgrp \
- $(use_enable maildir maildir-support) \
- $(use_enable pcre) \
- $(use_enable caps cap) \
- $(use_enable unicode multibyte) \
- $(use_enable gdbm ) \
- "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == 9999* ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install install.info
-
- insinto /etc/zsh
- doins "${T}"/zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dohtml -r Doc/*
- insinto /usr/share/doc/${PF}
- doins Doc/zsh.{dvi,pdf}
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2018-06-05 20:39 William Hubbs
0 siblings, 0 replies; 15+ messages in thread
From: William Hubbs @ 2018-06-05 20:39 UTC (permalink / raw
To: gentoo-commits
commit: d09566dc69f7806142d67955f8d05383d60d0622
Author: Mike Gilbert <floppym <AT> gentoo <DOT> org>
AuthorDate: Thu May 24 19:27:50 2018 +0000
Commit: William Hubbs <williamh <AT> gentoo <DOT> org>
CommitDate: Tue Jun 5 20:35:33 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d09566dc
app-shells/zsh: check for /usr/sbin in ROOTPATH before using it
The maintainer, radhermit <AT> gentoo.org, authorized me to fix this bug
(williamh).
Closes: https://bugs.gentoo.org/656400
Closes: https://github.com/gentoo/gentoo/pull/8550
Closes: https://github.com/gentoo/gentoo/pull/8566
app-shells/zsh/files/zprofile-4 | 42 ++++++++++++++++++++++
.../zsh/{zsh-5.5.1.ebuild => zsh-5.5.1-r1.ebuild} | 2 +-
app-shells/zsh/zsh-9999.ebuild | 11 ++----
3 files changed, 45 insertions(+), 10 deletions(-)
diff --git a/app-shells/zsh/files/zprofile-4 b/app-shells/zsh/files/zprofile-4
new file mode 100644
index 00000000000..6402ca718d3
--- /dev/null
+++ b/app-shells/zsh/files/zprofile-4
@@ -0,0 +1,42 @@
+# /etc/zsh/zprofile
+
+# Load environment settings from profile.env, which is created by
+# env-update from the files in /etc/env.d
+if [ -e /etc/profile.env ] ; then
+ . /etc/profile.env
+fi
+
+# You should override these in your ~/.zprofile (or equivalent) for per-user
+# settings. For system defaults, you can add a new file in /etc/profile.d/.
+export EDITOR=${EDITOR:-/bin/nano}
+export PAGER=${PAGER:-/usr/bin/less}
+
+# 077 would be more secure, but 022 is generally quite realistic
+umask 022
+
+# Set up PATH depending on whether we're root or a normal user.
+# There's no real reason to exclude sbin paths from the normal user,
+# but it can make tab-completion easier when they aren't in the
+# user's PATH to pollute the executable namespace.
+#
+# It is intentional in the following line to use || instead of -o.
+# This way the evaluation can be short-circuited and calling whoami is
+# avoided.
+if [ "$EUID" = "0" ] || [ "$USER" = "root" ] ; then
+ # Check to make sure ROOTPATH is sane before we use it.
+ # https://bugs.gentoo.org/656400
+ if [[ :${ROOTPATH}: == *:@GENTOO_PORTAGE_EPREFIX@/usr/sbin:* ]]; then
+ PATH="${ROOTPATH}"
+ fi
+fi
+export PATH
+unset ROOTPATH
+
+shopts=$-
+setopt nullglob
+for sh in /etc/profile.d/*.sh ; do
+ [ -r "$sh" ] && . "$sh"
+done
+unsetopt nullglob
+set -$shopts
+unset sh shopts
diff --git a/app-shells/zsh/zsh-5.5.1.ebuild b/app-shells/zsh/zsh-5.5.1-r1.ebuild
similarity index 98%
rename from app-shells/zsh/zsh-5.5.1.ebuild
rename to app-shells/zsh/zsh-5.5.1-r1.ebuild
index 4c17da09db4..9f6dc303d88 100644
--- a/app-shells/zsh/zsh-5.5.1.ebuild
+++ b/app-shells/zsh/zsh-5.5.1-r1.ebuild
@@ -139,7 +139,7 @@ src_install() {
insinto /etc/zsh
export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
- newins "$(prefixify_ro "${FILESDIR}"/zprofile-3)" zprofile
+ newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
keepdir /usr/share/zsh/site-functions
insinto /usr/share/zsh/${PV%_*}/functions/Prompts
diff --git a/app-shells/zsh/zsh-9999.ebuild b/app-shells/zsh/zsh-9999.ebuild
index f53a6be7a4d..9f6dc303d88 100644
--- a/app-shells/zsh/zsh-9999.ebuild
+++ b/app-shells/zsh/zsh-9999.ebuild
@@ -57,14 +57,6 @@ src_prepare() {
eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
fi
- cp "${FILESDIR}"/zprofile-2 "${T}"/zprofile || die
- eprefixify "${T}"/zprofile || die
- if use prefix ; then
- sed -i -e 's|@ZSH_PREFIX@||' -e '/@ZSH_NOPREFIX@/d' "${T}"/zprofile || die
- else
- sed -i -e 's|@ZSH_NOPREFIX@||' -e '/@ZSH_PREFIX@/d' -e 's|""||' "${T}"/zprofile || die
- fi
-
eapply_user
if [[ ${PV} == 9999* ]] ; then
@@ -146,7 +138,8 @@ src_install() {
emake DESTDIR="${D}" install $(usex doc "install.info" "")
insinto /etc/zsh
- doins "${T}"/zprofile
+ export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
+ newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
keepdir /usr/share/zsh/site-functions
insinto /usr/share/zsh/${PV%_*}/functions/Prompts
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2018-11-30 8:04 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2018-11-30 8:04 UTC (permalink / raw
To: gentoo-commits
commit: 7cca8ab466f778169e676c9467d3b9b418245221
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Fri Nov 30 08:02:50 2018 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Fri Nov 30 08:02:50 2018 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7cca8ab4
app-shells/zsh: Removed old.
Package-Manager: Portage-2.3.52, Repoman-2.3.12
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
app-shells/zsh/Manifest | 4 -
app-shells/zsh/files/zprofile-3 | 38 -------
app-shells/zsh/zsh-5.5.ebuild | 212 ----------------------------------------
app-shells/zsh/zsh-5.6.1.ebuild | 212 ----------------------------------------
4 files changed, 466 deletions(-)
diff --git a/app-shells/zsh/Manifest b/app-shells/zsh/Manifest
index cf8983f5a39..39f116b416a 100644
--- a/app-shells/zsh/Manifest
+++ b/app-shells/zsh/Manifest
@@ -1,8 +1,4 @@
-DIST zsh-5.5-doc.tar.xz 3216400 BLAKE2B 3d07b336222b08d7deff0ded6f603a47bcdcec978e6ad9c244b25f5249e07c22768ba30e67f02c8ebf4a0a8104997d0aa8959de7e3c39a428dca0b013c56e9b1 SHA512 0bde166bc4a4b8ea7512bd9d3ede53478959cb76ded65488b9a8993734cf2a8ffedcd38254fbf6ff73a5841289cb65715579744b10748afb038c9d93a01f987b
DIST zsh-5.5.1-doc.tar.xz 3216632 BLAKE2B ef1274799604d74eb9cec3c29927703c98bb63bde3aa5ce4880eda45420fe1eb79c54a693fe529c9e79161f924a76bc2a650253216c7b1e565af65f1ac3c0d91 SHA512 e240f6c6aa2efb941c2baaaf749c66c9e304ba54ce2be90586671ba47e380aac89315516e5dce41fa0ae1d8fccfc36f61ed1400b6aab3382927e2715a77d62e6
DIST zsh-5.5.1.tar.gz 4578700 BLAKE2B b58fc763bc64e8ed6de0db2e0fd454aef995fcc86b18c2ffd4b39e037ce1cdeb04e6e2a44b2495ca89218af41ad1dd7d29e429d21fbab39377d95e62d249732e SHA512 c4f7327a3f5480bd9a169fb07e34812e0106fa9de3b5f7d38bb0db85a3e4d01b9a4a8f35553da03a15d7d819108305cfaa2811c945273e2cac84512219e69ebb
-DIST zsh-5.5.tar.gz 4576506 BLAKE2B 4f5923d519b0c96475f4832cf0e5cabc1432e765d201c992903ead45b175d5bc76410ebe248c2bd01ad75a5b5939bc5bc58e9263bb4501f9b2c1f5b4d7755896 SHA512 aafa29e1bc29d35fb5822ad4ca5f4c64b1e4a4e3f9bff70e9e5976918fa9e7906467bd11f69291e694dfa77efa1e5433d7839fc668aa572228623f1c131c381f
-DIST zsh-5.6.1-doc.tar.xz 3199032 BLAKE2B 02b1eff0c1c0c49108f044f45f3d10f5d3c09bb1f52631e0090a06e1e87ae29e5b85e51f78f8aec918bcdb5122b0ac6dfcfda591f9f80de3ee54280917999356 SHA512 a3b64c01ce817d31c48bd8da7342af2a2adb116e6f58dab84f9c79fc9e687c4d83b2e5a2375ffe070376adc609b3f4f4f4114e5fd77f6f0b75859c5c30f7c752
-DIST zsh-5.6.1.tar.xz 3076732 BLAKE2B aaddea57cb3b926277fd90dd38a2a313ffb4e5222b24efe50b2baccb3b09af096a0107eed86746a5160f4112f8c91c3fa04f9bf86470607244d44f272379ec09 SHA512 45a60b864482a276277d8443f6faf41a2f63e11ab89a4ec0276c897971f34a874393f79c118af915b8f325a1b0265a457a1a82e8d33530f7fb797ece9c2adb7b
DIST zsh-5.6.2-doc.tar.xz 3198932 BLAKE2B 7e701bb12e0114b7d9847caad1146fa3d538f8f6d859a765037660fb18341f1c79002811a42ec795e41eb2bbe899e12d4bcd055ea5c66e7b73bd488bdf8bbb55 SHA512 5102314e2857b032c6e6b4b715c261970b2f0c28663aff99fb87f7bb6c3971f88f8e8892ed349793570beae3fb68ff7923c82e99a3c1bb485e4639f01caaad4a
DIST zsh-5.6.2.tar.xz 3077368 BLAKE2B 8c6ce22436f9f51eff809c779efad02f4a0730b4431630ab305abc9f1ef722698f7c565d0aa421b0d94c21f2c830f9d529709fd62a4205be1a20acf0f94a845a SHA512 f0a49e41b55eb478692ab5471d7c9828956b7e96bc82944202b0ef1c49a889b21a0e7682aa5f59fd0054ebfd866c2244c8a622e7aa46c13038af5c226c48a3a2
diff --git a/app-shells/zsh/files/zprofile-3 b/app-shells/zsh/files/zprofile-3
deleted file mode 100644
index 6c223a5ef15..00000000000
--- a/app-shells/zsh/files/zprofile-3
+++ /dev/null
@@ -1,38 +0,0 @@
-# /etc/zsh/zprofile
-
-# Load environment settings from profile.env, which is created by
-# env-update from the files in /etc/env.d
-if [ -e /etc/profile.env ] ; then
- . /etc/profile.env
-fi
-
-# You should override these in your ~/.zprofile (or equivalent) for per-user
-# settings. For system defaults, you can add a new file in /etc/profile.d/.
-export EDITOR=${EDITOR:-/bin/nano}
-export PAGER=${PAGER:-/usr/bin/less}
-
-# 077 would be more secure, but 022 is generally quite realistic
-umask 022
-
-# Set up PATH depending on whether we're root or a normal user.
-# There's no real reason to exclude sbin paths from the normal user,
-# but it can make tab-completion easier when they aren't in the
-# user's PATH to pollute the executable namespace.
-#
-# It is intentional in the following line to use || instead of -o.
-# This way the evaluation can be short-circuited and calling whoami is
-# avoided.
-if [ "$EUID" = "0" ] || [ "$USER" = "root" ] ; then
- PATH="${ROOTPATH}"
-fi
-export PATH
-unset ROOTPATH
-
-shopts=$-
-setopt nullglob
-for sh in /etc/profile.d/*.sh ; do
- [ -r "$sh" ] && . "$sh"
-done
-unsetopt nullglob
-set -$shopts
-unset sh shopts
diff --git a/app-shells/zsh/zsh-5.5.ebuild b/app-shells/zsh/zsh-5.5.ebuild
deleted file mode 100644
index 0d1b94fa1ce..00000000000
--- a/app-shells/zsh/zsh-5.5.ebuild
+++ /dev/null
@@ -1,212 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=6
-
-inherit flag-o-matic prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3 autotools
- EGIT_REPO_URI="git://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="alpha amd64 arm arm64 hppa ia64 ~m68k ~mips ppc ppc64 ~s390 ~sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="https://www.zsh.org/pub/${P}.tar.gz
- https://www.zsh.org/pub/old/${P}.tar.gz
- doc? ( https://www.zsh.org/pub/${P}-doc.tar.xz )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="https://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1:0=
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? (
- >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] )
- )
- gdbm? ( sys-libs/gdbm:= )
- !<sys-apps/baselayout-2.4.1
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == 9999* ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-src_prepare() {
- if [[ ${PV} != 9999* ]]; then
- # fix zshall problem with soelim
- ln -s Doc man1 || die
- mv Doc/zshall.1 Doc/zshall.1.soelim || die
- soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
-
- # add openrc specific options for init.d completion
- eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
- fi
-
- eapply_user
-
- if [[ ${PV} == 9999* ]] ; then
- sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
- eautoreconf
- fi
-}
-
-src_configure() {
- local myconf=(
- --bindir="${EPREFIX}"/bin
- --libdir="${EPREFIX}"/usr/$(get_libdir)
- --enable-etcdir="${EPREFIX}"/etc/zsh
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
- --enable-function-subdirs
- --with-tcsetpgrp
- $(use_enable maildir maildir-support)
- $(use_enable pcre)
- $(use_enable caps cap)
- $(use_enable unicode multibyte)
- $(use_enable gdbm )
- )
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == 9999* ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install $(usex doc "install.info" "")
-
- insinto /etc/zsh
- export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
- newins "$(prefixify_ro "${FILESDIR}"/zprofile-3)" zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- docinto html
- dodoc Doc/*.html
- insinto /usr/share/doc/${PF}
- doins Doc/zsh.{dvi,pdf}
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
diff --git a/app-shells/zsh/zsh-5.6.1.ebuild b/app-shells/zsh/zsh-5.6.1.ebuild
deleted file mode 100644
index 6b7bbf5c1e4..00000000000
--- a/app-shells/zsh/zsh-5.6.1.ebuild
+++ /dev/null
@@ -1,212 +0,0 @@
-# Copyright 1999-2018 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit flag-o-matic prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3 autotools
- EGIT_REPO_URI="https://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
- https://www.zsh.org/pub/old/${P}.tar.xz
- doc? ( https://www.zsh.org/pub/${P}-doc.tar.xz )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="https://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1:0=
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? (
- >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] )
- )
- gdbm? ( sys-libs/gdbm:= )
- !<sys-apps/baselayout-2.4.1
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == 9999* ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-src_prepare() {
- if [[ ${PV} != 9999* ]]; then
- # fix zshall problem with soelim
- ln -s Doc man1 || die
- mv Doc/zshall.1 Doc/zshall.1.soelim || die
- soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
-
- # add openrc specific options for init.d completion
- eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
- fi
-
- eapply_user
-
- if [[ ${PV} == 9999* ]] ; then
- sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
- eautoreconf
- fi
-}
-
-src_configure() {
- local myconf=(
- --bindir="${EPREFIX}"/bin
- --libdir="${EPREFIX}"/usr/$(get_libdir)
- --enable-etcdir="${EPREFIX}"/etc/zsh
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
- --enable-function-subdirs
- --with-tcsetpgrp
- $(use_enable maildir maildir-support)
- $(use_enable pcre)
- $(use_enable caps cap)
- $(use_enable unicode multibyte)
- $(use_enable gdbm)
- )
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == 9999* ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install $(usex doc "install.info" "")
-
- insinto /etc/zsh
- export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
- newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- docinto html
- dodoc Doc/*.html
- insinto /usr/share/doc/${PF}
- doins Doc/zsh.{dvi,pdf}
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2019-01-27 22:54 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2019-01-27 22:54 UTC (permalink / raw
To: gentoo-commits
commit: 90fec4c639c41d18e1da04ce35e36a019f5762c2
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Sun Jan 27 22:49:47 2019 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Sun Jan 27 22:49:47 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=90fec4c6
app-shells/zsh: Revbump to fix inifinite recursion.
Package-Manager: Portage-2.3.58, Repoman-2.3.12
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
.../zsh/files/zsh-5.7-fix_infinite_recursion.patch | 35 ++++++++++++++++++++++
.../zsh/{zsh-5.7.ebuild => zsh-5.7-r1.ebuild} | 6 +++-
2 files changed, 40 insertions(+), 1 deletion(-)
diff --git a/app-shells/zsh/files/zsh-5.7-fix_infinite_recursion.patch b/app-shells/zsh/files/zsh-5.7-fix_infinite_recursion.patch
new file mode 100644
index 00000000000..042b948b23d
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.7-fix_infinite_recursion.patch
@@ -0,0 +1,35 @@
+From b70919e0d9dadc93893e9d18bc3ef13b88756ecf Mon Sep 17 00:00:00 2001
+From: dana <dana@dana.is>
+Date: Sun, 27 Jan 2019 00:26:31 -0600
+Subject: [PATCH] 44020: VCS_INFO_detect_p4: Fix infinite recursion
+
+---
+ ChangeLog | 5 +++++
+ Functions/VCS_Info/Backends/VCS_INFO_detect_p4 | 1 -
+ 2 files changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/ChangeLog b/ChangeLog
+index 81668ccc9..be243c1b8 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,8 @@
++2018-01-27 dana <dana@dana.is>
++
++ * 44020: Functions/VCS_Info/Backends/VCS_INFO_detect_p4: Fix
++ infinite recursion
++
+ 2018-01-24 dana <dana@dana.is>
+
+ * unposted: Config/version.mk: Post-release version bump
+diff --git a/Functions/VCS_Info/Backends/VCS_INFO_detect_p4 b/Functions/VCS_Info/Backends/VCS_INFO_detect_p4
+index d171c68ee..5ec21da9f 100644
+--- a/Functions/VCS_Info/Backends/VCS_INFO_detect_p4
++++ b/Functions/VCS_Info/Backends/VCS_INFO_detect_p4
+@@ -44,7 +44,6 @@ VCS_INFO_p4_get_server() {
+ }
+
+
+-(( ${+functions[VCS_INFO_detect_p4]} )) ||
+ VCS_INFO_detect_p4() {
+ local serverport p4where
+
diff --git a/app-shells/zsh/zsh-5.7.ebuild b/app-shells/zsh/zsh-5.7-r1.ebuild
similarity index 98%
rename from app-shells/zsh/zsh-5.7.ebuild
rename to app-shells/zsh/zsh-5.7-r1.ebuild
index a0de20264a8..113f397ad17 100644
--- a/app-shells/zsh/zsh-5.7.ebuild
+++ b/app-shells/zsh/zsh-5.7-r1.ebuild
@@ -51,6 +51,10 @@ if [[ ${PV} == 9999* ]] ; then
)"
fi
+PATCHES=(
+ "${FILESDIR}"/${P}-fix_infinite_recursion.patch
+)
+
src_prepare() {
if [[ ${PV} != 9999* ]]; then
# fix zshall problem with soelim
@@ -62,7 +66,7 @@ src_prepare() {
eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
fi
- eapply_user
+ default
if [[ ${PV} == 9999* ]] ; then
sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2019-12-12 9:21 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2019-12-12 9:21 UTC (permalink / raw
To: gentoo-commits
commit: 7ac3356118d49aa8fcf73dc83c44274cf55b490a
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Thu Dec 12 09:19:18 2019 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Thu Dec 12 09:21:22 2019 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7ac33561
app-shells/zsh: Revbump to fix ncurses detection
Package-Manager: Portage-2.3.81, Repoman-2.3.20
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
.../zsh/files/zsh-5.7.1-ncurses_colors.patch | 37 ++++
app-shells/zsh/zsh-5.7.1-r1.ebuild | 221 +++++++++++++++++++++
2 files changed, 258 insertions(+)
diff --git a/app-shells/zsh/files/zsh-5.7.1-ncurses_colors.patch b/app-shells/zsh/files/zsh-5.7.1-ncurses_colors.patch
new file mode 100644
index 00000000000..3dc2a7d5a1a
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.7.1-ncurses_colors.patch
@@ -0,0 +1,37 @@
+From 7ce49801cc8ebc6f3a343ee5b829007f8cfb2bce Mon Sep 17 00:00:00 2001
+From: Lars Wendler <polynomial-c@gentoo.org>
+Date: Wed, 11 Dec 2019 14:56:25 +0100
+Subject: [PATCH] configure.ac: check for has_colors symbol in curses lib
+
+Otherwise zsh/curses module won't get built if ncurses was built with
+separate tinfo lib.
+One could still force-build the module but loading it later yields the
+following error message:
+
+ failed to load module `zsh/curses': /usr/lib64/zsh/5.7.1/zsh/curses.so:
+ undefined symbol: COLORS
+
+That is because the final linker call requires -lncurses(w) but it only
+contains -ltinfo(w).
+
+Reported-by: Tetja Rediske <tetja@tetja.de>
+Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
+---
+ configure.ac | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/configure.ac b/configure.ac
+index 5513e25f1..792ad4db0 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -814,6 +814,7 @@ AC_SEARCH_LIBS(tgetent, [$termcap_curses_order],
+ This is probably a library called 'curses' or 'ncurses'. You may
+ need to install a package called 'curses-devel' or 'ncurses-devel' on your
+ system."], 255))
++AC_SEARCH_LIBS(has_colors, [$termcap_curses_order])
+ AC_CHECK_HEADERS(curses.h, [],
+ [AC_CACHE_CHECK(for Solaris 8 curses.h mistake, ac_cv_header_curses_solaris,
+ AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <curses.h>]], [[]])],[ac_cv_header_curses_h=yes
+--
+2.24.1
+
diff --git a/app-shells/zsh/zsh-5.7.1-r1.ebuild b/app-shells/zsh/zsh-5.7.1-r1.ebuild
new file mode 100644
index 00000000000..391dda5cc54
--- /dev/null
+++ b/app-shells/zsh/zsh-5.7.1-r1.ebuild
@@ -0,0 +1,221 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools flag-o-matic prefix
+
+if [[ ${PV} == 9999* ]] ; then
+ inherit git-r3
+ EGIT_REPO_URI="https://git.code.sf.net/p/zsh/code"
+else
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~m68k-mint ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+ SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
+ https://www.zsh.org/pub/old/${P}.tar.xz
+ mirror://sourceforge/${PN}/${P}.tar.xz
+ doc? (
+ https://www.zsh.org/pub/${P}-doc.tar.xz
+ mirror://sourceforge/${PN}/${P}-doc.tar.xz
+ )"
+fi
+
+DESCRIPTION="UNIX Shell similar to the Korn shell"
+HOMEPAGE="https://www.zsh.org/"
+
+LICENSE="ZSH gdbm? ( GPL-2 )"
+SLOT="0"
+IUSE="caps debug doc examples gdbm maildir pcre static unicode"
+
+RDEPEND="
+ >=sys-libs/ncurses-5.1:0=
+ static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
+ caps? ( sys-libs/libcap )
+ pcre? (
+ >=dev-libs/libpcre-3.9
+ static? ( >=dev-libs/libpcre-3.9[static-libs] )
+ )
+ gdbm? ( sys-libs/gdbm:= )
+ !<sys-apps/baselayout-2.4.1
+"
+DEPEND="sys-apps/groff
+ ${RDEPEND}"
+PDEPEND="
+ examples? ( app-doc/zsh-lovers )
+"
+if [[ ${PV} == 9999* ]] ; then
+ DEPEND+=" app-text/yodl
+ doc? (
+ sys-apps/texinfo
+ app-text/texi2html
+ virtual/latex-base
+ )"
+fi
+
+PATCHES=(
+ "${FILESDIR}/${PN}-5.7.1-ncurses_colors.patch"
+)
+
+src_prepare() {
+ if [[ ${PV} != 9999* ]]; then
+ # fix zshall problem with soelim
+ ln -s Doc man1 || die
+ mv Doc/zshall.1 Doc/zshall.1.soelim || die
+ soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
+
+ # add openrc specific options for init.d completion
+ eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
+ fi
+
+ default
+
+ hprefixify configure.ac
+ if [[ ${PV} == 9999* ]] ; then
+ sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
+ fi
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=(
+ --bindir="${EPREFIX}"/bin
+ --libdir="${EPREFIX}"/usr/$(get_libdir)
+ --enable-etcdir="${EPREFIX}"/etc/zsh
+ --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
+ --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
+ --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
+ --enable-function-subdirs
+ --with-tcsetpgrp
+ --with-term-lib="$(usex unicode 'tinfow ncursesw' 'tinfo ncurses')"
+ $(use_enable maildir maildir-support)
+ $(use_enable pcre)
+ $(use_enable caps cap)
+ $(use_enable unicode multibyte)
+ $(use_enable gdbm)
+ )
+
+ if use static ; then
+ myconf+=( --disable-dynamic )
+ append-ldflags -static
+ fi
+ if use debug ; then
+ myconf+=(
+ --enable-zsh-debug
+ --enable-zsh-mem-debug
+ --enable-zsh-mem-warning
+ --enable-zsh-secure-free
+ --enable-zsh-hash-debug
+ )
+ fi
+
+ if [[ ${CHOST} == *-darwin* ]]; then
+ myconf+=( --enable-libs=-liconv )
+ append-ldflags -Wl,-x
+ fi
+
+ econf "${myconf[@]}"
+
+ if use static ; then
+ # compile all modules statically, see Bug #27392
+ # removed cap and curses because linking failes
+ sed -e "s,link=no,link=static,g" \
+ -e "/^name=zsh\/cap/s,link=static,link=no," \
+ -e "/^name=zsh\/curses/s,link=static,link=no," \
+ -i "${S}"/config.modules || die
+ if ! use gdbm ; then
+ sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
+ "${S}"/config.modules || die
+ fi
+ fi
+}
+
+src_compile() {
+ default
+
+ if [[ ${PV} == 9999* ]] && use doc ; then
+ emake -C Doc everything
+ fi
+}
+
+src_test() {
+ addpredict /dev/ptmx
+ local i
+ for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
+ rm "${S}"/Test/${i} || die
+ done
+ emake check
+}
+
+src_install() {
+ emake DESTDIR="${D}" install $(usex doc "install.info" "")
+
+ insinto /etc/zsh
+ export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
+ newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
+
+ keepdir /usr/share/zsh/site-functions
+ insinto /usr/share/zsh/${PV%_*}/functions/Prompts
+ newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
+
+ local i
+
+ # install miscellaneous scripts (bug #54520)
+ sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
+ -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
+ -i {Util,Misc}/* || die
+ for i in Util Misc ; do
+ insinto /usr/share/zsh/${PV%_*}/${i}
+ doins ${i}/*
+ done
+
+ # install header files (bug #538684)
+ insinto /usr/include/zsh
+ doins config.h Src/*.epro
+ for i in Src/{zsh.mdh,*.h} ; do
+ sed -e 's@\.\./config\.h@config.h@' \
+ -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
+ -i "${i}"
+ doins "${i}"
+ done
+
+ dodoc ChangeLog* META-FAQ NEWS README config.modules
+
+ if use doc ; then
+ pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
+ dodoc Doc/zsh.{dvi,pdf}
+ docinto html
+ dodoc Doc/*.html
+ popd >/dev/null
+ fi
+
+ docinto StartupFiles
+ dodoc StartupFiles/z*
+}
+
+pkg_postinst() {
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
+ echo
+ elog "If you want to enable Portage completions and Gentoo prompt,"
+ elog "emerge app-shells/gentoo-zsh-completions and add"
+ elog " autoload -U compinit promptinit"
+ elog " compinit"
+ elog " promptinit; prompt gentoo"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Also, if you want to enable cache for the completions, add"
+ elog " zstyle ':completion::complete:*' use-cache 1"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Note that a system zprofile startup file is installed. This will override"
+ elog "PATH and possibly other variables that a user may set in ~/.zshenv."
+ elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
+ elog "or other user startup files that are sourced after the system zprofile."
+ echo
+ elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
+ elog "one method is to use a separate path-setting file that is conditionally sourced"
+ elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
+ elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
+ echo
+ elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
+ echo
+ fi
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2022-02-12 18:50 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2022-02-12 18:50 UTC (permalink / raw
To: gentoo-commits
commit: a26c773f643fcfe35288ddfc0321a7a7d51fda0c
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Sat Feb 12 18:49:23 2022 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Sat Feb 12 18:50:42 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a26c773f
app-shells/zsh: Bump to version 5.8.1
Closes: https://bugs.gentoo.org/777333
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
app-shells/zsh/Manifest | 2 +
app-shells/zsh/files/zprofile-4 | 4 +-
app-shells/zsh/zsh-5.8.1.ebuild | 217 ++++++++++++++++++++++++++++++++++++++++
3 files changed, 221 insertions(+), 2 deletions(-)
diff --git a/app-shells/zsh/Manifest b/app-shells/zsh/Manifest
index 37076afac198..c63e18da2314 100644
--- a/app-shells/zsh/Manifest
+++ b/app-shells/zsh/Manifest
@@ -1,2 +1,4 @@
DIST zsh-5.8-doc.tar.xz 3088696 BLAKE2B f738bf15b137e84df91fff8500b6c309884d8a1777e3158807f6028a411ae3f345e6ccba49bdff04c6607c4eb06fc2913313e84e1f78be0a0f92d23e46ba87db SHA512 38cc549818eb9c6952051b714dd2008d99605aba4ca4f614e62b033c9b067dd2031fff766ac5c1efe5bb52eae32bd482dea5df2b2d46decb7ecdb458f3da9d52
+DIST zsh-5.8.1-doc.tar.xz 3088728 BLAKE2B c7f62f50a8fce483d2946ac550fa0996e5749a9040cf9424a61d591024292a2f1eb0fc2401824104c6ef0fff2a4b38e07269a0069cde1b0bff6e8a7b09daf160 SHA512 0d8ca4c54c10e8a471ba7d53f1371ee057f7df4b710fc01194833f29a61b5465133432b891b0b891b6cc5235a928a783bf99f39c67314e29e3d161ca5abf3219
+DIST zsh-5.8.1.tar.xz 3200540 BLAKE2B 19981d0cc208fb590af8e034bde66bda36a4a20abe76ff71ba9222d7150b7d53573e1f5b81ddb2cdd29f6aa0611071a35d8b48250e6bd4b196f0428b776c4af8 SHA512 f54a5a47ed15d134902613f6169c985680afc45a67538505e11b66b348fcb367145e9b8ae2d9eac185e07ef5f97254b85df01ba97294002a8c036fd02ed5e76d
DIST zsh-5.8.tar.xz 3193284 BLAKE2B b1186dd27aede3318763d7c42253e919e60d00a018d085b2de7e8d985c872e9756a3ce112f623a088ec0878abd7a38d04dfa5ec552ef0f0a72e623191a7ba5e3 SHA512 96198ecef498b7d7945fecebbe6bf14065fa8c5d81a7662164579eba8206b79575812d292adea1864bc7487ac0818ba900e25f9ab3802449340de80417c2c533
diff --git a/app-shells/zsh/files/zprofile-4 b/app-shells/zsh/files/zprofile-4
index b92c245784dd..9155aae3fc58 100644
--- a/app-shells/zsh/files/zprofile-4
+++ b/app-shells/zsh/files/zprofile-4
@@ -22,10 +22,10 @@ umask 022
# It is intentional in the following line to use || instead of -o.
# This way the evaluation can be short-circuited and calling whoami is
# avoided.
-if [[ "$EUID" = "0" ]] || [[ "$USER" = "root" ]] ; then
+if [[ "${EUID}" = "0" ]] || [[ "${USER}" = "root" ]] ; then
# Check to make sure ROOTPATH is sane before we use it.
# https://bugs.gentoo.org/656400
- if [[ :${ROOTPATH}: == *:/usr/sbin:* ]]; then
+ if [[ -n ${ROOTPATH} ]] && [[ :${ROOTPATH}: == *:/usr/sbin:* ]] ; then
PATH="${ROOTPATH}"
fi
fi
diff --git a/app-shells/zsh/zsh-5.8.1.ebuild b/app-shells/zsh/zsh-5.8.1.ebuild
new file mode 100644
index 000000000000..1e2235175665
--- /dev/null
+++ b/app-shells/zsh/zsh-5.8.1.ebuild
@@ -0,0 +1,217 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools flag-o-matic prefix
+
+if [[ ${PV} == 9999* ]] ; then
+ inherit git-r3
+ EGIT_REPO_URI="https://git.code.sf.net/p/zsh/code"
+else
+ KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+ SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
+ https://www.zsh.org/pub/old/${P}.tar.xz
+ mirror://sourceforge/${PN}/${P}.tar.xz
+ doc? (
+ https://www.zsh.org/pub/${P}-doc.tar.xz
+ mirror://sourceforge/${PN}/${P}-doc.tar.xz
+ )"
+fi
+
+DESCRIPTION="UNIX Shell similar to the Korn shell"
+HOMEPAGE="https://www.zsh.org/"
+
+LICENSE="ZSH gdbm? ( GPL-2 )"
+SLOT="0"
+IUSE="caps debug doc examples gdbm maildir pcre static unicode"
+
+RDEPEND="
+ >=sys-libs/ncurses-5.1:0=
+ static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
+ caps? ( sys-libs/libcap )
+ pcre? (
+ >=dev-libs/libpcre-3.9
+ static? ( >=dev-libs/libpcre-3.9[static-libs] )
+ )
+ gdbm? ( sys-libs/gdbm:= )
+ !<sys-apps/baselayout-2.4.1
+"
+DEPEND="sys-apps/groff
+ ${RDEPEND}"
+PDEPEND="
+ examples? ( app-doc/zsh-lovers )
+"
+if [[ ${PV} == *9999 ]] ; then
+ DEPEND+=" app-text/yodl
+ doc? (
+ sys-apps/texinfo
+ app-text/texi2html
+ virtual/latex-base
+ )"
+fi
+
+src_prepare() {
+ if [[ ${PV} != *9999 ]]; then
+ # fix zshall problem with soelim
+ ln -s Doc man1 || die
+ mv Doc/zshall.1 Doc/zshall.1.soelim || die
+ soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
+ fi
+
+ # add openrc specific options for init.d completion
+ eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
+
+ default
+
+ hprefixify configure.ac
+ if [[ ${PV} == *9999 ]] ; then
+ sed -i "/^VERSION=/s@=.*@=${PV}@" Config/version.mk || die
+ fi
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=(
+ --bindir="${EPREFIX}"/bin
+ --libdir="${EPREFIX}"/usr/$(get_libdir)
+ --enable-etcdir="${EPREFIX}"/etc/zsh
+ --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
+ --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
+ --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
+ --enable-function-subdirs
+ --with-tcsetpgrp
+ --with-term-lib="$(usex unicode 'tinfow ncursesw' 'tinfo ncurses')"
+ $(use_enable maildir maildir-support)
+ $(use_enable pcre)
+ $(use_enable caps cap)
+ $(use_enable unicode multibyte)
+ $(use_enable gdbm)
+ )
+
+ if use static ; then
+ myconf+=( --disable-dynamic )
+ append-ldflags -static
+ fi
+ if use debug ; then
+ myconf+=(
+ --enable-zsh-debug
+ --enable-zsh-mem-debug
+ --enable-zsh-mem-warning
+ --enable-zsh-secure-free
+ --enable-zsh-hash-debug
+ )
+ fi
+
+ if [[ ${CHOST} == *-darwin* ]]; then
+ myconf+=( --enable-libs=-liconv )
+ append-ldflags -Wl,-x
+ fi
+
+ econf "${myconf[@]}"
+
+ if use static ; then
+ # compile all modules statically, see Bug #27392
+ # removed cap and curses because linking failes
+ sed -e "s,link=no,link=static,g" \
+ -e "/^name=zsh\/cap/s,link=static,link=no," \
+ -e "/^name=zsh\/curses/s,link=static,link=no," \
+ -i "${S}"/config.modules || die
+ if ! use gdbm ; then
+ sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
+ "${S}"/config.modules || die
+ fi
+ fi
+}
+
+src_compile() {
+ default
+
+ if [[ ${PV} == *9999 ]] && use doc ; then
+ emake -C Doc everything
+ fi
+}
+
+src_test() {
+ addpredict /dev/ptmx
+ local i
+ for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
+ rm "${S}"/Test/${i} || die
+ done
+ emake check
+}
+
+src_install() {
+ emake DESTDIR="${D}" install $(usex doc "install.info" "")
+
+ insinto /etc/zsh
+ export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
+ newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
+
+ keepdir /usr/share/zsh/site-functions
+ insinto /usr/share/zsh/${PV%_*}/functions/Prompts
+ newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
+
+ local i
+
+ # install miscellaneous scripts (bug #54520)
+ sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
+ -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
+ -i {Util,Misc}/* || die
+ for i in Util Misc ; do
+ insinto /usr/share/zsh/${PV%_*}/${i}
+ doins ${i}/*
+ done
+
+ # install header files (bug #538684)
+ insinto /usr/include/zsh
+ doins config.h Src/*.epro
+ for i in Src/{zsh.mdh,*.h} ; do
+ sed -e 's@\.\./config\.h@config.h@' \
+ -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
+ -i "${i}"
+ doins "${i}"
+ done
+
+ dodoc ChangeLog* META-FAQ NEWS README config.modules
+
+ if use doc ; then
+ pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
+ dodoc Doc/zsh.{dvi,pdf}
+ docinto html
+ dodoc Doc/*.html
+ popd >/dev/null
+ fi
+
+ docinto StartupFiles
+ dodoc StartupFiles/z*
+}
+
+pkg_postinst() {
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
+ echo
+ elog "If you want to enable Portage completions and Gentoo prompt,"
+ elog "emerge app-shells/gentoo-zsh-completions and add"
+ elog " autoload -U compinit promptinit"
+ elog " compinit"
+ elog " promptinit; prompt gentoo"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Also, if you want to enable cache for the completions, add"
+ elog " zstyle ':completion::complete:*' use-cache 1"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Note that a system zprofile startup file is installed. This will override"
+ elog "PATH and possibly other variables that a user may set in ~/.zshenv."
+ elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
+ elog "or other user startup files that are sourced after the system zprofile."
+ echo
+ elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
+ elog "one method is to use a separate path-setting file that is conditionally sourced"
+ elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
+ elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
+ echo
+ elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
+ echo
+ fi
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2022-02-18 13:43 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2022-02-18 13:43 UTC (permalink / raw
To: gentoo-commits
commit: 61e46f37256b4148e607ce314859a526aba51ad6
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Fri Feb 18 13:42:55 2022 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Fri Feb 18 13:43:14 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=61e46f37
app-shells/zsh: Security cleanup
Bug: https://bugs.gentoo.org/833252
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
app-shells/zsh/Manifest | 2 -
.../zsh/files/zsh-5.7.1-ncurses_colors.patch | 37 ----
app-shells/zsh/zsh-5.8.ebuild | 221 ---------------------
3 files changed, 260 deletions(-)
diff --git a/app-shells/zsh/Manifest b/app-shells/zsh/Manifest
index c63e18da2314..4ce7faa192bc 100644
--- a/app-shells/zsh/Manifest
+++ b/app-shells/zsh/Manifest
@@ -1,4 +1,2 @@
-DIST zsh-5.8-doc.tar.xz 3088696 BLAKE2B f738bf15b137e84df91fff8500b6c309884d8a1777e3158807f6028a411ae3f345e6ccba49bdff04c6607c4eb06fc2913313e84e1f78be0a0f92d23e46ba87db SHA512 38cc549818eb9c6952051b714dd2008d99605aba4ca4f614e62b033c9b067dd2031fff766ac5c1efe5bb52eae32bd482dea5df2b2d46decb7ecdb458f3da9d52
DIST zsh-5.8.1-doc.tar.xz 3088728 BLAKE2B c7f62f50a8fce483d2946ac550fa0996e5749a9040cf9424a61d591024292a2f1eb0fc2401824104c6ef0fff2a4b38e07269a0069cde1b0bff6e8a7b09daf160 SHA512 0d8ca4c54c10e8a471ba7d53f1371ee057f7df4b710fc01194833f29a61b5465133432b891b0b891b6cc5235a928a783bf99f39c67314e29e3d161ca5abf3219
DIST zsh-5.8.1.tar.xz 3200540 BLAKE2B 19981d0cc208fb590af8e034bde66bda36a4a20abe76ff71ba9222d7150b7d53573e1f5b81ddb2cdd29f6aa0611071a35d8b48250e6bd4b196f0428b776c4af8 SHA512 f54a5a47ed15d134902613f6169c985680afc45a67538505e11b66b348fcb367145e9b8ae2d9eac185e07ef5f97254b85df01ba97294002a8c036fd02ed5e76d
-DIST zsh-5.8.tar.xz 3193284 BLAKE2B b1186dd27aede3318763d7c42253e919e60d00a018d085b2de7e8d985c872e9756a3ce112f623a088ec0878abd7a38d04dfa5ec552ef0f0a72e623191a7ba5e3 SHA512 96198ecef498b7d7945fecebbe6bf14065fa8c5d81a7662164579eba8206b79575812d292adea1864bc7487ac0818ba900e25f9ab3802449340de80417c2c533
diff --git a/app-shells/zsh/files/zsh-5.7.1-ncurses_colors.patch b/app-shells/zsh/files/zsh-5.7.1-ncurses_colors.patch
deleted file mode 100644
index 3dc2a7d5a1af..000000000000
--- a/app-shells/zsh/files/zsh-5.7.1-ncurses_colors.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 7ce49801cc8ebc6f3a343ee5b829007f8cfb2bce Mon Sep 17 00:00:00 2001
-From: Lars Wendler <polynomial-c@gentoo.org>
-Date: Wed, 11 Dec 2019 14:56:25 +0100
-Subject: [PATCH] configure.ac: check for has_colors symbol in curses lib
-
-Otherwise zsh/curses module won't get built if ncurses was built with
-separate tinfo lib.
-One could still force-build the module but loading it later yields the
-following error message:
-
- failed to load module `zsh/curses': /usr/lib64/zsh/5.7.1/zsh/curses.so:
- undefined symbol: COLORS
-
-That is because the final linker call requires -lncurses(w) but it only
-contains -ltinfo(w).
-
-Reported-by: Tetja Rediske <tetja@tetja.de>
-Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>
----
- configure.ac | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/configure.ac b/configure.ac
-index 5513e25f1..792ad4db0 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -814,6 +814,7 @@ AC_SEARCH_LIBS(tgetent, [$termcap_curses_order],
- This is probably a library called 'curses' or 'ncurses'. You may
- need to install a package called 'curses-devel' or 'ncurses-devel' on your
- system."], 255))
-+AC_SEARCH_LIBS(has_colors, [$termcap_curses_order])
- AC_CHECK_HEADERS(curses.h, [],
- [AC_CACHE_CHECK(for Solaris 8 curses.h mistake, ac_cv_header_curses_solaris,
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <curses.h>]], [[]])],[ac_cv_header_curses_h=yes
---
-2.24.1
-
diff --git a/app-shells/zsh/zsh-5.8.ebuild b/app-shells/zsh/zsh-5.8.ebuild
deleted file mode 100644
index 3a3a006e2559..000000000000
--- a/app-shells/zsh/zsh-5.8.ebuild
+++ /dev/null
@@ -1,221 +0,0 @@
-# Copyright 1999-2021 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-inherit autotools flag-o-matic prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3
- EGIT_REPO_URI="https://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
- https://www.zsh.org/pub/old/${P}.tar.xz
- mirror://sourceforge/${PN}/${P}.tar.xz
- doc? (
- https://www.zsh.org/pub/${P}-doc.tar.xz
- mirror://sourceforge/${PN}/${P}-doc.tar.xz
- )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="https://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1:0=
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? (
- >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] )
- )
- gdbm? ( sys-libs/gdbm:= )
- !<sys-apps/baselayout-2.4.1
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == 9999* ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-PATCHES=(
- "${FILESDIR}/${PN}-5.7.1-ncurses_colors.patch"
-)
-
-src_prepare() {
- if [[ ${PV} != 9999* ]]; then
- # fix zshall problem with soelim
- ln -s Doc man1 || die
- mv Doc/zshall.1 Doc/zshall.1.soelim || die
- soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
-
- # add openrc specific options for init.d completion
- eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
- fi
-
- default
-
- hprefixify configure.ac
- if [[ ${PV} == 9999* ]] ; then
- sed -i "/^VERSION=/s/=.*/=${PV}/" Config/version.mk || die
- fi
- eautoreconf
-}
-
-src_configure() {
- local myconf=(
- --bindir="${EPREFIX}"/bin
- --libdir="${EPREFIX}"/usr/$(get_libdir)
- --enable-etcdir="${EPREFIX}"/etc/zsh
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
- --enable-function-subdirs
- --with-tcsetpgrp
- --with-term-lib="$(usex unicode 'tinfow ncursesw' 'tinfo ncurses')"
- $(use_enable maildir maildir-support)
- $(use_enable pcre)
- $(use_enable caps cap)
- $(use_enable unicode multibyte)
- $(use_enable gdbm)
- )
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == 9999* ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install $(usex doc "install.info" "")
-
- insinto /etc/zsh
- export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
- newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dodoc Doc/zsh.{dvi,pdf}
- docinto html
- dodoc Doc/*.html
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2022-04-13 8:08 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2022-04-13 8:08 UTC (permalink / raw
To: gentoo-commits
commit: 35dd4906505f729d68ead73d64c42f764ba858dc
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Wed Apr 13 08:06:51 2022 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Wed Apr 13 08:08:48 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=35dd4906
app-shells/zsh: Revbump to fix non-interactive shell regression
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
....8.1-non_interactive_shell_regression_fix.patch | 76 ++++++++++++++++++++++
.../zsh/{zsh-5.8.1.ebuild => zsh-5.8.1-r1.ebuild} | 4 ++
2 files changed, 80 insertions(+)
diff --git a/app-shells/zsh/files/zsh-5.8.1-non_interactive_shell_regression_fix.patch b/app-shells/zsh/files/zsh-5.8.1-non_interactive_shell_regression_fix.patch
new file mode 100644
index 000000000000..6e202fa2fb24
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.8.1-non_interactive_shell_regression_fix.patch
@@ -0,0 +1,76 @@
+From da8be06c2062ea02795bcba25172369ec68848cf Mon Sep 17 00:00:00 2001
+From: Peter Stephenson <p.w.stephenson@ntlworld.com>
+Date: Thu, 3 Mar 2022 19:19:35 +0000
+Subject: [PATCH] 49792: Non-interative shell input is line buffered.
+
+---
+ ChangeLog | 5 +++++
+ Src/input.c | 21 ++++++++++++++-------
+ Test/A01grammar.ztst | 9 +++++++++
+ 3 files changed, 28 insertions(+), 7 deletions(-)
+
+diff --git a/ChangeLog b/ChangeLog
+index 8a5ad4941..cae2fc4e3 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,8 @@
++2022-03-03 Peter Stephenson <p.w.stephenson@ntlworld.com>
++
++ * 49792: Src/input.c, Test/A01grammar.ztst: Use line buffering
++ for non-interactive input.
++
+ 2022-02-12 dana <dana@dana.is>
+
+ * unposted: Config/version.mk, Etc/FAQ.yo, README: Update
+diff --git a/Src/input.c b/Src/input.c
+index 18228b37d..caa8e23b0 100644
+--- a/Src/input.c
++++ b/Src/input.c
+@@ -223,13 +223,20 @@ shingetchar(void)
+ return STOUC(*shinbufptr++);
+
+ shinbufreset();
+- do {
+- errno = 0;
+- nread = read(SHIN, shinbuffer, SHINBUFSIZE);
+- } while (nread < 0 && errno == EINTR);
+- if (nread <= 0)
+- return -1;
+- shinbufendptr = shinbuffer + nread;
++ for (;;) {
++ errno = 0;
++ nread = read(SHIN, shinbufendptr, 1);
++ if (nread > 0) {
++ /* Use line buffering (POSIX requirement) */
++ if (*shinbufendptr++ == '\n')
++ break;
++ if (shinbufendptr == shinbuffer + SHINBUFSIZE)
++ break;
++ } else if (nread == 0 || errno != EINTR)
++ break;
++ }
++ if (shinbufendptr == shinbuffer)
++ return -1;
+ return STOUC(*shinbufptr++);
+ }
+
+diff --git a/Test/A01grammar.ztst b/Test/A01grammar.ztst
+index 1e0e9a04e..adbf5f1d9 100644
+--- a/Test/A01grammar.ztst
++++ b/Test/A01grammar.ztst
+@@ -932,3 +932,12 @@ F:Note that the behaviour of 'exit' inside try-list inside a function is unspeci
+ $ZTST_testdir/../Src/zsh -fc '{ ( ) } always { echo foo }'
+ -f:exec last command optimization inhibited for try/always
+ >foo
++
++ (
++ export VALUE=first
++ print -l 'echo Value is $VALUE' 'VALUE=second sh' 'echo Value is $VALUE' |
++ $ZTST_testdir/../Src/zsh -f
++ )
++0:Non-interactive shell command input is line buffered
++>Value is first
++>Value is second
+--
+2.36.0.rc2
+
diff --git a/app-shells/zsh/zsh-5.8.1.ebuild b/app-shells/zsh/zsh-5.8.1-r1.ebuild
similarity index 98%
rename from app-shells/zsh/zsh-5.8.1.ebuild
rename to app-shells/zsh/zsh-5.8.1-r1.ebuild
index e44079087473..6cbf8622fe20 100644
--- a/app-shells/zsh/zsh-5.8.1.ebuild
+++ b/app-shells/zsh/zsh-5.8.1-r1.ebuild
@@ -51,6 +51,10 @@ if [[ ${PV} == *9999 ]] ; then
)"
fi
+PATCHES=(
+ "${FILESDIR}/${P}-non_interactive_shell_regression_fix.patch"
+)
+
src_prepare() {
if [[ ${PV} != *9999 ]]; then
# fix zshall problem with soelim
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2022-05-02 8:41 Lars Wendler
0 siblings, 0 replies; 15+ messages in thread
From: Lars Wendler @ 2022-05-02 8:41 UTC (permalink / raw
To: gentoo-commits
commit: d6d64f8fa58bae8d750bade521d5354507c9c483
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Mon May 2 08:36:59 2022 +0000
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Mon May 2 08:41:43 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d6d64f8f
app-shells/zsh: Revbump to fix performance regression
which was introduced with previous regression fix.
Closes: https://bugs.gentoo.org/839900
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>
.../zsh-5.8.1-performance_regression_fix.patch | 139 +++++++++++++++++++++
.../{zsh-5.8.1-r1.ebuild => zsh-5.8.1-r2.ebuild} | 1 +
2 files changed, 140 insertions(+)
diff --git a/app-shells/zsh/files/zsh-5.8.1-performance_regression_fix.patch b/app-shells/zsh/files/zsh-5.8.1-performance_regression_fix.patch
new file mode 100644
index 000000000000..14a3f38eb96d
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.8.1-performance_regression_fix.patch
@@ -0,0 +1,139 @@
+From cbe8d2bcdc20682464217856aa48628804637f28 Mon Sep 17 00:00:00 2001
+From: Bart Schaefer <schaefer@zsh.org>
+Date: Thu, 28 Apr 2022 21:06:51 -0700
+Subject: [PATCH] 50133: use read-ahead and lseek-rewind for efficient
+ line-buffered input
+
+---
+ ChangeLog | 6 ++++++
+ Src/input.c | 24 ++++++++++++++++++++-
+ configure.ac | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++
+ 3 files changed, 88 insertions(+), 1 deletion(-)
+
+diff --git a/ChangeLog b/ChangeLog
+index cae2fc4e3..79c77741b 100644
+--- a/ChangeLog
++++ b/ChangeLog
+@@ -1,3 +1,9 @@
++2022-04-28 Bart Schaefer <schaefer@zsh.org>
++
++ * 50133 (Bart, PWS, Jun-ichi): Src/input.c, configure.ac: when
++ lseek(2) is available, use it to check for and rewind read-ahead
++ for more efficient line-buffered input.
++
+ 2022-03-03 Peter Stephenson <p.w.stephenson@ntlworld.com>
+
+ * 49792: Src/input.c, Test/A01grammar.ztst: Use line buffering
+diff --git a/Src/input.c b/Src/input.c
+index caa8e23b0..6cc1b8a51 100644
+--- a/Src/input.c
++++ b/Src/input.c
+@@ -217,12 +217,34 @@ shinbufrestore(void)
+ static int
+ shingetchar(void)
+ {
+- int nread;
++ int nread, rsize = isset(SHINSTDIN) ? 1 : SHINBUFSIZE;
+
+ if (shinbufptr < shinbufendptr)
+ return STOUC(*shinbufptr++);
+
+ shinbufreset();
++#ifdef USE_LSEEK
++ if (rsize == 1 && lseek(SHIN, 0, SEEK_CUR) != (off_t)-1)
++ rsize = SHINBUFSIZE;
++ if (rsize > 1) {
++ do {
++ errno = 0;
++ nread = read(SHIN, shinbuffer, rsize);
++ } while (nread < 0 && errno == EINTR);
++ if (nread <= 0)
++ return -1;
++ if (isset(SHINSTDIN) &&
++ (shinbufendptr = memchr(shinbuffer, '\n', nread))) {
++ shinbufendptr++;
++ rsize = (shinbufendptr - shinbuffer);
++ if (nread > rsize &&
++ lseek(SHIN, -(nread - rsize), SEEK_CUR) < 0)
++ zerr("lseek(%d, %d): %e", SHIN, -(nread - rsize), errno);
++ } else
++ shinbufendptr = shinbuffer + nread;
++ return STOUC(*shinbufptr++);
++ }
++#endif
+ for (;;) {
+ errno = 0;
+ nread = read(SHIN, shinbufendptr, 1);
+diff --git a/configure.ac b/configure.ac
+index af8c5bba8..42f2837cd 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -2304,6 +2304,65 @@ if test x$zsh_cv_sys_fifo = xyes; then
+ AC_DEFINE(HAVE_FIFOS)
+ fi
+
++dnl -----------
++dnl check that lseek() correctly reports seekability.
++dnl -----------
++AC_CACHE_CHECK(if lseek() correctly reports seekability,
++zsh_cv_sys_lseek,
++[AC_RUN_IFELSE([AC_LANG_SOURCE([[
++#include <stdio.h>
++#include <sys/types.h>
++#include <fcntl.h>
++#include <unistd.h>
++#include <sys/socket.h>
++#include <sys/stat.h>
++int main() {
++ int pipefd[2], fd;
++ off_t ret;
++ char* tmpfile = "seekfiletest.tmp";
++ if ((fd = open(tmpfile, O_CREAT, S_IRUSR)) < 0) {
++ fprintf(stderr, "creating file failed\n");
++ return 1;
++ }
++ ret = lseek(fd, 0, SEEK_CUR);
++ close(fd);
++ unlink(tmpfile);
++ if (ret == (off_t)-1) {
++ fprintf(stderr, "lseek on regular file failed\n");
++ return 1;
++ }
++ if (pipe(pipefd) < 0) {
++ fprintf(stderr, "creating pipe failed\n");
++ return 1;
++ }
++ write(pipefd[1], "abcdefgh", 8);
++ ret = lseek(pipefd[0], 0, SEEK_CUR);
++ close(pipefd[0]);
++ close(pipefd[1]);
++ if (ret != (off_t)-1) {
++ fprintf(stderr, "lseek on pipe succeeded\n");
++ return 1;
++ }
++ if ((fd = socket(AF_UNIX, SOCK_STREAM, 0)) < 0) {
++ fprintf(stderr, "creating UNIX domain socket failed\n");
++ return 1;
++ }
++ ret = lseek(fd, 0, SEEK_CUR);
++ close(fd);
++ if (ret != (off_t)-1) {
++ fprintf(stderr, "lseek on UNIX domain socket succeeded\n");
++ return 1;
++ }
++ return 0;
++}
++]])],[zsh_cv_sys_lseek=yes],[zsh_cv_sys_lseek=no],[zsh_cv_sys_lseek=yes])
++])
++AH_TEMPLATE([USE_LSEEK],
++[Define to 1 if lseek() can be used for SHIN.])
++if test x$zsh_cv_sys_lseek = xyes; then
++ AC_DEFINE(USE_LSEEK)
++fi
++
+ dnl -----------
+ dnl test for whether link() works
+ dnl for instance, BeOS R4.51 doesn't support hard links yet
+--
+2.36.0
+
diff --git a/app-shells/zsh/zsh-5.8.1-r1.ebuild b/app-shells/zsh/zsh-5.8.1-r2.ebuild
similarity index 98%
rename from app-shells/zsh/zsh-5.8.1-r1.ebuild
rename to app-shells/zsh/zsh-5.8.1-r2.ebuild
index 6cbf8622fe20..dbb80d5ae6d8 100644
--- a/app-shells/zsh/zsh-5.8.1-r1.ebuild
+++ b/app-shells/zsh/zsh-5.8.1-r2.ebuild
@@ -53,6 +53,7 @@ fi
PATCHES=(
"${FILESDIR}/${P}-non_interactive_shell_regression_fix.patch"
+ "${FILESDIR}/${P}-performance_regression_fix.patch" #839900
)
src_prepare() {
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2022-09-01 2:06 Sam James
0 siblings, 0 replies; 15+ messages in thread
From: Sam James @ 2022-09-01 2:06 UTC (permalink / raw
To: gentoo-commits
commit: d12d15fee1604f729ea93a3401cbb25ee41c9897
Author: brahmajit das <listout <AT> protonmail <DOT> com>
AuthorDate: Fri Aug 26 19:53:14 2022 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Thu Sep 1 02:06:00 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d12d15fe
app-shells/zsh: Fix failing tests on musl
On musl the tests A03quoting.ztst, B03print.ztst, V09datetime.ztst, and
E02xtrace.ztst were failing. This commit fixes all four (E02xtrace is
removed for musl) of them.
Closes: https://bugs.gentoo.org/833981
Signed-off-by: brahmajit das <listout <AT> protonmail.com>
Signed-off-by: brahmajit das <listout <AT> protonmail.com>
Closes: https://github.com/gentoo/gentoo/pull/27019
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../files/zsh-5.9-musl-V09datetime-test-fix.patch | 15 ++++++++++++++
app-shells/zsh/zsh-5.9.ebuild | 23 +++++++++++++++++++---
2 files changed, 35 insertions(+), 3 deletions(-)
diff --git a/app-shells/zsh/files/zsh-5.9-musl-V09datetime-test-fix.patch b/app-shells/zsh/files/zsh-5.9-musl-V09datetime-test-fix.patch
new file mode 100644
index 000000000000..6f9fa4458a29
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.9-musl-V09datetime-test-fix.patch
@@ -0,0 +1,15 @@
+# On musl strftime '%@' returns new line, so we include to check for that too
+# Closes: https://bugs.gentoo.org/833981
+--- a/Test/V09datetime.ztst
++++ b/Test/V09datetime.ztst
+@@ -79,8 +79,8 @@
+ >1973^@03^@03
+
+ # We assume '%@' is not a valid format on any OSs.
+-# The result can be '%@' (Linux), '@' (BSDs) or an error (Cygwin).
+- [[ $(strftime '%@' 0 2> /dev/null) == (%|)@ || $? != 0 ]]
++# The result can be '%@' (Linux), '\n' (Linux with musl libc) '@', (BSDs) or an error (Cygwin).
++ [[ $(strftime '%@' 0 2> /dev/null) == (%|)@ || $? != 0 || $'\n' ]]
+ 0:bad format specifier
+
+ # This test may fail at 23:59:59.xxx on New Year's Eve :/
diff --git a/app-shells/zsh/zsh-5.9.ebuild b/app-shells/zsh/zsh-5.9.ebuild
index a2940a5c435e..9cfcc3a75650 100644
--- a/app-shells/zsh/zsh-5.9.ebuild
+++ b/app-shells/zsh/zsh-5.9.ebuild
@@ -50,6 +50,13 @@ if [[ ${PV} == *9999 ]] ; then
)"
fi
+PATCHES=(
+ # add openrc specific options for init.d completion
+ "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
+ # Please refer gentoo bug 833981
+ "${FILESDIR}"/${PN}-5.9-musl-V09datetime-test-fix.patch
+)
+
src_prepare() {
if [[ ${PV} != *9999 ]]; then
# fix zshall problem with soelim
@@ -58,9 +65,6 @@ src_prepare() {
soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
fi
- # add openrc specific options for init.d completion
- eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
-
default
hprefixify configure.ac
@@ -132,6 +136,19 @@ src_compile() {
}
src_test() {
+ # Fixes tests A03quoting.ztst B03print.ztst on musl
+ # Please refer:
+ # https://www.zsh.org/mla/workers/2021/msg00805.html
+ # Test E02xtrace fails on musl, so we are removing it.
+ # Closes: https://bugs.gentoo.org/833981
+ if use elibc_musl ; then
+ unset LC_ALL
+ unset LC_COLLATE
+ unset LC_NUMERIC
+ unset LC_MESSAGES
+ unset LANG
+ rm "${S}"/Test/E02xtrace.ztst || die
+ fi
addpredict /dev/ptmx
local i
for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2022-09-12 20:08 Sam James
0 siblings, 0 replies; 15+ messages in thread
From: Sam James @ 2022-09-12 20:08 UTC (permalink / raw
To: gentoo-commits
commit: 892dc0afaf0436e59259fec155f76ba4af9b6b06
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Mon Sep 12 20:07:51 2022 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Mon Sep 12 20:08:13 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=892dc0af
app-shells/zsh: fix configure tests with Clang 15
Note that in some cases, this may have caused either some
files to not be installed, or hangs at runtime.
Closes: https://bugs.gentoo.org/869539
Thanks-to: Nicholas Vinson <nvinson234 <AT> gmail.com>
Signed-off-by: Sam James <sam <AT> gentoo.org>
.../zsh/files/zsh-5.9-clang-15-configure.patch | 549 +++++++++++++++++++++
app-shells/zsh/zsh-5.9-r1.ebuild | 235 +++++++++
2 files changed, 784 insertions(+)
diff --git a/app-shells/zsh/files/zsh-5.9-clang-15-configure.patch b/app-shells/zsh/files/zsh-5.9-clang-15-configure.patch
new file mode 100644
index 000000000000..8a77e365c700
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.9-clang-15-configure.patch
@@ -0,0 +1,549 @@
+https://bugs.gentoo.org/869539
+--- a/configure.ac
++++ b/configure.ac
+@@ -583,11 +583,11 @@ if test x$zsh_cv_c_have_union_init = xye
+ fi
+
+ dnl Checking if compiler correctly cast signed to unsigned.
+ AC_CACHE_CHECK(if signed to unsigned casting is broken,
+ zsh_cv_c_broken_signed_to_unsigned_casting,
+-[AC_RUN_IFELSE([AC_LANG_SOURCE([[main(){return((int)(unsigned char)((char) -1) == 255);}]])],[zsh_cv_c_broken_signed_to_unsigned_casting=yes],[zsh_cv_c_broken_signed_to_unsigned_casting=no],[zsh_cv_c_broken_signed_to_unsigned_casting=no])])
++[AC_RUN_IFELSE([AC_LANG_SOURCE([[int main(){return((int)(unsigned char)((char) -1) == 255);}]])],[zsh_cv_c_broken_signed_to_unsigned_casting=yes],[zsh_cv_c_broken_signed_to_unsigned_casting=no],[zsh_cv_c_broken_signed_to_unsigned_casting=no])])
+ AH_TEMPLATE([BROKEN_SIGNED_TO_UNSIGNED_CASTING],
+ [Define to 1 if compiler incorrectly cast signed to unsigned.])
+ if test x$zsh_cv_c_broken_signed_to_unsigned_casting = xyes; then
+ AC_DEFINE(BROKEN_SIGNED_TO_UNSIGNED_CASTING)
+ fi
+@@ -1044,21 +1044,21 @@ if test x$zsh_cv_long_is_64_bit = xyes;
+ else
+ AC_CACHE_CHECK(if off_t is 64 bit, zsh_cv_off_t_is_64_bit,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <sys/types.h>
+
+-main() { return sizeof(off_t) < 8; }
++int main() { return sizeof(off_t) < 8; }
+ ]])],[zsh_cv_off_t_is_64_bit=yes],[zsh_cv_off_t_is_64_bit=no],[zsh_cv_off_t_is_64_bit=no])])
+ if test x$zsh_cv_off_t_is_64_bit = xyes; then
+ AC_DEFINE(OFF_T_IS_64_BIT)
+ fi
+
+ AC_CACHE_CHECK(if ino_t is 64 bit, zsh_cv_ino_t_is_64_bit,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <sys/types.h>
+
+-main() { return sizeof(ino_t) < 8; }
++int main() { return sizeof(ino_t) < 8; }
+ ]])],[zsh_cv_ino_t_is_64_bit=yes],[zsh_cv_ino_t_is_64_bit=no],[zsh_cv_ino_t_is_64_bit=no])])
+ if test x$zsh_cv_ino_t_is_64_bit = xyes; then
+ AC_DEFINE(INO_T_IS_64_BIT)
+ fi
+
+@@ -1394,22 +1394,22 @@ zsh_cv_func_tgetent_accepts_null,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <fcntl.h>
+ #include <stdlib.h>
+ int tgetent(char *, char *);
+ char *tgetstr(char *, char **);
+-main()
++int main()
+ {
+ char buf[4096];
+ int r1 = tgetent(buf, "vt100");
+ int r2 = tgetent((char*)0,"vt100");
+ if (r1 >= 0 && r1 == r2) {
+ char tbuf[1024], *u;
+ u = tbuf;
+ tgetstr("cl", &u);
+ creat("conftest.tgetent", 0640);
+ }
+- exit((r1 != r2) || r2 == -1);
++ return((r1 != r2) || r2 == -1);
+ }
+ ]])],[if test -f conftest.tgetent; then
+ zsh_cv_func_tgetent_accepts_null=yes
+ else
+ zsh_cv_func_tgetent_accepts_null=no
+@@ -1422,22 +1422,22 @@ zsh_cv_func_tgetent_zero_success,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <fcntl.h>
+ #include <stdlib.h>
+ int tgetent(char *, char*);
+ char *tgetstr(char *, char **);
+-main()
++int main()
+ {
+ char buf[4096];
+ int r1 = tgetent(buf, "!@#$%^&*");
+ int r2 = tgetent(buf, "vt100");
+ if (r1 < 0 && r2 == 0) {
+ char tbuf[1024], *u;
+ u = tbuf;
+ tgetstr("cl", &u);
+ creat("conftest.tgetent0", 0640);
+ }
+- exit(r1 == r2);
++ return(r1 == r2);
+ }
+ ]])],[if test -f conftest.tgetent0; then
+ zsh_cv_func_tgetent_zero_success=yes
+ else
+ zsh_cv_func_tgetent_zero_success=no
+@@ -1860,27 +1860,27 @@ zsh_cv_rlim_t_is_longer,
+ #ifdef HAVE_SYS_TIME_H
+ #include <sys/time.h>
+ #endif
+ #include <sys/resource.h>
+ #include <stdlib.h>
+-main(){struct rlimit r;exit(sizeof(r.rlim_cur) <= sizeof(long));}]])],[zsh_cv_rlim_t_is_longer=yes],[zsh_cv_rlim_t_is_longer=no],[zsh_cv_rlim_t_is_longer=yes])])
++int main(){struct rlimit r;return(sizeof(r.rlim_cur) <= sizeof(long));}]])],[zsh_cv_rlim_t_is_longer=yes],[zsh_cv_rlim_t_is_longer=no],[zsh_cv_rlim_t_is_longer=yes])])
+ if test x$zsh_cv_rlim_t_is_longer = xyes; then
+ AC_CACHE_CHECK(if rlim_t is a quad,
+ zsh_cv_rlim_t_is_quad_t,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #ifdef HAVE_SYS_TIME_H
+ #include <sys/time.h>
+ #endif
+ #include <stdio.h>
+ #include <sys/resource.h>
+ #include <stdlib.h>
+-main() {
++int main() {
+ struct rlimit r;
+ char buf[20];
+ r.rlim_cur = 0;
+ sprintf(buf, "%qd", r.rlim_cur);
+- exit(strcmp(buf, "0"));
++ return(strcmp(buf, "0"));
+ }]])],[zsh_cv_rlim_t_is_quad_t=yes],[zsh_cv_rlim_t_is_quad_t=no],[zsh_cv_rlim_t_is_quad_t=no])])
+ if test x$zsh_cv_rlim_t_is_quad_t = xyes; then
+ AC_DEFINE(RLIM_T_IS_QUAD_T)
+ DEFAULT_RLIM_T=quad_t
+ else
+@@ -1894,11 +1894,11 @@ else
+ #ifdef HAVE_SYS_TIME_H
+ #include <sys/time.h>
+ #endif
+ #include <sys/resource.h>
+ #include <stdlib.h>
+- main(){struct rlimit r;r.rlim_cur=-1;exit(r.rlim_cur<0);}]])],[zsh_cv_type_rlim_t_is_unsigned=yes],[zsh_cv_type_rlim_t_is_unsigned=no],[zsh_cv_type_rlim_t_is_unsigned=no])])
++ int main(){struct rlimit r;r.rlim_cur=-1;return(r.rlim_cur<0);}]])],[zsh_cv_type_rlim_t_is_unsigned=yes],[zsh_cv_type_rlim_t_is_unsigned=no],[zsh_cv_type_rlim_t_is_unsigned=no])])
+ if test x$zsh_cv_type_rlim_t_is_unsigned = xyes; then
+ AC_DEFINE(RLIM_T_IS_UNSIGNED)
+ DEFAULT_RLIM_T="unsigned $DEFAULT_RLIM_T"
+ fi
+ fi
+@@ -2175,11 +2175,11 @@ zsh_cv_sys_fifo,
+ #include <fcntl.h>
+ #include <signal.h>
+ #include <unistd.h>
+ #include <stdlib.h>
+ #include <sys/stat.h>
+-main()
++int main()
+ {
+ char c;
+ int fd;
+ int pid, ret;
+ unlink("/tmp/fifo$$");
+@@ -2189,19 +2189,19 @@ main()
+ if(mknod("/tmp/fifo$$", 0010600, 0) < 0)
+ #endif
+ exit(1);
+ pid = fork();
+ if(pid < 0)
+- exit(1);
++ return(1);
+ if(pid) {
+ fd = open("/tmp/fifo$$", O_RDONLY);
+- exit(fd < 0 || read(fd, &c, 1) != 1 || c != 'x');
++ return(fd < 0 || read(fd, &c, 1) != 1 || c != 'x');
+ }
+ fd = open("/tmp/fifo$$", O_WRONLY);
+ ret = (fd < 0 || write(fd, "x", 1) < 1);
+ unlink("/tmp/fifo$$");
+- exit(ret);
++ return(ret);
+ }
+ ]])],[zsh_cv_sys_fifo=yes],[zsh_cv_sys_fifo=no],[zsh_cv_sys_fifo=yes])
+ ])
+ AH_TEMPLATE([HAVE_FIFOS],
+ [Define to 1 if system has working FIFOs.])
+@@ -2276,24 +2276,24 @@ AC_CACHE_CHECK(if link() works,
+ zsh_cv_sys_link,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <unistd.h>
+ #include <fcntl.h>
+ #include <stdlib.h>
+-main()
++int main()
+ {
+ int ret;
+ char *tmpfile, *newfile;
+ tmpfile="/tmp/zsh.linktest$$";
+ newfile="/tmp/zsh.linktest2$$";
+ unlink(tmpfile);
+ unlink(newfile);
+ if(creat(tmpfile, 0644) < 0)
+- exit(1);
++ return(1);
+ ret = link(tmpfile, newfile);
+ unlink(tmpfile);
+ unlink(newfile);
+- exit(ret<0);
++ return(ret<0);
+ }
+ ]])],[zsh_cv_sys_link=yes],[zsh_cv_sys_link=no],[zsh_cv_sys_link=yes])])
+ AH_TEMPLATE([HAVE_LINK],
+ [Define to 1 if system has working link().])
+ if test x$zsh_cv_sys_link = xyes; then
+@@ -2309,15 +2309,15 @@ zsh_cv_sys_killesrch,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <unistd.h>
+ #include <signal.h>
+ #include <errno.h>
+ #include <stdlib.h>
+-main()
++int main()
+ {
+ int pid = (getpid() + 10000) & 0xffffff;
+ while (pid && (kill(pid, 0) == 0 || errno != ESRCH)) pid >>= 1;
+- exit(errno!=ESRCH);
++ return(errno!=ESRCH);
+ }
+ ]])],[zsh_cv_sys_killesrch=yes],[zsh_cv_sys_killesrch=no],[zsh_cv_sys_killesrch=yes])])
+ AH_TEMPLATE([BROKEN_KILL_ESRCH],
+ [Define to 1 if kill(pid, 0) doesn't return ESRCH, ie BeOS R4.51.])
+ if test x$zsh_cv_sys_killesrch = xno; then
+@@ -2339,11 +2339,11 @@ if test x$signals_style = xPOSIX_SIGNALS
+ #include <stdlib.h>
+ int child=0;
+ void handler(sig)
+ int sig;
+ {if(sig==SIGCHLD) child=1;}
+-main() {
++int main() {
+ struct sigaction act;
+ sigset_t set;
+ int pid, ret;
+ act.sa_handler = &handler;
+ sigfillset(&act.sa_mask);
+@@ -2354,11 +2354,11 @@ main() {
+ pid=fork();
+ if(pid==0) return 0;
+ if(pid>0) {
+ sigemptyset(&set);
+ ret=sigsuspend(&set);
+- exit(child==0);
++ return(child==0);
+ }
+ }
+ ]])],[zsh_cv_sys_sigsuspend=yes],[zsh_cv_sys_sigsuspend=no],[zsh_cv_sys_sigsuspend=yes])])
+ if test x$zsh_cv_sys_sigsuspend = xno; then
+ AC_DEFINE(BROKEN_POSIX_SIGSUSPEND)
+@@ -2387,18 +2387,18 @@ case "x$zsh_working_tcsetpgrp" in
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <sys/types.h>
+ #include <unistd.h>
+ #include <fcntl.h>
+ #include <stdlib.h>
+-main() {
++int main() {
+ int fd;
+ int ret;
+ fd=open("/dev/tty", O_RDWR);
+ if (fd < 0) exit(2);
+ ret=tcsetpgrp(fd, tcgetpgrp(fd));
+ if (ret < 0) exit(1);
+- exit(0);
++ return(0);
+ }
+ ]])],[zsh_cv_sys_tcsetpgrp=yes],[
+ case $? in
+ 1) zsh_cv_sys_tcsetpgrp=no;;
+ 2) zsh_cv_sys_tcsetpgrp=notty;;
+@@ -2434,19 +2434,19 @@ if test x$ac_cv_func_getpwnam = xyes; th
+ #include <pwd.h>
+ #include <stdio.h>
+ #include <string.h>
+ #include <stdlib.h>
+ #include <unistd.h>
+-main() {
++int main() {
+ struct passwd *pw1, *pw2;
+ char buf[1024], name[1024];
+ sprintf(buf, "%d:%d", getpid(), rand());
+ pw1=getpwnam(buf);
+ if (pw1) strcpy(name, pw1->pw_name);
+ sprintf(buf, "%d:%d", rand(), getpid());
+ pw2=getpwnam(buf);
+- exit(pw1!=0 && pw2!=0 && !strcmp(name, pw2->pw_name));
++ return(pw1!=0 && pw2!=0 && !strcmp(name, pw2->pw_name));
+ }
+ ]])],[zsh_cv_sys_getpwnam_faked=no],[zsh_cv_sys_getpwnam_faked=yes],[zsh_cv_sys_getpwnam_faked=no])])
+ if test x$zsh_cv_sys_getpwnam_faked = xyes; then
+ AC_DEFINE(GETPWNAM_FAKED)
+ fi
+@@ -2763,22 +2763,20 @@ elif test "x$dynamic" = xyes; then
+ zsh_cv_sys_elf,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[/* Test for whether ELF binaries are produced */
+ #include <fcntl.h>
+ #include <stdlib.h>
+ #include <unistd.h>
+-main(argc, argv)
+-int argc;
+-char *argv[];
++int main(int argc, char *argv[])
+ {
+ char b[4];
+ int i = open(argv[0],O_RDONLY);
+ if(i == -1)
+ exit(1); /* fail */
+ if(read(i,b,4)==4 && b[0]==127 && b[1]=='E' && b[2]=='L' && b[3]=='F')
+- exit(0); /* succeed (yes, it's ELF) */
++ return(0); /* succeed (yes, it's ELF) */
+ else
+- exit(1); /* fail */
++ return(1); /* fail */
+ }]])],[zsh_cv_sys_elf=yes],[zsh_cv_sys_elf=no],[zsh_cv_sys_elf=yes])])
+
+ # We use [0-9]* in case statements, so need to change quoting
+ changequote(, )
+
+@@ -2908,11 +2908,11 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM([[]], [[
+ EXTRA_LDFLAGS="${EXTRA_LDFLAGS=-rdynamic}"],[zsh_cvs_rdynamic_available=no])
+ LDFLAGS="$old_LDFLAGS")
+ AC_CACHE_CHECK(if your dlsym() needs a leading underscore,
+ zsh_cv_func_dlsym_needs_underscore,
+ [echo failed >conftestval && cat >conftest.c <<EOM
+-fred () { }
++void fred () { }
+ EOM
+ AC_TRY_COMMAND($CC -c $CFLAGS $CPPFLAGS $DLCFLAGS conftest.c 1>&AS_MESSAGE_LOG_FD) &&
+ AC_TRY_COMMAND($DLLD $LDFLAGS $DLLDFLAGS -o conftest.$DL_EXT conftest.o 1>&AS_MESSAGE_LOG_FD) &&
+ AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #include <stdio.h>
+@@ -2943,34 +2941,34 @@ char *zsh_gl_sym_addr ;
+ #define RTLD_LAZY 1
+ #endif
+
+ extern int fred() ;
+
+-main()
++int main()
+ {
+ void * handle ;
+ void * symbol ;
+ FILE *f=fopen("conftestval", "w");
+ if (!f) exit(1);
+ handle = dlopen("./conftest.$DL_EXT", RTLD_LAZY) ;
+ if (handle == NULL) {
+ fprintf (f, "dlopen failed") ;
+- exit(1);
++ return(1);
+ }
+ symbol = dlsym(handle, "fred") ;
+ if (symbol == NULL) {
+ /* try putting a leading underscore */
+ symbol = dlsym(handle, "_fred") ;
+ if (symbol == NULL) {
+ fprintf (f, "dlsym failed") ;
+- exit(1);
++ return(1);
+ }
+ fprintf (f, "yes") ;
+ }
+ else
+ fprintf (f, "no") ;
+- exit(0);
++ return(0);
+ }]])],[zsh_cv_func_dlsym_needs_underscore=`cat conftestval`],[zsh_cv_func_dlsym_needs_underscore=failed
+ dynamic=no],[zsh_cv_func_dlsym_needs_underscore=no])])
+ if test "x$zsh_cv_func_dlsym_needs_underscore" = xyes; then
+ AC_DEFINE(DLSYM_NEEDS_UNDERSCORE)
+ elif test "x$zsh_cv_func_dlsym_needs_underscore" != xno; then
+--- a/aczsh.m4.old
++++ b/aczsh.m4
+@@ -42,10 +42,11 @@ AC_DEFUN(zsh_64_BIT_TYPE,
+ [AC_RUN_IFELSE([AC_LANG_SOURCE([[
+ #ifdef HAVE_SYS_TYPES_H
+ #include <sys/types.h>
+ #endif
+
++int
+ main()
+ {
+ $1 foo = 0;
+ int bar = (int) foo;
+ return sizeof($1) != 8;
+@@ -144,33 +145,34 @@ char *zsh_gl_sym_addr ;
+ #endif
+ #ifndef RTLD_GLOBAL
+ #define RTLD_GLOBAL 0
+ #endif
+
++int
+ main()
+ {
+ void *handle1, *handle2;
+ void *(*zsh_getaddr1)(), *(*zsh_getaddr2)();
+ void *sym1, *sym2;
+ handle1 = dlopen("./conftest1.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle1) exit(1);
++ if(!handle1) return(1);
+ handle2 = dlopen("./conftest2.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle2) exit(1);
++ if(!handle2) return(1);
+ zsh_getaddr1 = (void *(*)()) dlsym(handle1, "${us}zsh_getaddr1");
+ zsh_getaddr2 = (void *(*)()) dlsym(handle2, "${us}zsh_getaddr2");
+ sym1 = zsh_getaddr1();
+ sym2 = zsh_getaddr2();
+- if(!sym1 || !sym2) exit(1);
+- if(sym1 != sym2) exit(1);
++ if(!sym1 || !sym2) return(1);
++ if(sym1 != sym2) return(1);
+ dlclose(handle1);
+ handle1 = dlopen("./conftest1.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle1) exit(1);
++ if(!handle1) return(1);
+ zsh_getaddr1 = (void *(*)()) dlsym(handle1, "${us}zsh_getaddr1");
+ sym1 = zsh_getaddr1();
+- if(!sym1) exit(1);
+- if(sym1 != sym2) exit(1);
+- exit(0);
++ if(!sym1) return(1);
++ if(sym1 != sym2) return(1);
++ return(0);
+ }
+ ]])],[zsh_cv_shared_$1=yes],
+ [zsh_cv_shared_$1=no],
+ [zsh_cv_shared_$1=no]
+ )
+@@ -226,23 +228,23 @@ char *zsh_gl_sym_addr ;
+ #endif
+ #ifndef RTLD_GLOBAL
+ #define RTLD_GLOBAL 0
+ #endif
+
+-
++int
+ main()
+ {
+ void *handle1, *handle2;
+ int (*fred1)(), (*fred2)();
+ handle1 = dlopen("./conftest1.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle1) exit(1);
++ if(!handle1) return(1);
+ handle2 = dlopen("./conftest2.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle2) exit(1);
++ if(!handle2) return(1);
+ fred1 = (int (*)()) dlsym(handle1, "${us}fred");
+ fred2 = (int (*)()) dlsym(handle2, "${us}fred");
+- if(!fred1 || !fred2) exit(1);
+- exit((*fred1)() != 42 || (*fred2)() != 69);
++ if(!fred1 || !fred2) return(1);
++ return((*fred1)() != 42 || (*fred2)() != 69);
+ }
+ ]])],[zsh_cv_sys_dynamic_clash_ok=yes],
+ [zsh_cv_sys_dynamic_clash_ok=no],
+ [zsh_cv_sys_dynamic_clash_ok=no]
+ )
+@@ -302,21 +304,22 @@ char *zsh_gl_sym_addr ;
+ #endif
+ #ifndef RTLD_GLOBAL
+ #define RTLD_GLOBAL 0
+ #endif
+
++int
+ main()
+ {
+ void *handle;
+ int (*barneysym)();
+ handle = dlopen("./conftest1.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle) exit(1);
++ if(!handle) return(1);
+ handle = dlopen("./conftest2.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle) exit(1);
++ if(!handle) return(1);
+ barneysym = (int (*)()) dlsym(handle, "${us}barney");
+- if(!barneysym) exit(1);
+- exit((*barneysym)() != 69);
++ if(!barneysym) return(1);
++ return((*barneysym)() != 69);
+ }
+ ]])],[zsh_cv_sys_dynamic_rtld_global=yes],
+ [zsh_cv_sys_dynamic_rtld_global=no],
+ [zsh_cv_sys_dynamic_rtld_global=no]
+ )
+@@ -372,19 +375,20 @@ char *zsh_gl_sym_addr ;
+ #endif
+ #ifndef RTLD_GLOBAL
+ #define RTLD_GLOBAL 0
+ #endif
+
++int
+ main()
+ {
+ void *handle;
+ int (*barneysym)();
+ handle = dlopen("./conftest1.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle) exit(1);
++ if(!handle) return(1);
+ barneysym = (int (*)()) dlsym(handle, "${us}barney");
+- if(!barneysym) exit(1);
+- exit((*barneysym)() != 69);
++ if(!barneysym) return(1);
++ return((*barneysym)() != 69);
+ }
+
+ int fred () { return 42; }
+ ]])],[zsh_cv_sys_dynamic_execsyms=yes],
+ [zsh_cv_sys_dynamic_execsyms=no],
+@@ -446,19 +450,20 @@ char *zsh_gl_sym_addr ;
+ #endif
+ #ifndef RTLD_GLOBAL
+ #define RTLD_GLOBAL 0
+ #endif
+
++int
+ main()
+ {
+ void *handle;
+ int (*barneysym)();
+ handle = dlopen("./conftest1.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle) exit(1);
++ if(!handle) return(1);
+ barneysym = (int (*)()) dlsym(handle, "${us}barney");
+- if(!barneysym) exit(1);
+- exit((*barneysym)() != 69);
++ if(!barneysym) return(1);
++ return((*barneysym)() != 69);
+ }
+
+ int fred () { return 42; }
+ ]])],[zsh_cv_sys_dynamic_strip_exe=yes],
+ [zsh_cv_sys_dynamic_strip_exe=no],
+@@ -514,19 +519,20 @@ char *zsh_gl_sym_addr ;
+ #endif
+ #ifndef RTLD_GLOBAL
+ #define RTLD_GLOBAL 0
+ #endif
+
++int
+ main()
+ {
+ void *handle;
+ int (*fredsym)();
+ handle = dlopen("./conftest1.$DL_EXT", RTLD_LAZY | RTLD_GLOBAL);
+- if(!handle) exit(1);
++ if(!handle) return(1);
+ fredsym = (int (*)()) dlsym(handle, "${us}fred");
+- if(!fredsym) exit(1);
+- exit((*fredsym)() != 42);
++ if(!fredsym) return(1);
++ return((*fredsym)() != 42);
+ }
+ ]])],[zsh_cv_sys_dynamic_strip_lib=yes],
+ [zsh_cv_sys_dynamic_strip_lib=no],
+ [zsh_cv_sys_dynamic_strip_lib=no]
+ )
+
diff --git a/app-shells/zsh/zsh-5.9-r1.ebuild b/app-shells/zsh/zsh-5.9-r1.ebuild
new file mode 100644
index 000000000000..2ce37dce147c
--- /dev/null
+++ b/app-shells/zsh/zsh-5.9-r1.ebuild
@@ -0,0 +1,235 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools flag-o-matic prefix
+
+if [[ ${PV} == 9999* ]] ; then
+ inherit git-r3
+ EGIT_REPO_URI="https://git.code.sf.net/p/zsh/code"
+else
+ KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+ SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
+ https://www.zsh.org/pub/old/${P}.tar.xz
+ mirror://sourceforge/${PN}/${P}.tar.xz
+ doc? (
+ https://www.zsh.org/pub/${P}-doc.tar.xz
+ mirror://sourceforge/${PN}/${P}-doc.tar.xz
+ )"
+fi
+
+DESCRIPTION="UNIX Shell similar to the Korn shell"
+HOMEPAGE="https://www.zsh.org/"
+
+LICENSE="ZSH gdbm? ( GPL-2 )"
+SLOT="0"
+IUSE="caps debug doc examples gdbm maildir pcre static unicode"
+
+RDEPEND="
+ >=sys-libs/ncurses-5.1:0=
+ static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
+ caps? ( sys-libs/libcap )
+ pcre? (
+ >=dev-libs/libpcre-3.9
+ static? ( >=dev-libs/libpcre-3.9[static-libs] )
+ )
+ gdbm? ( sys-libs/gdbm:= )
+"
+DEPEND="sys-apps/groff
+ ${RDEPEND}"
+PDEPEND="
+ examples? ( app-doc/zsh-lovers )
+"
+if [[ ${PV} == *9999 ]] ; then
+ DEPEND+=" app-text/yodl
+ doc? (
+ sys-apps/texinfo
+ app-text/texi2html
+ virtual/latex-base
+ )"
+fi
+
+PATCHES=(
+ # Add openrc specific options for init.d completion
+ "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
+ # Please refer gentoo bug #833981
+ "${FILESDIR}"/${PN}-5.9-musl-V09datetime-test-fix.patch
+ # bug #869539
+ "${FILESDIR}"/${PN}-5.9-clang-15-configure.patch
+)
+
+src_prepare() {
+ if [[ ${PV} != *9999 ]]; then
+ # fix zshall problem with soelim
+ ln -s Doc man1 || die
+ mv Doc/zshall.1 Doc/zshall.1.soelim || die
+ soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
+ fi
+
+ default
+
+ hprefixify configure.ac
+ if [[ ${PV} == *9999 ]] ; then
+ sed -i "/^VERSION=/s@=.*@=${PV}@" Config/version.mk || die
+ fi
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=(
+ --bindir="${EPREFIX}"/bin
+ --libdir="${EPREFIX}"/usr/$(get_libdir)
+ --enable-etcdir="${EPREFIX}"/etc/zsh
+ --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
+ --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
+ --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
+ --enable-function-subdirs
+ --with-tcsetpgrp
+ --with-term-lib="$(usex unicode 'tinfow ncursesw' 'tinfo ncurses')"
+ $(use_enable maildir maildir-support)
+ $(use_enable pcre)
+ $(use_enable caps cap)
+ $(use_enable unicode multibyte)
+ $(use_enable gdbm)
+ )
+
+ if use static ; then
+ myconf+=( --disable-dynamic )
+ append-ldflags -static
+ fi
+ if use debug ; then
+ myconf+=(
+ --enable-zsh-debug
+ --enable-zsh-mem-debug
+ --enable-zsh-mem-warning
+ --enable-zsh-secure-free
+ --enable-zsh-hash-debug
+ )
+ fi
+
+ if [[ ${CHOST} == *-darwin* ]]; then
+ myconf+=( --enable-libs=-liconv )
+ append-ldflags -Wl,-x
+ fi
+
+ econf "${myconf[@]}"
+
+ if use static ; then
+ # compile all modules statically, see Bug #27392
+ # removed cap and curses because linking failes
+ sed -e "s,link=no,link=static,g" \
+ -e "/^name=zsh\/cap/s,link=static,link=no," \
+ -e "/^name=zsh\/curses/s,link=static,link=no," \
+ -i "${S}"/config.modules || die
+ if ! use gdbm ; then
+ sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
+ "${S}"/config.modules || die
+ fi
+ fi
+}
+
+src_compile() {
+ default
+
+ if [[ ${PV} == *9999 ]] && use doc ; then
+ emake -C Doc everything
+ fi
+}
+
+src_test() {
+ # Fixes tests A03quoting.ztst B03print.ztst on musl
+ # Please refer:
+ # https://www.zsh.org/mla/workers/2021/msg00805.html
+ # Test E02xtrace fails on musl, so we are removing it.
+ # Closes: https://bugs.gentoo.org/833981
+ if use elibc_musl ; then
+ unset LC_ALL
+ unset LC_COLLATE
+ unset LC_NUMERIC
+ unset LC_MESSAGES
+ unset LANG
+ rm "${S}"/Test/E02xtrace.ztst || die
+ fi
+ addpredict /dev/ptmx
+ local i
+ for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
+ rm "${S}"/Test/${i} || die
+ done
+ emake check
+}
+
+src_install() {
+ emake DESTDIR="${D}" install $(usex doc "install.info" "")
+
+ insinto /etc/zsh
+ export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
+ newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
+
+ keepdir /usr/share/zsh/site-functions
+ insinto /usr/share/zsh/${PV%_*}/functions/Prompts
+ newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
+
+ local i
+
+ # install miscellaneous scripts (bug #54520)
+ sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
+ -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
+ -i {Util,Misc}/* || die
+ for i in Util Misc ; do
+ insinto /usr/share/zsh/${PV%_*}/${i}
+ doins ${i}/*
+ done
+
+ # install header files (bug #538684)
+ insinto /usr/include/zsh
+ doins config.h Src/*.epro
+ for i in Src/{zsh.mdh,*.h} ; do
+ sed -e 's@\.\./config\.h@config.h@' \
+ -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
+ -i "${i}"
+ doins "${i}"
+ done
+
+ dodoc ChangeLog* META-FAQ NEWS README config.modules
+
+ if use doc ; then
+ pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
+ dodoc Doc/zsh.{dvi,pdf}
+ docinto html
+ dodoc Doc/*.html
+ popd >/dev/null
+ fi
+
+ docinto StartupFiles
+ dodoc StartupFiles/z*
+}
+
+pkg_postinst() {
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
+ echo
+ elog "If you want to enable Portage completions and Gentoo prompt,"
+ elog "emerge app-shells/gentoo-zsh-completions and add"
+ elog " autoload -U compinit promptinit"
+ elog " compinit"
+ elog " promptinit; prompt gentoo"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Also, if you want to enable cache for the completions, add"
+ elog " zstyle ':completion::complete:*' use-cache 1"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Note that a system zprofile startup file is installed. This will override"
+ elog "PATH and possibly other variables that a user may set in ~/.zshenv."
+ elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
+ elog "or other user startup files that are sourced after the system zprofile."
+ echo
+ elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
+ elog "one method is to use a separate path-setting file that is conditionally sourced"
+ elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
+ elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
+ echo
+ elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
+ echo
+ fi
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2022-11-26 21:26 Piotr Karbowski
0 siblings, 0 replies; 15+ messages in thread
From: Piotr Karbowski @ 2022-11-26 21:26 UTC (permalink / raw
To: gentoo-commits
commit: 4ad14bbfc4f7c829df10ab89d1b8712c00dab896
Author: Piotr Karbowski <slashbeast <AT> gentoo <DOT> org>
AuthorDate: Sat Nov 26 21:26:09 2022 +0000
Commit: Piotr Karbowski <slashbeast <AT> gentoo <DOT> org>
CommitDate: Sat Nov 26 21:26:45 2022 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4ad14bbf
app-shells/zsh: drop old.
Bug: https://bugs.gentoo.org/833252
Signed-off-by: Piotr Karbowski <slashbeast <AT> gentoo.org>
app-shells/zsh/Manifest | 2 -
....8.1-non_interactive_shell_regression_fix.patch | 76 -------
.../zsh-5.8.1-performance_regression_fix.patch | 139 ------------
app-shells/zsh/zsh-5.8.1-r2.ebuild | 222 --------------------
app-shells/zsh/zsh-5.9.ebuild | 233 ---------------------
5 files changed, 672 deletions(-)
diff --git a/app-shells/zsh/Manifest b/app-shells/zsh/Manifest
index b5eba80c9a19..ebdcbff39663 100644
--- a/app-shells/zsh/Manifest
+++ b/app-shells/zsh/Manifest
@@ -1,4 +1,2 @@
-DIST zsh-5.8.1-doc.tar.xz 3088728 BLAKE2B c7f62f50a8fce483d2946ac550fa0996e5749a9040cf9424a61d591024292a2f1eb0fc2401824104c6ef0fff2a4b38e07269a0069cde1b0bff6e8a7b09daf160 SHA512 0d8ca4c54c10e8a471ba7d53f1371ee057f7df4b710fc01194833f29a61b5465133432b891b0b891b6cc5235a928a783bf99f39c67314e29e3d161ca5abf3219
-DIST zsh-5.8.1.tar.xz 3200540 BLAKE2B 19981d0cc208fb590af8e034bde66bda36a4a20abe76ff71ba9222d7150b7d53573e1f5b81ddb2cdd29f6aa0611071a35d8b48250e6bd4b196f0428b776c4af8 SHA512 f54a5a47ed15d134902613f6169c985680afc45a67538505e11b66b348fcb367145e9b8ae2d9eac185e07ef5f97254b85df01ba97294002a8c036fd02ed5e76d
DIST zsh-5.9-doc.tar.xz 3130444 BLAKE2B 96b635b438f8a90bc1f3c15c8a287ab392ba830e975e49b7f1c09d12de44c250dcf33d1d6dc93b58693839af2e57eb5c9d4e874ca08dd82fe876cb5ca26e6508 SHA512 5cc6abcdcfb4f5ad7bc4a31364ca49dfd87ae03e0082d89cc2ba1f00570f6757266ee60894ad31b562408de91494c22f177b414b03cb78c31d92328686be9860
DIST zsh-5.9.tar.xz 3332400 BLAKE2B 3ecd6d080ff47b78d228d9bf5c1bafd3dfc602beb681ec533ce1039041d0e93143ebd7e0e73a9aed0789e27ca42d58a55f3b6e2c7d89113ab3ee99112dec46d1 SHA512 d9138b7f379ad942a5f46819d2dd52d31f3a1129f2a0d1b53d4c5cd43c318b60396da6d37c57c477b8e958fb750209aca0ae93f8c9dd42ac958de006a0ff067e
diff --git a/app-shells/zsh/files/zsh-5.8.1-non_interactive_shell_regression_fix.patch b/app-shells/zsh/files/zsh-5.8.1-non_interactive_shell_regression_fix.patch
deleted file mode 100644
index 6e202fa2fb24..000000000000
--- a/app-shells/zsh/files/zsh-5.8.1-non_interactive_shell_regression_fix.patch
+++ /dev/null
@@ -1,76 +0,0 @@
-From da8be06c2062ea02795bcba25172369ec68848cf Mon Sep 17 00:00:00 2001
-From: Peter Stephenson <p.w.stephenson@ntlworld.com>
-Date: Thu, 3 Mar 2022 19:19:35 +0000
-Subject: [PATCH] 49792: Non-interative shell input is line buffered.
-
----
- ChangeLog | 5 +++++
- Src/input.c | 21 ++++++++++++++-------
- Test/A01grammar.ztst | 9 +++++++++
- 3 files changed, 28 insertions(+), 7 deletions(-)
-
-diff --git a/ChangeLog b/ChangeLog
-index 8a5ad4941..cae2fc4e3 100644
---- a/ChangeLog
-+++ b/ChangeLog
-@@ -1,3 +1,8 @@
-+2022-03-03 Peter Stephenson <p.w.stephenson@ntlworld.com>
-+
-+ * 49792: Src/input.c, Test/A01grammar.ztst: Use line buffering
-+ for non-interactive input.
-+
- 2022-02-12 dana <dana@dana.is>
-
- * unposted: Config/version.mk, Etc/FAQ.yo, README: Update
-diff --git a/Src/input.c b/Src/input.c
-index 18228b37d..caa8e23b0 100644
---- a/Src/input.c
-+++ b/Src/input.c
-@@ -223,13 +223,20 @@ shingetchar(void)
- return STOUC(*shinbufptr++);
-
- shinbufreset();
-- do {
-- errno = 0;
-- nread = read(SHIN, shinbuffer, SHINBUFSIZE);
-- } while (nread < 0 && errno == EINTR);
-- if (nread <= 0)
-- return -1;
-- shinbufendptr = shinbuffer + nread;
-+ for (;;) {
-+ errno = 0;
-+ nread = read(SHIN, shinbufendptr, 1);
-+ if (nread > 0) {
-+ /* Use line buffering (POSIX requirement) */
-+ if (*shinbufendptr++ == '\n')
-+ break;
-+ if (shinbufendptr == shinbuffer + SHINBUFSIZE)
-+ break;
-+ } else if (nread == 0 || errno != EINTR)
-+ break;
-+ }
-+ if (shinbufendptr == shinbuffer)
-+ return -1;
- return STOUC(*shinbufptr++);
- }
-
-diff --git a/Test/A01grammar.ztst b/Test/A01grammar.ztst
-index 1e0e9a04e..adbf5f1d9 100644
---- a/Test/A01grammar.ztst
-+++ b/Test/A01grammar.ztst
-@@ -932,3 +932,12 @@ F:Note that the behaviour of 'exit' inside try-list inside a function is unspeci
- $ZTST_testdir/../Src/zsh -fc '{ ( ) } always { echo foo }'
- -f:exec last command optimization inhibited for try/always
- >foo
-+
-+ (
-+ export VALUE=first
-+ print -l 'echo Value is $VALUE' 'VALUE=second sh' 'echo Value is $VALUE' |
-+ $ZTST_testdir/../Src/zsh -f
-+ )
-+0:Non-interactive shell command input is line buffered
-+>Value is first
-+>Value is second
---
-2.36.0.rc2
-
diff --git a/app-shells/zsh/files/zsh-5.8.1-performance_regression_fix.patch b/app-shells/zsh/files/zsh-5.8.1-performance_regression_fix.patch
deleted file mode 100644
index 14a3f38eb96d..000000000000
--- a/app-shells/zsh/files/zsh-5.8.1-performance_regression_fix.patch
+++ /dev/null
@@ -1,139 +0,0 @@
-From cbe8d2bcdc20682464217856aa48628804637f28 Mon Sep 17 00:00:00 2001
-From: Bart Schaefer <schaefer@zsh.org>
-Date: Thu, 28 Apr 2022 21:06:51 -0700
-Subject: [PATCH] 50133: use read-ahead and lseek-rewind for efficient
- line-buffered input
-
----
- ChangeLog | 6 ++++++
- Src/input.c | 24 ++++++++++++++++++++-
- configure.ac | 59 ++++++++++++++++++++++++++++++++++++++++++++++++++++
- 3 files changed, 88 insertions(+), 1 deletion(-)
-
-diff --git a/ChangeLog b/ChangeLog
-index cae2fc4e3..79c77741b 100644
---- a/ChangeLog
-+++ b/ChangeLog
-@@ -1,3 +1,9 @@
-+2022-04-28 Bart Schaefer <schaefer@zsh.org>
-+
-+ * 50133 (Bart, PWS, Jun-ichi): Src/input.c, configure.ac: when
-+ lseek(2) is available, use it to check for and rewind read-ahead
-+ for more efficient line-buffered input.
-+
- 2022-03-03 Peter Stephenson <p.w.stephenson@ntlworld.com>
-
- * 49792: Src/input.c, Test/A01grammar.ztst: Use line buffering
-diff --git a/Src/input.c b/Src/input.c
-index caa8e23b0..6cc1b8a51 100644
---- a/Src/input.c
-+++ b/Src/input.c
-@@ -217,12 +217,34 @@ shinbufrestore(void)
- static int
- shingetchar(void)
- {
-- int nread;
-+ int nread, rsize = isset(SHINSTDIN) ? 1 : SHINBUFSIZE;
-
- if (shinbufptr < shinbufendptr)
- return STOUC(*shinbufptr++);
-
- shinbufreset();
-+#ifdef USE_LSEEK
-+ if (rsize == 1 && lseek(SHIN, 0, SEEK_CUR) != (off_t)-1)
-+ rsize = SHINBUFSIZE;
-+ if (rsize > 1) {
-+ do {
-+ errno = 0;
-+ nread = read(SHIN, shinbuffer, rsize);
-+ } while (nread < 0 && errno == EINTR);
-+ if (nread <= 0)
-+ return -1;
-+ if (isset(SHINSTDIN) &&
-+ (shinbufendptr = memchr(shinbuffer, '\n', nread))) {
-+ shinbufendptr++;
-+ rsize = (shinbufendptr - shinbuffer);
-+ if (nread > rsize &&
-+ lseek(SHIN, -(nread - rsize), SEEK_CUR) < 0)
-+ zerr("lseek(%d, %d): %e", SHIN, -(nread - rsize), errno);
-+ } else
-+ shinbufendptr = shinbuffer + nread;
-+ return STOUC(*shinbufptr++);
-+ }
-+#endif
- for (;;) {
- errno = 0;
- nread = read(SHIN, shinbufendptr, 1);
-diff --git a/configure.ac b/configure.ac
-index af8c5bba8..42f2837cd 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -2304,6 +2304,65 @@ if test x$zsh_cv_sys_fifo = xyes; then
- AC_DEFINE(HAVE_FIFOS)
- fi
-
-+dnl -----------
-+dnl check that lseek() correctly reports seekability.
-+dnl -----------
-+AC_CACHE_CHECK(if lseek() correctly reports seekability,
-+zsh_cv_sys_lseek,
-+[AC_RUN_IFELSE([AC_LANG_SOURCE([[
-+#include <stdio.h>
-+#include <sys/types.h>
-+#include <fcntl.h>
-+#include <unistd.h>
-+#include <sys/socket.h>
-+#include <sys/stat.h>
-+int main() {
-+ int pipefd[2], fd;
-+ off_t ret;
-+ char* tmpfile = "seekfiletest.tmp";
-+ if ((fd = open(tmpfile, O_CREAT, S_IRUSR)) < 0) {
-+ fprintf(stderr, "creating file failed\n");
-+ return 1;
-+ }
-+ ret = lseek(fd, 0, SEEK_CUR);
-+ close(fd);
-+ unlink(tmpfile);
-+ if (ret == (off_t)-1) {
-+ fprintf(stderr, "lseek on regular file failed\n");
-+ return 1;
-+ }
-+ if (pipe(pipefd) < 0) {
-+ fprintf(stderr, "creating pipe failed\n");
-+ return 1;
-+ }
-+ write(pipefd[1], "abcdefgh", 8);
-+ ret = lseek(pipefd[0], 0, SEEK_CUR);
-+ close(pipefd[0]);
-+ close(pipefd[1]);
-+ if (ret != (off_t)-1) {
-+ fprintf(stderr, "lseek on pipe succeeded\n");
-+ return 1;
-+ }
-+ if ((fd = socket(AF_UNIX, SOCK_STREAM, 0)) < 0) {
-+ fprintf(stderr, "creating UNIX domain socket failed\n");
-+ return 1;
-+ }
-+ ret = lseek(fd, 0, SEEK_CUR);
-+ close(fd);
-+ if (ret != (off_t)-1) {
-+ fprintf(stderr, "lseek on UNIX domain socket succeeded\n");
-+ return 1;
-+ }
-+ return 0;
-+}
-+]])],[zsh_cv_sys_lseek=yes],[zsh_cv_sys_lseek=no],[zsh_cv_sys_lseek=yes])
-+])
-+AH_TEMPLATE([USE_LSEEK],
-+[Define to 1 if lseek() can be used for SHIN.])
-+if test x$zsh_cv_sys_lseek = xyes; then
-+ AC_DEFINE(USE_LSEEK)
-+fi
-+
- dnl -----------
- dnl test for whether link() works
- dnl for instance, BeOS R4.51 doesn't support hard links yet
---
-2.36.0
-
diff --git a/app-shells/zsh/zsh-5.8.1-r2.ebuild b/app-shells/zsh/zsh-5.8.1-r2.ebuild
deleted file mode 100644
index 4aedba310b22..000000000000
--- a/app-shells/zsh/zsh-5.8.1-r2.ebuild
+++ /dev/null
@@ -1,222 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit autotools flag-o-matic prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3
- EGIT_REPO_URI="https://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
- https://www.zsh.org/pub/old/${P}.tar.xz
- mirror://sourceforge/${PN}/${P}.tar.xz
- doc? (
- https://www.zsh.org/pub/${P}-doc.tar.xz
- mirror://sourceforge/${PN}/${P}-doc.tar.xz
- )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="https://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1:0=
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? (
- >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] )
- )
- gdbm? ( sys-libs/gdbm:= )
- !<sys-apps/baselayout-2.4.1
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == *9999 ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-PATCHES=(
- "${FILESDIR}/${P}-non_interactive_shell_regression_fix.patch"
- "${FILESDIR}/${P}-performance_regression_fix.patch" #839900
-)
-
-src_prepare() {
- if [[ ${PV} != *9999 ]]; then
- # fix zshall problem with soelim
- ln -s Doc man1 || die
- mv Doc/zshall.1 Doc/zshall.1.soelim || die
- soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
- fi
-
- # add openrc specific options for init.d completion
- eapply "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
-
- default
-
- hprefixify configure.ac
- if [[ ${PV} == *9999 ]] ; then
- sed -i "/^VERSION=/s@=.*@=${PV}@" Config/version.mk || die
- fi
- eautoreconf
-}
-
-src_configure() {
- local myconf=(
- --bindir="${EPREFIX}"/bin
- --libdir="${EPREFIX}"/usr/$(get_libdir)
- --enable-etcdir="${EPREFIX}"/etc/zsh
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
- --enable-function-subdirs
- --with-tcsetpgrp
- --with-term-lib="$(usex unicode 'tinfow ncursesw' 'tinfo ncurses')"
- $(use_enable maildir maildir-support)
- $(use_enable pcre)
- $(use_enable caps cap)
- $(use_enable unicode multibyte)
- $(use_enable gdbm)
- )
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == *9999 ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install $(usex doc "install.info" "")
-
- insinto /etc/zsh
- export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
- newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dodoc Doc/zsh.{dvi,pdf}
- docinto html
- dodoc Doc/*.html
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
diff --git a/app-shells/zsh/zsh-5.9.ebuild b/app-shells/zsh/zsh-5.9.ebuild
deleted file mode 100644
index 9cfcc3a75650..000000000000
--- a/app-shells/zsh/zsh-5.9.ebuild
+++ /dev/null
@@ -1,233 +0,0 @@
-# Copyright 1999-2022 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=8
-
-inherit autotools flag-o-matic prefix
-
-if [[ ${PV} == 9999* ]] ; then
- inherit git-r3
- EGIT_REPO_URI="https://git.code.sf.net/p/zsh/code"
-else
- KEYWORDS="~alpha amd64 arm arm64 ~hppa ~ia64 ~loong ~m68k ~mips ppc ppc64 ~riscv ~s390 sparc x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
- SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
- https://www.zsh.org/pub/old/${P}.tar.xz
- mirror://sourceforge/${PN}/${P}.tar.xz
- doc? (
- https://www.zsh.org/pub/${P}-doc.tar.xz
- mirror://sourceforge/${PN}/${P}-doc.tar.xz
- )"
-fi
-
-DESCRIPTION="UNIX Shell similar to the Korn shell"
-HOMEPAGE="https://www.zsh.org/"
-
-LICENSE="ZSH gdbm? ( GPL-2 )"
-SLOT="0"
-IUSE="caps debug doc examples gdbm maildir pcre static unicode"
-
-RDEPEND="
- >=sys-libs/ncurses-5.1:0=
- static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
- caps? ( sys-libs/libcap )
- pcre? (
- >=dev-libs/libpcre-3.9
- static? ( >=dev-libs/libpcre-3.9[static-libs] )
- )
- gdbm? ( sys-libs/gdbm:= )
-"
-DEPEND="sys-apps/groff
- ${RDEPEND}"
-PDEPEND="
- examples? ( app-doc/zsh-lovers )
-"
-if [[ ${PV} == *9999 ]] ; then
- DEPEND+=" app-text/yodl
- doc? (
- sys-apps/texinfo
- app-text/texi2html
- virtual/latex-base
- )"
-fi
-
-PATCHES=(
- # add openrc specific options for init.d completion
- "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
- # Please refer gentoo bug 833981
- "${FILESDIR}"/${PN}-5.9-musl-V09datetime-test-fix.patch
-)
-
-src_prepare() {
- if [[ ${PV} != *9999 ]]; then
- # fix zshall problem with soelim
- ln -s Doc man1 || die
- mv Doc/zshall.1 Doc/zshall.1.soelim || die
- soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
- fi
-
- default
-
- hprefixify configure.ac
- if [[ ${PV} == *9999 ]] ; then
- sed -i "/^VERSION=/s@=.*@=${PV}@" Config/version.mk || die
- fi
- eautoreconf
-}
-
-src_configure() {
- local myconf=(
- --bindir="${EPREFIX}"/bin
- --libdir="${EPREFIX}"/usr/$(get_libdir)
- --enable-etcdir="${EPREFIX}"/etc/zsh
- --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
- --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
- --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
- --enable-function-subdirs
- --with-tcsetpgrp
- --with-term-lib="$(usex unicode 'tinfow ncursesw' 'tinfo ncurses')"
- $(use_enable maildir maildir-support)
- $(use_enable pcre)
- $(use_enable caps cap)
- $(use_enable unicode multibyte)
- $(use_enable gdbm)
- )
-
- if use static ; then
- myconf+=( --disable-dynamic )
- append-ldflags -static
- fi
- if use debug ; then
- myconf+=(
- --enable-zsh-debug
- --enable-zsh-mem-debug
- --enable-zsh-mem-warning
- --enable-zsh-secure-free
- --enable-zsh-hash-debug
- )
- fi
-
- if [[ ${CHOST} == *-darwin* ]]; then
- myconf+=( --enable-libs=-liconv )
- append-ldflags -Wl,-x
- fi
-
- econf "${myconf[@]}"
-
- if use static ; then
- # compile all modules statically, see Bug #27392
- # removed cap and curses because linking failes
- sed -e "s,link=no,link=static,g" \
- -e "/^name=zsh\/cap/s,link=static,link=no," \
- -e "/^name=zsh\/curses/s,link=static,link=no," \
- -i "${S}"/config.modules || die
- if ! use gdbm ; then
- sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
- "${S}"/config.modules || die
- fi
- fi
-}
-
-src_compile() {
- default
-
- if [[ ${PV} == *9999 ]] && use doc ; then
- emake -C Doc everything
- fi
-}
-
-src_test() {
- # Fixes tests A03quoting.ztst B03print.ztst on musl
- # Please refer:
- # https://www.zsh.org/mla/workers/2021/msg00805.html
- # Test E02xtrace fails on musl, so we are removing it.
- # Closes: https://bugs.gentoo.org/833981
- if use elibc_musl ; then
- unset LC_ALL
- unset LC_COLLATE
- unset LC_NUMERIC
- unset LC_MESSAGES
- unset LANG
- rm "${S}"/Test/E02xtrace.ztst || die
- fi
- addpredict /dev/ptmx
- local i
- for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
- rm "${S}"/Test/${i} || die
- done
- emake check
-}
-
-src_install() {
- emake DESTDIR="${D}" install $(usex doc "install.info" "")
-
- insinto /etc/zsh
- export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
- newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
-
- keepdir /usr/share/zsh/site-functions
- insinto /usr/share/zsh/${PV%_*}/functions/Prompts
- newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
-
- local i
-
- # install miscellaneous scripts (bug #54520)
- sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
- -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
- -i {Util,Misc}/* || die
- for i in Util Misc ; do
- insinto /usr/share/zsh/${PV%_*}/${i}
- doins ${i}/*
- done
-
- # install header files (bug #538684)
- insinto /usr/include/zsh
- doins config.h Src/*.epro
- for i in Src/{zsh.mdh,*.h} ; do
- sed -e 's@\.\./config\.h@config.h@' \
- -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
- -i "${i}"
- doins "${i}"
- done
-
- dodoc ChangeLog* META-FAQ NEWS README config.modules
-
- if use doc ; then
- pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
- dodoc Doc/zsh.{dvi,pdf}
- docinto html
- dodoc Doc/*.html
- popd >/dev/null
- fi
-
- docinto StartupFiles
- dodoc StartupFiles/z*
-}
-
-pkg_postinst() {
- if [[ -z ${REPLACING_VERSIONS} ]] ; then
- echo
- elog "If you want to enable Portage completions and Gentoo prompt,"
- elog "emerge app-shells/gentoo-zsh-completions and add"
- elog " autoload -U compinit promptinit"
- elog " compinit"
- elog " promptinit; prompt gentoo"
- elog "to your ~/.zshrc"
- echo
- elog "Also, if you want to enable cache for the completions, add"
- elog " zstyle ':completion::complete:*' use-cache 1"
- elog "to your ~/.zshrc"
- echo
- elog "Note that a system zprofile startup file is installed. This will override"
- elog "PATH and possibly other variables that a user may set in ~/.zshenv."
- elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
- elog "or other user startup files that are sourced after the system zprofile."
- echo
- elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
- elog "one method is to use a separate path-setting file that is conditionally sourced"
- elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
- elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
- echo
- elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
- echo
- fi
-}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2023-03-12 12:33 Piotr Karbowski
0 siblings, 0 replies; 15+ messages in thread
From: Piotr Karbowski @ 2023-03-12 12:33 UTC (permalink / raw
To: gentoo-commits
commit: 9290ddedaac06dc082d112f2b906c08433c204f9
Author: Piotr Karbowski <slashbeast <AT> gentoo <DOT> org>
AuthorDate: Sun Mar 12 12:32:58 2023 +0000
Commit: Piotr Karbowski <slashbeast <AT> gentoo <DOT> org>
CommitDate: Sun Mar 12 12:33:46 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9290dded
app-shells/zsh: 5.9-r4 revbump, fixes tests.
Closes: https://bugs.gentoo.org/869332
Signed-off-by: Piotr Karbowski <slashbeast <AT> gentoo.org>
.../files/zsh-5.9-do-not-use-egrep-in-tests.patch | 166 ++++++++++++++
app-shells/zsh/zsh-5.9-r4.ebuild | 239 +++++++++++++++++++++
2 files changed, 405 insertions(+)
diff --git a/app-shells/zsh/files/zsh-5.9-do-not-use-egrep-in-tests.patch b/app-shells/zsh/files/zsh-5.9-do-not-use-egrep-in-tests.patch
new file mode 100644
index 000000000000..7cf605674e96
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.9-do-not-use-egrep-in-tests.patch
@@ -0,0 +1,166 @@
+commit 4fc5dc0292acd77f17281f451774ba2ca4203026
+Author: Jun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>
+Date: 2022-09-15 18:56:20 +0900
+
+ 50629: do not use egrep in tests
+
+ (ChangeLog changes removed)
+
+diff --git a/Test/D07multibyte.ztst b/Test/D07multibyte.ztst
+index e2e9a25ef..6909346cb 100644
+--- a/Test/D07multibyte.ztst
++++ b/Test/D07multibyte.ztst
+@@ -1,19 +1,7 @@
+ %prep
+
+-# Find a UTF-8 locale.
+- setopt multibyte
+-# Don't let LC_* override our choice of locale.
+- unset -m LC_\*
+- mb_ok=
+- langs=(en_{US,GB}.{UTF-,utf}8 en.UTF-8
+- $(locale -a 2>/dev/null | egrep 'utf8|UTF-8'))
+- for LANG in $langs; do
+- if [[ é = ? ]]; then
+- mb_ok=1
+- break;
+- fi
+- done
+- if [[ -z $mb_ok ]]; then
++ LANG=$(ZTST_find_UTF8)
++ if [[ -z $LANG ]]; then
+ ZTST_unimplemented="no UTF-8 locale or multibyte mode is not implemented"
+ else
+ print -u $ZTST_fd Testing multibyte with locale $LANG
+diff --git a/Test/E01options.ztst b/Test/E01options.ztst
+index 2acbfd357..d38fbed74 100644
+--- a/Test/E01options.ztst
++++ b/Test/E01options.ztst
+@@ -651,7 +651,7 @@
+ >noktarg1
+ >0 1
+
+- showopt() { setopt | egrep 'localoptions|ksharrays'; }
++ showopt() { echo ${(FM)${(@f)"$(setopt)"}:#(localoptions|ksharrays)*} }
+ f1() { setopt localoptions ksharrays; showopt }
+ f2() { setopt ksharrays; showopt }
+ setopt kshoptionprint
+diff --git a/Test/V07pcre.ztst b/Test/V07pcre.ztst
+index c9c844d2a..ca13419e5 100644
+--- a/Test/V07pcre.ztst
++++ b/Test/V07pcre.ztst
+@@ -6,20 +6,8 @@
+ return 0
+ fi
+ setopt rematch_pcre
+-# Find a UTF-8 locale.
+- setopt multibyte
+-# Don't let LC_* override our choice of locale.
+- unset -m LC_\*
+- mb_ok=
+- langs=(en_{US,GB}.{UTF-,utf}8 en.UTF-8
+- $(locale -a 2>/dev/null | egrep 'utf8|UTF-8'))
+- for LANG in $langs; do
+- if [[ é = ? ]]; then
+- mb_ok=1
+- break;
+- fi
+- done
+- if [[ -z $mb_ok ]]; then
++ LANG=$(ZTST_find_UTF8)
++ if [[ -z $LANG ]]; then
+ ZTST_unimplemented="no UTF-8 locale or multibyte mode is not implemented"
+ else
+ print -u $ZTST_fd Testing PCRE multibyte with locale $LANG
+diff --git a/Test/X02zlevi.ztst b/Test/X02zlevi.ztst
+index 8146d6752..203c13c32 100644
+--- a/Test/X02zlevi.ztst
++++ b/Test/X02zlevi.ztst
+@@ -1,16 +1,7 @@
+ # Tests of the vi mode of ZLE
+
+ %prep
+- unset -m LC_\*
+- ZSH_TEST_LANG=
+- langs=(en_{US,GB}.{UTF-,utf}8 en.UTF-8
+- $(locale -a 2>/dev/null | egrep 'utf8|UTF-8'))
+- for LANG in $langs; do
+- if [[ é = ? ]]; then
+- ZSH_TEST_LANG=$LANG
+- break;
+- fi
+- done
++ ZSH_TEST_LANG=$(ZTST_find_UTF8)
+ if ( zmodload zsh/zpty 2>/dev/null ); then
+ . $ZTST_srcdir/comptest
+ comptestinit -v -z $ZTST_testdir/../Src/zsh
+diff --git a/Test/X03zlebindkey.ztst b/Test/X03zlebindkey.ztst
+index 43692a85b..5277332a7 100644
+--- a/Test/X03zlebindkey.ztst
++++ b/Test/X03zlebindkey.ztst
+@@ -3,16 +3,7 @@
+ # into bindings. The latter is particularly tricky with multibyte sequences.
+
+ %prep
+- unset -m LC_\*
+- ZSH_TEST_LANG=
+- langs=(en_{US,GB}.{UTF-,utf}8 en.UTF-8
+- $(locale -a 2>/dev/null | egrep 'utf8|UTF-8'))
+- for LANG in $langs; do
+- if [[ é = ? ]]; then
+- ZSH_TEST_LANG=$LANG
+- break;
+- fi
+- done
++ ZSH_TEST_LANG=$(ZTST_find_UTF8)
+ if ( zmodload zsh/zpty 2>/dev/null ); then
+ . $ZTST_srcdir/comptest
+ comptestinit -z $ZTST_testdir/../Src/zsh
+diff --git a/Test/Y01completion.ztst b/Test/Y01completion.ztst
+index 6af0efc6d..f976f9f91 100644
+--- a/Test/Y01completion.ztst
++++ b/Test/Y01completion.ztst
+@@ -1,16 +1,7 @@
+ # Tests for completion system.
+
+ %prep
+- unset -m LC_\*
+- ZSH_TEST_LANG=
+- langs=(en_{US,GB}.{UTF-,utf}8 en.UTF-8
+- $(locale -a 2>/dev/null | egrep 'utf8|UTF-8'))
+- for LANG in $langs; do
+- if [[ é = ? ]]; then
+- ZSH_TEST_LANG=$LANG
+- break;
+- fi
+- done
++ ZSH_TEST_LANG=$(ZTST_find_UTF8)
+ if ( zmodload zsh/zpty 2>/dev/null ); then
+ . $ZTST_srcdir/comptest
+ mkdir comp.tmp
+diff --git a/Test/ztst.zsh b/Test/ztst.zsh
+index aca275c1c..d95b726e7 100755
+--- a/Test/ztst.zsh
++++ b/Test/ztst.zsh
+@@ -37,6 +37,21 @@ emulate -R zsh
+ # LANG must be passed to child zsh.
+ export LANG
+
++# find UTF-8 locale
++ZTST_find_UTF8 () {
++ setopt multibyte
++ # Don't let LC_* override our choice of locale.
++ unset -m LC_\*
++ local langs=(en_{US,GB}.{UTF-,utf}8 en.UTF-8
++ ${(M)$(locale -a 2>/dev/null):#*.(utf8|UTF-8)})
++ for LANG in $langs; do
++ if [[ é = ? ]]; then
++ echo $LANG
++ return
++ fi
++ done
++}
++
+ # Don't propagate variables that are set by default in the shell.
+ typeset +x WORDCHARS
+
diff --git a/app-shells/zsh/zsh-5.9-r4.ebuild b/app-shells/zsh/zsh-5.9-r4.ebuild
new file mode 100644
index 000000000000..97907e6b79e4
--- /dev/null
+++ b/app-shells/zsh/zsh-5.9-r4.ebuild
@@ -0,0 +1,239 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools flag-o-matic prefix
+
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris"
+
+SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
+ https://www.zsh.org/pub/old/${P}.tar.xz
+ mirror://sourceforge/${PN}/${P}.tar.xz
+ doc? (
+ https://www.zsh.org/pub/${P}-doc.tar.xz
+ mirror://sourceforge/${PN}/${P}-doc.tar.xz
+ )"
+
+DESCRIPTION="UNIX Shell similar to the Korn shell"
+HOMEPAGE="https://www.zsh.org/"
+
+LICENSE="ZSH gdbm? ( GPL-2 )"
+SLOT="0"
+IUSE="caps debug doc examples gdbm maildir pcre static"
+
+RDEPEND="
+ >=sys-libs/ncurses-5.1:0=
+ static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
+ caps? ( sys-libs/libcap )
+ pcre? (
+ >=dev-libs/libpcre-3.9
+ static? ( >=dev-libs/libpcre-3.9[static-libs] )
+ )
+ gdbm? (
+ sys-libs/gdbm:=
+ static? ( sys-libs/gdbm:=[static-libs] )
+ )
+"
+DEPEND="sys-apps/groff
+ ${RDEPEND}"
+PDEPEND="
+ examples? ( app-doc/zsh-lovers )
+"
+if [[ ${PV} == *9999 ]] ; then
+ DEPEND+=" app-text/yodl
+ doc? (
+ sys-apps/texinfo
+ app-text/texi2html
+ virtual/latex-base
+ )"
+fi
+
+PATCHES=(
+ # Add openrc specific options for init.d completion
+ "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
+ # Please refer gentoo bug #833981
+ "${FILESDIR}"/${PN}-5.9-musl-V09datetime-test-fix.patch
+ # bug #869539
+ "${FILESDIR}"/${PN}-5.9-clang-15-configure.patch
+ "${FILESDIR}"/${PN}-5.9-do-not-use-egrep-in-tests.patch
+)
+
+src_prepare() {
+ if [[ ${PV} != *9999 ]]; then
+ # fix zshall problem with soelim
+ ln -s Doc man1 || die
+ mv Doc/zshall.1 Doc/zshall.1.soelim || die
+ soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
+ fi
+
+ default
+
+ hprefixify configure.ac
+ if [[ ${PV} == *9999 ]] ; then
+ sed -i "/^VERSION=/s@=.*@=${PV}@" Config/version.mk || die
+ fi
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=(
+ --bindir="${EPREFIX}"/bin
+ --libdir="${EPREFIX}"/usr/$(get_libdir)
+ --enable-etcdir="${EPREFIX}"/etc/zsh
+ --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
+ --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
+ --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
+ --enable-function-subdirs
+ --with-tcsetpgrp
+ --enable-multibyte
+ --with-term-lib='tinfow ncursesw'
+ $(use_enable maildir maildir-support)
+ $(use_enable pcre)
+ $(use_enable caps cap)
+ $(use_enable gdbm)
+ )
+
+ if use static ; then
+ myconf+=( --disable-dynamic )
+ append-ldflags -static
+ fi
+ if use debug ; then
+ myconf+=(
+ --enable-zsh-debug
+ --enable-zsh-mem-debug
+ --enable-zsh-mem-warning
+ --enable-zsh-secure-free
+ --enable-zsh-hash-debug
+ )
+ fi
+
+ if [[ ${CHOST} == *-darwin* ]]; then
+ myconf+=( --enable-libs=-liconv )
+ append-ldflags -Wl,-x
+ fi
+
+ econf "${myconf[@]}"
+
+ if use static ; then
+ # compile all modules statically, see Bug #27392
+ # removed cap and curses because linking failes
+ sed -e "s,link=no,link=static,g" \
+ -e "/^name=zsh\/cap/s,link=static,link=no," \
+ -e "/^name=zsh\/curses/s,link=static,link=no," \
+ -i "${S}"/config.modules || die
+ if ! use gdbm ; then
+ sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
+ "${S}"/config.modules || die
+ fi
+ fi
+}
+
+src_compile() {
+ default
+
+ if [[ ${PV} == *9999 ]] && use doc ; then
+ emake -C Doc everything
+ fi
+}
+
+src_test() {
+ # Fixes tests A03quoting.ztst B03print.ztst on musl
+ # Please refer:
+ # https://www.zsh.org/mla/workers/2021/msg00805.html
+ # Test E02xtrace fails on musl, so we are removing it.
+ # Closes: https://bugs.gentoo.org/833981
+ if use elibc_musl ; then
+ unset LC_ALL
+ unset LC_COLLATE
+ unset LC_NUMERIC
+ unset LC_MESSAGES
+ unset LANG
+ rm "${S}"/Test/E02xtrace.ztst || die
+ fi
+
+ # Breaks tests if inherited from environment.
+ unset TMPPREFIX
+
+ addpredict /dev/ptmx
+ local i
+ for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
+ rm "${S}"/Test/${i} || die
+ done
+ emake check
+}
+
+src_install() {
+ emake DESTDIR="${D}" install $(usex doc "install.info" "")
+
+ insinto /etc/zsh
+ export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
+ newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
+
+ keepdir /usr/share/zsh/site-functions
+ insinto /usr/share/zsh/${PV%_*}/functions/Prompts
+ newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
+
+ local i
+
+ # install miscellaneous scripts (bug #54520)
+ sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
+ -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
+ -i {Util,Misc}/* || die
+ for i in Util Misc ; do
+ insinto /usr/share/zsh/${PV%_*}/${i}
+ doins ${i}/*
+ done
+
+ # install header files (bug #538684)
+ insinto /usr/include/zsh
+ doins config.h Src/*.epro
+ for i in Src/{zsh.mdh,*.h} ; do
+ sed -e 's@\.\./config\.h@config.h@' \
+ -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
+ -i "${i}"
+ doins "${i}"
+ done
+
+ dodoc ChangeLog* META-FAQ NEWS README config.modules
+
+ if use doc ; then
+ pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
+ dodoc Doc/zsh.{dvi,pdf}
+ docinto html
+ dodoc Doc/*.html
+ popd >/dev/null
+ fi
+
+ docinto StartupFiles
+ dodoc StartupFiles/z*
+}
+
+pkg_postinst() {
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
+ echo
+ elog "If you want to enable Portage completions and Gentoo prompt,"
+ elog "emerge app-shells/gentoo-zsh-completions and add"
+ elog " autoload -U compinit promptinit"
+ elog " compinit"
+ elog " promptinit; prompt gentoo"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Also, if you want to enable cache for the completions, add"
+ elog " zstyle ':completion::complete:*' use-cache 1"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Note that a system zprofile startup file is installed. This will override"
+ elog "PATH and possibly other variables that a user may set in ~/.zshenv."
+ elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
+ elog "or other user startup files that are sourced after the system zprofile."
+ echo
+ elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
+ elog "one method is to use a separate path-setting file that is conditionally sourced"
+ elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
+ elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
+ echo
+ elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
+ echo
+ fi
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/
@ 2023-12-16 7:44 Sam James
0 siblings, 0 replies; 15+ messages in thread
From: Sam James @ 2023-12-16 7:44 UTC (permalink / raw
To: gentoo-commits
commit: 24e0dd5fff14aee16dab340be37fd345b804c0c4
Author: Sam James <sam <AT> gentoo <DOT> org>
AuthorDate: Sat Dec 16 07:40:31 2023 +0000
Commit: Sam James <sam <AT> gentoo <DOT> org>
CommitDate: Sat Dec 16 07:44:23 2023 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=24e0dd5f
app-shells/zsh: fix modern C configure issue, fix relro plugin issue
* Fix configure issue with stricter C compilers which leads to build failure later
on in the build
* Fix plugin use w/ relro
Closes: https://bugs.gentoo.org/919001
Signed-off-by: Sam James <sam <AT> gentoo.org>
app-shells/zsh/files/zsh-5.9-c99.patch | 45 ++++++
app-shells/zsh/files/zsh-5.9-relro.patch | 71 +++++++++
app-shells/zsh/zsh-5.9-r5.ebuild | 245 +++++++++++++++++++++++++++++++
3 files changed, 361 insertions(+)
diff --git a/app-shells/zsh/files/zsh-5.9-c99.patch b/app-shells/zsh/files/zsh-5.9-c99.patch
new file mode 100644
index 000000000000..fad71a6a6c2b
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.9-c99.patch
@@ -0,0 +1,45 @@
+https://github.com/zsh-users/zsh/commit/4c89849c98172c951a9def3690e8647dae76308f
+https://bugs.gentoo.org/919001
+
+Avoid incompatible pointer types in terminfo global variable checks.
+Some compilers reject these incompatible pointer types, causing the
+checks to always fail, when these variables are in fact available.
+
+Submitted upstream: <https://www.zsh.org/mla/workers/2023/msg01112.html>
+
+--- a/configure.ac
++++ b/configure.ac
+@@ -1769,27 +1769,27 @@ if test x$zsh_cv_path_term_header != xnone; then
+ fi
+
+ AC_MSG_CHECKING(if boolcodes is available)
+- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = boolcodes; puts(*test);]])],[AC_DEFINE(HAVE_BOOLCODES) boolcodes=yes],[boolcodes=no])
++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)boolcodes; puts(*test);]])],[AC_DEFINE(HAVE_BOOLCODES) boolcodes=yes],[boolcodes=no])
+ AC_MSG_RESULT($boolcodes)
+
+ AC_MSG_CHECKING(if numcodes is available)
+- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = numcodes; puts(*test);]])],[AC_DEFINE(HAVE_NUMCODES) numcodes=yes],[numcodes=no])
++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)numcodes; puts(*test);]])],[AC_DEFINE(HAVE_NUMCODES) numcodes=yes],[numcodes=no])
+ AC_MSG_RESULT($numcodes)
+
+ AC_MSG_CHECKING(if strcodes is available)
+- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = strcodes; puts(*test);]])],[AC_DEFINE(HAVE_STRCODES) strcodes=yes],[strcodes=no])
++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)strcodes; puts(*test);]])],[AC_DEFINE(HAVE_STRCODES) strcodes=yes],[strcodes=no])
+ AC_MSG_RESULT($strcodes)
+
+ AC_MSG_CHECKING(if boolnames is available)
+- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = boolnames; puts(*test);]])],[AC_DEFINE(HAVE_BOOLNAMES) boolnames=yes],[boolnames=no])
++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)boolnames; puts(*test);]])],[AC_DEFINE(HAVE_BOOLNAMES) boolnames=yes],[boolnames=no])
+ AC_MSG_RESULT($boolnames)
+
+ AC_MSG_CHECKING(if numnames is available)
+- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = numnames; puts(*test);]])],[AC_DEFINE(HAVE_NUMNAMES) numnames=yes],[numnames=no])
++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)numnames; puts(*test);]])],[AC_DEFINE(HAVE_NUMNAMES) numnames=yes],[numnames=no])
+ AC_MSG_RESULT($numnames)
+
+ AC_MSG_CHECKING(if strnames is available)
+- AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = strnames; puts(*test);]])],[AC_DEFINE(HAVE_STRNAMES) strnames=yes],[strnames=no])
++ AC_LINK_IFELSE([AC_LANG_PROGRAM([[$term_includes]], [[char **test = (char **)strnames; puts(*test);]])],[AC_DEFINE(HAVE_STRNAMES) strnames=yes],[strnames=no])
+ AC_MSG_RESULT($strnames)
+
+ dnl There are apparently defective terminal library headers on some
diff --git a/app-shells/zsh/files/zsh-5.9-relro.patch b/app-shells/zsh/files/zsh-5.9-relro.patch
new file mode 100644
index 000000000000..7475c7cb85a6
--- /dev/null
+++ b/app-shells/zsh/files/zsh-5.9-relro.patch
@@ -0,0 +1,71 @@
+https://src.fedoraproject.org/rpms/zsh/blob/rawhide/f/0003-zsh-fix-module-loading-problem-with-full-RELRO.patch
+https://github.com/zsh-users/zsh/commit/a84fdd7c8f77935ecce99ff2b0bdba738821ed79
+
+From a84fdd7c8f77935ecce99ff2b0bdba738821ed79 Mon Sep 17 00:00:00 2001
+From: Jun-ichi Takimoto <takimoto-j@kba.biglobe.ne.jp>
+Date: Mon, 26 Jun 2023 17:13:04 +0900
+Subject: [PATCH] 51889: fix module loading problem with full RELRO
+
+If full RELRO (relocation read-only, one of the security enhancement
+methods for ELF-based systems) is used when building zsh (as in binary
+packages of most Linuxes), loading a module (e.g. zsh/zftp) fails unless
+all the modules it depends on are already loaded. With this patch the
+necessary modules are automatically loaded.
+
+Upstream-commit: a84fdd7c8f77935ecce99ff2b0bdba738821ed79
+Signed-off-by: Lukáš Zaoral <lzaoral@redhat.com>
+---
+ Src/Modules/zftp.c | 2 +-
+ Src/mkbltnmlst.sh | 24 ++++++++++++++++++++++++
+ 2 files changed, 25 insertions(+), 1 deletion(-)
+
+diff --git a/Src/Modules/zftp.c b/Src/Modules/zftp.c
+index 49b3ffa89..47a5e9de9 100644
+--- a/Src/Modules/zftp.c
++++ b/Src/Modules/zftp.c
+@@ -3172,7 +3172,7 @@ static struct features module_features = {
+ int
+ setup_(UNUSED(Module m))
+ {
+- return (require_module("zsh/net/tcp", NULL, 0) == 1);
++ return 0;
+ }
+
+ /**/
+diff --git a/Src/mkbltnmlst.sh b/Src/mkbltnmlst.sh
+index c4611d8b3..067ecdaf9 100644
+--- a/Src/mkbltnmlst.sh
++++ b/Src/mkbltnmlst.sh
+@@ -76,6 +76,30 @@ for x_mod in $x_mods; do
+ test "x$linked" = xno && echo "#endif"
+ done
+
++# if dynamic module 'mod' with load=no has moddeps in its .mdd,
++# then output add_dep(mod, dep) for each 'dep' in moddeps.
++dyn_mods="`grep ' link=dynamic .* load=no ' $CFMOD | \
++ sed -e '/^#/d' -e 's/ .*/ /' -e 's/^name=/ /'`"
++
++for mod in $dyn_mods; do
++ modfile="`grep '^name='$mod' ' $CFMOD | \
++ sed -e 's/^.* modfile=//' -e 's/ .*//'`"
++ if test "x$modfile" = x; then
++ echo >&2 "WARNING: no name for \`$mod' in $CFMOD (ignored)"
++ continue
++ fi
++ unset moddeps
++ . $srcdir/../$modfile
++ if test -n "$moddeps"; then
++ echo '#ifdef DYNAMIC'
++ echo "/* non-linked-in known module \`$mod' */"
++ for dep in $moddeps; do
++ echo " add_dep(\"$mod\", \"$dep\");"
++ done
++ echo '#endif'
++ fi
++done
++
+ echo
+ done_mods=" "
+ for bin_mod in $bin_mods; do
+--
+2.41.0
diff --git a/app-shells/zsh/zsh-5.9-r5.ebuild b/app-shells/zsh/zsh-5.9-r5.ebuild
new file mode 100644
index 000000000000..d81b45f6a42d
--- /dev/null
+++ b/app-shells/zsh/zsh-5.9-r5.ebuild
@@ -0,0 +1,245 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit autotools flag-o-matic prefix
+
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
+
+SRC_URI="https://www.zsh.org/pub/${P}.tar.xz
+ https://www.zsh.org/pub/old/${P}.tar.xz
+ mirror://sourceforge/${PN}/${P}.tar.xz
+ doc? (
+ https://www.zsh.org/pub/${P}-doc.tar.xz
+ mirror://sourceforge/${PN}/${P}-doc.tar.xz
+ )"
+
+DESCRIPTION="UNIX Shell similar to the Korn shell"
+HOMEPAGE="https://www.zsh.org/"
+
+LICENSE="ZSH gdbm? ( GPL-2 )"
+SLOT="0"
+IUSE="caps debug doc examples gdbm maildir pcre static valgrind"
+
+# Next release should use pcre2: https://github.com/zsh-users/zsh/commit/b62e911341c8ec7446378b477c47da4256053dc0
+RDEPEND="
+ >=sys-libs/ncurses-5.1:0=
+ static? ( >=sys-libs/ncurses-5.7-r4:0=[static-libs] )
+ caps? ( sys-libs/libcap )
+ pcre? (
+ >=dev-libs/libpcre-3.9
+ static? ( >=dev-libs/libpcre-3.9[static-libs] )
+ )
+ gdbm? (
+ sys-libs/gdbm:=
+ static? ( sys-libs/gdbm:=[static-libs] )
+ )
+"
+DEPEND="sys-apps/groff
+ valgrind? ( dev-util/valgrind )
+ ${RDEPEND}"
+PDEPEND="
+ examples? ( app-doc/zsh-lovers )
+"
+if [[ ${PV} == *9999 ]] ; then
+ DEPEND+=" app-text/yodl
+ doc? (
+ sys-apps/texinfo
+ app-text/texi2html
+ virtual/latex-base
+ )"
+fi
+
+PATCHES=(
+ # Add openrc specific options for init.d completion
+ "${FILESDIR}"/${PN}-5.3-init.d-gentoo.diff
+ # Please refer gentoo bug #833981
+ "${FILESDIR}"/${PN}-5.9-musl-V09datetime-test-fix.patch
+ # bug #869539
+ "${FILESDIR}"/${PN}-5.9-clang-15-configure.patch
+ "${FILESDIR}"/${PN}-5.9-do-not-use-egrep-in-tests.patch
+ # bug #919001
+ "${FILESDIR}"/${PN}-5.9-c99.patch
+ "${FILESDIR}"/${PN}-5.9-relro.patch
+)
+
+src_prepare() {
+ if [[ ${PV} != *9999 ]]; then
+ # fix zshall problem with soelim
+ ln -s Doc man1 || die
+ mv Doc/zshall.1 Doc/zshall.1.soelim || die
+ soelim Doc/zshall.1.soelim > Doc/zshall.1 || die
+ fi
+
+ default
+
+ hprefixify configure.ac
+ if [[ ${PV} == *9999 ]] ; then
+ sed -i "/^VERSION=/s@=.*@=${PV}@" Config/version.mk || die
+ fi
+ eautoreconf
+}
+
+src_configure() {
+ local myconf=(
+ --bindir="${EPREFIX}"/bin
+ --libdir="${EPREFIX}"/usr/$(get_libdir)
+ --enable-etcdir="${EPREFIX}"/etc/zsh
+ --enable-runhelpdir="${EPREFIX}"/usr/share/zsh/${PV%_*}/help
+ --enable-fndir="${EPREFIX}"/usr/share/zsh/${PV%_*}/functions
+ --enable-site-fndir="${EPREFIX}"/usr/share/zsh/site-functions
+ --enable-function-subdirs
+ --with-tcsetpgrp
+ --enable-multibyte
+ --with-term-lib='tinfow ncursesw'
+ $(use_enable maildir maildir-support)
+ $(use_enable pcre)
+ $(use_enable caps cap)
+ $(use_enable gdbm)
+ $(use_enable valgrind zsh-valgrind)
+ )
+
+ if use static ; then
+ myconf+=( --disable-dynamic )
+ append-ldflags -static
+ fi
+ if use debug ; then
+ myconf+=(
+ --enable-zsh-debug
+ --enable-zsh-mem-debug
+ --enable-zsh-mem-warning
+ --enable-zsh-secure-free
+ --enable-zsh-hash-debug
+ )
+ fi
+
+ if [[ ${CHOST} == *-darwin* ]]; then
+ myconf+=( --enable-libs=-liconv )
+ append-ldflags -Wl,-x
+ fi
+
+ econf "${myconf[@]}"
+
+ if use static ; then
+ # compile all modules statically, see Bug #27392
+ # removed cap and curses because linking failes
+ sed -e "s,link=no,link=static,g" \
+ -e "/^name=zsh\/cap/s,link=static,link=no," \
+ -e "/^name=zsh\/curses/s,link=static,link=no," \
+ -i "${S}"/config.modules || die
+ if ! use gdbm ; then
+ sed -i '/^name=zsh\/db\/gdbm/s,link=static,link=no,' \
+ "${S}"/config.modules || die
+ fi
+ fi
+}
+
+src_compile() {
+ default
+
+ if [[ ${PV} == *9999 ]] && use doc ; then
+ emake -C Doc everything
+ fi
+}
+
+src_test() {
+ # Fixes tests A03quoting.ztst B03print.ztst on musl
+ # Please refer:
+ # https://www.zsh.org/mla/workers/2021/msg00805.html
+ # Test E02xtrace fails on musl, so we are removing it.
+ # Closes: https://bugs.gentoo.org/833981
+ if use elibc_musl ; then
+ unset LC_ALL
+ unset LC_COLLATE
+ unset LC_NUMERIC
+ unset LC_MESSAGES
+ unset LANG
+ rm "${S}"/Test/E02xtrace.ztst || die
+ fi
+
+ # Breaks tests if inherited from environment.
+ unset TMPPREFIX
+
+ addpredict /dev/ptmx
+ local i
+ for i in C02cond.ztst V08zpty.ztst X02zlevi.ztst Y01completion.ztst Y02compmatch.ztst Y03arguments.ztst ; do
+ rm "${S}"/Test/${i} || die
+ done
+ emake check
+}
+
+src_install() {
+ emake DESTDIR="${D}" install $(usex doc "install.info" "")
+
+ insinto /etc/zsh
+ export PREFIX_QUOTE_CHAR='"' PREFIX_EXTRA_REGEX="/EUID/s,0,${EUID},"
+ newins "$(prefixify_ro "${FILESDIR}"/zprofile-4)" zprofile
+
+ keepdir /usr/share/zsh/site-functions
+ insinto /usr/share/zsh/${PV%_*}/functions/Prompts
+ newins "${FILESDIR}"/prompt_gentoo_setup-1 prompt_gentoo_setup
+
+ local i
+
+ # install miscellaneous scripts (bug #54520)
+ sed -e "s:/usr/local/bin/perl:${EPREFIX}/usr/bin/perl:g" \
+ -e "s:/usr/local/bin/zsh:${EPREFIX}/bin/zsh:g" \
+ -i {Util,Misc}/* || die
+ for i in Util Misc ; do
+ insinto /usr/share/zsh/${PV%_*}/${i}
+ doins ${i}/*
+ done
+
+ # install header files (bug #538684)
+ insinto /usr/include/zsh
+ doins config.h Src/*.epro
+ for i in Src/{zsh.mdh,*.h} ; do
+ sed -e 's@\.\./config\.h@config.h@' \
+ -e 's@#\(\s*\)include "\([^"]\+\)"@#\1include <zsh/\2>@' \
+ -i "${i}"
+ doins "${i}"
+ done
+
+ dodoc ChangeLog* META-FAQ NEWS README config.modules
+
+ if use doc ; then
+ pushd "${WORKDIR}/${PN}-${PV%_*}" >/dev/null
+ dodoc Doc/zsh.{dvi,pdf}
+ docinto html
+ dodoc Doc/*.html
+ popd >/dev/null
+ fi
+
+ docinto StartupFiles
+ dodoc StartupFiles/z*
+}
+
+pkg_postinst() {
+ if [[ -z ${REPLACING_VERSIONS} ]] ; then
+ echo
+ elog "If you want to enable Portage completions and Gentoo prompt,"
+ elog "emerge app-shells/gentoo-zsh-completions and add"
+ elog " autoload -U compinit promptinit"
+ elog " compinit"
+ elog " promptinit; prompt gentoo"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Also, if you want to enable cache for the completions, add"
+ elog " zstyle ':completion::complete:*' use-cache 1"
+ elog "to your ~/.zshrc"
+ echo
+ elog "Note that a system zprofile startup file is installed. This will override"
+ elog "PATH and possibly other variables that a user may set in ~/.zshenv."
+ elog "Custom PATH settings and similar overridden variables can be moved to ~/.zprofile"
+ elog "or other user startup files that are sourced after the system zprofile."
+ echo
+ elog "If PATH must be set in ~/.zshenv to affect things like non-login ssh shells,"
+ elog "one method is to use a separate path-setting file that is conditionally sourced"
+ elog "in ~/.zshenv and also sourced from ~/.zprofile. For more information, see the"
+ elog "zshenv example in ${EROOT}/usr/share/doc/${PF}/StartupFiles/."
+ echo
+ elog "See https://wiki.gentoo.org/wiki/Zsh/HOWTO for more introduction documentation."
+ echo
+ fi
+}
^ permalink raw reply related [flat|nested] 15+ messages in thread
end of thread, other threads:[~2023-12-16 7:44 UTC | newest]
Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-19 11:02 [gentoo-commits] repo/gentoo:master commit in: app-shells/zsh/files/, app-shells/zsh/ Lars Wendler
-- strict thread matches above, loose matches on Subject: below --
2023-12-16 7:44 Sam James
2023-03-12 12:33 Piotr Karbowski
2022-11-26 21:26 Piotr Karbowski
2022-09-12 20:08 Sam James
2022-09-01 2:06 Sam James
2022-05-02 8:41 Lars Wendler
2022-04-13 8:08 Lars Wendler
2022-02-18 13:43 Lars Wendler
2022-02-12 18:50 Lars Wendler
2019-12-12 9:21 Lars Wendler
2019-01-27 22:54 Lars Wendler
2018-11-30 8:04 Lars Wendler
2018-06-05 20:39 William Hubbs
2016-09-15 5:03 Tim Harder
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox