2008-08-25 20:53:13 +00:00
|
|
|
#
|
|
|
|
# Creates a root filesystem out of rpm packages
|
|
|
|
#
|
|
|
|
|
2017-02-13 14:44:48 +00:00
|
|
|
ROOTFS_PKGMANAGE = "rpm dnf"
|
2013-05-23 08:18:42 +00:00
|
|
|
ROOTFS_PKGMANAGE_BOOTSTRAP = "run-postinsts"
|
2011-07-07 16:39:32 +00:00
|
|
|
|
2017-02-13 14:44:48 +00:00
|
|
|
# dnf is using our custom distutils, and so will fail without these
|
|
|
|
export STAGING_INCDIR
|
|
|
|
export STAGING_LIBDIR
|
2011-07-07 16:39:32 +00:00
|
|
|
|
2017-02-13 14:44:48 +00:00
|
|
|
# Add 100Meg of extra space for dnf
|
|
|
|
IMAGE_ROOTFS_EXTRA_SPACE_append = "${@bb.utils.contains("PACKAGE_INSTALL", "dnf", " + 102400", "" ,d)}"
|
|
|
|
|
|
|
|
# Dnf is python based, so be sure python-native is available to us.
|
2012-11-29 15:43:16 +00:00
|
|
|
EXTRANATIVEPATH += "python-native"
|
|
|
|
|
2014-08-14 13:32:10 +00:00
|
|
|
# opkg is needed for update-alternatives
|
|
|
|
RPMROOTFSDEPENDS = "rpm-native:do_populate_sysroot \
|
2017-02-13 14:44:48 +00:00
|
|
|
dnf-native:do_populate_sysroot \
|
|
|
|
createrepo-c-native:do_populate_sysroot \
|
2014-08-14 13:32:10 +00:00
|
|
|
opkg-native:do_populate_sysroot"
|
2008-10-31 16:23:11 +00:00
|
|
|
|
2014-08-14 13:32:10 +00:00
|
|
|
do_rootfs[depends] += "${RPMROOTFSDEPENDS}"
|
|
|
|
do_populate_sdk[depends] += "${RPMROOTFSDEPENDS}"
|
2011-01-18 10:00:29 +00:00
|
|
|
|
2008-08-25 20:53:13 +00:00
|
|
|
do_rootfs[recrdeptask] += "do_package_write_rpm"
|
2014-02-27 20:20:38 +00:00
|
|
|
do_rootfs[vardeps] += "PACKAGE_FEED_URIS"
|
2008-08-25 20:53:13 +00:00
|
|
|
|
2008-10-07 16:47:22 +00:00
|
|
|
python () {
|
2016-12-14 21:13:04 +00:00
|
|
|
if d.getVar('BUILD_IMAGES_FROM_FEEDS'):
|
2016-12-14 21:13:06 +00:00
|
|
|
flags = d.getVarFlag('do_rootfs', 'recrdeptask')
|
2008-10-07 16:47:22 +00:00
|
|
|
flags = flags.replace("do_package_write_rpm", "")
|
|
|
|
flags = flags.replace("do_deploy", "")
|
2009-11-10 14:55:23 +00:00
|
|
|
flags = flags.replace("do_populate_sysroot", "")
|
Convert to use direct access to the data store (instead of bb.data.*Var*())
This is the result of running the following over the metadata:
sed \
-e 's:bb.data.\(setVar([^,()]*,[^,()]*\), *\([^ )]*\) *):\2.\1):g' \
-e 's:bb.data.\(setVarFlag([^,()]*,[^,()]*,[^,()]*\), *\([^) ]*\) *):\2.\1):g' \
-e 's:bb.data.\(getVar([^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \
-e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^(), ]*\) *,\([^)]*\)):\2.\1,\3):g' \
-e 's:bb.data.\(getVarFlag([^,()]*,[^,()]*\), *\([^() ]*\) *):\2.\1):g' \
-e 's:bb.data.\(getVar([^,()]*\), *\([^) ]*\) *):\2.\1):g' \
-i `grep -ril bb.data *`
(From OE-Core rev: b22831fd63164c4db9c0b72934d7d734a6585251)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-11-09 15:00:01 +00:00
|
|
|
d.setVarFlag('do_rootfs', 'recrdeptask', flags)
|
|
|
|
d.setVar('RPM_PREPROCESS_COMMANDS', '')
|
|
|
|
d.setVar('RPM_POSTPROCESS_COMMANDS', '')
|
2011-07-18 20:55:28 +00:00
|
|
|
|
2008-10-07 16:47:22 +00:00
|
|
|
}
|