diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-09-17 11:33:49 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2013-09-17 14:35:16 +0100 |
commit | 641a80d760afd2c05804f2f7aaff98a2e18ad5d6 (patch) | |
tree | 3d0c2d956de1e3f13b05260f47abd9cc59e4c67d /meta | |
parent | 912e8d567262f5c3f67fd290a72813c1f9f9d86b (diff) | |
download | ast2050-yocto-poky-641a80d760afd2c05804f2f7aaff98a2e18ad5d6.zip ast2050-yocto-poky-641a80d760afd2c05804f2f7aaff98a2e18ad5d6.tar.gz |
autotools: Remove .la files if rebuilding non out of tree software
(From OE-Core rev: bcf83bb604906361db98003127b90c422e822322)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r-- | meta/classes/autotools.bbclass | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/meta/classes/autotools.bbclass b/meta/classes/autotools.bbclass index 4e4ef98..883eb06 100644 --- a/meta/classes/autotools.bbclass +++ b/meta/classes/autotools.bbclass @@ -108,10 +108,16 @@ CONFIGURESTAMPFILE = "${WORKDIR}/configure.sstate" autotools_preconfigure() { if [ -n "${CONFIGURESTAMPFILE}" -a -e "${CONFIGURESTAMPFILE}" ]; then - if [ "`cat ${CONFIGURESTAMPFILE}`" != "${BB_TASKHASH}" -a "${S}" != "${B}" ]; then - echo "Previously configured separate build directory detected, cleaning ${B}" - rm -rf ${B} - mkdir ${B} + if [ "`cat ${CONFIGURESTAMPFILE}`" != "${BB_TASKHASH}" ]; then + if [ "${S}" != "${B}" ]; then + echo "Previously configured separate build directory detected, cleaning ${B}" + rm -rf ${B} + mkdir ${B} + else + # At least remove the .la files since automake won't automatically + # regenerate them even if CFLAGS/LDFLAGS are different + cd ${S}; find ${S} -name \*.la -delete + fi fi fi } |