]> code.ossystems Code Review - openembedded-core.git/commitdiff
package_rpm.bbclass: Set tmppath for rpm to somewhere which won't conflict with the...
authorRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 12 Apr 2012 20:16:41 +0000 (20:16 +0000)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 12 Apr 2012 20:24:55 +0000 (21:24 +0100)
If the rootfs has a specific layout in mind for /var/tmp, it should be
free to create this. Preinst scripts trigger rpm to create its tmppath
directory which could potentially conflict with this.

We're seeing issues if the provider of the /var/tmp wants to use a symlink
and a preinst script executes before it has been installed. This change
places tmppath as used by rpm somewhere safe which is already automatically
cleaned up too.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
meta/classes/package_rpm.bbclass

index fd00fb13e7ab234ef35be4acc72a8dc69490b803..ffe3b312ff664234751083f7de5f86e7d43e30af 100644 (file)
@@ -158,6 +158,7 @@ rpm_common_comand () {
         --predefine "_rpmrc_platform_path ${target_rootfs}/etc/rpm/platform" \
         -D "_var ${localstatedir}" \
         -D "_dbpath ${rpmlibdir}" \
+        -D "_tmppath /install/tmp" \
         --noparentdirs --nolinktos \
         -D "__dbi_txn create nofsync private" \
         -D "_cross_scriptlet_wrapper ${WORKDIR}/scriptlet_wrapper" $@