aboutsummaryrefslogtreecommitdiffstats
path: root/scripts
AgeCommit message (Collapse)Author
2012-05-06runqemu: be sh neutralBernhard Reutner-Fischer
Now runs with dash and busybox' ash as well as with bash Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-06runqemu: minor tweaksBernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-06runqemu: add and use error()Bernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-06runqemu: simplify process_filename()Bernhard Reutner-Fischer
Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-06runqemu: use modern, single-char name of test(1)Bernhard Reutner-Fischer
I do not have "[[", just "[". Be gentle to users of legacy-free setups, also by using '=' instead of the double notation. Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-06runqemu: Use OE_TMPDIRBernhard Reutner-Fischer
The error message erroneously talked about TMPDIR. Just use OE_TMPDIR everywhere to make the name of the variable obvious. Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-06terminal.bbclass, oe-buildenv-internal: pass SCREENDIR environment variableJason Wessel
Some versions of the screen utility provided from the host OS vendor write the socket directory to $HOME/.screen. When using a shared home directory across many servers, one sets the SCREENDIR environment variable to avoid collisions in the shared home directory. This results in problems launching a devshell where it is not entirely obvious what happened because the SCREENDIR environment variable got stripped from the environment prior to setting up the screen in detached mode. Example: % bitbake -c devshell busybox # ...Please connect in another terminal with "screen -r devshell" % screen -r devshell There is no screen to be resumed matching devshell. The temporary work around was to do something like: sh -c "unset SCREENDIR; screen -r devshell" This patch adds SCREENDIR to the white list to ensure screen works properly on systems where a developer needs to use the SCREENDIR with shared home directories. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-03runqemu: Fix TAP='TUNSETGROUP: Invalid argument' by falling back to tunctl -uJason Wessel
By default the runqemu script tries to set the group permissions on any tap device it creates. The TUNSETGROUP ioctl is not implemented on some popular host enterprise linux distributions. Internally the script will exit as follows: ++ /opt/qemux86/bitbake_build/tmp/sysroots/x86_64-linux/usr/bin/tunctl -b -g 100 + TAP='TUNSETGROUP: Invalid argument' + STATUS=1 + '[' 1 -ne 0 ']' + echo 'tunctl failed:' tunctl failed: + echo TUNSETGROUP: Invalid argument This patch implements a fallback to using the userid as the owner of the tap device which is supported by all 2.6 kernels, the default remains to try and use the groupid first. Signed-off-by: Jason Wessel <jason.wessel@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-03create-recipe: base on autospectacle.pl to create recipe fileKang Kai
[Yocto 1656] create-recipe is based on original autospectacle.pl from project Meego. Add feature to create a recipe .bb file. It requires a parameter to be told where to download source package, then download and parse. Create recipe file according to parse results. Signed-off-by: Kang Kai <kai.kang@windriver.com>
2012-05-03autospectacle.pl: pull it from meego as a baseKang Kai
This autospectacle.pl is from meego project http://meego.gitorious.org/meego-developer-tools/autospectacle And take its latest commit f462b759c6f569f35283d0885c97ae53b010bb03 as base of Yocto 1656: Recipe creation/import script. Signed-off-by: Kang Kai <kai.kang@windriver.com>
2012-04-27package_rpm: Only rebuild the indexes if the packages have changedRichard Purdie
This change farms the solvedb creation out to a separate script which handles creation of the index, only if mtime of any of the packages has changed. For a core-image-minimal set of rpm's this saves ~20s of a 45s rootfs build. For core-image-sato it saves 1 minute of a 5 minute rootfs build. The more packages in the system, the bigger the saving will be. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-04-25runqemu-ifup: enable ip masquerading for QEMU NAT addressesScott Garman
Fix the IP masquerading settings so that networked QEMU sessions can reach external networks. This is a partial fix for [YOCTO #2329]. Signed-off-by: Scott Garman <scott.a.garman@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-04-23scripts/hob: disable sanity checks when launchingJoshua Lock
This enables us to use the GUI to change any settings which might cause sanity checks to fail, such as the proxy configuration. Signed-off-by: Joshua Lock <josh@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-04-11python: multilib header support.Lianhao Lu
Add intercept multilib header for pyconfig.h in python. This is part of the bug fixing [YOCTO #2216]. Signed-off-by: Lianhao Lu <lianhao.lu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-04-10create-pull-request: Assume remote branch from local branchDarren Hart
It is common to use the same remote branch name as the local branch name. In this case, it would be nice not to have to specify the remote branch name. Make the -b argument optional and assume the remote branch is the same name as the local branch. Print a NOTE to this effect so as not to catch the user by surprise: NOTE: Assuming remote branch 'notthere', use -b to override. If the remote branch doesn't exist, a WARNING is displayed just as if the user had used -b to specify a non-existent branch: WARNING: Branch 'notthere' was not found on the contrib git tree. Please check your remote and branch parameter before sending. Signed-off-by: Darren Hart <dvhart@linux.intel.com>
2012-04-06runqemu-internal: Add console=tty for qemuppc and NFSSaul Wold
Adding this to the nfs to match the ext3 kernelcmdline, this re-enables keyboard input on the qemuppc. [YOCTO #2058] Thanks to Yi Zhao <yi.zhao@windriver.com> for the initial patch suggestion Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-04-02qemugl: Fix GL apps failure on Ubuntu 11 host with nVidia GLX driverZhai Edwin
Previous version of nVidia GLX driver in Ubuntu 10 cause qemu segfault, so we fall back to Mesa GLX driver if detecting nVidia driver installed. From Ubuntu 11, nVidia GLX driver works well, while previous work around cause GL apps failure. So this work around is limited in Ubuntu 10 only, and will be removed in future. [YOCTO #1886] got fixed. Signed-off-by: Zhai Edwin <edwin.zhai@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-31scripts/bitbake: add/fix some commentsPaul Eggleton
Add some comments explaining what this script does, fix one grammatical error in a comment and make the tar-replacement-native comment give the full reason why it is needed. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2012-03-31scripts/bitbake: allow switching between build directoriesPaul Eggleton
The recent addition of the check to ensure the user was in their build directory disabled the ability to switch between build directories without re-running the build environment setup script. We can rely upon checking for conf/bblayers.conf instead, so use this check. This does allow BUILDDIR (which is normally set by the environment script) to be unset; however if it is set then it is assumed to be the correct build directory and will be used in the error message that is shown when we can't find conf/bblayers.conf. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2012-03-31scripts/bitbake: try harder to check if pseudo existsPaul Eggleton
If pseudodone doesn't exist, we can get STAGING_BINDIR_NATIVE by calling bitbake -e and use that as the path to check for pseudo before we give up and try to build it explicitly first. This is useful for people who share TMPDIR between multiple build directories. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2012-03-30sstate-cache-management.sh: fixes and enhancementRobert Yang
Fix a few problems and enhance its functions, it shoud be more useful than before. * Search in meta and meta-* for archs, and grep AVAILTUNES for archs, (only search meta, and grep DEFAULTTUNE before), add the host arch. and also can search in extra layers with --extra-layer. * Reduce the analyzing time when remove duplicated files. It would cost more than 10 minutes to analyze 11,000 files before, now only needs about 50 seconds. * Check the access time rather than create time. * Need the user's confirm before really remove the file, or use --yes to assume yes. * Add --stamps-dir to keep sstate files which are used by the build directory, and remove others this can make the sstate cache dir clean, it is faster and should be useful than the --remove-duplicated. * Add --verbose to explain what is being done. * Add "-d" which is short for --remove-duplicated [YOCTO #2198] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-29runqemu: set console=ttyS0 when running with nographic optionScott Garman
When passing the nograhic option to the runqemu script, set console=ttyS0 in the kernel options so the user can view the kernel boot messages. This fixes [YOCTO #1475] Signed-off-by: Scott Garman <scott.a.garman@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-28scripts/bitbake: Update to help rebuild pseudo-nativeMark Hatle
Attempt to detect when pseudo-native has been updated. If it has been updated, or if the user is attempting an operation with pseudo-native in the name, force a build of pseudo-native, prior to running the main build. Note: This causes a build, then clean in the case of bitbake -c cleansstate pseudo-native Signed-off-by: Mark Hatle <mark.hatle@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-26python: fix packaging dependencies on minimal systemsGary Thomas
If you install the top-level python package only on a minimal system which has no other python packages installed then python is not functional at all. Without any extra packages installed this error is seen: # python Traceback (most recent call last): File "/usr/lib/python2.7/site.py", line 64, in <module> import traceback ImportError: No module named traceback Installing python-lang only partly fixes the problem as this error still exists: # python Traceback (most recent call last): File "/usr/lib/python2.7/site.py", line 569, in <module> main() File "/usr/lib/python2.7/site.py", line 551, in main known_paths = addusersitepackages(known_paths) File "/usr/lib/python2.7/site.py", line 278, in addusersitepackages user_site = getusersitepackages() File "/usr/lib/python2.7/site.py", line 253, in getusersitepackages user_base = getuserbase() # this will also set USER_BASE File "/usr/lib/python2.7/site.py", line 243, in getuserbase USER_BASE = get_config_var('userbase') File "/usr/lib/python2.7/sysconfig.py", line 520, in get_config_var return get_config_vars().get(name) File "/usr/lib/python2.7/sysconfig.py", line 400, in get_config_vars import re ImportError: No module named re Signed-off-by: Gary Thomas <gary@mlbassoc.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-26Various typoes fixed, all comments or output strings.Robert P. J. Day
Typoes fixed: "enviroment", "editted", "spliting", "scheulder". Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-26qemu: add fedora pkg names when build failedRobert Yang
When qemu build failed, we can see such messages: You need libGL.so and libGLU.so to exist in your library path and the development headers for SDL installed to build qemu-native. Ubuntu package names are: libgl1-mesa-dev, libglu1-mesa-dev and libsdl1.2-dev These pkgs have different names on Fedora distributions, and Fedora is one the main linux distributions, so add Fedora package names. The following Fedora versions have these pkgs: Fedora 9 64bit Fedora 13 32bit Fedora 13 64bit Fedora 16 64bit [YOCTO #2174] Signed-off-by: Robert Yang <liezhi.yang@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-23scripts/combo-layer: handle diffs in commit messagesPaul Eggleton
A few recent commits in the OE-Core repository contain diffs in their commit messages, which totally confuses git-am when applying them to the combo repository during update. Add some code to detect and indent any diff text in the commit message so that this does not happen (and show a warning). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-23scripts/combo-layer: limit component repo dirty checkPaul Eggleton
If one or more components are specified for update, only check if their repository/repositories are dirty rather than checking all of the configured repositories. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-22ddimage: Add script for writing images to boot mediaDarren Hart
Fixes [YOCTO #1806] Standard practice is to use the Linux "dd" command to write images to boot media. This can be error prone and the results of sloppy usage can be disastrous. Locating the device you want to use is a clumsy process, especially on a headless build system. The ddimage script does the following: o Check the image and device exist o Check the device is writable o Compare the device to a blacklist and abort if it's listed Blacklist defaults to "/dev/sda" o Display useful identifying information about the image and device o Prompt the user before commencing the write The output looks something like this: $ sudo ~/bin/ddimage tmp/deploy/images/core-image-sato-fri2-noemgd.hddimg /dev/sdk Image details ============= image: `tmp/deploy/images/core-image-sato-fri2-noemgd.hddimg' -> `core-image-sato-fri2-noemgd-20111202214038.hddimg' size: 318568448 bytes modified: 2011-12-02 13:45:05.298897861 -0800 type: x86 boot sector, code offset 0x58, OEM-ID "SYSLINUX", sectors/cluster 16, root entries 512, Media descriptor 0xf8, sectors/FAT 152, heads 64, hidden sectors 32, sectors 622204 (volumes > 32 MB) , serial number 0x4ed946e0, label: "boot ", FAT (16 bit) Device details ============== device: /dev/sdk vendor: Kingston model: DT 101 G2 Write tmp/deploy/images/core-image-sato-fri2-noemgd.hddimg to /dev/sdk [y/N]? y Writing image... 303+1 records in 303+1 records out 318568448 bytes (319 MB) copied, 53.6766 s, 5.9 MB/s Signed-off-by: Darren Hart <dvhart@linux.intel.com> CC: Dexuan Cui <dexuan.cui@intel.com> CC: Joshua Lock <josh@linux.intel.com> CC: Kishore K Bodke <kishore.k.bodke@intel.com>
2012-03-21buildhistory_analysis: use bb.utils.explode_dep_versionsPaul Eggleton
Previously this had its own implementation of splitting a list of packages with optional version e.g. "libncurses-dev (>= 5.9)"; switch to using the already existing bitbake function which does this as it is much better tested. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-21scripts/qemuimage-testlib: fix typosYi Zhao
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-21cleanup-workdir: add a script to clean up WORKDIRKang Kai
[Yocto 1561] Add script cleanup-workdir to clean up WORKDIR. It checks every package build directories under WORKDIR then parse the directory name to get package name and version. If the version is not the package prefer version then delete the directory. Signed-off-by: Kang Kai <kai.kang@windriver.com>
2012-03-14scripts/bitbake: ensure user is in build directoryPaul Eggleton
If the user is in any directory other than $BUILDDIR when the bitbake wrapper script is run, then show an error an exit. Fixes [YOCTO #2071]. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
2012-03-14scripts/contrib/python/generate-manifest-2.7.py: Catch up with staticdev fixesRichard Purdie
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-02scripts/oe-git-proxy-socks-command: Add fallback to use ncRichard Purdie
If our own proxy command isn't available for some reason and nc is available, fall back to use it. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-03-02scripts/oe-git-proxy-socks-command: Improve error fallback/handlingRichard Purdie
If oe-git-proxy-socks isn't available, try and create it. If that fails, tell the user there is a problem, don't just fail to find the command. [YOCTO #2007] Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28scripts/prserv-tool: Adepted to new bitbake cache.Lianhao Lu
Adepted to the new bitbake cache mechanism which is based on file content but not on file timp stamps any more. Signed-off-by: Lianhao Lu <lianhao.lu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24scripts/hob: Launch the new hobDongxiao Xu
Change the scripts to launch the new Hob. Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23A script to clean obsolete sstate cache filesRobert Yang
There would be many obsolete cache files in the SSTATE_DIR after several builds, this script can remove the obsolete one for a pkg, only leave the up to date one. Here is the help text: sstate-cache-management.sh <OPTION> Options: --help, -h Display this help and exit. --cache-dir=<sstate cache dir> Specify sstate cache directory, will use the environment variable SSTATE_CACHE_DIR if it is not specified. --remove-duplicated Remove the duplicated sstate cache files of one package, only the newest one would be kept. [YOCTO #1682] Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
2012-02-21scripts/combo-layer: allow updating a specific component(s) onlyPaul Eggleton
If you specify one or more components to update immediately following the "update" command, only these components will be updated as opposed to the default behaviour of updating all of them. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21scripts/combo-layer: add branch option to example configPaul Eggleton
Minor improvements to the example combo-layer config file: * Add the recently added branch option to the optional options section * Mention in comments that last_revision gets updated during "update" * Tidy up some more grammar Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21scripts/combo-layer: avoid saving last revision if unchangedPaul Eggleton
If we are running an update and the last revision hasn't changed since the last update, don't write to the configuration file. This avoids committing the config file with no changes other than spontaneous reordering of sections, which sometimes occurs due to the behaviour of the internal dictionary in Python's ConfigParser class. (This can be fixed properly but the fix is only easy in Python 2.7+ due to the availability there of the collections.OrderedDict class, and we currently want to be compatible with 2.6.x as well.) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21scripts/combo-layer: avoid error when config file is outside repoPaul Eggleton
Avoid displaying the error from the "git status" command we use to check the status of the config file if the config file is outside of the repository (a situation that is already handled). Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21scripts/bitbake: pass through debug options to initial pseudo buildPaul Eggleton
If you specify -D or -v options to the bitbake wrapper script, and the initial pseudo build needs to be done, it's useful to pass these options through to that command so that you can debug the initial pseudo build as well. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-07runqemu-internal: qemuarm can handle 256MKhem Raj
Raise the check for max RAM supported for QEMU/arm its 256M since we patched it to be so in OE Signed-off-by: Khem Raj <raj.khem@gmail.com>
2012-01-24documentation-audit.sh: remove COMMERCIAL_LICENSE warningTom Zanussi
COMMERCIAL_LICENSE no longer exists; the equivalent functionality is now has been replaced by LICENSE_FLAGS_WHITELIST, so replace the COMMERCIAL_LICENSE warning with a similarly equivalent warning. Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
2012-01-24qemuimage-testlib: rename qemuppc imageSaul Wold
A recent set of changes changed the kernel name from bzImage to vmlinux, this test needs to change also. Signed-off-by: Saul Wold <sgw@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24linux-yocto/qemuppc: fix console and ethernetBruce Ashfield
Two issues are fixed with this commit, the ability to use the keyboard on a graphical qemu boot and enabling ethernet by default on a 3.0 kernel. The keyboard is fixed via the same method as the other simulations with the addition of console=tty on the qemu command line. Ethernet is fixed by adding a dependency of PCNET32 to the qemuppc configuration, which allows us to build ethernet directly into the image. Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17runqemu: Fix the wrong path of libGL.so in 64b Ubuntu 11.10Zhai Edwin
From 11.10, libGL.so is installed @ /usr/lib/x86_64-linux-gnu/ in 64b Ubuntu. [YOCTO #1885] got fixed Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
2012-01-17qemuppc: replace emulation of qemuppc from prep to mac99Liming Wang
With this new emulation, existing qemuppc functionality is maintained and other functionality such as framebuffer + sato and NFS boot are added. Signed-off-by: Liming Wang <liming.wang@windriver.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>