summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm/rpm_git.bb
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/rpm/rpm_git.bb')
-rw-r--r--meta/recipes-devtools/rpm/rpm_git.bb108
1 files changed, 108 insertions, 0 deletions
diff --git a/meta/recipes-devtools/rpm/rpm_git.bb b/meta/recipes-devtools/rpm/rpm_git.bb
new file mode 100644
index 0000000000..22a4e71a80
--- /dev/null
+++ b/meta/recipes-devtools/rpm/rpm_git.bb
@@ -0,0 +1,108 @@
1SUMMARY = "The RPM package management system"
2DESCRIPTION = "The RPM Package Manager (RPM) is a powerful command line driven \
3package management system capable of installing, uninstalling, \
4verifying, querying, and updating software packages. Each software \
5package consists of an archive of files along with information about \
6the package like its version, a description, etc."
7
8SUMMARY_${PN}-dev = "Development files for manipulating RPM packages"
9DESCRIPTION_${PN}-dev = "This package contains the RPM C library and header files. These \
10development files will simplify the process of writing programs that \
11manipulate RPM packages and databases. These files are intended to \
12simplify the process of creating graphical package managers or any \
13other tools that need an intimate knowledge of RPM packages in order \
14to function."
15
16SUMMARY_python-rpm = "Python bindings for apps which will manupulate RPM packages"
17DESCRIPTION_python-rpm = "The rpm-python package contains a module that permits applications \
18written in the Python programming language to use the interface \
19supplied by the RPM Package Manager libraries."
20
21HOMEPAGE = "http://www.rpm.org"
22
23# libraries are also LGPL - how to express this?
24LICENSE = "GPL-2.0"
25LIC_FILES_CHKSUM = "file://COPYING;md5=f5259151d26ff18e78023450a5ac8d96"
26
27SRC_URI = "git://github.com/rpm-software-management/rpm \
28 file://0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch \
29 file://0001-Do-not-read-config-files-from-HOME.patch \
30 file://0001-When-cross-installing-execute-package-scriptlets-wit.patch \
31 file://0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch \
32 file://0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch \
33 file://0001-When-nice-value-cannot-be-reset-issue-a-notice-inste.patch \
34 file://0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch \
35 file://0001-Fix-build-with-musl-C-library.patch \
36 file://0001-Add-a-color-setting-for-mips64_n32-binaries.patch \
37 "
38
39PV = "4.13.90+git${SRCPV}"
40PE = "1"
41SRCREV = "a8e51b3bb05c6acb1d9b2e3d34f859ddda1677be"
42
43S = "${WORKDIR}/git"
44
45DEPENDS = "nss libarchive db file popt xz dbus elfutils python"
46DEPENDS_append_class-native = " file-replacement-native"
47
48inherit autotools gettext pkgconfig pythonnative
49
50# OE-core patches autoreconf to additionally run gnu-configize, which fails with this recipe
51EXTRA_AUTORECONF_append = " --exclude=gnu-configize"
52
53EXTRA_OECONF_append = " --without-lua --enable-python"
54EXTRA_OECONF_append_libc-musl = " --disable-nls"
55
56# --sysconfdir prevents rpm from attempting to access machine-specific configuration in sysroot/etc; we need to have it in rootfs
57#
58# --localstatedir prevents rpm from writing its database to native sysroot when building images
59#
60# Also disable plugins, so that rpm doesn't attempt to inhibit shutdown via session dbus
61EXTRA_OECONF_append_class-native = " --sysconfdir=/etc --localstatedir=/var --disable-plugins"
62
63BBCLASSEXTEND = "native"
64
65# Direct rpm-native to read configuration from our sysroot, not the one it was compiled in
66# libmagic also has sysroot path contamination, so override it
67do_install_append_class-native() {
68 create_wrapper ${D}/${bindir}/rpmbuild \
69 RPM_CONFIGDIR=${STAGING_LIBDIR_NATIVE}/rpm \
70 RPM_ETCCONFIGDIR=${STAGING_DIR_NATIVE} \
71 MAGIC=${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc \
72 RPM_NO_CHROOT_FOR_SCRIPTS=1
73
74 create_wrapper ${D}/${bindir}/rpmsign \
75 RPM_CONFIGDIR=${STAGING_LIBDIR_NATIVE}/rpm \
76 RPM_ETCCONFIGDIR=${STAGING_DIR_NATIVE} \
77 MAGIC=${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc \
78 RPM_NO_CHROOT_FOR_SCRIPTS=1
79
80 create_wrapper ${D}/${bindir}/rpmkeys \
81 RPM_CONFIGDIR=${STAGING_LIBDIR_NATIVE}/rpm \
82 RPM_ETCCONFIGDIR=${STAGING_DIR_NATIVE} \
83 MAGIC=${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc \
84 RPM_NO_CHROOT_FOR_SCRIPTS=1
85
86 create_wrapper ${D}/${bindir}/rpm \
87 RPM_CONFIGDIR=${STAGING_LIBDIR_NATIVE}/rpm \
88 RPM_ETCCONFIGDIR=${STAGING_DIR_NATIVE} \
89 MAGIC=${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc \
90 RPM_NO_CHROOT_FOR_SCRIPTS=1
91}
92
93
94# Rpm's make install creates var/tmp which clashes with base-files packaging
95do_install_append_class-target() {
96 rm -rf ${D}/var
97}
98
99FILES_${PN} += "${libdir}/rpm-plugins/*.so \
100 "
101
102FILES_${PN}-dev += "${libdir}/rpm-plugins/*.la \
103 "
104
105PACKAGES += "python-rpm"
106PROVIDES += "python-rpm"
107FILES_python-rpm = "${PYTHON_SITEPACKAGES_DIR}/rpm/*"
108