aboutsummaryrefslogtreecommitdiffstats
path: root/classes
diff options
context:
space:
mode:
authorGraeme Gregory <dp@xora.org.uk>2008-03-20 12:24:54 +0000
committerGraeme Gregory <dp@xora.org.uk>2008-03-20 12:24:54 +0000
commit878425ebbfd687f787069e033aa65db93b440a84 (patch)
treee434e280fe7b3a0c3b0999cce5db3ad23ddb7858 /classes
parent9c644c69de2a38f7f308b84ca40f634a04705c8b (diff)
parent23de7a3b28cdf268b1cd5c9d25445244e55f62b2 (diff)
downloadopenembedded-878425ebbfd687f787069e033aa65db93b440a84.tar.gz
openembedded-878425ebbfd687f787069e033aa65db93b440a84.tar.bz2
openembedded-878425ebbfd687f787069e033aa65db93b440a84.zip
merge of '25b9e259d256dba0e7e78b122b1880331d820762'
and '776dc04c7eba19512692b4d40a123d45e6adb862'
Diffstat (limited to 'classes')
-rw-r--r--classes/autotools.bbclass59
-rw-r--r--classes/native.bbclass1
-rw-r--r--classes/package.bbclass3
3 files changed, 23 insertions, 40 deletions
diff --git a/classes/autotools.bbclass b/classes/autotools.bbclass
index a535b046e3..1f03825b92 100644
--- a/classes/autotools.bbclass
+++ b/classes/autotools.bbclass
@@ -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}
}
diff --git a/classes/native.bbclass b/classes/native.bbclass
index 43c71e16cf..4022cb09c0 100644
--- a/classes/native.bbclass
+++ b/classes/native.bbclass
@@ -80,7 +80,6 @@ do_stage () {
then
oe_runmake install
else
- export AUTOTOOLS_NATIVE_STAGE_BINARIES="1"
autotools_stage_all
fi
fi
diff --git a/classes/package.bbclass b/classes/package.bbclass
index 3177965b18..eb43856c55 100644
--- a/classes/package.bbclass
+++ b/classes/package.bbclass
@@ -490,6 +490,8 @@ python emit_pkgdata() {
for pkg in packages.split():
subdata_file = pkgdatadir + "/runtime/%s" % pkg
sf = open(subdata_file, 'w')
+ write_if_exists(sf, pkg, 'PN')
+ write_if_exists(sf, pkg, 'PR')
write_if_exists(sf, pkg, 'DESCRIPTION')
write_if_exists(sf, pkg, 'RDEPENDS')
write_if_exists(sf, pkg, 'RPROVIDES')
@@ -497,7 +499,6 @@ python emit_pkgdata() {
write_if_exists(sf, pkg, 'RSUGGESTS')
write_if_exists(sf, pkg, 'RREPLACES')
write_if_exists(sf, pkg, 'RCONFLICTS')
- write_if_exists(sf, pkg, 'PR')
write_if_exists(sf, pkg, 'PKG')
write_if_exists(sf, pkg, 'ALLOW_EMPTY')
write_if_exists(sf, pkg, 'FILES')