more random patches. who knows.
[patches.git] / autotools.eclass.patch
1 Index: autotools.eclass
2 ===================================================================
3 RCS file: /var/cvsroot/gentoo-x86/eclass/autotools.eclass,v
4 retrieving revision 1.56
5 diff -u -p -r1.56 autotools.eclass
6 --- autotools.eclass 1 Nov 2006 10:58:46 -0000 1.56
7 +++ autotools.eclass 4 Nov 2006 10:13:05 -0000
8 @@ -20,6 +20,8 @@ if [[ -n ${WANT_AUTOMAKE} ]]; then
9 latest) _automake_atom="|| ( =sys-devel/automake-1.10* =sys-devel/automake-1.9* )" ;;
10 *) _automake_atom="=sys-devel/automake-${WANT_AUTOMAKE}*" ;;
11 esac
12 + [[ ${WANT_AUTOMAKE} == "latest" ]] && WANT_AUTOMAKE="1.10:1.9"
13 + export WANT_AUTOMAKE
14 fi
15
16 if [[ -n ${WANT_AUTOCONF} ]] ; then
17 @@ -27,6 +29,8 @@ if [[ -n ${WANT_AUTOCONF} ]] ; then
18 2.1) _autoconf_atom="=sys-devel/autoconf-${WANT_AUTOCONF}*" ;;
19 latest | 2.5) _autoconf_atom=">=sys-devel/autoconf-2.59" ;;
20 esac
21 + [[ ${WANT_AUTOCONF} == "latest" ]] && WANT_AUTOCONF="2.5"
22 + export WANT_AUTOCONF
23 fi
24 DEPEND="${_automake_atom}
25 ${_autoconf_atom}
26 @@ -116,7 +120,6 @@ eaclocal() {
27 done
28 fi
29
30 - autotools_set_versions
31 [[ ! -f aclocal.m4 || -n $(grep -e 'generated.*by aclocal' aclocal.m4) ]] && \
32 autotools_run_tool aclocal "$@" ${aclocal_opts}
33 }
34 @@ -142,7 +145,6 @@ _elibtoolize() {
35 eautoheader() {
36 # Check if we should run autoheader
37 [[ -n $(autotools_check_macro "AC_CONFIG_HEADERS") ]] || return 0
38 - autotools_set_versions
39 autotools_run_tool autoheader "$@"
40 }
41
42 @@ -154,7 +156,6 @@ eautoconf() {
43 die "No configure.{ac,in} present!"
44 fi
45
46 - autotools_set_versions
47 autotools_run_tool autoconf "$@"
48 }
49
50 @@ -163,7 +164,6 @@ eautomake() {
51
52 [[ -f Makefile.am ]] || return 0
53
54 - autotools_set_versions
55 if [[ -z ${FROM_EAUTORECONF} && -f Makefile.in ]]; then
56 local used_automake
57 local installed_automake
58 @@ -188,35 +188,6 @@ eautomake() {
59 autotools_run_tool automake --add-missing --copy ${extra_opts} "$@"
60 }
61
62 -autotools_set_versions() {
63 - [[ -n ${autotools_version_sets} ]] && return 0
64 -
65 - if [[ -n ${WANT_AUTOCONF} ]]; then
66 - [[ ${WANT_AUTOCONF} == "latest" ]] && WANT_AUTOCONF="2.5"
67 - export WANT_AUTOCONF
68 - einfo "Requested autoconf ${WANT_AUTOCONF}"
69 - einfo "Using $(autoconf --version 2>/dev/null | head -n 1)"
70 - einfo "Using $(autoheader --version 2>/dev/null | head -n 1)"
71 - fi
72 -
73 - if [[ -n ${WANT_AUTOMAKE} ]]; then
74 - local latest_automake
75 - if [[ ${WANT_AUTOMAKE} == "latest" ]]; then
76 - latest_automake="latest: "
77 - for amver in 1.10 1.9 1.8 1.7 1.6; do
78 - WANT_AUTOMAKE="${amver}"
79 - ROOT=/ has_version =sys-devel/automake-${amver}* && break
80 - done
81 - fi
82 - export WANT_AUTOMAKE
83 - einfo "Requested automake ${latest_automake}${WANT_AUTOMAKE}"
84 - einfo "Using $(automake --version 2>/dev/null | head -n 1)"
85 - einfo "Using $(aclocal --version 2>/dev/null | head -n 1)"
86 - fi
87 -
88 - autotools_version_sets="yes"
89 -}
90 -
91 # Internal function to run an autotools' tool
92 autotools_run_tool() {
93 local STDERR_TARGET="${T}/$$.out"