Gentoo Archives: gentoo-commits

From: "Mike Frysinger (vapier)" <vapier@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in eclass: autotools.eclass
Date: Fri, 06 Jan 2012 21:06:27
Message-Id: 20120106210617.48C272004B@flycatcher.gentoo.org
1 vapier 12/01/06 21:06:17
2
3 Modified: autotools.eclass
4 Log:
5 add a helper for updating config.rpath files for projects that dont use gettext
6
7 Revision Changes Path
8 1.118 eclass/autotools.eclass
9
10 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/autotools.eclass?rev=1.118&view=markup
11 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/autotools.eclass?rev=1.118&content-type=text/plain
12 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/eclass/autotools.eclass?r1=1.117&r2=1.118
13
14 Index: autotools.eclass
15 ===================================================================
16 RCS file: /var/cvsroot/gentoo-x86/eclass/autotools.eclass,v
17 retrieving revision 1.117
18 retrieving revision 1.118
19 diff -u -r1.117 -r1.118
20 --- autotools.eclass 4 Jan 2012 22:00:27 -0000 1.117
21 +++ autotools.eclass 6 Jan 2012 21:06:17 -0000 1.118
22 @@ -1,6 +1,6 @@
23 # Copyright 1999-2011 Gentoo Foundation
24 # Distributed under the terms of the GNU General Public License v2
25 -# $Header: /var/cvsroot/gentoo-x86/eclass/autotools.eclass,v 1.117 2012/01/04 22:00:27 vapier Exp $
26 +# $Header: /var/cvsroot/gentoo-x86/eclass/autotools.eclass,v 1.118 2012/01/06 21:06:17 vapier Exp $
27
28 # @ECLASS: autotools.eclass
29 # @MAINTAINER:
30 @@ -297,6 +297,25 @@
31 autotools_run_tool autopoint "$@"
32 }
33
34 +# @FUNCTION: config_rpath_update
35 +# @USAGE: [destination]
36 +# @DESCRIPTION:
37 +# Some packages utilize the config.rpath helper script, but don't
38 +# use gettext directly. So we have to copy it in manually since
39 +# we can't let `autopoint` do it for us.
40 +config_rpath_update() {
41 + local dst src=$(type -P gettext | sed 's:bin/gettext:share/gettext/config.rpath:')
42 +
43 + [[ $# -eq 0 ]] && set -- $(find -name config.rpath)
44 + [[ $# -eq 0 ]] && return 0
45 +
46 + einfo "Updating all config.rpath files"
47 + for dst in "$@" ; do
48 + einfo " ${dst}"
49 + cp "${src}" "${dst}" || die
50 + done
51 +}
52 +
53 # Internal function to run an autotools' tool
54 autotools_env_setup() {
55 # We do the “latest” → version switch here because it solves