path: root/meta-oe/classes
Commit message (Collapse)AuthorAgeFilesLines
* meta-oe: remove True option to getVar calls (again)André Draszik2019-01-131-5/+5
| | | | | | | | | | | | | | A couple have still been missed in the past despite multiple attempts at doing so (or simply have re-appeared?). Search & replace made using the following command: sed -e 's|\(d\.getVar \?\)( \?\([^,()]*\), \?True)|\1(\2)|g' \ -i $(git grep -E 'getVar ?\( ?([^,()]*), ?True\)' \ | cut -d':' -f1 \ | sort -u) Signed-off-by: André Draszik <andre.draszik@jci.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
* Copy breakpad .sym file in appropriate folder.Tristan Ramseyer2018-11-261-0/+3
| | | | | | | Google breakpad requires a very specific folder structure which is only known after dump_syms has been executed. Therefore the .sym file's first line has to be parsed in order to move the file where breakpad wants it. Signed-off-by: Khem Raj <raj.khem@gmail.com>
* dos2unix: Remove after move to coreKhem Raj2018-08-211-14/+0
| | | | | | Its in OE-Core now Signed-off-by: Khem Raj <raj.khem@gmail.com>
* scancode.bbclass: Adding a bbclass for scancode license scaning utilityirfan sadiq2018-05-231-0/+35
| | | | | | | | | | | | | | | This is adding the functionality to run scancode utility on code. You need to set the following variables to use it. You can override these from local.conf or auto.conf. 1) SCANCODE_GIT_LOCATION: Git Path for scancode-toolkit cloning, default is set. 2) SCANCODE_TAG: Select tag, if you want. 3) SCANCODE_FORMAT: Output file format json or html-app. 4) SCANCODE_SRC_LOCATION: Location to store scancode-toolkit. This belongs to OI-2. Signed-off-by: H M Irfan Sadiq <irfan_sadiq@mentor.com> Signed-off-by: Noor Ahsan <noor_ahsan@mentor.com>
* classes/recipes: Convert SkipPackage -> SkipRecipeMaxin John2018-03-051-1/+1
| | | | | | | | Update following the SkipPackage -> SkipRecipe change in oe-core. Signed-off-by: Maxin B. John <maxin.john@intel.com> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
* meson: remove recipe and classAlexander Kanavin2018-01-161-106/+0
| | | | | | | | | They have been moved to oe-core layer, as meson is increasingly the primary build system for many projects, particularly in the Gnome stack. Signed-off-by: Alexander Kanavin <alexander.kanavin@linux.intel.com> Signed-off-by: Armin Kuster <akuster808@gmail.com>
* meson: set needs_exe_wrapperRoss Burton2017-08-131-0/+1
| | | | | | | | | Tell Meson that even if it looks like the architectures are compatible, not to bother executing binaries: differences in tunes, C libraries and so on mean binaries may not work. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson: set native tool flag variablesRoss Burton2017-07-011-0/+4
| | | | | | | As well as setting CC/CXX, export CFLAGS/CXXFLAGS and so on. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson: export PKG_CONFIG to use pkg-config-native for native buildsRoss Burton2017-07-011-0/+1
| | | | | | | | By default Meson uses 'pkg-config' in native builds but as that is the cross pkg-config, export PKG_CONFIG to use the correct pkg-config-native binary. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson: don't pass localedirRoss Burton2017-07-011-1/+0
| | | | | | | | | | | For historic reasons the localedir directory is where binary locales are stored (/usr/lib/locale) , not where application translations belong (typically, /usr/share/locale). Don't pass localedir explicitly, and let Meson use the default of $datadir/locale to match the behaviour of autotools.bbclass and the expectations of the system. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* Revert "meson: fix build/host confusion for bbclass"Ross Burton2017-07-011-3/+3
| | | | | | | | | | This patch was incorrect: meson and autotools (thus OE) don't have conflicting terminology, and using HOST_* for the host_machine variables is correct. This reverts commit 77eae90ef5ca3f9a4bdf5727a29713dd2b215165. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson: revert changes which shouldn't have been submittedRoss Burton2017-07-011-1/+1
| | | | | | | | | | | >From Adam Foltzer: Apologies, this line was inadvertently committed. It was a fix I tried before learning that adding TARGET_CC_ARCH was the solution to linking the wrong ld.so. Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* gitver: skip packages instead of panic()ing if ${GITVER} fails to expandAlejandro Mery2017-06-221-13/+10
| | | | | | | | | | | | | | | | `inherit externalsrc gitver` is a very useful combo to get development trees in your workspace having a ${PN}_git.bb with PV=${GITVER} coexisting with a regular ${PN}_${PV}.bb but not everyone wants to checkout all developments sources and managinging different layers for each options is quite troublesome. making `gitver` skip the .bb instead of panic()ing every time EXTERNALSRC is missing allows people to have a single development layer where packages get enabled if the right sources are present or falling back to the last release if not Signed-off-by: Alejandro Mery <amery@hanoverdisplays.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* gitver: fix broken ${GITSHA} and recursion in S when PV="${GITVER}"Alejandro Mery2017-06-141-4/+14
| | | | | Signed-off-by: Alejandro Mery <amery@hanoverdisplays.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* gitver: extend class to use EXTERNALSRC if setAlejandro Mery2017-06-141-2/+4
| | | | | Signed-off-by: Alejandro Mery <amery@hanoverdisplays.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* dos2unix.bbclass: add recipeMing Liu2017-06-141-0/+14
| | | | | | | | | | Class for use to convert all CRLF line terminators to LF provided that some projects are being developed/maintained on Windows so they have different line terminators(CRLF) vs on Linux(LF), which can cause annoying patching errors during git push/checkout processes. Signed-off-by: Ming Liu <peter.x.liu@external.atlascopco.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson: add LDFLAGS to bbclass C/C++ link argumentsAdam C. Foltzer2017-06-141-5/+6
| | | | | | | | This adds compiler flags for C++ projects, and fixes the linker arguments for both C and C++ to avoid the GNU_HASH qa failure Signed-off-by: Adam C. Foltzer <acfoltzer@galois.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson: fix build/host confusion for bbclassAdam C. Foltzer2017-06-141-3/+3
| | | | | | | | Meson and Bitbake use different terminology for the build and host; this provides the correct build machine info to Meson. Signed-off-by: Adam C. Foltzer <acfoltzer@galois.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson: Suport for c++ cross-compilationRicardo Ribalda Delgado2017-06-051-0/+2
| | | | | | | | | cpp_args and cpp_link_args must be set on the meson.cross file to compile c++ applications. Otherwise variables such as the sysroot are not set correctly and libraries/headers are not found. Signed-off-by: Ricardo Ribalda Delgado <ricardo.ribalda@gmail.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson.bbclass: Use the correct C++ compiler when cross compilingPeter Kjellerstedt2017-03-161-1/+1
| | | | Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson.bbclass: Support building for nativePeter Kjellerstedt2017-03-161-4/+9
| | | | | Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson.bbclass: Make changes to meson.build files trigger reconfigurationPeter Kjellerstedt2017-03-161-0/+2
| | | | | | | | When externalsrc.bbclass is used, any changes to meson.build files should trigger do_configure to be re-run. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson.bbclass: Add support for more standard installation directoriesPeter Kjellerstedt2017-03-161-1/+5
| | | | | | | | A couple of more standard installation directories are supported with meson 0.37.1, so make sure they are configured. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* gitver: fix try/except syntax for python3 supportAlejandro Mery2017-03-071-2/+2
| | | | | | | | | https://www.python.org/dev/peps/pep-3110/ It's backward compatible with 2.6+ Signed-off-by: Alejandro Mery <amery@hanoverdisplays.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson.bbclass: Add progress support for do_compile()Peter Kjellerstedt2017-03-071-0/+1
| | | | | | | | ninja provides progress information when building so let's make use of it. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* gitpkgv.bbclass: fix versioning with multiple reposS. Lockwood-Childs2017-02-221-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | gitpkgv class is supposed to use SRCREV_FORMAT variable to define how to smoosh together revision info from multiple repos that are used in a single recipe. It is incorrectly repeating the rev hash for the first repo instead of including the rev from each listed repo. Example: SRC_URI = "git://some-server/purple.git;destsuffix=git/purple;name=purple" SRC_URI += "git://other-server/blue.git;destsuffix=git/blue;name=blue" SRCREV_purple = "${AUTOREV}" SRCREV_blue = "${AUTOREV}" SRCREV_FORMAT = "purple_blue" Suppose gitpkgv calculates "67+ea121ea" for purple repo, and "123+feef001" for blue repo. This should result in a package version with them joined together like so: "67+ea121ea_123+feef001" It didn't. Instead the git hash part for the first repo got repeated: "67+ea121ea_123+ea121ea" Fix this by looking in the right place for the git revisions of 2nd (and following) repos when assembling the full version string. Signed-off-by: S. Lockwood-Childs <sjl@vctlabs.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meson.bbclass: Add meson.bbclassLinus Svensson2017-02-201-0/+86
| | | | | | | | | | | | | | | | Add a class for packages that uses the meson build system. Meson uses a cross-file that contain needed tools and information about the host and target system. Such a file will be created in {WORKDIR}. Meson only allows installation directories to be specified as relative to prefix, except for sysconfdir, which can be absolute. This patch is based on a prototype patch by Ross Burton <ross.burton@intel.com>. Signed-off-by: Linus Svensson <linussn@axis.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* remove True option to getVar callsJoshua Lock2016-12-025-12/+12
| | | | | | | | | 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>
* gitpkgv: Fix $GITPKV for a single named git sourceClemens Lang2016-09-051-1/+8
| | | | | | | | | | | | | | | Recipes that fetch from a single git source, assign a name to this source and do not set SRCREV_FORMAT to this name will always get a GITPKGV value of "default", which causes version-going-backwards QA errors. Fix this by automatically determining a suitable SRCREV_FORMAT from the SRC_URI if none is set explicitly. This code does not run for multiple git sources, because bitbake's fetcher enforces setting SRCREV_FORMAT when multiple version-controlled sources are used. Signed-off-by: Clemens Lang <clemens.lang@bmw-carit.de> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* gitkpkgv: Ensure files are closedRichard Purdie2016-06-081-2/+4
| | | | | | | This avoids warnings with python 3. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* autotools-bootstrap: make bootstrap package specific.Paul Gortmaker2016-05-121-24/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | The theory behind this bbclass was reasonable, with the primary goal being to avoid multiple downloads of gnulib, but it neglected the fact that packages would be shipping a specific version of the ./bootstrap which will support some flags but maybe not all the latest ones from the latest gnulib/build-aux/bootstrap file. I attempted to simply update the two pkgs to use the latest copy of bootstrap from gnulib but this of course triggers the descent into autoconf hell that we all know and love. Rather than futzing with the packages configure.ac and deviating from what the pkg maintainers intended and tested, we can just let the packages have independent calls to ./bootstrap with whatever flags are needed. The goal of this commit is to move the prepend out to the packages and then delete the class without any real functional change ; i.e. a purely mechanical change. Then we can adjust each package to ensure it will still build with a modern host, in an independent fashion, while keeping the main advantage of not fetching gnulib two extra times for netcf and fontforge. Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
* waf-samba.bbclass: move to meta-networkingJackie Huang2016-04-011-95/+0
| | | | | | | | | | The recipes that are using waf-samba were all moved to meta-networking, so move the bbclass and related cross-answers files as well. Signed-off-by: Jackie Huang <jackie.huang@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
* waf-samba.bbclass: add cross-answers option and filesJackie Huang2016-03-021-1/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --cross-execute uses qemu to run cross-compiled binaries, it works fine for qemu supported targets, but it definitely will fail if the target is not supported by qemu. So we need to use the cross-answers option. Added three methods and set 'answer' as default: 1. answers: Only --cross-answers - try the cross-answers file, and if there's no corresponding answer, add to the file and mark the configure process as unfinished. 2. exec: Only --cross-execute - get the answer from cross-execute, an emulator (qemu) is used to run cross-compiled binaries. 3. both: Try the cross-answers file first, and if there is no corresponding answer, use cross-execute to get an answer, and add that answer to the file. The cross files in are all generated by qemu when the 'both' mode is enabled, and are placed in a common directory LAYERDIR/files/waf-cross-answers which is set as WAF_CROSS_ANSWERS_PATH in layer.conf of meta-oe, so that we don't have to put copies of them for each package (there are 5 packages inerit waf-samba for now) Signed-off-by: Jackie Huang <jackie.huang@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Signed-off-by: Joe MacDonald <joe_macdonald@mentor.com>
* waf-samba: enable parallel buildsJens Rehsack2016-01-061-0/+4
| | | | | | | | | Instead of relying on sequencial waf build invoked by make, invoke waf as documented with default switch for building in parallel. Signed-off-by: Jens Rehsack <sno@netbsd.org> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* gitpkgv.bbclass: Add support for gitsm:// url typeDaniel Adolfsson2015-12-181-1/+1
| | | | | | | | | When using "gitsm://", for projects using submodules, instead of "git://", gitpkgv does not work. The limitation is synthetic, this patch simply adds gitsm as an allowed url type. Signed-off-by: Daniel Adolfsson <daniel.adolfsson@bluetest.se> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* autotools-bootstrap.bbclass: initial addAndreas Müller2015-11-061-0/+24
| | | | | | | | bootstrap is another magic script which is intended run before autotools. The class created runs this script at the right time and ensures that sources of gnulib are not cloned during configure. Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
* waf-samba.bbclass: add missing qemu optionsJackie Huang2015-11-021-2/+1
| | | | | | | | | | - QEMU_OPTIONS is needed for running binary through qemu, add it for CROSS_EXEC. - "-r ${OLDEST_KERNEL}" is already included in QEMU_OPTIONS, remove it from CROSS_EXEC Signed-off-by: Jackie Huang <jackie.huang@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* waf-samba.bbclass: remove bashismJackie Huang2015-09-231-1/+1
| | | | | | | use '=' instead of '==' so this works with dash as /bin/sh Signed-off-by: Jackie Huang <jackie.huang@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* waf-samba: add new classBian Naimeng2015-08-241-0/+51
| | | | | | waf-samba is a build system used by samba related software Signed-off-by: Bian Naimeng <biannm@cn.fujitsu.com>
* socorro-syms: Limit the search for repository to within the build directoryDaniel Markus2015-04-211-15/+24
| | | | | | | | | | | When we search for the git repository associated with a file and the there's no repository associated, we incorrectly find the yocto repository itself. To prevent the search from finding an incorrect repository, we only accept repositories found within the build directory. Signed-off-by: Daniel Markus <daniel.markus@leica-geosystems.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* socorro-syms: Correct the extraction of repository branchDaniel Markus2015-04-131-6/+4
| | | | | | | | | | | | When a recipe has git-cloned source code to compile, it may be checked out with a detached HEAD. The current VCS information extraction in socorro-syms incorrectly assumes a detached HEAD belongs to the master branch. With the proper git command we find the branch the detached HEAD belongs to and use that in the Socorro link. Signed-off-by: Daniel Markus <daniel.markus@leica-geosystems.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* socorro-syms: Add support for local repositoriesDaniel Markus2015-04-131-1/+13
| | | | | | | | | | | | | | | This socorro-syms functionality tries to extract the host name out of the source code repository origin. This causes problems when the origin is a local repository. The solution is to look for the origin in two steps. If the origin in the first step is a local directory we assume it is a temporary download repository. In the second step we look for the origin to that download repository and if that also redirects to a local repository, we provide the absolute path instead of a Socorro repository link. Signed-off-by: Daniel Markus <daniel.markus@leica-geosystems.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* socorro-syms: Add directory arrangement needed by minidump_stackwalkDaniel Markus2015-03-211-1/+49
| | | | | | | | | | | | | | | | | | http://code.google.com/p/google-breakpad/wiki/LinuxStarterGuide When extracting a stack trace out of a Breakpad minidump, the application minidump_stackwalk is used. This application needs all symbol files to be arranged in a particular directory structure in order to match the correct symbol file with the version of the crashed program in question. A directory structure is created in accordance with minidump_stackwalk. The structure contains the name of the application binary and a hash value where the hash corresponds to the binary the symbol file was produced from. The symbol file is moved to the hash directory allowing multiple versions of the same symbol file. Signed-off-by: Daniel Markus <daniel.markus@leica-geosystems.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* socorro-syms: Add Breakpad symbol generation adapted for SocorroDaniel Markus2015-03-031-0/+164
| | | | | | | | | | | | | | | https://github.com/mozilla/socorro Mozilla Socorro is a downloadable crash dump server that handles Breakpad crash dumps coming from own applications. In order for Socorro to create clickable links into your source code repository, Breakpad's symbol files must be copied and modified to contain VCS information for each file reference. This class reads the symbol file generated by Breakpad and creates a new symbol file with that VCS information contained. Signed-off-by: Daniel Markus <daniel.markus@leica-geosystems.com>
* breakpad: correct the file suffix of the symbol fileAnders Darander2014-11-071-1/+1
| | | | | | | minidump_stackwalk looks for a .sym file extension. Correct the extension used for the generated file. Signed-off-by: Anders Darander <anders@chargestorm.se> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* meta-oe: use BPN in SRC_URIRobert Yang2014-07-151-1/+1
| | | | | | | | | | | | Fixed SRC_URI: * ${PN} -> ${BPN}, use ${BP} if it was ${PN}-${PV} * ${P} -> ${BP} Otherwise we would meet do_fetch errors when we do the multilib, native or nativesdk build. Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* breakpad.bbclass: set includedir in CXXFLAGSAnders Darander2014-05-031-0/+1
| | | | | | | | | | Previously this was only set in CFLAGS. An build issue was discovered while convering in internal application from Qt4 to Qt5. As a result of this, the required header files were no longer found, until we also set CXXFLAGS. Signed-off-by: Anders Darander <anders@chargestorm.se> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* breakpad: add initial recipeAnders Darander2013-10-211-0/+32
| | | | | | | | | | | Breakpad is an open-source multi-platform crash reporting system. Apart from the breakpad recipe, add a bbclass for applications that want to use this library. This bbclass will set up the include path and also generate the symbol file. Signed-off-by: Anders Darander <anders@chargestorm.se> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* classes/vala: removePaul Eggleton2013-09-031-18/+0
| | | | | | | This is now in OE-Core as of 807285c751862aaa775db5a13293007bfb3c29df. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
* recipes: Unify indentationMartin Jansa2013-04-152-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | * This change is only aesthetic (unlike indentation in Python tasks). * Some recipes were using tabs. * Some were using 8 spaces. * Some were using mix or different number of spaces. * Make them consistently use 4 spaces everywhere. * Yocto styleguide advises to use tabs (but the only reason to keep tabs is the need to update a lot of recipes). Lately this advice was also merged into the styleguide on the OE wiki. * Using 4 spaces in both types of tasks is better because it's less error prone when someone is not sure if e.g. do_generate_toolchain_file() is Python or shell task and also allows to highlight every tab used in .bb, .inc, .bbappend, .bbclass as potentially bad (shouldn't be used for indenting of multiline variable assignments and cannot be used for Python tasks). * Don't indent closing quote on multiline variables we're quite inconsistent wheater it's first character on line under opening quote or under first non-whitespace character in previous line. Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com> Acked-by: Koen Kooi <koen@dominion.thruhere.net>