summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm/rpm
diff options
context:
space:
mode:
authorMark Hatle <mark.hatle@windriver.com>2012-10-04 13:54:13 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2012-11-18 16:42:02 +0000
commit4dd9d39dca1221792f963f7fa74da0d0221f12ef (patch)
treea447bfb51becc4c41c51535be7999cfe58eb97e6 /meta/recipes-devtools/rpm/rpm
parent9e0d3c0faa9cc80ce8f2ce0eb31dcd20ef875955 (diff)
downloadast2050-yocto-poky-4dd9d39dca1221792f963f7fa74da0d0221f12ef.zip
ast2050-yocto-poky-4dd9d39dca1221792f963f7fa74da0d0221f12ef.tar.gz
rpm: Slightly change the way python-rpm is constructed
If python support is enabled we want to make sure that the RPM python support is packaged properly. Move the components into the site-packages directory, move the .la files to a new -dev package. Add "rpm" as a dependency of python-rpm, otherwise rpm and the associated libraries won't be available. Fixup python wrapper to handle automatic relocation, as supported by the vendor WINDRIVER configuration. (Based on a patch from Paul Eggleton) (From OE-Core rev: cd0473a145cec51be736b6141b0b18a82b64d483) Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/rpm/rpm')
-rw-r--r--meta/recipes-devtools/rpm/rpm/rpm-py-init.patch27
1 files changed, 27 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rpm/rpm/rpm-py-init.patch b/meta/recipes-devtools/rpm/rpm/rpm-py-init.patch
new file mode 100644
index 0000000..b65abc2
--- /dev/null
+++ b/meta/recipes-devtools/rpm/rpm/rpm-py-init.patch
@@ -0,0 +1,27 @@
+python/rpmmodules.c: Change the way the python module loads the RPM config
+
+In order to support the RPM_VENDOR_WINDRIVER enhancement of dynamic
+runtime relocation paths, we need to call rpmcliInit instead of
+rpmReadConfigFiles. The rpmcliInit will end up calling rpmReadConfigFiles
+after the necessary relocation processing (if enabled).
+
+Code derived from changes suggested by Paul Eggleton.
+
+Upstream-Status: Pending
+
+Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
+
+diff --git a/python/rpmmodule.c b/python/rpmmodule.c
+index f7282bc..dde68ca 100644
+--- a/python/rpmmodule.c
++++ b/python/rpmmodule.c
+@@ -392,7 +392,8 @@ void init_rpm(void)
+ if (Py_AtExit(rpm_exithook) == -1)
+ return;
+
+- rpmReadConfigFiles(NULL, NULL);
++ const char *argv[1] = {"rpmmodule", 0};
++ rpmcliInit(1, argv, NULL);
+
+ d = PyModule_GetDict(m);
+
OpenPOWER on IntegriCloud