summaryrefslogtreecommitdiff
path: root/meta/classes
Commit message (Collapse)AuthorAgeFilesLines
* autotools.bbclass: Don't copy into non-existant directoryAndreas Oberritter2012-02-231-1/+1
| | | | | | | | | | | | | * If configure.ac contains AM_GNU_GETTEXT and po/Makefile.in.in doesn't exist, autotools_do_configure() copies a local version of Makefile.in.in to this location. If the directory 'po' doesn't exist, the function aborts. * This patch verifies that the directory exists before copying a file to it. This fixes libcddb, which uses AM_GNU_GETTEXT, but has no 'po' directory. Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
* sstate.bbclass: add *_config to SSTATE_SCAN_FILESMartin Jansa2012-02-231-1/+1
| | | | | | | * e.g. mysql5 has mysql_config not mysql-config Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* base.bbclass: check all entries of FILESPATH for MACHINE overridesJoshua Lock2012-02-221-6/+8
| | | | | | | | | | | | The logic which looks for MACHINE overrides in SRC_URI and updates PACKAGE_ARCH was checking only certain subdirectories of the recipes parent which, amongst other issues, doesn't account for SRC_URI overrides in layers. This patch changes the logic such that all FILESPATH entries are checked for children named for MACHINE. Signed-off-by: Joshua Lock <josh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* sanity.bbclass: Add ABI version 8, used for transition from the OEBasic to ↵Richard Purdie2012-02-221-0/+2
| | | | | | OEBasicHash stamp layout Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes/buildhistory: fix splitting on + in package list fieldsPaul Eggleton2012-02-211-1/+1
| | | | | | | Ensure we do not erroneously split on + in RDEPENDS/RRECOMMENDS e.g. libstdc++-dev was being split into libstdc and -dev. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/buildhistory: use hostname instead of reading /etc/hostnamePaul Eggleton2012-02-211-1/+1
| | | | | | | | | For the purposes of querying the hostname to include it in the commit message, it seems "cat /etc/hostname" does not work on the Yocto Project autobuilder machines, and it's likely that the hostname command will be more generally reliable, so use that instead. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/buildhistory: sort FILELIST in package infoPaul Eggleton2012-02-211-0/+1
| | | | | | | | The FILELIST order can vary depending on the order the files were written which may change between builds with no ill effect, so sort the list prior to writing it. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/buildhistory: sort and de-dupe dependency graphsPaul Eggleton2012-02-211-2/+2
| | | | | | | | Sort dependencies of each package which sometimes change order and cause noise in the buildhistory repo, and at the same time remove duplicates (which seem to be common especially for the RPM package query output). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/buildhistory: squash spaces out of image variablesPaul Eggleton2012-02-211-4/+12
| | | | | | | | Values of image variables that are lists (e.g. IMAGE_INSTALL) are easier to read if there are no extraneous spaces in them, so ensure that there is only one space between each item. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/sdl: remove Opie-specific desktop file/packagingPaul Eggleton2012-02-211-38/+0
| | | | | | | | | This code will not work without palmtopdir being defined, and is better kept in meta-opie in any case (where we already have the OE-Classic version of this class). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* package.bbclass: Optimise the per file rpm handlingRichard Purdie2012-02-101-20/+32
| | | | | | | | | | Currently a process was being forked off for each individual file this class wanted to inspect with rpmdeps. This converts it to use rpmdeps-oecore which allows batch processing of these dependencies. For do_package for perl, this reduced the time by about 1 minute (33%). Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* sstate.bbclass: Optimise sstate_hardcode_pathRichard Purdie2012-02-101-11/+16
| | | | | | | | | | | | The sstate_hardcode_path() function triggered large numbers of exec() calls when processing packages with large numbers of file relocations (e.g. perl). This patch optimises those calls into longer single commands which make the code significantly more efficient. This reduced the do_package time for perl by 2 minutes (from 4.75 minutes) for me. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* distutils.bbclass: override LDSHARED so we use the linker for this build and ↵Matthew McClintock2012-02-101-0/+2
| | | | | | | | | | | | | not the one used in sstate-cache Without this fix, when packages are being built using distutils and the python packages were deployed from sstate-cache is it possible that the LD command will contain an invalid sysroot override. We can fix this by always exported LDSHARED, which is the env var that distutil looks for to override creating shared libraries. Signed-off-by: Matthew McClintock <msm@freescale.com>
* cross.bbclass: add virtclass handlerOtavio Salvador2012-02-101-0/+17
| | | | | | | Allow use of BBCLASSEXTEND with 'cross' and use of virtclass-cross in recipes. Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
* useradd.bbclass: skip processing on virtclass-cross extended packagesOtavio Salvador2012-02-101-0/+3
| | | | Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
* classes/buildhistory: sort list fields in package infoPaul Eggleton2012-02-081-3/+14
| | | | | | | | | | Sort DEPENDS, RDEPENDS, and RRECOMMENDS in package info files so that any changes in order (which are not important) are smoothed out in the change history. Fixes [YOCTO #1961] Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/buildhistory: sort image file listPaul Eggleton2012-02-081-1/+1
| | | | | | | Sort the contents of files-in-image.txt to avoid unnecessary changes showing up in the history due to reordering. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* mirrors.bbclass: Add yp.org and oe.org to fallback mirrorsKhem Raj2012-02-071-1/+20
| | | | | | | This should improve the fetching errors users see when upstream src_uri is unavailable Signed-off-by: Khem Raj <raj.khem@gmail.com>
* classes,recipes: Replace POKY_* with CORE_IMAGE_*Khem Raj2012-02-071-4/+4
| | | | Signed-off-by: Khem Raj <raj.khem@gmail.com>
* linux-yocto: locate and use out of tree features specified on the SRC_URIBruce Ashfield2012-02-071-0/+21
| | | | | | | | | | In a similar manner to calling the patch.bbclass to locate patches that were listed on the SRC_URI, it is also useful to query about 'other' items that are on the SRC_URI. In the case of linux-yocto, it allows us to know about kernel features that were specific on the URI and then apply them to the current tree. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* bootimg: Use the same OS files for each boot methodDarren Hart2012-02-073-47/+46
| | | | | | | | | | | | | | | | | | | Fixes [YOCTO #1951] The do_bootimg code can generate hybrid efi+pcbios images (syslinux and grub-efi) to boot on platforms with both EFI and legacy BIOS options. The current implementation copies the kernel, initrd, and rootfs twice, unnecessarily bloating the image size. This is an especially egregious bug on -sato images. Update the classes to use a common install of the kernel, initrd, and rootfs to the root of the boot media. Grub-efi, syslinux, and isolinux can all reference this location explicitly with a leading slash. Tested with an EFI+PCBIOS image in both EFI and PCBIOS boot modes on two platforms. No ISO image testing was performed. Signed-off-by: Darren Hart <dvhart@linux.intel.com>
* classes/patch: optionally return non-patch sourcesBruce Ashfield2012-02-031-1/+8
| | | | | | | | | | | | | | | | | | | | commit: patch.bbclass: abstract out logic that determines patches to apply gives the ability for other clases to emit series files for use outside of a build system, or even within the build system. There are sometimes elements on the SRC_URI that while not directly applicable to patching, can be related to patching the package. For example, the yocto kernel class would like to know about these other source items on the SRC_URI to locate out of tree kernel features. This change keeps the default behaviour of returning patches, but adds the ability to request that non-patch results be returned. Additional filtering within the non-patch category, is left up to the caller of the routine. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* Add EXTERNAL_TOOLCHAIN to CMAKE_FIND_ROOT_PATHKen Werner2012-02-031-1/+1
| | | | | | | This allows cmake to find the binaries of an external toolchain. Signed-off-by: Ken Werner <ken.werner@linaro.org> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* gconf.bbclass: Add proper RDEPENDS to packages with gconf postinststep.Peter Tworek2012-02-021-0/+3
| | | | | | | | | | | Right now gconf bbclass adds both postinst and prerm steps, but it does not ensure that packages involved have gconf in RDEPENDS. This can lead to a situation where postinst/prerm steps fail because gconftool-2 is not installed. Signed-off-by: Peter Tworek <tworaz666@gmail.com> Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* external-csl-toolchain: fixes for metadata changesChristopher Larson2012-02-011-1/+3
| | | | | | | | | | | | | | | These allow the recipe to build again: - add compilerlibs, g++, libgcc to the provides - add linux-libc-headers-dev to the packages - in libc-package, only sed the ldd.bash.in file if it exists, as the external toolchain is using that class as well - shift the inherit location of the libc classes, as they were overriding the recipe's do_install - use ?= for EXTERNAL_TOOLCHAIN, so the user can set it Signed-off-by: Christopher Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* libc-package: fix typo in LOCALETREESRC default valueChristopher Larson2012-02-011-1/+1
| | | | | Signed-off-by: Christopher Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* package bbclass: allow per package PRIVATE_LIBSKoen Kooi2012-02-011-1/+1
| | | | | | | | If a recipe packages multiple versions of shlib (e.g. powervr drivers) we only want the shlib code to pickup $PN, not $PN-foo subpackages. This keeps backward compatibility with the global PRIVATE_LIBS usage if no per package PRIVATE_LIBS are set for a given package. In other words: this doesn't break the firefox recipe. Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* pkgconfig: Ensure pkgconfig RDEPENDS are trackedRichard Purdie2012-02-011-0/+5
| | | | | | | | | | | Currently, pkgconfig dependencies get added to -dev packages which install pc files however nothing in the system makes bitbake aware of these dependencies so images can fail with pkgconfig being missing. This change explictly adds in the pkgconfig RDEPENDS to the -dev packages and hence makes bitbake aware of the dependency. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bootimg: Do not force FAT32 on all images, it violates the FAT specificationDarren Hart2012-02-011-1/+4
| | | | | | | | | | | | | | | | | | | | | | Fixes [YOCTO #1940] do_bootimg was performing the FAT overhead calculations assuming FAT32 and then forcing the use of FAT32 with "-F 32" to mkdosfs. The FAT specification is clear on cluster count being the determining factor for FAT size (even if the fs string is set to FAT32, go figure). Syslinux follows this spec, and rightly so, resulting in a failure on core-image-minimal: syslinux: zero FAT sectors (FAT12/16) Drop the "-F 32" from mkdosfs to allow it to select the appropriate FAT size based on cluster count. Leave the FAT overhead calculation in FAT32. This will result in a little extra padding for really small images, but not enough extra to justify recalculating for FAT12 and FAT16. Tested with a core-image-minimal build for atom-pc. do_bootimg completed successfully, and the resulting image was FAT16. Signed-off-by: Darren Hart <dvhart@linux.intel.com>
* classes: replace 'Poky' with 'OE-core'Koen Kooi2012-02-015-9/+9
| | | | Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
* image_types.bbclass: refactor cpio images generation.Andrea Adami2012-02-011-4/+17
| | | | | | | | | * Add common check for the presence of an /init * symlink, being 'touch' would fail with it * and 'touch -h' is not yet generally supported * (depends on distro on build host). Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
* rootfs_ipk: remove runtime_script_required usageMartin Jansa2012-02-011-1/+1
| | | | | | | | | * it was introduced in 87780fc09b066525e47d0f50ee5497db54d304cd * then partially removed in 2feba313c991170747381c7cf821a45c2cd04632 * so remove this use too as runtime_script_required is not initialized anymore and results in run.do_rootfs.6328: line 235: [: -eq: unary operator expected Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* useradd.bbclass: Fix missing quoteRichard Purdie2012-01-271-1/+1
| | | | Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* useradd: Ensure dependencies are only added for target recipes, not native ↵Richard Purdie2012-01-271-1/+4
| | | | | | or nativesdk Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* useradd.bbclass: Add explict setscene dependencies to ensure correct ↵Richard Purdie2012-01-271-0/+2
| | | | | | ordering of setscene tasks Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* useradd.bbclass: Ensure pseudo can load in the pseudo unloaded caseRichard Purdie2012-01-271-5/+11
| | | | | | | | | | In the do_populate_sysroot_setscene case, pseudo has been unloaded and we need to reload it. This code change ensures all the pseudo options are specified so pseudo loads correctly. It also improves some of the comments so all the different contexts are listed. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* useradd.bbclass: Execute user addition code before do_package_setscene, not ↵Richard Purdie2012-01-271-2/+2
| | | | | | | | | | after do_populate_sysroot_setscene The user addition needs to happen before the do_package files are extracted by do_package_setscene since those are the ones we need to preserve the file ownership information for. This patch ensures this happens. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* sstate.bbclass: Add support for sstate preinst functionsRichard Purdie2012-01-271-0/+5
| | | | Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* insane.bbclass: Add test for static .a libraries in non-staticdev packagesSaul Wold2012-01-261-1/+14
| | | | | | | | | | | | | | | This check verifies that non staticdev and non pic packages do not have static libraries in them. There are a few exceptions for the libgcc-dev and libgcov-dev packages which are whitelisted, also the *_nonshared.a need to be part of their respective -dev packages. This is currently a warning to work out any other issues in the upper layers but will be moved to ERROR at somepoint in the future. [YOCTO #663] Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* bootimg: Fix a math thinko in the block count calculationDarren Hart2012-01-251-1/+1
| | | | | | | | | | | | | Fixes [YOCTO #1852] ... again. The conversion from sectors to blocks was multiplying by 2 instead of dividing by 2. Blocks are 1024 bytes, sectors are 512 bytes. The result was images being much larger than intended. Reported-by: Tom Zanussi <tom.zanussi@intel.com> Signed-off-by: Darren Hart <dvhart@linux.intel.com> CC: Joshua Lock <josh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* base.bbclass: replace COMMERCIAL_LICENSE code with LICENSE_FLAGS codeTom Zanussi2012-01-241-6/+6
| | | | | | | | The COMMERCIAL_LICENSE mechanism has been superseded by LICENSE_FLAGS so remove the code that implements COMMERCIAL_LICENSE and replace it with the corresponding LICENSE_FLAGS version. Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
* license.bbclass: add support for LICENSE_FLAGSTom Zanussi2012-01-241-0/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | LICENSE_FLAGS are a per-recipe replacement for the COMMERCIAL_LICENSE mechanism. In the COMMERCIAL_LICENSE mechanism, any package name mentioned in the global COMMERCIAL_LICENSE list is 'blacklisted' from being included in an image. To allow the blacklisted package into the image, the corresponding packages need to be removed from the COMMERCIAL_LICENSE list. This mechanism relies on a global list defined in default-distrovars.inc. The LICENSE_FLAGS mechanism essentially implements the same thing but turns the global blacklist into a per-recipe whitelist. Any recipe can optionally define one or more 'license flags'; if defined, each of the license flags defined for a recipe must have matching entries in a global LICENSE_FLAGS_WHITELIST variable. The definition of 'matching' is simple, but there are a couple things users need to know in order to correctly and effectively use it. Before we test a flag against the whitelist, we append _${PN} to it, thus automatically making each LICENSE_FLAG recipe-specific. We then try to match that string against the whitelist. So if the user specifies LICENSE_FLAGS = 'commercial' for recipe 'foo', the string 'commercial_foo' should be specified in the whitelist in order for it to match. However, the user can also broaden the match by putting any '_'-separated beginning subset of a LICENSE_FLAG in the whitelist, which will also match e.g. simply specifying 'commercial' in the whitelist would match any expanded LICENSE_FLAG starting with 'commercial' such as 'commercial_foo' and 'commercial_bar' which are the strings that would have been automatically generated if those recipes had simply specified LICENSE_FLAGS = 'commercial' This allows for a range of specificity for the items in the whitelist, from more general to perfectly specific. So users have the choice of exhaustively enumerating each license flag in the whitelist to allow only those specific recipes into the image, or of using a more general string to pick up anything matching just the first component(s). Note that this scheme works even if the flag already has _pn appended - the extra _pn is redundant, but doesn't affect the outcome e.g. a license flag of 'commercial_1.2_foo' would turn into 'commercial_1.2_foo_foo' and would match both the general 'commercial' and the specific 'commercial_1.2_foo' as expected (it would also match commercial_1.2_foo_foo' and 'commercial_1.2', which don't make much sense as far as something a user would think of specifying in the whitelist). For a versioned string, the user could instead specify 'commercial_foo_1.2', which would turn into 'commercial_foo_1.2_foo', but which would as expected allow the user to pick up this package along with anything else 'commercial' by specifying 'commercial' in the whitelist, or anything with a 'commercial_foo' license regardless of version by using 'commercial_foo' in the whitelist, or 'commercial_foo_1.1' to be completely specific about package and version. The current behavior of COMMERCIAL_LICENSE is replicated as mentioned above by having the current set of COMMERCIAL_LICENSE flags implemented using LICENSE_FLAGS = "commercial". That being the case, the current COMMERCIAL_LICENSE can equivalently be specified in the new scheme by putting the below in local.conf: # This is a list of packages that require a commercial license to ship # product. If shipped as part of an image these packages may have # implications so they are disabled by default. To enable them, # un-comment the below as appropriate. #LICENSE_FLAGS_WHITELIST = "commercial_gst-fluendo-mp3 \ # commercial_gst-openmax \ # commercial_gst-plugins-ugly \ # commercial_lame \ # commercial_libmad \ # commercial_libomxil \ # commercial_mpeg2dec \ # commercial_qmmp" The above allows all of the current COMMERCIAL_LICENSE packages in - to disallow a particular package from appearing in the image, simply remove it from the whitelist. To allow them all in, you could also specify LICENSE_FLAGS_WHITELIST = "commercial". Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
* lib/oe: Add sstatesig, OE specific signature generator classesRichard Purdie2012-01-231-1/+1
| | | | | | | | | | | | | This patch adds SignatureGenerator classes specific to OE. For now, these emulate the previous behaviour with the exception that dependencies on quilt-native are now ignored for checksum purposes. The intent is to allow easier experimentation and customisation of this code in future as a result of these changes. Note that these changes require pending bitbake patches. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes/patch: avoid backtrace when patch does not applyPaul Eggleton2012-01-191-1/+4
| | | | | | | | | | | | We don't need to see a Python stack backtrace when a patch does not apply, just the error output from patch, so trap these kinds of errors and ensure that we display the message and fail the task and nothing else. Fixes [YOCTO #1143] Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* buildhistory: record additional image infoPaul Eggleton2012-01-191-0/+18
| | | | | | | | | | | | | | | Record some additional information about images - the uncompressed size of the final image as well as the values of various variables that may have influenced its contents. This is recorded in a machine-readable "image-info.txt" file similar in structure to the package history files. Also add some code to analyse changes to these values. (Most of the variable values aren't monitored directly but will be used as contextual information when they change at the same time as the content of the image changing.) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* linux-yocto: restore WORKDIR as a patch source directoryBruce Ashfield2012-01-191-0/+2
| | | | | | | | | In the switch to using src_patches and using patches in their source directory, the scanning of WORKDIR migrated items like config fragments was dropped. Adding WORKDIR back as a patch directory restores the old functionality. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
* package_rpm.bbclass: Add support for filenames with spacesMark Hatle2012-01-171-4/+4
| | | | | | | | Files with spaces must be fully quoted in an RPM spec file. It was easier to quote all file paths, then to do it selectively. Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
* classes/packagehistory: remove now obsolete classPaul Eggleton2012-01-171-249/+0
| | | | | | | | packagehistory.bbclass has been superseded by buildhistory.bbclass, which gives more detailed output (including information on produced images) as well as other enhanced functionality. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/package: remove out-of-date notice referring to the OE bugtrackerPaul Eggleton2012-01-171-3/+0
| | | | | | | | OpenEmbedded doesn't officially use a bug tracker anymore, and a message asking the user to fix the metadata could be applied to almost any error that occurs, so just remove the whole message. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
* classes/base: note variable name in COMPATIBLE_* skip messagesPaul Eggleton2012-01-171-2/+2
| | | | | | | When raising SkipPackage for COMPATIBLE_MACHINE and COMPATIBLE_HOST exceptions, include the name of the variable as a hint to the user. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>