aboutsummaryrefslogtreecommitdiffstats
path: root/meta/classes/package_rpm.bbclass
AgeCommit message (Collapse)Author
2013-09-13bitbake.conf/package: Collapse PKGDATA_DIR into a single machine specific ↵Richard Purdie
directory Currently we have a hierarchy of pkgdata directories and the code has to put together a search path and look through each in turn until it finds the data it needs. This has lead to a number of hardcoded paths and file globing which is unpredictable and undesirable. Worse, certain tricks that should be easy like a GL specific package architecture become problematic with the curretn search paths. With the modern sstate code, we can do better and construct a single pkgdata directory for each machine in just the same way as we do for the sysroot. This is already tried and well tested. With such a single directory, all the code that iterated through multiple pkgdata directories and simply be removed and give a significant simplification of the code. Even existing build directories adapt to the change well since the package contents doesn't change, just the location they're installed to and the stamp for them. The only complication is the we need a different shlibs directory for each multilib. These are only used by package.bbclass and the simple fix is to add MLPREFIX to the shlib directory name. This means the multilib packages will repackage and the sstate checksum will change but an existing build directory will adapt to the changes safely. It is close to release however I believe the benefits this patch give us are worth consideration for inclusion and give us more options for dealing with problems like the GL one. It also sets the ground work well for shlibs improvements in 1.6. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-11classes/package_rpm: remove unsed outdir variableStefan Stanacar
Not only outdir had the wrong value, it wasn't used actually used in that function. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-11python-smartpm: Add an attempt install modeMark Hatle
[ YOCTO #3723 ] Add a mode to smart that will allow an installation to continue, instead of failure in the case that one or more items is uninstallable. Uninstallable packages are simply ignored, and no error is generated. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-06package_rpm.bbclass: Fix no_recommendations and package_excludeMark Hatle
When the code was refactored to address review comments, the wrong version was sent to the community. Replace the $1 with ${target_rootfs} Fix identified by: Yue Tao <yue.tao@windriver.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-01meta: Don't use deprecated bitbake APIRichard Purdie
These have been deprecated for a long time, convert the remaining references to the correct modules and prepare for removal of the compatibility support from bitbake. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-22package_rpm.bbclass: NO_RECOMMENDATIONS supportMark Hatle
Add NO_RECOMMENDATIONS support. A way to disable all recommended packages from being installed. This will help shrink the size of the resulting filesystem. Add documentation on NO_RECOMMENDATIONS and BAD_RECOMMENDATIONS. Note, using NO_RECOMMENDATIONS has side effects such that kernel-modules may not have been installed. A user will need to manually add to their image any kernel-modules required to be on the image for functionality. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-08-22package_rpm.bbclass: Add support for PACKAGE_EXCLUDE to RPM installsMark Hatle
Using the new smart exclude mechanism an error will be generated in the excluded package is required for the image to be generated. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-08-16classes/buildhistory: record size of installed package not compressed archiveMartin Jansa
* usually it's more important to know how much space will each package take on target device then size of compressed package * example for libewebkit0 with 4 different architectures, interesting that om_gta02 .ipk is bigger but it's smaller when installed before: MACHINE DEFAULTTUNE SIZE (.ipk file) om_gta04 cortexa8t-neon 15996 KiB libewebkit0 qemux86_64 x86-64 16992 KiB libewebkit0 spitz xscale 16148 KiB libewebkit0 om_gta02 arm920t 16260 KiB libewebkit0 after: MACHINE DEFAULTTUNE SIZE (installed) om_gta04 cortexa8t-neon 60544 KiB libewebkit0 qemux86_64 x86-64 63720 KiB libewebkit0 spitz xscale 60588 KiB libewebkit0 om_gta02 arm920t 56268 KiB libewebkit0 Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-07-27classes/rootfs_rpm: implement BAD_RECOMMENDATIONS for RPMPaul Eggleton
Add support for the BAD_RECOMMENDATIONS variable that can be used to prevent specific packages from being installed via an RRECOMMENDS relationship when using the RPM backend. (Previously this functionality was only available when using ipk packaging.) In the process this moves the defaulting of BAD_RECOMMENDATIONS (as empty) to bitbake.conf since it is no longer specific to the ipk backend, as well as unifying some of the code that creates the configuration for smart for use on the host and target. Fixes [YOCTO #3916]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-07-12package_rpm.bbclass: remove xx.spec before doing rpmbuild xx.src.rpmBian Naimeng
If the spec file already exist, and has not been stored into pseudo's files.db, it maybe cause rpmbuild src.rpm fail, so remove it before doing rpmbuild src.rpm. Signed-off-by: Bian Naimeng <biannm@cn.fujitsu.com>
2013-07-09package_rpm.bbclass: make DESCRIPTION support newlineRobert Yang
The recipe's DESCRIPTION is wrapped automatically by textwrap, make it support newline ("\n") to let the user can wrap it manually, e.g.: DESCRIPTION = "Foo1\nFoo2" In the past, it would be: Foo1\nFoo2 Now: Foo1 Foo2 [YOCTO #4348] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-06-10package_rpm.bbclass: handle pre/post remove scriptletsLaurentiu Palcu
Currently the scriptlet_wrapper is designed to handle only pre/post install scriptlets. This patch will slightly change the wrapper script to handle also pre/post remove scriptlets when we want to remove packages from the final image. Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-06-07package_*.bbclass: Drop fakeroot from setscene callsRichard Purdie
Back in 2010, I added these in commit: http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=36f1ae42fe13dae174b7fb5eb85dc49d7d7b516b however the package_write tasks sstate only consists of package files and no fakeroot privileges are needed to write these out, only originally create them. We can therefore drop these for some small performance gains and a less convoluted depenency chain. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-05-16bbclass: bb.fatal() clean upRobert Yang
The bb.fatal() is defined as: def fatal(*args): logger.critical(''.join(args)) sys.exit(1) So anything after bb.fatal() in the same code block doesn't have any effect, e.g.: bb.fatal("%s_%s: %s" % (var, pkg, e)) raise e The "raise e" should be removed. I searched all the files which use bb.fatal(), only the following 3 classes have this issues: insane.bbclass package.bbclass package_rpm.bbclass [YOCTO #4461] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-05-09class/lib: Fix up various file access methodsRichard Purdie
There are various bits of cruft that have built up around our file accesses. This patch cleans some of them up, specifically: * Remove pointless "from __builtin__ import file" * Use open(), not file() * Wrap file usage in a with container to ensure files are closed * Add missing .close() calls in some cases Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-11package_rpm.bbclass: fix build multilib image failed when PR Server enabledHongxu Jia
1, In bitbake.conf PKGR ?= "${PR}${EXTENDPRAUTO}" EXTENDPKGV ?= "${EXTENDPKGEVER}${PKGV}-${PKGR}" RDEPENDS_${PN}-dev = "${PN} (= ${EXTENDPKGV})" 2, When PR Server is enabled, EXTENDPRAUTO is not none which means PKGR and PR don't have the same value. 3, When multilib is enabled, RDEPENDS_${PN}-dev is not expanded correctly which uses PR rather than PKGR in the versioned dependency string. 4, Make sure PKGR rather than PR in version string when do_package_rpm. [YOCTO #4050] Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-23package/populate_sdk: Move functions from package_* to populate_sdk_*Richard Purdie
This fixes build failures introduced with "classes/buildhistory: implement history collection for SDK" by moving the functions to files where only the specific image type which is enabled is inherited. The failures occured when multiple PACKAGE_CLASSES were enabled. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-23classes/buildhistory: implement history collection for SDKsPaul Eggleton
SDKs are constructed in a similar manner to images, and the contents can be influenced by a number of different factors, thus tracking the contents of produced SDKs when buildhistory is enabled can help detect the same kinds of issues as with images. This required adding POPULATE_SDK_POST_HOST_COMMAND and SDK_POSTPROCESS_COMMAND variables so that data collection functions can be injected at the appropriate points in the SDK construction process, as well as moving the list_installed_packages and rootfs_list_installed_depends functions from the rootfs_{rpm,ipk,deb} to the package_{rpm,ipk,deb} classes so they can also be called during do_populate_sdk as well as do_rootfs. Implements [YOCTO #3964]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-22package_{ipk, deb, rpm}: drop the TARGET_OS conditionalChristopher Larson
The tclibc file for uclibc already empties IMAGE_LINGUAS, so there's no point to this conditional as far as I can tell, and it can cause issues for certain values of TARGET_OS. Signed-off-by: Christopher Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-16package_rpm: Ensure PV manipulations are correctRichard Purdie
The previous change to this function fixed one manipuation at the expense of the other, depending on ow expanded the versioned dependency string was when the AUTOINC substitution was made. This update ensures we cover both cases and ensures the classextended version works as as well as the normal case. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-14package_rpm: Ensure package dependencies have correct version numbersRichard Purdie
If a recipe has versioned dependencies on another package within the same recipe, there are potentially races where the version remapping may not happen correctly. This issue triggered with neard in multilib builds since it uses a "-" character in its PV which is illegal in an rpm version field. The remapping to "+" was not occuring. It only triggers in the multilib case since in this case, expansion of the datastore happens at slightly different points. The correct fix is to search for PV, not PKGV but substitute the PV value. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-04package_rpm.bbclass: Optimise per file dependency handlingRichard Purdie
Currently the process for injecting the per file rpm dependencies into rpmbuild is painfully slow. Its done through the repeated execution of a script which has to return the correct value in each case. This continual execution means the CPU usage of rpmbuild is low. This patch allows the option of collapsing the per file dependencies to a per package basis and injecting them through the .spec file. This removes the execution overhead and allows rpmbuild to run at 100% of cpu. Ultimately it would be nice to inject the per file dependencies through the .spec file however that is not currently possible. Since few people use the per file dependency information, this patch goes for the faster approach. It can be enabled if anyone needs it although I'd mention that its being used to us as this code may well go away in the future if nobody complains. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-02package_rpm.bbclass: Fix translate_smart_to_oe arch comparisonMark Hatle
When the OE arch is of the format "foo_bar-foobar" the previous comparison routine did not selectively translate the '-' causing a failed comparison. In order to work around this issue, we -always- compare the RPM translated version of the package architectures. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-01package_rpm.bbclass: add more description for pre/post scriptletsKang Kai
When write rpm spec file, one description line "# pkgname - script_type" is added to pre/post scriptlets for base package but no such line writted for subpackage. Add similiar line to subpackage to facilitate handling the pre/post scriptlets. Signed-off-by: Kang Kai <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-01package_rpm.bbclass: name postinst files with package nameKang Kai
When create rootfs, some post install scripts need be run on device. They are saved under directory /etc/rpm-postinst and named with numbers such as 100, 101 etc. Update to name the postinst script file with its package name instead of just number. That may be more easy to debug when there is a error. [YOCTO #3218] Signed-off-by: Kang Kai <kai.kang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-22rootfs_rpm.bbclass: Handle multilib configures with different OS valuesMark Hatle
[ CQID: WIND00404082 ] It is possible for the TARGET_OS to change dependending on the multilib used for a given package build. mips64 has two potential TARGET_OS values: linux and linux-gnun32. The RPM and Smart setup needs to distinguish between the two otherwise packages of the "non-default" TARGET_OS may be ignored as incompatible. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-17package_rpm/dev/ipk/tar: Drop unused functionsRichard Purdie
The package_xxx_install functions date from a different era and are not used by anything. In the rpm case, they're simply unimplemented, in the tar case they're using broken whitespace and deprecated functions. We might as well clean out the old broken unused code. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-17package_rpm/deb/ipk: Error if we don't find packages when creating the ↵Richard Purdie
package index If for whatever reason the package directory is empty of packages, it makes sense to error early rather than later in what become much more obtuse errors. This adds in a sanity check to each of the packaging backends. It also removes the duplicate createrepo call since the core index creation function now uses this directly after the switch to smart. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-01-30package_ipk/deb/rpm: Ensure deploy staging directory is empty before ↵Richard Purdie
rerunning task If we don't do this, stale files can build up, particularly with the PR server. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-01-25Split do_packagedata task from do_packageRichard Purdie
Currently, do_rootfs has a dependency on all the do_package output being present due to its usage of the pkgdata directories. This means that if you run: bitbake xxxx-image -c rootfs you end up having to fetch and unpack all the do_package data which is usually large and inefficient. It also means rm_work has to leave all the do_package data lying around so rootfs works. This patch splits the actual creation of the pkgdata directory off into a separate task, "packagedata" which happens immediately after do_package. We can then remap the dependencies so this task is depended upon, not do_package. Sstate can then be programmed not to require do_package at the appropriate times. Whilst this patch doesn't do so, it opens the possibility of rm_work wiping out the do_package output from WORKDIR as long as it also removed the do_package stamp (both normal and setscene variants) and allowing more space savings with rm_work which has been regularly requested. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-12-19package_rpm.bbclass: Refactor the attempt only installMark Hatle
Smart does not have a method to perform an install, but ignore failures. There was a class of failures that stopped Smart from processing attemptonly installs. To work around this we need to iterate over the to be attempted list. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-19classes/image: handle multilibs in complementary package lookupPaul Eggleton
For multilib the vendor string is altered, so we need to iterate over all of the multilib vendors when we do the glob processing for complementary packages. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> In addition, the RPM package arch have been munged by adding the multilib identifier. This identifier needs to be stripped when generating the installed_packages list for the complementary lookup code to work. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14package_rpm: Workaround for 'all' arch multilib package namingMark Hatle
[YOCTO #3565] All packages should not be multilib specific, however when the multilib rules run, they automatically rename the 'all' target recipes. As such there is no way to know if an 'all' package should or should not contain the multilib prefix. We workaround this issue in the translate function by checking to see if the runtime-reverse file exists or not. The workaround should be removed once a proper solution to the architectural issue is in place. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14package_rpm.bbclass: Add a simply way to enable RPM debuggingMark Hatle
Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14package_rpm.bbclass: Add additional install error detectionMark Hatle
There is a condition where the package will fail to install, but smart does not capture the error. Add the error string to the scan list. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14package_rpm.bbclass: Add support for incremental installsMark Hatle
Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14package_rpm.bbclass: Add additional loggingMark Hatle
Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14package_rpm.bbclass: Fix the way the RPM platform file is generatedMark Hatle
When generating an SDK, we need to use either the SDK or TARGET version of the OS. They are not interchangable! Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14package_rpm: Update the way the multilib package names are translatedMark Hatle
The variable MULTILIB_PACKAGE_ARCHS has been removed in favor of a repurposed MULTILIB_PREFIX_LIST. The format of this item is now <libid>:<arch>:<arch1>:...:<archN>. This ensures that we can correctly translate the libid to one of the supported archs in a tri-lib system. All of the users of MULTILIB_PREFIX_LIST and MULTILIB_PACKAGE_ARCHS have been modified accordingly. Also change the way attempted packages are installed, verify the package exists in the translate functions, then perform the install in one single operation. This results in a significantly faster install time. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-14classes/*_rpm: integrate Smart into RPM filesystem constructionPaul Eggleton
Use Smart to construct the root filesystem for images and the contents of SDKs rather than the custom scripts around rpm we had previously. This ensures the result when producing an updated image will be the same as upgrading to the same package versions from an older image on the target, as well as allowing us to remove a substantial amount of code making the rpm classes much easier to follow. Some bugfixes from Bogdan Marinescu <bogdan.marinescu@intel.com>. SDK implementation and testing as well as a number of bugfixes from Mark Hatle <mark.hatle@windriver.com>. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-06rootfs generation: export two new variables to postinst scriptletsLaurentiu Palcu
In order for the postinst scriptlets to be able to run once we need to export the location of the intercept scripts and also the location of native sysrootfs. The gdk-pixbuf binaries will need the latter because in order to generate the loaders.cache it will need to scan some shared libraries that must be native. Even though the output is a text file. Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-12-06package_rpm.bbclass: Add the runtime dependencies to the pre/post scriptletsMark Hatle
When the scriptlets are processed in RPM, they have a different dependency set then the core package. OE has no way to specify dependencies for the pre/post scriptlists, so we simply make the runtime dependencies scriptlets as well. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-10-07package_rpm.bbclass: Fix an issue where complementary installs failMark Hatle
Also ensure that we always cleanup the temporary install manifest files, some of them will cause problems if they exist in multiple install attempts. Finally verify that the lists remain uniquely sorted otherwise the complementary install may install the same files numerous times, triggering a failure. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-10-02classes: Update to use corrected bb.utils.explode_dep_versions2 APIRichard Purdie
The bb.utils.explode_dep_versions function has issues where dependency information can be lost. The API doesn't support maintaining the correct information so this changes to use a new function which correctly handles the data. This patch also fixes various points in the code to ensure that we do not have any duplicates in things that use explode_dep_versions. A new sanity test to test the contents of the R* variables is also added. [Some changes from Mark Hatle <mark.hatle@windriver.com>] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-09-26package_rpm.bbclass: change the arch's "-" to "_" for platformRobert Yang
The platform and platform_extra will be written to /etc/rpm/platform, the rpm's arch has changed the "-" to "_", so the value in platform should also be updated. [YOCTO #3159] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-09-26package_rpm.bbclass: no initial_solution in the second buildRobert Yang
There is no initial_solution.manifest in the second build when incremental rpm image generation, since the initial solution has been skipped. So we should check it before cat it. [YOCTO #3128] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-09-20Replace "echo -e" with "printf" to have the same behavior in dash or bashAndrei Gherzan
oe-core removed the prerequisite to have sh as bash. POSIX doesn't define any options and furthermore allows 'echo -e' to be the default behavior. This means that in dash 'echo -e' will actually print '-e' and interpret backslashes by default. We use instead 'printf' builtin command with or without '\n' to simulate 'echo -e' or 'echo -n'. 'printf' needs format while 'echo' can be used without any arguments. So 'echo >' was replaced by 'printf "" >'. 'echo' without '-n' flag adds a new line by default so to keep the same behavior of two new lines while using 'echo "\n"', 'printf "\n\n"' is used. [YOCTO #3138] Signed-off-by: Andrei Gherzan <andrei@gherzan.ro> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-09-12package_rpm.bbclass: Avoid unnecessary installs in complementary passMark Hatle
When called with the complementary install option, the first step is to backup the install manifest so that we can avoid installing items previously installed. However, this backup process skipped the initial_install portion of the manifest, causing early install items like libc6, bash, and base-files to be installed a second time. Fix this by cating the files to original_solution. This is done as an append to allow multiple calls to package_install_internal_rpm to work. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-09-10package_rpm.bbclass: fix incremental rpm image generationRobert Yang
* Check ${target_rootfs}/etc/passwd rather than ${target_rootfs}${rpmlibdir} to make sure that it has been previously installed. * Remove the "--nodeps" when incremental image generation, it should take care of the dependencies. Still use "--replacefiles --replacepkgs" in case there are conflicts. [YOCTO #3047] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-09-10package_rpm.bbclass: fix the arch (replace "-" with "_")Robert Yang
rpm can't use the "-" as the arch, which causes problem, e.g., when MACHINE = "beagleboard": * The arch should be armv7a-vfp-neon, but rpm only takes the armv7a, this is incorrect since it is mixed with real arch armv7a. * The nativesdk's arch should be i686-nativesdk (or x86_64-nativesdk), but rpm only takes the i686 (or x86_64), this in incorrect since it is mixed with the arch i686 (or x86_64). Replace "-" with "_" when rpm package and the rootfs generation would fix the problem, I think this is fine since it doesn't change the tune's arch, the package manager doesn't care about the arch's name, but it needs a unify arch system to avoid confusing. This is similar to what we have done on the deb which fixed the arch i486, i586 and so on to i386. [YOCTO #2328] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>