aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/contrib
AgeCommit message (Collapse)Author
2014-07-03scripts/contrib/verify-homepage.py: add a script to verify HOMEPAGEChong Lu
Add a script to verify all the recipes' HOMEPAGE. [YOCTO #5689] Signed-off-by: Chong Lu <Chong.Lu@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-25list-packageconfig-flags: improve option parsingPaul Eggleton
* Use optparse instead of getopt (less code & automatic help) * Change help text / output to use "recipe" instead of "package" * Print something to indicate the script is still gathering information Note that the long options have been renamed as appropriate. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-06-25list-packageconfig-flags: filter out doc and defaultval varflagsPaul Eggleton
These are generic flags and shouldn't be listed in the output of this script. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-06-25scripts: consolidate code to find bitbake pathPaul Eggleton
Several of these scripts were using duplicated code (and slightly different methods) to find the path to bitbake and add its lib subdirectory to the Python import path. Add some common code to do this and change the scripts to use it. Fixes [YOCTO #5076]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-06-24mkefidisk.sh: Allow symlink for deviceDarren Hart
Allow the user to specify a symlink as the host device. If a link is used, mkefidisk will now dereference it and use the link target when looking for sysfs information. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-06generate-manifest-2.7.py: Add importlibMatt Fleming
importlib isn't currently included in any of the python packages, so create a new one for recipes that require it. Cc: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Matt Fleming <matt.fleming@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-06-06generate-manifest-3.3.py: Add importlibMatt Fleming
importlib isn't currently included in any of the python packages, so create a new one for recipes that require it. Cc: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Matt Fleming <matt.fleming@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-05-28ddimage: Support Mac OSDarren Hart
Update the ddimage script to allow it to work on Mac OS too. The biggest difference is sysfs vs diskutil and in the syntax of the stat command between Mac OS and Linux, unfortunately. Workarounds using ls, cut, and columns got really fragile really quickly. Relying on stat and switching on uname seemed the more robust solution. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Cc: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-04-30scripts/contrib/dialog-power-control: add a trivial power prompt scriptPaul Eggleton
If you want to do automated hardware testing but don't have a controllable power strip this script can be useful so that you know when you need to cycle the power. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-04-30scripts/contrib/serdevtry: add script to handle transient serial terminalsPaul Eggleton
When running automated tests (or just generally interacting with) boards whose serial console devices are on the board itself and thus disappear when powered down or practically disconnected, such as the BeagleBone white, some terminal programs (e.g. picocom) will exit when the device disappears and need to be restarted after the serial device returns. This script handles this automatically for such terminal programs. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-21python3: sync module dependencies from 2.7Paul Eggleton
These have been added recently to 2.7 but were missing in the 3.3 script/inc file. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-03-21generate-manifest-3.3.py: sync descriptions with 2.7 versionPaul Eggleton
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2014-03-21generate-manifest-2.7.py: sync with python-2.7-manifest.incPaul Eggleton
Some changes were made earlier by me to SUMMARY values in python-2.7-manifest.inc without changing the manifest script. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-21generate-manifest-*.py: set SUMMARY instead of DESCRIPTIONPaul Eggleton
Typically what's being set here is a short description, so it makes much more sense to set SUMMARY. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-03-21python: add python-mmap to python-multiprocessing RDEPENDSPaul Eggleton
The multiprocessing module needs the mmap module. We got away with not having this for the build appliance because python-mmap was added to packagegroup-self-hosted, but this is the proper place to have it. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2014-02-02generate-manifest-3.3.py: Add script to generate python 3.3 manifestsKhem Raj
Bases on python 2.7.x generator Package collections/ in python-core Signed-off-by: Khem Raj <raj.khem@gmail.com>
2013-12-18scripts/contrib: Add graph-toolPaul Eggleton
A simple script I put together for getting the paths from one node to another in a dot graph. This is useful for example in working out why a particular recipe is getting built in conjunction with dot graph files produced by bitbake -g. For example: $ bitbake -g core-image-minimal ... $ graph-tool find-paths pn-depends.dot core-image-minimal util-linux core-image-minimal -> packagegroup-core-boot -> udev -> glib-2.0 -> python-dbus -> dbus-glib -> dbus -> libsm -> e2fsprogs -> util-linux core-image-minimal -> packagegroup-core-boot -> udev -> glib-2.0 -> python-dbus -> dbus -> libsm -> e2fsprogs -> util-linux core-image-minimal -> packagegroup-core-boot -> udev -> util-linux Partially addresses [YOCTO #3362]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-12-06python: Add missing RDEPENDS for python-unittestMike Looijmans
After installing python-unittest, the following errors occur when executing "import unittest" from a python commandline: ImportError: No module named StringIO ImportError: No module named pprint ImportError: No module named difflib ImportError: No module named pprint ImportError: No module named fnmatch Fix this by adding the missing dependencies to the generator script and run the generator. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-30mkefidisk.sh: Allow using a loopback mounted fileJason Wessel
It should be possible to generate a disk to a file using a loopback device with mkefidisk.sh, which is useful for booting simulators. To make this possible the partitions for the loop back need to work similarly to the mmc devices. The mkfs.vfat also requires and additional argument to force it to write to something other then a real disk. Example: qemu-img create -f raw bigdisk 4G dev=`sudo losetup -f` sudo losetup $dev bigdisk mkefidisk.sh $dev tmp-eglibc/deploy/images/qemux86/core-image-minimal-qemux86.hddimg /dev/sda sudo losetup -d $dev Note: Also a bug was fixed in the mkefidisk.sh where if the disk you are writing to initially has an invalid label the size of the first partition will be computed incorrectly. For the simulator disk creation this is generally always the case, but this can happen with real hardware as well. Signed-off-by: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-14scripts/contrib/build-perf-test.sh: record size in kb and remove extra spacesStefan Stanacar
Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-12bb-matrix-plot: Use interpolation for sparse dataPeter Kjellerstedt
If not every combination of BB_NUMBER_THREADS and PARALLEL_MAKE have been tested by bb-matrix.sh, e.g., by using BB_RANGE="04 08 10 12 16" and PM_RANGE="04 08 10 12 16", then the graph that gnuplot generates by default looks very jagged due to the missing data points. By using splines to interpolate the missing data the graph looks a lot better. This should not change graphs where all data points are available in any way, only improve sparse graphs. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-09-12bb-matrix: Clean before, rather than after, buildingPeter Kjellerstedt
This makes sure the the first build starts from a clean state. Otherwise one could have the first build affected by any leftover state from a previous build. This also leaves a working state behind after the final build. Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-30list-packageconfig-flags.py: fix searching bitbake module failedHongxu Jia
Run list-packageconfig-flags.py on wrlinux's platform in which the oe-core layer and bitbake layer in different directories: ---- ../layers/oe-core/scripts/contrib/list-packageconfig-flags.py Traceback (most recent call last): File "../layers/oe-core/scripts/contrib/list-packageconfig-flags.py", line 28, in <module> import bb.cache ImportError: No module named bb.cache ---- The script import bb module from bitbake lib dir, the previous lib dir was hardcode and only worked on poky but not for others. In this situation, look for bitbake/bin dir in PATH could fix this issue. [YOCTO #5060] Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-26python-2.7-manifest: Add missing python-ctypes dependency to ↵Richard Purdie
python-multiprocessing Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-08-05list-packageconfig-flags.py: add a script to list all PACKAGECONFIG flagsHongxu Jia
- This script will list available pkgs which have PACKAGECONFIG flags. - If option '-f' is used, it will list available PACKAGECONFIG flags and all affected pkgs. - If option '-a' is used, it will list all pkgs and PACKAGECONFIG information - If option '-p' is used, it means list the pkgs with preferred version EXAMPLE: list-packageconfig-flags.py PACKAGE NAME PACKAGECONFIG FLAGS ============================================================== alsa-tools-1.0.26.1 defaultval gtk+ avahi-ui-0.6.31 defaultval python bluez4-4.101 alsa defaultval pie list-packageconfig-flags.py -f PACKAGECONFIG FLAG PACKAGE NAMES ==================================== 3g connman-1.16 avahi cups-1.6.3 pulseaudio-4.0 beecrypt rpm-5.4.9 rpm-native-5.4.9 list-packageconfig-flags.py -a ================================================== gtk+-2.24.18 /home/jiahongxu/yocto/poky/meta/recipes-gnome/gtk+/gtk+_2.24.18.bb PACKAGECONFIG x11 PACKAGECONFIG[x11] --with-x=yes --with-gdktarget=x11,--with-x=no,${X11DEPENDS} xf86-video-intel-2.21.9 /home/jiahongxu/yocto/poky/meta/recipes-graphics/xorg-driver/xf86-video-intel_2.21.9.bb PACKAGECONFIG None PACKAGECONFIG[xvmc] --enable-xvmc,--disable-xvmc,libxvmc PACKAGECONFIG[sna] --enable-sna,--disable-sna [YOCTO #4368] Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-08-05scripts/contrib/mkefidisk.sh: fix bashismChen Qi
Remove the function keyword. Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-07-18scripts/contrib/*: fix arithmetic bashismPaul Eggleton
Apparently $[...] isn't valid in dash, so use $((...)) instead for mkefidisk.sh and ddimage that both start with $!/bin/sh. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-06-28python-multiprocessing: adding runtime dependenciesLukas Bulwahn
As python-multiprocessing requires python-threading and python-pickle, this commit adds them as runtime dependency. The observed behavior was: When typing 'import multiprocessing' in the python shell on a minimal image with only the python-multiprocessing recipe installed, python reports at first: Python 2.7.3 (default, Jun 27 2013, 08:26:25) [GCC 4.7.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import multiprocessing; Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python2.7/multiprocessing/__init__.py", line 65, in <module> from multiprocessing.util import SUBDEBUG, SUBWARNING File "/usr/lib/python2.7/multiprocessing/util.py", line 38, in <module> import threading # we want threading to install it's ImportError: No module named threading After adding python-threading as runtime dependency and rebuilding the image, python reports: Python 2.7.3 (default, Jun 27 2013, 08:26:25) [GCC 4.7.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import multiprocessing; Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python2.7/multiprocessing/__init__.py", line 84, in <module> import _multiprocessing ImportError: No module named cPickle Signed-off-by: Lukas Bulwahn <lukas.bulwahn@oss.bmw-carit.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-06-13scripts/contrib/build-perf-test.sh: fix passing argumentsStefan Stanacar
Don't pass arguments to bitbake as a single one, because this will break when the bitbake double-exec is removed. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-06-13scripts/contrib/build-perf-test.sh: add branch name and sizes to resultsStefan Stanacar
Be more descriptive about the revision we are running on in the global results file: add branch:commit and git describe fields. Also add the sizes for tmp dir not only times. (previously these were only available in the output.log) Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-06-10ddimage: fix incompatibility with dashHongxu Jia
On systems with dash as /bin/sh there were failures while invoking ddimage. Fix to let it work with both bash and dash shells. [YOCTO #4617] Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-05-02mkefidisk: Unmount after partitioningDarren Hart
Some automounters are rather overzealous and like to mount things immediately after partitioning. This can happen if the disk is being reused and the partitions align exactly with the existing partitions which have already been formatted. Move the unmount code into a function and call it before and after partitioning. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-04-29scripts/contrib/build-perf-test.sh: change the global results formatStefan Stanacar
When all builds have finished write the hostname, commit and times on a single line in the global results file (useful for merging later on files from multiple systems). Also the final cleaning should be last after writing the results. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-04-29scripts/contrib/build-perf-test.sh: skip network sanity testsStefan Stanacar
When your proxy/network connection is unstable the network sanity test which runs before every build (because we wipe all the files in the build dir) can influence build time. Appending CONNECTIVITY_CHECK_URIS = "" in local.conf will disable the check. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-04-29scripts/contrib/build-perf-test.sh: use the same identation everywhereStefan Stanacar
Some functions didn't used the same identation as the rest of them, let's fix that. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-04-29mkefidisk: Attempt to automatically unmount target deviceDarren Hart
With automounters abounding it makes more sense to attempt to unmount the device rather than abort, just like ddimage does. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com>
2013-04-04python: adding missing runtime dependency python-io to python-pprintLukas Bulwahn
When trying to import python-pprint on a minimal image, it reports that the cStringIO python module is missing. This is provided with python-io, so we add python-io as runtime dependency. The complete observed trace was: Python 2.7.3 (default, Apr 4 2013, 07:45:36) [GCC 4.7.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import pprint Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python2.7/pprint.py", line 40, in <module> from cStringIO import StringIO as _StringIO ImportError: No module named cStringIO Signed-off-by: Lukas Bulwahn <lukas.bulwahn@oss.bmw-carit.de> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-29scripts/contrib/build-perf-test.sh: add timings for bitbake -pStefan Stanacar
Add another test to time bitbake -p with and without cache/ or tmp/cache. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-29scripts/contrib/build-perf-test.sh: add option to allow cherry-picking of ↵Richard Purdie
fix revisions Adds a -p option to allow cherry-picking of fix revisions. Removes the final build/sstate directories to stop running out of space. Runs subsequent tasks even if one test fails. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-29scripts/contrib/build-perf-test.sh: add a global results fileStefan Stanacar
Append results from each run to a single file in order to keep a history. Also do some cosmetic changes and fix some whitespace. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-29scripts/contrib/build-perf-test.sh: add a script for build performance trackingStefan Stanacar
This script runs a series of builds (core-image-sato by default) with and without sstate cache and collects some metrics (time and size currently). It takes a commit as argument (-c <rev>) and measures wall clock for bitbake core-image-sato and virtual/kernel. Signed-off-by: Stefan Stanacar <stefanx.stanacar@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-22mkefidisk: Use msdos partition tablesDarren Hart
While GPT works fine when writing to actual media, it cannot be reliably used for distributing disk images as it requires the backup table to be on the last block on the device, which of course varies from device to device. Use MSDOS tables instead. Use mkfs to label the filesystems as msdos tables do not support partition labeling. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-22mkefidisk: Remove startup.nshDarren Hart
Most firmware implementations use the EFI specified EFI/BOOT/bootia32.efi (and similar) boot paths. Only broken firmware uses different paths for removable media. In those cases, the user can add their own startup.nsh. For the compliant case, selecting "Shell" from the EFI boot menu should go to the shell. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-22mkefidisk: Always use rootwait and document kernel parameters usedDarren Hart
Without a reliable way of knowing if the target device with be an asyncronous block device on the target (MMC or USB), err on the side of caution of always specifcy "rootwait", ensuring the kernel will wait for the device to appear and not abort if it hasn't appeared in time for mount. Document the remaining kernel parameters added by this script on the same line as rootwait. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-22mkefidisk: Boot with ro kernel parameter instead of rwDarren Hart
There is no need to boot with "rw". Booting with "ro" will allow for fsck to be run during boot, and a proper /etc/fstab will still ensure the rootfs is "rw" by the time the user can interact with the system. Change the "rw" to "ro" in the kernel parameters specified in the generated grub.cfg file. Fixes [YOCTO 4036] mkefidisk.sh hardcodes 'rw' as root mount option Signed-off-by: Darren Hart <dvhart@linux.intel.com> Cc: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-22mkefidisk: Cleanup comment lengthDarren Hart
Keep comments under 80 characters in length. Signed-off-by: Darren Hart <dvhart@linux.intel.com> Cc: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-22mkefidisk: Always specify a root= kernel parameterDarren Hart
The current script only replaces an existing root= kernel parameter which can result images created without a root= paremeter, even though the script expects a target rootfs parameter. Rather than replacing the root= parameter, delete the root= parameter if it exists, then append an appropriate root= parameter. Fixes [YOCTO 4035] mkefidisk.sh forgets to add root= parameter Signed-off-by: Darren Hart <dvhart@linux.intel.com> Cc: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-18mkefidisk.sh: create a proper ESPKoen Kooi
The script was creating a FAT fs with EFI files in it, but wasn't setting the GPT GUID. Using 'gummiboot install' natively failed because of the missing GPT GUID, so fix that. While we're there also set the name to "EFI System Partition". Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> Acked-by: Darren Hart <dvhart@linux.intel.com> Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-03-09mkefidisk.sh: Cope with translations and modelnames with 'Disk' in it.Koen Kooi
The script greps for 'Disk', which doesn't work when your crazy Dutch distro has parted call it 'Schijf', so force LANG=C. The second problem is that 'Disk' might be a substring in the Model entry: [root@Angstrom-F16-vm-rpm contrib] # parted /dev/sdc unit mb print Model: SanDisk SDDR-113 (scsi) Disk /dev/sdc: 3905MB Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-14Python: Add missing dependency "textutils" to "io" packageMiLo
Modify the include file and script to generate a missing RDEPENDS. Install python on target with python-io. Import ssl: Python 2.7.3 (default, Feb 9 2013, 16:04:35) [GCC 4.7.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import ssl Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/lib/python2.7/ssl.py", line 58, in <module> ImportError: No module named textwrap Installing python-textutils solves the issue. Signed-off-by: MiLo <milo-software@users.sourceforge.net> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>