diff options
| -rw-r--r-- | meta-oe/classes/autotools-bootstrap.bbclass | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/meta-oe/classes/autotools-bootstrap.bbclass b/meta-oe/classes/autotools-bootstrap.bbclass new file mode 100644 index 0000000000..8d7af1b472 --- /dev/null +++ b/meta-oe/classes/autotools-bootstrap.bbclass | |||
| @@ -0,0 +1,24 @@ | |||
| 1 | # Class to inherit when you want to build with autotools after running bootstrap | ||
| 2 | inherit autotools | ||
| 3 | |||
| 4 | DEPENDS += "gnulib" | ||
| 5 | |||
| 6 | do_configure_prepend() { | ||
| 7 | currdir=`pwd` | ||
| 8 | cd ${S} | ||
| 9 | |||
| 10 | # avoid bootstrap cloning gnulib on every configure | ||
| 11 | cat >.gitmodules <<EOF | ||
| 12 | [submodule "gnulib"] | ||
| 13 | path = gnulib | ||
| 14 | url = git://git.sv.gnu.org/gnulib | ||
| 15 | EOF | ||
| 16 | cp -rf ${STAGING_DATADIR}/gnulib ${S} | ||
| 17 | |||
| 18 | # --force to avoid errors on reconfigure e.g if recipes changed we depend on | ||
| 19 | # | bootstrap: running: libtoolize --quiet | ||
| 20 | # | libtoolize: error: 'libltdl/COPYING.LIB' exists: use '--force' to overwrite | ||
| 21 | # | ... | ||
| 22 | ./bootstrap --force | ||
| 23 | cd $currdir | ||
| 24 | } | ||
