diff options
Diffstat (limited to 'meta/classes/rootfs_rpm.bbclass')
-rw-r--r-- | meta/classes/rootfs_rpm.bbclass | 35 |
1 files changed, 18 insertions, 17 deletions
diff --git a/meta/classes/rootfs_rpm.bbclass b/meta/classes/rootfs_rpm.bbclass index cd9c5ab778..1cc4a84495 100644 --- a/meta/classes/rootfs_rpm.bbclass +++ b/meta/classes/rootfs_rpm.bbclass @@ -22,7 +22,7 @@ do_rootfs[depends] += "opkg-native:do_populate_sysroot" do_rootfs[recrdeptask] += "do_package_write_rpm" RPM_PREPROCESS_COMMANDS = "package_update_index_rpm; package_generate_rpm_conf; " -RPM_POSTPROCESS_COMMANDS = "rootfs_install_all_locales; " +RPM_POSTPROCESS_COMMANDS = "" # # Allow distributions to alter when [postponed] package install scripts are run @@ -56,6 +56,7 @@ fakeroot rootfs_rpm_do_rootfs () { export INSTALL_PACKAGES_LINGUAS_RPM="${LINGUAS_INSTALL}" export INSTALL_PROVIDENAME_RPM="" export INSTALL_TASK_RPM="rootfs_rpm_do_rootfs" + export INSTALL_COMPLEMENTARY_RPM="" # Setup base system configuration mkdir -p ${INSTALL_ROOTFS_RPM}/etc/rpm/ @@ -69,6 +70,8 @@ fakeroot rootfs_rpm_do_rootfs () { package_install_internal_rpm + rootfs_install_complementary + export D=${IMAGE_ROOTFS} export OFFLINE_ROOT=${IMAGE_ROOTFS} export IPKG_OFFLINE_ROOT=${IMAGE_ROOTFS} @@ -134,11 +137,15 @@ remove_packaging_data_files() { rm -rf ${IMAGE_ROOTFS}${opkglibdir} } -RPM_QUERY_CMD = '${RPM} --root ${IMAGE_ROOTFS} -D "_dbpath ${rpmlibdir}" \ +RPM_QUERY_CMD = '${RPM} --root $INSTALL_ROOTFS_RPM -D "_dbpath ${rpmlibdir}" \ -D "__dbi_txn create nofsync private"' list_installed_packages() { - ${RPM_QUERY_CMD} -qa --qf "[%{NAME}\n]" + if [ "$1" = "arch" ] ; then + ${RPM_QUERY_CMD} -qa --qf "[%{NAME} %{ARCH}\n]" + else + ${RPM_QUERY_CMD} -qa --qf "[%{NAME}\n]" + fi } get_package_filename() { @@ -172,21 +179,15 @@ list_package_recommends() { ${RPM_QUERY_CMD} -q --suggests $1 } -rootfs_check_package_exists() { - resolve_package_rpm ${RPMCONF_TARGET_BASE}-base_archs.conf $1 -} - rootfs_install_packages() { - # The pkg to be installed here is not controlled by the - # package_install_internal_rpm, so it may have already been - # installed(e.g, installed in the first time when generate the - # rootfs), use '--replacepkgs' to always install them - for pkg in $@; do - ${RPM} --root ${IMAGE_ROOTFS} -D "_dbpath ${rpmlibdir}" \ - -D "__dbi_txn create nofsync private" \ - --noscripts --notriggers --noparentdirs --nolinktos \ - --replacepkgs -Uhv $pkg || true - done + # Note - we expect the variables not set here to already have been set + export INSTALL_PACKAGES_RPM="" + export INSTALL_PACKAGES_ATTEMPTONLY_RPM="`cat $1`" + export INSTALL_PROVIDENAME_RPM="" + export INSTALL_TASK_RPM="rootfs_install_packages" + export INSTALL_COMPLEMENTARY_RPM="1" + + package_install_internal_rpm } python () { |