aboutsummaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/rpm
AgeCommit message (Collapse)Author
2016-12-16meta: remove True option to getVar callsJoshua Lock
getVar() now defaults to expanding by default, thus remove the True option from getVar() calls with a regex search and replace. Search made with the following regex: getVar ?\(( ?[^,()]*), True\) Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-23rpm: fix multilib macro installationChen Qi
For now, the rpm macro for multilib is not installed correctly. For example, in x86-64 lib32 situation, the macro is installed under tmp/work/x86-pokymllib32-linux/rpm/5.4.16-r0/image/usr/lib/rpm/poky/i686-linux/. The directory is even not under WORKDIR. And it will of course not be packaged. We need to save necessary values before updating the localdata and restore them so that the macros could be installed into the correct directory. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-11-06rpm: fix file location of rpm2cpio.realChen Qi
rpm2cpio is in ${PN}-common, but rpm2cpio.real is in ${PN}. This seperation is really weird. Put them both in ${PN}-common. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-10-15rpm: prevent race in tempdir creationMarkus Lehtonen
This patch fixes an extramely rare race condition in creation of rpmdb temporary directory. The "rpmdb-more-verbose-error-logging" patch is still left in place, just for the case. [YOCTO #9416] Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-09-13rpm: remove redundant removalsRoss Burton
These were noticed by the use of bashisms (rm *.{foo,bar}) and lots of these rm commands are deleting files which don't exist in the first place. Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-09-13rpm: manually cleanup sysckJérémy Rosen
version 5.4.1 of rpm was not properly distclean before release, which causes problems when cross-compiling. The previous version this recipe called make distclean, but that would trigger a call to ./configure which would fail when no gcc is available and make the whole do_configure fail further down the line This patch manually removes the files from the recipe. Signed-off-by: Jérémy Rosen <jeremy.rosen@smile.fr> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-09-06rpm: ensure rpm2cpio call rpm relocation codeZhixiong Chi
We need to call rpmcliInit to ensure the rpm relocation code is called. when we allow rpm2cpio to be relocatable, The adjusted path used to find the macro files was being built into the binary and this path was valid for the machine it was built on and some of our other build machines, but invalid on some others, and was not being properly overridden at runtime. when we export the wrsdk and source the sdk, then execute rpm2cpio xxx.rpm|cpio -t. we will get the following error : "rpm-5.4.14/rpmdb/dbconfig.c:493: db3New: Assertion `dbOpts != ((void *)0) && *dbOpts != '\0'' failed. Signed-off-by: Zhixiong Chi <Zhixiong.Chi@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-08-17Use PYTHON_SITEPACKAGES_DIR insted of hard-coded *site-packages*Ming Liu
For thoese recipes that are inheriting python*-dir.bbclass, there is already a PYTHON_SITEPACKAGES_DIR present, use that definition replacing redundant "${libdir}/python*/site-packages". Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-08-04meta: add more missing patch tagsRoss Burton
Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-07-25rpm: make --nosignature workRobert Yang
OE-core uses rpm's --nosignature, but it never worked: self._invoke_smart('config --set rpm-check-signatures=false') Now fix it with: * Define SUPPORT_NOSIGNATURES to 1 in system.h * !QVA_ISSET(qva->qva_flags, SIGNATURE) -> QVA_ISSET(qva->qva_flags, SIGNATURE), otherwise, when use --nosignature would read database and verify signature, this is not expected. This can fix some race issues, for example, when more than one process are querying rpm file with "rpm -qp --nosignature", they may hang up because of race issues (the processes are trying to get RW/RD lock on the database, but they shouldn't read the database at all since -qp and --nosignature are used). Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-07-20rpm: remove CVS-based recipeRoss Burton
This recipe doesn't really get used or maintained, and as the sole recipe in oe-core that uses the CVS fetcher it's removal means we don't need to list CVS as a host dependency. Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-05-30default-versions.inc: drop python-related defaultsAlexander Kanavin
There is only one version of python 2.x provided, so no need to set a preferred version. PYTHON_BASEVERSION is now set explicitly in python-dir.bbclass and python3-dir.bbclass, so fix up a few recipes that relied on it being set in default-versions.inc without inheriting python-dir. Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com>
2016-05-13rpm: Fix build with gcc6Khem Raj
Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-04-29rpm: explicitly disable tomcryptAndreas Oberritter
Configure autodetects libtomcrypt, but then it adds libtommath to $LIBS and fails to link subsequent tests if it's unavailable. | checking for pcre.h... yes | checking for pcre_compile in -lpcre... no | checking whether to build with PCRE library... no | ++ executing failure action | configure: error: unable to find usable PCRE library Signed-off-by: Andreas Oberritter <obi@opendreambox.org> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-04-18rpm: Disable __sync_add_and_fetch_8 on nios2Marek Vasut
The NIOS2 softcore does not implement the __sync_add_and_fetch_8, so disable it accordingly. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Ley Foon Tan <lftan@altera.com> Cc: Richard Purdie <richard.purdie@linuxfoundation.org> Cc: Ross Burton <ross.burton@intel.com> Cc: Thomas Chou <thomas@wytron.com.tw> Cc: Walter Goossens <waltergoossens@home.nl> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-04-14rpm: more verbose errors in rpmTempFileMarkus Lehtonen
This patch adds better error logging inside the rpm tempfile function in order to be able to better analyze a rare and very hard-to-reproduce failure in oe-selftest for rpm signing. [YOCTO #9416] Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-04-08rpm: brace expansion is a bashismRoss Burton
The constuct rm *.{a,la} is a bashism and as tasks are run under /bin/sh this may not work as expected. Expand the {a,la} to two separate calls, and remove the architecture-specific macro deletion as they are not installed in the first place anymore. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-04-06rpm: remove two unused patchRobert Yang
They are already in the source: rpm-CVE-2013-6435.patch rpm-CVE-2014-8118.patch Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-23rpm: check _gpg_passphrase before ask for inputRobert Yang
rpm always asked for pass phrasae when add signature, which made it can't work non-interactively, this patch fix the problem. It will work non-interactively if _gpg_passphrase is defined, and work as before if not. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-20rpm: remove RPM 4Joshua Lock
RPM4 support is buggy and incomplete. As we don't have the resources or interest to maintain it this patch removes it. Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-03-20rpm: fix error when 'lua' is enabledChen Qi
Fix the following compilation error when 'lua' is enabled in PACKAGECONFIG. | gcc: error: lib21.c: No such file or directory | gcc: fatal error: no input files Modify FILES for dev package to avoid installed-not-shipped error. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-03-10rpm: Sync CVS to regular versionMark Hatle
A previous fix for a python dep issue was not merged to the CVS version. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-10rpm: Fix musl integration with RPM5Mark Hatle
Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-03-09rpmresolve: It is not necessary to manually specify -lpoptMark Hatle
Popt may be internal or external to rpm. Either way the rpm libraries will link properly with or without -lpopt. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
2016-03-09rpm: A number of the patches have been submitted upstreamMark Hatle
Note the upstream submission in the patches. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
2016-03-09rpm: Enable specific crypto and digest settings via variablesMark Hatle
Allow the user to set the specific digest and non-repudiable signature algorithms. This should be done on a distribution wide basis. See recipe for exact instructions, but values are now set using: RPM_FILE_DIGEST_ALGO (default 1 - md5) RPM_SELF_SIGN_ALGO (default DSA) Also, change the PACKAGECONFIG to define the default crypto engine for RPM5. Not just the available crypto engines. If a crypto engine is not selected, the system will default to the internal beecrypt version. Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
2016-03-09rpm: Uprev to rpm-5.4.16 (pre) and rpm-5.4+cvs to current CVS headMark Hatle
meta/lib/oe/package_manager.py was also updated. This ensures that any diagnostic messages are ignored from the output of rpmresolve. The patches have been split into bug fixes (things that belong upstream) and local changes that are OE specific. The following patches are obsolete and have been removed: rpm-remove-sykcparse-decl.patch fstack-protector-configure-check.patch rpm-disable-Wno-override-init.patch rpm-lua-fix-print.patch rpm-rpmpgp-fix.patch verify-fix-broken-logic-for-ghost-avoidance-Mark-Hat.patch Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
2016-02-22rpm: fix building rpm 5 with internal beecryptJoshua Lock
RPM 5 cannot be built without beecrypt, therefore the EXTRA_OECONF arguments to pass when the beecrypt PACKAGECONFIG is disabled should enable the internal/bundled beecrypt. [YOCTO #9150] Signed-off-by: Joshua Lock <joshua.g.lock@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-02-15rpm: Fix build with muslKhem Raj
Signed-off-by: Khem Raj <raj.khem@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-25Revert "xz: Allow to work with ASSUME_PROVIDED xz-native"Richard Purdie
This reverts commit 5c69c561a76cb10d7896ae0a0399190f11b2e0ca. The change was incomplete, not handling cases such as the fetcher using xz, or linux-yocto, dpkg or apt or the lzma image type. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-23xz: Allow to work with ASSUME_PROVIDED xz-nativeRichard Purdie
At some point we may want to add xz-native to ASSUME_PROVIDED. This allows that to work whilst still allowing access to liblzma for those things which need it (e.g. pixz). Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-19rpm: remove bashisms: [ x == x ] -> [ x = x ]Olof Johansson
The postinst and postrm of rpm contained a bashism, that could in some situations potentially cause ldconfig not be triggered when it should be. If you use dash on host, test would fail because of syntax errors. But on host, it should fail because of the comparison. On target, you often use busybox ash, and it supports == as an alias for =. So in practice, only if you use a shell like dash on target, you'll run into issues with this. Signed-off-by: Olof Johansson <olofjn@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2016-01-11Add "CVE:" tag to current patches in OE-coreMariano Lopez
The currnet patches in OE-core doesn't have the "CVE:" tag, now part of the policy of the patches. This is patch add this tag to several patches. There might be patches that I miss; the tag can be added in the future. Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2016-01-11rpmresolve.c: Fix unfreed pointers that keep DB openedMariano Lopez
There are some unfreed rpmmi pointers in printDepList() function; this happens when the package have null as the requirement. This patch fixes these unfreed pointers and add small changes to keep consistency with some variables. [YOCTO #8028] Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-12-27rpm: Generate per distribution and multilib macro filesMark Hatle
The distribution and multilib macro files are required for rpmbuild, on the target, to work properly. These override the default settings from the upstream macro files with the proper values for the OE configuration. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-12-22rpm: Fix support for db5 and db6Yuanjie Huang
The previous attempt to let rpm configuration support both db5 and db6 has a flaw that when the building host provides db6 without its header the db_create test will false pass. This new patch addresses this issue by test against the DB_VERSION_MAJOR macro value, which is defined in both db5 and db6's header. Signed-off-by: Yuanjie Huang <Yuanjie.Huang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-12-16meta: more removals of redunant FILES_${PN}-dbgRoss Burton
In some recipes overly-split -dbg packages were merged into PN-dbg. Unless there's a very good reason, recipes should have a single -dev and -dbg package. Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-12-16meta: Drop now pointless manual -dbg packagingRichard Purdie
With the autodebug package generation logic, specifically setting FILES_${PN}-dbg isn't needed in most cases, we can remove them. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-12-12rpm: fix file conflicts for MIPS64 N32Robert Yang
The following error can occur: smart install libc6-2.22-r0.1@lib32_mips32r2octeon3 libc6-dbg-2.22-r0.1@lib32_mips32r2octeon3 error: file /sbin/ldconfig conflicts between attempted installs of libc6-2.22-r0.1.lib32_mips32r2octeon3 and libc6-2.22-r0.1.octeon3_n32 error: file /sbin/.debug/ldconfig conflicts between attempted installs of libc6-dbg-2.22-r0.1.lib32_mips32r2octeon3 and libc6-dbg-2.22-r0.1.octeon3_n32 This was because: transactions_color = 001 (ELF32) & 010 (ELF64) & 100 (ELF32 N32 MIPS64) FColor = Current file color (001) & transaction_color (111) oFcolor = Previous file color (100) & transaction_color (111) There are two places where the conflict comparisons occur. In both places the 'else' clause was too restrictive (opposite of the 'positive' clause). This caused the system to only permit a binary comparison - "new preferred" or "old preferred". It did not permissing "neither preferred". By removing the else comparison the system will now perform a 'last-in-wins' resolution when "neither is preferred". Note, if _transaction_color is 3, MIPS64 N32 will be skipped (pretend as installed). Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-12-12rpm: Enable MIPS64 N32 transactionsMark Hatle
In a multilib install RPM will break a conflict using the transaction color. However, by default MIPS64 N32 transactions are not enabled. This change always enables them. This is effectively a no-op on non-MIPS systems, and required if we need to support N32 on MIPS. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-12-08package_regex.inc: split the rest of the entries to their recipesAlexander Kanavin
Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-12-01rpm: fix for N32 MIPS64Robert Yang
It is 'N32 MIPS64', not 'N32 MIPS32' as command file shows: $ file image/usr/bin/getent getent: ELF 32-bit MSB executable, MIPS, N32 MIPS64 [snip] And "rpm -qp --filecolor" was wrong (it was 1, but should be 4), which caused multilib installation error. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-11-16rpm: define EM_AARCH64 for debugeditRoy Li
EM_AARCH64 maybe not be defined due to old version elf.h when compile rpm-native, and lead to that debugedit can not work on aarch64 elf object files, since there is no other dependence, except these two macro, define them to make debugedit work on aarch64 elf files. debugedit: /bitbake_build/tmp/work/aarch64-wrs-linux/libvirt/1.2.19-r0/ package/usr/lib64/libvirt/ptest/daemon/libvirtd_admin_la-admin_server.o: Unhandled relocation 258 in .debug_info section Signed-off-by: Roy Li <rongqing.li@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-10-24rpm: add explicit dependency on file-replacement-native for native buildsRoss Burton
2015-10-21rpm: remove spurious build dependenciesRoss Burton
make, patch and binutils are assumed to exist on the host, so there's no need to have them in DEPENDS and can result in the building of make-native for no good reason. Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-10-07rpm: fix return without value in patchRoss Burton
The error patch in rpm-check-rootpath-reasonableness.patch did a bare return from a function that should be returning an int. As this is the error path, return -1 instead. Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-09-28rpm: search for gpg if gpg2 is not foundMarkus Lehtonen
Some (host) systems only have a binary named 'gpg' (e.g. Fedora) while some only have 'gpg2' (Ubuntu) and others have both of them (openSUSE). Currently the behavior of rpm-native with regards to GnuPG depends on the host platform: rpm(-native) is configured to use GnuPG binary of the host system if 'gpg2' is found in $PATH. Otherwise, rpm(-native) will default to using '%{_bindir}/gpg2' which will be pointing to a sysroot binary which usually does not exist. This patch changes rpm to look for both 'gpg' and 'gpg2' when searching for the GnuPG binary in PATH. This makes possible to create signed RPM packages on different host platforms, using the GnuPG binary of the host, without the need to explicitly define the gpg binary in bitbake configuration (via GPG_BIN variable). [YOCTO #8134] Signed-off-by: Markus Lehtonen <markus.lehtonen@linux.intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
2015-09-12meta: Fix Upstream-Status statementsRoss Burton
Fix a variety of problems such as typos, bad punctuations, or incorrect Upstream-Status values. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-08-31upstream_tracking.inc: deprecate and move contents to recipesAlexander Kanavin
No-update reasons and manual version checks should be in the recipes themselves because otherwise they're prone to getting out of date. Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2015-08-19rpm: opendb before rpmverifyscript to avoid null point inputZhixiong Chi
If the command is "rpm -V" and the return value of (headerIsEntry(h, RPMTAG_VERIFYSCRIPT) || headerIsEntry(h, RPMTAG_SANITYCHECK)) located in /lib/verify.c is true, it will call rpmpsmStage function(rpmVerifyScript->rpmpsmScriptStage->rpmpsmStage) and occur segment fault because of null point(rpmtsGetRdb(ts) == NULL and rpmtsGetRdb(ts)->db_txn). So we open rpmdb to avoid bad input when find headerIsEntry true. workflow: main()->rpmcliVerify()->rpmcliArgIter()->rpmQueryVerify()->rpmgiShowMatches()->showVerifyPackage()-> rpmqv.c verify.c query.c query.c verify.c(headerIsEntry) rpmVerifyScript()->rpmpsmScriptStage()->rpmpsmStage()-> rpmtxnCommit(rpmtsGetRdb(ts)->db_txn); verify.c psm.c psm.c psm.c Signed-off-by: Zhixiong Chi <zhixiong.chi@windriver.com> Signed-off-by: Ross Burton <ross.burton@intel.com>