From de0c24161e6a2e4bdf83040268064b0b65df28c4 Mon Sep 17 00:00:00 2001 From: Fabian Groffen Date: Sun, 26 Jan 2020 09:45:00 +0100 Subject: app-shells/tcsh-6.21.00-r1: fix compilation with GCC 10/-fno-common Closes: https://bugs.gentoo.org/706316 Package-Manager: Portage-2.3.84, Repoman-2.3.20 Signed-off-by: Fabian Groffen --- .../tcsh/files/tcsh-6.21.00-fno-common.patch | 22 +++++ app-shells/tcsh/tcsh-6.21.00-r1.ebuild | 103 +++++++++++++++++++++ app-shells/tcsh/tcsh-6.21.00.ebuild | 102 -------------------- 3 files changed, 125 insertions(+), 102 deletions(-) create mode 100644 app-shells/tcsh/files/tcsh-6.21.00-fno-common.patch create mode 100644 app-shells/tcsh/tcsh-6.21.00-r1.ebuild delete mode 100644 app-shells/tcsh/tcsh-6.21.00.ebuild (limited to 'app-shells/tcsh') diff --git a/app-shells/tcsh/files/tcsh-6.21.00-fno-common.patch b/app-shells/tcsh/files/tcsh-6.21.00-fno-common.patch new file mode 100644 index 000000000000..b5a0cf0600a0 --- /dev/null +++ b/app-shells/tcsh/files/tcsh-6.21.00-fno-common.patch @@ -0,0 +1,22 @@ +From 6974bc35a5cda6eab748e364bd76a860ca66968b Mon Sep 17 00:00:00 2001 +From: zoulasc +Date: Sat, 11 Jan 2020 11:16:51 -0500 +Subject: [PATCH] Remove extra variable definition that cause -fno-common build + to fail (Werner Fink) + +--- + tc.sig.c | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/tc.sig.c b/tc.sig.c +index 77659ca..576605a 100644 +--- a/tc.sig.c ++++ b/tc.sig.c +@@ -56,7 +56,6 @@ int alrmcatch_disabled; /* = 0; */ + int phup_disabled; /* = 0; */ + int pchild_disabled; /* = 0; */ + int pintr_disabled; /* = 0; */ +-int handle_interrupt; /* = 0; */ + + int + handle_pending_signals(void) diff --git a/app-shells/tcsh/tcsh-6.21.00-r1.ebuild b/app-shells/tcsh/tcsh-6.21.00-r1.ebuild new file mode 100644 index 000000000000..8adadc2e6cc4 --- /dev/null +++ b/app-shells/tcsh/tcsh-6.21.00-r1.ebuild @@ -0,0 +1,103 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=6 + +inherit eutils flag-o-matic autotools prefix + +CONFVER="1.9" + +DESCRIPTION="Enhanced version of the Berkeley C shell (csh)" +HOMEPAGE="http://www.tcsh.org/" +SRC_URI=" + ftp://ftp.astron.com/pub/tcsh/${P}.tar.gz + https://dev.gentoo.org/~grobian/distfiles/tcsh-gentoo-patches-r${CONFVER}.tar.bz2" + +LICENSE="BSD" +SLOT="0" +KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" +IUSE="nls doc" +RESTRICT="test" + +# we need gettext because we run autoconf (AM_ICONV) +RDEPEND=" + >=sys-libs/ncurses-5.1:0= + virtual/libiconv" +DEPEND="${RDEPEND} + sys-devel/gettext + doc? ( dev-lang/perl )" + +CONFDIR=${WORKDIR}/tcsh-gentoo-patches-r${CONFVER} + +PATCHES=( + "${FILESDIR}"/${PN}-6.20.00-debian-dircolors.patch # bug #120792 + "${FILESDIR}"/${PN}-6.18.01-aix.patch + "${FILESDIR}"/${PN}-6.21.00-no-nls.patch + "${FILESDIR}"/${PN}-6.21.00-use-ncurses.patch + "${FILESDIR}"/${PN}-6.21.00-fno-common.patch # upstream +) + +src_prepare() { + epatch "${PATCHES[@]}" + + eautoreconf + + # fix gencat usage + sed \ + -e 's/cat \$\^ \$> | \$(GENCAT) \$@/rm -f $@; $(GENCAT) $@ $> $^/' \ + -i nls/Makefile.in || die + + # use sysmalloc (for larger alloc sets) on Darwin also + sed -i -e 's/__MACHTEN__/__MACH__/' config_f.h || die + + # unify ECHO behaviour + echo "#undef ECHO_STYLE" >> config_f.h + echo "#define ECHO_STYLE BOTH_ECHO" >> config_f.h + + eprefixify "${CONFDIR}"/* + # activate the right default PATH + if [[ -z ${EPREFIX} ]] ; then + sed -i \ + -e 's/^#MAIN//' -e '/^#PREFIX/d' \ + "${CONFDIR}"/csh.login || die + else + sed -i \ + -e 's/^#PREFIX//' -e '/^#MAIN/d' \ + "${CONFDIR}"/csh.login || die + fi + + eapply_user +} + +src_configure() { + # make tcsh look and live along the lines of the prefix + append-cppflags -D_PATH_DOTCSHRC="'"'"${EPREFIX}/etc/csh.cshrc"'"'" + append-cppflags -D_PATH_DOTLOGIN="'"'"${EPREFIX}/etc/csh.login"'"'" + append-cppflags -D_PATH_DOTLOGOUT="'"'"${EPREFIX}/etc/csh.logout"'"'" + append-cppflags -D_PATH_USRBIN="'"'"${EPREFIX}/usr/bin"'"'" + append-cppflags -D_PATH_BIN="'"'"${EPREFIX}/bin"'"'" + + econf \ + --prefix="${EPREFIX:-}" \ + --datarootdir='${prefix}/usr/share' \ + $(use_enable nls) +} + +src_install() { + emake DESTDIR="${D}" install install.man + + DOCS=( FAQ Fixes NewThings Ported README.md WishList Y2K ) + if use doc ; then + perl tcsh.man2html tcsh.man || die + HTML_DOCS=( tcsh.html/*.html ) + fi + einstalldocs + + insinto /etc + doins \ + "${CONFDIR}"/csh.cshrc \ + "${CONFDIR}"/csh.login + + # bug #119703: add csh -> tcsh symlink + dosym tcsh /bin/csh +} diff --git a/app-shells/tcsh/tcsh-6.21.00.ebuild b/app-shells/tcsh/tcsh-6.21.00.ebuild deleted file mode 100644 index 8085148f47f9..000000000000 --- a/app-shells/tcsh/tcsh-6.21.00.ebuild +++ /dev/null @@ -1,102 +0,0 @@ -# Copyright 1999-2019 Gentoo Authors -# Distributed under the terms of the GNU General Public License v2 - -EAPI=6 - -inherit eutils flag-o-matic autotools prefix - -CONFVER="1.9" - -DESCRIPTION="Enhanced version of the Berkeley C shell (csh)" -HOMEPAGE="http://www.tcsh.org/" -SRC_URI=" - ftp://ftp.astron.com/pub/tcsh/${P}.tar.gz - https://dev.gentoo.org/~grobian/distfiles/tcsh-gentoo-patches-r${CONFVER}.tar.bz2" - -LICENSE="BSD" -SLOT="0" -KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86 ~ppc-aix ~x64-cygwin ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~sparc64-solaris ~x64-solaris ~x86-solaris" -IUSE="nls doc" -RESTRICT="test" - -# we need gettext because we run autoconf (AM_ICONV) -RDEPEND=" - >=sys-libs/ncurses-5.1:0= - virtual/libiconv" -DEPEND="${RDEPEND} - sys-devel/gettext - doc? ( dev-lang/perl )" - -CONFDIR=${WORKDIR}/tcsh-gentoo-patches-r${CONFVER} - -PATCHES=( - "${FILESDIR}"/${PN}-6.20.00-debian-dircolors.patch # bug #120792 - "${FILESDIR}"/${PN}-6.18.01-aix.patch - "${FILESDIR}"/${PN}-6.21.00-no-nls.patch - "${FILESDIR}"/${PN}-6.21.00-use-ncurses.patch -) - -src_prepare() { - epatch "${PATCHES[@]}" - - eautoreconf - - # fix gencat usage - sed \ - -e 's/cat \$\^ \$> | \$(GENCAT) \$@/rm -f $@; $(GENCAT) $@ $> $^/' \ - -i nls/Makefile.in || die - - # use sysmalloc (for larger alloc sets) on Darwin also - sed -i -e 's/__MACHTEN__/__MACH__/' config_f.h || die - - # unify ECHO behaviour - echo "#undef ECHO_STYLE" >> config_f.h - echo "#define ECHO_STYLE BOTH_ECHO" >> config_f.h - - eprefixify "${CONFDIR}"/* - # activate the right default PATH - if [[ -z ${EPREFIX} ]] ; then - sed -i \ - -e 's/^#MAIN//' -e '/^#PREFIX/d' \ - "${CONFDIR}"/csh.login || die - else - sed -i \ - -e 's/^#PREFIX//' -e '/^#MAIN/d' \ - "${CONFDIR}"/csh.login || die - fi - - eapply_user -} - -src_configure() { - # make tcsh look and live along the lines of the prefix - append-cppflags -D_PATH_DOTCSHRC="'"'"${EPREFIX}/etc/csh.cshrc"'"'" - append-cppflags -D_PATH_DOTLOGIN="'"'"${EPREFIX}/etc/csh.login"'"'" - append-cppflags -D_PATH_DOTLOGOUT="'"'"${EPREFIX}/etc/csh.logout"'"'" - append-cppflags -D_PATH_USRBIN="'"'"${EPREFIX}/usr/bin"'"'" - append-cppflags -D_PATH_BIN="'"'"${EPREFIX}/bin"'"'" - - econf \ - --prefix="${EPREFIX:-}" \ - --datarootdir='${prefix}/usr/share' \ - $(use_enable nls) -} - -src_install() { - emake DESTDIR="${D}" install install.man - - DOCS=( FAQ Fixes NewThings Ported README.md WishList Y2K ) - if use doc ; then - perl tcsh.man2html tcsh.man || die - HTML_DOCS=( tcsh.html/*.html ) - fi - einstalldocs - - insinto /etc - doins \ - "${CONFDIR}"/csh.cshrc \ - "${CONFDIR}"/csh.login - - # bug #119703: add csh -> tcsh symlink - dosym tcsh /bin/csh -} -- cgit v1.2.3-65-gdbad