Skip to contentSkip to conversation

automake.inc: bootstrap aclocal.

PATCH Superseded Graham Gower 1 participant 2 messages Dec 2, 2010

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 2/2 automake.inc: bootstrap aclocal.

Fixes problems seen with micro-uclibc.

NOTE: make -j 12
CDPATH="${ZSH_VERSION+.}:" && cd . && perllibdir="/mnt/oe/tmp/work/mipsel-oe-linux-uclibc/automake-1.11.1-r3.2/automake-1.11.1/lib:./lib" "/mnt/oe/tmp/work/mipsel-oe-linux-uclibc/automake-1.11.1-r3.2/automake-1.11.1/aclocal" --acdir=m4 -I m4 /bin/sh: /mnt/oe/tmp/work/mipsel-oe-linux-uclibc/automake-1.11.1-r3.2/automake-1.11.1/aclocal: No such file or directory
make: *** [aclocal.m4] Error 127
FATAL: oe_runmake failed

---
 recipes/automake/automake.inc |   31 ++++++++++++++++++++++++++++++-
 1 files changed, 30 insertions(+), 1 deletions(-)
recipes/automake/automake.inc +30 -1
index e378c04..743c140 100644
@@ -29,17 +29,46 @@ RDEPENDS_automake += "\
     perl-module-text-parsewords \
     perl-module-vars "
 SRC_URI = "${GNU_MIRROR}/automake/automake-${PV}.tar.bz2;name=automake"
-INC_PR = "r3"
+INC_PR = "r4"
 AUTOMAKE_API = "${@".".join(bb.data.getVar("PV",d,1).split(".")[0:2])}"
 
 inherit autotools
 
 FILES_${PN} += "${datadir}/automake* ${datadir}/aclocal*"
 
+dosubst () {
+	ver=`echo "${PV}" | sed -e 's/^\([[0-9]]*\.[[0-9]]*[[a-z]]*\).*$/\1/'`
+	rm -f $2
+	in=`echo $1 | sed 's,^.*/,,'`
+	sed -e "s%@APIVERSION@%${ver}%g" \
+		-e "s%@PACKAGE@%${PN}%g" \
+		-e "s%@PERL@%${STAGING_BINDIR_NATIVE}/perl%g" \
+		-e "s%@PERL_THREADS@%1%g" \
+		-e "s%@SHELL@%/bin/sh%g" \
+		-e "s%@VERSION@%${PV}%g" \
+		-e "s%@datadir@%${datadir}%g" \
+		-e "s%@PATH_SEPARATOR@%:%g" \
+		-e "s%@configure_input@%Generated from \$in.%g" \
+		$1 > $2
+	chmod 755 $2
+}
+
 do_configure_prepend () {
+
+	# See ${S}/bootstrap
+	dosubst lib/Automake/Config.in lib/Automake/Config.pm
+	dosubst aclocal.in aclocal
+	dosubst m4/amversion.in m4/amversion.m4
+	dosubst automake.in automake
+
 	if ${@['true', 'false'][bb.data.inherits_class('native', d)]}
 	then
 		export ac_cv_path_PERL="${ac_cv_path_PERL=${bindir}/perl}"
+
+		# Don't try to build the example (amhello), its ./configure
+		# is invoked incorrectly.
+		sed -i -e 's|dist_doc_DATA = .*$|dist_doc_DATA =|' \
+				${S}/doc/Makefile.am
 	fi
 }
 
Signature · 1 line
1.7.1
#1 lore raw
Quoted 29 lines · Graham Gower

Fixes problems seen with micro-uclibc.

NOTE: make -j 12
CDPATH="${ZSH_VERSION+.}:" && cd . && perllibdir="/mnt/oe/tmp/work/mipsel-oe-linux-uclibc/automake-1.11.1-r3.2/automake-1.11.1/lib:./lib" "/mnt/oe/tmp/work/mipsel-oe-linux-uclibc/automake-1.11.1-r3.2/automake-1.11.1/aclocal" --acdir=m4 -I m4 /bin/sh: /mnt/oe/tmp/work/mipsel-oe-linux-uclibc/automake-1.11.1-r3.2/automake-1.11.1/aclocal: No such file or directory
make: *** [aclocal.m4] Error 127
FATAL: oe_runmake failed

---
 recipes/automake/automake.inc |   31 ++++++++++++++++++++++++++++++-

 1 files changed, 30 insertions(+), 1 deletions(-)
recipes/automake/automake.inc +0 -0
index e378c04..743c140 100644
@@ -29,17 +29,46 @@ RDEPENDS_automake += "\
     perl-module-text-parsewords \

    perl-module-vars "
 SRC_URI = "${GNU_MIRROR}/automake/automake-${PV}.tar.bz2;name=automake"

recipes/automake/automake.inc +1 -1
-INC_PR = "r3"
+INC_PR = "r4"

 AUTOMAKE_API = "${@".".join(bb.data.getVar("PV",d,1).split(".")[0:2])}"

 inherit autotools

 FILES_${PN} += "${datadir}/automake* ${datadir}/aclocal*"

Quoted 7 lines

+dosubst () {
+       ver=echo "${PV}" | sed -e 's/^\([[0-9]]*\.[[0-9]]*[[a-z]]*\).*$/\1/'
+       rm -f $2
+       in=echo $1 | sed 's,^.*/,,'
+       sed -e "s%@APIVERSION@%${ver}%g" \
+               -e "s%@PACKAGE@%${PN}%g" \
+               -e "s%@PERL@%${STAGING_BINDIR_NATIVE}/perl%g" \

This appears to introduce problems when doing a from scratch build. Automake-native cannot find the perl binary. Adding perl-native to DEPENDS creates a circular dependency.

Not to mention a whole lot of shebang lines pointing to /mnt/oe/tmp/sysroots/x86_64-linux/bin/perl get inserted into the cross automake scripts.

Anyone else got a bright idea how to resolve this?

-Graham