diff options
author | Koen Kooi <koen@openembedded.org> | 2008-03-19 20:17:40 +0000 |
---|---|---|
committer | Koen Kooi <koen@openembedded.org> | 2008-03-19 20:17:40 +0000 |
commit | e0c07ebd9158c035921040c1641fb7f80427a895 (patch) | |
tree | 8b7c077b3acbae1f7b6b014b527b4ce6b5660524 /classes | |
parent | f1204894470e72800bcb7654ba5d346066fd6a1a (diff) |
native, autotools bbclass: check if bindir exists before trying to access it
* hardcoded since native.bbclass redefines ${bindir} and friends :(
Diffstat (limited to 'classes')
-rw-r--r-- | classes/autotools.bbclass | 19 | ||||
-rw-r--r-- | classes/native.bbclass | 2 |
2 files changed, 16 insertions, 5 deletions
diff --git a/classes/autotools.bbclass b/classes/autotools.bbclass index ae9b108279..5ef8814259 100644 --- a/classes/autotools.bbclass +++ b/classes/autotools.bbclass @@ -205,10 +205,21 @@ autotools_stage_all() { cp -fpPR ${STAGE_TEMP}/${datadir}/aclocal/* ${STAGING_DATADIR}/aclocal fi - if [ "${AUTOTOOLS_NATIVE_STAGE_BINARIES}" = "1"] ; then - install -d ${STAGING_BINDIR_NATIVE} - cp -fpPR ${STAGE_TEMP}/*bin/* ${STAGING_BINDIR_NATIVE}/ - cp -fpPR ${STAGE_TEMP}/usr/*bin/* ${STAGING_BINDIR_NATIVE}/ + if [ "${AUTOTOOLS_NATIVE_STAGE_BINARIES}" = "1" ] ; then + if [ -d ${STAGE_TEMP}/bin ]; then + cp -fpPR ${STAGE_TEMP}/bin/*${STAGING_DIR_HOST}/${layout_bindir} + fi + + if [ -d ${STAGE_TEMP}/sbin ]; then + cp -fpPR ${STAGE_TEMP}/sbin/* ${STAGING_DIR_HOST}/${layout_bindir} + fi + + if [ -d ${STAGE_TEMP}/usr/bin ]; then + cp -fpPR ${STAGE_TEMP}/usr/bin/* ${STAGING_DIR_HOST}/${layout_bindir} + fi + if [ -d ${STAGE_TEMP}/usr/sbin ]; then + cp -fpPR ${STAGE_TEMP}/usr/sbin/* ${STAGING_DIR_HOST}/${layout_bindir} + fi fi rm -rf ${STAGE_TEMP} } diff --git a/classes/native.bbclass b/classes/native.bbclass index aa1d4b6510..ec9ca6bef3 100644 --- a/classes/native.bbclass +++ b/classes/native.bbclass @@ -80,7 +80,7 @@ do_stage () { then oe_runmake install else - AUTOTOOLS_NATIVE_STAGE_BINARIES = "1" + export AUTOTOOLS_NATIVE_STAGE_BINARIES="1" autotools_stage_all fi fi |