1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
8 DESCRIPTION="Used to generate Makefile.in from Makefile.am"
9 HOMEPAGE="https://www.gnu.org/software/automake/"
10 SRC_URI="mirror://gnu/${PN}/${P}.tar.bz2"
13 # Use Gentoo versioning for slotting.
15 KEYWORDS="~alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sparc x86"
18 RDEPEND="dev-lang/perl
19 >=sys-devel/automake-wrapper-10
20 >=sys-devel/autoconf-2.69
25 export WANT_AUTOCONF=2.5
26 epatch "${FILESDIR}"/${PN}-1.8.2-infopage-namechange.patch
27 epatch "${FILESDIR}"/${P}-test-fixes.patch #159557
28 epatch "${FILESDIR}"/${PN}-1.9.6-aclocal7-test-sleep.patch #197366
29 epatch "${FILESDIR}"/${PN}-1.9.6-subst-test.patch #222225
30 epatch "${FILESDIR}"/${PN}-1.10-ccnoco-ldflags.patch #203914
31 epatch "${FILESDIR}"/${P}-CVE-2009-4029.patch #295357
32 epatch "${FILESDIR}"/${PN}-1.8-perl-5.11.patch
35 # slot the info pages. do this w/out munging the source so we don't have
36 # to depend on texinfo to regen things. #464146 (among others)
38 pushd "${ED}"/usr/share/info >/dev/null
41 # Rewrite all the references to other pages.
42 # before: * aclocal-invocation: (automake)aclocal Invocation. Generating aclocal.m4.
43 # after: * aclocal-invocation v1.13: (automake-1.13)aclocal Invocation. Generating aclocal.m4.
44 local p pages=( *.info ) args=()
45 for p in "${pages[@]/%.info}" ; do
47 -e "/START-INFO-DIR-ENTRY/,/END-INFO-DIR-ENTRY/s|: (${p})| v${SLOT}&|"
48 -e "s:(${p}):(${p}-${SLOT}):g"
51 sed -i "${args[@]}" * || die
53 # Rewrite all the file references, and rename them in the process.
56 d=${f/.info/-${SLOT}.info}
57 mv "${f}" "${d}" || die
58 sed -i -e "s:${f}:${d}:g" * || die
67 rm -f "${ED}"/usr/bin/{aclocal,automake}
69 # remove all config.guess and config.sub files replacing them
70 # w/a symlink to a specific gnuconfig version
72 for x in guess sub ; do
73 dosym ../gnuconfig/config.${x} /usr/share/${PN}-${SLOT}/config.${x}