[oe-commits] org.oe.dev autotools.bbclass: Merge autotools_stage_all with changes in Poky. Removes a typo, adds libexec dir to staging list, works with cross.bbclass, removed info and man data which is pointless in staging and factors out repeated functionality into a separate function
rpurdie commit
oe at amethyst.openembedded.net
Thu Mar 20 11:01:13 UTC 2008
autotools.bbclass: Merge autotools_stage_all with changes in Poky. Removes a typo, adds libexec dir to staging list, works with cross.bbclass, removed info and man data which is pointless in staging and factors out repeated functionality into a separate function
Author: rpurdie at openembedded.org
Branch: org.openembedded.dev
Revision: 34ad27a72e617afd415764f7d661a12d78890e8c
ViewMTN: http://monotone.openembedded.org/revision/info/34ad27a72e617afd415764f7d661a12d78890e8c
Files:
1
classes/autotools.bbclass
classes/native.bbclass
Diffs:
#
# mt diff -r578f199bc6b531a09543f38044f98199ef5f49ad -r34ad27a72e617afd415764f7d661a12d78890e8c
#
#
#
# patch "classes/autotools.bbclass"
# from [d5a547cefa5e9958965f5dda7aac45f65e89d575]
# to [a03edf4667fb88b98d0f6ea62adcf75168d43bea]
#
# patch "classes/native.bbclass"
# from [ff9a8ed86294577afe2ec629e61b3d86ca2eec27]
# to [49b3ea484f76f2d16525a51fd376aab503da1e3b]
#
============================================================
--- classes/autotools.bbclass d5a547cefa5e9958965f5dda7aac45f65e89d575
+++ classes/autotools.bbclass a03edf4667fb88b98d0f6ea62adcf75168d43bea
@@ -165,6 +165,17 @@ autotools_stage_includes() {
fi
}
+autotools_stage_dir() {
+ from="$1"
+ to="$2"
+ # This will remove empty directories so we can ignore them
+ rmdir "$from" 2> /dev/null || true
+ if [ -d "$from" ]; then
+ mkdir -p "$to"
+ cp -fpPR -t "$to" "$from"/*
+ fi
+}
+
autotools_stage_all() {
if [ "${INHIBIT_AUTO_STAGE}" = "1" ]
then
@@ -173,9 +184,13 @@ autotools_stage_all() {
rm -rf ${STAGE_TEMP}
mkdir -p ${STAGE_TEMP}
oe_runmake DESTDIR="${STAGE_TEMP}" install
- if [ -d ${STAGE_TEMP}/${includedir} ]; then
- mkdir -p ${STAGING_INCDIR}
- cp -fpPR -t ${STAGING_INCDIR} ${STAGE_TEMP}/${includedir}/*
+ autotools_stage_dir ${STAGE_TEMP}/${includedir} ${STAGING_INCDIR}
+ if [ "${BUILD_SYS}" = "${HOST_SYS}" ]; then
+ autotools_stage_dir ${STAGE_TEMP}/${bindir} ${STAGING_DIR_HOST}${layout_bindir}
+ autotools_stage_dir ${STAGE_TEMP}/${sbindir} ${STAGING_DIR_HOST}${layout_sbindir}
+ autotools_stage_dir ${STAGE_TEMP}/${base_bindir} ${STAGING_DIR_HOST}${layout_base_bindir}
+ autotools_stage_dir ${STAGE_TEMP}/${base_sbindir} ${STAGING_DIR_HOST}${layout_base_sbindir}
+ autotools_stage_dir ${STAGE_TEMP}/${libexecdir} ${STAGING_DIR_HOST}${layout_libexecdir}
fi
if [ -d ${STAGE_TEMP}/${libdir} ]
then
@@ -200,41 +215,9 @@ autotools_stage_all() {
cp -fpPR ${STAGE_TEMP}/${libdir}/* ${STAGING_LIBDIR}
fi
fi
-
- #This will remove an empty directory so we can ignore it
- rmdir ${STAGE_TEMP}/${datadir} || true
- if [ -d ${STAGE_TEMP}/${datadir} ]; then
- install -d ${STAGING_DATADIR}/
- cp -fpPR ${STAGE_TEMP}/${datadir}/* ${STAGING_DATADIR}/
- fi
-
- if [ "${AUTOTOOLS_NATIVE_STAGE_BINARIES}" = "1" ] ; then
- #This will remove an empty directory so we can ignore it
- rmdir ${STAGE_TEMP}/${bindir} || true
- if [ -d ${STAGE_TEMP}/${bindir} ]; then
- mkdir -p ${STAGING_DIR_HOST}${layout_bindir}
- cp -fpPR -t ${STAGING_DIR_HOST}/${layout_bindir} ${STAGE_TEMP}/${bindir}/*
- fi
- #This will remove an empty directory so we can ignore it
- rmdir ${STAGE_TEMP}/${sbindir} || true
- if [ -d ${STAGE_TEMP}/${sbindir} ]; then
- mkdir -p ${STAGING_DIR_HOST}${layout_sbindir}
- cp -fpPR -t ${STAGING_DIR_HOST}/${layout_sbindir} ${STAGE_TEMP}/${sbindir}/*
- fi
- #This will remove an empty directory so we can ignore it
- rmdir ${STAGE_TEMP}/${base_bindir} || true
- if [ -d ${STAGE_TEMP}/${base_bindir} ]; then
- mkdir -p ${STAGING_DIR_HOST}${layout_base_bindir}
- cp -fpPR -t ${STAGING_DIR_HOST}/${layout_base_bindir} ${STAGE_TEMP}/${base_bindir}/*
- fi
- #This will remove an empty directory so we can ignore it
- rmdir ${STAGE_TEMP}/${base_sbindir} || true
- if [ -d ${STAGE_TEMP}/${base_sbindir} ]; then
- mkdir -p ${STAGING_DIR_HOST}${layout_base_sbindir}
- cp -fpPR -t ${STAGING_DIR_HOST}/${layout_nase_sbindir} ${STAGE_TEMP}/${base_sbindir}/*
- fi
-
- fi
+ rm -rf ${STAGE_TEMP}/${mandir} || true
+ rm -rf ${STAGE_TEMP}/${infodir} || true
+ autotools_stage_dir ${STAGE_TEMP}/${datadir} ${STAGING_DATADIR}
rm -rf ${STAGE_TEMP}
}
============================================================
--- classes/native.bbclass ff9a8ed86294577afe2ec629e61b3d86ca2eec27
+++ classes/native.bbclass 49b3ea484f76f2d16525a51fd376aab503da1e3b
@@ -80,7 +80,6 @@ do_stage () {
then
oe_runmake install
else
- export AUTOTOOLS_NATIVE_STAGE_BINARIES="1"
autotools_stage_all
fi
fi
More information about the Openembedded-commits
mailing list