summaryrefslogtreecommitdiffstats
path: root/meta/classes
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2011-02-15 22:20:49 -0600
committerSaul Wold <sgw@linux.intel.com>2011-02-16 07:34:51 -0800
commitca649ef8253cbf69062322b5bdee4123ee4c4eca (patch)
treee6006e59ece4109391ddd09ad683bc28821cce5d /meta/classes
parent0e4aa13e9eef50533d8385b7fa638f33d4248e78 (diff)
downloadpoky-ca649ef8253cbf69062322b5bdee4123ee4c4eca.tar.gz
rpm: Add the ability to use the platform file during install
Add a new rpm macro, rpmrc_platform_path to specify an alternative platform file. This is required to allow the dep resolver to identify compatible packages. Also workaround a minor problem with the --showrc command in RPM. A bug has been reported upstream on this. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Diffstat (limited to 'meta/classes')
-rw-r--r--meta/classes/package_rpm.bbclass15
1 files changed, 10 insertions, 5 deletions
diff --git a/meta/classes/package_rpm.bbclass b/meta/classes/package_rpm.bbclass
index cc262dc831..215be8d607 100644
--- a/meta/classes/package_rpm.bbclass
+++ b/meta/classes/package_rpm.bbclass
@@ -219,7 +219,8 @@ package_install_internal_rpm () {
219 219
220 # Generate an install solution by doing a --justdb install, then recreate it with 220 # Generate an install solution by doing a --justdb install, then recreate it with
221 # an actual package install! 221 # an actual package install!
222 ${RPM} -D "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \ 222 ${RPM} --predefine "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \
223 --predefine "_rpmrc_platform_path ${target_rootfs}/etc/rpm/platform" \
223 -D "_dbpath ${target_rootfs}/install" -D "`cat ${confbase}.macro`" \ 224 -D "_dbpath ${target_rootfs}/install" -D "`cat ${confbase}.macro`" \
224 -D "__dbi_txn create nofsync" \ 225 -D "__dbi_txn create nofsync" \
225 -U --justdb --noscripts --notriggers --noparentdirs --nolinktos --ignoresize \ 226 -U --justdb --noscripts --notriggers --noparentdirs --nolinktos --ignoresize \
@@ -235,7 +236,8 @@ package_install_internal_rpm () {
235 exit 1 236 exit 1
236 fi 237 fi
237 echo "Attempting $pkg_name..." >> "${WORKDIR}/temp/log.do_${task}_attemptonly.${PID}" 238 echo "Attempting $pkg_name..." >> "${WORKDIR}/temp/log.do_${task}_attemptonly.${PID}"
238 ${RPM} -D "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \ 239 ${RPM} --predefine "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \
240 --predefine "_rpmrc_platform_path ${target_rootfs}/etc/rpm/platform" \
239 -D "_dbpath ${target_rootfs}/install" -D "`cat ${confbase}.macro`" \ 241 -D "_dbpath ${target_rootfs}/install" -D "`cat ${confbase}.macro`" \
240 -D "__dbi_txn create nofsync private" \ 242 -D "__dbi_txn create nofsync private" \
241 -U --justdb --noscripts --notriggers --noparentdirs --nolinktos --ignoresize \ 243 -U --justdb --noscripts --notriggers --noparentdirs --nolinktos --ignoresize \
@@ -254,7 +256,8 @@ package_install_internal_rpm () {
254 cat /dev/null > ${target_rootfs}/install/recommend.list 256 cat /dev/null > ${target_rootfs}/install/recommend.list
255 while [ $loop -eq 1 ]; do 257 while [ $loop -eq 1 ]; do
256 # Dump the full set of recommends... 258 # Dump the full set of recommends...
257 ${RPM} -D "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \ 259 ${RPM} --predefine "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \
260 --predefine "_rpmrc_platform_path ${target_rootfs}/etc/rpm/platform" \
258 -D "_dbpath ${IMAGE_ROOTFS}/install" -D "`cat ${confbase}.macro`" \ 261 -D "_dbpath ${IMAGE_ROOTFS}/install" -D "`cat ${confbase}.macro`" \
259 -D "__dbi_txn create nofsync private" \ 262 -D "__dbi_txn create nofsync private" \
260 -qa --qf "[%{RECOMMENDS}\n]" | sort -u > ${target_rootfs}/install/recommend 263 -qa --qf "[%{RECOMMENDS}\n]" | sort -u > ${target_rootfs}/install/recommend
@@ -273,7 +276,8 @@ package_install_internal_rpm () {
273 continue 276 continue
274 fi 277 fi
275 echo "Attempting $pkg_name..." >> "${WORKDIR}/temp/log.do_{task}_recommend.${PID}" 278 echo "Attempting $pkg_name..." >> "${WORKDIR}/temp/log.do_{task}_recommend.${PID}"
276 ${RPM} -D "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \ 279 ${RPM} --predefine "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \
280 --predefine "_rpmrc_platform_path ${target_rootfs}/etc/rpm/platform" \
277 -D "_dbpath ${target_rootfs}/install" -D "`cat ${confbase}.macro`" \ 281 -D "_dbpath ${target_rootfs}/install" -D "`cat ${confbase}.macro`" \
278 -D "__dbi_txn create nofsync private" \ 282 -D "__dbi_txn create nofsync private" \
279 -U --justdb --noscripts --notriggers --noparentdirs --nolinktos --ignoresize \ 283 -U --justdb --noscripts --notriggers --noparentdirs --nolinktos --ignoresize \
@@ -293,7 +297,8 @@ package_install_internal_rpm () {
293 297
294 # Attempt install 298 # Attempt install
295 ${RPM} --root ${target_rootfs} \ 299 ${RPM} --root ${target_rootfs} \
296 -D "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \ 300 --predefine "_rpmds_sysinfo_path ${target_rootfs}/etc/rpm/sysinfo" \
301 --predefine "_rpmrc_platform_path ${target_rootfs}/etc/rpm/platform" \
297 -D "_dbpath ${rpmlibdir}" \ 302 -D "_dbpath ${rpmlibdir}" \
298 --noscripts --notriggers --noparentdirs --nolinktos \ 303 --noscripts --notriggers --noparentdirs --nolinktos \
299 -D "__dbi_txn create nofsync private" \ 304 -D "__dbi_txn create nofsync private" \