Compare commits

..

583 Commits

Author SHA1 Message Date
Paul Eggleton
320558f494 More quoting fixes
(From OE-Core rev: 17f2d5d70ad323cea4fb149154bc38844661fa3a)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-29 13:12:13 +00:00
Richard Purdie
0cfceaa53b parse/ConfHandler: Fix enthusiatic export regexp matching
The export regexp was only meant to catch values like:

export VARIABLENAME

however after the stricter quoting patch was applied, it was also matching
variables like:

export BAR=foo

and setting the export flag on a variable called "BAR=foo". The = character
is an invalid variable name character. This patch tightens up the regexp
match so it only matches the intended character set and only matches variable
names.

(Bitbake rev: 6d1765c2eac8c1958ceb9c81d55d04a9bc961cb1)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-29 13:12:12 +00:00
Otavio Salvador
7fee190f67 image_types.bbclass: fix bzip2 and xz compression commands
We need to use -f (force) or the command fails in the image file
already exists.

(From OE-Core rev: 419ddab8266ecfd6da1841d38a451a9fc5be49b0)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-29 12:56:45 +00:00
Otavio Salvador
c97ebae788 image_types.bbclass: properly support IMAGE_LINK_NAME as empty
[RP: Remove unneeded len()]
(From OE-Core rev: 45a094372ea9e68888efee45d8e21cf2b7fa2df6)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-29 12:56:44 +00:00
Otavio Salvador
05c7d5d512 image.bbclass: do not create image manifest link if IMAGE_LINK_NAME is empty
(From OE-Core rev: d0f1ae1f8cf8ef4e5adc24cc6246d3849e51aa98)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-29 12:56:44 +00:00
Otavio Salvador
a4624063ed syslinux: fix packaging of ${PN} and ${PN}-staticdev
- ${PN} where not being build due ordering;
 - ${PN}-staticdev lacked the ${libdir} files.

(From OE-Core rev: e83b2e25ebf0169371035483095a06b3ca5eb479)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-29 12:52:55 +00:00
James Limbouris
426b7fd111 busybox: Enable 64 bit shell tests, and disable non-standard date format interpretation.
Without 64 bit shell tests, the timestamp comparison in initscripts' bootmisc.sh throws 'out of range' errors.
With CONFIG_FEATURE_DATE_COMPAT, date reads the YYYYMMddhhmm string as hhmmYYYYMMdd when setting the time from the timestamp in bootmisc.sh.

(From OE-Core rev: e32e23649f4eab0bdc71a854f99b11fee19125ac)

Signed-off-by: James Limbouris <james@digitalmatter.com.au>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-29 12:52:55 +00:00
Otavio Salvador
d86e3082e6 licenses.conf: fix quotting of SRC_DISTRIBUTE_LICENSES
(From OE-Core rev: 61216d2743502ef38955054aad6a4f2ed63e6d43)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 17:51:52 +00:00
Richard Purdie
2474e6c55c tcl: Ensure native verison has correct dependencies and builds
(From OE-Core rev: 9b63fbb5f41d8a7167bbb534da03908c996693ad)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 17:51:51 +00:00
Saul Wold
7f67843c32 bootimg: Fix Quoting
(From OE-Core rev: 18ad7e003e36510ff0097d71bad0378a77fabbdd)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 17:51:51 +00:00
Otavio Salvador
2684714480 syslinux: bump PR
The change done in 868a81e869a6193aada2073ae533d937a1c0baf4 has
changed the packaging however it haven't bump the PR making
auto-building fail.

(From OE-Core rev: eaa8c7d7c047c44067c8931edc81fe476b9a36db)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 14:38:38 +00:00
Paul Eggleton
0e39107047 bitbake: implement BB_VERBOSE_LOGS
Enable configuring whether "set +x" is added to all shell tasks rather
than forcing it; this is enabled by setting BB_VERBOSE_LOGS to 1.

(Bitbake rev: 659411b6bb30e1a8355afc1c29b8170a8f2b55ac)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 13:47:10 +00:00
Richard Purdie
8fbdf5faa6 tcl 8.5.11: fix packaging for native version
Fix an issue in the previous commit:

ERROR: Nothing RPROVIDES 'tcl-native-lib-native' (but virtual:native:/srv/home/pokybuild/yocto-autobuilder/yocto-slave/nightly/build/meta/recipes-devtools/tcltk/tcl_8.5.11.bb RDEPENDS on or otherwise requires it)
NOTE: Runtime target 'tcl-native-lib-native' is unbuildable, removing.

by replacing ${PN}-lib with tcl-lib

(From OE-Core rev: 3cb519598d9ce044ccccb2d6a52a3c0933433501)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 13:35:02 +00:00
Richard Purdie
b82a793bdb More quoting fixes
(From OE-Core rev: 749d252475df090d51313cfbbe3f159db9f0566d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 13:14:42 +00:00
Richard Purdie
f60a5d159b bitbake/ConfHandler: Be more strict about variable quoting
Currently, bitbake will accept variables in the forms:

X = 1
X = '1 \

X = "1"
X = '1'

which will all set X=1. This patch removes the first two possibilities
and makes quoting mandatory. There is little metadata out there which
doesn't quote properly and bitbake will exit with an error about the
exact line number and file with any problem so users can easily identify
and fix issues. OE-Core has already been checked/fixed.

The motivation for this is being able to give sane errors if a user
does something like:

IMAGE_INSTALL += # tslib mtd-utils"

which currently gives a really nasty failure.

(Bitbake rev: a8ae80741fea5e0ec0fb9a52a963a4baa38d2564)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:33:20 +00:00
Richard Purdie
126f634207 image_types: Refactor compression code into a generic compression solution
The current approach of adding each different compressed image type doesn't
scale. This patch changes the code so compressed images for each form are
automatically available using the form <type>.<compression type> in
IMAGE_FSTYPES. This doesn't change any existing externally visible behaviour
and the image generation process becomes more efficient as a result too.

(From OE-Core rev: b7e4ed41ee480f00b7265341e9e2d2c2b9135143)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:53 +00:00
Zhai Edwin
93d157b724 qemugl: Fix gl apps failure on qemu-x86-64
Extend commit 028968 to qemu x86-64, where stack disorder happen due to
register handling via push/pop.

[YOCTO #1927] fixed

(From OE-Core rev: 70c224d80c2330cbb0fa8213b0c0d5a1c87459f6)

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:53 +00:00
Zhai Edwin
3152baea3e libskba: Fix for multilib
(From OE-Core rev: 5cf9c308756017648692d2559ec5cd432fbd5a5a)

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:53 +00:00
Zhai Edwin
aebb13e885 gnupg: Fix for multilib
(From OE-Core rev: a1db815957a0409255c517d3a35382ee704c8390)

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:52 +00:00
Koen Kooi
2902bbe44f tcl 8.5.11: fix packaging
Include /usr/lib/tcl8 for the msgcat and test module, force dependency on tcl-lib since shlibs isn't picking it up.

(From OE-Core rev: 77eaa55d94e8ce73aa3c43b1f068d6ad4cf20e80)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:52 +00:00
Wenzong Fan
695a609057 gettext: Get gettext use its own libunistring
According to its documentation, gettext 0.18.1.1 needs either
libunistring or it will use its own internal version. Just add
a configure option '--with-included-libunistring' to force the
latter to avoid races.

[YOCTO#1934]

(From OE-Core rev: f4f242cf8af9df3dc2394d245740b173f34cbf81)

Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:52 +00:00
James Limbouris
991e34ca89 mtd-utils: Don't use host 'ranlib' or 'ar'.
If ranlib, ar, or cc are not supplied to make, it attempts to use ${CROSS}xxx.
Since ${CROSS} is not set, host ranlib may run, producing an unusable .a file on some platforms.

(From OE-Core rev: b8231237c6878599833c9bbaef7b68060fcbe935)

Signed-off-by: James Limbouris <james@digitalmatter.com.au>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:52 +00:00
Andreas Oberritter
13949f2100 qt4.inc: depend on tiff
* Fixes the following error with qt4-embedded-4.8.0 and possibly others:

| ../../../gui/image/qtiffhandler.cpp:48:20: fatal error: tiffio.h: No such file or directory

(From OE-Core rev: d0853052228128ccca2b744dae9c4dceae23067a)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:51 +00:00
Matthew McClintock
36a0bde559 tune-ppc*.inc: update to use new default value for TUNE_PKGARCH
(From OE-Core rev: 12f0a0d3e1afe90633c8b95d36670ab0f156e912)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:51 +00:00
Matthew McClintock
1919ba235f bitbake.conf: add default value for TUNE_PKGARCH
Add a default value for TUNE_PKGARCH. This let's us use
the following:

TUNE_PKGARCH_tune-ppce500

Instead of scanning over variables and using bitbake internal
functions to create a valid value here.

(From OE-Core rev: 785962440131f993b912d26cba39dc7ffc91aad4)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:51 +00:00
Matthew McClintock
b3f05552bc multilib.bbclass: allow TARGET_VENDOR_virtclass-multilib to be overriden
If we set this bit, we can override the ugly "pokymllib32" to back to
"poky" (powerpc-pokymllib32-linux-gcc -> powerpc-poky-linux-gcc). I've
left this unset by default, but can be set by adding the following:

TARGET_VENDOR_virtclass-multilib-lib32 = "-poky"

(From OE-Core rev: 01fd9be5db633d881c789c5b119f794a3f1000da)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:51 +00:00
Matthew McClintock
e42bc47ef8 tune-ppce5500: consolidate ppce5500 and ppc64e5500 into one tune file
We don't need two files for this. Also this fixes some mutlilib build
issues where we were not able to select the multilib arch to be
ppce5500 or ppc64e5500.

Changes recently made to meta-fsl-ppc layer depend on this change as
well

(From OE-Core rev: 4fbb72a359fea2e0922f472f48f186bbd1ca2b36)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:50 +00:00
Matthew McClintock
df329ad709 arch-powerpc{, 64}.inc: update/add PACKAGE_EXTRA_ARCHS for powerpc/powerpc64
(From OE-Core rev: d19298a4915e00f4a91364d64ddc5fb9689b23c9)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:50 +00:00
Bruce Ashfield
6beb61f3ca linux-yocto: allow non-branched repositories to check out
Not all users of the checkout phase of linux-yocto have all
branches present. This is normal, and should be supported. By
checking for an empty KBRANCH we can avoid validating a branch
that isn't supposed to exist.

[YOCTO #2032]

(From OE-Core rev: fb2b3c7c10df1b44679a20e7dffd37f07fd01aba)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:50 +00:00
Bruce Ashfield
84ad6671d5 linux-yocto: update 3.2 kernel to v3.2.7
Updating the 3.2 kernel recipe to the latest -stable release.

(From OE-Core rev: 97d55a32c7bb7650af59a5bce49cf8409a875f98)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:50 +00:00
Bruce Ashfield
d1130b4b21 linux-yocto: update 3.0 kernel to v3.0.22
bumping the revision of the 3.0 kernel to the latest -stable release.

(From OE-Core rev: b91c32360469ce97fc00e807e7c3415fed1848a5)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:49 +00:00
Khem Raj
9fff795f12 bluez4: Fix build on x86/amd64 with gcc 4.7
gcc figures an impossible asm contraint
in inline asm which it is correct about

"i" requires the operand to be a compile-time constant
but memory location of a multi-dimensional array isn't constant
at compile time.

(From OE-Core rev: 09dcd878a55b5aec5427288c4faf3c4d64a30a72)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:49 +00:00
Saul Wold
7f27de5bdf distro_tracking: Account for updates and Manual Checking
Updates:

sqlite3
psmisc
boost
file
util-linux
tiff
mkfonddir
mkfontscale
libdrm
xf86-video-intel

Manual Checks:
libcheck
libcap
console-tools
zip
unzip
sysfsutils
less
usbutils
sysstat
cracklib
libexif
qemugl
glew
squashfs-tools
lsb

Fixup:
bzip2

(From OE-Core rev: d3bc674dc7ec46b215df50236b95d3b0aed2ee4a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:49 +00:00
Saul Wold
622327145c bind: add DEPENDS for libcap
(From OE-Core rev: aced47c5044fd9e69975dde0071efb7964bd93fa)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:49 +00:00
Saul Wold
68f2485a83 tiff: Update to version 3.9.5
Ensure that OpenGL and friends are disable with the
setting of ax_cv_check_gl_libgl = no.

(From OE-Core rev: 69e67ac74bda6de1243e35643ee4af8a25a5f32f)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:48 +00:00
Saul Wold
adc53a00f8 xf86-video-intel: Update to version 2.18.0
(From OE-Core rev: 0118a6e05de5b6de65a190e7962e35de2e920bdf)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:48 +00:00
Saul Wold
9a3d725780 sqlite3: Update to version 3.7.10
(From OE-Core rev: faf0fd34c65f2f715aad26676b4af74a2badabd6)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:48 +00:00
Saul Wold
d6e0cbc087 boost: Update to version 1.49.0
(From OE-Core rev: db7d0089205124d2c537bd3185444581a7a351fa)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:48 +00:00
Saul Wold
4ab5d64b96 mkfontscale: Update to version 1.1.0
(From OE-Core rev: 5293df3a10a27dcd1d68b2a5c716f236fcbbaff8)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:47 +00:00
Saul Wold
4770a6e6ad mkfontdir: Update to version 1.0.7
(From OE-Core rev: 87fad1bbdad0b1da6aa6f1e5e933655fbf3247cd)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:47 +00:00
Saul Wold
5fb90bc29c libdrm: Update to version 2.4.31
(From OE-Core rev: 769f6165b5b39da8308cf0f7410c267f25ae9553)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:47 +00:00
Saul Wold
86d3f776aa psmisc: Update to version 22.16
Remove libintl-link patch which has in the upstream code now

(From OE-Core rev: f3aad7c3a88dbe171147a703b98488c00a615fcf)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:47 +00:00
Saul Wold
debd4da669 file: Update to version 5.11
(From OE-Core rev: 1cd88605f9fb989b854081e7d4b68874c6656250)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:46 +00:00
Saul Wold
79e8d533ee util-linux: Update to 2.21
This updates various checksums for the COPYING files, which moved in the process
no changes to Licenses

Tweak the scanf_cv_alloc_modifier and rebase the patch

(From OE-Core rev: 9cb35b41c803bd0d1904b2dc0e14624fa7ea6e95)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:46 +00:00
Saul Wold
ef461c4a2a qemu: Add glib-2.0 as depends
(From OE-Core rev: 37a8655bd4b781985eb6b4e33f1847e997609f7b)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:46 +00:00
Saul Wold
caea5b9610 gnupg: Add missing patch for curl_typeof_fix
Seems the wrong commit was grabbed and missed this patch

(From OE-Core rev: 347426ca3dbe06df1d1b0976a81e96cf6238af21)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:46 +00:00
Paul Eggleton
0733f7a4a9 qt4-tools-nativesdk: improve and tidy up qmake build
* Use the same method to build qmake as in the qt4 target recipes
* We always have qmake from qt4-native so don't check if it exists -
  just skip the check like we do in the qt4 target recipes. This
  saves us a patch.
* Replace qt4-tools-native in DEPENDS with qt4-native

(From OE-Core rev: 71153270466352245fe2aa3318bbabb1f8062ed2)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:45 +00:00
Paul Eggleton
afc6d1bb31 qt4-tools-nativesdk: fix build of 4.7.4
Commit 4ccae37db1aa77a1d15098c3720ea6e2d383fbdc introduced a sed command
line to modify a file that only exists in 4.8.0, thus do_configure of
4.7.4 was failing; so make this conditional upon the file existing.

(From OE-Core rev: 0b948d20b835387702a4f5e103eaae5b4a330edd)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:45 +00:00
Paul Eggleton
6be627fd5f qt4: build qmake for the target
qmake was not being built at all (since we had the host version from
qt4-native) and the default is to build for the host machine within
configure. With a minor hack we can build qmake for the target as well,
which is useful if you want to build Qt 4 software on an actual device.
This is now installed as part of the tools package (together with uic,
moc etc.)

Additionally, add an environment setup script (installed in
/usr/share/qt4/environment-setup or /usr/share/qtopia/environment-setup
for the embedded version) as part of the mkspecs package since the
mkspecs will not work without the paths set up by this script. The code
to create this script was adapted from the qmake2 recipe in meta-oe.

Also move do_compile() from qt-${PV}.inc up to qt4.inc as both versions
have the exact same content.

(From OE-Core rev: 4306606489a2d922595d4c86a21c496bbd8a607e)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:25 +00:00
Paul Eggleton
76c1712202 qt4: fix compile error in Qt 4.8.0 with gcc 4.6
Ensure the Qt configure script can can detect the compiler correctly as
g++. This fixes the following compile error with gcc 4.6:

./wtf/NullPtr.h:48:1: error: identifier 'nullptr' will become a keyword in C++0x [-Werror=c++0x-compat]

(From OE-Core rev: f29bb5b2a99ecef46e5570bf3336e9680c0b6705)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:24 +00:00
Yi Zhao
cf87669e7c task-core-lsb: add lsbtest to RDEPENDS_task-core-misc list
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:24 +00:00
Yi Zhao
835197d65c distro_tracking_fields: add information for lsbtest
Add information for recipe lsbtest.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:24 +00:00
Yi Zhao
36a2f338f3 lsbtest: Add recipe for LSB tests and automate test
The recipe is used for LSB tests. The script LSB_Test.sh does the following things:
- setup LSB testing environment
- download LSB rpm packages with list file packages_list from remote
- install the packages
- execute LSB testing with profile file session
- collect the results

Install packages_list and session files into ${D}/opt/lsb-test.

[YOCTO #1567]

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:24 +00:00
Lianhao Lu
c3a23ec304 scripts/prserv-tool: Adepted to new bitbake cache.
Adepted to the new bitbake cache mechanism which is based on file
content but not on file timp stamps any more.

(From OE-Core rev: c1705317f9456f761da2094e886a07939291e53a)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:23 +00:00
Paul Eggleton
ce0ecf5d84 bitbake: fix setscene task start/failure handling
* When a setscene task starts, print out that it's starting in the UI
  (ensuring we get the correct task name)
* When a setscene task fails, ensure we remove it from the list of
  running tasks so that if you break out any time afterwards it
  is not still listed.

(Bitbake rev: e8a3499c95a6d4f2b8fed002fb9504733c5be3c6)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:22 +00:00
Paul Eggleton
e7952c1883 bitbake/runqueue: make dry-run do everything except execute
Make dry-run do everything except executing the task, instead of
cutting it off earlier. This fully tests the code path for running the
child task (parsing and fakeroot), as well as enabling future
functionality such as using dry-run to produce signature files.

(Bitbake rev: bf1d7739618dabf3872a868230c0112b9ad2a2c0)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:21 +00:00
Lianhao Lu
959981da53 bitbake: Added BBINCLUDED variable.
Added new variable BBINCLUDED indicating the file dependency
information. It exposes the internal variable '__base_depends' and
'__depends'.

(Bitbake rev: af524a656fce32d01687481b86c31bef00eb9fc3)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-28 12:27:21 +00:00
Dongxiao Xu
927bec5f72 bitbake.conf: Create a new filter variable BB_HASHCONFIG_WHITELIST
Create a new filter variable BB_HASHCONFIG_WHITELIST to filter
variables for calculating cache's hash value.

(From OE-Core rev: 8d4db8e6dcd2d25637cb77515fe776552f2fdd6d)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-27 20:10:41 +00:00
Dongxiao Xu
a295cdc19f data_smart.py: Uses BB_HASHCONFIG_WHITELIST to filter unnecessary variables
Adopt the BB_HASHCONFIG_WHITELIST as a exclusion list for variables that are
not needed in cache hash calculation.

(Bitbake rev: ae8cf138b5eb8f1f28a7143b8d67ad06cbe43061)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
CC: Christopher Larson <kergoth@gmail.com>
CC: Martin Jansa <martin.jansa@gmail.com>
CC: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-27 20:10:40 +00:00
Richard Purdie
f420fb3de1 glib-2.0: Disable fam, we don't depend on it
Various people are reporting glib-2.0 failures from a dependency on
libfam creeping in uninvited. This patch explicitly disables it to
favour a deterministic build.

(From OE-Core rev: e1d5a81bf78786dcb11a4840436f46ba9ec4010e)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-27 12:17:27 +00:00
Martin Jansa
6cf61b30aa arch-armv7.inc: fix quoting
(From OE-Core rev: 6e1065a4988489baa762f7dc1535fe326e0ba7b5)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 23:01:42 +00:00
Martin Jansa
3349b88a76 More quoting fixes
* We have various variables which are either not quoted at all or are half
  quoted. This patch fixes the bad exmaples so everything is consistent.

(From OE-Core rev: 960ee8076e860353a05eb2eb7f825a455c54698d)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 22:51:58 +00:00
Richard Purdie
36e918b8a8 Quoting fixes
We have various variables which are either not quoted at all or are half
quoted. This patch fixes the bad exmaples so everything is consistent.

(From OE-Core rev: 30253358f5e76fb7b25be27198b4c125e0dbdf2c)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 12:52:12 +00:00
Eric Bénard
21f2c0b5cd pulseaudio: Really disable orc support
If orc is detected the compilation fails with missing headers which
should have been generated by orc (using meta-angstrom + meta-openembedded
and and armv7 target)

[RP: add RP bump, fix typos]
(From OE-Core rev: 8f72d9e4ecf495646af3c5cebe7f08ca01bbbb99)

Signed-off-by: Eric Bénard <eric@eukrea.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:56:05 +00:00
Saul Wold
c02bea652b gnupg: Update checksum, fix configure and compliation issues
This recipe was added, but did not have the correct
checksum information for the LIC_FILES_CHKSUM or the
SRC_URI.  Also disable Documetnation for now due to
older autotools issue.

[YOCTO #1966]

(From OE-Core rev: e8c02ead5ce130492eb11457f58cc4d28a330132)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:45:23 +00:00
Saul Wold
43d9193f69 syslinux: Package unpackaged files in -misc
(From OE-Core rev: 868a81e869a6193aada2073ae533d937a1c0baf4)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:45:23 +00:00
Andreas Oberritter
eb8ce05d13 automake: omit compilation of pyc files on install
* On install, automake calls py-compile, which previously
  compiled python source code to pyc and pyo, which both
  got packaged.
* The python interpreter in OE contains patches to enable
  optimization (pyo) by default:
    04-default-is-optimized.patch
    99-ignore-optimization-flag.patch
* automake created pyc files by calling py_compile.compile()
  and adding the c suffix manually, resulting in identical
  byte code for both pyc and pyo files.
* py-compile-compile-only-optimized-byte-code.patch
  applies to automake 1.11 and automake master, but older
  versions require a slightly modified patch. However,
  older versions are only pinned by chinook-compat and
  nylon, so I left them untouched.

(From OE-Core rev: 40ccf816c597e7eed5243fb4b4e9473d2b58afaa)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Khem Raj <raj.khem@gmail.com>

The patch was imported from the OpenEmbedded git server
(git://git.openembedded.org/openembedded) as of commit id
aa4585c5065e05c759f16e1e8623fc7f40640f1b.

Modified to apply to automake version 1.11.2 and to
include a patch header. Also renamed the patch.

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:42:34 +00:00
Andreas Oberritter
6aa3a09876 xorg-lib: don't build libs unless requested by DISTRO_FEATURES (fix up)
* Improve error message as suggested by Koen.
  (This got lost when v1 was committed instead of v2)

(From OE-Core rev: 384912b4719a77b2e5f6673066e75258df130f5d)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:42:33 +00:00
Otavio Salvador
1adeb37d79 qt4-native: set headerdir as done in regular builds
qmake uses a generated qt.conf file that expects headers to be found
at ${includedir}/qt4 but qt4-native were not following this layout
breaking the builds of native binaries that use qt4.

(From OE-Core rev: 7828bf71babd965b263249f4a24ecfe58e97cc0b)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:15:07 +00:00
Robert Yang
5ecae0be86 local.conf.sample.extended: Add config sample for disk space monitoring
Add config sample for disk space monitoring to
meta-yocto/conf/local.conf.sample

[YOCTO #1589]
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:07:25 +00:00
Robert Yang
9674ea28ff V5 Disk space monitoring
Monitor disk availability and take action when the free disk space or
amount of free inode is running low, it is enabled when BB_DISKMON_DIRS
is set.

* Variable meanings(from meta-yocto/conf/local.conf.sample):

  # Set the directories to monitor for disk usage, if more than one
  # directories are mounted in the same device, then only one directory
  # would be monitored since the monitor is based on the device.
  # The format is:
  # "action,directory,minimum_space,minimum_free_inode"
  #
  # The "action" must be set and should be one of:
  # ABORT: Immediately abort
  # STOPTASKS: The new tasks can't be executed any more, will stop the build
  #           when the running tasks have been done.
  # WARN: show warnings (see BB_DISKMON_WARNINTERVAL for more information)
  #
  # The "directory" must be set, any directory is OK.
  #
  # Either "minimum_space" or "minimum_free_inode" (or both of them)
  # should be set, otherwise the monitor would not be enabled,
  # the unit can be G, M, K or none, but do NOT use GB, MB or KB
  # (B is not needed).
  #BB_DISKMON_DIRS = "STOPTASKS,${TMPDIR},1G,100K WARN,${SSTATE_DIR},1G,100K"
  #
  # Set disk space and inode interval (only works when the action is "WARN",
  # the unit can be G, M, or K, but do NOT use the GB, MB or KB
  # (B is not needed), the format is:
  # "disk_space_interval, disk_inode_interval",  the default value is
  # "50M,5K" which means that it would warn when the free space is
  # lower than the minimum space(or inode), and would repeat the action
  # when the disk space reduces 50M (or the amount of inode reduces 5k)
  # again.
  #BB_DISKMON_WARNINTERVAL = "50M,5K"

[YOCTO #1589]
(Bitbake rev: 4d173d441d2beb8e6492b6b1842682f8cf32e6cc)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:05:27 +00:00
Richard Purdie
aac45679fb bitbake/runqueue: Ensure finish_now() sets the runqueue state consistently
If we call finish_now(True), rq.state is not updated to match. This
makes the behaviour of finish_now(False) and finish_now(True) consistent
so both leave rq.state consistently.

(Bitbake rev: 9079ae0ab74f9232b7e9853b2013b051d4fcf623)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:04:38 +00:00
Eric BENARD
1cb4614f1d gdb-cross-canadian: build gdb with python support
* python support is needed for providing finer scripting control
in gdb, and for remote controling gdb for example from qtcreator
* gdb/configure tries to autodetect python using python executable
with --includes --ldflags --exec-prefix to get the right flags
As it's difficult to achieve in OE's context, we generate a
script which will return the right values and make gdb's build
system happy. This idea was taken from the following article :
http://www.mentby.com/doug-evans-2/python-enabled-gdb-on-windows-and-relocation.html
* tested using angstrom & armv7 target & qtcreator 201005 & 2.4.0

* MJ: updated paths to python as disscussed here
  http://lists.linuxtogo.org/pipermail/openembedded-core/2012-February/018222.html
  now it's easier with cross-canadian staging dir and SDKPATH fixed :)

(From OE-Core rev: 73a90b88541c373aa5b83a939dd3b5f1fe05b9b8)

Signed-off-by: Eric Bénard <eric@eukrea.com>
Cc: fcooper@ti.com
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 11:00:07 +00:00
Martin Jansa
56bbea6dcf layer.conf: add keymaps to SIGGEN_EXCLUDERECIPES_ABISAFE
(From OE-Core rev: 1669ae88553c4124387438b88541de8e7951b4a4)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 10:56:46 +00:00
Martin Jansa
17fe2963c9 sstatesig: add SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS option to exclude well defined recipe->dependency
(From OE-Core rev: d73c139fd73ee268d29837db6ccc69c412022d6e)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 10:56:45 +00:00
Martin Jansa
745f5c329d bitbake.conf: remove TARGET_ARCH from in SDKPATH
* SDKPATH shouldn't depend on TARGET_ARCH as discused here:
  http://lists.linuxtogo.org/pipermail/openembedded-core/2012-February/018222.html
* introduce SDK_NAME_PREFIX so that distributions can overwrite only
  this instead of whole SDK_NAME

(From OE-Core rev: 54821d53f75eb31f1eca3809e674680316dcbf69)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 10:56:45 +00:00
Martin Jansa
7160f874c4 bitbake.conf: use weak assignment for BB_CONSOLELOG
* some people prefer subdirectory like ${TMPDIR}/cooker/${DATETIME}.log

(From OE-Core rev: d3a06178202c65ce52ea8ad7af5b72ed5c0881d4)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 10:56:45 +00:00
Richard Purdie
be1443b9d0 cross-canadian: Set STAGING_DIR_HOST correctly
As reported by Martin Jansa, the path to nativesdk sysroot was changing between
nativesdk and cross-canadian recipes. The problem was the incorrect deinfition of
STAGING_DIR_HOST in cross-canadian.bbclass.

Since nothing really uses the cross-canadian output in the sysroot, only the
packages, its not surprising this bug has gone un-noticed.

(From OE-Core rev: 8c6966cb8e353dc28819419ea7e395fb0d5f2536)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 10:56:44 +00:00
Richard Purdie
e17c709b43 glib: Drop dbus dependency, it isn't useful
dbus is only needed for some of the glib tests which we don't use. We can
therefore drop the dependency and gain some small parallelism gains.

(From OE-Core rev: 4642ae91cee2978956a61cf15df7ea62e3eb1726)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 10:56:44 +00:00
Darren Hart
a54932dc37 poky-tiny: Assume pkgconfig is provided
-dev packages require pkgconfig, but it pulls in glib->dbus->shadow
which breaks with tiny's minimal libc.

-dev packages are not currently supported on poky-tiny.

[YOCTO #2030]

Proposed-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-26 10:56:24 +00:00
Joshua Lock
2ff96d664e crumbs: add back progress implementation for depexp
The commit which introduced the new hob UI also deleted this class
which is used by depexp.

(Bitbake rev: d54dbe54cde8e0086bf1fb4926468e212660db53)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-25 11:55:45 +00:00
Paul Eggleton
c9e95d3363 bitbake/cooker: terminate when errors found in layer configuration
If we find an error in the layer configuration (such as an unsatisfied
item in LAYERDEPENDS) then exit by raising an exception at the end of
handleCollections() (without producing a backtrace).

(Bitbake rev: c7486a09310fe63b1aa1b7b0bb9450f306b6093b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:30:27 +00:00
Andreas Oberritter
e894f0e71c initscripts: mount and unmount cifs network filesystems
* Added cifs to mountnfs.sh and umountnfs.sh.

(From OE-Core rev: c44e51f281101c8933679f679e3d4a75a41bedf7)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:25:53 +00:00
Martin Jansa
ee86f899e1 layer.conf: use += for SIGGEN_EXCLUDERECIPES_ABISAFE and split to multiple lines
* += is important, because if oe-core is in BBLAYERS after some other
  layers with SIGGEN_EXCLUDERECIPES_ABISAFE it overwrites their entries

(From OE-Core rev: 3aa1bb01c0fa91bcb7d9a03198d19ac88a1bdecb)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:25:52 +00:00
Otavio Salvador
b6bd0f8a32 useradd.bbclass: override USERADDSETSCENEDEPS to empty when building cross packages
(From OE-Core rev: 5650eb44ea28c87f2f87ea3c5a557b9f08d58775)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:25:52 +00:00
Elizabeth Flanagan
d7cef163e4 license.bbclass: Symbolic links of generic license
This is to reduce the size of licenses added to images. With this
commit license.manifest, original license and generic license
adds about .5M to a core-image-minimal image, substantially less
than what is currently occuring when COPY_LIC_MANIFEST and
COPY_LIC_DIRS are set.

(From OE-Core rev: 2c753a714c1ee2b7c6479836f47aeec182ca3670)

Signed-off-by: Elizabeth Flanagan <elizabeth.flanagan@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:25:52 +00:00
Elizabeth Flanagan
5272e883ff license.bbclass: Gather Pkg level licenses
We should look for LICENSE at a package level first. If it's
not found, we should use the recipe level LICENSE. This adds a
bit more granularity to license manifests where needed.

(From OE-Core rev: d50dd280f52587b6225bc5db3c9e85f78107f5f5)

Signed-off-by: Elizabeth Flanagan <elizabeth.flanagan@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:25:52 +00:00
Elizabeth Flanagan
cde25845a7 less_444.bb: Adding license email from author
This slipped off my plate. Adding the email response from the
author of less which allows us to use a generic BSD instead of
the less license.

(From OE-Core rev: fa7bdf96b8eb8b5078db38249c5c60ec511c35c6)

Signed-off-by: Elizabeth Flanagan <elizabeth.flanagan@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:25:51 +00:00
Saul Wold
3be2c7d611 distro_check: fix the fedora URL for rleases as they seem to have moved
(From OE-Core rev: eb2d70e02d299ab651aebda49d2006aef16b4ae0)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 23:25:51 +00:00
Dongxiao Xu
21ddc964ce scripts/hob: Launch the new hob
Change the scripts to launch the new Hob.

(From OE-Core rev: 22194a04f224864dd687660e351a3a10da1f06fa)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 18:09:20 +00:00
Martin Jansa
f496389aa8 gst-plugin-bluetooth: upgrade to 4.98 and add checksums
(From OE-Core rev: d390a2d6a14b1bec11f6e6ceaa448e15f18e0017)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 18:04:49 +00:00
Martin Jansa
3a20beb260 shadow-sysroot: disable package creation
(From OE-Core rev: a46d80247553f5ecb68bdd3f77ec539381350399)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 18:04:49 +00:00
Dongxiao Xu
656f9a0758 Hob: A new implemetation (v2)
This commit implements a new design for hob
Some of the new features:
 - Friendly new designed GUI. Quick response to user actions.
 - Two step builds support package generation and image generation.
 - Support running GUI seprarately from bitbake server.
 - Recipe/package selection and deselection.
 - Accurate customization for image contents and size.
 - Progress bars showing the parsing and build status.
 - Load/save user configurations from/into templates.

(Bitbake rev: 4dacd29f9c957d20f4583330b51e5420f9c3338d)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Liming An <limingx.l.an@intel.com>
Signed-off-by: Fengxia Hua <fengxia.hua@intel.com>
Designed-by: Belen Barros Pena <belen.barros.pena@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 18:04:27 +00:00
Bruce Ashfield
14df6d53b6 linux-yocto: improve checkout error handling and reporting
The typical workflow for linux-yocto simply uses a remote
upstream repository (Whether it is mirrored or not), and in this
case there are no issues with consistency in the format of the
resository that is unpacked into the WORKDIR.

When working with a local linux-yocto repository for kernel
development the remote vs local branches is not always consistent
between repositories.

The suggested/documented workflow has always been to use a
bare clone of linux-yocto, and use a second working tree repository
for development. Changes flow from the working tree to the bare
clone and then into the working directory for build. A common
mistake that happens with this workflow is that the non-bare,
working repository is used instead of the bare clone version.

If a non-bare repository is reference by the SRC_URI, then the
branches that are fetched into WORKDIR are not consitent. If the
MACHINE and META branches are not present, cryptic build errors
will result.

To solve this problem, the checkout code has been changed in
several ways:

  - works with a newly proposed 'bareclone' option to bitbake
  - detects if a bareclone is present in WORKDIR or not and
    adjustst the checkout accordingly.
  - if a non-bare clone is detected, machine and meta branches
    are checked. If they are not present, or can't be created
    a clear error message is produced
  - instead of manipulating the refs directly in the git tree,
    local tracking branches are (quietly) created for remote
    branches. Enabling a better workflow in the WORKDIR kernel
    repository.

This has been tested with linux-yocto remote upstreams, local
bare and non-bare respositories. All builds succeed or fail
with clear error messages.

(From OE-Core rev: e3b6537cc7931636ab11ae6ed2c8fbaad9da91bc)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 17:12:05 +00:00
Martin Jansa
db94ad4cf3 sstate.bbclass: improve performance of sstate package creation
* also fixes replacing paths for perl where cmd line was probably
  too long for os.system(cmd) (it had 560410 characters because a lot of
  files from sstate_scan_cmd).
* also print those 2 commands so we can find them in log.do_package

(From OE-Core rev: 94c52d68fc2ce258bcc5b0978ac73413480a1a93)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 17:06:57 +00:00
Paul Eggleton
c8af05547e qemu: remove version 0.14.0
0.15.1 has been available in OE-Core for some time and has demonstrated
no major regressions, so remove the older version.

(From OE-Core rev: d242e637a2b5101985befd93d3b560f17b37504b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 17:01:45 +00:00
Paul Eggleton
ef36dc896d libsdl: allow building without x11
Disable X11 output support for target and nativesdk if x11 is not in
DISTRO_FEATURES.

Fixes [YOCTO #2020]

(From OE-Core rev: 506e4c9b05d61f126fff112d7c111902d5c9fac5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 17:01:45 +00:00
Paul Eggleton
189a854e8d qemu: enable building qemu-nativesdk without x11
Allow building for nativesdk with x11 removed from DISTRO_FEATURES
by conditionally disabling qemugl (which requires X).

Fixes [YOCTO #2020]

(From OE-Core rev: 136b13eb6a682222e2af887d3247a61310476c70)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 17:01:44 +00:00
Paul Eggleton
dfd6c546c4 psplash: allow building multiple splash executables
Adds a SPLASH_IMAGES variable which you can set to include one or more
images (listed in URI form as they would appear in SRC_URI), and an
executable will be built for each one, with each executable packaged
separately and managed at runtime using the alternatives system. An
optional "outsuffix" parameter can be used to specify the suffix for the
executable/package name. The images themselves can either be
pre-processed image header files (produced using the
make-image-header.sh script that comes with psplash), or alternatively
you can provide a .png and it will be converted using the aforementioned
script on the fly (at the expense of requiring gdk-pixbuf-native at
build time).

This has been implemented in such a way that you can still just provide
your own psplash-poky-img.h in a bbappend and it will work as it did
before; the only change being that the psplash executable is provided
in a "psplash-default" package rather than in the main psplash package,
and an RRECOMMENDS is set up to ensure psplash-default gets pulled in
(if you specify your own file or change the outsuffix you will need to
either install it separately yourself or add your own RRECOMMENDS
relationship.)

Implements [YOCTO #1947]

(From OE-Core rev: d3de5f7308b4a42b809884119a670af5bedde38f)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 17:01:44 +00:00
Paul Eggleton
5dc51532b6 psplash: use OpenEmbedded logo
Use the OpenEmbedded logo for psplash in OE-Core.

(From OE-Core rev: cd321b83c78c00003f1ce06ac3ca85647cf9df51)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 17:01:44 +00:00
Paul Eggleton
16b715bc84 meta-yocto: add bbappend to restore Yocto psplash image
OE-core now uses the OpenEmbedded logo for the psplash image; override
this and use the Yocto Project image as we did previously.

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:42:44 +00:00
Bruce Ashfield
408fd37529 fetch2/git: create bareclone option
For similar reasons as the nocheckout option, packages that need
enhanced control over the checkout and branch creation on a repository
may want a complete mirror/bareclone created of the repository when
performing the unpack.

This is useful/required when a local respository is being used, but
local tracking branches have not been created for all branches that
a given recipe needs to manipulate. The standard git clone operations
will create remote branches for the branches that are local to the
source repository, but branches that are remote do not translate to
the destination repository. Doing a mirror/bare clone of the source,
makes all branches available to the repository.

This is a particular use case, but the ability to do a bare clone
creates great flexibility in recipe space, with no impact to recipes
that don't need this functionality.

To implement this, a new option 'bareclone' is craeted which creates
a mirror copy of the repository and leaves it bare in the unpacking
phase. A recipe that uses this option must both checkout and debare
the repository itself.

(Bitbake rev: 82482aae6f311c994275fb0b6b32d954bbfc78c3)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:40:08 +00:00
Paul Eggleton
72ce5c4cde conf/bitbake.conf: add DISTRO_FEATURES_BACKFILL
When introducing new items to DISTRO_FEATURES that control functionality
that is already enabled, in order to leave existing distro configuration
unchanged we need a way to "backfill" these new feature items onto the
existing DISTRO_FEATURES value.

This introduces a DISTRO_FEATURES_BACKFILL variable whose items will be
added to the end of DISTRO_FEATURES, unless they also appear in
DISTRO_FEATURES_BACKFILL_CONSIDERED which distros can use in their
configuration to prevent specific items from being added.

Fixes [YOCTO #1946].

(From OE-Core rev: 738658d9d5ddef026d2929188744aa225324bf26)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:37:07 +00:00
Khem Raj
5ac604e67a glib-networking: Add intltools-native to DEPENDS
(From OE-Core rev: deb501b8a1cb3cdb1ea0a48ea08e411c2be365b3)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:29:47 +00:00
Dexuan Cui
ae34e43b24 task-self-hosted: add hicolor-icon-theme and socat
python-pygtk depends on libgtk and libgtk's recommends have
gdk-pixbuf-loader-{png,jpeg,gif,xpm}, so we have the warnings.
We can add hicolor-icon-theme to fix the warning:
Configuring gdk-pixbuf-loader-png.
gtk-update-icon-cache: No theme index file.
Configuring gdk-pixbuf-loader-jpeg.
gtk-update-icon-cache: No theme index file.
Configuring liberation-fonts.
Configuring gdk-pixbuf-loader-xpm.
gtk-update-icon-cache: No theme index file.
Configuring gdk-pixbuf-loader-gif.
gtk-update-icon-cache: No theme index file.

Add socat for to faciliate proxy setting.

(From OE-Core rev: d32933a74b380aac906bbfbe1ec7d89b02e9f72d)

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:29:46 +00:00
Martin Jansa
c867e31f7e mpfr: add patch to fix build for thumb
(From OE-Core rev: 68bc9416d9e4beb027133e151b1bb3ecadd2ee26)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:29:46 +00:00
Richard Purdie
7c46f0b109 package.bbclass: Add a sanity check to the debugsrcdir removal code
(From OE-Core rev: 9f6b9d7d0402b883fc3ad3cdead40e838ce31a27)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:11:27 +00:00
Richard Purdie
f017b9b6b8 libfm: Fix packaging and dependency issues
Add missing pango and glib-2.0 dependencies.

Fix QA warnings:

WARNING: For recipe libfm, the following files/directories were installed but not shipped in any package:
WARNING:   /usr/lib/gio
WARNING:   /usr/lib/gio/modules
WARNING:   /usr/share/mime
WARNING:   /usr/share/mime/packages
WARNING:   /usr/share/mime/packages/libfm.xml

(From OE-Core rev: f6f527694e4f896b5d8a649f0b12f5b437c27cd1)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:11:27 +00:00
Dongxiao Xu
d02f7b4649 runqueue: fire sceneQueueTaskStarted event when a setscene queue starts
The current code prints a log when a setscene task starts, therefore
the progressbar in hob will not receive it. Use a sceneQueueTaskStarted
event instead.

Besides, change the sceneQueueTaskFailed event to inherit runQueueEvent
directly to avoid confusion to event receiver.

(Bitbake rev: 7c07cc93d6558d7d9c3144b13493901b7ebae050)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 16:11:24 +00:00
Richard Purdie
e6230da00e image.bbclass: Ensure timestamp matches format used in initscripts after recent changes
(From OE-Core rev: 173a48f79f8f2f18737f1901fc5992223d456348)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 10:25:40 +00:00
Otavio Salvador
5aca6a7e94 update-rc.d.bbclass: do nothing for extended cross packages
(From OE-Core rev: a1f23a7cc527afdd1ce6cc7cd6083ee78fde09b3)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:47:51 +00:00
Otavio Salvador
826c1a1e44 rootfs_ipk.bbclass: fix status file location in rootfs
This fixes runtime requirement checking and read-only-fs checking.

(From OE-Core rev: c50a46fbd50a148146fb1f077db20cdc8121f20b)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:45:44 +00:00
Dongxiao Xu
cc2ef82c0c meta-hob: Add a new meta-hob layer
This new layer contains hob-image.bb and hob-toolchain.bb that
are used by hob to build images or toolchain.

(From OE-Core rev: 213b5038215b1d7df10f1df0375610034fa156c7)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:39:10 +00:00
Dongxiao Xu
99c805a168 packageinfo.bbclass: add a new bbclass to pass package information
packageinfo.bbclass is to pass the accurate package information to
clients (e.g. Hob), including PN, PV, RDEPENDS, PKGSIZE, etc.

(From OE-Core rev: 1a0be9ec4d53cfcaea907edebe5d8bb525496b4e)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:39:09 +00:00
Shane Wang
9531161d40 package.bbclass: set package size into pkgdata for hob2's use
Write the size of a package into its pkgdata for hob2 to get the size
and show on the UI for image making.

(From OE-Core rev: 9c446d007957dab36ee2c012f0a5b22494a7a84f)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:39:09 +00:00
Richard Purdie
f378918c79 gthumb: Resolve staticdev QA warnings
Since the .a files are pretty useless in the case of plugin modules, lets
just remove them. This resolves the warnings:

WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libslideshow.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libimporter.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libimage_viewer.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libchange_date.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libedit_metadata.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libgstreamer_tools.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libphoto_importer.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libimage_rotation.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libfile_viewer.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libpixbuf_savers.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libexport_tools.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libconvert_format.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/librename_series.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libfile_tools.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libwebalbums.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libcatalogs.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libresize_images.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libimage_print.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libdesktop_background.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libred_eye_removal.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libcomments.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libfile_manager.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libjpeg_utils.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libgstreamer_utils.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/liblist_tools.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libbookmarks.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libsearch.a'
WARNING: QA Issue: non -staticdev package contains static .a library: gthumb path '/work/x86_64-poky-linux/gthumb-2.12.4-r1/packages-split/gthumb/usr/lib/gthumb/extensions/libraw_files.a'

(From OE-Core rev: a31d0dbd03b437de9c64a160e86ef97ef7e08807)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:03 +00:00
Richard Purdie
95eb87b7f6 autotools.bbclass: Make builds deterministic
We need to ensure any aclocal-copy directory is removed before we s
earch for .m4 files, else the locations .m4 files are found from can
vary depending on whether its the first or second time we run configure.

Clearing any existing aclocal-copy directory before we start resolves
this issue and makes builds deterministic again.

(From OE-Core rev: 673e2a05013cbe08efde936f663845031025689d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:02 +00:00
Richard Purdie
6ad11cba63 insane.bbclass: Only depend on desktop-file-utils-native when we need it
There is no point in depending on desktop-file-utils if we're not going to
use it. This patch makes the dependency conditional upon the desktop tests
being enabled.

(From OE-Core rev: f775f76dc01f1a969c00f697507958d8a4f9b088)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:02 +00:00
Richard Purdie
2fb9aace07 package.bbclass: Remove empty directories created as part of srcdebug handling
We can create directories like /usr/src/debug as part of the debug file
manipulations. If these are going to end up empty, remove them to avoid QA
warnings like:

WARNING: For recipe task-core-x11, the following files/directories were installed but not shipped in any package:
WARNING:   /usr
WARNING:   /usr/src
WARNING:   /usr/src/debug
WARNING: For recipe task-core-console, the following files/directories were installed but not shipped in any package:
WARNING:   /usr
WARNING:   /usr/src
WARNING:   /usr/src/debug

(From OE-Core rev: 4f4451f7c0f9762092eb3dbc995b4afa2572ceb6)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:02 +00:00
Richard Purdie
e7caf3d1bc dbus-glib: Correctly package bash completion pieces to avoid QA warning
WARNING: For recipe dbus-glib, the following files/directories were installed but not shipped in any package:
WARNING:   /etc
WARNING:   /etc/bash_completion.d
WARNING:   /etc/bash_completion.d/dbus-bash-completion.sh
WARNING:   /usr/libexec/dbus-bash-completion-helper

(From OE-Core rev: 8f0d188df4aaccc3fd4911f12c532f81ae9714a7)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:02 +00:00
Richard Purdie
fa10f797e3 glib-2.0: Fix unpackaged files warning
WARNING: For recipe glib-2.0, the following files/directories were installed but not shipped in any package:
WARNING:   /usr/lib/gio
WARNING:   /usr/lib/gio/modules

(From OE-Core rev: a85f283ffae5407b23532ce2262142ee2d986af2)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:01 +00:00
Richard Purdie
2065d3999d cracklib: Fix unpackaged files warning by disabling autodetected python
WARNING: For recipe cracklib, the following files/directories were installed but not shipped in any package:
WARNING:   /usr/lib/python2.7
WARNING:   /usr/lib/python2.7/site-packages

(From OE-Core rev: f9b184b9454da8374de7351af8619d0201d6f843)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:01 +00:00
Richard Purdie
68a738e538 libgcrypt: Fix unpackaged file warning
WARNING: For recipe libgcrypt, the following files/directories were installed but not shipped in any package:
WARNING:   /usr/sbin

(From OE-Core rev: db3d5baa07ce8c81d229fdea4d80671768efa7a3)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:01 +00:00
Richard Purdie
050be51c1d readline: Add a patch to remove the redundant rpath linker option
This resolves the QA warnings:

WARNING: QA Issue: readline: /work/x86_64-poky-linux/readline-6.2-r0/packages-split/readline/usr/lib/libhistory.so.6.2 contains probably-redundant RPATH /usr/lib
WARNING: QA Issue: readline: /work/x86_64-poky-linux/readline-6.2-r0/packages-split/readline/usr/lib/libreadline.so.6.2 contains probably-redundant RPATH /usr/lib
WARNING: QA Issue: readline: /work/x86_64-poky-linux/readline-6.2-r0/packages-split/readline/usr/lib/libreadline.so.6 contains probably-redundant RPATH /usr/lib
WARNING: QA Issue: readline: /work/x86_64-poky-linux/readline-6.2-r0/packages-split/readline/usr/lib/libhistory.so.6 contains probably-redundant RPATH /usr/lib

(From OE-Core rev: fe8661cd30b02dd8ea9bf172479f372c919c36a7)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:01 +00:00
Richard Purdie
bd7f819b1f libusb-compat: Address unpackaged files warning
WARNING: For recipe libusb-compat, the following files/directories were installed but not shipped in any package:
WARNING:   /lib/libusb.la

(From OE-Core rev: 019747e5fe834092731cdb2987d9c6e1f7fd1cc1)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:00 +00:00
Richard Purdie
b899244305 libusb1: Address unpackaged files warning
WARNING: For recipe libusb1, the following files/directories were installed but not shipped in any package:
WARNING:   /lib/libusb-1.0.la

(From OE-Core rev: 3155ace4bd2c9ba0ecb0db4c65778601eb5ed186)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:00 +00:00
Richard Purdie
f409cf4bbd rpm: Fix LICENSE field
This addresses the warning:

WARNING: rpm: No generic license file exists for: LGPL in any provider
WARNING: rpm: No generic license file exists for: 2.1 in any provider

(From OE-Core rev: 2345f788c9206b87804292c0afdd73f565784d45)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:00 +00:00
Richard Purdie
b1d418e315 eglibc: Fix package warning
WARNING: For recipe eglibc, the following files/directories were installed but not shipped in any package:
WARNING:   /usr/lib/locale

(From OE-Core rev: d8c24378c6813036fcf9bc88cac919c3443c1446)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-24 00:12:00 +00:00
Saul Wold
1d7728e8cb distro_tracking_fields: fix typos
(From OE-Core rev: 1034e798cbab0bd16e35db6ae750f146fc8689c1)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:40 +00:00
Dexuan Cui
da1b26c350 task-self-hosted: make the package lists alphabetical
This patch makes no actual change to the functionality of the recipe.

(From OE-Core rev: 0dff62c849650f3fa51ce80979b4d80dcc0d36f1)

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:40 +00:00
Dexuan Cui
1eec640238 task-self-hosted: remove duplicate packages
The package names are specified more than once.
We only need to keep one for each of them, so let's remove the duplicated
ones.
This patch makes no actual change to the functionality of the recipe.

(From OE-Core rev: 121a1499a81706366acc0081272a6bff634d4d62)

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:40 +00:00
Robert Yang
6224e30834 A script to clean obsolete sstate cache files
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]

(From OE-Core rev: 7c99ef6d2173b14e1109a540ee5ae47b56d707e7)

Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:40 +00:00
Andrei Gherzan
ef29851fe8 openssl: Move libcrypto to base_libdir
This fix is for dhclient. It needs libcrypto at runtime and if
libcrypto is in libdir, it's path can be inaccessible on systems
where /usr is on nfs for example or dhclient is needed before
/usr is mounted.

(From OE-Core rev: 01ea85f7f6c53c66c76d6f832518b28bf06ec072)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>

[Fix comment to from /usr -> /lib - sgw]

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:39 +00:00
Saul Wold
136d9cd07d boot-directdisk: Use correct SYSLINUX_TIMEOUT and SYSLINUX_ROOT instead of APPEND
(From OE-Core rev: 1284230ad554f8607cb02b054fdd74017ae7c861)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:39 +00:00
Saul Wold
5d04c6e173 image-live: fix SYSLINUX_TIME and add SYSLINUX_ROOT instead of APPEND
(From OE-Core rev: e03d5cbdfc39a835576b16a0beeea6858e983f56)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:39 +00:00
Saul Wold
1792a02606 image_types: add vmdk type to use with VMware
(From OE-Core rev: c18e6d444929c32a714b3e46f21567867e48814c)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:39 +00:00
Saul Wold
8ea3bf3821 syslinux: add SYSLINUX_ROOT to APPEND line
By prepending the SYSLINUX_ROOT to the APPEND line, will allow a sane default
to be set for the various syslinux images

(From OE-Core rev: 47f53bc7998aa8390f846e939b6a7f6df3789777)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:38 +00:00
Saul Wold
4fe569e949 syslinux: Use SYSLINUX_TIMEOUT and SYSLINUX_PROMPT to configure syslinux
syslinux allows you to set TIMEOUT and PROMPT variables, when PROMPT is 0,
the "boot:" is not displayed uless one presses CTRL or SHIFT during startup.
TIMEOUT is in 1/10th of seconds, and a value of 0 for TIMEOUT will disable
the timeout mechanism.

In bitbake, recipes had set TIMEOUT (not SYSLINUX_TIMEOUT) incorrectly, other
patches fix this issues.  We are adding SYSLINUX_PROMPT to enable/disable the
"boot:" prompt in syslinux.

See http://www.syslinux.org/wiki/index.php/SYSLINUX for more details

(From OE-Core rev: be04e3b2e13c1a7e1cd5416771b72a80ec52b8ad)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:38 +00:00
Yauhen Kharuzhy
dced0c16e8 ppp: Fix rp-pppoe plugin compilation
rp-pppoe plugin was broken due linux headers changes: pppd has own copy of
if_pppol2tp.h file which is included from <linux/if_pppox.h>.

Add patch from Debian for struct pppol2tpv3_addr definition.

(From OE-Core rev: bc2581aff2a859b414c8097514527a9b5b0ab2a6)

Signed-off-by: Yauhen Kharuzhy <yauhen.kharuzhy@promwad.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:38 +00:00
Andreas Oberritter
83d1d135d6 mpeg2dec: depend on libx11 conditionally
* mpeg2dec currently doesn't build if x11 is unavailable,
  due to an unconditional dependency on libx11. However,
  libx11 is not required to build mpeg2dec.

(From OE-Core rev: 6ebbeeb0bcd29aec25e2c437d0bc95dd78d62f82)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:38 +00:00
Andreas Oberritter
c6580ce1e4 gst-plugins-base: depend on libx11 and libxv conditionally
* gst-plugins-base currently doesn't build if x11 is
  unavailable, due to unconditional dependencies on libx11
  and libxv. However, they are not required to build
  gst-plugins-base.

(From OE-Core rev: 668ebf38a5b9b0dbd0f6f1a0ebfafb04afbcbf07)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:37 +00:00
Mike Crowe
8d26a9f7e6 e2fsprogs: Cope with ${libdir} and ${base_libdir} being the same
${libdir} and ${base_libdir} may be the same. If they are don't try and
move files onto themselves.

(From OE-Core rev: 992604c533c9f3c2133cfa87c1121d43a508ec4a)

Signed-off-by: Mike Crowe <mac@mcrowe.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:37 +00:00
Andreas Oberritter
578b6f222d busybox: don't create /etc/default
* It's not used by the recipe and its creation
  currently depends on CONFIG_HWCLOCK=y.

(From OE-Core rev: cd59c2fcefa6aeacf78a63c5c9a623a4d77c0941)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:37 +00:00
Andrei Gherzan
762966eaae dbus: Remove empty ${lindir}dbus-1.0/test directory as we don't build tests
This empty directory generates a QA warning of unshippped files/dirs.

(From OE-Core rev: d3573ae136c532d3cf537ef05c22f163275f4f41)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:37 +00:00
Andrei Gherzan
566ae9796b e2fsprogs: e2initrd_helper was moved in libdir but not packaged correctly in FILES_libext2fs
The new install path of e2initrd_helper is %{libdir}. FILES_libext2fs modified accordigly to
avoid QA warnings.

(From OE-Core rev: 31684b34f3521e97dbfd35ff961960b9792ef657)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:36 +00:00
Andrei Gherzan
aba82ec3cd nspr: Add patch in order to remove rpath from binaries
This patch was created in order to avoid QA warnings.

(From OE-Core rev: 16b8a25ec03b9e9f360290263593b9f8f92bb9e1)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:36 +00:00
Andrei Gherzan
d8a78f3e32 nspr: Compile nspr with tests
1. Compile package tests suite
2. Add tests to -dev rpm as it needs dev libraries

(From OE-Core rev: c78db5086091e09e510fcd275918aee0949483c1)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:36 +00:00
Andrei Gherzan
af57b2e7ca nspr: Integrate version 4.8.9
(From OE-Core rev: cbe6eced99566129c575b43a58cdde2ac669a741)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Sergey 'Jin' Bostandzhyan <jin@mediatomb.cc>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:36 +00:00
Andrei Gherzan
adbe09435a dhcp: Update to 4.2.3-P2
1. Update to 4.2.3-P2
2. From 4.2.0 final release, -lcrypto check was removed and we compile static libraries
from bind that are linked to libcrypto. This is why i added a patch in order to add
-lcrypto to LIBS.
3. Add openssl in DEPENDS as we need libcrypto from this package
4. Drop installing /var/lib/dhcp/ as it is handled in pkg_postinst

(From OE-Core rev: 1cd882c47865a501d5401bad44e1c7f460ce2699)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:35 +00:00
Andreas Oberritter
a470400cf8 autotools.bbclass: Don't copy into non-existant directory
* 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.

(From OE-Core rev: ba175bdfe85d701298d28e5190e55207420a24e8)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:35 +00:00
Martin Jansa
a6fb1939c1 wireless-tools: remove ldconfig call from install-libs
* and drop apply=yes param as it's not needed

(From OE-Core rev: ca343882f8e95b49b18b234000e387c879cf5885)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:35 +00:00
Gary Thomas
daeb5beb8f initscripts: Make /etc/timestamp consistent again.
Commit cc8695 changed the way timestamps were handled
and added some extra munging to be able to compare them
reliably.  This change makes the timestamp value the same
everywhere and simplifies how the check to set the system
clock based on the timestamp is done.

Also, if the value stored in /etc/timestamp is newer
[at all] than the current system time, set the system clock
from the stored value, down to the minute, not just the day.

(From OE-Core rev: 5aab6653c9afa05e7c1b3ccd6bd34aec05c2a6f8)

Signed-off-by: Gary Thomas <gary@mlbassoc.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:35 +00:00
Andreas Oberritter
831e0b5cd7 xorg-lib: don't build libs unless requested by DISTRO_FEATURES
* If 'x11' is not set in DISTRO_FEATURES, then skip all
  recipes using xorg-lib-common.inc instead of only those
  using libx11.inc.

* One exception: pixman, which is not only used by xorg,
  but also by cairo.

(From OE-Core rev: a101bc85adcc915f151348107e850b8998a395b0)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:59:34 +00:00
Martin Jansa
5a4b06ddec e2fsprogs: remove ldconfig call from install-libs
(From OE-Core rev: 6a74c2050de4540deaf4e855bdf7aec4518f648a)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:53:03 +00:00
Martin Jansa
30b709c50c sstate.bbclass: add *_config to SSTATE_SCAN_FILES
* e.g. mysql5 has mysql_config not mysql-config

(From OE-Core rev: aebdffc93ba8446bbd4e20263f0f75d4d4460c47)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:53:02 +00:00
Martin Jansa
331540ca8b apr: add apr_rules.mk to SSTATE_SCAN_FILES
(From OE-Core rev: 9db1f3b13c7e7f37c41f6a4fabdb2fc0c5ebc227)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:53:02 +00:00
Koen Kooi
9d6d5e37ab libsdl 1.2.14: regenerate patch so it applies with 'patch' as well as 'git apply'
The '@@ -, +, @@' part upsets plain 'patch'

(From OE-Core rev: 949f4dc6f2bd59aa3e2c782fee87f07438aebd21)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 23:50:52 +00:00
Richard Purdie
26882fdd67 sstatesig.py: Move package exclusion list to the layer config
its desireable for other layers to be able to append to the list of packages
with 'safe ABI's which are excluded from the sstate signatures.

I can't emphasise enough how careful you need to be with this list, anything
excluded here needs to be things which don't change interface and are consistent
between different machines.

(From OE-Core rev: 5adef35691a956c3071c0a1ed1caf6b58d1ec5a1)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:22 +00:00
Richard Purdie
77988c32f1 sstatesig.py: Add handling for machine specific module dependencies
Adding dependencies on machine specific recipes from generic packages
causes a rebuild of the generic package per machine if using signatures
for the stamp files which is unacceptable.

We need to declare that RRECOMMENDS on kernel-module-* are safe
and that we shouldn't care about these machine specific dependencies
from a stamp perspective. This change adds code which does this.

It depends on a change in bitbake to expose the dataCache object
which can be used to make the calculations we need to allow this to
work correctly.

(From OE-Core rev: 91fc672756d45086cdf4e9c6de8e920dcd8cd14e)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:22 +00:00
Martin Jansa
2ede6787ea python: add Makefile to SSTATE_SCAN_FILES
* it contains sysroot specific paths, this is from om-gta04 sysroot and
  notice nokia900
  ./usr/lib/python2.7/config/Makefile:CC=         arm-oe-linux-gnueabi-gcc  -march=armv7-a -fno-tree-vectorize      -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 -D__SOFTFP__ --sysroot=/OE/shr-core/tmp-eglibc/sysroots/nokia900
  ./usr/lib/python2.7/config/Makefile:CXX=                arm-oe-linux-gnueabi-g++  -march=armv7-a -fno-tree-vectorize      -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 -D__SOFTFP__ --sysroot=/OE/shr-core/tmp-eglibc/sysroots/nokia900
  ./usr/lib/python2.7/config/Makefile:LDFLAGS=-L. -L/OE/shr-core/tmp-eglibc/sysroots/nokia900/usr/lib     -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed
  ./usr/lib/python2.7/config/Makefile:LIBDIR=             /OE/shr-core/tmp-eglibc/sysroots/nokia900/usr/lib
  ./usr/lib/python2.7/config/Makefile:INCLUDEDIR= /OE/shr-core/tmp-eglibc/sysroots/nokia900/usr/include
  ./usr/lib/python2.7/config/Makefile:CONFIG_ARGS=         '--build=x86_64-linux' '--host=arm-oe-linux-gnueabi' '--target=arm-oe-linux-gnueabi' '--prefix=/usr' '--exec_prefix=/usr' '--bindir=/usr/bin' '--sbindir=/usr/sbin' '--libexecdir=/OE/shr-core/tmp-eglibc/sysroots/nokia900/usr/libexec' '--datadir=/usr/share' '--sysconfdir=/etc' '--sharedstatedir=/com' '--localstatedir=/var' '--libdir=/usr/lib' '--includedir=/OE/shr-core/tmp-eglibc/sysroots/nokia900/usr/include' '--oldincludedir=/usr/include' '--infodir=/usr/share/info' '--mandir=/usr/share/man' '--disable-silent-rules' '--disable-dependency-tracking' \
  '--with-libtool-sysroot=/OE/shr-core/tmp-eglibc/sysroots/nokia900' '--with-threads' '--with-pymalloc' '--with-cyclic-gc' '--without-cxx' '--with-signal-module' '--with-wctype-functions' '--enable-shared' 'build_alias=x86_64-linux' 'host_alias=arm-oe-linux-gnueabi' 'target_alias=arm-oe-linux-gnueabi' 'CC=arm-oe-linux-gnueabi-gcc  -march=armv7-a -fno-tree-vectorize      -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 -D__SOFTFP__ --sysroot=/OE/shr-core/tmp-eglibc/sysroots/nokia900' 'CFLAGS=-O2 -pipe -g -feliminate-unused-debug-types' 'LDFLAGS=-L. -L/OE/shr-core/tmp-eglibc/sysroots/nokia900/usr/lib-Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed' 'CPPFLAGS=' 'CPP=arm-oe-linux-gnueabi-gcc -E --sysroot=/OE/shr-core/tmp-eglibc/sysroots/nokia900  -march=armv7-a -fno-tree-vectorize      -mthumb-interwork -mfloat-abi=softfp -mfpu=neon -mtune=cortex-a8 -D__SOFTFP__'
  ./usr/lib/python2.7/config/Makefile:            $(RUNSHARED) /OE/shr-core/tmp-eglibc/sysroots/nokia900/usr/libexec/oah/translate ./$(BUILDPYTHON) -E -tt $(TESTPROG) -uall $(TESTOPTS)

(From OE-Core rev: bf1628286987ad6b4a762b0aeb6aece4a51e7255)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:21 +00:00
Andreas Oberritter
571c9c7980 lib/oe/utils.py: use bb.utils.vercmp_string
Fixes the following warning:

| WARNING: .../meta/lib/oe/utils.py:31: DeprecationWarning: Call to deprecated function bb.vercmp_string: Please use bb.utils.vercmp_string instead.
|  result = bb.vercmp(d.getVar(variable,True), checkvalue)

(From OE-Core rev: 925a9729afaa9cd498661f7f363112c974b023a2)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:21 +00:00
Shane Wang
8fa33800ef bitbake: change for adding progress bar in Hob2.
The changes include:
- Clean some events in event.py
- Fire essential events for Hob2 to handle with more information.
- knotty changes

(Bitbake rev: 9ede881620c501574f014e600cea6947ea908ac2)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:17 +00:00
Dongxiao Xu
de77b9752a command.py: add resolve option for generateTargetsTree API
Currently we have generateTargetsTree API, which is used to get
dependency information. However in that tree, there will be
"virtual/xxx" in depends fields. Therefore we add the resolve option
to replace it with its real providers.

Besides, for packages that provided by multiple recipes, we will find
their preverred provider.

(Bitbake rev: 28501612efdfc6ee47576cc90deb6e897883e7f5)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:17 +00:00
Dongxiao Xu
85fa989df7 command.py: Add a new API triggerEvent()
This functions enables the client to request triggering specific event
from bitbake server.

(Bitbake rev: 45da6d709a69697158fae92e1c0c0a6ac8f30831)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:16 +00:00
Shane Wang
cb873084d0 command.py: add new API to get the cpu count on the server
Add a new API in command.py to get the cpu count in order to set the appropriate default BB_NUMBER_THREADS and PARALLEL_MAKE variables.

(Bitbake rev: 335047b2e440e65713e88fabb24b47a9c82f939b)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:16 +00:00
Dongxiao Xu
c42f973180 bitbake: Add client socket info for BitBakeServerConnection
In server/client split model, the client will bind to a specific address
and port. We need to pass the values to BitBakeServerConnection().

(Bitbake rev: c8e19c5c389efc06696084c6f9439ba75472c5b7)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:16 +00:00
Dongxiao Xu
19089aca83 bitbake: add -B option to bind with interface
When start bitbake as a server only process, we need to assign certain
interface to it.

(Bitbake rev: 95b97d2dc6466ea3d99371f5b5bd68f6f3c99074)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:16 +00:00
Dongxiao Xu
b70bcb353d event.py: Add new events RequestPackageInfo and PackageInfo
RequestPackageInfo is triggered by GUI client to request the available
package information.

PackageInfo event is to pass package information back to GUI.

(Bitbake rev: 9020c2d4476766f63ff7e024bbd99043d06feefc)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:15 +00:00
Dongxiao Xu
8e737db4fc cache: Use configuration's hash value to validate cache
Previously we use the file time stamp to judge if a cache is valid.
Here this commit introduce a new method, which calculates the total
hash value for a certain configuration's key/value paris, and tag
it into cache filename, for example, bb_cache.dat.xxxyyyzzz.

This mechanism also ensures the cache's correctness if user
dynamically setting variables from some frontend GUI, like HOB.

(Bitbake rev: 1c1df03a6c4717bfd5faab144c4f8bbfcbae0b57)

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:15 +00:00
Paul Eggleton
99d326a818 bitbake: add file and line number to ParseError
Ensure that a file and line number are reported for ParseError where
possible. This helps particularly in the case of inherit and require
which previously did not report either of these upon failure.

(Bitbake rev: f588ba69622a2df35417ced184e56c79ac1b40d5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:15 +00:00
Paul Eggleton
ebc0d4252a bitbake: fix parse errors not being reported
Fixes a regression introduced in BitBake rev
c9f58ef6b897d3fa5b0d23734b5f2cb3dabb057a which prevents errors during
parsing from being fully reported because BitBake shuts down before it
can print them. Move the error printing to before the shutdown in order
to fix it.

Also remove a couple of superfluous calls to sys.exit() since these
will never be called (as self.shutdown(clean=False) does this itself).

(Bitbake rev: 356c42ed00541dea2c382c57f768a4f431d22db0)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:15 +00:00
Richard Purdie
4a1c163b55 siggen.py: Pass the datacache to signature generator classes
The dataCache exposes much useful information to the singature generation code
for example its possible to figure out whether kernel dependencies are
important or not based on the RRECOMMENDS values.

We therefore pass this information to the handler and trust it to handle
any API changes in the dataCache structure.

For backwards compatibility, OE-Core is already updated to handle
the extra argument when it appears.

(Bitbake rev: 4ebc25155d5f96a7f63de22b52b18d045eb4dec7)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-23 22:52:15 +00:00
Zhai Edwin
d8b3718303 texi2html: Fix for multilib
(From OE-Core rev: 55f72b98f606c1554eb6edd151292ffdfddf1384)

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 23:03:16 +00:00
Zhai Edwin
65c1399be1 quicky: Fix for multilib
(From OE-Core rev: 1be7873cec6630ddb485590a8473e04cfb224615)

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 23:03:16 +00:00
Joshua Lock
a578fbce14 netbase: remove redundant assignments
There's no need to explicitly set PACKAGE_ARCH = MACHINE_ARCH, base.bbclass
takes care of setting this value for us based on the interfaces for those
machines being an OVERRIDE.

(From OE-Core rev: c3d5800d2850a186f91b5a0db642aa5d1c20156b)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 22:11:27 +00:00
Joshua Lock
729a9019bc base.bbclass: check all entries of FILESPATH for MACHINE overrides
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.

(From OE-Core rev: f2b572072c754048aaafdc4c42b71af87d61d9e7)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 22:11:27 +00:00
Joshua Lock
f409a49c3a external-csl-toolchain: skip parsing if CSL_VER_MAIN isn't set
(From OE-Core rev: 264d1254e5ac11613af06c0f1c53c736f54e9f54)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 22:11:26 +00:00
Richard Purdie
83007574cc sanity.bbclass: Add ABI version 8, used for transition from the OEBasic to OEBasicHash stamp layout
(From OE-Core rev: bf440fd971dd549ae4e92c54046ea062ef51cd85)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 22:06:19 +00:00
Richard Purdie
ea2c8defd5 meta-yocto: Add abi_version setting version 8, to match the OEBasicHash change and trigger warnings for existing build directories
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 22:06:11 +00:00
Lianhao Lu
3a2338607b meta-yocto/conf: Change default signature handler.
[YOCTO #1555]
1. Changed default signature handler to 'basichash' in poky.conf.
2. Added comment about PRservice settings in local.conf.extened.

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
2012-02-22 22:05:59 +00:00
Richard Purdie
30d0bbfb01 layer.conf: We really need to be able to override files in the core so reverse BBPATH priority
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 22:05:46 +00:00
Paul Eggleton
c8286e049f bitbake/ui/knotty: fix incorrect exit code
The recent Ctrl+C patch was not fully tested; the variable it was
relying upon is set to non-zero under other circumstances and thus
bitbake was reporting that it was interrupted and returning a non-zero
exit code when it was not. Track this status in a separate variable
in order to fix the issue.

(Bitbake rev: 95a599067650902727ecb4a39d6dd003c5cfedf3)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 21:30:29 +00:00
Martin Jansa
8e0c7b3c0d siggen: compare runtaskdeps dictionary even when they have the same size
* otherwise it reports lots of changed checksums just because it compares different tasks

  notice linux-libc-headers_3.1.bb.do_package_write:
  Task dependency hash changed from 42acced29debf54d598802474c5e9cbb to f438a54f995df77620d0727d6f4b4ce5 (for linux-libc-headers_3.1.bb.do_package_write and linux-gta04_git.bb.do_deploy)
  Task dependency hash changed from 61f8babe1d10c6e7fb1423112bb04e1e to 1b3e21ff106ecfcb7ddf76a1e29537bb (for linux-nokia900-meego_git.bb.do_deploy and linux-gta04_git.bb.do_package_write)
  Task dependency hash changed from 512f9d6686d760b318d8b11c8b589226 to 42acced29debf54d598802474c5e9cbb (for linux-nokia900-meego_git.bb.do_package_write and linux-libc-headers_3.1.bb.do_package_write)
  Task dependency hash changed from 153e91dfd1d2053fda7b98cc08d4b802 to 92a293bdd8ed234932b87a66025038c5 (for systemd-serialgetty.bb.do_package_write and systemd-serialgetty.bb.do_package_write)
  Task dependency hash changed from 730abebf9954794bb440c2f3239f79fe to 413eaebaff27a2fd16f5cf68c1f4ff17 (for systemd_git.bb.do_package_write and systemd_git.bb.do_package_write)

  with this patch:
  Dependency on task linux-nokia900-meego_git.bb.do_package_write was added
  Dependency on task linux-nokia900-meego_git.bb.do_deploy was added
  Dependency on task linux-gta04_git.bb.do_deploy was removed
  Dependency on task linux-gta04_git.bb.do_package_write was removed
  Hash for dependent task systemd_git.bb.do_package_write changed from 730abebf9954794bb440c2f3239f79fe to 413eaebaff27a2fd16f5cf68c1f4ff17
  Hash for dependent task systemd-serialgetty.bb.do_package_write changed from 153e91dfd1d2053fda7b98cc08d4b802 to 92a293bdd8ed234932b87a66025038c5

* added test if there is different task with same hash then we don't
  show it as added/removed dependency, because bitbake doesn't care

(Bitbake rev: ca52bf32b479811bd7fed41648bedcc06b00430b)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:32:40 +00:00
Paul Eggleton
e228289bf0 bitbake/knotty: ensure CommandFailed increases error count
CommandFailed already sets the return code, so we print out the error
summary message, however we don't increase the error count so it is
usually zero in this case. As we are actually showing an ERROR message,
increment the error count so that the summary makes sense.

(Bitbake rev: aeb71c3ca65dc42015c29c0e4cac050bfbcb51a5)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:25:31 +00:00
Paul Eggleton
b62249f3db bitbake/knotty: ensure we return non-zero exit code on Ctrl+C
If the user uses Ctrl+C to exit out of the build, then ensure we return
a non-zero exit code since the entire build was not completed
successfully.

If nothing else, this is useful to avoid continuing in the bitbake
wrapper script in OE-Core if the initial pseudo build is interrupted.

(Bitbake rev: c11eab7fa230f1fd5cc33589f3555b94e95f202d)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:25:30 +00:00
Paul Eggleton
5210cc40db bitbake: show appropriate warnings for universe target
When building the universe target:
* Show a warning about universe likely producing errors
* Multiprovider errors are now shown as warnings

Also remove an unused "error" variable in runqueue.py.

Fixes [YOCTO #1936]

(Bitbake rev: 293c796e8a3d1f74ca1e51017b6dede261612281)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:25:30 +00:00
Caleb Crome
0aedc60b02 Fix parser hang at 0% with single-core machines
The number of threads is self.num_processes - 1 due to the range(1,
self.num_processes). Fixed by changing to range(0, self.num_processes).

(Bitbake rev: adc041fd9e3def29cdf9c1ae4849c5383bac46e5)

Signed-off-by: Caleb Crome <caleb@signalessence.com>
Signed-off-by: Christopher Larson <kergoth@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:25:30 +00:00
Christopher Larson
f7c0488bd5 persist_data: survive if sqlite3 couldn't enable the shared cache
(Bitbake rev: e870fd57bb84a17a871a5b5de3bf5202fe9b135f)

Signed-off-by: Christopher Larson <kergoth@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:25:29 +00:00
Christopher Larson
52ebd5ff1b knotty: shut down more cleanly
This ensures that when we are shutting down, we drain the queue of events from
the server. This ensures that the server never gets hung up on the join of the
feeder thread associated with the event queue, thereby avoiding a bitbake hang
issue.

Also, since the third keyboard interrupt now behaves the same as the second,
removed that message.

(Bitbake rev: ce9e0946b8a412616074809c76fba54f8bff36c4)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:25:29 +00:00
Christopher Larson
cf60f95d9f cooker: roll our own process pool
This fixes the hang issue encountered with parse errors. The underlying issue
seems to have been the pool.terminate(). This sends SIGTERM to each of the
multiprocessing pool's processes, however, a python process terminating in
this fashion can corrupt any queues it's interacting with, causing a number of
problems for us (e.g. the queue that sends events to the UI).

So instead of using multiprocessing's pool, we roll our own, with the ability
to cancel the work. In the very long term, the python concurrent.futures
module introduced in python 3.2 could be used to resolve this as well.

(Bitbake rev: 7c39cfd8e060cca8753ac4114775447b18e13067)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-22 20:25:29 +00:00
Saul Wold
87e32edb88 iputils: Add base_libdir to VPATH in order to find the crypto library
(From OE-Core rev: d4ffe12ca36bf10be4e0f9565d7c3d8e6f4a265a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:40 +00:00
Andreas Oberritter
d27351a2c2 consolekit: depend on libx11
* Fixes the following error at configure time:

|checking for TOOLS... no
|configure: error: Package requirements (x11 >= 1.0.0
|  glib-2.0 >= 2.14
|) were not met:
|
|No package 'x11' found

(From OE-Core rev: e5c60517a22997bb966bbe21a2d7cbc99a97b42b)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:39 +00:00
Bob Cochran
92dd65f05a udev.inc has a bad link for udev home page; update the link
Fixed bad link in udev.inc to the udev home page / documentation on
kernel.org

(From OE-Core rev: 479b9a52a013d990da296f96bd658db00423f9a6)

Signed-off-by: Robert Cochran<yocto@mindchasers.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:39 +00:00
Ken Werner
9c16786928 Add sanity checks for eglibc locale
Add sanity checks that test for the existance of folders. This allows to use
an external binary toolchain that doesn't have localization support.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:39 +00:00
Martin Jansa
b2a84e717e libsdl: add fix for new _XGetRequest symbol backported to libx11
(From OE-Core rev: d2c96e22de19a649ff7121e5ea0f95797abba93a)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:39 +00:00
Wenzong Fan
888f9d59a9 eds-tools: Update it to fix the build error
The head file 'libedataserver/e-data-server-module.h' has been moved
to 'libebackend/e-data-server-module.h', just update eds-tools to get
the latest changes for fixing the path of 'e-data-server-module.h'.

Also update its recipe file to reflect it has been converted to git
repo and split all generated binaries to correct packages.

[YOCTO#1786]

(From OE-Core rev: 38d74ee1fe6f28ec4d7db79f550c7d2830d922fb)

Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:38 +00:00
Paul Eggleton
5aec33be72 buildhistory_analysis: correctly split RDEPENDS/RRECOMMENDS
Split RDEPENDS and RRECOMMENDS correctly (which may contain version
number specifications after each item).

(From OE-Core rev: d974ed4330f33c4f8dfd635a83c61a0d44e688b6)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:38 +00:00
Paul Eggleton
79eb4b8fdb buildhistory_analysis: avoid noise due to reordering
Avoid noise in the output due to reordering of list variables (except
for PACKAGES where we just report that the order changed). Recent
changes to the buildhistory class itself will avoid this reordering
from occurring but this allows us to examine the results before and
after those changes.

(From OE-Core rev: e23c5b01766602c9c86b0a7ba170fb3b1aceb658)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:38 +00:00
Paul Eggleton
e155952b4d classes/buildhistory: fix splitting on + in package list fields
Ensure we do not erroneously split on + in RDEPENDS/RRECOMMENDS e.g.
libstdc++-dev was being split into libstdc and -dev.

(From OE-Core rev: cad533880df42ad4fe6f04d56d3a59cb4a033275)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:37 +00:00
Paul Eggleton
1b7014ffc5 classes/buildhistory: use hostname instead of reading /etc/hostname
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.

(From OE-Core rev: cb939b753c9e7648a38e22e0349c279da785e69d)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:37 +00:00
Paul Eggleton
04c290a492 classes/buildhistory: sort FILELIST in package info
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.

(From OE-Core rev: 2e9981000a211a89f88d7728393cc231e466581a)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:37 +00:00
Paul Eggleton
3cce3196fa classes/buildhistory: sort and de-dupe dependency graphs
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).

(From OE-Core rev: 830df6067c1ea4a5aab580b42ba7e1e84fe1bcbf)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:37 +00:00
Paul Eggleton
7b3ea97051 classes/buildhistory: squash spaces out of image variables
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.

(From OE-Core rev: 200159125eb6bcfc046c45cf5160b2eb340625e3)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:37 +00:00
Dexuan Cui
9eab86041f task-self-hosted: add connman and connman-plugin-ethernet
Without this, the VMware guest running self-hosted-image can't get IP
address automatically.

(From OE-Core rev: 3fa9a7e4dc9eadce22a9838d2067d5af0111b04b)

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:36 +00:00
Dexuan Cui
0f00536d0a mini-x-session: try to use a resolution that's big enough for hob2's window
The patch was tested on VMware Player 4.0.1.

(From OE-Core rev: d33cc3be420fb509d8dddb1f1a752db6d41f50f9)

Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:36 +00:00
Lianhao Lu
ab5eed4af1 gcc: Excluding the DATE/SRCDATE from do_patch dependency.
Corrected the error introduced by commit afb400e of dropping
DATE/SRCDATE out of the vardepsexlude list of do_patch.

(From OE-Core rev: 6546096d068b51cc9cf4557cdb35aee6f62838d5)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:36 +00:00
Saul Wold
2101ea6367 rpcbind: add DEPENDS on quota for rpcsvc/rquota.h
(From OE-Core rev: 4771f4af5926d724958ba7cf46b937c53babfc7c)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:36 +00:00
Saul Wold
63b680ed05 u-boot-fw-utils: Add DEPEND on mtd-utils
(From OE-Core rev: 47d8444edb644a92d3bae524c8a2a42a1cdf740c)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:59:35 +00:00
Martin Jansa
b2196ca256 zlib: remove ldconfig call from install-libs
* it's called from install-libs target and when /etc/ld.so.cache is writeable by user running bitbake
  then it creates invalid cache (in my case libstdc++.so cannot be found after building zlib(-native)
  and I have to call touch */libstdc++.so && /sbin/ldconfig to fix it

(From OE-Core rev: b5c8add7f3ed58451cb460a242b4edd671ba618e)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:48 +00:00
Martin Jansa
0761649736 recipes: bump PR to rebuild .la files without libz.la
(From OE-Core rev: 1da6a2dbd5e7aeea6cd45ca05590bdd50b67bf89)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:47 +00:00
Paul Eggleton
c3b3a681f7 scripts/combo-layer: allow updating a specific component(s) only
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.

(From OE-Core rev: 1779afce024b31edcf846329da705ed5aa9fe63e)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:47 +00:00
Paul Eggleton
7f880ca20d conf/bitbake.conf: remove Opie definitions
These values are now set via palmtop-defs.bbclass in meta-opie (and are
not needed for anything else.)

(From OE-Core rev: a18de4dc0b988c79964354496a6a93c7ee5a28f6)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:47 +00:00
Paul Eggleton
362fd558fe classes/sdl: remove Opie-specific desktop file/packaging
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).

(From OE-Core rev: e45b0672e28d19cfb66c9e57e153ef15e004dcaf)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:46 +00:00
Paul Eggleton
8a31618c35 stat: remove NATIVE_INSTALL_WORKS
This variable is no longer used in OE-Core.

(From OE-Core rev: b70d100047912569d6eb060eb48a753c56968d89)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:46 +00:00
Paul Eggleton
cf10b9b847 scripts/combo-layer: add branch option to example config
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

(From OE-Core rev: 065798d8dd0552934175f794f7678e0dd24ef152)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:46 +00:00
Paul Eggleton
8e7cd329b1 scripts/combo-layer: avoid saving last revision if unchanged
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.)

(From OE-Core rev: 4592f238de3fe6b0384c334774be9fcfc0985e4f)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:46 +00:00
Paul Eggleton
f273c04175 scripts/combo-layer: avoid error when config file is outside repo
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).

(From OE-Core rev: 9d3e54057673348e85ba479705c4ffaad56973d6)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:45 +00:00
Paul Eggleton
0656f57235 scripts/bitbake: pass through debug options to initial pseudo build
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.

(From OE-Core rev: dcf6f72c35f7c108e447d01c15df86807e26a88b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-21 17:00:45 +00:00
Lianhao Lu
41a83ccfe5 guile: fix cross configure failure
[YOCTO #1978]
Fixing the cross configure failure by not searching libltdl and libgmp
in includedir and libdir.

(From OE-Core rev: e5ad03093dfc4364d1407183f458df79f347c7a1)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 17:01:42 +00:00
Christopher Larson
754847f34b Revert the switch to futures for now
Without it, we get random hangs on parse failure. With it, some folks have
seen hangs even on successful cases. The former is clearly less problematic.
This is temporary, until I can finish investigating the root causes of both
issues.

(Bitbake rev: db689a99beffea1a285cdfc74a58fe73f1666987)

Signed-off-by: Christopher Larson <kergoth@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 17:00:54 +00:00
Richard Purdie
d366c1890e siggen.py: Handle cases where the input to symmetric_difference() may be None
[YOCTO #1967]

(Bitbake rev: f6cee29bf853874876923a7d6ae8574e3801ae8d)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 16:57:27 +00:00
Saul Wold
d3d11016de valgrind: Fixed Added-support-for-PPC-instructions-mfatbu-mfatbl.patch Upstream-Status
(From OE-Core rev: c8f821484939348dfa63e11c5c9c6571708553ab)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 16:56:59 +00:00
Lianhao Lu
a2a03ba68b gcc: Ensure same sstate hashes for shared soruce directory
Ensure do_patch have the same sstate hashes for nativesdk variants of
gcc family recipes, since they share the same source directory.

(From OE-Core rev: afb400e9c3ddac604906bde44df5da29a6c134d9)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:46 +00:00
Richard Purdie
c62296dab6 gcc-4.6: Some small performance tweaks
a) Use the system zlib to avoid building it for each gcc.
b) -initial and -intermediate don't need plugins or lto-plugin
   so disable them.

(From OE-Core rev: a124a0883507caf4ffb7e25be666f6781b30abdd)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:45 +00:00
Richard Purdie
12306d01a0 package.bbclass: Optimise the per file rpm handling
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%).

(From OE-Core rev: 548037acd63bd4859f8de8d23a3d12f36ce9f97f)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:45 +00:00
Richard Purdie
d60912993d sstate.bbclass: Optimise sstate_hardcode_path
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.

(From OE-Core rev: 4159ff761cf29a03aeb56c7686a4e7af02b52219)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:45 +00:00
Khem Raj
765547eb71 gnupg: Add missing DEPENDS on libgcrypt
Found during single recipe rebuilds

(From OE-Core rev: bb672b1591197966b79fbcf7753f995b8e829e65)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:45 +00:00
Khem Raj
84983afa63 sat-solver: Fix build with zlib 1.2.6
(From OE-Core rev: 6064f6bd7c28640db59a216aa578f3cca6219b1f)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:44 +00:00
Khem Raj
a142cbd47e zlib: Upgrade 1.2.5 -> 1.2.6
Dont use autotools, it really not so autoconf like.
the configure script gets updated with every release of zlib
and we overwrite that. Instead use the upstream provided
configure

copyright year was changed in zlib.h which caused change in
LIC_FILE_CHECKSUM

fix.inverted.LFS.logic.patch is already applied upstream so drop it

Drop the configure.ac and Makefile.am scripts since we do not
autoreconf anymore and do not inherit autotools anymore

Bump PR for depending recipes so a rebuild it ensues so that
they dont depend on .la anymore
and add missing dependencies discovered during incremental
build

(From OE-Core rev: 50ad5230ea9e0982cdfda23fb9fcfccf89d28f29)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:44 +00:00
Joshua Lock
65d296a235 distro-tracking-fields: update clutter, clutter_git and mx
(From OE-Core rev: e303aeec9a97903479baad836671591b511b3e19)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:43 +00:00
Joshua Lock
18c3197911 clutter: upgrade git recipe to reflect 1.8.4 tag
(From OE-Core rev: 37b47a8f038947c6725dec10845412df7f67e9e4)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:42 +00:00
Joshua Lock
970fcc886e mx: ensure gettext and dbus are present
Upstream informs me that D-bus isn't really optional as it's required
to make some of the API work such as the single instance MxApplication.
Therefore ensure we're building with it enabled.

Gettext macros are used in the configure.ac so inherit gettext to
ensure the required dependencies are present.

(From OE-Core rev: fe2c13684e2a0b652007e92a6f11942c6366483e)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:42 +00:00
Joshua Lock
15ff81be40 mx: update to 1.4.2
Patch in a copy of introspection.m4 so that we can continue to easily and
cleanly disable introspection.

(From OE-Core rev: 84d62181f80402fa461675e03b20ba08da1991e8)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:42 +00:00
Joshua Lock
51c719d779 clutter-1.8: update to clutter-1.8.4
Added a note about why we're setting S, so I don't have to figure it out again
next time I try and update clutter.

(From OE-Core rev: b752e2d6ae286db5588547fc49f1aa64e112fa32)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:42 +00:00
Matthew McClintock
0de4750a57 powerpc64-linux: Update cached autoconf values for libpcap on powerpc64
Without this fix, libpcap will fail to build on powerpc64

(From OE-Core rev: 01a28e8b04c206e54bcb01ccd7401c08d5c600ce)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:41 +00:00
Tom Rini
c56792ce08 u-boot-fw-utils: Add for v2011.06
This provides the 'fw_setenv' and 'fw_getenv' programs for the target
so that the U-Boot environment can be modified from Linux.  These
programs are system-agnostic and rely on a config file that a given BSP
would provide and potentially RRECOMMEND this be installed.

(From OE-Core rev: 4a2543c0641f1df6d74c18cfe0c3ac3cfd50e60c)

Signed-off-by: Tom Rini <trini@ti.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:41 +00:00
Matthew McClintock
433f2ead93 distutils.bbclass: override LDSHARED so we use the linker for this build and 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.

(From OE-Core rev: 3f6b859a29ba7f570b9dae3b5bb7ab4bd7b8cee4)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:41 +00:00
Otavio Salvador
ef5bad08de cross.bbclass: add virtclass handler
Allow use of BBCLASSEXTEND with 'cross' and use of virtclass-cross in
recipes.

(From OE-Core rev: 9624a817bb7d2d9fce10704b1c1a047f93260f36)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:40 +00:00
Otavio Salvador
af85900ba7 useradd.bbclass: skip processing on virtclass-cross extended packages
(From OE-Core rev: 4308acbbd43e6b8b37123d95df6675233007dae4)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:40 +00:00
Christopher Larson
d90565366c external-csl-toolchain: fix mtd-user.h issue
The use of __packed, which isn't defined in userspace, caused busybox build
failures.

(From OE-Core rev: 9c44bb6434a1d2347ebbb38bde9671688b0ae447)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-10 14:38:39 +00:00
Paul Eggleton
8d41b0ddbf bitbake-layers: add copyright notice
This ought to have been added earlier. (I consulted with Chris Larson on
the notice covering his work.)

(Bitbake rev: 69ed02b645bdc28c1bf24e436beeed37d226b56b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-09 14:14:20 +00:00
Christopher Larson
1e8b62991a tcmode-default: add preference for gdb/gdbserver
(From OE-Core rev: 4ef5e70f531f48cef90805402c16ec02ad3f2b92)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 16:28:35 +00:00
Paul Eggleton
1a35ed4f5d classes/buildhistory: sort list fields in package info
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]

(From OE-Core rev: 06b740d4ca077fb4c89ee6d1065fabb02da45ec6)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 10:57:09 +00:00
Paul Eggleton
8653bf474e classes/buildhistory: sort image file list
Sort the contents of files-in-image.txt to avoid unnecessary changes
showing up in the history due to reordering.

(From OE-Core rev: 791ad7a522f6800114febd1605072202c1450356)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 10:57:09 +00:00
Christopher Larson
4255cb85a0 external-csl-toolchain: split out gdbserver packages
(From OE-Core rev: b6ddd434c47c66fdd6dd27a31e545f46b52bc90f)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 10:57:09 +00:00
Christopher Larson
57b7b8a7ba external-csl-toolchain: correct binary packaging
CS puts optimized executables in usr/lib/bin, not usr/bin.

(From OE-Core rev: 25d22bfb0970f7152b678796f2282dced7230fe1)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 10:57:09 +00:00
Christopher Larson
b5b4066b08 external-csl-toolchain: set PKG/PKGV for staticdev
(From OE-Core rev: 481f6f32cd414ff11f154adc24f1b596495286df)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 10:57:09 +00:00
Saul Wold
af1ddab5c3 task-core-tools-profile: fix valgrind for arm and systemtap for mips
(From OE-Core rev: e5f41c2213568c7aef24ce8f666042492054377d)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 10:57:08 +00:00
Saul Wold
8054217a35 poky.conf: Fix the MIRROR URI
Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-02-08 00:50:49 +00:00
Saul Wold
be174f37b9 task-core-tools-profile: change to match oe-core
Signed-off-by: Saul Wold <sgw@linux.intel.com>
2012-02-08 00:50:40 +00:00
Khem Raj
eb1be234fc mirrors.bbclass: Add yp.org and oe.org to fallback mirrors
This should improve the fetching errors users see
when upstream src_uri is unavailable

(From OE-Core rev: ca8a3422eb96ea431c322532dfd1be9980d4d48c)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:30 +00:00
Khem Raj
0c1386ccad uclibc: Upgrade recipes from 0.9.32 -> 0.9.33
Prefer 0.9.33 by default
Delete recipes for 0.9.32

(From OE-Core rev: 5d2c0b051072b3cee510dcad8d20fb26d3843f62)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:30 +00:00
Otavio Salvador
b9ff9682b3 dhcp: move dhcp leases files handling to postinst/postrm
Both server and client needs access to leases files so its creation
and removal are now handled by postinst/postrm scripts.

(From OE-Core rev: c8a9ae7c047051958b8667e77288c5ac295766c6)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:29 +00:00
Khem Raj
54fd9ad71b gcc-cross-testing: Fix evaluation of user and target name
Dont use -q to grep we pipe to /dev/null anyway all we
care is the return status of grep

(From OE-Core rev: 9c575b5f37ee53eaf26bfdc468d4cbb661db703f)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:29 +00:00
Khem Raj
d6b885b1b5 classes,recipes: Replace POKY_* with CORE_IMAGE_*
(From OE-Core rev: b14a92f4450bb08b9f11d3fd7a99155315527cdd)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:29 +00:00
Khem Raj
41936cd5bc pseudo: Wrap renameat and opendir
(From OE-Core rev: f6056cf0e7c76f2f3df650b088ce84df41ec14ca)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:28 +00:00
Saul Wold
bdc50cbfbb mtools-3.9.9: Use correct URI for the mirror
(From OE-Core rev: b4206046476dc6ff758bb45cf0c97ab2c57893b6)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:28 +00:00
Khem Raj
a50eeb884a libx11: Backport _XGetRequest API
This API is relatively new and will be in next release of libX11
this is needed for OE qemu-native which links to libx11-native
but uses libGL from build system and herein lies the problem
if you have bleeding edge distro e.g. ubuntu 12.04(development)
libGL.so expects this API to be present. Backported to 1.4.4
thusly

(From OE-Core rev: e08604800fe1cb8f240f53c147ceb4ee08a29b91)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:28 +00:00
Khem Raj
a4021674ed libdrm: Fix build failure unearthed by uclibc
uclibc wants to know value of __USE_GNU for certain
header prototypes to be enabled. So we move the config.h
header up in search list.

(From OE-Core rev: 086679cfbc30dba4af2f650984084195e5171b8f)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:28 +00:00
Khem Raj
fadd554603 python: Fix build failure of python-elementtree on x86_64
The problem is due to mixing of headers from host system
thusly corrected in setup.py by checkinng if we are cross
compiling

(From OE-Core rev: 25016d158af927e0c9e70c3df4674f53fa54fec8)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:28 +00:00
Khem Raj
7d9ac1db13 gconf,consolekit: Avoid polkit when compiling with uclibc
polkit uses netdb functionality from glibc which is not
available in uclibc therefore we avoid polkit when compiling
for uclibc systems.

(From OE-Core rev: 7eae02f47a08587cf5be3d39df0184cf346cbaea)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:28 +00:00
Khem Raj
fd2983e5fc runqemu-internal: qemuarm can handle 256M
Raise the check for max RAM supported for QEMU/arm
its 256M since we patched it to be so in OE

(From OE-Core rev: cfd84a05581e068d705b0804829c4833a06bffa6)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:27 +00:00
Khem Raj
a481c10d72 Enable options needed for ltp to compile
(From OE-Core rev: 22309029a9599b8f947c1fca664760123c325885)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:27 +00:00
Khem Raj
7215c25ec3 task-core-tools: Divide it into 3 recipes
task-core-tools-debug, task-core-tools-profile, task-core-tools-testapps
otherwise if we choose one through PACKAGE_GROUPS all packages
are built since they are in same recipe.

(From OE-Core rev: 180227d8ff71c42e0d16ad7eb4a5f9b7d6a0c1c6)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:27 +00:00
Bruce Ashfield
8df37ad549 linux-yocto: fri2: use emgd-1.10
Updating meta for the following change:

[
    fri2: use emgd-1.10

    Use the yocto/emgd-1.10 branch in place of yocto/emgd.
]

(From OE-Core rev: aa6293ffbc7f8f17e55f2105de56384e14591b44)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:27 +00:00
Bruce Ashfield
5d02d8dc17 kern-tools: remove explicit 'yocto' references from auto-bsp handling
To adapt to different branch names in a repository, removing explicit
references to 'yocto' in automatically created BSPs ensures that they
are consistent with the merged variants. Existing BSPs and auto BSPs
are not impacted by this change.

(From OE-Core rev: 74613d02aa844cac3be0626cc64139643fe17a4f)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:27 +00:00
Bruce Ashfield
a6065e7fc2 linux-yocto: rt compiliation fix
Updating the meta SRCREC to pickup the following changes:

  70e86dc meta/rt: update rt patch cache

Without this change a 3.0 based -rt build will fail to patch.

(From OE-Core rev: e5da5e84e64362f59a62f65b9f260f96af96bc11)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:26 +00:00
Bruce Ashfield
bb1e769cf1 linux-yocto: meta updates for sys940x and cleanup
Updating the meta SRCREV to pickup the following changes:

[
  Author: Darren Hart <dvhart@linux.intel.com>
  Date:   Wed Feb 1 09:37:48 2012 -0800

    Remove boot-live cfg duplication from BSPs

    Several BSPs duplicated the boot-live fragment in their BSP
    specific config. Remove the duplication and add CONFIG_RD_GZIP
    and CONFIG_BLK_DEV_SR to the boot-live fragment.

    (From OE-Core rev: a243dded5c84d48728308a769e527302b7539939)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
    Acked-by: Tom Zanussi <tzanussi@intel.com>

  Author: Darren Hart <dvhart@linux.intel.com>
  Date:   Tue Jan 31 13:18:17 2012 -0800

    meta: sys940x BSP meta data

    The Inforce SYS940x-ECX Developer-Ready Reference Platform features:
    o Intel Atom E6xx (0.6-1.6 GHz)
    o Up to 1GB on-board DDR2
    o Intel Platform Controller Hub EG20T
    o VGA,LVDS
    o HD Audio
    o SD Card
    o Dual SATA
    o Mini-PCIe

    http://www.inforcecomputing.com/SYS940X_ECX.html

    Signed-off-by: Darren Hart <dvhart@linux.intel.com>
    Acked-by: Tom Zanussi <tzanussi@intel.com>
    Signed-off-by: Darren Hart <dvhart@linux.intel.com>
]

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:26 +00:00
Bruce Ashfield
568bdc78f9 linux-yocto: locate and use out of tree features specified on the SRC_URI
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.

(From OE-Core rev: 3e2ce87566124db8c78472f9a4f00ab26410f213)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:26 +00:00
Khem Raj
44f0a2cfc5 xorg-apps: Bump PR to accomodate meta-oe recipe deletion
rgb in meta-oe has been removed in favour of
oe-core which requires a PR bump so feeds
keep working

(From OE-Core rev: 00c2e80e8cae2db6e2c34b1291c615f7f146b070)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:25 +00:00
Otavio Salvador
23c4961ace udev: stop providing cache support by default
The usefulness of cache nowadays has been reduced a lot and thus it's
better to stop using it by default. Dropping the recommends allows for
image to decide if they want or not to have cache enabled, instead of
require a machine override.

(From OE-Core rev: bf849b8a6da32cebaa361242162e4fcc4b1cd97f)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:25 +00:00
Wade Farnsworth
98a994acff systemtap: build and install uprobes.ko
SystemTap needs to provide uprobes.ko in order to support user space
probing.  Build and install the module on systems that support it.

Additionally, split off common bits into systemtap_git.inc.

(From OE-Core rev: 3cc4ba935444240b93abdc726342658ada803118)

Signed-off-by: Wade Farnsworth <wade_farnsworth@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:24 +00:00
Wade Farnsworth
c2c215b887 systemtap: extend the recipe to build the native package
Since the target image may not contain dev tools, it is useful to
provide native systemtap in order to be able to compile systemtap
scripts for the target.

(From OE-Core rev: 507bd29c5d1a3459e376e2d2c338b7e2a0afabaa)

Signed-off-by: Wade Farnsworth <wade_farnsworth@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:24 +00:00
Wade Farnsworth
3709697117 systemtap: bump SRCREV to grab version 1.7
Bump SRCREV to the latest stable version of systemtap.

(From OE-Core rev: ea57a29c75aa8265aecb8b0acd9c29340e98092c)

Signed-off-by: Wade Farnsworth <wade_farnsworth@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:24 +00:00
Chase Maupin
ce0740fbb5 u-boot inc: update inc file for newer u-boot versions
* Add support for different suffixes found with later u-boot
  versions which have switched from .bin to .img
* Allow recipes that include u-boot.inc to also package an
  SPL if they build one.
    * Minimum requirement is to set the SPL_BINARY value to add
      the SPL to the u-boot package as well as into the deploy
      directory.

(From OE-Core rev: 2965aa2faaccce43f6c3e451c0a2ded3734766e4)

Signed-off-by: Chase Maupin <Chase.Maupin@ti.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:24 +00:00
Mike Crowe
5a33401b84 libcap: Cope with ${libdir} and ${base_libdir} being the same
${libdir} and ${base_libdir} may be the same. If they are don't try and
move files onto themselves.

(From OE-Core rev: bf136334aecc156c73eed76562819351de368eec)

Signed-off-by: Mike Crowe <mac@mcrowe.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:24 +00:00
Mike Crowe
f2b55ac391 libusb-compat: Cope with ${libdir} and ${base_libdir} being the same
${libdir} and ${base_libdir} may be the same. If they are don't try and
move files onto themselves.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:23 +00:00
Mike Crowe
83dcff4042 libusb1: Cope with ${libdir} and ${base_libdir} being the same
${libdir} and ${base_libdir} may be the same. If they are don't try and
move files onto themselves.

(From OE-Core rev: 2ada7f7a0fa8a76a9ef7b45b0e0ced78757d9021)

Signed-off-by: Mike Crowe <mac@mcrowe.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:23 +00:00
Peter Tworek
e33f828d88 webkit-gtk: Make webgl support configurable via DISTRO_FEATURES.
* Add missing dependency on virtual/libgl.
* Make webgl configurable via DISTRO_FEATURES="opengl".
* Run tested on netbook pro.

(From OE-Core rev: 9500ef3f5fae07c1592e8208bb306c1148e49418)

Signed-off-by: Peter Tworek <tworaz666@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:23 +00:00
Peter Tworek
cc036d4c4e webkit-gtk: Fix error.html resource path.
(From OE-Core rev: cb0e0e3de421e2dd8335765adb3c0e442177bb9a)

Signed-off-by: Peter Tworek <tworaz666@gmail.com>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:23 +00:00
Saul Wold
c54070c0b1 openssl-0.9.8: Remove in favor or 1.0.0
Now that Openssl 1.0.0 has been out for a while, there is no need to
keep multiple versions.

(From OE-Core rev: 6017251a1de93ff3d509a040a220e30d0ee9cd5e)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:22 +00:00
Saul Wold
4825e2af65 gnupg-1.4.7: Update Patch Info
(From OE-Core rev: 50641a59bf10485f62d6d3669a2c1ded95cc48ed)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:22 +00:00
Peter Tworek
0e80bb7a26 busybox: Add flock utility to default configuration.
Flock is required by by pm-utils package to function properly
(/usr/lib/pm-utils/functions). It's shipped in both busybox and
util-linux. Both versions work fine with pm-utils. Enabling it
in busybox seems like simpliest solution for the problem.

(From OE-Core rev: a8ba002b5eb3c2e57550483d7b3ea99f0cc8a9cb)

Signed-off-by: Peter Tworek <tworaz666@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:22 +00:00
Darren Hart
67cfa74744 bootimg: Use the same OS files for each boot method
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.

(From OE-Core rev: 5209016cf4c4c8f649e37dc8857b3fbcfe8dd8c8)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:22 +00:00
Andreas Oberritter
50a097be16 tune-mips32.inc: Add mips32-nf and mips32el-nf
tune-mips32.inc only lists mips32 CPUs with hardware FPU.
Extend it to list CPUs without hardware FPU, too.

(From OE-Core rev: 26630a9f37b04e215eff9b8e63414b6b2066d6fa)

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-08 00:50:21 +00:00
Steve Sakoman
cb89d43473 libzypp: add missing runtime dependences on gzip and gnupg
gzip is required to uncompress repository files
gnupg is required for the support of signed repositories.

(From OE-Core rev: 18d9fcfc4bc4b01f73e89f3b988c9d3d543c7705)

Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 17:23:34 +00:00
Steve Sakoman
8fcfbaeb48 gnupg: add 2.0.18 (initial recipe)
GnuPG 2.0 is the new modularized version of GnuPG supporting OpenPGP and S/MIME

(From OE-Core rev: d99215fb1928e9996bb358b9f95d379d93b45377)

Signed-off-by: Steve Sakoman <steve@sakoman.com>
Acked-by: Paul Menzel <paulepanter@users.sourceforge.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 17:23:33 +00:00
Steve Sakoman
6034d1c512 libksba: add 1.2.0 (initial recipe)
Libksba provides an easy API to create and parse X.509 and CMS related objects
and is required for gnupg

(From OE-Core rev: fdee3a3e00d9677a71f3a4f4f4c4cbc4af3ab028)

Signed-off-by: Steve Sakoman <steve@sakoman.com>
Acked-by: Paul Menzel <paulepanter@users.sourceforge.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 17:23:33 +00:00
Steve Sakoman
3301dc44b2 shadow-securetty: allow root logins on usb serial gadget device
Existing tty list does not include ttyGS0, add it

(From OE-Core rev: 6ba9dc6460eb615e002e90ead0f4d5bc31856f22)

Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 17:22:12 +00:00
Bruce Ashfield
3b1ad76c87 classes/patch: optionally return non-patch sources
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.

(From OE-Core rev: 41e92923a0b2fe047ecaa9f9ffb564d6069f784f)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 17:22:12 +00:00
Ken Werner
4be9d82596 Add EXTERNAL_TOOLCHAIN to CMAKE_FIND_ROOT_PATH
This allows cmake to find the binaries of an external toolchain.

(From OE-Core rev: 7b355ad09a622cfe57c66674ed1affd61c4d872e)

Signed-off-by: Ken Werner <ken.werner@linaro.org>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 16:33:21 +00:00
Christopher Larson
a29939639b external-csl-toolchain: extract version info from the toolchain
(From OE-Core rev: ba59a35cd2b7a0cb5903146d991f5d7f535f4f19)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 16:17:16 +00:00
Christopher Larson
79e48d853b external-csl-toolchain: leverage eglibc's packaging for more granular output
(From OE-Core rev: 414a81a6f3e7caee4107889230a5e648f2791f75)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 16:17:16 +00:00
Christopher Larson
cbe0a0dd8a external-csl-toolchain: support ia32
Unfortunately, the CSL ia32 toolchain has non-prefixed binaries in its bindir
(e.g. gcc, ld). To avoid this messing up our build, we avoid adding this
bindir to our PATH, and instead add symlinks to the prefixed binaries to our
staging toolchain bindir.

(From OE-Core rev: c924d878b55cce7a0e98dc60acf706b5a1b4f404)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 16:17:16 +00:00
Christopher Larson
c0d7e9b062 external-csl-toolchain: support mips/ppc/arm
- Rather than adjusting TARGET_VENDOR, which results in our TARGET_SYS
  matching the external toolchain, override TARGET_PREFIX to match external,
  and leave TARGET_SYS alone
- Grab the optimized files out of the toolchain if available
- Create a symlink in sysroot to ensure the sysroot layout matches toolchain
  expectations (optimized files in a subdir)

(From OE-Core rev: a37298eb3421a44e88ec5a66b2fc5305ab18f453)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 16:17:16 +00:00
Christopher Larson
b942a8ee6a eglibc-package.inc: don't include debug files in -pic
(From OE-Core rev: 64eccd7aacbb7e31478482e0deec1a6a3a94c9ea)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 16:17:16 +00:00
Christopher Larson
34ba3b689e binutils: fixes for build with an external csl toolchain
(From OE-Core rev: 050eb9c82d8a2d04f2578c04a826b7762d737446)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 16:17:15 +00:00
Xiaofeng Yan
6cafc0011e LSB_Setup.sh: Add locale resources and startup script avahi-daemon
The purpose of adding locale resources is to resolve bug 1954 because missing locale resources
cause many failures.

The purpose of adding startup script avahi-daemon is to resolve bug 1907. The detailed description
is as follows:
No daemon progress "avahi-daemon" when system starting up.
Function "gethostbyaddr" will search file "/var/run/avahi-daemon/socket" but there is no
this file which is created by avahi-daemon.

[YOCTO #1907 #1954]

(From OE-Core rev: ce410852b7623379ad6961529e28f643e209749e)

Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:38 +00:00
Xiaofeng Yan
bb5704a4ee init-functions: Add two functions
Add log_begin_msg() and log_end_msg () in init-functions because some startup scripts need them.
if there are not two functions, then error information will arise on screen.
for example,
$ /etc/init.d/avahi-daemon start
/etc/init.d/avahi-daemon: line 161: log_begin_msg: command not found
/etc/init.d/avahi-daemon: line 163: log_end_msg: command not found

[YOCTO #1907]

(From OE-Core rev: 05682408ef7fca6029e48a18b2f660eeec65a4ec)

Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:38 +00:00
Nitin A Kamble
14e6b02ceb strace: add x32 support
This commits adds a patch to enable x32 support in the strace recipe.

(From OE-Core rev: 2042d52ff5425e864740b330adc27c2632cc5dc7)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:38 +00:00
Nitin A Kamble
e1be40cdd2 byacc: upgrade from 20111219 to 20120115
update md5sum for license as the copyright years are updated in the file

(From OE-Core rev: f763948c36ac078fe7412e647c7fc7936987eb43)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:38 +00:00
Nitin A Kamble
e87bbf1250 distro_tracking: update for current upgrades
(From OE-Core rev: 9542ddad873a12fa2c36f4781c42b07418ae30df)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:37 +00:00
Nitin A Kamble
85beca9f88 python-dbus: upgrade from 0.84.0 to 1.0.0
(From OE-Core rev: 1bf4df7aa343d74e7bcb136840d87924f30c3019)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:37 +00:00
Nitin A Kamble
f0262b7ab2 quilt: upgrade from 0.50 to 0.51
(From OE-Core rev: 956bb43cabac5c2245c4588464e8ee3e69e6d433)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:37 +00:00
Nitin A Kamble
a03c350074 gdb: upgrade from 7.3.1 to 7.4
(From OE-Core rev: c24bd38fdde69e30981efc1c0e81f8aa65555130)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:37 +00:00
Nitin A Kamble
f5d505e0cd gmp: upgrade from 5.0.2 to 5.0.3
rebased configure.patch & amd64.patchto the newer code.
Removed sh4-asmfix.patch as it is not needed with the newer code.

(From OE-Core rev: 7c33a18ed5cdca6765d04ad9e4387001f72993a4)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:36 +00:00
Saul Wold
0637f1b409 distro_track: Track Updates
openssl: Update to 1.0.0g
openssl: Update to 0.9.8t (gplv2)
gnutls: Update to 2.12.16
rxvt-unicode: Update to 9.15
gnupg: Add gplv2 version 1.4.7
file: Update to version 5.10
libidn: Update to 1.24
libdrm: Update to 2.4.30
xinit: Update to 1.3.2
xf86-input-keyboard: Update to 1.6.1
xf87-input-evdev: 2.6.0

Manual Checks:
util-linux - NO Update reason

(From OE-Core rev: cc3a6f625278d8ec9a61be1170823c3ec4302e61)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:36 +00:00
Saul Wold
6c988aa5f3 xf86-input-keyboard: Update to 1.6.1
(From OE-Core rev: 5960e647d18284fd42b4547dfeff3b1970b1d819)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:36 +00:00
Saul Wold
e7973af409 xinit: Update to 1.3.2
(From OE-Core rev: 1b3db3597c2b644e61394014886082eb212eef1a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:35 +00:00
Saul Wold
735371dcd2 libdrm: Update to 2.4.30
(From OE-Core rev: 4f9e5767b239335c47dbd57da6a21ce1f2bf686d)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:35 +00:00
Saul Wold
6e28930bdd libidn: Update to 1.24
(From OE-Core rev: ef2dcae84fe3a91f781ce906ea283d9f8d698af8)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:35 +00:00
Saul Wold
30049f0e7b file: Update to version 5.10
(From OE-Core rev: 260dd6a85d0f3fe64f7c4df5c4b99bb48b4e36ca)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:35 +00:00
Saul Wold
b1d4d3599f gnupg: Add gplv2 version 1.4.7
(From OE-Core rev: daff80c595616de10f32e74e2881e851707c7ff9)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:34 +00:00
Saul Wold
954a0bf236 rxvt-unicode: Update to 9.15
(From OE-Core rev: 75789868df9cfc5cb74edfc3fe7d773cfa272ce6)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:34 +00:00
Saul Wold
cba606f260 gnutls: Update to 2.12.16
(From OE-Core rev: 3439512952a64dc9537aa9842c64489219a76ee5)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:34 +00:00
Saul Wold
d54c972888 openssl: Update to 0.9.8t (gplv2)
(From OE-Core rev: d58903b22aa879484a5eaa01efad5c031ea485fa)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:33 +00:00
Saul Wold
e2d9ed9539 openssl: Update to 1.0.0g
(From OE-Core rev: 263c39e624d6c8681e716d26718ce7502de8ae6d)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:33 +00:00
Saul Wold
7b36125097 self-hosted-image: add package management for correct installation
(From OE-Core rev: 6ac8940f9d328afccd0176ae7c33053c3e565aca)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:32 +00:00
Saul Wold
31f34914db task-self-hosted: add python-pkgutil since it's required
(From OE-Core rev: fb5064de4d5d83b2f8b4d0aabea419f0681537f0)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:32 +00:00
Saul Wold
45228d39f3 task-self-hosted: add disk partitioning tools
(From OE-Core rev: 956d582f95f98690add05dc3f34fd520dedd8df0)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 15:56:32 +00:00
Richard Purdie
f7a1bd43e8 linux-yocto_3.2: Fix missing quote that was triggering parsing errors
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-03 11:26:30 +00:00
Tom Zanussi
a402d0e921 meta-yocto/local.conf.sample.extended: add LICENSE_FLAGS_WHITELIST section
Add a new section for LICENSE_FLAGS_WHITELIST, containing a list of
the current packages with LICENSE_FLAGS.

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 22:03:54 +00:00
Andreas Müller
15f09b1cfe atk: add native / disable introspection / merge atk.inc->recipe / change license
Native support currently is appended in meta-oe. Native build failed with:

| /usr/share/gir-1.0/GLib-2.0.gir:9:1: error: Unsupported version '1.1'
| /usr/share/gir-1.0/GLib-2.0.gir:9:39: error: Unsupported version '1.1'
| error parsing file Atk-1.0.gir: Failed to parse included gir GLib-2.0
| make[3]: *** [Atk-1.0.typelib] Error 1

build tested in meta-oe / angstrom environment

(From OE-Core rev: a69108ea388fce9034ecc8670f1149fabae55e1b)

Signed-off-by: Andreas Müller <schnitzeltony@googlemail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 18:37:36 +00:00
Peter Tworek
cd5225adfd gconf.bbclass: Add proper RDEPENDS to packages with gconf postinststep.
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.

(From OE-Core rev: 31997ae9188302f276241266590a1ae0f4316c3f)

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>
2012-02-02 18:28:27 +00:00
Joshua Lock
7bc766b9f8 distro_tracking_fields: take sysklogd off Saul's plate
(From OE-Core rev: 969661790df0e6f18617b8e867011dcc9504eb36)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 18:28:27 +00:00
Joshua Lock
5c3323b7e7 sysklogd: various fixes so it starts/stops cleanly
This patch fixes several issues with the sysklogd recipe:
o Errors at start due to non-existent /var/log/news/ - every other log
  file is created in /var/log, not a sub-directory. Do the same for news
  logs.
o klogd would not be stopped due to pidfile recycling, give klogd its own
  pidfile
o preinstalls failed at rootfs creation time by trying to access the host
  root filesystem rather than a path relative to $D. Update the preinst to
  test for $D and do the right thing.

(From OE-Core rev: 111d1b8bb2b89e06091335fff6a917bbd9a1f66e)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 18:28:27 +00:00
Joshua Lock
f408dd164e pciutils: fix configure script for dash
configure.patch was missing a closing quote in a sed expression which
causes script execution to error on less forgiving shells such as dash.

(From OE-Core rev: ad72484a2783afa948966263629006558fbde476)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 18:28:26 +00:00
Otavio Salvador
ac62f06e09 udev: improve udev-cache robustness
* allow udev-cache to be disabled at runtime (using
   /etc/default/udev-cache);

 * make cache invalidated if kernel, bootparams or device list
   changes;

(From OE-Core rev: 22b72b23653736436f10d394de36201c32630d5d)

Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 16:55:32 +00:00
Christopher Larson
7923ba87a2 external-csl-toolchain: avoid the hardcoded version/prefix
(From OE-Core rev: 4346516a6a719355d2793af289f93e14d3dedd0c)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 16:55:31 +00:00
Christopher Larson
ae21dc189f external-csl-toolchain: fixes for metadata changes
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

(From OE-Core rev: 8fb1c84f4cadf8d7a061fd6d90d270c19b474bfe)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 16:55:31 +00:00
Christopher Larson
aa2c4e3879 libc-package: fix typo in LOCALETREESRC default value
(From OE-Core rev: 73ff2f404392a6942ec89af15ec7f52fe2e629a6)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 16:55:31 +00:00
Christopher Larson
6028cd196e external-csl-toolchain: fix critical PATH manipulation bug
(From OE-Core rev: 9ccf5400d4d22f6fb90f5d61ad89dd0ac6273e43)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 16:55:30 +00:00
Shane Wang
a95445cf7b bitbake: Add description into the cache and clean up cache duplication
With the addition of new cache domains, the summary, license and section
information is no longer requred in the core cache since its only used by
the hob UI. This patch removes the duplicated entries.

It also adds the DESCRIPTION field to the cache for the benefit of hob2.

(Bitbake rev: 33ffb2e99825cb643b148b3462c2d4cf33ff5f58)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-02 16:55:28 +00:00
Koen Kooi
8d4d9a15c4 package bbclass: allow per package PRIVATE_LIBS
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.

(From OE-Core rev: ce46dbddef40ae3eef7238ac07438b15bd09e156)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:15:15 +00:00
Jessica Zhang
8ac227e4ac Fix the issue that adt-installer tar ball is not regenerated if sstate is on, and other minor bug fixes
(From OE-Core rev: 61da952fdc2996c27c56234c36116a69a23a378d)

Signed-off-by: Jessica Zhang <jessica.zhang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:15:15 +00:00
Scott Garman
58026ecc28 e2fsprogs: remove unneeded patch and re-enable PARALLEL_MAKE
Koen Kooi suggested that the quotefix patch was not needed,
and the build of the recipe should now be multithread-safe.
My testing has confirmed this.

(From OE-Core rev: 731700ec390d680ee4d277312755bea0ab4aeeec)

Signed-off-by: Scott Garman <sgarman@zenlinux.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:15:15 +00:00
Richard Purdie
76640582e8 pkgconfig: Ensure pkgconfig RDEPENDS are tracked
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.

(From OE-Core rev: 23e773eb8b70a5e36270b2e6415512b7dc4f1e05)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:15:14 +00:00
Saul Wold
ef328622c2 opkg-utils: convert to git repo at git.yoctoproject.org
The svn.openmoko.org site seems to have become unstable, make a copy
and convert to git at git.yoctoproject.org to preserve history

[YOCTO #1867]

(From OE-Core rev: b44717c29c4f50917570039adf896680d24bb216)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:15:14 +00:00
Darren Hart
2175842116 bootimg: Do not force FAT32 on all images, it violates the FAT specification
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.

(From OE-Core rev: 634137704dd1a205e377a1131ef708f1c981f6b2)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:15:14 +00:00
Bruce Ashfield
89b71a5062 meta-yocto/poky.conf: set qemu* preferred linux-yocto version to 3.2
With introduction of the 3.2 kernel repository, we can make the qemu
targets prefer this variant. Built and boot testing has been completed
on sato/minimal targets for all emulated targets.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2012-02-01 15:11:12 +00:00
Bruce Ashfield
6719d3e9e7 linux-yocto/meta-yocto: create linux-yocto 3.2 bbappend
Now that the 3.2 kernel has been introduced, we need a 3.2 bbappend for
the yocto hardware reference boards.

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2012-02-01 15:10:56 +00:00
Bruce Ashfield
1655fd11d3 linux-yocto/meta-yocto: update to v3.0.18 + features
Updateing the meta-yocto SRCREVs to the new 3.0.18 kernel.

The -stable team released v3.0.18, so it becomes the new base for the
linux-yocto_3.0 recipe.

Along with the 3.0.18 update this kernel refresh brings in the following
changes:

      59314a3 meta/beagleboard: Using CONFIG_PANEL_GENERIC_DPI=y
      b168325 crownbay: use emgd-1.10
      281b80f kver: bumping to v3.0.18
      0d5d0dd common-pc*: add SMP and virtio

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
2012-02-01 15:10:51 +00:00
Richard Purdie
64662290d3 fetch2/git: Add workaround for clone using alternates problem
To quote my report of this to the git mailing list:
"""

I have a problem with git clone commands using alternates failing by
mixing up different repositories. I have a situation where I could end
up with both:

/srv/mirrors/repo
/srv/mirrors/repo.git

as bare clones.

I then try cloning "repo" with alternates with the command:

$ git clone -s -n /srv/mirrors/repo /tmp/foo
Cloning into /tmp/foo...
done.

$ cat /tmp/foo/.git/objects/info/alternates
/srv/mirrors/repo.git/objects

Note how I'm now referencing repo.git, not repo. This doesn't work as
expected giving some very bizarre results when actually using the
repository.

I appreciate this is a rather bizarre corner case but its one that is
breaking the build system I work with. Ideally people would use a
consistent URL for the same repository but we have an example where they
haven't and this really shouldn't break like this.

Looking at the code, the cause seems to be

clone.c:get_repo_path():
        static char *suffix[] = { "/.git", ".git", "" };

since its looking in order for:
 repo/.git (fails)
 repo.git (suceeds, incorrect)
 repo (never looked at)

I'm not sure what would break if that order were to change, swapping the
last two options.

I can "force" the issue by running:

git clone -s -n /srv/mirrors/repo/ /tmp/foo

but this results in the slightly odd looking:

$ cat /tmp/foo/.git/objects/info/alternates

/srv/mirrors/repo//objects

which does at least work.
"""

This patch adds the trailing slash to ensure the correct repository is
referenced at the expense of some ugliness in the alternates file.

(Bitbake rev: d978e7b35550e3785c7c567ffe4c40a3c3947450)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:43 +00:00
Christopher Larson
38daf8b7eb cooker: add missing shutdowns to the exception handling
(Bitbake rev: c9f58ef6b897d3fa5b0d23734b5f2cb3dabb057a)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:42 +00:00
Lianhao Lu
555262744d prserv: Do not ping PRService if not required
[YOCTO #1942]
Ping the PRService only if PRSERV_HOST and PRSERV_PORT are set.

(Bitbake rev: 20f24de0bdafac21f5d8a58701f977efa7041288)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:42 +00:00
Paul Eggleton
90e99a5cae bitbake-layers: list overlayed classes in show-overlayed
Classes (.bbclass files) can be overlayed in a layer although they are
currently located by BitBake in a different way (via BBPATH instead of
using layer priority) and thus it is useful to be able to see when this
is in effect and which layer's class is actually being used.

(Bitbake rev: f6493e4bad005a82580380d800ebf4c438292f5b)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:42 +00:00
Paul Eggleton
86a5fcd2c6 bitbake-layers: add show-recipes subcommand
Add a show-recipes subcommand which lists all available recipes, with
the layer they are provided by. You can optionally filter the output by
recipe name (PN).

(This is a generalised version of the show-overlayed subcommand.)

(Bitbake rev: 05e86ba966f5a26721891c82b21afa48768a67cc)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:42 +00:00
Paul Eggleton
526264e7d7 bitbake-layers: improve show-overlayed output
Make the following improvements to the show-overlayed subcommand:

* Show recipes that are overlayed when the version is higher or lower,
  not just when it is the same. This gives a much better picture of the
  influence each layer is having over the metadata used for building.
  This can be disabled with the -s option if you just want to see
  recipes with the same version as before.
* Default to showing name (PN), layer and version rather than the full
  path and filename. The old style formatting can be used by specifying
  the -f option.
* Mark skipped recipes as such in the output, and print them in the
  correct sorted place in the list rather than at the end
* Prefix/suffix title line with === so it can be filtered out easily in
  shell scripts if desired

(Bitbake rev: 43b473275d3cb2e60a14e4a52cdc4654b3f4e5e7)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:41 +00:00
Paul Eggleton
3d2f6d5610 bitbake-layers: use directory name as layer name
It turns out that using the collection name as specified within
layer.conf (i.e. what gets added to BBFILE_COLLECTIONS) as a name to
refer to the layer is not particularly useful, since layer creators
aren't necessarily setting these to a meaningful value - e.g. OE-Core
uses "normal", meta-oe uses "openembedded-layer", etc. In any case,
BitBake uses the directory name in its list of configured layers in the
system information presented upon starting a build, so let's just do the
same here and avoid confusion.

Also rename the get_append_layer function to get_file_layer since it is
in no way specific to bbappends.

(Bitbake rev: 35d2c1c618826e961dbf4b9889b829f469346d74)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:41 +00:00
Paul Eggleton
cf425a13a2 bitbake-layers: use dashes in subcommands
Rather than the slightly awkward underscores, use dashes in subcommands
e.g. show-layers instead of show_layers. (The old underscored forms
continue to be accepted however.)

(Bitbake rev: 6d311ddc1be04ae5bd0a1ebee94b44968e8a3f27)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:08:41 +00:00
Martin Jansa
936aca72c9 rootfs_ipk: remove runtime_script_required usage
* 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

(From OE-Core rev: 6d3eac57bdba8e2582c210a2f82a3a4546f68581)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:44 +00:00
Saul Wold
22181a759d gcc-runtime: fix override from poky-lsb to linuxstdbase
(From OE-Core rev: 1f5de4b36ad5853e489e47078c830f12a1c71ce9)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:44 +00:00
Saul Wold
0de413782e default-providers: add kbd as PREFERRED_PROVIDER for console-tools
kbd is used a primary provider for console-tools

(From OE-Core rev: 9a88125c546e6bcbec683eb736e232236c38a4f9)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:44 +00:00
Khem Raj
dc153672aa gdb-common: Drop elfutils from DEPENDS
(From OE-Core rev: 8330205eeb605354c139605618255940e3b312d4)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:43 +00:00
Bruce Ashfield
a092311949 linux-yocto: update to v3.0.18 + features
The -stable team released v3.0.18, so it becomes the new base for the
linux-yocto_3.0 recipe.

Along with the 3.0.18 update this kernel refresh brings in the following
changes:

  59314a3 meta/beagleboard: Using CONFIG_PANEL_GENERIC_DPI=y
  b168325 crownbay: use emgd-1.10
  281b80f kver: bumping to v3.0.18
  0d5d0dd common-pc*: add SMP and virtio

(From OE-Core rev: b58d330a88a64ac8ff82362cc90cc817f38b82cd)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:43 +00:00
Bruce Ashfield
e670fdc7ae linux-yocto: add kernel 3.2.2 support
Adding initial support for the linux 3.2 kernel.

Although the branching and naming has changed slightly, the same BSPs and
features exist in this tree as have existed in previous linux-yocto versions.

Notable features of this update are:

  - streamlined branch naming
  - configuration and functionality split in the standard kernel
  - creation of the 'tiny' kernel type branch
  - audited kernel configurations with optional features documented
    in the meta branch
  - feature and BSP refreshes
  - 3.2-rt support refresh
  - qemu ppc graphics support

Build and boot testing has been performed on all emulated targets
(sato and core).

(From OE-Core rev: 72264df07d7e57ba8232aae90b76ab220fdb2d22)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:43 +00:00
Bruce Ashfield
278e53ca6b kern-tools: import config audit and branch manipulation updates
Updating the kern-tools SRCREV to import the following changes:

 a7a9930 kgit-meta/scc: allow multi-line defines
 e3442c6 kern-tools: add required and optional kernel configuration processing
 b56b67b configme: extract redefinition and mismatch information
 6118eaf kern-tools: remove branchname assumptions

These are required to support the kernel configuration policy changes
implemented in the yocto 3.2 kernel repository.

(From OE-Core rev: 5a3759f4b23361dd2c1968ce51e5c3695a661972)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:43 +00:00
Andrea Adami
0d1dee2a56 tzdata_2011n: provide pkg_postinst and timezone defaults
* Introduce DEFAULT_TIMEZONE variable ('Universal', present in base package)
* and add /etc/timezone during do_install.
* While there, fix hardcoded references to $exec_prefix (/usr).
* Add the pkg_postinst script (adapted from Gentoo).
* Create /etc/localtime during postinst.
* Bump PR

(From OE-Core rev: 5304ce429f2c05857f04fbe3b47a067983ca96be)

Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:43 +00:00
Koen Kooi
ae3184c96e classes: replace 'Poky' with 'OE-core'
(From OE-Core rev: 1fdcd32520a05465b0d54c062f28bac9cdf74a20)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:42 +00:00
Koen Kooi
2805ff120e alsa-utils: make alsa-utils-alsactl recommend alsa-states
This will drag in the asound.state from the BSP that alsactl uses.

(From OE-Core rev: 6a1c75971d35b6a8272741a4f3e25ef46f7ce305)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:42 +00:00
Koen Kooi
a26a2cba60 alsa-state: fix RDEPENDS assignment
(From OE-Core rev: 358ad279d525ca3c806cbb6ceadb2d6170468d80)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:42 +00:00
Eric Bénard
37d93b9818 qt4-tools-nativesdk-4.8.0: fix build
the build is actually failing because host g++ and ld are used to
compile and link

(From OE-Core rev: 4ccae37db1aa77a1d15098c3720ea6e2d383fbdc)

Signed-off-by: Eric Bénard <eric@eukrea.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:42 +00:00
Saul Wold
9123e9eb9b genext2fs: fix inode computation
This patch fixes a problem with the computation of inodes
based on the bytes_per_inode options, for a larger FS (> 2G)
the inode count would go negative and a smaller default
count would be used, this would cause the FS to run out of
inodes.

(From OE-Core rev: df5e886be059da35fb69710c79227cc768f1c58e)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:41 +00:00
Andrea Adami
84e24f0f00 image_types.bbclass: refactor cpio images generation.
* 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).

(From OE-Core rev: ab282056148f3152f96b6990e09270ae5405da9d)

Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-02-01 15:07:41 +00:00
Richard Purdie
636d7e308f useradd.bbclass: Fix missing quote
(From OE-Core rev: d7b13cd42ab8d5f44f97e119b73ec2e363677d26)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 23:57:46 +00:00
Richard Purdie
b719d7e10b useradd: Ensure dependencies are only added for target recipes, not native or nativesdk
(From OE-Core rev: 63d006b2d3fc2223c74f81b91f70f5c841108c80)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 16:59:56 +00:00
Shane Wang
df823d5958 distro_tracking_fields: fix the typos in the field of maintainer.
(From OE-Core rev: fba0459da7f274ae284d36b7fdbf2f9d10a52610)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:52:08 +00:00
Koen Kooi
973f93c031 libtool 2.4.2: fix missing quote in FILES_libtldtl
The missing quote prohibits OE from packaging it correctly, leading to:

|  * satisfy_dependencies_for: Cannot satisfy the following dependencies for task-gnome:
|  *    libltdl7 (>= 2.4.2) *   libltdl7 (>= 2.4.2) *   libltdl7 (>= 2.4.2) *   libltdl7 (>= 2.4.2) *   libltdl7 (>= 2.4.2) *   libltdl7 (>= 2.4.2) *   libltdl7 (>= 2.4.2) *

for incremental builds and binary feeds.

(From OE-Core rev: ed6968b731e8ebc161fa59e18a9284bddf86c61b)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:47:52 +00:00
Richard Purdie
75fcfde061 useradd.bbclass: Add explict setscene dependencies to ensure correct ordering of setscene tasks
(From OE-Core rev: ffc7bbcf0011de3f1f6e8d95f1de0b8f7164fa51)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:42:48 +00:00
Richard Purdie
3b47c5310a useradd.bbclass: Ensure pseudo can load in the pseudo unloaded case
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.

(From OE-Core rev: 76345cd61c9523ce6755ef8e923dec37800b7a98)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:40:07 +00:00
Richard Purdie
0a3a15c8dd useradd.bbclass: Execute user addition code before do_package_setscene, not 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.

(From OE-Core rev: 34282c1b996ef008384af456735692d66ddabc13)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:40:07 +00:00
Richard Purdie
9a58e312ef sstate.bbclass: Add support for sstate preinst functions
(From OE-Core rev: f2b0a71b3100a0d2ceb80300d7f3823a31eb907a)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:40:07 +00:00
Richard Purdie
de7a6ab1ba runqueue.py: Add inter setscene task dependency handling
This is being added to resolve setscene race issues where we do have
particular dependencies required between setscene tasks. This allows
specific dependencies to be specified. This allows us to fix the races
in sstate with the useradd class in OE-Core.

Any tasks being depended upon have their reverse dependencies cleared to
ensure we don't have circular references.

(Bitbake rev: e1b157d26374a70e6274edcb4c0b9f3bc48f765c)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:40:06 +00:00
Richard Purdie
9aeb38a5b8 runqueue.py: Fix missing setscene dependencies
When constructing the setscene inter-dependencies, we need to account for all task,
not just the last one found. This patch corrects this oversight and ensures all
dependencies are added, not just the first one found.

(Bitbake rev: b9b5b5129d066e1ff7d3effda116afc3c6657beb)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:40:05 +00:00
Richard Purdie
2a361cdb39 data/runqueue.py: Fix commented out test code after variable name changes
(Bitbake rev: 175c5c8a5e51365aa127562e8598e84f5cd36495)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-27 09:40:05 +00:00
Richard Purdie
238a47d800 shadow-sysroot: Simplfy login.defs installation
Currently if shadow-sysroot is installed from a sstate package,
shadow_sysroot_sstate_postinst is looking in ${D} for login.defs which
isn't a valid for an install from sstate.

The easiest and most correct way to fix this is to override the standard
sysroot_stage_all function to install the files correctly and then
sstate installs work as expected. This simplifies the code as an added
bonus.

(From OE-Core rev: 6437e7315a0f2e077f9d69e4b65b48280ea8edbc)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-26 20:53:16 +00:00
Saul Wold
f54a443aa7 libgcc: Add INSANE_SKIP of staticdev for libgcc-dev and libgcov-dev
Skip the staticdev QA test since the static archives belong
with the -dev.

(From OE-Core rev: 3de810a7f745b253d4b63eea353a31514d64a2e3)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-26 20:48:02 +00:00
Saul Wold
7aa33dba3b insane.bbclass: Add test for static .a libraries in non-staticdev packages
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]

(From OE-Core rev: 4f31eb53fb0b1bfdf8be05356e57df607a6e82a9)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-26 20:48:01 +00:00
Marc Ferland
cd7da08486 pm-utils: Add grep to RDEPENDS to avoid command failures.
Second version of the patch that adds grep to RDEPENDS.

Fixes [YOCTO #1887]

(From OE-Core rev: 6d4ff87b935d61aae63260262c0f48fe7e9d2a48)

Signed-off-by: Marc Ferland <ferlandm@sonatest.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-26 20:48:01 +00:00
Joshua Lock
494a500032 linux-tools: don't build perf when GPLv3 in INCOMPATIBLE_LICENSE
As binutils is required by perf to build and is GPLv3 licensed adding
GPLv3 to INCOMPATIBLE_LICENSE will cause linux-yocto to be skipped.

Long term we should look at moving perf to a separate recipe but as a
short term solution this patch will ensure that when GPLv3 is in
INCOMPATIBLE_LICENSE perf is not built and it's dependencies are not
added to build.

Fixes [YOCTO #1879]

(From OE-Core rev: ce61f9031b54067bffa304dab90c31278631dcdf)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-26 20:48:01 +00:00
Khem Raj
3a9e5682a9 uclibc-git: Update to latest RC
Document the patches

(From OE-Core rev: 746e8ffa66850bf9050cd6baf94eb76c492eb535)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:09 +00:00
Khem Raj
e60acb7e0b eglibc-2.15: Add upstream status for x86_fenv.patch
(From OE-Core rev: 64a8f93cb6a7cd86f966b8f53227246deebce3a0)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:09 +00:00
Khem Raj
5ff048d979 uclibc: Dont package all .a in uclibc-dev
only *_nonshared.a are to be packaged in uclibc-dev
rest can go into uclibc-staticdev

(From OE-Core rev: aa799ba49833bdf6acbcd4b34f0605050c938175)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:09 +00:00
Khem Raj
609f637ff0 util-linux: Change SRC_URI to a fetchable location
(From OE-Core rev: 140ca6f3e690f34940fd60809f2d03fabb27105d)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:09 +00:00
Khem Raj
d8aada2b9a ltp: Update recipe and fix building on uclibc
(From OE-Core rev: 4e8644584aa8826e9cbf9ff0dc23b8c395978013)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:09 +00:00
Joshua Lock
8549ebb873 distro-tracking-fields: update entries for clutter-gst-1.8
(From OE-Core rev: 5801f480b74465696389783dc651ec48ff42e715)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:08 +00:00
Joshua Lock
6882a60b18 clutter-gst: update to 1.4.6
(From OE-Core rev: a440654076008a107fff2245eff7791a4abf5abf)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:08 +00:00
Joshua Lock
0d7dfedca4 cogl: update upstream status for build_for_armv4t.patch
This has patch has been merged into upstreams git repository and will be
available in the next stable release.

(From OE-Core rev: 77f5e99a821ad30b859a402bdc55c495741b24cc)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:34:08 +00:00
Richard Purdie
0287f645f1 gcc-cross: Don't reference machine specific variables
gcc-cross is installed into a package architecture specific directory
and is not meant to be machine specific. This patch replaces MACHINE_ARCH
with PACKAGE_ARCH to ensure this is really the case.

This was found by examining sstate checksums.

(From OE-Core rev: b3ca57418f47b16ed0a63d3291bf7d31e3ca5a45)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:30:57 +00:00
Darren Hart
8f55130e6f bootimg: Fix a math thinko in the block count calculation
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>
(From OE-Core rev: b35384fa3ca96b31c63d764322215abced2066e4)

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>
2012-01-25 14:30:56 +00:00
Richard Purdie
0bf6f8035c lib/oe/sstatesig.py: Exclude common machine specific dependencies from task signatures
Where we have machine specific recipes with well defined behaviour, it makes
no sense to rebuild recipes with these as dependencies whenever the machine
changes. This patch lists those well behaved recipes and excludes them from
the task signatures so we can change MACHINE without invalidating existing
PACKAGE_ARCH binaries.

(From OE-Core rev: 07e34778fc74126af1380bf249fd34a5e3df12c2)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:30:56 +00:00
Richard Purdie
7c8899662b shadow: Split securetty into a separate recipe
The securetty file is machine specific whilst the rest of the shadow recipe
is not. Unfortunately making the recipce machine specific is both inefficient
and also causes dependency problems since parts of the system such as the useradd
code depend upon it and this introduces a machine specific element to sstate
checksums which should not be machine specific.

To resolve this, this patch separates out the file into a separate recipe
meaning the machine specific components are isolated.

(From OE-Core rev: 318133b5202632c6957c2aade22b1ef7af929f23)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-25 14:30:56 +00:00
Richard Purdie
6b2cb82802 gcc-common.inc: Fix comment
(From OE-Core rev: a4a98b6d6273d4e716afbff0880d0ac2ff7be0a9)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 14:38:39 +00:00
Richard Purdie
ef3c1dd356 gcc-common.inc: Ensure WORKDIR doesn't adversly affect sstate checksums
Changes in WORKDIR were changing the do_patch stamps between gcc-crosssdk
and gcc-cross. This excludes the variable since in this case, we don't
need want those changes to affect the signatures.

(From OE-Core rev: 0de85d2ca3bc9674323302a35995dfddb6044a71)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 12:19:01 +00:00
Nitin A Kamble
f13ee1e877 guile: fix a quote in description
(From OE-Core rev: 29118b57c7804a237e0c8fef41fcf032476bfb10)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:26 +00:00
Nitin A Kamble
5c6aa87a91 ltp: disable elf binary stripping
Otherwise the ltp tests ldd01 & nm01 fail due to missing stripped
information.

This Fixes these bugs:
[YOCTO #1922]
[YOCTO #1923]

(From OE-Core rev: 075266fa8bf12719c58a21c75a35fede5608dcdf)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:26 +00:00
Shane Wang
19561311a3 distro_tracking.inc: update the info for recipes upgraded recently
This patch is to update the information for the recipes upgraded recently, including strace, pciutils, ed, ofono, iproute2, bluez4, bluez-hcidump, kexec-tools, tremor, iptables, polkit, libxcb, xcb-proto, pixman and util-macros.

And add the new recipe for mobile-broadband-provider-info, which is depended on by ofono v1.3.

(From OE-Core rev: 10b255bd881e6f63c7eb7140aa798fcb2093db89)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:25 +00:00
Shane Wang
803850a0ee libsoup: update its info in distro_tracking.inc
(From OE-Core rev: 01ed085b6b2be063ee9249f3ad3f3c03bd19490b)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:25 +00:00
Shane Wang
87b3c3f813 strace: upgrade to 4.6
(From OE-Core rev: 2b81cf3d76241572c299a0a58a3d0ca022bef9a0)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:25 +00:00
Shane Wang
27aec8bef6 pciutils: upgrade to 3.1.9
(From OE-Core rev: 745bdcd3421747b050493079101f6f5ba7830daf)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:25 +00:00
Shane Wang
be76d89496 ed: upgrade to 1.6
This patch is to upgrade ed to 1.6, and the change of license checksum is because

the diff between two ed.h files:

3c3,4
<     Copyright (C) 1993, 1994, 2006, 2007, 2008, 2009, 2010

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:24 +00:00
Shane Wang
07b940b752 ofono: upgrade to 1.3
This patch is to upgrade ofono to 1.3 and the v1.3 ofono depends on mobile-broadband-provider-info.

(From OE-Core rev: d691b150d1222a23422658d6dc4b72a3307bc77f)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:24 +00:00
Shane Wang
d6dcd8de12 mobile-broadband-provider-info: bring a new recipe into poky
This patch is to bring a new recipe mobile-broadband-provider-info into poky because the latest version ofono v1.3 depends on it.

And the patch is imported from the OpenEmbedded server (http://git.openembedded.org/openembedded/tree/recipes/mobile-broadband-provider-info) as of commit ids

commit 9d612c4bb9bef813bdef9e198efc5949d51905eb
commit 84bf98dc6876ef6be8a4ee3744924e922253b53e
commit 30a913149de95ecafe4ef87bd50cfdbd6737fe1e
commit 7d2be53866d317bb032c63548f504f63107b4c2c

And upgrade to the latest.

(From OE-Core rev: 851299c8dd2bf8012078a2c78f79dc1b9fdc3323)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:24 +00:00
Shane Wang
d6a55ca79c iproute2: upgrade to 3.2.0
This patch is to upgrade iproute2 to tag 3.2.0.
And the tag is not fully testd by the upstream and has build error.
We use the next commit of tag 3.2.0 which fixs the error.

(From OE-Core rev: f2a7b225b5a243e0a364be678a71bdc3b0fa99e0)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:24 +00:00
Shane Wang
e96ec29709 bluez4: upgrade to 4.98
(From OE-Core rev: 8d3188a4a69214f23d8b7f8d972bdd35f574196b)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:23 +00:00
Shane Wang
a3c6899639 bluez-hcidump: upgrade to 2.2
(From OE-Core rev: cfa2e9ef3f52f8956d05c2b12ca9984fc08ef238)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:23 +00:00
Shane Wang
1483a6c5d7 kexec-tools: upgrade to 2.0.3
This patch is to upgrade kexec-tools to 2.0.3.
And since fix_for_compiling_with_gcc-4.6.0.patch is there in 2.0.3, it is removed.

(From OE-Core rev: aea75907ff0ad11b7a17910f74491278e55bbc10)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:23 +00:00
Shane Wang
e36a3c16d5 tremor: upgrade to 18163 (20120122)
(From OE-Core rev: 67ae9bbbab31b69f37e3ee0c1c969e43da034699)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:23 +00:00
Shane Wang
d70f34fddd iptables: upgrade to 1.4.12.2
This patch is to upgrade iptables to 1.4.12.2, and introduce a patch not to check unknown symbols.
Otherwise, when it is compiled, it will report "libxtables.so.7" from LD_PRELOAD cannot be preloaded.

(From OE-Core rev: 27ed7024cf2ee9c9f84246fd931bc390cb638851)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:22 +00:00
Shane Wang
71dbcbcdcb polkit: upgrade to 0.104
Upgrade polkit to 0.104.
And fix the typo for "endline" and the checksum.

(From OE-Core rev: a04c89e4e2a5f98716001ba9e5e25b21323f4606)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:22 +00:00
Shane Wang
35200aa6b9 libxcb: upgrade to 1.8
(From OE-Core rev: d10c9e9a5f83bdd744a8e5ac6bed504404c92ecf)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:22 +00:00
Shane Wang
ab315a3b68 xcb-proto: upgrade to 1.7
Upgrade xcb-proto from 1.6 to 1.7
Since xcb-proto-libdir.patch is there, the file is removed.

(From OE-Core rev: 15780c7d7bb5d242aa688c1c1d9842a1004222d9)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:22 +00:00
Shane Wang
12e10a653a pixman: upgrade to 0.24.2
(From OE-Core rev: 897828ae798ac84d1a0a1a929ddb62807f5fb3f4)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:21 +00:00
Shane Wang
80b9d5125d util-macros: upgrade to 1.16.1
(From OE-Core rev: cae171c3017af47896df4752992fefe2161211d4)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:21 +00:00
Saul Wold
eccece9553 gcc: move shared .a to their own package
Keep the *_nonshared.a in the libgcc-dev package as
required for linking, moved the other *.a libraries
into their respective packages (libstdc++ and libssp).

(From OE-Core rev: c2838d949ffd15282c72551b40c5fd81d0db1fa0)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:21 +00:00
Saul Wold
307fcba065 libgcc: Seperate out libgcov.a from libgcc-dev
libgcov.a is moved to it's own libgcov-dev package, instead
of being part of libgcc-dev.

(From OE-Core rev: a82a3f8ec55e68a003420549392d638e565562fc)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:21 +00:00
Saul Wold
b227700cac binutils: refactor packages for staticdev
(From OE-Core rev: 42b2996a58635483aa111ba4c61f71740d8294f5)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:20 +00:00
Saul Wold
7843f8ec97 eglibc: refactor packages for staticdev
(From OE-Core rev: bdf64c5e7ca2268b095405208407f95e1ba41488)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:20 +00:00
Saul Wold
70b6b6bdf4 opkg: refactor packages for staticdev
(From OE-Core rev: 01bc511d772a47e34b2071393651a915c8ddb1b0)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:20 +00:00
Saul Wold
930424bf2f opkg: move common code & metadata into opkg.inc to reduce code duplication
(From OE-Core rev: da70cc9f33845d62943afc78168e56931d0a9b15)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:20 +00:00
Saul Wold
c6c3f87450 tcp-wrappers: refactor packages for staticdev
(From OE-Core rev: 391bc0715ee7fb3391f0719b2515fcf0bee9c4ad)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:20 +00:00
Saul Wold
a64c2a90ad syslinux: refactor packages for staticdev
(From OE-Core rev: 256b610b0ba679a14d0348db95ef8bce21ddc8a0)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:20 +00:00
Saul Wold
662666046c libtool: refactor packages for staticdev
(From OE-Core rev: 63bfddf162cea836748e56da1488de56758d0418)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:19 +00:00
Saul Wold
9ed7ac6ffa gstreamer: refactor packages for staticdev
(From OE-Core rev: 66c348403d2289ad9a4d95ee3f3aaf8088593e82)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:19 +00:00
Saul Wold
14953b7c51 tiff: refactor packages for staticdev
(From OE-Core rev: 93135c19b9574d952aaf8a4b97425640b847847a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:19 +00:00
Saul Wold
50a073fe04 mpeg2dec: refactor packages for staticdev
(From OE-Core rev: 6d59ffeb45062b46fbfecf898f76183d73798331)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:19 +00:00
Saul Wold
ed08326255 apr-util: refactor packages for staticdev
(From OE-Core rev: 40aeac840516f33f57134ac25fb046f6d2e43534)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:18 +00:00
Saul Wold
a15f44464e sqlite3: refactor packages for staticdev
(From OE-Core rev: 6c642cf6b8aadfa3d1e9299c135f9cfc6abdd162)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:18 +00:00
Saul Wold
8d54a0de69 libxft: refactor packages for staticdev
(From OE-Core rev: 165bac5be2555727ae475a4fbcc02c53712578da)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:18 +00:00
Saul Wold
f514242c8d sysfsutils: refactor packages for staticdev
(From OE-Core rev: 216333723b126a7e727b01e7074900e5bb339440)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:18 +00:00
Saul Wold
3507c03f16 libsoup: refactor packages for staticdev
(From OE-Core rev: 5a44b3aa50bb4bff652af5e6835a6707bba1104a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:18 +00:00
Saul Wold
3346afefa3 augeas: refactor packages for staticdev
(From OE-Core rev: 4c1a1eb9a646dfebeb031a29baba1055065a0148)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:17 +00:00
Saul Wold
d74c85201e avahi-ui: refactor packages for staticdev
(From OE-Core rev: abdbf82de718468da3963cae2b9717b72480d66a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:17 +00:00
Saul Wold
bb52d385c6 apmd: refactor packages for staticdev
(From OE-Core rev: 0f32aea7b133743020f5f91ff7d2d595ad1c5f86)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:17 +00:00
Saul Wold
ca848609cb Fix Upstream-Status entries
(From OE-Core rev: 0cd9314ef95168ba5452a01ed8d923585c8d54ae)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:16 +00:00
Tom Zanussi
79af7541e2 documentation-audit.sh: remove COMMERCIAL_LICENSE warning
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.

(From OE-Core rev: 64e1db588bcb7b66b08097c0ea443bd4406422d3)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:16 +00:00
Tom Zanussi
7301b4c187 default-distrovars.inc: remove COMMERCIAL_LICENSE et al
The global COMMERCIAL_LICENSE mechanism has been obsoleted by
per-recipe LICENSE_FLAGS, so remove the related variables.

(From OE-Core rev: a66fdbda548fab367cada035c49a32d9bf8ea528)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:16 +00:00
Tom Zanussi
2896b4a1c4 base.bbclass: replace COMMERCIAL_LICENSE code with LICENSE_FLAGS code
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.

(From OE-Core rev: 3735716996ec11691054d7f03db873afde89b143)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:15 +00:00
Tom Zanussi
7b81ef8d95 Add LICENSE_FLAGS to packages mentioned in COMMERCIAL_LICENSE
Per-recipe LICENSE_FLAGS replace the global COMMERCIAL_LICENSE list;
add LICENSE_FLAGS varables to each the recipes mentioned in that list:

     - lame
     - gst-fluendo-mp3
     - gst-openmax
     - gst-plugins-ugly
     - libmad
     - libomxil
     - mpeg2dec
     - qmmp

(From OE-Core rev: 43410523a07d9eb52a7d57ae3dc1cc320cbbc6f9)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:15 +00:00
Tom Zanussi
b68ea54360 license.bbclass: add support for LICENSE_FLAGS
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".

(From OE-Core rev: a2760661b8c7a4a1b6f2e556853b3a9ae38cbcb5)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:15 +00:00
Shane Wang
127d1fd1c2 core-image-foo: add description to each image bb file
Add DESCRIPTION to each image bb file according to poky reference manual for Hob2 use later.

(From OE-Core rev: 05a7c022e613f35de8ce47bb667140a7ce47fcea)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:54:15 +00:00
Martin Jansa
6b2b5d2acd initscripts: remove space from shebang, just cosmetics
* at least in initscripts it's consistent now

(From OE-Core rev: 20d5effcf192d469883b5ac899cbd2340b71bd2c)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:05:30 +00:00
Martin Jansa
c6a2c300d1 initscripts: add shebang where it was missing completely
(From OE-Core rev: d58fc7a3ccede8706bf6a6aa7f7301f716128db8)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:05:29 +00:00
Saul Wold
d4a942fb51 qemuimage-testlib: rename qemuppc image
A recent set of changes changed the kernel name from bzImage to vmlinux,
this test needs to change also.

(From OE-Core rev: f11f03b27bd0bf41bcb45d0589d9982d006474d2)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 11:00:35 +00:00
Bruce Ashfield
21b3f5ddb1 linux-yocto/qemuppc: fix console and ethernet
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.

(From OE-Core rev: 29c71eeb98aa8ce0fb0e0a30483499525bf6305d)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 10:20:10 +00:00
Richard Purdie
c47def3b04 gcc_4.6.bb: Drop duplicated SRC_URI component
This was duplicated from the main SRC_URI and was causing incorrect
task signatures. This simply removes the duplication.

(From OE-Core rev: cc8d02c582a72d07fd08c59d14ee5720e01a5cd9)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-24 10:20:09 +00:00
Richard Purdie
4ad01bdf3f gcc-package-cross.inc: Mark do_package* tasks as noexec
These tasks don't do anything, this just avoids the overhead of forking
to exec them.

(From OE-Core rev: 6708b3e908ae383922703390ac2d39f40348e1b3)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-23 09:01:39 +00:00
Richard Purdie
a7b32bd9ef bitbake.conf: Switch to the OEBasic signature generator
This signature generator will allow easier customisation of which task
dependencies get included in the signatures using the code in
lib/oe/sstatesig.py. Compared the the regexp, this function is much
easier to understand and customise.

(From OE-Core rev: 2654adc15e59e72e80cf78dc576fdc5472edac20)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-23 09:01:39 +00:00
Richard Purdie
85cf3ed593 lib/oe: Add sstatesig, OE specific signature generator classes
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.

(From OE-Core rev: cb73cf4299a192e6065d567fae700987c3f937aa)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-23 09:01:39 +00:00
Richard Purdie
b454cb7366 sanity.conf: Incrase bitbake minimum version requirement to 1.15.1
(From OE-Core rev: 383b1ef37c1c6f6b1be043ac61e338d75488c9a3)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-23 09:01:38 +00:00
Richard Purdie
280e5fd212 gcc: Ensure that the shared source directory shared the same sstate hashes
The fetch/unpack/patch/headerfix tasks are shared and hence their sstate hashes
should also match. Sadly this is not the case since:

a) gcc-runtime applies an additional patch
b) The do_headerfix task was missing from libgcc
c) The do_headerfix task is a shell task and hence depends
   on all exported variables which can vary between cross and target
   recipes.

To fix this, the patch moves the patch to the common code, adds
the headerfix task to a common include file and disabled shell
dependencies on the do_headerfix task since its clear in this case
we don't need thsoe dependencies since we just call sed.

With this patch applied, all these recipes now share common sstate checksums.

(From OE-Core rev: 2c4569801a710f34a695b8d2a0ee7fc127fb34e4)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-23 09:01:38 +00:00
Richard Purdie
76c16c4fa8 Bump the version to 1.15.1
(Bitbake rev: 65c2eb1c095fe7ba3259060aefd4ba0e20cae319)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-23 09:01:36 +00:00
Scott Garman
3fe81df640 distro_tracking: update libpng, libgdbus, opensp, nfs-utils manual check dates
(From OE-Core rev: ac162df288f6d8f68c1764fad0ab2d33b9cee281)

Signed-off-by: Scott Garman <scott.a.garman@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:51 +00:00
Martin Jansa
3c5f108001 prserv: fix import of sqlite3
* this is used in all other bitbake parts where sqlite3 is used, don't
  know why it wasn't used here, but it fails e.g. on Gentoo
  Traceback (most recent call last):
    File "bin/bitbake", line 39, in <module>
      from bb import cooker
    File "lib/bb/cooker.py", line 39, in <module>
      import prserv.serv
    File "lib/prserv/serv.py", line 4, in <module>
      import xmlrpclib,sqlite3
  ImportError: No module named sqlite3

(Bitbake rev: 9a57ec705cf5c932d8c2a35852db7a4627c57937)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:49 +00:00
Richard Purdie
7a8bae92ed siggen.py: Abstract the runtime task dependency handling code in the generators
This means that custom signature handlers can override specific parts
of the code without having to reimplement whole functions allowing them
more flexibility.

(Bitbake rev: 164195c068a656733cfe7aa07369c5ed6ea62ca5)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:40 +00:00
Richard Purdie
c4a8fab1a4 cooker.py: Allow siggen classes to be added by the metadata
By calling init_parser which sets up the siggen code after the ConfigParsed
event is fired, we can allow the metadata to add siggen classes which
was always what the code intended.

(Bitbake rev: 69fd5ad4a8402fab5eb8348260966b337c5648ff)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:40 +00:00
Paul Eggleton
8878ee89ba bitbake/fetch2: allow resuming interrupted fetch
A lot of our checks in the fetcher code assume that if the downloaded
file exists, the download finished successfully; this meant that if
BitBake was interrupted in the middle of a fetch then it would not
resume the fetch the next time, but instead attempt to use the
half-fetched file and usually fail as a result.

Since we're already writing a ".done" stamp file when a fetch completes,
just check for its existence and assume the download didn't complete
successfully if it isn't present.

(Bitbake rev: 721e986624529aedef96dd06c9fe6243f2897b10)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:39 +00:00
Paul Eggleton
42645b0965 bitbake/runqueue: always log tasks summary
It's unclear from the history but at some point we stopped logging the
"Tasks Summary" NOTE when tasks failed. Reinstate this for failure, and
also make the count of attempted tasks include the failed task.

(Bitbake rev: e44d5be98fc5d2589cd929ce143638395936b936)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:39 +00:00
Richard Purdie
f3e51862f1 siggen: Ensure correct runtask dependency output is shown for diffsigs
The actual task names are discounted for comparison of dependent tasks, only
the actual hashes are used. This updates the comparison code to account for
this change, attempting heuristic matching for more user friendly output but
falling back to showing the changed hashes directly. This avoids some confusing
output to users where it looked like tasks had changed when they had not and
actually had the same hash but a different taskname.

(Bitbake rev: 7da7dff83ed765c9cde1d7f91ee1b65e49520481)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:39 +00:00
Darren Hart
11cce80137 usermanual: Correct "inherit" search to bbclass from oeclass
Bitbake looks for bbclass now, not oeclass. Update the docs accordingly.

(Bitbake rev: 8b713708541f85a4252c0f7b683aff4407c7d3e0)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:38 +00:00
Christopher Larson
0779a90e2a cooker: use futures rather than a multiprocessing pool
This avoids some silent parser hangs we were seeing which were
near impossible to debug as no user feedback was given.

[RP: Tweak commit message]
(Bitbake rev: d104f29871c04a5a36600a35b2568b49e5b21ca0)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:38 +00:00
Christopher Larson
299fa3489b Add dependency on the backported python 3.2 concurrent.futures
(Bitbake rev: 774f59f06e65a35df597aa77c0fa06ab66c46906)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:47:32 +00:00
Zumeng Chen
7a8e1ef418 rspro-conf: remove usbgadget from routerstationpro
Since the target doesn't have the related requirement
to use USB slave hardware supporting usb gadget, so
remove it from MACHINE_FEATURES.

Signed-off-by: Zumeng.chen@windriver.com>
Acked-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-20 16:31:34 +00:00
Paul Eggleton
967de59f35 buildhistory_analysis: include related fields in output
Sometimes, when a value changes in the buildhistory it is useful to
know when a related (but not necessarily itself monitored) value
changes as it can help explain the change. For example, when the list
of installed packages for an image changes it could be caused by a
change to one of the image-related variables.

Related field changes are recorded as sub-items of each change.
Currently the only way to visualise these is via the buildhistory-diff
tool, so an example would be:

Changes to images/qemux86/eglibc/core-image-minimal (installed-package-names.txt):
  locale-base-de-de was added
  procps was added
  * IMAGE_LINGUAS: added "de-de"
  * IMAGE_INSTALL: added "procps"

Here we see that two additional packages have been added to the image,
and looking at the related changes to the two variables IMAGE_INSTALL
and IMAGE_LINGUAS we have the explanation as to why.

(From OE-Core rev: 2c5b90c6d1b1091779602ebe03e84674eb63ea83)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 14:59:23 +00:00
Paul Eggleton
11e5d7bc81 classes/patch: avoid backtrace when patch does not apply
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]

(From OE-Core rev: ce6c80a1e68c2af0b4b5fa27582ad9c9f119e5c1)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 14:34:34 +00:00
Martin Jansa
adb3ed29db task-base: rename VIRTUAL-RUNTIME-alsa-state to use underscore
* in http://lists.linuxtogo.org/pipermail/openembedded-core/2012-January/016226.html
  we talked about
  VIRTUAL-RUNTIME_alsa-state, but
  VIRTUAL-RUNTIME-alsa-state was used instead, which is inconsistent with other VIRTUAL-RUNTIME vars

(From OE-Core rev: d5b892467023d77d219ae05170c875f7b423aa78)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 14:34:34 +00:00
Paul Eggleton
dac8259131 hdparm: remove PRIORITY
PRIORITY is no longer set in recipes in OE-Core, so remove it. (Since
"optional" is the default value from bitbake.conf, no PR bump is
necessary.)

(From OE-Core rev: da5d3438fc9161e94fba24e1e8fd50afcae3b7aa)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 14:34:33 +00:00
Paul Eggleton
5cf28333a7 buildhistory_analysis: improve field handling robustness
Avoid errors when comparing changes for KEY = value files (package info
files and image-info.txt):

* Handle keys appearing and disappearing - this will help to handle PE
  in package info files (which is only written when it is not blank) and
  when we add additional fields in future.
* Handle when old value is 0 for numeric field (avoid division by zero)
* Report when numeric field was empty or missing rather than 0 (but
  still treat it as 0 for comparison purposes)

(From OE-Core rev: 255d4bbf4d1e430d45f5fafb7d1c77d9ea67e174)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 14:34:33 +00:00
Paul Eggleton
c1cebf6a2b buildhistory_analysis: correctly handle whitespace when splitting lists
Don't specify any argument to the split() function when handling changes
to list type variables (e.g. PACKAGES) so that the values are split by
any whitespace and only split once for a block of multiple whitespace
characters.

(From OE-Core rev: 15ad5d2c0e92fefdbb7c0cf064134b1cabfd84ac)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 14:34:33 +00:00
Paul Eggleton
2f4f8ef0fc buildhistory: record additional image info
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.)

(From OE-Core rev: 459ed6759a307b389f6ec1874136ec9aa0749120)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 14:34:32 +00:00
Nitin A Kamble
ffa93f0e25 grub-efi-native: fix errors with automake 1.11.2
This commit replaces earlier patch
(grub-1.99_fix_for_automake_1.11.2.patch) which did not work on all distros.

Fixes these errors observed with automake 1.11.2
The useof pkglibhas become more strict compared to the earlier release
of
automake resulting in these failures.
Fixed the files related to automake to avoid the issue.

| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| grub-core/Makefile.am:5:   `conf/Makefile.common' included from here
| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| Makefile.am:6:   `conf/Makefile.common' included from here
| autoreconf: automake failed with exit status: 1
| ERROR: autoreconf execution failed.

| conf/Makefile.common:150: `pkglibdir' is not a legitimate directory
for `SCRIPTS'
| grub-core/Makefile.am:5:   `conf/Makefile.common' included from here
| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| grub-core/Makefile.am:5:   `conf/Makefile.common' included from here
| conf/Makefile.common:150: `pkglibdir' is not a legitimate directory
for `SCRIPTS'
| Makefile.am:6:   `conf/Makefile.common' included from here
| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| Makefile.am:6:   `conf/Makefile.common' included from here
| autoreconf: automake failed with exit status: 1

(From OE-Core rev: ecc383f72791c3c4a3e7ccc646469706b88e68fb)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:13 +00:00
Nitin A Kamble
6ddf0b2b97 autogen-native: new recipe for grub-efi-native
grub-efi-native build is failing due to missing autogen command.
Hence created this recipe.

The newer versions of autogen 5.13 & 5.14 both are dumping core while
building from source, so going back to the working 5.12 version.

Also noticed that no distro vendor has picked up 5.13 or 5.14 versions
of autogen yet.

(From OE-Core rev: 218dbe61917fbedbce45d55de63cce123773f721)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:13 +00:00
Nitin A Kamble
34f4ab18bd guile: new recipe for autogen
guile recipe is needed by autogen.

Imported & updated  the guile-cross-config generation & guile-2.0.pc
manipulation code from the meta-oe guile recipe.

(From OE-Core rev: 7726884826332387180cd24ebe565cd13a193e13)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:12 +00:00
Nitin A Kamble
225a24a390 libunistring: new recipe for autogen
libunistring recipe is needed by guile.
And guile is needed by autogen.

(From OE-Core rev: b9006a6fe807f6717fd6ee7237b23987184d2316)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:12 +00:00
Nitin A Kamble
4cf1776ebc bdwgc: new recipe for autogen
This recipe is needed by guile.
And guile is needed for autogen.

As per Beth's recommondation changed the license specification of the
recipe as

LICENSE = "MIT & FSF-Unlimited & GPL-2.0"

(From OE-Core rev: 2c2080b6aabce57d98caecc396decf9f0a68b07f)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:12 +00:00
Saul Wold
d8063119fc enchant: refactor packages for staticdev
(From OE-Core rev: 87c47a6696add8dc532e83471b74211a1f53f317)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:11 +00:00
Saul Wold
b44c25b72b boost: refactor packages for staticdev
(From OE-Core rev: 0f4f139dd1a6e2c58f26a109b0a94ce01aca272b)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:11 +00:00
Saul Wold
38b034168f js: refactor packages for staticdev
(From OE-Core rev: 7aa32f7b841f7fcd77cb0197891bd43ef5b8562a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:11 +00:00
Saul Wold
cb06a5aa2b db: refactor packages for staticdev
(From OE-Core rev: ceeb10689f80cc86796d1ab32142aa1c4802eb84)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:11 +00:00
Saul Wold
b5dee63c2e attr/acl: refactor packages for staticdev
(From OE-Core rev: 7c124d7c359729d074a5a55bd3bf7415a0aacd51)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:10 +00:00
Saul Wold
cdd2f4e474 liba52: refactor packages for staticdev
(From OE-Core rev: 4390e0c6e6c9390f75410daaa4497826b7638ee5)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:10 +00:00
Saul Wold
40fcaac48e gst-openmax: refactor packages for staticdev
(From OE-Core rev: 6e1daa495a8ff16114d26e554d5e4a7e82c6dea6)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 13:26:10 +00:00
Khem Raj
522c6b376d gnutls: Fix configure issue wrt to rm
Add -f option so if the files dont exist then we can
still continue. Fixes errors like

| + do_configure
| + for dir in . lib libextra
| + rm ./aclocal.m4 ./m4/libtool.m4 './m4/lt*.m4'
| rm: cannot remove `./m4/libtool.m4': No such file or directory
| rm: cannot remove `./m4/lt*.m4': No such file or directory

(From OE-Core rev: 8904e075d4953413edf13c43ee3a10493a6c63bb)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:13 +00:00
Nitin A Kamble
5664e3c14f distro-tracking: add data for newer recipes
(From OE-Core rev: 0a7171176c6a39dae08d683961bc53dfb7f206e9)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:13 +00:00
Joshua Lock
2280404731 distro-tracking-fields: claim responsibility for udev, dpkg, apt, v86d
Nominate myself to be on the hook for updates to the udev, dpkg, apt and v86d
recipes.

Add a copy of the clutter-1.8 metadata without the namespace to keep the
tools happy when they find the clutter_git recipe.

(From OE-Core rev: a87ba1d30890a9042c4c88039d3e9dbbdfb8f10a)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:13 +00:00
Andrea Adami
4f108e93b7 xinput: add utility for configuring and testing XInput devices.
* from meta-openembedded with minor editings
* (fields reordering like other recipes in xorg-app)

(From OE-Core rev: 618da7f65d3f9e3a1a5ee0b35371ae036a219a9a)

Signed-off-by: Andrea Adami <andrea.adami@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:12 +00:00
Khem Raj
c2a74cc148 e2fsprogs_1.42.bb: Fix build fallout for uclibc
e2fsprogs 1.42 onwards uses fallocate() which uclibc
does not implement(yet). In most of places its use
is controlled and it only used when configure detects
fallocate being present but in this one case it missed
to check for fallocate being available so here we
add the check

(From OE-Core rev: 1625faad281eeef3931573908c557362236dcd47)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:12 +00:00
Lianhao Lu
89705eadb4 adt-installer: install autoconf(/automake)-nativesdk
[YOCTO #1909]
Install autoconf-nativesdk and automake-nativesdk to host.

(From OE-Core rev: 0b3842f5c3c1587d25e70bc8223e2b144b9043cb)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:12 +00:00
Khem Raj
ea8e63df24 uclibc: Upgrade to latest master
Document the patches

(From OE-Core rev: fdcae83ad715af92a4d25f4ef5b30c49ce6ceb69)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:11 +00:00
Bruce Ashfield
13a62254e8 linux-yocto: restore WORKDIR as a patch source directory
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.

(From OE-Core rev: fd46d2ec75a53a02464ab2f0bc69eb1971432c9a)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:11 +00:00
Nitin A Kamble
80038a0352 site/ix86-common: fix an error
Fixed this line
ac_cv_sizeof_unsigned_char=${ac_cv_sizeof_unsigned_int=1}

as this line
ac_cv_sizeof_unsigned_char=${ac_cv_sizeof_unsigned_char=1}

This issue was causing guile recipe to compile-fail for x86 target.

(From OE-Core rev: d71df3cc2ff2504d61078c578c0e73bbf53b6651)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:11 +00:00
Saul Wold
05f421f200 pkgconfig: Move pkg.m4 from -dev to package
If pkgconfig is installed you're doing development work and the -dev package
makes little sense in the pkgconfig case. Keeping the .m4 file associated with
the main package therefore makes more sense than having the user install both.

[YOCTO #1908]

(From OE-Core rev: 80fdf2cf2b048d7c2e8dff9c47490f47fc62e820)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:11 +00:00
Khem Raj
b19b27676e gnutls: Fix compilation on uclibc
Examples do not compile correctly on latest uclibc

(From OE-Core rev: c0cd44bb5588e96b00631de1f1f8a8143b338c02)

Signed-off-by: Khem Raj <raj.khem@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:10 +00:00
Andrei Gherzan
6455292b96 libsoup: Update package from v2.2.100 to v2.2.105
I included a patch as well to solve a compile error. In this package, a dfprinf function
is declared. It will fail as eglibc provides it's function as well. So i renamed libsoup's
dprintf function into dprinfsoup.

(From OE-Core rev: 6b3364c4c96429c6cb2a492102362b005fdd3a81)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:10 +00:00
Andrei Gherzan
8a7a7fef73 chkconfig: Update package from v1.3.55 to v1.3.57
(From OE-Core rev: 28191449636ef2554e82459038a2d67915e9a022)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:10 +00:00
Joshua Lock
3ba7426bbf busybox: enable dropping of duplicates in syslog, off by default
Busybox syslog includes functionality to drop duplicated syslog entries,
enable this feature in the defconfig yet disable it by default.

Expose configuration of the feature through the syslog-startup.conf file
and the syslog init script.

(From OE-Core rev: 0afa9a63a83ee128dac522af70e1f823b7d6a6df)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:09 +00:00
Joshua Lock
35d1c6821d busybox: change syslog default to log to a file
This changes the default in syslog-startup.conf to log messages
to a file (/var/log/messages) because:

a) we already mount /var/log as a volatile mount by default
b) users are accustomed to looking at /var/log/messages as
most distributions don't ship with logread

(From OE-Core rev: bbf44dddcc473ca085fa5b2dda5f89c22ec31cc0)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:09 +00:00
Joshua Lock
42f0d50fa3 busybox: enable log level configuration in syslog-startup.conf and script
It's possible to configure busybox syslog to only log messages above a
certain level, expose this functionality through the syslog-startup.conf
and syslog init script.

Valid values are 1-8 inclusive.

(From OE-Core rev: 921dfd1a2bc6ad2867da13d2b669288f9788a088)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:09 +00:00
Joshua Lock
030bdde04a busybox: remove incorrect comments from syslog-startup.conf
Setting rotation size and generations is supported with busybox syslogd

(From OE-Core rev: 5b2dcbde7290616104afe5f20c67f87dbc734939)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:09 +00:00
Joshua Lock
cbc784f4eb busybox: drop MARKINT option from init script and syslog-startup.conf
This option has been disabled in busybox since 2007 as it was deemed too
buggy. See:

http://git.busybox.net/busybox/commit/?id=4998c818919477d90674a3f220e7407c26da17f9

(From OE-Core rev: 0e85cd35a71fe14adc3da9b756b919836b687a12)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:08 +00:00
Saul Wold
703e1f06fd pango.inc: fix /etc/pango -> /${sysconfdir}/pango/*
(From OE-Core rev: ea660263d20066f35a47e60a9d48832ff3959ac3)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:08 +00:00
Andrei Gherzan
4884ccd236 busybox: defconfig modified in order to activate CONFIG_EXPR_MATH_SUPPORT_64
Enable 64-bit math support in the expr applet. This will make
the applet slightly larger, but will allow computation with very
large numbers.

[YOCTO #1767]

(From OE-Core rev: 5ab12509051b732944a5027750505fa860133f1b)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:08 +00:00
Saul Wold
f127738aad m4: A better refactoring
(From OE-Core rev: a07e6449a19deec698f6682c97f8f5c8d3b51486)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 11:34:07 +00:00
Lianhao Lu
1fedd166b7 bitbake/persist_data: Reconnect when DB is locked
[YOCTO #1761]
Reconnect to the backend Sqlite DB in 'database is locked' exception so
the timeout can be leveraged in each time retry.

(Bitbake rev: b310382764367b573c84f33d847c6eb821266f9e)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-19 00:15:38 +00:00
Mark Hatle
5724ee9c3a package_rpm.bbclass: Add support for filenames with spaces
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.

(From OE-Core rev: a0f5dd25a37fe3b8664c2133e80b6214559f93f6)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 16:20:54 +00:00
Joshua Lock
39a991880a beagleboard-audio: drop in favour of alsa-state
Signed-off-by: Joshua Lock <josh@linux.intel.com>
2012-01-17 15:53:48 +00:00
Joshua Lock
9ea681fffb alsa-state: add beagleboard specific asound.state
Signed-off-by: Joshua Lock <josh@linux.intel.com>
2012-01-17 15:53:44 +00:00
Andrei Gherzan
e2a3695ad4 busybox/uglibc: remove obsolete check for "kernel24"
Busybox checks if MACHINE_FEATURES contains "kernel24". If so, CONFIG_FEATURE_2_4_MODULES will be on "y".
kernel24 is no longer present in any machine configuration. The same situation is in uglibc with a
different CONFIG mapping.

[YOCTO #1901]

(From OE-Core rev: 7257ded5355ffdc0fc169e7f34daeedb0b3dcd78)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 15:15:53 +00:00
Martin Jansa
8773ebef26 gnutls.inc: set libz prefix
* without this patch host's zlib is used, similar to issue with
  libreadline it's important if host's zlib is compatible with MACHINE
  and in this case zlib was in DEPENDS so header was always available in
  sysroot
  lib/config.log:
  configure:18288: checking whether to include zlib compression support
  configure:18291: result: yes
  configure:18786: checking for libz
  configure:18808: x86_64-oe-linux-gcc    -m64 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/qemux86-64 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -I/OE/shr-core/tmp-eglibc/sysroots/qemux86-64/usr/include -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c /usr/lib/libz.so  >&5
  configure:18808: $? = 0
  configure:18818: result: yes
  configure:18825: checking how to link with libz
  configure:18827: result: /usr/lib/libz.so

(From OE-Core rev: 6d21c87ca37a11b34551d79758da65ed417c70a0)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 15:10:16 +00:00
Martin Jansa
8ca0061744 gnutls: add readline to DEPENDS and add --with-libreadline-prefix
* without this patch it looks for readline in host's /usr/lib
  a) and fails if readline wasn't built before gnutls, because -I is set
     and cannot find header file, this case is better
     configure:33131: checking for readline
     configure:33156: x86_64-oe-linux-gcc    -m64 --sysroot=/OE/oe-core/tmp-eglibc/sysroots/qemux86-64 -std=gnu99 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -I/OE/oe-core/tmp-eglibc/sysroots/qemux86-64/usr/include -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c  /usr/lib/libreadline.so >&5
     conftest.c:240:31: fatal error: readline/readline.h: No such file or directory

  b) and finds usable version there if readline was built and MACHINE is compatible with host
     (like qemux86-64 on amd64 host) and then it's passing -L/usr/lib (without sysroot prefix)
     to every build using libgnutls.la
     configure:33131: checking for readline
     configure:33156: x86_64-oe-linux-gcc    -m64 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/qemux86-64 -std=gnu99 -o conftest -O2 -pipe -g -feliminate-unused-debug-types -I/OE/shr-core/tmp-eglibc/sysroots/qemux86-64/usr/include -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed conftest.c  /usr/lib/libreadline.so >&5
     configure:33156: $? = 0
     configure:33173: result: yes
     configure:33185: checking how to link with libreadline
     configure:33187: result: /usr/lib/libreadline.so
     configure:33199: checking readline/readline.h usability
     configure:33199: x86_64-oe-linux-gcc    -m64 --sysroot=/OE/shr-core/tmp-eglibc/sysroots/qemux86-64 -std=gnu99 -c -O2 -pipe -g -feliminate-unused-debug-types -I/OE/shr-core/tmp-eglibc/sysroots/qemux86-64/usr/include conftest.c >&5
     configure:33199: $? = 0
     configure:33199: result: yes
     configure:33199: checking readline/readline.h presence
     configure:33199: x86_64-oe-linux-gcc -E --sysroot=/OE/shr-core/tmp-eglibc/sysroots/qemux86-64    -m64 -I/OE/shr-core/tmp-eglibc/sysroots/qemux86-64/usr/include conftest.c
     configure:33199: $? = 0
     configure:33199: result: yes
     configure:33199: checking for readline/readline.h
     configure:33199: result: yes

(From OE-Core rev: 044f99155bf8775481b70cbe02745c6d9ae1d6a9)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 15:10:15 +00:00
Koen Kooi
925433d6e6 pango: create /etc/pango in module postinsts if it's missing
(From OE-Core rev: 1b24f76bae9612bc69fb0afeaccb06c5e5746ce6)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 15:10:15 +00:00
Koen Kooi
1ca0401f33 Revert "pango.inc: add directory "/etc/pango""
This reverts commit 65186bd86170d8c375931a18487c2fdf3bd1b3b0.

(From OE-Core rev: 25c2d1a825a5d028b99f956be2918ceed4a93ac3)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 15:10:15 +00:00
Saul Wold
8b11a2f3f0 openssl-1.0.0: Update to 1.0.0e and fix QA Warning
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4108

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4576

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4577

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4619

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2012-0027

[YOCTO #1905]

(From OE-Core rev: 294e808d12131412bf1edb6f4babc9e57c8141e0)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:58:41 +00:00
Saul Wold
ac27587f93 openssl-0.9.8: Update to 0.9.8s
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4108

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4109

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4576

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4577

http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2011-4619

[YOCTO #1904]

(From OE-Core rev: 980ba5e77438c3a22c295f56ffb71f1d290db50a)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:58:41 +00:00
Saul Wold
7edf3dc059 valgrind: Update for eglibc 2.15
(From OE-Core rev: 8953e4a93ce6ad0257a094fdc6f3cd88ac5e89b9)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:58:40 +00:00
Aneesh Bansal
93d70e4b86 valgrind: Add mfatbu/mfatbl instructions support for pcc
This adds a patch submitted to upstream to add support for these missing
ppc instructions.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:57:47 +00:00
Zumeng Chen
e1d3a32bb1 babeltrace: Integrated from version 0.8
It provides trace read and write libraries, as well as a trace converter.

(From OE-Core rev: d14441874163bd579d9901f9bc07852882502100)

Signed-off-by: Zumeng Chen <zumeng.chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:27 +00:00
Zumeng Chen
95386cfb96 lttng-modules: Update to 2.0
This patch intended to integrate the lttng-modules 2.0 package
containing the kernel tracer modules.
LTTng-modules 2.0 is currently in pre-release (-pre11), so we
have to update it when official released.

lttng-2.0 supports lttng-modules extra builds, which don't need
any patches on Linux kernel vs the previous version of lttng.
As described in README of lttng-modules-2.0, so far, it has been
tested in the latest kernel on x86 32/64-bit, and powerpc 32-bit,
, build tested on ARM. So does yocto kernel, the related tests
on qemux86 and qemuppc has been validated and a build test on
qemuarm passed too with this patcheset.

(From OE-Core rev: b054921f7dd59519a896a4e1a5f40965d4abd87e)

Signed-off-by: Zumeng Chen <zumeng.chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:26 +00:00
Zumeng Chen
6d769b286e lttng-tools: Update to 2.0-pre16
This patch intended to integrate the Linux trace toolkit, which
is a suite of tools designed to extract program execution details
from the Linux operating system and interpret them.

lttng-tools 2.0 is currently in pre-release(-pre16), so we have to
update it when official released.

(From OE-Core rev: 4733cd6501e5d39b4229c3da79529d6a3ae844f6)

Signed-off-by: Zumeng Chen <zumeng.chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:26 +00:00
Zumeng Chen
6f3d52ec11 lttng-ust: Update to 2.0
This patch intended to integrate the LTTng UST 2.0 package, which
contains the userspace tracer library to trace userspace codes.

(From OE-Core rev: 4ed09cb80196c7a3f691c8b9304df7c1fe4a8be5)

Signed-off-by: Zumeng Chen <zumeng.chen@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:26 +00:00
Saul Wold
a9095e5cb2 m4: refactor .bb and .inc files
The orignal had common code in the m4_1.4.16.bb file that was
in the m4.inc file. m4-native was then including the m4.bb file
and picking up the BBCLASSEXTEND, which causes the fetch to fail.

(From OE-Core rev: 4677da625f8ceb02c96f365bb948b8901bd694a4)

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:26 +00:00
Paul Eggleton
f290935151 classes/packagehistory: remove now obsolete class
packagehistory.bbclass has been superseded by buildhistory.bbclass,
which gives more detailed output (including information on produced
images) as well as other enhanced functionality.

(From OE-Core rev: d07bd704e2c0624deba10f33ccc946bd1338855c)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:26 +00:00
Paul Eggleton
ee7fb2b86d classes/package: remove out-of-date notice referring to the OE bugtracker
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.

(From OE-Core rev: ee486e30432ffd3ef97ba16511a9a1a38bad3826)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:25 +00:00
Paul Eggleton
9d6bf93e9d conf/bitbake.conf: allow wget to output error messages
Use the -nv instead of -q command line option for wget so that if
fetching from a URL that the wget fetcher handles (e.g. http) fails, we
get a possibly useful error message (but it still remains relatively
quiet when the fetch succeeds.)

(From OE-Core rev: 81dcfc5e7a93d74caafde1dff923bfe6c008d9ea)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:25 +00:00
Paul Eggleton
edef415be6 classes/base: note variable name in COMPATIBLE_* skip messages
When raising SkipPackage for COMPATIBLE_MACHINE and COMPATIBLE_HOST
exceptions, include the name of the variable as a hint to the user.

(From OE-Core rev: c9f6fd20cf65799714b45a7bdfc3dd022b3d79cd)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:25 +00:00
Mark Hatle
3287e4be35 prelink: Update to latest version
The latest version of prelink corrects a problem when attempting
to prelink MIPS architectures.

    2012-01-04 Mark Hatle <mark.hatle@windriver.com>
      * exec.c: Check that a section is larger then 0 bytes when
        determining the section to segment mapping. This matches
        the behavior of elfutils - readelf. Otherwise an empty
        PROGBITS section at the end of a segment will cause a
        failure.

[YOCTO #1463]

(From OE-Core rev: 09a70c55e590d169b8a3b4b89853c96b7b977fc0)

Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:25 +00:00
Joshua Lock
b6b909abd8 task-base: add VIRTUAL-RUNTIME_alsa-state to task-base-alsa
Define this to be the alsa-state package by default. This enables automatic
configuration setting and restoration on systems with alsa.

(From OE-Core rev: a70cc15b4b053ff01229010e55b37ed4487b8f3a)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:25 +00:00
Joshua Lock
432c6cff0f alsa-state: move state files to localstatedir
alsactl creates the state files in /var/lib/alsa by default so switch
alsa-state to use files in that location.

Further, update the alsa-state init script to have the location of the
state files sed'ed into the script at do_install time (so as to remove
hard coding of directory paths).

(From OE-Core rev: 896924c72e7b37c18819229e8160c34cdf4465c8)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:24 +00:00
Joshua Lock
c86797abdf alsa-state: add alsa-state from oe classic
alsa-state adds an init script and configuration files to enable a
consistent and centralised mechanism for setting and restoring alsa
configuration.

(From OE-Core rev: 8bc43c40cf72d5543924229146fa4106ad87b147)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:24 +00:00
Joshua Lock
79b6192d21 task-base: move default definition of VIRTUAL-RUNTIME_apm
This belongs in default-providers.conf

(From OE-Core rev: afff4e6130e835048d81f65f703e118d5944629a)

Signed-off-by: Joshua Lock <josh@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:24 +00:00
Scott Garman
f07793dd77 distro_tracking: recipe upgrades and manual check info
Updated info for the following recipes:

e2fsprogs
expat
chrpath
libevent
libpam

(From OE-Core rev: 3f6c29bc32722d4cef3a89aed749e2fbce44a080)

Signed-off-by: Scott Garman <scott.a.garman@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:24 +00:00
Scott Garman
464a2d66a4 e2fsprogs: upgrade to 1.42
Refactored quotefix.patch to apply cleanly.

(From OE-Core rev: 1749f35bc92acd971eda245b93781305f79c2bef)

Signed-off-by: Scott Garman <scott.a.garman@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:23 +00:00
Scott Garman
6ce82eac3b libpam: upgrade to 1.1.5
Updated HOMEPAGE, BUGTRACKER, and SRC_URI fields to reflect new
project hosting.

Cleaned up some of the metadata ordering.

(From OE-Core rev: 1fcd483e5ee5223f37c5edce26327f79b76bd01d)

Signed-off-by: Scott Garman <scott.a.garman@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:23 +00:00
Enrico Scholz
35759f977e bitbake.conf: search /lib for -native builds
Changes to BUILD_LDFLAGS are required due to the recent movement of some
libraries from ${libdir} to ${base_libdir}.  ${base_libdir} must be now
in the linker search path to avoid build problems of -native packages.

(From OE-Core rev: 46bf69dcfa99a3a8677b241bb32bed2f30255ece)

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:23 +00:00
Colin Walters
73a7876b27 libtool: Put all libltdl headers in the correct libltdl-dev package
/usr/include/ltdl.h was in libtldl-dev, but not the headers it depends
on.

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:22 +00:00
Nitin A Kamble
023fe87943 grub-efi-native: fix errors with automake 1.11.2
Fixes these errors observed with automake 1.11.2
The useof pkglibhas become more strict compared to the earlier release
of
automake resulting in these failures.
Fixed the files related to automake to avoid the issue.

| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| grub-core/Makefile.am:5:   `conf/Makefile.common' included from here
| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| Makefile.am:6:   `conf/Makefile.common' included from here
| autoreconf: automake failed with exit status: 1
| ERROR: autoreconf execution failed.

| conf/Makefile.common:150: `pkglibdir' is not a legitimate directory
for `SCRIPTS'
| grub-core/Makefile.am:5:   `conf/Makefile.common' included from here
| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| grub-core/Makefile.am:5:   `conf/Makefile.common' included from here
| conf/Makefile.common:150: `pkglibdir' is not a legitimate directory
for `SCRIPTS'
| Makefile.am:6:   `conf/Makefile.common' included from here
| conf/Makefile.common:140: `pkglibdir' is not a legitimate directory
for `DATA'
| Makefile.am:6:   `conf/Makefile.common' included from here
| autoreconf: automake failed with exit status: 1

(From OE-Core rev: e9c5c354086546efe4114c6225d05116fb18b9fe)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:22 +00:00
Enrico Scholz
866ed43c12 package.bbclass: quote pathname given to objdump
Packaging will fail with executable files containing spaces in their
names. Patch quotes the parameter passed to 'objdump'.

(From OE-Core rev: 7f7db286ca0b70bd5cce643c3b84f77ad45cc786)

Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:22 +00:00
Matthew McClintock
f20d49315d image_types_uboot.bbclass: Add uncompressed ext2 image option
(From OE-Core rev: 1a8e02fee858fa9569f2e980ebff0698e4a53d36)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:21 +00:00
Matthew McClintock
2eb5811da7 image_types.bbclass: Fix generating uncompressed ext2 images
(From OE-Core rev: d0687295456bcf240be657e6b5b508f718ca9ebd)

Signed-off-by: Matthew McClintock <msm@freescale.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:21 +00:00
Martin Jansa
e0ae57d9f4 dbus-1.4.16: use INC_PR from dbus.inc to fix PR bump after dbus-launch-helper permission change
(From OE-Core rev: ef8171ecad2197d8b123712be36f6e03e8926e13)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:21 +00:00
Zhai Edwin
e7a31cf67d runqemu: Fix the wrong path of libGL.so in 64b Ubuntu 11.10
From 11.10, libGL.so is installed @ /usr/lib/x86_64-linux-gnu/ in 64b Ubuntu.

[YOCTO #1885] got fixed

(From OE-Core rev: d32c15b9b09e49cb79028f59b493d478f00d4019)

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:21 +00:00
Xiaofeng Yan
a521f9d679 distro_tracking_fields.inc: Modify the status of eds-tools and mingetty
Update the status of eds-tools and mingetty.
mingetty has still not been updated since 2008.

(From OE-Core rev: f8d984e485a5bb12f4df8e28e7e0fb0da2a7098e)

Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>

[Fixed Date format]

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:20 +00:00
Martin Jansa
5fabe90808 xorg-*: disable xmlto where it was failing
* meta-oe now provides xmlto-native
  http://git.openembedded.org/meta-openembedded/commit/?id=ab8f876ca8fa223c183e3db2029cce88f3435a27
  but not the stylesheets for buildhosts without them it's unusable and fails, because xorg macros
  autodetecting xmlto available, see:
  http://lists.linuxtogo.org/pipermail/openembedded-devel/2011-December/037066.html
  after adding xmlto-native and stylesheets-native to DEPENDS we can enable it again

(From OE-Core rev: 58f18f04d7783cc75127f7f1c0921051431dcd8c)

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:20 +00:00
Denis 'GNUtoo' Carikli
1db019ac7c alsa-utils: depend on libsamplerate0
We need to depend on libsamplerate0 because it's detected automatically
  and if we configure without it we get that issue at runtime trying
  to run the alsaloop program:
    No libsamplerate support.

(From OE-Core rev: 545a7407361a7e144a0f868e1a095bf7b10fffd8)

Signed-off-by: Denis 'GNUtoo' Carikli <GNUtoo@no-log.org>
Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:20 +00:00
Darren Hart
1cabda965d bootimg: Account for FAT filesystem overhead in image size
Fixes [YOCTO #1852]

The bootimg class wasn't accounting for non-trivial amount of space
required by the directory entries and FATs for the FAT filesystem.

This patch attempts to make an accurate prediction of FAT overhead and
adjusts the image size accordingly. It assumes no more than 16 directory
entries per directory (which fit in a single sector). It also assumes
8.3 filenames. With the ceiling functions rounding up to full sectors
and tracks, these assumptions seem reasonable.

In order to ensure the calculations are accurate, this patch forces the
FAT size to 32, rather than allowing mkdosfs to automatically select 12,
16, or 32 depending on the image being built.

Tested by setting BOOTIMG_EXTRA_SPACE=0 and building core-image-minimal
and core-image-sato for fri2-noemgd from meta-intel.

(From OE-Core rev: 68aa18609c10a3ae2f738930c933fa2a95ce8959)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
CC: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:20 +00:00
Christopher Larson
19247e44a3 oe.license: avoid the need to catch SyntaxError
(From OE-Core rev: cace9ddc0edd654877d968643960fa4343472b58)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:19 +00:00
Christopher Larson
7ce97336aa oe.license: add is_included convenience function
Given a license string and whitelist and blacklist, determine if the
license string matches the whitelist and does not match the blacklist.

When encountering an OR, it prefers the side with the highest weight (more
included licenses). It then checks the inclusion of the flattened list of
licenses from there.

Returns a tuple holding the boolean state and a list of the applicable
licenses which were excluded (or None, if the state is True)

Examples:

    is_included, excluded = oe.license.is_included(licensestr, ['GPL*', 'LGPL*'])
    is_included, excluded = oe.license.is_included(licensestr, blacklist=['Proprietary', 'CLOSED'])

(From OE-Core rev: 7903433898b4683a1c09cc9a6a379421bc9bbd58)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:19 +00:00
Christopher Larson
49a0821376 copyleft_compliance: add debug message with the reason for exclusion
(From OE-Core rev: 02101bbe08a5cd6e5eecb21f2095c15ebfe9287f)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:19 +00:00
Christopher Larson
6d73a199e4 copyleft_compliance: add control of recipe types to include
In this context, recipe "type" refers to whether it is 'target', 'native',
'cross', etc. COPYLEFT_RECIPE_TYPES is a space separated list of types to
include. It defaults to 'target'.

(From OE-Core rev: 045e8a409ffe23d4f562b2982bfeee6e45f3c0d9)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:19 +00:00
Bruce Ashfield
7561d5b204 linux-yocto: consolidated fix SRCREV updates
Updating the SRCREVs to include the following fixes from Khem Raj and
Zumeng Chen.

 6f5b118 compiler.h: Undef before redefining __attribute_const__
 fe80c1e oprofile, arm/sh: Fix oprofile_arch_exit() linkage issue

(From OE-Core rev: 02e22816d68dc2bac7fed6952e52ea8a3d9532d2)

Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:18 +00:00
Liming Wang
bec7def38d tslib: enable big endian support for qemuppc
This enables wacom tablet/touchscreen support on qemuppc.

(From OE-Core rev: 127b15cb0e9644fb732b707b9d4ddaf00d24973e)

Signed-off-by: Liming Wang <liming.wang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:18 +00:00
Liming Wang
57e78fa12d qemuppc: add machconfig
(From OE-Core rev: de8fa377f0bbc9aa3911fc6b4be554f8584fb43f)

Signed-off-by: Liming Wang <liming.wang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:18 +00:00
Liming Wang
b98851cc6f qemuppc: add pointercal file
This file is for tslib.

(From OE-Core rev: 80fcbee25036d2051538e26cd8b3d2989b0d276d)

Signed-off-by: Liming Wang <liming.wang@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:17 +00:00
Liming Wang
523f6b69c6 qemuppc: replace emulation of qemuppc from prep to mac99
With this new emulation, existing qemuppc functionality is maintained
and other functionality such as framebuffer + sato and NFS boot are
added.

(From OE-Core rev: 52ea026df141ea23bbab38ad3a9733c15097eaa4)

Signed-off-by: Liming Wang <liming.wang@windriver.com>
Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:17 +00:00
Shane Wang
573daf6734 hdparm: upgrade to 9.37
The patch was imported from the OpenEmbedded server (http://git.openembedded.org/openembedded/tree/recipes/hdparm) as of commit id 4d2cb79dcecd056742f411a328f9f1f1113bf689.

And changes include:
       - upgrade to the latest version 9.37 from 9.35.
       - added license checksum.
       - the license for wiper which is in hdparm is GPLv2.

(From OE-Core rev: e46995adec82623342234e4a51bd8c12e6d62c3e)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:17 +00:00
Shane Wang
7a20966e05 stat: add recipe stat with version 3.3
stat is brought into Yocto because the latest version hdparm 9.37 depends on it, and add license checksum.

The recipe was imported from the OpenEmbedded server
(http://git.openembedded.org/openembedded/tree/recipes/stat) as of commit ids
709c4d66e0b107ca606941b988bad717c0b45d9b,
44985d56bc556786812a0a02d6219afd31a7381d,
b3246d96069fd11caee42ec6ebcbf6dca2d62449.

(From OE-Core rev: 99fdc0626d2e0f5a4a8fbaf0b1de86437966260f)

Signed-off-by: Shane Wang <shane.wang@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:16 +00:00
Zhai Edwin
fb878477cb distro-tracking: Update info for webkit-gtk, web-webkit
(From OE-Core rev: 3add06d4407b0a30ff8a8202aa028ab0cbfd28d6)

Signed-off-by: Zhai Edwin <edwin.zhai@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:16 +00:00
Nitin A Kamble
d0cc840977 distro_tracking: update manual_check_date fields
(From OE-Core rev: bf039fdb6036a5cae11ad58edb2fd9e4f60632da)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:16 +00:00
Nitin A Kamble
f93408805a btrfs-tools: upgrade to newer git commit
(From OE-Core rev: 32068d9e3157748f3894b3368c0a050af5e12d47)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:16 +00:00
Nitin A Kamble
ccd2a31003 libpcre: upgrade from 8.20 to 8.21
(From OE-Core rev: efd200bc0db4d290445f742798e20914e4db347a)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:15 +00:00
Nitin A Kamble
8f44e9030b insane.bbclass: fix elf.arch not matching error for x32 kernel
For x32 the user space is 32bit and the kernel is 64bit.
So the elf.arch for vmlinuz is x86_64 and not x86. This commit
fixes this QA error thrown for x32 kernel.

| ERROR: QA Issue: Architecture did not match (62 to 3) on
/work/qemux86_64-poky-linux-gnux32/linux-korg-3.1+git1+e2bf8464ddbf5da24d3d320cded5691828a91a0b-r1/packages-split/kernel-vmlinux/boot/vmlinux-3.1.0-yocto-standard-01628-ge2bf846
(From OE-Core rev: 74686edafa241839d3880e06740ee7450ff94fd8)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:15 +00:00
Nitin A Kamble
dd04a42df4 diffstat: upgrade from 1.54 to 1.55
(From OE-Core rev: f29dd1173c261c46b0c3d0d30f94a45c011a72de)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:15 +00:00
Nitin A Kamble
3754d75e49 locale: fix package's "provides" tag
Fixes this bug: [YOCTO #1874]

Fixes an issue where a locale package depends on one package while it
also provides the same, as seen bellow.

Package: locale-base-de-de
Version: 2.12-r19
Depends: eglibc-binary-localedata-de-de
Provides: virtual-locale-de-de, virtual-locale-de,
eglibc-binary-localedata-de-de

Actually the eglibc-binary-localedata-de-de is ia separate package,
 and it should not be part of provides of the locale-base-de-de.

(From OE-Core rev: 49c5ff7197b44c7d29d31506c2425b86bc2c1ff6)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:14 +00:00
Christopher Larson
4807e0b3ae ncurses-native: install to libdir, not base_libdir
For target, both base_libdir and libdir in sysroot can be used, as we pass
--sysroot to the toolchain. For native, we don't do this, and we also only add
-L<sysroot>/${libdir}, not -L<sysroot>/${base_libdir}, resulting in other
native recipes (like readline-native) failing to find the ncurses libraries.

readline-native only built successfully on hosts where it could fall back to
their ncurses/termcap rather than the one in the sysroot.

(From OE-Core rev: dd05e06b89906002f68d616a6326c962e725bc54)

Signed-off-by: Christopher Larson <chris_larson@mentor.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:14 +00:00
James Limbouris
b5ad3773af ghostscript: build cups filters
Cups filters are no longer built by default. Since ghostscript already depends
on cups, build the filters and package them as ghostscript-cups.

Ghostscript uses the cups-config script from the oe sysroots to determine some
of the target install paths, as well as to determine the linker path. The config
script gives out paths pointing to the sysroot, so some of the paths needed to
be adjusted in the Makefile.

(From OE-Core rev: 8c457ea44dc75a01826b070c8b41d1ca5e712171)

Signed-off-by: James Limbouris <james@digitalmatter.com.au>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:13 +00:00
Andrei Gherzan
254b9de1af wpa-supplicant: Compile without CONFIG_GNUTLS_EXTRA (PR BUMP)
CONFIG_GNUTLS_EXTRA is needed as support for TLS/IA which was designed to be used
in the EAP-TTLSv1. As we don't see any requirement for that protocol today we decided
to remove it from wpa-supplicant .config file.
This change includes PR bump.

[YOCTO #1845]

(From OE-Core rev: 959449005c02d5e2554bb03bfa8e21874012d2e5)

Signed-off-by: Andrei Gherzan <andrei@gherzan.ro>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-17 14:53:13 +00:00
Richard Purdie
7c8ebf6f0d pango: Use gnomebase class, not gnome
There was a circular dependency introduced by the recent gconf changes
to depend on gtk+. The issue is that gtk+ depends on pango and pango
depends on gconf.

This patch changes to use the gnonebase class since pango has no need
of gconf/mime/gtk-icon-cache and hence removes the circular dependency.

(From OE-Core rev: 91e17c0c0ac2330f826b95e762542cd0d0c82385)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 18:01:43 +00:00
Koen Kooi
b02e7d45e0 gconf: enable gtk+ 2.0 support to build gconf-sanity-check-2
This is needed for e.g. gnome-session:

gnome-session[424]: WARNING: Failed to run gconf-sanity-check-2: Failed to execute child process "/usr/libexec/gconf-sanity-check-2" (No such file or directory)

(From OE-Core rev: ecf15d60dd0c255c80de223dad08234e915916a2)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 14:11:25 +00:00
Jean-François Dagenais
f17c9d3b38 buildstats: tolerate absence of /proc/diskstats
In OpenVZ containers (and probably lx containers as well),
the diskstats entry is not even present. Use the "NoLogicalDrive"
introduced by Elizabeth Flanagan in such case.

This allows the bitbaking to occure within such containers.

(From OE-Core rev: 16e09b850dcb44cb1afe411439e40a4bae7e8002)

Signed-off-by: Jean-François Dagenais <jeff.dagenais@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 12:24:57 +00:00
Steve Sakoman
18fe75dd84 dhcp: package /var/lib/dhcp with dhcp-client rather than dhcp-server
Otherwise dhclient encounters errors of this type:

dhclient: can't create /var/lib/dhcp/dhclient-c0c60402-0bc5-4bd7-bc3b-49a27fa37d72-eth1.lease: No such file or directory

(From OE-Core rev: aad04928116feea421fba84c4780b93191be6169)

Signed-off-by: Steve Sakoman <steve@sakoman.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 12:24:56 +00:00
Koen Kooi
16d911d191 cairo 1.10.2: enable tee backend
This is needed for firefox:

| checking CAIRO_LIBS... -lcairo -lpixman-1 -lfreetype -lfontconfig
| checking for cairo-tee >= 1.10... Package cairo-tee was not found in the pkg-config search path. Perhaps you should add the directory containing `cairo-tee.pc' to the PKG_CONFIG_PATH environment variable No package 'cairo-tee' found
| configure: error: Library requirements (cairo-tee >= 1.10) not met; consider adjusting the PKG_CONFIG_PATH environment variable if your libraries are in a nonstandard prefix so pkg-config can find them.

(From OE-Core rev: 935ae84757ca623f93b1465088e27107bc226dee)

Signed-off-by: Koen Kooi <koen@dominion.thruhere.net>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 12:24:56 +00:00
Xiaofeng Yan
094118031c pango.inc: add directory "/etc/pango"
Command "pango-querymodules > /etc/pango/pango.modules" can't work when \
starting up yocto because of no directory "/etc/pango". It will cause \
messy code when gtk-demo running.

[YOCTO #1900]

[RP: PR bump]
(From OE-Core rev: 65186bd86170d8c375931a18487c2fdf3bd1b3b0)

Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 12:24:56 +00:00
Xiaofeng Yan
e2948feae8 cairo.inc: Change configuration of directfb to gtk-directfb
"direcdtfb" is a wrong configuration in PACKAGECONFIG. It should be "gtk-directfb".
PACKAGECONFIG can't select directfb as backend rightly, or else.

[YOCTO #1900]

(From OE-Core rev: 458ffd3f47b99ee89e6cb8015d68f9820f86e3e7)

Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 12:24:55 +00:00
Xiaofeng Yan
beb601f79f gtk.inc: Change configuration of directfb to gtk-directfb
"direcdtfb" is a wrong configuration in PACKAGECONFIG. It should be "gtk-directfb".
PACKAGECONFIG can't select directfb as backend rightly, or else.

[YOCTO #1900]

(From OE-Core rev: 785412c0dfb8df055e3f5fa865474ee1cf0ce10f)

Signed-off-by: Xiaofeng Yan <xiaofeng.yan@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-16 12:24:55 +00:00
Paul Eggleton
684c6ef2d0 bitbake/knotty: print task failure summary
Remove the error logged within cooker summarising the list of failed
tasks, and instead print this in the UI (knotty) where it belongs. This
also adds the actual name of the task that failed as well as the
corresponding recipe file that was being shown previously.

In addition, reformat the summary messages more tidily - no extra breaks
between lines and use correct English singular/plurals, with some
allowance for future translation.

(Bitbake rev: cdf69913f99d28bc7f51067a60257701f952c6cb)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:23 +00:00
Paul Eggleton
9fd17bbe1c bitbake/cooker: avoid printing stack trace for -b match error
Improves error output for matching problems when the -b / --buildfile
command line option is used.

Rename MultipleMatches exception to NoSpecificMatch (as it is also
raised when there are no matching recipes) and make it inherit from
BBHandledException so that it doesn't print a stack trace (we always log
an ERROR prior to raising it.)

In addition, improve the formatting of the error message - only call the
log function once rather than once for every match, and use a more
appropriate message if there are no matches.

Fixes [YOCTO #1141]

(Bitbake rev: 803550a5098ec878164245e71344c3d687310b72)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:22 +00:00
Paul Eggleton
5f5ae14ee3 bitbake/fetch2: reduce output for fetch failures
Make the warning for the initial fetch failure a single line - we don't
need the full command and output here yet, but write it into the log in
full as a debug message. However, if fetching from mirrors fails as well
then print out the full details for the first error that occurred as an
ERROR rather than a WARNING.

Since this is logged as an ERROR, combined with an earlier patch it
suppresses the full log which does make the output much more readable
for any fetch error.

Fixes [YOCTO #1832].

(Bitbake rev: 6bbdc7d259c0cc041b62dbdb26cfc3ec6edcb6f3)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:22 +00:00
Paul Eggleton
eb6291b36f bitbake/knotty: avoid printing full task log when error already printed
If a task has logged an ERROR then don't print the contents of the
task's log file in knotty (the default terminal UI).

As a side-effect we now also respect BBINCLUDELOGS in knotty; if it is
false we never print the log (but the pointer to the log file is always
printed).

(Bitbake rev: b9746b7e4d7aa5c34eba15a61427bfc6949af123)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:22 +00:00
Paul Eggleton
ecdfc1ebbe bitbake/fetch2: correctly decode exit signal/status
The termination signal and exit code of the fetch process were not being
decoded correctly, resulting in bitbake reporting that the process
terminated with a signal of the exit code (if it was under 255). There
are functions in the Python os module to do this decoding correctly (for
Unix at least), so let's use them.

(Bitbake rev: 50aea9a76e40cf71cc3f1462c88298e4846a031c)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:21 +00:00
Paul Eggleton
4e8085ccfa bitbake/runqueue: avoid "failed" in task summary if nothing did
Seeing the word "failed" alone without reading the whole context has
occasionally triggered an automatic assumption on the part of some users
(myself included) that something has gone wrong, even when this message
is telling you that "0 [tasks] failed". To avoid this let's just say
"all succeeded" in this case instead.

As a bonus this means you can now search the output for "fail" and not
find anything if all went well.

(Bitbake rev: b6f067af12d4661758a78788f1db472684b9aba8)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:21 +00:00
Paul Eggleton
dcf6b641fe bitbake/fetch2: improve error formatting for fetcher errors
* The "name" argument to FuncFailed is rarely used as a name in actual
  usage within bitbake, so don't treat it as one in the output.
* Don't print URL for FetchError if it was not specified (i.e. don't
  output "Fetcher failure for URL 'None'")
* Don't include URL in "unable to fetch from any source" message since
  we supply it to FetchError and it will be printed anyway.
* Don't include URL in "checksum failed" message for the same reason

(Bitbake rev: 86811bd85e2e453ee92a05fe60160d9b49ac69e8)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:21 +00:00
Paul Eggleton
98a610b3db bitbake/knotty: don't count errors as warnings in summary
The count of warnings being shown in the summary at the end was also
including the number of errors.

(Bitbake rev: d242d6ca81dd83b2b13a3ac77ac4cd829a69cf83)

Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-15 10:06:20 +00:00
Richard Purdie
8a98af2bb5 patch.bbclass: Ensure the DATE and SRCDATE variable exclusions apply to the correct function
People have noticed that sstate is now getting invalidated very readily. The
issue is that the code using these variables was factored into a new function
but the variable exclusion was not. This patch moves the variable exclusion
to the correct place allowing the sstate checksums to work correctly.

(From OE-Core rev: bd047935305c872b565f30b46c94b7077e5fb3a2)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-01-13 16:56:36 +00:00
783 changed files with 19373 additions and 46680 deletions

View File

@@ -40,7 +40,7 @@ from bb import cooker
from bb import ui
from bb import server
__version__ = "1.15.0"
__version__ = "1.15.1"
logger = logging.getLogger("BitBake")
@@ -168,6 +168,8 @@ Default BBFILES are the .bb files in the current directory.""")
parser.add_option("", "--server-only", help = "Run bitbake without UI, the frontend can connect with bitbake server itself",
action = "store_true", dest = "server_only", default = False)
parser.add_option("-B", "--bind", help = "The name/address for the bitbake server to bind to",
action = "store", dest = "bind", default = False)
options, args = parser.parse_args(sys.argv)
configuration = BBConfiguration(options)
@@ -189,8 +191,14 @@ Default BBFILES are the .bb files in the current directory.""")
sys.exit("FATAL: Invalid server type '%s' specified.\n"
"Valid interfaces: xmlrpc, process [default], none." % servertype)
if configuration.server_only and configuration.servertype != "xmlrpc":
sys.exit("FATAL: If '--server-only' is defined, we must set the servertype as 'xmlrpc'.\n")
if configuration.server_only:
if configuration.servertype != "xmlrpc":
sys.exit("FATAL: If '--server-only' is defined, we must set the servertype as 'xmlrpc'.\n")
if not configuration.bind:
sys.exit("FATAL: The '--server-only' option requires a name/address to bind to with the -B option.\n")
if configuration.bind and configuration.servertype != "xmlrpc":
sys.exit("FATAL: If '-B' or '--bind' is defined, we must set the servertype as 'xmlrpc'.\n")
# Save a logfile for cooker into the current working directory. When the
# server is daemonized this logfile will be truncated.
@@ -212,8 +220,11 @@ Default BBFILES are the .bb files in the current directory.""")
bb.utils.clean_environment()
server = server.BitBakeServer()
if configuration.bind:
server.initServer((configuration.bind, 0))
else:
server.initServer()
server.initServer()
idle = server.getServerIdleCB()
cooker = bb.cooker.BBCooker(configuration, idle, initialenv)

View File

@@ -4,11 +4,15 @@
# displaying useful information, or acting against them.
# See the help output for details on available commands.
# Copyright (C) 2011 Mentor Graphics Corporation
# Copyright (C) 2012 Intel Corporation
import cmd
import logging
import os
import sys
import fnmatch
from collections import defaultdict
bindir = os.path.dirname(__file__)
topdir = os.path.dirname(bindir)
@@ -38,6 +42,8 @@ def main(args):
cmds = Commands(initialenv)
if args:
# Allow user to specify e.g. show-layers instead of show_layers
args = [args[0].replace('-', '_')] + args[1:]
cmds.onecmd(' '.join(args))
else:
cmds.do_help('')
@@ -55,6 +61,7 @@ class Commands(cmd.Cmd):
self.config_data = self.cooker.configuration.data
bb.providers.logger.setLevel(logging.ERROR)
self.cooker_data = None
self.bblayers = (self.config_data.getVar('BBLAYERS', True) or "").split()
def register_idle_function(self, function, data):
pass
@@ -90,14 +97,14 @@ class Commands(cmd.Cmd):
"""display general help or help on a specified command"""
if topic:
sys.stdout.write('%s: ' % topic)
cmd.Cmd.do_help(self,topic)
cmd.Cmd.do_help(self, topic.replace('-', '_'))
else:
sys.stdout.write("usage: bitbake-layers <command> [arguments]\n\n")
sys.stdout.write("Available commands:\n")
procnames = self.get_names()
for procname in procnames:
if procname[:3] == 'do_':
sys.stdout.write(" %s\n" % procname[3:])
sys.stdout.write(" %s\n" % procname[3:].replace('_', '-'))
doc = getattr(self, procname).__doc__
if doc:
sys.stdout.write(" %s\n" % doc.splitlines()[0])
@@ -108,34 +115,219 @@ class Commands(cmd.Cmd):
logger.plain('')
logger.plain("%s %s %s" % ("layer".ljust(20), "path".ljust(40), "priority"))
logger.plain('=' * 74)
layerdirs = str(self.config_data.getVar('BBLAYERS', True)).split()
for layerdir in layerdirs:
layername = '?'
for layerdir in self.bblayers:
layername = self.get_layer_name(layerdir)
layerpri = 0
for layer, _, regex, pri in self.cooker.status.bbfile_config_priorities:
if regex.match(os.path.join(layerdir, 'test')):
layername = layer
layerpri = pri
break
logger.plain("%s %s %d" % (layername.ljust(20), layerdir.ljust(40), layerpri))
def version_str(self, pe, pv, pr = None):
verstr = "%s" % pv
if pr:
verstr = "%s-%s" % (verstr, pr)
if pe:
verstr = "%s:%s" % (pe, verstr)
return verstr
def do_show_overlayed(self, args):
"""list overlayed recipes (where there is a recipe in another layer that has a higher layer priority)
"""list overlayed recipes (where the same recipe exists in another layer that has a higher layer priority)
usage: show_overlayed
usage: show-overlayed [-f] [-s]
Highest priority recipes are listed with the recipes they overlay as subitems.
Lists the names of overlayed recipes and the available versions in each
layer, with the preferred version first. Note that skipped recipes that
are overlayed will also be listed, with a " (skipped)" suffix.
Options:
-f instead of the default formatting, list filenames of higher priority
recipes with the ones they overlay indented underneath
-s only list overlayed recipes where the version is the same
"""
self.check_prepare_cooker()
if self.cooker.overlayed:
logger.plain('Overlayed recipes:')
for f in self.cooker.overlayed.iterkeys():
logger.plain('%s' % f)
for of in self.cooker.overlayed[f]:
logger.plain(' %s' % of)
else:
logger.plain('No overlayed recipes found')
show_filenames = False
show_same_ver_only = False
for arg in args.split():
if arg == '-f':
show_filenames = True
elif arg == '-s':
show_same_ver_only = True
else:
sys.stderr.write("show-overlayed: invalid option %s\n" % arg)
self.do_help('')
return
items_listed = self.list_recipes('Overlayed recipes', None, True, show_same_ver_only, show_filenames, True)
# Check for overlayed .bbclass files
classes = defaultdict(list)
for layerdir in self.bblayers:
classdir = os.path.join(layerdir, 'classes')
if os.path.exists(classdir):
for classfile in os.listdir(classdir):
if os.path.splitext(classfile)[1] == '.bbclass':
classes[classfile].append(classdir)
# Locating classes and other files is a bit more complicated than recipes -
# layer priority is not a factor; instead BitBake uses the first matching
# file in BBPATH, which is manipulated directly by each layer's
# conf/layer.conf in turn, thus the order of layers in bblayers.conf is a
# factor - however, each layer.conf is free to either prepend or append to
# BBPATH (or indeed do crazy stuff with it). Thus the order in BBPATH might
# not be exactly the order present in bblayers.conf either.
bbpath = str(self.config_data.getVar('BBPATH', True))
overlayed_class_found = False
for (classfile, classdirs) in classes.items():
if len(classdirs) > 1:
if not overlayed_class_found:
logger.plain('=== Overlayed classes ===')
overlayed_class_found = True
mainfile = bb.utils.which(bbpath, os.path.join('classes', classfile))
if show_filenames:
logger.plain('%s' % mainfile)
else:
# We effectively have to guess the layer here
logger.plain('%s:' % classfile)
mainlayername = '?'
for layerdir in self.bblayers:
classdir = os.path.join(layerdir, 'classes')
if mainfile.startswith(classdir):
mainlayername = self.get_layer_name(layerdir)
logger.plain(' %s' % mainlayername)
for classdir in classdirs:
fullpath = os.path.join(classdir, classfile)
if fullpath != mainfile:
if show_filenames:
print(' %s' % fullpath)
else:
print(' %s' % self.get_layer_name(os.path.dirname(classdir)))
if overlayed_class_found:
items_listed = True;
if not items_listed:
logger.note('No overlayed files found')
def do_show_recipes(self, args):
"""list available recipes, showing the layer they are provided by
usage: show-recipes [-f] [-m] [pnspec]
Lists the names of overlayed recipes and the available versions in each
layer, with the preferred version first. Optionally you may specify
pnspec to match a specified recipe name (supports wildcards). Note that
skipped recipes will also be listed, with a " (skipped)" suffix.
Options:
-f instead of the default formatting, list filenames of higher priority
recipes with other available recipes indented underneath
-m only list where multiple recipes (in the same layer or different
layers) exist for the same recipe name
"""
self.check_prepare_cooker()
show_filenames = False
show_multi_provider_only = False
pnspec = None
title = 'Available recipes:'
for arg in args.split():
if arg == '-f':
show_filenames = True
elif arg == '-m':
show_multi_provider_only = True
elif not arg.startswith('-'):
pnspec = arg
title = 'Available recipes matching %s:' % pnspec
else:
sys.stderr.write("show-recipes: invalid option %s\n" % arg)
self.do_help('')
return
self.list_recipes(title, pnspec, False, False, show_filenames, show_multi_provider_only)
def list_recipes(self, title, pnspec, show_overlayed_only, show_same_ver_only, show_filenames, show_multi_provider_only):
pkg_pn = self.cooker.status.pkg_pn
(latest_versions, preferred_versions) = bb.providers.findProviders(self.cooker.configuration.data, self.cooker.status, pkg_pn)
allproviders = bb.providers.allProviders(self.cooker.status)
# Ensure we list skipped recipes
# We are largely guessing about PN, PV and the preferred version here,
# but we have no choice since skipped recipes are not fully parsed
skiplist = self.cooker.skiplist.keys()
skiplist.sort( key=lambda fileitem: self.cooker.calc_bbfile_priority(fileitem) )
skiplist.reverse()
for fn in skiplist:
recipe_parts = os.path.splitext(os.path.basename(fn))[0].split('_')
p = recipe_parts[0]
if len(recipe_parts) > 1:
ver = (None, recipe_parts[1], None)
else:
ver = (None, 'unknown', None)
allproviders[p].append((ver, fn))
if not p in pkg_pn:
pkg_pn[p] = 'dummy'
preferred_versions[p] = (ver, fn)
def print_item(f, pn, ver, layer, ispref):
if f in skiplist:
skipped = ' (skipped)'
else:
skipped = ''
if show_filenames:
if ispref:
logger.plain("%s%s", f, skipped)
else:
logger.plain(" %s%s", f, skipped)
else:
if ispref:
logger.plain("%s:", pn)
logger.plain(" %s %s%s", layer.ljust(20), ver, skipped)
preffiles = []
items_listed = False
for p in sorted(pkg_pn):
if pnspec:
if not fnmatch.fnmatch(p, pnspec):
continue
if len(allproviders[p]) > 1 or not show_multi_provider_only:
pref = preferred_versions[p]
preffile = bb.cache.Cache.virtualfn2realfn(pref[1])[0]
if preffile not in preffiles:
preflayer = self.get_file_layer(preffile)
multilayer = False
same_ver = True
provs = []
for prov in allproviders[p]:
provfile = bb.cache.Cache.virtualfn2realfn(prov[1])[0]
provlayer = self.get_file_layer(provfile)
provs.append((provfile, provlayer, prov[0]))
if provlayer != preflayer:
multilayer = True
if prov[0] != pref[0]:
same_ver = False
if (multilayer or not show_overlayed_only) and (same_ver or not show_same_ver_only):
if not items_listed:
logger.plain('=== %s ===' % title)
items_listed = True
print_item(preffile, p, self.version_str(pref[0][0], pref[0][1]), preflayer, True)
for (provfile, provlayer, provver) in provs:
if provfile != preffile:
print_item(provfile, p, self.version_str(provver[0], provver[1]), provlayer, False)
# Ensure we don't show two entries for BBCLASSEXTENDed recipes
preffiles.append(preffile)
return items_listed
def do_flatten(self, args):
"""flattens layer configuration into a separate output directory.
@@ -179,22 +371,20 @@ build results (as the layer priority order has effectively changed).
return
self.check_prepare_cooker()
layers = (self.config_data.getVar('BBLAYERS', True) or "").split()
layers = self.bblayers
if len(arglist) > 2:
layernames = arglist[:-1]
found_layernames = []
found_layerdirs = []
for layerdir in layers:
for layername, _, regex, _ in self.cooker.status.bbfile_config_priorities:
if layername in layernames:
if regex.match(os.path.join(layerdir, 'test')):
found_layerdirs.append(layerdir)
found_layernames.append(layername)
break
layername = self.get_layer_name(layerdir)
if layername in layernames:
found_layerdirs.append(layerdir)
found_layernames.append(layername)
for layername in layernames:
if not layername in found_layernames:
logger.error('Unable to find layer %s in current configuration, please run "%s show_layers" to list configured layers' % (layername, os.path.basename(sys.argv[0])))
logger.error('Unable to find layer %s in current configuration, please run "%s show-layers" to list configured layers' % (layername, os.path.basename(sys.argv[0])))
return
layers = found_layerdirs
else:
@@ -266,10 +456,9 @@ build results (as the layer priority order has effectively changed).
first_regex = None
layerdir = layers[0]
for layername, pattern, regex, _ in self.cooker.status.bbfile_config_priorities:
if (not layernames) or layername in layernames:
if regex.match(os.path.join(layerdir, 'test')):
first_regex = regex
break
if regex.match(os.path.join(layerdir, 'test')):
first_regex = regex
break
if first_regex:
# Find the BBFILES entries that match (which will have come from this conf/layer.conf file)
@@ -295,17 +484,22 @@ build results (as the layer priority order has effectively changed).
if not entry_found:
logger.warning("File %s does not match the flattened layer's BBFILES setting, you may need to edit conf/layer.conf or move the file elsewhere" % f1full)
def get_append_layer(self, appendname):
def get_file_layer(self, filename):
for layer, _, regex, _ in self.cooker.status.bbfile_config_priorities:
if regex.match(appendname):
return layer
if regex.match(filename):
for layerdir in self.bblayers:
if regex.match(os.path.join(layerdir, 'test')):
return self.get_layer_name(layerdir)
return "?"
def get_layer_name(self, layerdir):
return os.path.basename(layerdir.rstrip(os.sep))
def apply_append(self, appendname, recipename):
appendfile = open(appendname, 'r')
recipefile = open(recipename, 'a')
recipefile.write('\n')
recipefile.write('##### bbappended from %s #####\n' % self.get_append_layer(appendname))
recipefile.write('##### bbappended from %s #####\n' % self.get_file_layer(appendname))
recipefile.writelines(appendfile.readlines())
recipefile.close()
appendfile.close()
@@ -313,7 +507,7 @@ build results (as the layer priority order has effectively changed).
def do_show_appends(self, args):
"""list bbappend files and recipe files they apply to
usage: show_appends
usage: show-appends
Recipes are listed with the bbappends that apply to them as subitems.
"""

View File

@@ -204,7 +204,7 @@ include</literal> directive.</para>
<section>
<title>Inheritance</title>
<para><emphasis>NOTE:</emphasis> This is only supported in .bb and .bbclass files.</para>
<para>The <literal>inherit</literal> directive is a means of specifying what classes of functionality your .bb requires. It is a rudimentary form of inheritance. For example, you can easily abstract out the tasks involved in building a package that uses autoconf and automake, and put that into a bbclass for your packages to make use of. A given bbclass is located by searching for classes/filename.oeclass in <envar>BBPATH</envar>, where filename is what you inherited.</para>
<para>The <literal>inherit</literal> directive is a means of specifying what classes of functionality your .bb requires. It is a rudimentary form of inheritance. For example, you can easily abstract out the tasks involved in building a package that uses autoconf and automake, and put that into a bbclass for your packages to make use of. A given bbclass is located by searching for classes/filename.bbclass in <envar>BBPATH</envar>, where filename is what you inherited.</para>
</section>
<section>
<title>Tasks</title>

View File

@@ -21,7 +21,7 @@
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
__version__ = "1.15.0"
__version__ = "1.15.1"
import sys
if sys.version_info < (2, 6, 0):

View File

@@ -53,7 +53,7 @@ class FuncFailed(Exception):
self.logfile = logfile
self.name = name
if name:
self.msg = "Function '%s' failed" % name
self.msg = 'Function failed: %s' % name
else:
self.msg = "Function failed"
@@ -91,9 +91,16 @@ class TaskSucceeded(TaskBase):
class TaskFailed(TaskBase):
"""Task execution failed"""
def __init__(self, task, logfile, metadata, errprinted = False):
self.logfile = logfile
self.errprinted = errprinted
super(TaskFailed, self).__init__(task, metadata)
class TaskFailedSilent(TaskBase):
"""Task execution failed (silently)"""
def __init__(self, task, logfile, metadata):
self.logfile = logfile
super(TaskFailed, self).__init__(task, metadata)
super(TaskFailedSilent, self).__init__(task, metadata)
class TaskInvalid(TaskBase):
@@ -152,8 +159,6 @@ def exec_func(func, d, dirs = None):
bb.utils.mkdirhier(adir)
ispython = flags.get('python')
if flags.get('fakeroot') and not flags.get('task'):
bb.fatal("Function %s specifies fakeroot but isn't a task?!" % func)
lockflag = flags.get('lockfiles')
if lockflag:
@@ -222,9 +227,10 @@ def exec_func_shell(function, d, runfile, cwd=None):
with open(runfile, 'w') as script:
script.write('#!/bin/sh -e\n')
if bb.msg.loggerDefaultVerbose:
script.write("set -x\n")
data.emit_func(function, script, d)
if bb.msg.loggerVerboseLogs:
script.write("set -x\n")
if cwd:
script.write("cd %s\n" % cwd)
script.write("%s\n" % function)
@@ -232,6 +238,10 @@ def exec_func_shell(function, d, runfile, cwd=None):
os.chmod(runfile, 0775)
cmd = runfile
if d.getVarFlag(function, 'fakeroot'):
fakerootcmd = d.getVar('FAKEROOT', True)
if fakerootcmd:
cmd = [fakerootcmd, runfile]
if bb.msg.loggerDefaultVerbose:
logfile = LogTee(logger, sys.stdout)
@@ -286,6 +296,13 @@ def _exec_task(fn, task, d, quieterr):
prefuncs = localdata.getVarFlag(task, 'prefuncs', expand=True)
postfuncs = localdata.getVarFlag(task, 'postfuncs', expand=True)
class ErrorCheckHandler(logging.Handler):
def __init__(self):
self.triggered = False
logging.Handler.__init__(self, logging.ERROR)
def emit(self, record):
self.triggered = True
# Handle logfiles
si = file('/dev/null', 'r')
try:
@@ -311,6 +328,9 @@ def _exec_task(fn, task, d, quieterr):
handler.setLevel(logging.DEBUG - 2)
bblogger.addHandler(handler)
errchk = ErrorCheckHandler()
bblogger.addHandler(errchk)
localdata.setVar('BB_LOGFILE', logfn)
event.fire(TaskStarted(task, localdata), localdata)
@@ -321,9 +341,12 @@ def _exec_task(fn, task, d, quieterr):
for func in (postfuncs or '').split():
exec_func(func, localdata)
except FuncFailed as exc:
if not quieterr:
if quieterr:
event.fire(TaskFailedSilent(task, logfn, localdata), localdata)
else:
errprinted = errchk.triggered
logger.error(str(exc))
event.fire(TaskFailed(task, logfn, localdata), localdata)
event.fire(TaskFailed(task, logfn, localdata, errprinted), localdata)
return 1
finally:
sys.stdout.flush()
@@ -366,7 +389,7 @@ def exec_task(fn, task, d):
if not quieterr:
logger.error("Build of %s failed" % (task))
logger.error(format_exc())
failedevent = TaskFailed(task, None, d)
failedevent = TaskFailed(task, None, d, True)
event.fire(failedevent, d)
return 1

View File

@@ -42,10 +42,10 @@ except ImportError:
logger.info("Importing cPickle failed. "
"Falling back to a very slow implementation.")
__cache_version__ = "142"
__cache_version__ = "143"
def getCacheFile(path, filename):
return os.path.join(path, filename)
def getCacheFile(path, filename, data_hash):
return os.path.join(path, filename + "." + data_hash)
# RecipeInfoCommon defines common data retrieving methods
# from meta data for caches. CoreRecipeInfo as well as other
@@ -137,9 +137,6 @@ class CoreRecipeInfo(RecipeInfoCommon):
self.rdepends_pkg = self.pkgvar('RDEPENDS', self.packages, metadata)
self.rrecommends_pkg = self.pkgvar('RRECOMMENDS', self.packages, metadata)
self.inherits = self.getvar('__inherit_cache', metadata)
self.summary = self.getvar('SUMMARY', metadata)
self.license = self.getvar('LICENSE', metadata)
self.section = self.getvar('SECTION', metadata)
self.fakerootenv = self.getvar('FAKEROOTENV', metadata)
self.fakerootdirs = self.getvar('FAKEROOTDIRS', metadata)
self.fakerootnoenv = self.getvar('FAKEROOTNOENV', metadata)
@@ -174,9 +171,6 @@ class CoreRecipeInfo(RecipeInfoCommon):
cachedata.basetaskhash = {}
cachedata.inherits = {}
cachedata.summary = {}
cachedata.license = {}
cachedata.section = {}
cachedata.fakerootenv = {}
cachedata.fakerootnoenv = {}
cachedata.fakerootdirs = {}
@@ -240,9 +234,6 @@ class CoreRecipeInfo(RecipeInfoCommon):
cachedata.basetaskhash[identifier] = taskhash
cachedata.inherits[fn] = self.inherits
cachedata.summary[fn] = self.summary
cachedata.license[fn] = self.license
cachedata.section[fn] = self.section
cachedata.fakerootenv[fn] = self.fakerootenv
cachedata.fakerootnoenv[fn] = self.fakerootnoenv
cachedata.fakerootdirs[fn] = self.fakerootdirs
@@ -254,7 +245,7 @@ class Cache(object):
BitBake Cache implementation
"""
def __init__(self, data, caches_array):
def __init__(self, data, data_hash, caches_array):
# Pass caches_array information into Cache Constructor
# It will be used in later for deciding whether we
# need extra cache file dump/load support
@@ -266,6 +257,7 @@ class Cache(object):
self.data = None
self.data_fn = None
self.cacheclean = True
self.data_hash = data_hash
if self.cachedir in [None, '']:
self.has_cache = False
@@ -274,26 +266,17 @@ class Cache(object):
return
self.has_cache = True
self.cachefile = getCacheFile(self.cachedir, "bb_cache.dat")
self.cachefile = getCacheFile(self.cachedir, "bb_cache.dat", self.data_hash)
logger.debug(1, "Using cache in '%s'", self.cachedir)
bb.utils.mkdirhier(self.cachedir)
# If any of configuration.data's dependencies are newer than the
# cache there isn't even any point in loading it...
newest_mtime = 0
deps = data.getVar("__base_depends")
old_mtimes = [old_mtime for _, old_mtime in deps]
old_mtimes.append(newest_mtime)
newest_mtime = max(old_mtimes)
cache_ok = True
if self.caches_array:
for cache_class in self.caches_array:
if type(cache_class) is type and issubclass(cache_class, RecipeInfoCommon):
cachefile = getCacheFile(self.cachedir, cache_class.cachefile)
cache_ok = cache_ok and (bb.parse.cached_mtime_noerror(cachefile) >= newest_mtime)
cachefile = getCacheFile(self.cachedir, cache_class.cachefile, self.data_hash)
cache_ok = cache_ok and os.path.exists(cachefile)
cache_class.init_cacheData(self)
if cache_ok:
self.load_cachefile()
@@ -327,7 +310,7 @@ class Cache(object):
# Calculate the correct cachesize of all those cache files
for cache_class in self.caches_array:
if type(cache_class) is type and issubclass(cache_class, RecipeInfoCommon):
cachefile = getCacheFile(self.cachedir, cache_class.cachefile)
cachefile = getCacheFile(self.cachedir, cache_class.cachefile, self.data_hash)
with open(cachefile, "rb") as cachefile:
cachesize += os.fstat(cachefile.fileno()).st_size
@@ -335,7 +318,7 @@ class Cache(object):
for cache_class in self.caches_array:
if type(cache_class) is type and issubclass(cache_class, RecipeInfoCommon):
cachefile = getCacheFile(self.cachedir, cache_class.cachefile)
cachefile = getCacheFile(self.cachedir, cache_class.cachefile, self.data_hash)
with open(cachefile, "rb") as cachefile:
pickled = pickle.Unpickler(cachefile)
while cachefile:
@@ -353,7 +336,7 @@ class Cache(object):
current_percent = 100 * current_progress / cachesize
if current_percent > previous_percent:
previous_percent = current_percent
bb.event.fire(bb.event.CacheLoadProgress(current_progress),
bb.event.fire(bb.event.CacheLoadProgress(current_progress, cachesize),
self.data)
previous_progress += current_progress
@@ -588,7 +571,7 @@ class Cache(object):
for cache_class in self.caches_array:
if type(cache_class) is type and issubclass(cache_class, RecipeInfoCommon):
cache_class_name = cache_class.__name__
cachefile = getCacheFile(self.cachedir, cache_class.cachefile)
cachefile = getCacheFile(self.cachedir, cache_class.cachefile, self.data_hash)
file_dict[cache_class_name] = open(cachefile, "wb")
pickler_dict[cache_class_name] = pickle.Pickler(file_dict[cache_class_name], pickle.HIGHEST_PROTOCOL)
@@ -693,7 +676,7 @@ def init(cooker):
Files causing parsing errors are evicted from the cache.
"""
return Cache(cooker.configuration.data)
return Cache(cooker.configuration.data, cooker.configuration.data_hash)
class CacheData(object):

View File

@@ -40,6 +40,7 @@ class HobRecipeInfo(RecipeInfoCommon):
self.summary = self.getvar('SUMMARY', metadata)
self.license = self.getvar('LICENSE', metadata)
self.section = self.getvar('SECTION', metadata)
self.description = self.getvar('DESCRIPTION', metadata)
@classmethod
def init_cacheData(cls, cachedata):
@@ -47,8 +48,10 @@ class HobRecipeInfo(RecipeInfoCommon):
cachedata.summary = {}
cachedata.license = {}
cachedata.section = {}
cachedata.description = {}
def add_cacheData(self, cachedata, fn):
cachedata.summary[fn] = self.summary
cachedata.license[fn] = self.license
cachedata.section[fn] = self.section
cachedata.description[fn] = self.description

View File

@@ -173,6 +173,18 @@ class CommandsSync:
"""
command.cooker.reset()
def getCpuCount(self, command, params):
"""
Get the CPU count on the bitbake server
"""
return bb.utils.cpu_count()
def triggerEvent(self, command, params):
"""
Trigger a certain event
"""
event = params[0]
bb.event.fire(eval(event), command.cooker.configuration.data)
class CommandsAsync:
"""
@@ -230,14 +242,21 @@ class CommandsAsync:
included in the package list.
If pkg_list provided use that list (plus any extras brought in by
klass) rather than generating a tree for all packages.
Add a new option "resolve" to indicate if we need to resolve the
replacement for "virtual/xxx" like pn.
"""
klass = params[0]
if len(params) > 1:
resolve = False
if len(params) > 2:
pkg_list = params[1]
resolve = params[2]
elif len(params) > 1:
pkg_list = params[1]
else:
pkg_list = []
command.cooker.generateTargetsTree(klass, pkg_list)
command.cooker.generateTargetsTree(klass, pkg_list, resolve)
command.finishAsyncCommand()
generateTargetsTree.needcache = True

View File

@@ -36,6 +36,7 @@ from functools import wraps
from collections import defaultdict
import bb, bb.exceptions, bb.command
from bb import utils, data, parse, event, cache, providers, taskdata, runqueue
import Queue
import prserv.serv
logger = logging.getLogger("BitBake")
@@ -44,9 +45,9 @@ buildlog = logging.getLogger("BitBake.Build")
parselog = logging.getLogger("BitBake.Parsing")
providerlog = logging.getLogger("BitBake.Provider")
class MultipleMatches(Exception):
class NoSpecificMatch(bb.BBHandledException):
"""
Exception raised when multiple file matches are found
Exception raised when no or multiple file matches are found
"""
class NothingToBuild(Exception):
@@ -54,6 +55,11 @@ class NothingToBuild(Exception):
Exception raised when there is nothing to build
"""
class CollectionError(bb.BBHandledException):
"""
Exception raised when layer configuration is incorrect
"""
class state:
initial, parsing, running, shutdown, stop = range(5)
@@ -200,6 +206,10 @@ class BBCooker:
def parseConfiguration(self):
# Set log file verbosity
verboselogs = bb.utils.to_boolean(self.configuration.data.getVar("BB_VERBOSE_LOGS", "0"))
if verboselogs:
bb.msg.loggerVerboseLogs = True
# Change nice level if we're asked to
nice = self.configuration.data.getVar("BB_NICE_LEVEL", True)
@@ -258,20 +268,8 @@ class BBCooker:
# Need files parsed
self.updateCache()
# Need to ensure data store is expanded
localdata = data.createCopy(self.configuration.data)
bb.data.update_data(localdata)
bb.data.expandKeys(localdata)
pkg_pn = self.status.pkg_pn
preferred_versions = {}
latest_versions = {}
# Sort by priority
for pn in pkg_pn:
(last_ver, last_file, pref_ver, pref_file) = bb.providers.findBestProvider(pn, localdata, self.status)
preferred_versions[pn] = (pref_ver, pref_file)
latest_versions[pn] = (last_ver, last_file)
(latest_versions, preferred_versions) = bb.providers.findProviders(self.configuration.data, self.status, pkg_pn)
logger.plain("%-35s %25s %25s", "Package Name", "Latest Version", "Preferred Version")
logger.plain("%-35s %25s %25s\n", "============", "==============", "=================")
@@ -345,6 +343,7 @@ class BBCooker:
"""
Prepare a runqueue and taskdata object for iteration over pkgs_to_build
"""
bb.event.fire(bb.event.TreeDataPreparationStarted(), self.configuration.data)
# Need files parsed
self.updateCache()
# If we are told to do the None task then query the default task
@@ -361,11 +360,14 @@ class BBCooker:
taskdata = bb.taskdata.TaskData(False, skiplist=self.skiplist)
runlist = []
current = 0
for k in pkgs_to_build:
taskdata.add_provider(localdata, self.status, k)
runlist.append([k, "do_%s" % task])
current += 1
bb.event.fire(bb.event.TreeDataPreparationProgress(current, len(pkgs_to_build)), self.configuration.data)
taskdata.add_unresolved(localdata, self.status)
bb.event.fire(bb.event.TreeDataPreparationCompleted(len(pkgs_to_build)), self.configuration.data)
return runlist, taskdata
def generateTaskDepTreeData(self, pkgs_to_build, task):
@@ -440,7 +442,20 @@ class BBCooker:
return depend_tree
def generatePkgDepTreeData(self, pkgs_to_build, task):
def append_package(self, taskdata, depend_tree_package, package):
if package not in depend_tree_package:
targetid = taskdata.getrun_id(package)
if targetid in taskdata.run_targets and taskdata.run_targets[targetid]:
fnid = taskdata.run_targets[targetid][0]
fn = taskdata.fn_index[fnid]
pn = self.status.pkg_fn[fn]
version = "%s:%s-%s" % self.status.pkg_pepvpr[fn]
depend_tree_package[package] = {}
depend_tree_package[package]["pn"] = pn
depend_tree_package[package]["filename"] = fn
depend_tree_package[package]["version"] = version
def generatePkgDepTreeData(self, pkgs_to_build, task, resolve=False):
"""
Create a dependency tree of pkgs_to_build, returning the data.
"""
@@ -457,6 +472,7 @@ class BBCooker:
depend_tree["rdepends-pn"] = {}
depend_tree["packages"] = {}
depend_tree["rdepends-pkg"] = {}
depend_tree["rrecs-pkg"] = {}
for task in xrange(len(tasks_fnid)):
fnid = tasks_fnid[task]
@@ -466,6 +482,9 @@ class BBCooker:
summary = self.status.summary[fn]
lic = self.status.license[fn]
section = self.status.section[fn]
description = self.status.description[fn]
rdepends = self.status.rundeps[fn]
rrecs = self.status.runrecs[fn]
if pn not in depend_tree["pn"]:
depend_tree["pn"][pn] = {}
depend_tree["pn"][pn]["filename"] = fn
@@ -473,6 +492,8 @@ class BBCooker:
depend_tree["pn"][pn]["summary"] = summary
depend_tree["pn"][pn]["license"] = lic
depend_tree["pn"][pn]["section"] = section
depend_tree["pn"][pn]["description"] = description
depend_tree["pn"][pn]["packages"] = rdepends.keys()
if fnid not in seen_fnids:
seen_fnids.append(fnid)
@@ -480,25 +501,44 @@ class BBCooker:
depend_tree["depends"][pn] = []
for dep in taskdata.depids[fnid]:
depend_tree["depends"][pn].append(taskdata.build_names_index[dep])
if resolve:
item = taskdata.build_names_index[dep]
pn_provider = ""
targetid = taskdata.getbuild_id(item)
if targetid in taskdata.build_targets and taskdata.build_targets[targetid]:
fnid = taskdata.build_targets[targetid][0]
fn_provider = taskdata.fn_index[fnid]
pn_provider = self.status.pkg_fn[fn_provider]
else:
pn_provider = item
depend_tree["depends"][pn].append(pn_provider)
else:
depend_tree["depends"][pn].append(taskdata.build_names_index[dep])
depend_tree["rdepends-pn"][pn] = []
for rdep in taskdata.rdepids[fnid]:
depend_tree["rdepends-pn"][pn].append(taskdata.run_names_index[rdep])
rdepends = self.status.rundeps[fn]
for package in rdepends:
depend_tree["rdepends-pkg"][package] = []
for rdepend in rdepends[package]:
depend_tree["rdepends-pkg"][package].append(rdepend)
packages.append(package)
if resolve:
self.append_package(taskdata, depend_tree["packages"], rdepend)
if not package in packages:
packages.append(package)
for package in rrecs:
depend_tree["rrecs-pkg"][package] = []
for rrec in rrecs[package]:
depend_tree["rrecs-pkg"][package].append(rrec)
if resolve:
self.append_package(taskdata, depend_tree["packages"], rrec)
if not package in packages:
packages.append(package)
for package in packages:
if package not in depend_tree["packages"]:
depend_tree["packages"][package] = {}
depend_tree["packages"][package]["pn"] = pn
depend_tree["packages"][package]["filename"] = fn
depend_tree["packages"][package]["version"] = version
self.append_package(taskdata, depend_tree["packages"], package)
return depend_tree
@@ -744,7 +784,7 @@ class BBCooker:
return pkg_list
def generateTargetsTree(self, klass=None, pkgs=[]):
def generateTargetsTree(self, klass=None, pkgs=[], resolve=False):
"""
Generate a dependency tree of buildable targets
Generate an event with the result
@@ -759,7 +799,7 @@ class BBCooker:
pkgs = pkgs + extra_pkgs
# generate a dependency tree for all our packages
tree = self.generatePkgDepTreeData(pkgs, 'build')
tree = self.generatePkgDepTreeData(pkgs, 'build', resolve)
bb.event.fire(bb.event.TargetsTreeGenerated(tree), self.configuration.data)
def buildWorldTargetList(self):
@@ -855,12 +895,15 @@ class BBCooker:
if data.getVar("BB_WORKERCONTEXT", False) is None:
bb.fetch.fetcher_init(data)
bb.codeparser.parser_cache_init(data)
bb.parse.init_parser(data)
bb.event.fire(bb.event.ConfigParsed(), data)
bb.parse.init_parser(data)
data.setVar('BBINCLUDED',bb.parse.get_file_depends(data))
self.configuration.data = data
self.configuration.data_hash = data.get_hash()
def handleCollections( self, collections ):
"""Handle collections"""
errors = False
self.status.bbfile_config_priorities = []
if collections:
collection_priorities = {}
@@ -875,6 +918,7 @@ class BBCooker:
prio = int(priority)
except ValueError:
parselog.error("invalid value for BBFILE_PRIORITY_%s: \"%s\"", c, priority)
errors = True
if min_prio == 0 or prio < min_prio:
min_prio = prio
collection_priorities[c] = prio
@@ -893,6 +937,7 @@ class BBCooker:
depver = int(depsplit[1])
except ValueError:
parselog.error("invalid version value in LAYERDEPENDS_%s: \"%s\"", c, dep)
errors = True
continue
else:
depver = None
@@ -907,13 +952,17 @@ class BBCooker:
lver = int(layerver)
except ValueError:
parselog.error("invalid value for LAYERVERSION_%s: \"%s\"", c, layerver)
errors = True
continue
if lver <> depver:
parselog.error("Layer dependency %s of layer %s is at version %d, expected %d", dep, c, lver, depver)
errors = True
else:
parselog.error("Layer dependency %s of layer %s has no version, expected %d", dep, c, depver)
errors = True
else:
parselog.error("Layer dependency %s of layer %s not found", dep, c)
errors = True
collection_depends[c] = depnamelist
else:
collection_depends[c] = []
@@ -937,13 +986,18 @@ class BBCooker:
regex = self.configuration.data.getVar("BBFILE_PATTERN_%s" % c, 1)
if regex == None:
parselog.error("BBFILE_PATTERN_%s not defined" % c)
errors = True
continue
try:
cre = re.compile(regex)
except re.error:
parselog.error("BBFILE_PATTERN_%s \"%s\" is not a valid regular expression", c, regex)
errors = True
continue
self.status.bbfile_config_priorities.append((c, regex, cre, collection_priorities[c]))
if errors:
# We've already printed the actual error(s)
raise CollectionError("Errors during parsing layer configuration")
def buildSetVars(self):
"""
@@ -979,10 +1033,15 @@ class BBCooker:
"""
matches = self.matchFiles(buildfile)
if len(matches) != 1:
parselog.error("Unable to match %s (%s matches found):" % (buildfile, len(matches)))
for f in matches:
parselog.error(" %s" % f)
raise MultipleMatches
if matches:
msg = "Unable to match '%s' to a specific recipe file - %s matches found:" % (buildfile, len(matches))
if matches:
for f in matches:
msg += "\n %s" % f
parselog.error(msg)
else:
parselog.error("Unable to find any recipe file matching '%s'" % buildfile)
raise NoSpecificMatch
return matches[0]
def buildFile(self, buildfile, task):
@@ -1060,8 +1119,6 @@ class BBCooker:
try:
retval = rq.execute_runqueue()
except runqueue.TaskFailure as exc:
for fnid in exc.args:
buildlog.error("'%s' failed" % taskdata.fn_index[fnid])
failures += len(exc.args)
retval = False
except SystemExit as exc:
@@ -1069,7 +1126,7 @@ class BBCooker:
return False
if not retval:
bb.event.fire(bb.event.BuildCompleted(buildname, item, failures), self.configuration.event_data)
bb.event.fire(bb.event.BuildCompleted(len(rq.rqdata.runq_fnid), buildname, item, failures), self.configuration.event_data)
self.command.finishAsyncCommand()
return False
if retval is True:
@@ -1090,6 +1147,7 @@ class BBCooker:
if (task == None):
task = self.configuration.cmd
universe = ('universe' in targets)
targets = self.checkPackages(targets)
def buildTargetsIdle(server, rq, abort):
@@ -1101,8 +1159,6 @@ class BBCooker:
try:
retval = rq.execute_runqueue()
except runqueue.TaskFailure as exc:
for fnid in exc.args:
buildlog.error("'%s' failed" % taskdata.fn_index[fnid])
failures += len(exc.args)
retval = False
except SystemExit as exc:
@@ -1110,7 +1166,7 @@ class BBCooker:
return False
if not retval:
bb.event.fire(bb.event.BuildCompleted(buildname, targets, failures), self.configuration.data)
bb.event.fire(bb.event.BuildCompleted(len(rq.rqdata.runq_fnid), buildname, targets, failures), self.configuration.data)
self.command.finishAsyncCommand()
return False
if retval is True:
@@ -1135,6 +1191,8 @@ class BBCooker:
taskdata.add_unresolved(localdata, self.status)
rq = bb.runqueue.RunQueue(self, self.configuration.data, self.status, taskdata, runlist)
if universe:
rq.rqdata.warn_multi_bb = True
self.server_registration_cb(buildTargetsIdle, rq)
@@ -1188,6 +1246,7 @@ class BBCooker:
pkgs_to_build.append(t)
if 'universe' in pkgs_to_build:
parselog.warn("The \"universe\" target is only intended for testing and may produce errors.")
parselog.debug(1, "collating packages for \"universe\"")
pkgs_to_build.remove('universe')
for t in self.status.universe_target:
@@ -1402,7 +1461,7 @@ def _parse(fn, data, include=True):
@catch_parse_error
def _inherit(bbclass, data):
bb.parse.BBHandler.inherit([bbclass], data)
bb.parse.BBHandler.inherit([bbclass], "configuration INHERITs", 0, data)
return data
class ParsingFailure(Exception):
@@ -1411,26 +1470,94 @@ class ParsingFailure(Exception):
self.recipe = recipe
Exception.__init__(self, realexception, recipe)
def parse_file(task):
filename, appends, caches_array = task
try:
return True, bb.cache.Cache.parse(filename, appends, parse_file.cfg, caches_array)
except Exception as exc:
tb = sys.exc_info()[2]
exc.recipe = filename
exc.traceback = list(bb.exceptions.extract_traceback(tb, context=3))
raise exc
# Need to turn BaseExceptions into Exceptions here so we gracefully shutdown
# and for example a worker thread doesn't just exit on its own in response to
# a SystemExit event for example.
except BaseException as exc:
raise ParsingFailure(exc, filename)
class Feeder(multiprocessing.Process):
def __init__(self, jobs, to_parsers, quit):
self.quit = quit
self.jobs = jobs
self.to_parsers = to_parsers
multiprocessing.Process.__init__(self)
def run(self):
while True:
try:
quit = self.quit.get_nowait()
except Queue.Empty:
pass
else:
if quit == 'cancel':
self.to_parsers.cancel_join_thread()
break
try:
job = self.jobs.pop()
except IndexError:
break
try:
self.to_parsers.put(job, timeout=0.5)
except Queue.Full:
self.jobs.insert(0, job)
continue
class Parser(multiprocessing.Process):
def __init__(self, jobs, results, quit, init):
self.jobs = jobs
self.results = results
self.quit = quit
self.init = init
multiprocessing.Process.__init__(self)
def run(self):
if self.init:
self.init()
pending = []
while True:
try:
self.quit.get_nowait()
except Queue.Empty:
pass
else:
self.results.cancel_join_thread()
break
if pending:
result = pending.pop()
else:
try:
job = self.jobs.get(timeout=0.25)
except Queue.Empty:
continue
if job is None:
break
result = self.parse(*job)
try:
self.results.put(result, timeout=0.25)
except Queue.Full:
pending.append(result)
def parse(self, filename, appends, caches_array):
try:
return True, bb.cache.Cache.parse(filename, appends, self.cfg, caches_array)
except Exception as exc:
tb = sys.exc_info()[2]
exc.recipe = filename
exc.traceback = list(bb.exceptions.extract_traceback(tb, context=3))
return True, exc
# Need to turn BaseExceptions into Exceptions here so we gracefully shutdown
# and for example a worker thread doesn't just exit on its own in response to
# a SystemExit event for example.
except BaseException as exc:
return True, ParsingFailure(exc, filename)
class CookerParser(object):
def __init__(self, cooker, filelist, masked):
self.filelist = filelist
self.cooker = cooker
self.cfgdata = cooker.configuration.data
self.cfghash = cooker.configuration.data_hash
# Accounting statistics
self.parsed = 0
@@ -1446,7 +1573,7 @@ class CookerParser(object):
self.num_processes = int(self.cfgdata.getVar("BB_NUMBER_PARSE_THREADS", True) or
multiprocessing.cpu_count())
self.bb_cache = bb.cache.Cache(self.cfgdata, cooker.caches_array)
self.bb_cache = bb.cache.Cache(self.cfgdata, self.cfghash, cooker.caches_array)
self.fromcache = []
self.willparse = []
for filename in self.filelist:
@@ -1461,22 +1588,28 @@ class CookerParser(object):
self.start()
def start(self):
def init(cfg):
parse_file.cfg = cfg
multiprocessing.util.Finalize(None, bb.codeparser.parser_cache_save, args=(self.cooker.configuration.data, ), exitpriority=1)
self.results = self.load_cached()
self.processes = []
if self.toparse:
bb.event.fire(bb.event.ParseStarted(self.toparse), self.cfgdata)
def init():
Parser.cfg = self.cfgdata
multiprocessing.util.Finalize(None, bb.codeparser.parser_cache_save, args=(self.cfgdata,), exitpriority=1)
self.pool = multiprocessing.Pool(self.num_processes, init, [self.cfgdata])
parsed = self.pool.imap(parse_file, self.willparse)
self.pool.close()
self.feeder_quit = multiprocessing.Queue(maxsize=1)
self.parser_quit = multiprocessing.Queue(maxsize=self.num_processes)
self.jobs = multiprocessing.Queue(maxsize=self.num_processes)
self.result_queue = multiprocessing.Queue()
self.feeder = Feeder(self.willparse, self.jobs, self.feeder_quit)
self.feeder.start()
for i in range(0, self.num_processes):
parser = Parser(self.jobs, self.result_queue, self.parser_quit, init)
parser.start()
self.processes.append(parser)
self.results = itertools.chain(self.results, parsed)
self.results = itertools.chain(self.results, self.parse_generator())
def shutdown(self, clean=True):
def shutdown(self, clean=True, force=False):
if not self.toparse:
return
@@ -1486,9 +1619,22 @@ class CookerParser(object):
self.virtuals, self.error,
self.total)
bb.event.fire(event, self.cfgdata)
self.feeder_quit.put(None)
for process in self.processes:
self.jobs.put(None)
else:
self.pool.terminate()
self.pool.join()
self.feeder_quit.put('cancel')
self.parser_quit.cancel_join_thread()
for process in self.processes:
self.parser_quit.put(None)
self.jobs.cancel_join_thread()
sys.exit(1)
for process in self.processes:
process.join()
self.feeder.join()
sync = threading.Thread(target=self.bb_cache.sync)
sync.start()
@@ -1500,6 +1646,22 @@ class CookerParser(object):
cached, infos = self.bb_cache.load(filename, appends, self.cfgdata)
yield not cached, infos
def parse_generator(self):
while True:
if self.parsed >= self.toparse:
break
try:
result = self.result_queue.get(timeout=0.25)
except Queue.Empty:
pass
else:
value = result[1]
if isinstance(value, BaseException):
raise value
else:
yield result
def parse_next(self):
try:
parsed, result = self.results.next()
@@ -1507,27 +1669,27 @@ class CookerParser(object):
self.shutdown()
return False
except ParsingFailure as exc:
self.shutdown(clean=False)
bb.fatal('Unable to parse %s: %s' %
logger.error('Unable to parse %s: %s' %
(exc.recipe, bb.exceptions.to_string(exc.realexception)))
self.shutdown(clean=False)
except (bb.parse.ParseError, bb.data_smart.ExpansionError) as exc:
bb.fatal(str(exc))
logger.error(str(exc))
self.shutdown(clean=False)
except SyntaxError as exc:
logger.error('Unable to parse %s', exc.recipe)
sys.exit(1)
self.shutdown(clean=False)
except Exception as exc:
etype, value, tb = sys.exc_info()
logger.error('Unable to parse %s', value.recipe,
exc_info=(etype, value, exc.traceback))
self.shutdown(clean=False)
sys.exit(1)
self.current += 1
self.virtuals += len(result)
if parsed:
self.parsed += 1
if self.parsed % self.progress_chunk == 0:
bb.event.fire(bb.event.ParseProgress(self.parsed),
bb.event.fire(bb.event.ParseProgress(self.parsed, self.toparse),
self.cfgdata)
else:
self.cached += 1

View File

@@ -333,7 +333,7 @@ def generate_dependencies(d):
deps[dep], values[dep] = build_dependencies(dep, keys, shelldeps, vardepvals, d)
newdeps |= deps[dep]
newdeps -= seen
#print "For %s: %s" % (task, str(taskdeps[task]))
#print "For %s: %s" % (task, str(deps[task]))
return tasklist, deps, values
def inherits_class(klass, d):

View File

@@ -31,6 +31,7 @@ BitBake build tools.
import copy, re
from collections import MutableMapping
import logging
import hashlib
import bb, bb.codeparser
from bb import utils
from bb.COW import COWDictBase
@@ -459,3 +460,15 @@ class DataSmart(MutableMapping):
def __delitem__(self, var):
self.delVar(var)
def get_hash(self):
data = ""
config_whitelist = set((self.getVar("BB_HASHCONFIG_WHITELIST", True) or "").split())
keys = set(key for key in iter(self) if not key.startswith("__"))
for key in keys:
if key in config_whitelist:
continue
value = self.getVar(key, False) or ""
data = data + key + ': ' + str(value) + '\n'
return hashlib.md5(data).hexdigest()

View File

@@ -204,6 +204,27 @@ def getName(e):
else:
return e.__name__
class OperationStarted(Event):
"""An operation has begun"""
def __init__(self, msg = "Operation Started"):
Event.__init__(self)
self.msg = msg
class OperationCompleted(Event):
"""An operation has completed"""
def __init__(self, total, msg = "Operation Completed"):
Event.__init__(self)
self.total = total
self.msg = msg
class OperationProgress(Event):
"""An operation is in progress"""
def __init__(self, current, total, msg = "Operation in Progress"):
Event.__init__(self)
self.current = current
self.total = total
self.msg = msg + ": %s/%s" % (current, total);
class ConfigParsed(Event):
"""Configuration Parsing Complete"""
@@ -276,14 +297,20 @@ class BuildBase(Event):
class BuildStarted(BuildBase):
class BuildStarted(BuildBase, OperationStarted):
"""bbmake build run started"""
def __init__(self, n, p, failures = 0):
OperationStarted.__init__(self, "Building Started")
BuildBase.__init__(self, n, p, failures)
class BuildCompleted(BuildBase):
class BuildCompleted(BuildBase, OperationCompleted):
"""bbmake build run completed"""
def __init__(self, total, n, p, failures = 0):
if not failures:
OperationCompleted.__init__(self, total, "Building Succeeded")
else:
OperationCompleted.__init__(self, total, "Building Failed")
BuildBase.__init__(self, n, p, failures)
class NoProvider(Event):
@@ -329,17 +356,16 @@ class MultipleProviders(Event):
"""
return self._candidates
class ParseStarted(Event):
class ParseStarted(OperationStarted):
"""Recipe parsing for the runqueue has begun"""
def __init__(self, total):
Event.__init__(self)
OperationStarted.__init__(self, "Recipe parsing Started")
self.total = total
class ParseCompleted(Event):
class ParseCompleted(OperationCompleted):
"""Recipe parsing for the runqueue has completed"""
def __init__(self, cached, parsed, skipped, masked, virtuals, errors, total):
Event.__init__(self)
OperationCompleted.__init__(self, total, "Recipe parsing Completed")
self.cached = cached
self.parsed = parsed
self.skipped = skipped
@@ -347,33 +373,44 @@ class ParseCompleted(Event):
self.masked = masked
self.errors = errors
self.sofar = cached + parsed
self.total = total
class ParseProgress(Event):
class ParseProgress(OperationProgress):
"""Recipe parsing progress"""
def __init__(self, current, total):
OperationProgress.__init__(self, current, total, "Recipe parsing")
def __init__(self, current):
self.current = current
class CacheLoadStarted(Event):
class CacheLoadStarted(OperationStarted):
"""Loading of the dependency cache has begun"""
def __init__(self, total):
Event.__init__(self)
OperationStarted.__init__(self, "Loading cache Started")
self.total = total
class CacheLoadProgress(Event):
class CacheLoadProgress(OperationProgress):
"""Cache loading progress"""
def __init__(self, current):
Event.__init__(self)
self.current = current
def __init__(self, current, total):
OperationProgress.__init__(self, current, total, "Loading cache")
class CacheLoadCompleted(Event):
class CacheLoadCompleted(OperationCompleted):
"""Cache loading is complete"""
def __init__(self, total, num_entries):
Event.__init__(self)
self.total = total
OperationCompleted.__init__(self, total, "Loading cache Completed")
self.num_entries = num_entries
class TreeDataPreparationStarted(OperationStarted):
"""Tree data preparation started"""
def __init__(self):
OperationStarted.__init__(self, "Preparing tree data Started")
class TreeDataPreparationProgress(OperationProgress):
"""Tree data preparation is in progress"""
def __init__(self, current, total):
OperationProgress.__init__(self, current, total, "Preparing tree data")
class TreeDataPreparationCompleted(OperationCompleted):
"""Tree data preparation completed"""
def __init__(self, total):
OperationCompleted.__init__(self, total, "Preparing tree data Completed")
class DepTreeGenerated(Event):
"""
@@ -467,3 +504,16 @@ class LogHandler(logging.Handler):
def filter(self, record):
record.taskpid = worker_pid
return True
class RequestPackageInfo(Event):
"""
Event to request package information
"""
class PackageInfo(Event):
"""
Package information for GUI
"""
def __init__(self, pkginfolist):
Event.__init__(self)
self._pkginfolist = pkginfolist

View File

@@ -55,7 +55,10 @@ class MalformedUrl(BBFetchException):
class FetchError(BBFetchException):
"""General fetcher exception when something happens incorrectly"""
def __init__(self, message, url = None):
msg = "Fetcher failure for URL: '%s'. %s" % (url, message)
if url:
msg = "Fetcher failure for URL: '%s'. %s" % (url, message)
else:
msg = "Fetcher failure: %s" % message
self.url = url
BBFetchException.__init__(self, msg)
self.args = (message, url)
@@ -302,10 +305,10 @@ def verify_checksum(u, ud, d):
# it does not match.
msg = ""
if md5mismatch and ud.md5_expected:
msg = msg + "\nFile: '%s' has %s checksum %s when %s was expected (from URL: '%s')" % (ud.localpath, 'md5', md5data, ud.md5_expected, u)
msg = msg + "\nFile: '%s' has %s checksum %s when %s was expected" % (ud.localpath, 'md5', md5data, ud.md5_expected)
if sha256mismatch and ud.sha256_expected:
msg = msg + "\nFile: '%s' has %s checksum %s when %s was expected (from URL: '%s')" % (ud.localpath, 'sha256', sha256data, ud.sha256_expected, u)
msg = msg + "\nFile: '%s' has %s checksum %s when %s was expected" % (ud.localpath, 'sha256', sha256data, ud.sha256_expected)
if len(msg):
raise FetchError('Checksum mismatch!%s' % msg, u)
@@ -419,8 +422,11 @@ def runfetchcmd(cmd, d, quiet = False, cleanup = []):
output += line
status = stdout_handle.close() or 0
signal = status >> 8
exitstatus = status & 0xff
signal = os.WTERMSIG(status)
if os.WIFEXITED(status):
exitstatus = os.WEXITSTATUS(status)
else:
exitstatus = 0
if (signal or status != 0):
for f in cleanup:
@@ -431,8 +437,8 @@ def runfetchcmd(cmd, d, quiet = False, cleanup = []):
if signal:
raise FetchError("Fetch command %s failed with signal %s, output:\n%s" % (cmd, signal, output))
elif status != 0:
raise FetchError("Fetch command %s failed with exit code %s, output:\n%s" % (cmd, status, output))
elif exitstatus:
raise FetchError("Fetch command %s failed with exit code %s, output:\n%s" % (cmd, exitstatus, output))
return output
@@ -473,7 +479,7 @@ def try_mirrors(d, origud, mirrors, check = False):
return found
continue
if ud.method.need_update(newuri, ud, ld):
if not os.path.exists(ud.donestamp) or ud.method.need_update(newuri, ud, ld):
ud.method.download(newuri, ud, ld)
if hasattr(ud.method,"build_mirror_data"):
ud.method.build_mirror_data(newuri, ud, ld)
@@ -949,7 +955,7 @@ class Fetch(object):
try:
self.d.setVar("BB_NO_NETWORK", network)
if not m.need_update(u, ud, self.d):
if os.path.exists(ud.donestamp) and not m.need_update(u, ud, self.d):
localpath = ud.localpath
elif m.try_premirror(u, ud, self.d):
logger.debug(1, "Trying PREMIRRORS")
@@ -959,7 +965,8 @@ class Fetch(object):
if premirroronly:
self.d.setVar("BB_NO_NETWORK", "1")
if not localpath and m.need_update(u, ud, self.d):
firsterr = None
if not localpath and ((not os.path.exists(ud.donestamp)) or m.need_update(u, ud, self.d)):
try:
logger.debug(1, "Trying Upstream")
m.download(u, ud, self.d)
@@ -974,7 +981,9 @@ class Fetch(object):
raise
except BBFetchException as e:
logger.warn(str(e))
logger.warn('Failed to fetch URL %s' % u)
logger.debug(1, str(e))
firsterr = e
# Remove any incomplete fetch
if os.path.isfile(ud.localpath):
bb.utils.remove(ud.localpath)
@@ -983,7 +992,9 @@ class Fetch(object):
localpath = try_mirrors (self.d, ud, mirrors)
if not localpath or ((not os.path.exists(localpath)) and localpath.find("*") == -1):
raise FetchError("Unable to fetch URL %s from any source." % u, u)
if firsterr:
logger.error(str(firsterr))
raise FetchError("Unable to fetch URL from any source.", u)
update_stamp(u, ud, self.d)

View File

@@ -38,6 +38,12 @@ Supported SRC_URI options are:
who has its own routine to checkout code.
The default is "0", set nocheckout=1 if needed.
- bareclone
Create a bare clone of the source code and don't checkout the source code
when unpacking. Set this option for the recipe who has its own routine to
checkout code and tracking branch requirements.
The default is "0", set bareclone=1 if needed.
"""
#Copyright (C) 2005 Richard Purdie
@@ -95,6 +101,11 @@ class Git(FetchMethod):
ud.rebaseable = ud.parm.get("rebaseable","0") == "1"
# bareclone implies nocheckout
ud.bareclone = ud.parm.get("bareclone","0") == "1"
if ud.bareclone:
ud.nocheckout = 1
branches = ud.parm.get("branch", "master").split(',')
if len(branches) != len(ud.names):
raise bb.fetch2.ParameterError("The number of name and branch parameters is not balanced", ud.url)
@@ -220,7 +231,11 @@ class Git(FetchMethod):
if os.path.exists(destdir):
bb.utils.prunedir(destdir)
runfetchcmd("git clone -s -n %s %s" % (ud.clonedir, destdir), d)
cloneflags = "-s -n"
if ud.bareclone:
cloneflags += " --mirror"
runfetchcmd("git clone %s %s/ %s" % (cloneflags, ud.clonedir, destdir), d)
if not ud.nocheckout:
os.chdir(destdir)
if subdir != "":

View File

@@ -0,0 +1,237 @@
#!/usr/bin/env python
# ex:ts=4:sw=4:sts=4:et
# -*- tab-width: 4; c-basic-offset: 4; indent-tabs-mode: nil -*-
#
# Copyright (C) 2012 Robert Yang
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import os, logging, re, sys
import bb
logger = logging.getLogger("BitBake.Monitor")
def printErr(info):
logger.error("%s\n Disk space monitor will NOT be enabled" % info)
def convertGMK(unit):
""" Convert the space unit G, M, K, the unit is case-insensitive """
unitG = re.match('([1-9][0-9]*)[gG]\s?$', unit)
if unitG:
return int(unitG.group(1)) * (1024 ** 3)
unitM = re.match('([1-9][0-9]*)[mM]\s?$', unit)
if unitM:
return int(unitM.group(1)) * (1024 ** 2)
unitK = re.match('([1-9][0-9]*)[kK]\s?$', unit)
if unitK:
return int(unitK.group(1)) * 1024
unitN = re.match('([1-9][0-9]*)\s?$', unit)
if unitN:
return int(unitN.group(1))
else:
return None
def getMountedDev(path):
""" Get the device mounted at the path, uses /proc/mounts """
# Get the mount point of the filesystem containing path
# st_dev is the ID of device containing file
parentDev = os.stat(path).st_dev
currentDev = parentDev
# When the current directory's device is different from the
# parrent's, then the current directory is a mount point
while parentDev == currentDev:
mountPoint = path
# Use dirname to get the parrent's directory
path = os.path.dirname(path)
# Reach the "/"
if path == mountPoint:
break
parentDev= os.stat(path).st_dev
try:
with open("/proc/mounts", "r") as ifp:
for line in ifp:
procLines = line.rstrip('\n').split()
if procLines[1] == mountPoint:
return procLines[0]
except EnvironmentError:
pass
return None
def getDiskData(BBDirs, configuration):
"""Prepare disk data for disk space monitor"""
# Save the device IDs, need the ID to be unique (the dictionary's key is
# unique), so that when more than one directories are located in the same
# device, we just monitor it once
devDict = {}
for pathSpaceInode in BBDirs.split():
# The input format is: "dir,space,inode", dir is a must, space
# and inode are optional
pathSpaceInodeRe = re.match('([^,]*),([^,]*),([^,]*),?(.*)', pathSpaceInode)
if not pathSpaceInodeRe:
printErr("Invalid value in BB_DISKMON_DIRS: %s" % pathSpaceInode)
return None
action = pathSpaceInodeRe.group(1)
if action not in ("ABORT", "STOPTASKS", "WARN"):
printErr("Unknown disk space monitor action: %s" % action)
return None
path = os.path.realpath(pathSpaceInodeRe.group(2))
if not path:
printErr("Invalid path value in BB_DISKMON_DIRS: %s" % pathSpaceInode)
return None
# The disk space or inode is optional, but it should have a correct
# value once it is specified
minSpace = pathSpaceInodeRe.group(3)
if minSpace:
minSpace = convertGMK(minSpace)
if not minSpace:
printErr("Invalid disk space value in BB_DISKMON_DIRS: %s" % pathSpaceInodeRe.group(3))
return None
else:
# 0 means that it is not specified
minSpace = None
minInode = pathSpaceInodeRe.group(4)
if minInode:
minInode = convertGMK(minInode)
if not minInode:
printErr("Invalid inode value in BB_DISKMON_DIRS: %s" % pathSpaceInodeRe.group(4))
return None
else:
# 0 means that it is not specified
minInode = None
if minSpace is None and minInode is None:
printErr("No disk space or inode value in found BB_DISKMON_DIRS: %s" % pathSpaceInode)
return None
# mkdir for the directory since it may not exist, for example the
# DL_DIR may not exist at the very beginning
if not os.path.exists(path):
bb.utils.mkdirhier(path)
mountedDev = getMountedDev(path)
devDict[mountedDev] = action, path, minSpace, minInode
return devDict
def getInterval(configuration):
""" Get the disk space interval """
interval = configuration.getVar("BB_DISKMON_WARNINTERVAL", 1)
if not interval:
# The default value is 50M and 5K.
return 50 * 1024 * 1024, 5 * 1024
else:
# The disk space or inode interval is optional, but it should
# have a correct value once it is specified
intervalRe = re.match('([^,]*),?\s*(.*)', interval)
if intervalRe:
intervalSpace = intervalRe.group(1)
if intervalSpace:
intervalSpace = convertGMK(intervalSpace)
if not intervalSpace:
printErr("Invalid disk space interval value in BB_DISKMON_WARNINTERVAL: %s" % intervalRe.group(1))
return None, None
intervalInode = intervalRe.group(2)
if intervalInode:
intervalInode = convertGMK(intervalInode)
if not intervalInode:
printErr("Invalid disk inode interval value in BB_DISKMON_WARNINTERVAL: %s" % intervalRe.group(2))
return None, None
return intervalSpace, intervalInode
else:
printErr("Invalid interval value in BB_DISKMON_WARNINTERVAL: %s" % interval)
return None, None
class diskMonitor:
"""Prepare the disk space monitor data"""
def __init__(self, configuration):
self.enableMonitor = False
BBDirs = configuration.getVar("BB_DISKMON_DIRS", 1) or None
if BBDirs:
self.devDict = getDiskData(BBDirs, configuration)
if self.devDict:
self.spaceInterval, self.inodeInterval = getInterval(configuration)
if self.spaceInterval and self.inodeInterval:
self.enableMonitor = True
# These are for saving the previous disk free space and inode, we
# use them to avoid print too many warning messages
self.preFreeS = {}
self.preFreeI = {}
# This is for STOPTASKS and ABORT, to avoid print the message repeatly
# during waiting the tasks to finish
self.checked = {}
for dev in self.devDict:
self.preFreeS[dev] = 0
self.preFreeI[dev] = 0
self.checked[dev] = False
if self.spaceInterval is None and self.inodeInterval is None:
self.enableMonitor = False
def check(self, rq):
""" Take action for the monitor """
if self.enableMonitor:
for dev in self.devDict:
st = os.statvfs(self.devDict[dev][1])
# The free space, float point number
freeSpace = st.f_bavail * st.f_frsize
if self.devDict[dev][2] and freeSpace < self.devDict[dev][2]:
# Always show warning, the self.checked would always be False if the action is WARN
if self.preFreeS[dev] == 0 or self.preFreeS[dev] - freeSpace > self.spaceInterval and not self.checked[dev]:
logger.warn("The free space of %s is running low (%.3fGB left)" % (dev, freeSpace / 1024 / 1024 / 1024.0))
self.preFreeS[dev] = freeSpace
if self.devDict[dev][0] == "STOPTASKS" and not self.checked[dev]:
logger.error("No new tasks can be excuted since the disk space monitor action is \"STOPTASKS\"!")
self.checked[dev] = True
rq.finish_runqueue(False)
elif self.devDict[dev][0] == "ABORT" and not self.checked[dev]:
logger.error("Immediately abort since the disk space monitor action is \"ABORT\"!")
self.checked[dev] = True
rq.finish_runqueue(True)
# The free inodes, float point number
freeInode = st.f_favail
if self.devDict[dev][3] and freeInode < self.devDict[dev][3]:
# Always show warning, the self.checked would always be False if the action is WARN
if self.preFreeI[dev] == 0 or self.preFreeI[dev] - freeInode > self.inodeInterval and not self.checked[dev]:
logger.warn("The free inode of %s is running low (%.3fK left)" % (dev, freeInode / 1024.0))
self.preFreeI[dev] = freeInode
if self.devDict[dev][0] == "STOPTASKS" and not self.checked[dev]:
logger.error("No new tasks can be excuted since the disk space monitor action is \"STOPTASKS\"!")
self.checked[dev] = True
rq.finish_runqueue(False)
elif self.devDict[dev][0] == "ABORT" and not self.checked[dev]:
logger.error("Immediately abort since the disk space monitor action is \"ABORT\"!")
self.checked[dev] = True
rq.finish_runqueue(True)
return

View File

@@ -100,6 +100,7 @@ class BBLogFilter(object):
loggerDefaultDebugLevel = 0
loggerDefaultVerbose = False
loggerVerboseLogs = False
loggerDefaultDomains = []
def init_msgconfig(verbose, debug, debug_domains = []):
@@ -108,6 +109,8 @@ def init_msgconfig(verbose, debug, debug_domains = []):
"""
bb.msg.loggerDefaultDebugLevel = debug
bb.msg.loggerDefaultVerbose = verbose
if verbose:
bb.msg.loggerVerboseLogs = True
bb.msg.loggerDefaultDomains = debug_domains
def addDefaultlogFilter(handler):

View File

@@ -37,6 +37,17 @@ logger = logging.getLogger("BitBake.Parsing")
class ParseError(Exception):
"""Exception raised when parsing fails"""
def __init__(self, msg, filename, lineno=0):
self.msg = msg
self.filename = filename
self.lineno = lineno
Exception.__init__(self, msg, filename, lineno)
def __str__(self):
if self.lineno:
return "ParseError at %s:%d: %s" % (self.filename, self.lineno, self.msg)
else:
return "ParseError in %s: %s" % (self.filename, self.msg)
class SkipPackage(Exception):
"""Exception raised to skip this package"""
@@ -78,7 +89,7 @@ def handle(fn, data, include = 0):
for h in handlers:
if h['supports'](fn, data):
return h['handle'](fn, data, include)
raise ParseError("%s is not a BitBake file" % fn)
raise ParseError("not a BitBake file", fn)
def init(fn, data):
for h in handlers:
@@ -111,7 +122,7 @@ def vars_from_file(mypkg, d):
parts = myfile[0].split('_')
__pkgsplit_cache__[mypkg] = parts
if len(parts) > 3:
raise ParseError("Unable to generate default variables from the filename: %s (too many underscores)" % mypkg)
raise ParseError("Unable to generate default variables from filename (too many underscores)", mypkg)
exp = 3 - len(parts)
tmplist = []
while exp != 0:
@@ -120,4 +131,13 @@ def vars_from_file(mypkg, d):
parts.extend(tmplist)
return parts
def get_file_depends(d):
'''Return the dependent files'''
dep_files = []
depends = d.getVar('__depends', True) or set()
depends = depends.union(d.getVar('__base_depends', True) or set())
for (fn, _) in depends:
dep_files.append(os.path.abspath(fn))
return " ".join(dep_files)
from bb.parse.parse_py import __version__, ConfHandler, BBHandler

View File

@@ -59,9 +59,9 @@ class IncludeNode(AstNode):
# TODO: Cache those includes... maybe not here though
if self.force:
bb.parse.ConfHandler.include(self.filename, s, data, "include required")
bb.parse.ConfHandler.include(self.filename, s, self.lineno, data, "include required")
else:
bb.parse.ConfHandler.include(self.filename, s, data, False)
bb.parse.ConfHandler.include(self.filename, s, self.lineno, data, False)
class ExportNode(AstNode):
def __init__(self, filename, lineno, var):
@@ -267,7 +267,7 @@ class InheritNode(AstNode):
self.classes = classes
def eval(self, data):
bb.parse.BBHandler.inherit(self.classes, data)
bb.parse.BBHandler.inherit(self.classes, self.filename, self.lineno, data)
def handleInclude(statements, filename, lineno, m, force):
statements.append(IncludeNode(filename, lineno, m.group(1), force))
@@ -328,6 +328,8 @@ def finalize(fn, d, variant = None):
bb.parse.siggen.finalise(fn, d, variant)
d.setVar('BBINCLUDED', bb.parse.get_file_depends(d))
bb.event.fire(bb.event.RecipeParsed(fn), d)
def _create_variants(datastores, names, function):
@@ -450,7 +452,7 @@ def multi_finalize(fn, d):
d.setVar("BBEXTENDVARIANT", variantmap[name])
else:
d.setVar("PN", "%s-%s" % (pn, name))
bb.parse.BBHandler.inherit([extendedmap[name]], d)
bb.parse.BBHandler.inherit([extendedmap[name]], fn, 0, d)
safe_d.setVar("BBCLASSEXTEND", extended)
_create_variants(datastores, extendedmap.keys(), extendfunc)

View File

@@ -68,10 +68,8 @@ def supports(fn, d):
"""Return True if fn has a supported extension"""
return os.path.splitext(fn)[-1] in [".bb", ".bbclass", ".inc"]
def inherit(files, d):
def inherit(files, fn, lineno, d):
__inherit_cache = data.getVar('__inherit_cache', d) or []
fn = ""
lineno = 0
for file in files:
file = data.expand(file, d)
if not os.path.isabs(file) and not file.endswith(".bbclass"):
@@ -81,7 +79,7 @@ def inherit(files, d):
logger.log(logging.DEBUG -1, "BB %s:%d: inheriting %s", fn, lineno, file)
__inherit_cache.append( file )
data.setVar('__inherit_cache', __inherit_cache, d)
include(fn, file, d, "inherit")
include(fn, file, lineno, d, "inherit")
__inherit_cache = data.getVar('__inherit_cache', d) or []
def get_statements(filename, absolute_filename, base_name):

View File

@@ -29,11 +29,10 @@ import logging
import bb.utils
from bb.parse import ParseError, resolve_file, ast, logger
#__config_regexp__ = re.compile( r"(?P<exp>export\s*)?(?P<var>[a-zA-Z0-9\-_+.${}]+)\s*(?P<colon>:)?(?P<ques>\?)?=\s*(?P<apo>['\"]?)(?P<value>.*)(?P=apo)$")
__config_regexp__ = re.compile( r"(?P<exp>export\s*)?(?P<var>[a-zA-Z0-9\-_+.${}/]+)(\[(?P<flag>[a-zA-Z0-9\-_+.]+)\])?\s*((?P<colon>:=)|(?P<lazyques>\?\?=)|(?P<ques>\?=)|(?P<append>\+=)|(?P<prepend>=\+)|(?P<predot>=\.)|(?P<postdot>\.=)|=)\s*(?P<apo>['\"]?)(?P<value>.*)(?P=apo)$")
__config_regexp__ = re.compile( r"(?P<exp>export\s*)?(?P<var>[a-zA-Z0-9\-_+.${}/]+)(\[(?P<flag>[a-zA-Z0-9\-_+.]+)\])?\s*((?P<colon>:=)|(?P<lazyques>\?\?=)|(?P<ques>\?=)|(?P<append>\+=)|(?P<prepend>=\+)|(?P<predot>=\.)|(?P<postdot>\.=)|=)\s*(?P<apo>['\"])(?P<value>.*)(?P=apo)$")
__include_regexp__ = re.compile( r"include\s+(.+)" )
__require_regexp__ = re.compile( r"require\s+(.+)" )
__export_regexp__ = re.compile( r"export\s+(.+)" )
__export_regexp__ = re.compile( r"export\s+([a-zA-Z0-9\-_+.${}/]+)$" )
def init(data):
topdir = data.getVar('TOPDIR')
@@ -44,10 +43,11 @@ def init(data):
def supports(fn, d):
return fn[-5:] == ".conf"
def include(oldfn, fn, data, error_out):
def include(oldfn, fn, lineno, data, error_out):
"""
error_out If True a ParseError will be raised if the to be included
config-files could not be included.
error_out: A string indicating the verb (e.g. "include", "inherit") to be
used in a ParseError that will be raised if the file to be included could
not be included. Specify False to avoid raising an error in this case.
"""
if oldfn == fn: # prevent infinite recursion
return None
@@ -68,7 +68,7 @@ def include(oldfn, fn, data, error_out):
ret = handle(fn, data, True)
except IOError:
if error_out:
raise ParseError("Could not %(error_out)s file %(fn)s" % vars() )
raise ParseError("Could not %(error_out)s file %(fn)s" % vars(), oldfn, lineno)
logger.debug(2, "CONF file '%s' not found", fn)
def handle(fn, data, include):
@@ -131,7 +131,7 @@ def feeder(lineno, s, fn, statements):
ast.handleExport(statements, fn, lineno, m)
return
raise ParseError("%s:%d: unparsed line: '%s'" % (fn, lineno, s));
raise ParseError("unparsed line: '%s'" % s, fn, lineno);
# Add us to the handlers list
from bb.parse import handlers

View File

@@ -41,15 +41,19 @@ if sqlversion[0] < 3 or (sqlversion[0] == 3 and sqlversion[1] < 3):
logger = logging.getLogger("BitBake.PersistData")
if hasattr(sqlite3, 'enable_shared_cache'):
sqlite3.enable_shared_cache(True)
try:
sqlite3.enable_shared_cache(True)
except sqlite3.OperationalError:
pass
@total_ordering
class SQLTable(collections.MutableMapping):
"""Object representing a table/domain in the database"""
def __init__(self, cursor, table):
self.cursor = cursor
def __init__(self, cachefile, table):
self.cachefile = cachefile
self.table = table
self.cursor = connect(self.cachefile)
self._execute("CREATE TABLE IF NOT EXISTS %s(key TEXT, value TEXT);"
% table)
@@ -63,6 +67,8 @@ class SQLTable(collections.MutableMapping):
except sqlite3.OperationalError as exc:
if 'database is locked' in str(exc) and count < 500:
count = count + 1
self.cursor.close()
self.cursor = connect(self.cachefile)
continue
raise
@@ -188,7 +194,7 @@ class PersistData(object):
del self.data[domain][key]
def connect(database):
return sqlite3.connect(database, timeout=30, isolation_level=None)
return sqlite3.connect(database, timeout=5, isolation_level=None)
def persist(domain, d):
"""Convenience factory for SQLTable objects based upon metadata"""
@@ -201,5 +207,4 @@ def persist(domain, d):
bb.utils.mkdirhier(cachedir)
cachefile = os.path.join(cachedir, "bb_persist_data.sqlite3")
connection = connect(cachefile)
return SQLTable(connection, domain)
return SQLTable(cachefile, domain)

View File

@@ -24,6 +24,7 @@
import re
import logging
from bb import data, utils
from collections import defaultdict
import bb
logger = logging.getLogger("BitBake.Provider")
@@ -35,6 +36,41 @@ class NoRProvider(bb.BBHandledException):
"""Exception raised when no provider of a runtime dependency can be found"""
def findProviders(cfgData, dataCache, pkg_pn = None):
"""
Convenience function to get latest and preferred providers in pkg_pn
"""
if not pkg_pn:
pkg_pn = dataCache.pkg_pn
# Need to ensure data store is expanded
localdata = data.createCopy(cfgData)
bb.data.update_data(localdata)
bb.data.expandKeys(localdata)
preferred_versions = {}
latest_versions = {}
for pn in pkg_pn:
(last_ver, last_file, pref_ver, pref_file) = findBestProvider(pn, localdata, dataCache, pkg_pn)
preferred_versions[pn] = (pref_ver, pref_file)
latest_versions[pn] = (last_ver, last_file)
return (latest_versions, preferred_versions)
def allProviders(dataCache):
"""
Find all providers for each pn
"""
all_providers = defaultdict(list)
for (fn, pn) in dataCache.pkg_fn.items():
ver = dataCache.pkg_pepvpr[fn]
all_providers[pn].append((ver, fn))
return all_providers
def sortPriorities(pn, dataCache, pkg_pn = None):
"""
Reorder pkg_pn by file priority and default preference

View File

@@ -31,6 +31,7 @@ import fcntl
import logging
import bb
from bb import msg, data, event
from bb import monitordisk
bblogger = logging.getLogger("BitBake")
logger = logging.getLogger("BitBake.RunQueue")
@@ -187,6 +188,7 @@ class RunQueueData:
self.taskData = taskData
self.targets = targets
self.rq = rq
self.warn_multi_bb = False
self.stampwhitelist = cfgData.getVar("BB_STAMP_WHITELIST", 1) or ""
self.multi_provider_whitelist = (cfgData.getVar("MULTI_PROVIDER_WHITELIST", 1) or "").split()
@@ -674,11 +676,14 @@ class RunQueueData:
prov_list[prov] = [fn]
elif fn not in prov_list[prov]:
prov_list[prov].append(fn)
error = False
for prov in prov_list:
if len(prov_list[prov]) > 1 and prov not in self.multi_provider_whitelist:
error = True
logger.error("Multiple .bb files are due to be built which each provide %s (%s).\n This usually means one provides something the other doesn't and should.", prov, " ".join(prov_list[prov]))
msg = "Multiple .bb files are due to be built which each provide %s (%s)." % (prov, " ".join(prov_list[prov]))
if self.warn_multi_bb:
logger.warn(msg)
else:
msg += "\n This usually means one provides something the other doesn't and should."
logger.error(msg)
# Create a whitelist usable by the stamp checks
@@ -771,6 +776,9 @@ class RunQueue:
self.state = runQueuePrepare
# For disk space monitor
self.dm = monitordisk.diskMonitor(cfgData)
def check_stamps(self):
unchecked = {}
current = []
@@ -945,6 +953,9 @@ class RunQueue:
else:
self.rqexe = RunQueueExecuteScenequeue(self)
if self.state in [runQueueSceneRun, runQueueRunning, runQueueCleanUp]:
self.dm.check(self)
if self.state is runQueueSceneRun:
retval = self.rqexe.execute()
@@ -959,6 +970,13 @@ class RunQueue:
if self.state is runQueueCleanUp:
self.rqexe.finish()
if self.state is runQueueComplete or self.state is runQueueFailed:
if self.rqexe.stats.failed:
logger.info("Tasks Summary: Attempted %d tasks of which %d didn't need to be rerun and %d failed.", self.rqexe.stats.completed + self.rqexe.stats.failed, self.rqexe.stats.skipped, self.rqexe.stats.failed)
else:
# Let's avoid the word "failed" if nothing actually did
logger.info("Tasks Summary: Attempted %d tasks of which %d didn't need to be rerun and all succeeded.", self.rqexe.stats.completed, self.rqexe.stats.skipped)
if self.state is runQueueFailed:
if not self.rqdata.taskData.tryaltconfigs:
raise bb.runqueue.TaskFailure(self.rqexe.failed_fnids)
@@ -968,7 +986,6 @@ class RunQueue:
if self.state is runQueueComplete:
# All done
logger.info("Tasks Summary: Attempted %d tasks of which %d didn't need to be rerun and %d failed.", self.rqexe.stats.completed, self.rqexe.stats.skipped, self.rqexe.stats.failed)
return False
if self.state is runQueueChildProcess:
@@ -1050,6 +1067,13 @@ class RunQueueExecute:
for pipe in self.build_pipes:
self.build_pipes[pipe].read()
if len(self.failed_fnids) != 0:
self.rq.state = runQueueFailed
return
self.rq.state = runQueueComplete
return
def finish(self):
self.rq.state = runQueueCleanUp
@@ -1429,18 +1453,20 @@ class RunQueueExecuteScenequeue(RunQueueExecute):
sq_revdeps.append(copy.copy(self.rqdata.runq_revdeps[task]))
sq_revdeps_new.append(set())
if (len(self.rqdata.runq_revdeps[task]) == 0) and task not in self.rqdata.runq_setscene:
endpoints[task] = None
endpoints[task] = set()
for task in self.rqdata.runq_setscene:
for dep in self.rqdata.runq_depends[task]:
endpoints[dep] = task
if dep not in endpoints:
endpoints[dep] = set()
endpoints[dep].add(task)
def process_endpoints(endpoints):
newendpoints = {}
for point, task in endpoints.items():
tasks = set()
if task:
tasks.add(task)
tasks |= task
if sq_revdeps_new[point]:
tasks |= sq_revdeps_new[point]
sq_revdeps_new[point] = set()
@@ -1465,8 +1491,30 @@ class RunQueueExecuteScenequeue(RunQueueExecute):
elif len(sq_revdeps_new[task]) != 0:
bb.msg.fatal("RunQueue", "Something went badly wrong during scenequeue generation, aborting. Please report this problem.")
# Resolve setscene inter-task dependencies
# e.g. do_sometask_setscene[depends] = "targetname:do_someothertask_setscene"
# Note that anything explicitly depended upon will have its reverse dependencies removed to avoid circular dependencies
for task in self.rqdata.runq_setscene:
realid = self.rqdata.taskData.gettask_id(self.rqdata.taskData.fn_index[self.rqdata.runq_fnid[task]], self.rqdata.runq_task[task] + "_setscene", False)
idepends = self.rqdata.taskData.tasks_idepends[realid]
for (depid, idependtask) in idepends:
if depid not in self.rqdata.taskData.build_targets:
continue
depdata = self.rqdata.taskData.build_targets[depid][0]
if depdata is None:
continue
dep = self.rqdata.taskData.fn_index[depdata]
taskid = self.rqdata.get_task_id(self.rqdata.taskData.getfn_id(dep), idependtask.replace("_setscene", ""))
if taskid is None:
bb.msg.fatal("RunQueue", "Task %s depends upon nonexistant task %s:%s" % (self.rqdata.taskData.tasks_name[realid], dep, idependtask))
sq_revdeps_squash[self.rqdata.runq_setscene.index(task)].add(self.rqdata.runq_setscene.index(taskid))
# Have to zero this to avoid circular dependencies
sq_revdeps_squash[self.rqdata.runq_setscene.index(taskid)] = set()
#for task in xrange(len(sq_revdeps_squash)):
# print "Task %s: %s.%s is %s " % (task, self.taskData.fn_index[self.runq_fnid[self.runq_setscene[task]]], self.runq_task[self.runq_setscene[task]] + "_setscene", sq_revdeps_squash[task])
# print "Task %s: %s.%s is %s " % (task, self.rqdata.taskData.fn_index[self.rqdata.runq_fnid[self.rqdata.runq_setscene[task]]], self.rqdata.runq_task[self.rqdata.runq_setscene[task]] + "_setscene", sq_revdeps_squash[task])
self.sq_deps = []
self.sq_revdeps = sq_revdeps_squash
@@ -1614,8 +1662,8 @@ class RunQueueExecuteScenequeue(RunQueueExecute):
self.task_skip(task)
return True
logger.info("Running setscene task %d of %d (%s:%s)" % (self.stats.completed + self.stats.active + self.stats.failed + 1,
self.stats.total, fn, taskname))
startevent = sceneQueueTaskStarted(task, self.stats, self.rq)
bb.event.fire(startevent, self.cfgData)
pid, pipein, pipeout = self.fork_off_task(fn, realtask, taskname)
@@ -1676,6 +1724,15 @@ class runQueueEvent(bb.event.Event):
self.stats = stats.copy()
bb.event.Event.__init__(self)
class sceneQueueEvent(runQueueEvent):
"""
Base sceneQueue event class
"""
def __init__(self, task, stats, rq, noexec=False):
runQueueEvent.__init__(self, task, stats, rq)
realtask = rq.rqdata.runq_setscene[task]
self.taskstring = rq.rqdata.get_user_idstring(realtask, "_setscene")
class runQueueTaskStarted(runQueueEvent):
"""
Event notifing a task was started
@@ -1684,6 +1741,14 @@ class runQueueTaskStarted(runQueueEvent):
runQueueEvent.__init__(self, task, stats, rq)
self.noexec = noexec
class sceneQueueTaskStarted(sceneQueueEvent):
"""
Event notifing a setscene task was started
"""
def __init__(self, task, stats, rq, noexec=False):
sceneQueueEvent.__init__(self, task, stats, rq)
self.noexec = noexec
class runQueueTaskFailed(runQueueEvent):
"""
Event notifing a task failed
@@ -1692,13 +1757,13 @@ class runQueueTaskFailed(runQueueEvent):
runQueueEvent.__init__(self, task, stats, rq)
self.exitcode = exitcode
class sceneQueueTaskFailed(runQueueTaskFailed):
class sceneQueueTaskFailed(sceneQueueEvent):
"""
Event notifing a setscene task failed
"""
def __init__(self, task, stats, exitcode, rq):
runQueueTaskFailed.__init__(self, task, stats, exitcode, rq)
self.taskstring = rq.rqdata.get_user_idstring(task, "_setscene")
sceneQueueEvent.__init__(self, task, stats, rq)
self.exitcode = exitcode
class runQueueTaskCompleted(runQueueEvent):
"""

View File

@@ -163,7 +163,7 @@ class BitBakeXMLRPCServer(SimpleXMLRPCServer):
# remove this when you're done with debugging
# allow_reuse_address = True
def __init__(self, interface = ("localhost", 0)):
def __init__(self, interface):
"""
Constructor
"""
@@ -247,9 +247,9 @@ class BitbakeServerInfo():
self.port = port
class BitBakeServerConnection():
def __init__(self, serverinfo):
def __init__(self, serverinfo, clientinfo=("localhost", 0)):
self.connection = _create_server(serverinfo.host, serverinfo.port)
self.events = uievent.BBUIEventQueue(self.connection)
self.events = uievent.BBUIEventQueue(self.connection, clientinfo)
for event in bb.event.ui_queue:
self.events.queue_event(event)
@@ -267,8 +267,8 @@ class BitBakeServerConnection():
pass
class BitBakeServer(object):
def initServer(self):
self.server = BitBakeXMLRPCServer()
def initServer(self, interface = ("localhost", 0)):
self.server = BitBakeXMLRPCServer(interface)
def addcooker(self, cooker):
self.cooker = cooker

View File

@@ -62,9 +62,13 @@ class SignatureGeneratorBasic(SignatureGenerator):
self.runtaskdeps = {}
self.gendeps = {}
self.lookupcache = {}
self.pkgnameextract = re.compile("(?P<fn>.*)\..*")
self.basewhitelist = set((data.getVar("BB_HASHBASE_WHITELIST", True) or "").split())
self.taskwhitelist = data.getVar("BB_HASHTASK_WHITELIST", True) or None
self.taskwhitelist = None
self.init_rundepcheck(data)
def init_rundepcheck(self, data):
self.taskwhitelist = data.getVar("BB_HASHTASK_WHITELIST", True) or None
if self.taskwhitelist:
self.twl = re.compile(self.taskwhitelist)
else:
@@ -131,17 +135,24 @@ class SignatureGeneratorBasic(SignatureGenerator):
for task in taskdeps:
d.setVar("BB_BASEHASH_task-%s" % task, self.basehash[fn + "." + task])
def rundep_check(self, fn, recipename, task, dep, depname, dataCache):
# Return True if we should keep the dependency, False to drop it
# We only manipulate the dependencies for packages not in the whitelist
if self.twl and not self.twl.search(recipename):
# then process the actual dependencies
if self.twl.search(depname):
return False
return True
def get_taskhash(self, fn, task, deps, dataCache):
k = fn + "." + task
data = dataCache.basetaskhash[k]
self.runtaskdeps[k] = []
recipename = dataCache.pkg_fn[fn]
for dep in sorted(deps, key=clean_basepath):
# We only manipulate the dependencies for packages not in the whitelist
if self.twl and not self.twl.search(dataCache.pkg_fn[fn]):
# then process the actual dependencies
dep_fn = re.search("(?P<fn>.*)\..*", dep).group('fn')
if self.twl.search(dataCache.pkg_fn[dep_fn]):
continue
depname = dataCache.pkg_fn[self.pkgnameextract.search(dep).group('fn')]
if not self.rundep_check(fn, recipename, task, dep, depname, dataCache):
continue
if dep not in self.taskhash:
bb.fatal("%s is not in taskhash, caller isn't calling in dependency order?", dep)
data = data + self.taskhash[dep]
@@ -250,11 +261,13 @@ def compare_sigfiles(a, b):
if 'basewhitelist' in a_data and a_data['basewhitelist'] != b_data['basewhitelist']:
print "basewhitelist changed from %s to %s" % (a_data['basewhitelist'], b_data['basewhitelist'])
print "changed items: %s" % a_data['basewhitelist'].symmetric_difference(b_data['basewhitelist'])
if a_data['basewhitelist'] and b_data['basewhitelist']:
print "changed items: %s" % a_data['basewhitelist'].symmetric_difference(b_data['basewhitelist'])
if 'taskwhitelist' in a_data and a_data['taskwhitelist'] != b_data['taskwhitelist']:
print "taskwhitelist changed from %s to %s" % (a_data['taskwhitelist'], b_data['taskwhitelist'])
print "changed items: %s" % a_data['taskwhitelist'].symmetric_difference(b_data['taskwhitelist'])
if a_data['taskwhitelist'] and b_data['taskwhitelist']:
print "changed items: %s" % a_data['taskwhitelist'].symmetric_difference(b_data['taskwhitelist'])
if a_data['taskdeps'] != b_data['taskdeps']:
print "Task dependencies changed from:\n%s\nto:\n%s" % (sorted(a_data['taskdeps']), sorted(b_data['taskdeps']))
@@ -266,7 +279,8 @@ def compare_sigfiles(a, b):
if changed:
for dep in changed:
print "List of dependencies for variable %s changed from %s to %s" % (dep, a_data['gendeps'][dep], b_data['gendeps'][dep])
print "changed items: %s" % a_data['gendeps'][dep].symmetric_difference(b_data['gendeps'][dep])
if a_data['gendeps'][dep] and b_data['gendeps'][dep]:
print "changed items: %s" % a_data['gendeps'][dep].symmetric_difference(b_data['gendeps'][dep])
if added:
for dep in added:
print "Dependency on variable %s was added" % (dep)
@@ -286,16 +300,27 @@ def compare_sigfiles(a, b):
changed, added, removed = dict_diff(a, b)
if added:
for dep in added:
print "Dependency on task %s was added" % (dep)
bdep_found = False
if removed:
for bdep in removed:
if a[dep] == b[bdep]:
#print "Dependency on task %s was replaced by %s with same hash" % (dep, bdep)
bdep_found = True
if not bdep_found:
print "Dependency on task %s was added with hash %s" % (dep, a[dep])
if removed:
for dep in removed:
print "Dependency on task %s was removed" % (dep)
adep_found = False
if added:
for adep in added:
if a[adep] == b[dep]:
#print "Dependency on task %s was replaced by %s with same hash" % (adep, dep)
adep_found = True
if not adep_found:
print "Dependency on task %s was removed with hash %s" % (dep, b[dep])
if changed:
for dep in changed:
print "Hash for dependent task %s changed from %s to %s" % (dep, a[dep], b[dep])
elif 'runtaskdeps' in a_data and 'runtaskdeps' in b_data and sorted(a_data['runtaskdeps']) != sorted(b_data['runtaskdeps']):
print "Tasks this task depends on changed from %s to %s" % (sorted(a_data['runtaskdeps']), sorted(b_data['runtaskdeps']))
print "changed items: %s" % a_data['runtaskdeps'].symmetric_difference(b_data['runtaskdeps'])
def dump_sigfile(a):
p1 = pickle.Unpickler(file(a, "rb"))

View File

@@ -0,0 +1,110 @@
#!/usr/bin/env python
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2012 Intel Corporation
#
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
from bb.ui.crumbs.progressbar import HobProgressBar
from bb.ui.crumbs.hobwidget import hic
from bb.ui.crumbs.runningbuild import RunningBuildTreeView
from bb.ui.crumbs.hobpages import HobPage
#
# BuildDetailsPage
#
class BuildDetailsPage (HobPage):
def __init__(self, builder):
super(BuildDetailsPage, self).__init__(builder, "Building ...")
# create visual elements
self.create_visual_elements()
def create_visual_elements(self):
# create visual elements
self.vbox = gtk.VBox(False, 15)
self.progress_box = gtk.HBox(False, 5)
self.progress_bar = HobProgressBar()
self.progress_box.pack_start(self.progress_bar, expand=True, fill=True)
self.stop_button = gtk.LinkButton("Stop the build process", "Stop")
self.stop_button.connect("clicked", self.stop_button_clicked_cb)
self.progress_box.pack_end(self.stop_button, expand=False, fill=False)
self.build_tv = RunningBuildTreeView(readonly=True)
self.build_tv.set_model(self.builder.handler.build.model)
self.scrolled_view = gtk.ScrolledWindow ()
self.scrolled_view.set_policy(gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC)
self.scrolled_view.add(self.build_tv)
self.button_box = gtk.HBox(False, 5)
self.back_button = gtk.LinkButton("Go back to Image Configuration screen", "<< Back to image configuration")
self.back_button.connect("clicked", self.back_button_clicked_cb)
self.button_box.pack_start(self.back_button, expand=False, fill=False)
def _remove_all_widget(self):
children = self.vbox.get_children() or []
for child in children:
self.vbox.remove(child)
children = self.box_group_area.get_children() or []
for child in children:
self.box_group_area.remove(child)
children = self.get_children() or []
for child in children:
self.remove(child)
def show_page(self, step):
self._remove_all_widget()
if step == self.builder.PACKAGE_GENERATING or step == self.builder.FAST_IMAGE_GENERATING:
self.title = "Building packages ..."
else:
self.title = "Building image ..."
self.build_details_top = self.add_onto_top_bar(None)
self.pack_start(self.build_details_top, expand=False, fill=False)
self.pack_start(self.group_align, expand=True, fill=True)
self.box_group_area.pack_start(self.vbox, expand=True, fill=True)
self.progress_bar.reset()
self.vbox.pack_start(self.progress_box, expand=False, fill=False)
self.vbox.pack_start(self.scrolled_view, expand=True, fill=True)
self.box_group_area.pack_end(self.button_box, expand=False, fill=False)
self.show_all()
self.back_button.hide()
def update_progress_bar(self, title, fraction, status=True):
self.progress_bar.update(fraction)
self.progress_bar.set_title(title)
self.progress_bar.set_rcstyle(status)
def back_button_clicked_cb(self, button):
self.builder.show_configuration()
def show_back_button(self):
self.back_button.show()
def stop_button_clicked_cb(self, button):
self.builder.stop_build()
def hide_stop_button(self):
self.stop_button.hide()

View File

@@ -0,0 +1,873 @@
#!/usr/bin/env python
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011-2012 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import copy
import os
import subprocess
import shlex
from bb.ui.crumbs.template import TemplateMgr
from bb.ui.crumbs.imageconfigurationpage import ImageConfigurationPage
from bb.ui.crumbs.recipeselectionpage import RecipeSelectionPage
from bb.ui.crumbs.packageselectionpage import PackageSelectionPage
from bb.ui.crumbs.builddetailspage import BuildDetailsPage
from bb.ui.crumbs.imagedetailspage import ImageDetailsPage
from bb.ui.crumbs.hobwidget import hwc
from bb.ui.crumbs.hig import CrumbsDialog, BinbDialog, \
AdvancedSettingDialog, LayerSelectionDialog, \
DeployImageDialog, ImageSelectionDialog
class Configuration:
'''Represents the data structure of configuration.'''
def __init__(self, params):
# Settings
self.curr_mach = ""
self.curr_distro = params["distro"]
self.dldir = params["dldir"]
self.sstatedir = params["sstatedir"]
self.sstatemirror = params["sstatemirror"]
self.pmake = params["pmake"]
self.bbthread = params["bbthread"]
self.curr_package_format = " ".join(params["pclass"].split("package_")).strip()
self.image_rootfs_size = params["image_rootfs_size"]
self.image_extra_size = params["image_extra_size"]
self.image_overhead_factor = params['image_overhead_factor']
self.incompat_license = params["incompat_license"]
self.curr_sdk_machine = params["sdk_machine"]
self.extra_setting = {}
self.toolchain_build = False
self.image_fstypes = params["image_fstypes"].split()
# bblayers.conf
self.layers = params["layer"].split()
# image/recipes/packages
self.selected_image = None
self.selected_recipes = []
self.selected_packages = []
def load(self, template):
self.curr_mach = template.getVar("MACHINE")
self.curr_package_format = " ".join(template.getVar("PACKAGE_CLASSES").split("package_")).strip()
self.curr_distro = template.getVar("DISTRO")
self.dldir = template.getVar("DL_DIR")
self.sstatedir = template.getVar("SSTATE_DIR")
self.sstatemirror = template.getVar("SSTATE_MIRROR")
self.pmake = int(template.getVar("PARALLEL_MAKE").split()[1])
self.bbthread = int(template.getVar("BB_NUMBER_THREAD"))
self.image_rootfs_size = int(template.getVar("IMAGE_ROOTFS_SIZE"))
self.image_extra_size = int(template.getVar("IMAGE_EXTRA_SPACE"))
# image_overhead_factor is read-only.
self.incompat_license = template.getVar("INCOMPATIBLE_LICENSE")
self.curr_sdk_machine = template.getVar("SDKMACHINE")
self.extra_setting = eval(template.getVar("EXTRA_SETTING"))
self.toolchain_build = eval(template.getVar("TOOLCHAIN_BUILD"))
self.image_fstypes = template.getVar("IMAGE_FSTYPES").split()
# bblayers.conf
self.layers = template.getVar("BBLAYERS").split()
# image/recipes/packages
self.selected_image = template.getVar("__SELECTED_IMAGE__")
self.selected_recipes = template.getVar("DEPENDS").split()
self.selected_packages = template.getVar("IMAGE_INSTALL").split()
def save(self, template, filename):
# bblayers.conf
template.setVar("BBLAYERS", " ".join(self.layers))
# local.conf
template.setVar("MACHINE", self.curr_mach)
template.setVar("DISTRO", self.curr_distro)
template.setVar("DL_DIR", self.dldir)
template.setVar("SSTATE_DIR", self.sstatedir)
template.setVar("SSTATE_MIRROR", self.sstatemirror)
template.setVar("PARALLEL_MAKE", "-j %s" % self.pmake)
template.setVar("BB_NUMBER_THREAD", self.bbthread)
template.setVar("PACKAGE_CLASSES", " ".join(["package_" + i for i in self.curr_package_format.split()]))
template.setVar("IMAGE_ROOTFS_SIZE", self.image_rootfs_size)
template.setVar("IMAGE_EXTRA_SPACE", self.image_extra_size)
template.setVar("INCOMPATIBLE_LICENSE", self.incompat_license)
template.setVar("SDKMACHINE", self.curr_sdk_machine)
template.setVar("EXTRA_SETTING", self.extra_setting)
template.setVar("TOOLCHAIN_BUILD", self.toolchain_build)
template.setVar("IMAGE_FSTYPES", " ".join(self.image_fstypes).lstrip(" "))
# image/recipes/packages
self.selected_image = filename
template.setVar("__SELECTED_IMAGE__", self.selected_image)
template.setVar("DEPENDS", self.selected_recipes)
template.setVar("IMAGE_INSTALL", self.selected_packages)
class Parameters:
'''Represents other variables like available machines, etc.'''
def __init__(self, params):
# Variables
self.all_machines = []
self.all_package_formats = []
self.all_distros = []
self.all_sdk_machines = []
self.max_threads = params["max_threads"]
self.all_layers = []
self.core_base = params["core_base"]
self.image_names = []
self.image_addr = params["image_addr"]
self.image_types = params["image_types"].split()
class Builder(gtk.Window):
(MACHINE_SELECTION,
LAYER_CHANGED,
RCPPKGINFO_POPULATING,
RCPPKGINFO_POPULATED,
RECIPE_SELECTION,
PACKAGE_GENERATING,
PACKAGE_GENERATED,
PACKAGE_SELECTION,
FAST_IMAGE_GENERATING,
IMAGE_GENERATING,
IMAGE_GENERATED,
MY_IMAGE_OPENED,
BACK,
END_NOOP) = range(14)
(IMAGE_CONFIGURATION,
RECIPE_DETAILS,
BUILD_DETAILS,
PACKAGE_DETAILS,
IMAGE_DETAILS,
END_TAB) = range(6)
__step2page__ = {
MACHINE_SELECTION : IMAGE_CONFIGURATION,
LAYER_CHANGED : IMAGE_CONFIGURATION,
RCPPKGINFO_POPULATING : IMAGE_CONFIGURATION,
RCPPKGINFO_POPULATED : IMAGE_CONFIGURATION,
RECIPE_SELECTION : RECIPE_DETAILS,
PACKAGE_GENERATING : BUILD_DETAILS,
PACKAGE_GENERATED : PACKAGE_DETAILS,
PACKAGE_SELECTION : PACKAGE_DETAILS,
FAST_IMAGE_GENERATING : BUILD_DETAILS,
IMAGE_GENERATING : BUILD_DETAILS,
IMAGE_GENERATED : IMAGE_DETAILS,
MY_IMAGE_OPENED : IMAGE_DETAILS,
END_NOOP : None,
}
def __init__(self, hobHandler, recipe_model, package_model):
super(Builder, self).__init__()
# handler
self.handler = hobHandler
self.template = None
# settings
params = self.handler.get_parameters()
self.configuration = Configuration(params)
self.parameters = Parameters(params)
# build step
self.current_step = None
self.previous_step = None
self.stopping = False
self.build_succeeded = True
# recipe model and package model
self.recipe_model = recipe_model
self.package_model = package_model
# create visual elements
self.create_visual_elements()
# connect the signals to functions
#self.connect("configure-event", self.resize_window_cb)
self.connect("delete-event", self.destroy_window_cb)
self.recipe_model.connect ("recipe-selection-changed", self.recipelist_changed_cb)
self.package_model.connect("package-selection-changed", self.packagelist_changed_cb)
self.recipe_model.connect ("recipelist-populated", self.recipelist_populated_cb)
self.package_model.connect("packagelist-populated", self.packagelist_populated_cb)
self.handler.connect("config-updated", self.handler_config_updated_cb)
self.handler.connect("package-formats-updated", self.handler_package_formats_updated_cb)
self.handler.connect("layers-updated", self.handler_layers_updated_cb)
self.handler.connect("parsing-started", self.handler_parsing_started_cb)
self.handler.connect("parsing", self.handler_parsing_cb)
self.handler.connect("parsing-completed", self.handler_parsing_completed_cb)
self.handler.build.connect("build-started", self.handler_build_started_cb)
self.handler.build.connect("build-succeeded", self.handler_build_succeeded_cb)
self.handler.build.connect("build-failed", self.handler_build_failed_cb)
self.handler.build.connect("task-started", self.handler_task_started_cb)
self.handler.connect("generating-data", self.handler_generating_data_cb)
self.handler.connect("data-generated", self.handler_data_generated_cb)
self.handler.connect("command-succeeded", self.handler_command_succeeded_cb)
self.handler.connect("command-failed", self.handler_command_failed_cb)
self.switch_page(self.MACHINE_SELECTION)
def create_visual_elements(self):
self.set_title("HOB -- Image Creator")
self.set_icon_name("applications-development")
self.set_position(gtk.WIN_POS_CENTER_ALWAYS)
self.set_resizable(True)
window_width = self.get_screen().get_width()
window_height = self.get_screen().get_height()
if window_width >= hwc.MAIN_WIN_WIDTH:
window_width = hwc.MAIN_WIN_WIDTH
window_height = hwc.MAIN_WIN_HEIGHT
else:
lbl = "<b>Screen dimension mismatched</b>\nfor better usability and visual effects,"
lbl = lbl + " the screen dimension should be 1024x768 or above."
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
dialog.run()
dialog.destroy()
self.set_size_request(window_width, window_height)
self.vbox = gtk.VBox(False, 0)
self.vbox.set_border_width(0)
self.add(self.vbox)
# create pages
self.image_configuration_page = ImageConfigurationPage(self)
self.recipe_details_page = RecipeSelectionPage(self)
self.build_details_page = BuildDetailsPage(self)
self.package_details_page = PackageSelectionPage(self)
self.image_details_page = ImageDetailsPage(self)
self.nb = gtk.Notebook()
self.nb.set_show_tabs(False)
self.nb.insert_page(self.image_configuration_page, None, self.IMAGE_CONFIGURATION)
self.nb.insert_page(self.recipe_details_page, None, self.RECIPE_DETAILS)
self.nb.insert_page(self.build_details_page, None, self.BUILD_DETAILS)
self.nb.insert_page(self.package_details_page, None, self.PACKAGE_DETAILS)
self.nb.insert_page(self.image_details_page, None, self.IMAGE_DETAILS)
self.vbox.pack_start(self.nb, expand=True, fill=True)
self.show_all()
self.nb.set_current_page(0)
def get_split_model(self):
return self.handler.split_model
def load_template(self, path):
self.template = TemplateMgr()
self.template.load(path)
self.configuration.load(self.template)
if self.get_split_model():
if not set(self.configuration.layers) <= set(self.parameters.all_layers):
return False
else:
for layer in self.configuration.layers:
if not os.path.exists(layer+'/conf/layer.conf'):
return False
self.switch_page(self.LAYER_CHANGED)
self.template.destroy()
self.template = None
def save_template(self, path):
if path.rfind("/") == -1:
filename = "default"
path = "."
else:
filename = path[path.rfind("/") + 1:len(path)]
path = path[0:path.rfind("/")]
self.template = TemplateMgr()
self.template.open(filename, path)
self.configuration.save(self.template, filename)
self.template.save()
self.template.destroy()
self.template = None
def switch_page(self, next_step):
# Main Workflow (Business Logic)
self.nb.set_current_page(self.__step2page__[next_step])
if next_step == self.MACHINE_SELECTION: # init step
self.image_configuration_page.show_machine()
elif next_step == self.LAYER_CHANGED:
# after layers is changd by users
self.image_configuration_page.show_machine()
self.handler.refresh_layers(self.configuration.layers)
elif next_step == self.RCPPKGINFO_POPULATING:
# MACHINE CHANGED action or SETTINGS CHANGED
# show the progress bar
self.image_configuration_page.show_info_populating()
self.generate_recipes()
elif next_step == self.RCPPKGINFO_POPULATED:
self.image_configuration_page.show_info_populated()
elif next_step == self.RECIPE_SELECTION:
pass
elif next_step == self.PACKAGE_SELECTION:
pass
elif next_step == self.PACKAGE_GENERATING or next_step == self.FAST_IMAGE_GENERATING:
# both PACKAGE_GENEATING and FAST_IMAGE_GENERATING share the same page
self.build_details_page.show_page(next_step)
self.generate_packages()
elif next_step == self.PACKAGE_GENERATED:
pass
elif next_step == self.IMAGE_GENERATING:
# after packages are generated, selected_packages need to
# be updated in package_model per selected_image in recipe_model
self.build_details_page.show_page(next_step)
self.generate_image()
elif next_step == self.IMAGE_GENERATED:
self.image_details_page.show_page(next_step)
elif next_step == self.MY_IMAGE_OPENED:
self.image_details_page.show_page(next_step)
self.previous_step = self.current_step
self.current_step = next_step
def set_user_config(self):
self.handler.init_cooker()
# set bb layers
self.handler.set_bblayers(self.configuration.layers)
# set local configuration
self.handler.set_machine(self.configuration.curr_mach)
self.handler.set_package_format(self.configuration.curr_package_format)
self.handler.set_distro(self.configuration.curr_distro)
self.handler.set_dl_dir(self.configuration.dldir)
self.handler.set_sstate_dir(self.configuration.sstatedir)
self.handler.set_sstate_mirror(self.configuration.sstatemirror)
self.handler.set_pmake(self.configuration.pmake)
self.handler.set_bbthreads(self.configuration.bbthread)
self.handler.set_rootfs_size(self.configuration.image_rootfs_size)
self.handler.set_extra_size(self.configuration.image_extra_size)
self.handler.set_incompatible_license(self.configuration.incompat_license)
self.handler.set_sdk_machine(self.configuration.curr_sdk_machine)
self.handler.set_image_fstypes(self.configuration.image_fstypes)
self.handler.set_extra_config(self.configuration.extra_setting)
self.handler.set_extra_inherit("packageinfo")
def reset_recipe_model(self):
self.recipe_model.reset()
def reset_package_model(self):
self.package_model.reset()
def update_recipe_model(self, selected_image, selected_recipes):
self.recipe_model.set_selected_image(selected_image)
self.recipe_model.set_selected_recipes(selected_recipes)
def update_package_model(self, selected_packages):
left = self.package_model.set_selected_packages(selected_packages)
self.configuration.selected_packages += left
def generate_packages(self):
# Build packages
_, all_recipes = self.recipe_model.get_selected_recipes()
self.set_user_config()
self.handler.reset_build()
self.handler.generate_packages(all_recipes)
def generate_recipes(self):
# Parse recipes
self.set_user_config()
self.handler.generate_recipes()
def generate_image(self):
# Build image
self.set_user_config()
all_packages = self.package_model.get_selected_packages()
self.handler.reset_build()
self.handler.generate_image(all_packages, self.configuration.toolchain_build)
# Callback Functions
def handler_config_updated_cb(self, handler, which, values):
if which == "distro":
self.parameters.all_distros = values
elif which == "machine":
self.parameters.all_machines = values
self.image_configuration_page.update_machine_combo()
elif which == "machine-sdk":
self.parameters.all_sdk_machines = values
def handler_package_formats_updated_cb(self, handler, formats):
self.parameters.all_package_formats = formats
def handler_layers_updated_cb(self, handler, layers):
self.parameters.all_layers = layers
def handler_command_succeeded_cb(self, handler, initcmd):
if initcmd == self.handler.LAYERS_REFRESH:
self.image_configuration_page.switch_machine_combo()
elif initcmd in [self.handler.GENERATE_RECIPES,
self.handler.GENERATE_PACKAGES,
self.handler.GENERATE_IMAGE]:
self.handler.request_package_info_async()
elif initcmd == self.handler.POPULATE_PACKAGEINFO:
if self.current_step == self.FAST_IMAGE_GENERATING:
self.switch_page(self.IMAGE_GENERATING)
elif self.current_step == self.RCPPKGINFO_POPULATING:
self.switch_page(self.RCPPKGINFO_POPULATED)
elif self.current_step == self.PACKAGE_GENERATING:
self.switch_page(self.PACKAGE_GENERATED)
elif self.current_step == self.IMAGE_GENERATING:
self.switch_page(self.IMAGE_GENERATED)
def handler_command_failed_cb(self, handler, msg):
lbl = "<b>Error</b>\n"
lbl = lbl + "%s\n\n" % msg
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_WARNING)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
response = dialog.run()
dialog.destroy()
self.handler.clear_busy()
self.configuration.curr_mach = None
self.image_configuration_page.switch_machine_combo()
self.switch_page(self.MACHINE_SELECTION)
def window_sensitive(self, sensitive):
self.set_sensitive(sensitive)
if sensitive:
self.get_root_window().set_cursor(gtk.gdk.Cursor(gtk.gdk.LEFT_PTR))
else:
self.get_root_window().set_cursor(gtk.gdk.Cursor(gtk.gdk.WATCH))
def handler_generating_data_cb(self, handler):
self.window_sensitive(False)
def handler_data_generated_cb(self, handler):
self.window_sensitive(True)
def recipelist_populated_cb(self, recipe_model):
selected_image = self.configuration.selected_image
selected_recipes = self.configuration.selected_recipes[:]
selected_packages = self.configuration.selected_packages[:]
self.recipe_model.image_list_append(selected_image,
" ".join(selected_recipes),
" ".join(selected_packages))
self.image_configuration_page.update_image_combo(self.recipe_model, selected_image)
self.update_recipe_model(selected_image, selected_recipes)
def packagelist_populated_cb(self, package_model):
selected_packages = self.configuration.selected_packages[:]
self.update_package_model(selected_packages)
def recipelist_changed_cb(self, recipe_model):
self.recipe_details_page.refresh_selection()
def packagelist_changed_cb(self, package_model):
self.package_details_page.refresh_selection()
def handler_parsing_started_cb(self, handler, message):
if self.current_step != self.RCPPKGINFO_POPULATING:
return
fraction = 0
if message["eventname"] == "TreeDataPreparationStarted":
fraction = 0.6 + fraction
self.image_configuration_page.update_progress_bar(message["title"], fraction)
def handler_parsing_cb(self, handler, message):
if self.current_step != self.RCPPKGINFO_POPULATING:
return
fraction = message["current"] * 1.0/message["total"]
if message["eventname"] == "TreeDataPreparationProgress":
fraction = 0.6 + 0.4 * fraction
else:
fraction = 0.6 * fraction
self.image_configuration_page.update_progress_bar(message["title"], fraction)
def handler_parsing_completed_cb(self, handler, message):
if self.current_step != self.RCPPKGINFO_POPULATING:
return
if message["eventname"] == "TreeDataPreparationCompleted":
fraction = 1.0
else:
fraction = 0.6
self.image_configuration_page.update_progress_bar(message["title"], fraction)
def handler_build_started_cb(self, running_build):
if self.current_step == self.FAST_IMAGE_GENERATING:
fraction = 0
elif self.current_step == self.IMAGE_GENERATING:
if self.previous_step == self.FAST_IMAGE_GENERATING:
fraction = 0.9
else:
fraction = 0
elif self.current_step == self.PACKAGE_GENERATING:
fraction = 0
self.build_details_page.update_progress_bar("Build Started: ", fraction)
def handler_build_succeeded_cb(self, running_build):
self.build_succeeded = True
if self.current_step == self.FAST_IMAGE_GENERATING:
fraction = 0.9
elif self.current_step == self.IMAGE_GENERATING:
fraction = 1.0
self.parameters.image_names = []
linkname = 'hob-image-' + self.configuration.curr_mach
for image_type in self.parameters.image_types:
linkpath = self.parameters.image_addr + '/' + linkname + '.' + image_type
if os.path.exists(linkpath):
self.parameters.image_names.append(os.readlink(linkpath))
elif self.current_step == self.PACKAGE_GENERATING:
fraction = 1.0
self.build_details_page.update_progress_bar("Build Completed: ", fraction)
def handler_build_failed_cb(self, running_build):
self.build_succeeded = False
if self.current_step == self.FAST_IMAGE_GENERATING:
fraction = 0.9
elif self.current_step == self.IMAGE_GENERATING:
fraction = 1.0
elif self.current_step == self.PACKAGE_GENERATING:
fraction = 1.0
self.build_details_page.update_progress_bar("Build Failed: ", fraction, False)
self.build_details_page.show_back_button()
self.build_details_page.hide_stop_button()
self.handler.build_failed_async()
self.stopping = False
def handler_task_started_cb(self, running_build, message):
fraction = message["current"] * 1.0/message["total"]
title = "Build packages"
if self.current_step == self.FAST_IMAGE_GENERATING:
if message["eventname"] == "sceneQueueTaskStarted":
fraction = 0.27 * fraction
elif message["eventname"] == "runQueueTaskStarted":
fraction = 0.27 + 0.63 * fraction
elif self.current_step == self.IMAGE_GENERATING:
title = "Build image"
if self.previous_step == self.FAST_IMAGE_GENERATING:
if message["eventname"] == "sceneQueueTaskStarted":
fraction = 0.27 + 0.63 + 0.03 * fraction
elif message["eventname"] == "runQueueTaskStarted":
fraction = 0.27 + 0.63 + 0.03 + 0.07 * fraction
else:
if message["eventname"] == "sceneQueueTaskStarted":
fraction = 0.2 * fraction
elif message["eventname"] == "runQueueTaskStarted":
fraction = 0.2 + 0.8 * fraction
elif self.current_step == self.PACKAGE_GENERATING:
if message["eventname"] == "sceneQueueTaskStarted":
fraction = 0.2 * fraction
elif message["eventname"] == "runQueueTaskStarted":
fraction = 0.2 + 0.8 * fraction
self.build_details_page.update_progress_bar(title + ": ", fraction)
def destroy_window_cb(self, widget, event):
lbl = "<b>Do you really want to exit the Hob image creator?</b>"
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_YES, gtk.RESPONSE_YES)
dialog.add_button(gtk.STOCK_NO, gtk.RESPONSE_NO)
dialog.set_default_response(gtk.RESPONSE_NO)
response = dialog.run()
dialog.destroy()
if response == gtk.RESPONSE_YES:
gtk.main_quit()
return False
else:
return True
def build_packages(self):
_, all_recipes = self.recipe_model.get_selected_recipes()
if not all_recipes:
lbl = "<b>No selections made</b>\nYou have not made any selections"
lbl = lbl + " so there isn't anything to bake at this time."
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
dialog.run()
dialog.destroy()
return
self.switch_page(self.PACKAGE_GENERATING)
def build_image(self):
selected_packages = self.package_model.get_selected_packages()
if not selected_packages:
lbl = "<b>No selections made</b>\nYou have not made any selections"
lbl = lbl + " so there isn't anything to bake at this time."
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
dialog.run()
dialog.destroy()
return
self.switch_page(self.IMAGE_GENERATING)
def just_bake(self):
selected_image = self.recipe_model.get_selected_image()
selected_packages = self.package_model.get_selected_packages() or []
# If no base image and no selected packages don't build anything
if not (selected_packages or selected_image != self.recipe_model.__dummy_image__):
lbl = "<b>No selections made</b>\nYou have not made any selections"
lbl = lbl + " so there isn't anything to bake at this time."
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
dialog.run()
dialog.destroy()
return
self.switch_page(self.FAST_IMAGE_GENERATING)
def show_binb_dialog(self, binb):
binb_dialog = BinbDialog("Brought in by:", binb, self)
binb_dialog.run()
binb_dialog.destroy()
def show_layer_selection_dialog(self):
dialog = LayerSelectionDialog(title = "Layer Selection",
layers = copy.deepcopy(self.configuration.layers),
all_layers = self.parameters.all_layers,
split_model = self.get_split_model(),
parent = self,
flags = gtk.DIALOG_MODAL
| gtk.DIALOG_DESTROY_WITH_PARENT
| gtk.DIALOG_NO_SEPARATOR,
buttons = (gtk.STOCK_OK, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
response = dialog.run()
if response == gtk.RESPONSE_YES:
self.configuration.layers = dialog.layers
# DO refresh layers
if dialog.layers_changed:
self.switch_page(self.LAYER_CHANGED)
dialog.destroy()
def show_load_template_dialog(self):
dialog = gtk.FileChooserDialog("Load Template Files", self,
gtk.FILE_CHOOSER_ACTION_SAVE,
(gtk.STOCK_OPEN, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
filter = gtk.FileFilter()
filter.set_name("HOB Files")
filter.add_pattern("*.hob")
dialog.add_filter(filter)
response = dialog.run()
if response == gtk.RESPONSE_YES:
path = dialog.get_filename()
self.load_template(path)
dialog.destroy()
def show_save_template_dialog(self):
dialog = gtk.FileChooserDialog("Save Template Files", self,
gtk.FILE_CHOOSER_ACTION_SAVE,
(gtk.STOCK_SAVE, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
dialog.set_current_name("hob")
response = dialog.run()
if response == gtk.RESPONSE_YES:
path = dialog.get_filename()
self.save_template(path)
dialog.destroy()
def show_load_my_images_dialog(self):
dialog = ImageSelectionDialog(self.parameters.image_addr, self.parameters.image_types,
"Open My Images", self,
gtk.FILE_CHOOSER_ACTION_SAVE,
(gtk.STOCK_OPEN, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
response = dialog.run()
if response == gtk.RESPONSE_YES:
if not dialog.image_names:
lbl = "<b>No selections made</b>\nYou have not made any selections"
crumbs_dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
crumbs_dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
crumbs_dialog.run()
crumbs_dialog.destroy()
dialog.destroy()
return
self.parameters.image_addr = dialog.image_folder
self.parameters.image_names = dialog.image_names[:]
self.switch_page(self.MY_IMAGE_OPENED)
dialog.destroy()
def show_adv_settings_dialog(self):
dialog = AdvancedSettingDialog(title = "Settings",
configuration = copy.deepcopy(self.configuration),
all_image_types = self.parameters.image_types,
all_package_formats = self.parameters.all_package_formats,
all_distros = self.parameters.all_distros,
all_sdk_machines = self.parameters.all_sdk_machines,
max_threads = self.parameters.max_threads,
split_model = self.get_split_model(),
parent = self,
flags = gtk.DIALOG_MODAL
| gtk.DIALOG_DESTROY_WITH_PARENT
| gtk.DIALOG_NO_SEPARATOR,
buttons = ("Save", gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
response = dialog.run()
if response == gtk.RESPONSE_YES:
self.configuration = dialog.configuration
# DO reparse recipes
if dialog.settings_changed:
if self.configuration.curr_mach == "":
self.switch_page(self.MACHINE_SELECTION)
else:
self.switch_page(self.RCPPKGINFO_POPULATING)
dialog.destroy()
def deploy_image(self, image_name):
if not image_name:
lbl = "<b>Please select an image to deploy.</b>"
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
dialog.run()
dialog.destroy()
return
image_path = os.path.join(self.parameters.image_addr, image_name)
dialog = DeployImageDialog(title = "Usb Image Maker",
image_path = image_path,
parent = self,
flags = gtk.DIALOG_MODAL
| gtk.DIALOG_DESTROY_WITH_PARENT
| gtk.DIALOG_NO_SEPARATOR,
buttons = ("Close", gtk.RESPONSE_NO,
"Make usb image", gtk.RESPONSE_YES))
response = dialog.run()
dialog.destroy()
def runqemu_image(self, image_name):
if not image_name:
lbl = "<b>Please select an image to launch in QEMU.</b>"
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
dialog.run()
dialog.destroy()
return
dialog = gtk.FileChooserDialog("Load Kernel Files", self,
gtk.FILE_CHOOSER_ACTION_SAVE,
(gtk.STOCK_OPEN, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
filter = gtk.FileFilter()
filter.set_name("Kernel Files")
filter.add_pattern("*.bin")
dialog.add_filter(filter)
dialog.set_current_folder(self.parameters.image_addr)
response = dialog.run()
if response == gtk.RESPONSE_YES:
kernel_path = dialog.get_filename()
image_path = os.path.join(self.parameters.image_addr, image_name)
dialog.destroy()
if response == gtk.RESPONSE_YES:
source_env_path = os.path.join(self.parameters.core_base, "oe-init-build-env")
tmp_path = os.path.join(os.getcwd(), "tmp")
if os.path.exists(image_path) and os.path.exists(kernel_path) \
and os.path.exists(source_env_path) and os.path.exists(tmp_path):
cmdline = "/usr/bin/xterm -e "
cmdline += "\" export OE_TMPDIR=" + tmp_path + "; "
cmdline += "source " + source_env_path + " " + os.getcwd() + "; "
cmdline += "runqemu " + kernel_path + " " + image_path + "; bash\""
subprocess.Popen(shlex.split(cmdline))
else:
lbl = "<b>Path error</b>\nOne of your paths is wrong,"
lbl = lbl + " please make sure the following paths exist:\n"
lbl = lbl + "image path:" + image_path + "\n"
lbl = lbl + "kernel path:" + kernel_path + "\n"
lbl = lbl + "source environment path:" + source_env_path + "\n"
lbl = lbl + "tmp path: " + tmp_path + "."
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
dialog.run()
dialog.destroy()
def show_packages(self, ask=True):
_, selected_recipes = self.recipe_model.get_selected_recipes()
if selected_recipes and ask:
lbl = "<b>Package list may be incomplete!</b>\nDo you want to build selected recipes"
lbl = lbl + " to get a full list (Yes) or just view the existing packages (No)?"
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_INFO)
dialog.add_button(gtk.STOCK_YES, gtk.RESPONSE_YES)
dialog.add_button(gtk.STOCK_NO, gtk.RESPONSE_NO)
dialog.set_default_response(gtk.RESPONSE_YES)
response = dialog.run()
dialog.destroy()
if response == gtk.RESPONSE_YES:
self.switch_page(self.PACKAGE_GENERATING)
else:
self.switch_page(self.PACKAGE_SELECTION)
else:
self.switch_page(self.PACKAGE_SELECTION)
def show_recipes(self):
self.switch_page(self.RECIPE_SELECTION)
def initiate_new_build(self):
self.configuration.curr_mach = ""
self.image_configuration_page.switch_machine_combo()
self.switch_page(self.MACHINE_SELECTION)
def show_configuration(self):
self.switch_page(self.RCPPKGINFO_POPULATED)
def stop_build(self):
if self.stopping:
lbl = "<b>Force Stop build?</b>\nYou've already selected Stop once,"
lbl = lbl + " would you like to 'Force Stop' the build?\n\n"
lbl = lbl + "This will stop the build as quickly as possible but may"
lbl = lbl + " well leave your build directory in an unusable state"
lbl = lbl + " that requires manual steps to fix.\n"
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_WARNING)
dialog.add_button(gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL)
dialog.add_button("Force Stop", gtk.RESPONSE_YES)
else:
lbl = "<b>Stop build?</b>\n\nAre you sure you want to stop this"
lbl = lbl + " build?\n\n'Force Stop' will stop the build as quickly as"
lbl = lbl + " possible but may well leave your build directory in an"
lbl = lbl + " unusable state that requires manual steps to fix.\n\n"
lbl = lbl + "'Stop' will stop the build as soon as all in"
lbl = lbl + " progress build tasks are finished. However if a"
lbl = lbl + " lengthy compilation phase is in progress this may take"
lbl = lbl + " some time."
dialog = CrumbsDialog(self, lbl, gtk.STOCK_DIALOG_WARNING)
dialog.add_button(gtk.STOCK_CANCEL, gtk.RESPONSE_CANCEL)
dialog.add_button("Stop", gtk.RESPONSE_OK)
dialog.add_button("Force Stop", gtk.RESPONSE_YES)
response = dialog.run()
dialog.destroy()
if response != gtk.RESPONSE_CANCEL:
self.stopping = True
if response == gtk.RESPONSE_OK:
self.handler.cancel_build()
elif response == gtk.RESPONSE_YES:
self.handler.cancel_build(True)

View File

@@ -1,346 +0,0 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gobject
import copy
import re, os
from bb import data
class Configurator(gobject.GObject):
"""
A GObject to handle writing modified configuration values back
to conf files.
"""
__gsignals__ = {
"layers-loaded" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"layers-changed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
())
}
def __init__(self):
gobject.GObject.__init__(self)
self.bblayers = None
self.enabled_layers = {}
self.loaded_layers = {}
self.config = {}
self.orig_config = {}
self.preconf = None
self.postconf = None
# NOTE: cribbed from the cooker...
def _parse(self, f, data, include=False):
try:
return bb.parse.handle(f, data, include)
except (IOError, bb.parse.ParseError) as exc:
parselog.critical("Unable to parse %s: %s" % (f, exc))
sys.exit(1)
def _loadConf(self, path):
def getString(var):
return data.getVar(var, True) or ""
if self.orig_config:
del self.orig_config
self.orig_config = {}
data = bb.data.init()
data = self._parse(path, data)
# We only need to care about certain variables
mach = getString('MACHINE')
if mach and mach != self.config.get('MACHINE', ''):
self.config['MACHINE'] = mach
sdkmach = getString('SDKMACHINE')
if sdkmach and sdkmach != self.config.get('SDKMACHINE', ''):
self.config['SDKMACHINE'] = sdkmach
distro = getString('DISTRO')
if not distro:
distro = "defaultsetup"
if distro and distro != self.config.get('DISTRO', ''):
self.config['DISTRO'] = distro
bbnum = getString('BB_NUMBER_THREADS')
if bbnum and bbnum != self.config.get('BB_NUMBER_THREADS', ''):
self.config['BB_NUMBER_THREADS'] = bbnum
pmake = getString('PARALLEL_MAKE')
if pmake and pmake != self.config.get('PARALLEL_MAKE', ''):
self.config['PARALLEL_MAKE'] = pmake
pclass = getString('PACKAGE_CLASSES')
if pclass and pclass != self.config.get('PACKAGE_CLASSES', ''):
self.config['PACKAGE_CLASSES'] = pclass
fstypes = getString('IMAGE_FSTYPES')
if fstypes and fstypes != self.config.get('IMAGE_FSTYPES', ''):
self.config['IMAGE_FSTYPES'] = fstypes
# Values which aren't always set in the conf must be explicitly
# loaded as empty values for save to work
incompat = getString('INCOMPATIBLE_LICENSE')
if incompat and incompat != self.config.get('INCOMPATIBLE_LICENSE', ''):
self.config['INCOMPATIBLE_LICENSE'] = incompat
else:
self.config['INCOMPATIBLE_LICENSE'] = ""
# Non-standard, namespaces, variables for GUI preferences
toolchain = getString('HOB_BUILD_TOOLCHAIN')
if toolchain and toolchain != self.config.get('HOB_BUILD_TOOLCHAIN', ''):
self.config['HOB_BUILD_TOOLCHAIN'] = toolchain
header = getString('HOB_BUILD_TOOLCHAIN_HEADERS')
if header and header != self.config.get('HOB_BUILD_TOOLCHAIN_HEADERS', ''):
self.config['HOB_BUILD_TOOLCHAIN_HEADERS'] = header
self.orig_config = copy.deepcopy(self.config)
def setConfVar(self, var, val):
self.config[var] = val
def getConfVar(self, var):
if var in self.config:
return self.config[var]
else:
return ""
def _loadLayerConf(self, path):
self.bblayers = path
self.enabled_layers = {}
self.loaded_layers = {}
data = bb.data.init()
data = self._parse(self.bblayers, data)
layers = (data.getVar('BBLAYERS', True) or "").split()
for layer in layers:
# TODO: we may be better off calling the layer by its
# BBFILE_COLLECTIONS value?
name = self._getLayerName(layer)
self.loaded_layers[name] = layer
self.enabled_layers = copy.deepcopy(self.loaded_layers)
self.emit("layers-loaded")
def _addConfigFile(self, path):
conffiles = ["local.conf", "hob-pre.conf", "hob-post.conf"]
pref, sep, filename = path.rpartition("/")
if filename == "hob-pre.conf":
self.preconf = path
if filename == "hob-post.conf":
self.postconf = path
if filename in conffiles:
self._loadConf(path)
elif filename == "bblayers.conf":
self._loadLayerConf(path)
def _splitLayer(self, path):
# we only care about the path up to /conf/layer.conf
layerpath, conf, end = path.rpartition("/conf/")
return layerpath
def _getLayerName(self, path):
# Should this be the collection name?
layerpath, sep, name = path.rpartition("/")
return name
def disableLayer(self, layer):
if layer in self.enabled_layers:
del self.enabled_layers[layer]
def addLayerConf(self, confpath):
layerpath = self._splitLayer(confpath)
name = self._getLayerName(layerpath)
if not layerpath or not name:
return None, None
elif name not in self.enabled_layers:
self.addLayer(name, layerpath)
return name, layerpath
else:
return name, None
def addLayer(self, name, path):
self.enabled_layers[name] = path
def _isLayerConfDirty(self):
# if a different number of layers enabled to what was
# loaded, definitely different
if len(self.enabled_layers) != len(self.loaded_layers):
return True
for layer in self.loaded_layers:
# if layer loaded but no longer present, definitely dirty
if layer not in self.enabled_layers:
return True
for layer in self.enabled_layers:
# if this layer wasn't present at load, definitely dirty
if layer not in self.loaded_layers:
return True
# if this layers path has changed, definitely dirty
if self.enabled_layers[layer] != self.loaded_layers[layer]:
return True
return False
def _constructLayerEntry(self):
"""
Returns a string representing the new layer selection
"""
layers = self.enabled_layers.copy()
# Construct BBLAYERS entry
layer_entry = "BBLAYERS = \" \\\n"
if 'meta' in layers:
layer_entry = layer_entry + " %s \\\n" % layers['meta']
del layers['meta']
for layer in layers:
layer_entry = layer_entry + " %s \\\n" % layers[layer]
layer_entry = layer_entry + " \""
return "".join(layer_entry)
def writeConfFile(self, conffile, contents):
"""
Make a backup copy of conffile and write a new file in its stead with
the lines in the contents list.
"""
# Create a backup of the conf file
bkup = "%s~" % conffile
os.rename(conffile, bkup)
# Write the contents list object to the conf file
with open(conffile, "w") as new:
new.write("".join(contents))
def updateConf(self, orig_lines, changed_values):
new_config_lines = []
for var in changed_values:
# Convenience function for re.subn(). If the pattern matches
# return a string which contains an assignment using the same
# assignment operator as the old assignment.
def replace_val(matchobj):
var = matchobj.group(1) # config variable
op = matchobj.group(2) # assignment operator
val = changed_values[var] # new config value
return "%s %s \"%s\"" % (var, op, val)
pattern = '^\s*(%s)\s*([+=?.]+)(.*)' % re.escape(var)
p = re.compile(pattern)
cnt = 0
replaced = False
# Iterate over the local.conf lines and if they are a match
# for the pattern comment out the line and append a new line
# with the new VAR op "value" entry
for line in orig_lines:
new_line, replacements = p.subn(replace_val, line)
if replacements:
orig_lines[cnt] = "#%s" % line
new_config_lines.append(new_line)
replaced = True
cnt = cnt + 1
if not replaced:
new_config_lines.append("%s = \"%s\"\n" % (var, changed_values[var]))
# Add the modified variables
orig_lines.extend(new_config_lines)
return orig_lines
def writeConf(self):
pre_vars = ["MACHINE", "SDKMACHINE", "DISTRO",
"INCOMPATIBLE_LICENSE"]
post_vars = ["BB_NUMBER_THREADS", "PARALLEL_MAKE", "PACKAGE_CLASSES",
"IMAGE_FSTYPES", "HOB_BUILD_TOOLCHAIN",
"HOB_BUILD_TOOLCHAIN_HEADERS"]
pre_values = {}
post_values = {}
changed_values = {}
pre_lines = None
post_lines = None
for var in self.config:
val = self.config[var]
if self.orig_config.get(var, None) != val:
changed_values[var] = val
if not len(changed_values):
return
for var in changed_values:
if var in pre_vars:
pre_values[var] = changed_values[var]
elif var in post_vars:
post_values[var] = changed_values[var]
with open(self.preconf, 'r') as pre:
pre_lines = pre.readlines()
pre_lines = self.updateConf(pre_lines, pre_values)
if len(pre_lines):
self.writeConfFile(self.preconf, pre_lines)
with open(self.postconf, 'r') as post:
post_lines = post.readlines()
post_lines = self.updateConf(post_lines, post_values)
if len(post_lines):
self.writeConfFile(self.postconf, post_lines)
del self.orig_config
self.orig_config = copy.deepcopy(self.config)
def insertTempBBPath(self, bbpath, bbfiles):
# read the original conf into a list
with open(self.postconf, 'r') as config:
config_lines = config.readlines()
if bbpath:
config_lines.append("BBPATH := \"${BBPATH}:%s\"\n" % bbpath)
if bbfiles:
config_lines.append("BBFILES := \"${BBFILES} %s\"\n" % bbfiles)
self.writeConfFile(self.postconf, config_lines)
def writeLayerConf(self):
# If we've not added/removed new layers don't write
if not self._isLayerConfDirty():
return
# This pattern should find the existing BBLAYERS
pattern = 'BBLAYERS\s=\s\".*\"'
replacement = self._constructLayerEntry()
with open(self.bblayers, "r") as f:
contents = f.read()
p = re.compile(pattern, re.DOTALL)
new = p.sub(replacement, contents)
self.writeConfFile(self.bblayers, new)
# set loaded_layers for dirtiness tracking
self.loaded_layers = copy.deepcopy(self.enabled_layers)
self.emit("layers-changed")
def configFound(self, handler, path):
self._addConfigFile(path)
def loadConfig(self, path):
self._addConfigFile(path)

View File

@@ -1,9 +1,11 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
# Copyright (C) 2011-2012 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
@@ -18,21 +20,33 @@
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gobject
import gtk
import gobject
import hashlib
import os
import re
import subprocess
import shlex
from bb.ui.crumbs.hobcolor import HobColors
from bb.ui.crumbs.hobwidget import HobWidget
from bb.ui.crumbs.progressbar import HobProgressBar
"""
The following are convenience classes for implementing GNOME HIG compliant
BitBake GUI's
In summary: spacing = 12px, border-width = 6px
"""
#
# CrumbsDialog
#
class CrumbsDialog(gtk.Dialog):
"""
A GNOME HIG compliant dialog widget.
Add buttons with gtk.Dialog.add_button or gtk.Dialog.add_buttons
"""
def __init__(self, parent=None, label="", icon=gtk.STOCK_INFO):
gtk.Dialog.__init__(self, "", parent, gtk.DIALOG_DESTROY_WITH_PARENT)
super(CrumbsDialog, self).__init__("", parent, gtk.DIALOG_DESTROY_WITH_PARENT)
#self.set_property("has-separator", False) # note: deprecated in 2.22
@@ -59,3 +73,572 @@ class CrumbsDialog(gtk.Dialog):
self.label.set_property("yalign", 0.00)
self.label.show()
first_row.add(self.label)
#
# Brought-in-by Dialog
#
class BinbDialog(gtk.Dialog):
"""
A dialog widget to show "brought in by" info when a recipe/package is clicked.
"""
def __init__(self, title, content, parent=None):
super(BinbDialog, self).__init__(title, parent, gtk.DIALOG_MODAL | gtk.DIALOG_DESTROY_WITH_PARENT, None)
self.set_position(gtk.WIN_POS_MOUSE)
self.set_resizable(False)
self.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.DARK))
hbox = gtk.HBox(False, 0)
self.vbox.pack_start(hbox, expand=False, fill=False, padding=10)
label = gtk.Label(content)
label.set_alignment(0, 0)
label.set_line_wrap(True)
label.modify_fg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.WHITE))
hbox.pack_start(label, expand=False, fill=False, padding=10)
self.vbox.show_all()
#
# AdvancedSettings Dialog
#
class AdvancedSettingDialog (gtk.Dialog):
def __init__(self, title, configuration, all_image_types,
all_package_formats, all_distros, all_sdk_machines,
max_threads, split_model, parent, flags, buttons):
super(AdvancedSettingDialog, self).__init__(title, parent, flags, buttons)
# class members from other objects
# bitbake settings from Builder.Configuration
self.configuration = configuration
self.image_types = all_image_types
self.all_package_formats = all_package_formats
self.all_distros = all_distros
self.all_sdk_machines = all_sdk_machines
self.max_threads = max_threads
self.split_model = split_model
# class members for internal use
self.pkgfmt_store = None
self.distro_combo = None
self.dldir_text = None
self.sstatedir_text = None
self.sstatemirror_text = None
self.bb_spinner = None
self.pmake_spinner = None
self.rootfs_size_spinner = None
self.extra_size_spinner = None
self.gplv3_checkbox = None
self.toolchain_checkbox = None
self.setting_store = None
self.image_types_checkbuttons = {}
self.variables = {}
self.variables["PACKAGE_FORMAT"] = self.configuration.curr_package_format
self.variables["INCOMPATIBLE_LICENSE"] = self.configuration.incompat_license
self.variables["IMAGE_FSTYPES"] = self.configuration.image_fstypes
self.md5 = hashlib.md5(str(sorted(self.variables.items()))).hexdigest()
self.settings_changed = False
# create visual elements on the dialog
self.create_visual_elements()
self.connect("response", self.response_cb)
def create_visual_elements(self):
self.set_size_request(500, 500)
self.nb = gtk.Notebook()
self.nb.set_show_tabs(True)
self.nb.append_page(self.create_image_types_page(), gtk.Label("Image types"))
self.nb.append_page(self.create_output_page(), gtk.Label("Output"))
self.nb.append_page(self.create_build_environment_page(), gtk.Label("Build environment"))
self.nb.append_page(self.create_others_page(), gtk.Label("Others"))
self.nb.set_current_page(0)
self.vbox.pack_start(self.nb, expand=True, fill=True)
self.vbox.pack_end(gtk.HSeparator(), expand=True, fill=True)
self.show_all()
def create_image_types_page(self):
advanced_vbox = gtk.VBox(False, 15)
advanced_vbox.set_border_width(20)
rows = (len(self.image_types)+1)/2
table = gtk.Table(rows + 1, 10, True)
advanced_vbox.pack_start(table, expand=False, fill=False)
tooltip = "Select image file system types that will be used."
image = gtk.Image()
image.show()
image.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
image.set_tooltip_text(tooltip)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Select image types:</span>")
table.attach(label, 0, 9, 0, 1)
table.attach(image, 9, 10, 0, 1)
i = 1
j = 1
for image_type in self.image_types:
self.image_types_checkbuttons[image_type] = gtk.CheckButton(image_type)
self.image_types_checkbuttons[image_type].set_tooltip_text("Build an %s image" % image_type)
table.attach(self.image_types_checkbuttons[image_type], j, j + 4, i, i + 1)
if image_type in self.configuration.image_fstypes:
self.image_types_checkbuttons[image_type].set_active(True)
i += 1
if i > rows:
i = 1
j = j + 4
return advanced_vbox
def create_output_page(self):
advanced_vbox = gtk.VBox(False, 15)
advanced_vbox.set_border_width(20)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Packaging Format:</span>")
tooltip = "Select package formats that will be used. "
tooltip += "The first format will be used for final image"
pkgfmt_widget, self.pkgfmt_store = HobWidget.gen_pkgfmt_widget(self.configuration.curr_package_format, self.all_package_formats, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(pkgfmt_widget, expand=False, fill=False)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Image Rootfs Size: (MB)</span>")
tooltip = "Sets the size of your target image.\nThis is the basic size of your target image, unless your selected package size exceeds this value, or you set value to \"Image Extra Size\"."
rootfs_size_widget, self.rootfs_size_spinner = HobWidget.gen_spinner_widget(int(self.configuration.image_rootfs_size*1.0/1024), 0, 1024, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(rootfs_size_widget, expand=False, fill=False)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Image Extra Size: (MB)</span>")
tooltip = "Sets the extra free space of your target image.\nDefaultly, system will reserve 30% of your image size as your free space. If your image contains zypper, it will bring in 50MB more space. The maximum free space is 1024MB."
extra_size_widget, self.extra_size_spinner = HobWidget.gen_spinner_widget(int(self.configuration.image_extra_size*1.0/1024), 0, 1024, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(extra_size_widget, expand=False, fill=False)
self.gplv3_checkbox = gtk.CheckButton("Exclude GPLv3 packages")
self.gplv3_checkbox.set_tooltip_text("Check this box to prevent GPLv3 packages from being included in your image")
if "GPLv3" in self.configuration.incompat_license.split():
self.gplv3_checkbox.set_active(True)
else:
self.gplv3_checkbox.set_active(False)
advanced_vbox.pack_start(self.gplv3_checkbox, expand=False, fill=False)
sub_hbox = gtk.HBox(False, 5)
advanced_vbox.pack_start(sub_hbox, expand=False, fill=False)
self.toolchain_checkbox = gtk.CheckButton("Build Toolchain")
self.toolchain_checkbox.set_tooltip_text("Check this box to build the related toolchain with your image")
self.toolchain_checkbox.set_active(self.configuration.toolchain_build)
sub_hbox.pack_start(self.toolchain_checkbox, expand=False, fill=False)
tooltip = "This is the Host platform you would like to run the toolchain"
sdk_machine_widget, self.sdk_machine_combo = HobWidget.gen_combo_widget(self.configuration.curr_sdk_machine, self.all_sdk_machines, tooltip)
sub_hbox.pack_start(sdk_machine_widget, expand=False, fill=False)
return advanced_vbox
def create_build_environment_page(self):
advanced_vbox = gtk.VBox(False, 15)
advanced_vbox.set_border_width(20)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Select Distro:</span>")
tooltip = "This is the Yocto distribution you would like to use"
distro_widget, self.distro_combo = HobWidget.gen_combo_widget(self.configuration.curr_distro, self.all_distros, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(distro_widget, expand=False, fill=False)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">BB_NUMBER_THREADS:</span>")
tooltip = "Sets the number of threads that bitbake tasks can run simultaneously"
bbthread_widget, self.bb_spinner = HobWidget.gen_spinner_widget(self.configuration.bbthread, 1, self.max_threads, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(bbthread_widget, expand=False, fill=False)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">PARALLEL_MAKE:</span>")
tooltip = "Sets the make parallism, as known as 'make -j'"
pmake_widget, self.pmake_spinner = HobWidget.gen_spinner_widget(self.configuration.pmake, 1, self.max_threads, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(pmake_widget, expand=False, fill=False)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Set Download Directory:</span>")
tooltip = "Select a folder that caches the upstream project source code"
dldir_widget, self.dldir_text = HobWidget.gen_entry_widget(self.split_model, self.configuration.dldir, self, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(dldir_widget, expand=False, fill=False)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Select SSTATE Directory:</span>")
tooltip = "Select a folder that caches your prebuilt results"
sstatedir_widget, self.sstatedir_text = HobWidget.gen_entry_widget(self.split_model, self.configuration.sstatedir, self, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(sstatedir_widget, expand=False, fill=False)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=False, fill=False)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Select SSTATE Mirror:</span>")
tooltip = "Select the prebuilt mirror that will fasten your build speed"
sstatemirror_widget, self.sstatemirror_text = HobWidget.gen_entry_widget(self.split_model, self.configuration.sstatemirror, self, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(sstatemirror_widget, expand=False, fill=False)
return advanced_vbox
def create_others_page(self):
advanced_vbox = gtk.VBox(False, 15)
advanced_vbox.set_border_width(20)
sub_vbox = gtk.VBox(False, 5)
advanced_vbox.pack_start(sub_vbox, expand=True, fill=True)
label = HobWidget.gen_label_widget("<span weight=\"bold\">Add your own variables:</span>")
tooltip = "This is the key/value pair for your extra settings"
setting_widget, self.setting_store = HobWidget.gen_editable_settings(self.configuration.extra_setting, tooltip)
sub_vbox.pack_start(label, expand=False, fill=False)
sub_vbox.pack_start(setting_widget, expand=True, fill=True)
return advanced_vbox
def response_cb(self, dialog, response_id):
self.variables = {}
self.configuration.curr_package_format = ""
it = self.pkgfmt_store.get_iter_first()
while it:
value = self.pkgfmt_store.get_value(it, 2)
if value:
self.configuration.curr_package_format += (self.pkgfmt_store.get_value(it, 1) + " ")
it = self.pkgfmt_store.iter_next(it)
self.configuration.curr_package_format = self.configuration.curr_package_format.strip()
self.variables["PACKAGE_FORMAT"] = self.configuration.curr_package_format
self.configuration.curr_distro = self.distro_combo.get_active_text()
self.configuration.dldir = self.dldir_text.get_text()
self.configuration.sstatedir = self.sstatedir_text.get_text()
self.configuration.sstatemirror = self.sstatemirror_text.get_text()
self.configuration.bbthread = self.bb_spinner.get_value_as_int()
self.configuration.pmake = self.pmake_spinner.get_value_as_int()
self.configuration.image_rootfs_size = self.rootfs_size_spinner.get_value_as_int() * 1024
self.configuration.image_extra_size = self.extra_size_spinner.get_value_as_int() * 1024
self.configuration.image_fstypes = []
for image_type in self.image_types:
if self.image_types_checkbuttons[image_type].get_active():
self.configuration.image_fstypes.append(image_type)
self.variables["IMAGE_FSTYPES"] = self.configuration.image_fstypes
if self.gplv3_checkbox.get_active():
if "GPLv3" not in self.configuration.incompat_license.split():
self.configuration.incompat_license += " GPLv3"
else:
if "GPLv3" in self.configuration.incompat_license.split():
self.configuration.incompat_license = self.configuration.incompat_license.split().remove("GPLv3")
self.configuration.incompat_license = " ".join(self.configuration.incompat_license or [])
self.configuration.incompat_license = self.configuration.incompat_license.strip()
self.variables["INCOMPATIBLE_LICENSE"] = self.configuration.incompat_license
self.configuration.toolchain_build = self.toolchain_checkbox.get_active()
self.configuration.extra_setting = {}
it = self.setting_store.get_iter_first()
while it:
key = self.setting_store.get_value(it, 0)
value = self.setting_store.get_value(it, 1)
self.configuration.extra_setting[key] = value
self.variables[key] = value
it = self.setting_store.iter_next(it)
md5 = hashlib.md5(str(sorted(self.variables.items()))).hexdigest()
self.settings_changed = (self.md5 != md5)
#
# DeployImageDialog
#
class DeployImageDialog (gtk.Dialog):
__dummy_usb__ = "--select a usb drive--"
def __init__(self, title, image_path, parent, flags, buttons):
super(DeployImageDialog, self).__init__(title, parent, flags, buttons)
self.image_path = image_path
self.create_visual_elements()
self.connect("response", self.response_cb)
def create_visual_elements(self):
self.set_border_width(20)
self.set_default_size(500, 250)
label = gtk.Label()
label.set_alignment(0.0, 0.5)
markup = "<span font_desc='12'>The image to be written into usb drive:</span>"
label.set_markup(markup)
self.vbox.pack_start(label, expand=False, fill=False, padding=2)
scroll = gtk.ScrolledWindow()
scroll.set_policy(gtk.POLICY_NEVER, gtk.POLICY_AUTOMATIC)
scroll.set_shadow_type(gtk.SHADOW_IN)
tv = gtk.TextView()
tv.set_editable(False)
tv.set_wrap_mode(gtk.WRAP_WORD)
tv.set_cursor_visible(False)
buf = gtk.TextBuffer()
buf.set_text(self.image_path)
tv.set_buffer(buf)
scroll.add(tv)
self.vbox.pack_start(scroll, expand=True, fill=True)
self.usb_desc = gtk.Label()
self.usb_desc.set_alignment(0.0, 0.5)
markup = "<span font_desc='12'>You haven't chosen any USB drive.</span>"
self.usb_desc.set_markup(markup)
self.usb_combo = gtk.combo_box_new_text()
self.usb_combo.connect("changed", self.usb_combo_changed_cb)
model = self.usb_combo.get_model()
model.clear()
self.usb_combo.append_text(self.__dummy_usb__)
for usb in self.find_all_usb_devices():
self.usb_combo.append_text("/dev/" + usb)
self.usb_combo.set_active(0)
self.vbox.pack_start(self.usb_combo, expand=True, fill=True)
self.vbox.pack_start(self.usb_desc, expand=False, fill=False, padding=2)
self.progress_bar = HobProgressBar()
self.vbox.pack_start(self.progress_bar, expand=False, fill=False)
separator = gtk.HSeparator()
self.vbox.pack_start(separator, expand=False, fill=True, padding=10)
self.vbox.show_all()
self.progress_bar.hide()
def popen_read(self, cmd):
return os.popen("%s 2>/dev/null" % cmd).read().strip()
def find_all_usb_devices(self):
usb_devs = [ os.readlink(u)
for u in self.popen_read('ls /dev/disk/by-id/usb*').split()
if not re.search(r'part\d+', u) ]
return [ '%s' % u[u.rfind('/')+1:] for u in usb_devs ]
def get_usb_info(self, dev):
return "%s %s" % \
(self.popen_read('cat /sys/class/block/%s/device/vendor' % dev),
self.popen_read('cat /sys/class/block/%s/device/model' % dev))
def usb_combo_changed_cb(self, usb_combo):
combo_item = self.usb_combo.get_active_text()
if not combo_item or combo_item == self.__dummy_usb__:
markup = "<span font_desc='12'>You haven't chosen any USB drive.</span>"
self.usb_desc.set_markup(markup)
else:
markup = "<span font_desc='12'>" + self.get_usb_info(combo_item.lstrip("/dev/")) + "</span>"
self.usb_desc.set_markup(markup)
def response_cb(self, dialog, response_id):
if response_id == gtk.RESPONSE_YES:
combo_item = self.usb_combo.get_active_text()
if combo_item and combo_item != self.__dummy_usb__:
cmdline = "/usr/bin/xterm -e "
cmdline += "\"sudo dd if=" + self.image_path + " of=" + combo_item + "; bash\""
subprocess.Popen(args=shlex.split(cmdline))
def update_progress_bar(self, title, fraction, status=True):
self.progress_bar.update(fraction)
self.progress_bar.set_title(title)
self.progress_bar.set_rcstyle(status)
def write_file(self, ifile, ofile):
self.progress_bar.reset()
self.progress_bar.show()
f_from = os.open(ifile, os.O_RDONLY)
f_to = os.open(ofile, os.O_WRONLY)
total_size = os.stat(ifile).st_size
written_size = 0
while True:
buf = os.read(f_from, 1024*1024)
if not buf:
break
os.write(f_to, buf)
written_size += 1024*1024
self.update_progress_bar("Writing to usb:", written_size * 1.0/total_size)
self.update_progress_bar("Writing completed:", 1.0)
os.close(f_from)
os.close(f_to)
self.progress_bar.hide()
#
# LayerSelectionDialog
#
class LayerSelectionDialog (gtk.Dialog):
def __init__(self, title, layers, all_layers, split_model,
parent, flags, buttons):
super(LayerSelectionDialog, self).__init__(title, parent, flags, buttons)
# class members from other objects
self.layers = layers
self.all_layers = all_layers
self.split_model = split_model
self.layers_changed = False
# class members for internal use
self.layer_store = None
# create visual elements on the dialog
self.create_visual_elements()
self.connect("response", self.response_cb)
def create_visual_elements(self):
self.set_border_width(20)
self.set_default_size(400, 250)
hbox_top = gtk.HBox()
self.set_border_width(12)
self.vbox.pack_start(hbox_top, expand=False, fill=False)
if self.split_model:
label = HobWidget.gen_label_widget("<span weight=\"bold\" font_desc='12'>Select Layers:</span>\n(Available layers under '${COREBASE}/layers/' directory)")
else:
label = HobWidget.gen_label_widget("<span weight=\"bold\" font_desc='12'>Select Layers:</span>")
hbox_top.pack_start(label, expand=False, fill=False)
tooltip = "Layer is a collection of bb files and conf files"
image = gtk.Image()
image.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
image.set_tooltip_text(tooltip)
hbox_top.pack_end(image, expand=False, fill=False)
layer_widget, self.layer_store = HobWidget.gen_layer_widget(self.split_model, self.layers, self.all_layers, self, None)
self.vbox.pack_start(layer_widget, expand=True, fill=True)
separator = gtk.HSeparator()
self.vbox.pack_start(separator, False, True, 5)
separator.show()
hbox_button = gtk.HBox()
self.vbox.pack_end(hbox_button, expand=False, fill=False)
hbox_button.show()
label = HobWidget.gen_label_widget("<i>'meta' is Core layer for Yocto images</i>\n"
"<span weight=\"bold\">Please do not remove it</span>")
hbox_button.pack_start(label, expand=False, fill=False)
self.show_all()
def response_cb(self, dialog, response_id):
model = self.layer_store
it = model.get_iter_first()
layers = []
while it:
if self.split_model:
inc = model.get_value(it, 1)
if inc:
layers.append(model.get_value(it, 0))
else:
layers.append(model.get_value(it, 0))
it = model.iter_next(it)
self.layers_changed = (self.layers != layers)
self.layers = layers
class ImageSelectionDialog (gtk.Dialog):
def __init__(self, image_folder, image_types, title, parent, flags, buttons):
super(ImageSelectionDialog, self).__init__(title, parent, flags, buttons)
self.connect("response", self.response_cb)
self.image_folder = image_folder
self.image_types = image_types
self.image_names = []
# create visual elements on the dialog
self.create_visual_elements()
self.image_store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_BOOLEAN)
self.fill_image_store()
def create_visual_elements(self):
self.set_border_width(20)
self.set_default_size(600, 300)
self.vbox.set_spacing(10)
hbox = gtk.HBox(False, 10)
self.vbox.pack_start(hbox, expand=False, fill=False)
entry = gtk.Entry()
entry.set_text(self.image_folder)
table = gtk.Table(1, 10, True)
table.set_size_request(560, -1)
hbox.pack_start(table, expand=False, fill=False)
table.attach(entry, 0, 9, 0, 1)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_OPEN,gtk.ICON_SIZE_BUTTON)
open_button = gtk.Button()
open_button.set_image(image)
open_button.connect("clicked", self.select_path_cb, self, entry)
table.attach(open_button, 9, 10, 0, 1)
imgtv_widget, self.imgsel_tv = HobWidget.gen_imgtv_widget(400, 160)
self.vbox.pack_start(imgtv_widget, expand=True, fill=True)
self.show_all()
def select_path_cb(self, action, parent, entry):
dialog = gtk.FileChooserDialog("", parent,
gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER,
(gtk.STOCK_OK, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
response = dialog.run()
if response == gtk.RESPONSE_YES:
path = dialog.get_filename()
entry.set_text(path)
self.image_folder = path
self.fill_image_store()
dialog.destroy()
def fill_image_store(self):
self.image_store.clear()
imageset = set()
for root, dirs, files in os.walk(self.image_folder):
for f in files:
for image_type in self.image_types:
if f.endswith('.' + image_type):
imageset.add(f.rsplit('.' + image_type)[0])
for image in imageset:
self.image_store.set(self.image_store.append(), 0, image, 1, False)
self.imgsel_tv.set_model(self.image_store)
def response_cb(self, dialog, response_id):
self.image_names = []
if response_id == gtk.RESPONSE_YES:
iter = self.image_store.get_iter_first()
while iter:
path = self.image_store.get_path(iter)
if self.image_store[path][1]:
for root, dirs, files in os.walk(self.image_folder):
for f in files:
if f.startswith(self.image_store[path][0] + '.'):
self.image_names.append(f)
break
iter = self.image_store.iter_next(iter)

View File

@@ -0,0 +1,35 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2012 Intel Corporation
#
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
class HobColors:
WHITE = "#ffffff"
PALE_GREEN = "#aaffaa"
ORANGE = "#ff7c24"
PALE_RED = "#ffaaaa"
GRAY = "#aaaaaa"
LIGHT_GRAY = "#dddddd"
DARK = "#3c3b37"
BLACK = "#000000"
LIGHT_ORANGE = "#f7a787"
OK = WHITE
RUNNING = PALE_GREEN
WARNING = ORANGE
ERROR = PALE_RED

View File

@@ -4,6 +4,7 @@
# Copyright (C) 2011 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
@@ -20,10 +21,7 @@
import gobject
import logging
import tempfile
import datetime
progress_total = 0
from bb.ui.crumbs.runningbuild import RunningBuild
class HobHandler(gobject.GObject):
@@ -31,147 +29,176 @@ class HobHandler(gobject.GObject):
This object does BitBake event handling for the hob gui.
"""
__gsignals__ = {
"machines-updated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"sdk-machines-updated": (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"distros-updated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"package-formats-found" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"config-found" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_STRING,)),
"generating-data" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"data-generated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"fatal-error" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_STRING,
gobject.TYPE_STRING,)),
"command-failed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_STRING,)),
"reload-triggered" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_STRING,
gobject.TYPE_STRING,)),
"layers-updated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"package-formats-updated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"config-updated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_STRING, gobject.TYPE_PYOBJECT,)),
"command-succeeded" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_INT,)),
"command-failed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_STRING,)),
"generating-data" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"data-generated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"parsing-started" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"parsing" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
"parsing-completed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
}
(CFG_PATH_LOCAL, CFG_PATH_PRE, CFG_PATH_POST, CFG_PATH_LAYERS, CFG_FILES_DISTRO, CFG_FILES_MACH, CFG_FILES_SDK, FILES_MATCH_CLASS, GENERATE_TGTS, REPARSE_FILES, BUILD_IMAGE) = range(11)
(CFG_AVAIL_LAYERS, CFG_PATH_LAYERS, CFG_FILES_DISTRO, CFG_FILES_MACH, CFG_FILES_SDKMACH, FILES_MATCH_CLASS, PARSE_CONFIG, PARSE_BBFILES, GENERATE_TGTS, GENERATE_PACKAGEINFO, BUILD_TARGET_RECIPES, BUILD_TARGET_IMAGE, CMD_END) = range(13)
(LAYERS_REFRESH, GENERATE_RECIPES, GENERATE_PACKAGES, GENERATE_IMAGE, POPULATE_PACKAGEINFO) = range(5)
def __init__(self, taskmodel, server):
gobject.GObject.__init__(self)
def __init__(self, server, server_addr, client_addr, recipe_model, package_model):
super(HobHandler, self).__init__()
self.current_command = None
self.building = False
self.build_toolchain = False
self.build_toolchain_headers = False
self.build = RunningBuild(sequential=True)
self.recipe_model = recipe_model
self.package_model = package_model
self.commands_async = []
self.generating = False
self.build_queue = []
self.current_phase = None
self.bbpath_ok = False
self.bbfiles_ok = False
self.build_type = "image"
self.image_dir = os.path.join(tempfile.gettempdir(), 'hob-images')
self.building = False
self.recipe_queue = []
self.package_queue = []
self.model = taskmodel
self.server = server
self.error_msg = ""
self.initcmd = None
deploy_dir = self.server.runCommand(["getVariable", "DEPLOY_DIR"])
self.image_out_dir = os.path.join(deploy_dir, "images")
self.image_output_types = self.server.runCommand(["getVariable", "IMAGE_FSTYPES"]).split(" ")
self.bbpath = self.server.runCommand(["getVariable", "BBPATH"])
self.bbfiles = self.server.runCommand(["getVariable", "BBFILES"])
self.split_model = False
if server_addr and client_addr:
self.split_model = (server_addr != client_addr)
self.reset_server() # reset server if server was found just now
self.server_addr = server_addr
def run_next_command(self):
if self.current_command and not self.generating:
def kick(self):
import xmlrpclib
try:
# kick the while thing off
if self.split_model:
self.commands_async.append(self.CFG_AVAIL_LAYERS)
else:
self.commands_async.append(self.CFG_PATH_LAYERS)
self.commands_async.append(self.CFG_FILES_DISTRO)
self.commands_async.append(self.CFG_FILES_MACH)
self.commands_async.append(self.CFG_FILES_SDKMACH)
self.commands_async.append(self.FILES_MATCH_CLASS)
self.run_next_command()
return True
except xmlrpclib.Fault as x:
print("XMLRPC Fault getting commandline:\n %s" % x)
return False
def set_busy(self):
if not self.generating:
self.emit("generating-data")
self.generating = True
if self.current_command == self.CFG_PATH_LOCAL:
self.current_command = self.CFG_PATH_PRE
self.server.runCommand(["findConfigFilePath", "hob-pre.conf"])
elif self.current_command == self.CFG_PATH_PRE:
self.current_command = self.CFG_PATH_POST
self.server.runCommand(["findConfigFilePath", "hob-post.conf"])
elif self.current_command == self.CFG_PATH_POST:
self.current_command = self.CFG_PATH_LAYERS
def clear_busy(self):
if self.generating:
self.emit("data-generated")
self.generating = False
def run_next_command(self, initcmd=None):
if initcmd != None:
self.initcmd = initcmd
if self.commands_async:
self.set_busy()
next_command = self.commands_async.pop(0)
else:
self.clear_busy()
if self.initcmd != None:
self.emit("command-succeeded", self.initcmd)
return
if next_command == self.CFG_AVAIL_LAYERS:
self.server.runCommand(["findCoreBaseFiles", "layers", "conf/layer.conf"])
elif next_command == self.CFG_PATH_LAYERS:
self.server.runCommand(["findConfigFilePath", "bblayers.conf"])
elif self.current_command == self.CFG_PATH_LAYERS:
self.current_command = self.CFG_FILES_DISTRO
elif next_command == self.CFG_FILES_DISTRO:
self.server.runCommand(["findConfigFiles", "DISTRO"])
elif self.current_command == self.CFG_FILES_DISTRO:
self.current_command = self.CFG_FILES_MACH
elif next_command == self.CFG_FILES_MACH:
self.server.runCommand(["findConfigFiles", "MACHINE"])
elif self.current_command == self.CFG_FILES_MACH:
self.current_command = self.CFG_FILES_SDK
elif next_command == self.CFG_FILES_SDKMACH:
self.server.runCommand(["findConfigFiles", "MACHINE-SDK"])
elif self.current_command == self.CFG_FILES_SDK:
self.current_command = self.FILES_MATCH_CLASS
elif next_command == self.FILES_MATCH_CLASS:
self.server.runCommand(["findFilesMatchingInDir", "rootfs_", "classes"])
elif self.current_command == self.FILES_MATCH_CLASS:
self.current_command = self.GENERATE_TGTS
self.server.runCommand(["generateTargetsTree", "classes/image.bbclass"])
elif self.current_command == self.GENERATE_TGTS:
if self.generating:
self.emit("data-generated")
self.generating = False
self.current_command = None
elif self.current_command == self.REPARSE_FILES:
if self.build_queue:
self.current_command = self.BUILD_IMAGE
else:
self.current_command = self.CFG_PATH_LAYERS
self.server.runCommand(["resetCooker"])
self.server.runCommand(["reparseFiles"])
elif self.current_command == self.BUILD_IMAGE:
if self.generating:
self.emit("data-generated")
self.generating = False
elif next_command == self.PARSE_CONFIG:
self.server.runCommand(["parseConfigurationFiles", "", ""])
elif next_command == self.PARSE_BBFILES:
self.server.runCommand(["parseFiles"])
elif next_command == self.GENERATE_TGTS:
self.server.runCommand(["generateTargetsTree", "classes/image.bbclass", [], True])
elif next_command == self.GENERATE_PACKAGEINFO:
self.server.runCommand(["triggerEvent", "bb.event.RequestPackageInfo()"])
elif next_command == self.BUILD_TARGET_RECIPES:
self.clear_busy()
self.building = True
self.server.runCommand(["buildTargets", self.build_queue, "build"])
self.build_queue = []
self.current_command = None
self.server.runCommand(["buildTargets", self.recipe_queue, "build"])
self.recipe_queue = []
elif next_command == self.BUILD_TARGET_IMAGE:
self.clear_busy()
self.building = True
targets = ["hob-image"]
self.server.runCommand(["setVariable", "LINGUAS_INSTALL", ""])
self.server.runCommand(["setVariable", "PACKAGE_INSTALL", " ".join(self.package_queue)])
if self.toolchain_build:
pkgs = self.package_queue + [i+'-dev' for i in self.package_queue] + [i+'-dbg' for i in self.package_queue]
self.server.runCommand(["setVariable", "TOOLCHAIN_TARGET_TASK", " ".join(pkgs)])
targets.append("hob-toolchain")
self.server.runCommand(["buildTargets", targets, "build"])
def handle_event(self, event, running_build, pbar):
def handle_event(self, event):
if not event:
return
return
# If we're running a build, use the RunningBuild event handler
if self.building:
self.current_phase = "building"
running_build.handle_event(event)
self.build.handle_event(event)
if isinstance(event, bb.event.PackageInfo):
self.package_model.populate(event._pkginfolist)
self.run_next_command()
elif(isinstance(event, logging.LogRecord)):
if event.levelno >= logging.ERROR:
self.error_msg += event.msg + '\n'
elif isinstance(event, bb.event.TargetsTreeGenerated):
self.current_phase = "data generation"
if event._model:
self.model.populate(event._model)
self.recipe_model.populate(event._model)
elif isinstance(event, bb.event.CoreBaseFilesFound):
self.current_phase = "configuration lookup"
paths = event._paths
self.emit('layers-updated', paths)
elif isinstance(event, bb.event.ConfigFilesFound):
self.current_phase = "configuration lookup"
var = event._variable
if var == "distro":
distros = event._values
distros.sort()
self.emit("distros-updated", distros)
elif var == "machine":
machines = event._values
machines.sort()
self.emit("machines-updated", machines)
elif var == "machine-sdk":
sdk_machines = event._values
sdk_machines.sort()
self.emit("sdk-machines-updated", sdk_machines)
values = event._values
values.sort()
self.emit("config-updated", var, values)
elif isinstance(event, bb.event.ConfigFilePathFound):
self.current_phase = "configuration lookup"
path = event._path
self.emit("config-found", path)
elif isinstance(event, bb.event.FilesMatchingFound):
self.current_phase = "configuration lookup"
# FIXME: hard coding, should at least be a variable shared between
@@ -183,48 +210,84 @@ class HobHandler(gobject.GObject):
fs, sep, format = classname.rpartition("_")
formats.append(format)
formats.sort()
self.emit("package-formats-found", formats)
self.emit("package-formats-updated", formats)
elif isinstance(event, bb.command.CommandCompleted):
self.current_phase = None
self.run_next_command()
elif isinstance(event, bb.event.NoProvider):
if event._runtime:
r = "R"
else:
r = ""
if event._dependees:
self.error_msg += " Nothing %sPROVIDES '%s' (but %s %sDEPENDS on or otherwise requires it)" % (r, event._item, ", ".join(event._dependees), r)
else:
self.error_msg += " Nothing %sPROVIDES '%s'" % (r, event._item)
if event._reasons:
for reason in event._reasons:
self.error_msg += " %s" % reason
self.commands_async = []
self.emit("command-failed", self.error_msg)
self.error_msg = ""
elif isinstance(event, bb.command.CommandFailed):
self.emit("command-failed", event.error)
elif isinstance(event, bb.event.CacheLoadStarted):
self.current_phase = "cache loading"
bb.ui.crumbs.hobeventhandler.progress_total = event.total
pbar.set_text("Loading cache: %s/%s" % (0, bb.ui.crumbs.hobeventhandler.progress_total))
elif isinstance(event, bb.event.CacheLoadProgress):
self.current_phase = "cache loading"
pbar.set_text("Loading cache: %s/%s" % (event.current, bb.ui.crumbs.hobeventhandler.progress_total))
elif isinstance(event, bb.event.CacheLoadCompleted):
self.current_phase = None
pbar.set_text("Loading...")
elif isinstance(event, bb.event.ParseStarted):
self.current_phase = "recipe parsing"
if event.total == 0:
return
bb.ui.crumbs.hobeventhandler.progress_total = event.total
pbar.set_text("Processing recipes: %s/%s" % (0, bb.ui.crumbs.hobeventhandler.progress_total))
elif isinstance(event, bb.event.ParseProgress):
self.current_phase = "recipe parsing"
pbar.set_text("Processing recipes: %s/%s" % (event.current, bb.ui.crumbs.hobeventhandler.progress_total))
elif isinstance(event, bb.event.ParseCompleted):
self.current_phase = None
pbar.set_fraction(1.0)
pbar.set_text("Loading...")
elif isinstance(event, logging.LogRecord):
format = bb.msg.BBLogFormatter("%(levelname)s: %(message)s")
if event.levelno >= format.CRITICAL:
self.emit("fatal-error", event.getMessage(), self.current_phase)
self.commands_async = []
if self.error_msg:
self.emit("command-failed", self.error_msg)
self.error_msg = ""
elif isinstance(event, (bb.event.ParseStarted,
bb.event.CacheLoadStarted,
bb.event.TreeDataPreparationStarted,
)):
message = {}
message["eventname"] = bb.event.getName(event)
message["current"] = 0
message["total"] = None
message["title"] = "Parsing recipes: "
self.emit("parsing-started", message)
elif isinstance(event, (bb.event.ParseProgress,
bb.event.CacheLoadProgress,
bb.event.TreeDataPreparationProgress)):
message = {}
message["eventname"] = bb.event.getName(event)
message["current"] = event.current
message["total"] = event.total
message["title"] = "Parsing recipes: "
self.emit("parsing", message)
elif isinstance(event, (bb.event.ParseCompleted,
bb.event.CacheLoadCompleted,
bb.event.TreeDataPreparationCompleted)):
message = {}
message["eventname"] = bb.event.getName(event)
message["current"] = event.total
message["total"] = event.total
message["title"] = "Parsing recipes: "
self.emit("parsing-completed", message)
return
def event_handle_idle_func (self, eventHandler, running_build, pbar):
# Consume as many messages as we can in the time available to us
event = eventHandler.getEvent()
while event:
self.handle_event(event, running_build, pbar)
event = eventHandler.getEvent()
return True
def init_cooker(self):
self.server.runCommand(["initCooker"])
def refresh_layers(self, bblayers):
self.server.runCommand(["initCooker"])
self.server.runCommand(["setVariable", "BBLAYERS", " ".join(bblayers)])
self.commands_async.append(self.PARSE_CONFIG)
self.commands_async.append(self.CFG_FILES_DISTRO)
self.commands_async.append(self.CFG_FILES_MACH)
self.commands_async.append(self.CFG_FILES_SDKMACH)
self.commands_async.append(self.FILES_MATCH_CLASS)
self.run_next_command(self.LAYERS_REFRESH)
def set_extra_inherit(self, bbclass):
inherits = self.server.runCommand(["getVariable", "INHERIT"]) or ""
inherits = inherits + " " + bbclass
self.server.runCommand(["setVariable", "INHERIT", inherits])
def set_bblayers(self, bblayers):
self.server.runCommand(["setVariable", "BBLAYERS", " ".join(bblayers)])
def set_machine(self, machine):
self.server.runCommand(["setVariable", "MACHINE", machine])
@@ -232,62 +295,78 @@ class HobHandler(gobject.GObject):
def set_sdk_machine(self, sdk_machine):
self.server.runCommand(["setVariable", "SDKMACHINE", sdk_machine])
def set_image_fstypes(self, image_fstypes):
self.server.runCommand(["setVariable", "IMAGE_FSTYPES", " ".join(image_fstypes).lstrip(" ")])
def set_distro(self, distro):
self.server.runCommand(["setVariable", "DISTRO", distro])
def set_package_format(self, format):
self.server.runCommand(["setVariable", "PACKAGE_CLASSES", "package_%s" % format])
def reload_data(self, config=None):
img = self.model.selected_image
selected_packages, _ = self.model.get_selected_packages()
self.emit("reload-triggered", img, " ".join(selected_packages))
self.current_command = self.REPARSE_FILES
self.run_next_command()
package_classes = ""
for pkgfmt in format.split():
package_classes += ("package_%s" % pkgfmt + " ")
self.server.runCommand(["setVariable", "PACKAGE_CLASSES", package_classes])
def set_bbthreads(self, threads):
self.server.runCommand(["setVariable", "BB_NUMBER_THREADS", threads])
def set_pmake(self, threads):
pmake = "-j %s" % threads
self.server.runCommand(["setVariable", "BB_NUMBER_THREADS", pmake])
self.server.runCommand(["setVariable", "PARALLEL_MAKE", pmake])
def build_targets(self, tgts, configurator, build_type="image"):
self.build_type = build_type
def set_dl_dir(self, directory):
self.server.runCommand(["setVariable", "DL_DIR", directory])
def set_sstate_dir(self, directory):
self.server.runCommand(["setVariable", "SSTATE_DIR", directory])
def set_sstate_mirror(self, url):
self.server.runCommand(["setVariable", "SSTATE_MIRROR", url])
def set_extra_size(self, image_extra_size):
self.server.runCommand(["setVariable", "IMAGE_ROOTFS_EXTRA_SPACE", str(image_extra_size)])
def set_rootfs_size(self, image_rootfs_size):
self.server.runCommand(["setVariable", "IMAGE_ROOTFS_SIZE", str(image_rootfs_size)])
def set_incompatible_license(self, incompat_license):
self.server.runCommand(["setVariable", "INCOMPATIBLE_LICENSE", incompat_license])
def set_extra_config(self, extra_setting):
for key in extra_setting.keys():
value = extra_setting[key]
self.server.runCommand(["setVariable", key, value])
def request_package_info_async(self):
self.commands_async.append(self.GENERATE_PACKAGEINFO)
self.run_next_command(self.POPULATE_PACKAGEINFO)
def generate_recipes(self):
self.commands_async.append(self.PARSE_CONFIG)
self.commands_async.append(self.GENERATE_TGTS)
self.run_next_command(self.GENERATE_RECIPES)
def generate_packages(self, tgts):
targets = []
nbbp = None
nbbf = None
targets.extend(tgts)
if self.build_toolchain and self.build_toolchain_headers:
targets.append("meta-toolchain-sdk")
elif self.build_toolchain:
targets.append("meta-toolchain")
self.build_queue = targets
self.recipe_queue = targets
self.commands_async.append(self.PARSE_CONFIG)
self.commands_async.append(self.PARSE_BBFILES)
self.commands_async.append(self.BUILD_TARGET_RECIPES)
self.run_next_command(self.GENERATE_PACKAGES)
if not self.bbpath_ok:
if self.image_dir in self.bbpath.split(":"):
self.bbpath_ok = True
else:
nbbp = self.image_dir
def generate_image(self, tgts, toolchain_build=False):
self.package_queue = tgts
self.toolchain_build = toolchain_build
self.commands_async.append(self.PARSE_CONFIG)
self.commands_async.append(self.PARSE_BBFILES)
self.commands_async.append(self.BUILD_TARGET_IMAGE)
self.run_next_command(self.GENERATE_IMAGE)
if not self.bbfiles_ok:
import re
pattern = "%s/\*.bb" % self.image_dir
for files in self.bbfiles.split(" "):
if re.match(pattern, files):
self.bbfiles_ok = True
if not self.bbfiles_ok:
nbbf = "%s/*.bb" % self.image_dir
if nbbp or nbbf:
configurator.insertTempBBPath(nbbp, nbbf)
self.bbpath_ok = True
self.bbfiles_ok = True
self.current_command = self.REPARSE_FILES
self.run_next_command()
def build_failed_async(self):
self.initcmd = None
self.commands_async = []
self.building = False
def cancel_build(self, force=False):
if force:
@@ -298,46 +377,83 @@ class HobHandler(gobject.GObject):
# leave the workdir in a usable state
self.server.runCommand(["stateShutdown"])
def set_incompatible_license(self, incompatible):
self.server.runCommand(["setVariable", "INCOMPATIBLE_LICENSE", incompatible])
def reset_server(self):
self.server.runCommand(["resetCooker"])
def toggle_toolchain(self, enabled):
if self.build_toolchain != enabled:
self.build_toolchain = enabled
def reset_build(self):
self.build.reset()
def toggle_toolchain_headers(self, enabled):
if self.build_toolchain_headers != enabled:
self.build_toolchain_headers = enabled
def get_parameters(self):
# retrieve the parameters from bitbake
params = {}
params["core_base"] = self.server.runCommand(["getVariable", "COREBASE"]) or ""
hob_layer = params["core_base"] + "/meta-hob"
params["layer"] = (self.server.runCommand(["getVariable", "BBLAYERS"]) or "") + " " + hob_layer
params["dldir"] = self.server.runCommand(["getVariable", "DL_DIR"]) or ""
params["machine"] = self.server.runCommand(["getVariable", "MACHINE"]) or ""
params["distro"] = self.server.runCommand(["getVariable", "DISTRO"]) or "defaultsetup"
params["pclass"] = self.server.runCommand(["getVariable", "PACKAGE_CLASSES"]) or ""
params["sstatedir"] = self.server.runCommand(["getVariable", "SSTATE_DIR"]) or ""
params["sstatemirror"] = self.server.runCommand(["getVariable", "SSTATE_MIRROR"]) or ""
def set_fstypes(self, fstypes):
self.server.runCommand(["setVariable", "IMAGE_FSTYPES", fstypes])
num_threads = self.server.runCommand(["getCpuCount"])
if not num_threads:
num_threads = 1
max_threads = 65536
else:
num_threads = int(num_threads)
max_threads = 16 * num_threads
params["max_threads"] = max_threads
def add_image_output_type(self, output_type):
if output_type not in self.image_output_types:
self.image_output_types.append(output_type)
fstypes = " ".join(self.image_output_types).lstrip(" ")
self.set_fstypes(fstypes)
return self.image_output_types
bbthread = self.server.runCommand(["getVariable", "BB_NUMBER_THREADS"])
if not bbthread:
bbthread = num_threads
else:
bbthread = int(bbthread)
params["bbthread"] = bbthread
def remove_image_output_type(self, output_type):
if output_type in self.image_output_types:
ind = self.image_output_types.index(output_type)
self.image_output_types.pop(ind)
fstypes = " ".join(self.image_output_types).lstrip(" ")
self.set_fstypes(fstypes)
return self.image_output_types
pmake = self.server.runCommand(["getVariable", "PARALLEL_MAKE"])
if not pmake:
pmake = num_threads
elif isinstance(pmake, int):
pass
else:
pmake = int(pmake.lstrip("-j "))
params["pmake"] = pmake
def get_image_deploy_dir(self):
return self.image_out_dir
image_addr = self.server.runCommand(["getVariable", "DEPLOY_DIR_IMAGE"]) or ""
if self.server_addr:
image_addr = "http://" + self.server_addr + ":" + image_addr
params["image_addr"] = image_addr
def make_temp_dir(self):
bb.utils.mkdirhier(self.image_dir)
image_extra_size = self.server.runCommand(["getVariable", "IMAGE_ROOTFS_EXTRA_SPACE"])
if not image_extra_size:
image_extra_size = 0
else:
image_extra_size = int(image_extra_size)
params["image_extra_size"] = image_extra_size
def remove_temp_dir(self):
bb.utils.remove(self.image_dir, True)
image_rootfs_size = self.server.runCommand(["getVariable", "IMAGE_ROOTFS_SIZE"])
if not image_rootfs_size:
image_rootfs_size = 0
else:
image_rootfs_size = int(image_rootfs_size)
params["image_rootfs_size"] = image_rootfs_size
def get_temp_recipe_path(self, name):
timestamp = datetime.date.today().isoformat()
image_file = "hob-%s-variant-%s.bb" % (name, timestamp)
recipepath = os.path.join(self.image_dir, image_file)
return recipepath
image_overhead_factor = self.server.runCommand(["getVariable", "IMAGE_OVERHEAD_FACTOR"])
if not image_overhead_factor:
image_overhead_factor = 1
else:
image_overhead_factor = float(image_overhead_factor)
params['image_overhead_factor'] = image_overhead_factor
params["incompat_license"] = self.server.runCommand(["getVariable", "INCOMPATIBLE_LICENSE"]) or ""
params["sdk_machine"] = self.server.runCommand(["getVariable", "SDKMACHINE"]) or self.server.runCommand(["getVariable", "SDK_ARCH"]) or ""
#params["image_types"] = self.server.runCommand(["getVariable", "IMAGE_TYPES"]) or ""
params["image_fstypes"] = self.server.runCommand(["getVariable", "IMAGE_FSTYPES"]) or ""
"""
A workaround
"""
params["image_types"] = "jffs2 sum.jffs2 cramfs ext2 ext2.gz ext2.bz2 ext3 ext3.gz ext2.lzma btrfs live squashfs squashfs-lzma ubi tar tar.gz tar.bz2 tar.xz cpio cpio.gz cpio.xz cpio.lzma"
return params

View File

@@ -0,0 +1,765 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import gobject
#
# PackageListModel
#
class PackageListModel(gtk.TreeStore):
"""
This class defines an gtk.TreeStore subclass which will convert the output
of the bb.event.TargetsTreeGenerated event into a gtk.TreeStore whilst also
providing convenience functions to access gtk.TreeModel subclasses which
provide filtered views of the data.
"""
(COL_NAME, COL_VER, COL_REV, COL_RNM, COL_SEC, COL_SUM, COL_RDEP, COL_RPROV, COL_SIZE, COL_BINB, COL_INC) = range(11)
__gsignals__ = {
"packagelist-populated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"package-selection-changed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
}
def __init__(self):
self.contents = None
self.images = None
self.pkgs_size = 0
self.pn_path = {}
self.pkg_path = {}
gtk.TreeStore.__init__ (self,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_BOOLEAN)
"""
Find the model path for the item_name
Returns the path in the model or None
"""
def find_path_for_item(self, item_name):
if item_name not in self.pkg_path.keys():
return None
else:
return self.pkg_path[item_name]
def find_item_for_path(self, item_path):
return self[item_path][self.COL_NAME]
"""
Helper function to determine whether an item is an item specified by filter
"""
def tree_model_filter(self, model, it, filter):
for key in filter.keys():
if model.get_value(it, key) not in filter[key]:
return False
return True
"""
Create, if required, and return a filtered gtk.TreeModelSort
containing only the items specified by filter
"""
def tree_model(self, filter):
model = self.filter_new()
model.set_visible_func(self.tree_model_filter, filter)
sort = gtk.TreeModelSort(model)
sort.set_sort_column_id(PackageListModel.COL_NAME, gtk.SORT_ASCENDING)
sort.set_default_sort_func(None)
return sort
def convert_vpath_to_path(self, view_model, view_path):
# view_model is the model sorted
# get the path of the model filtered
filtered_model_path = view_model.convert_path_to_child_path(view_path)
# get the model filtered
filtered_model = view_model.get_model()
# get the path of the original model
path = filtered_model.convert_path_to_child_path(filtered_model_path)
return path
def convert_path_to_vpath(self, view_model, path):
name = self.find_item_for_path(path)
it = view_model.get_iter_first()
while it:
child_it = view_model.iter_children(it)
while child_it:
view_name = view_model.get_value(child_it, self.COL_NAME)
if view_name == name:
view_path = view_model.get_path(child_it)
return view_path
child_it = view_model.iter_next(child_it)
it = view_model.iter_next(it)
return None
"""
The populate() function takes as input the data from a
bb.event.PackageInfo event and populates the package list.
Once the population is done it emits gsignal packagelist-populated
to notify any listeners that the model is ready
"""
def populate(self, pkginfolist):
self.clear()
self.pkgs_size = 0
self.pn_path = {}
self.pkg_path = {}
for pkginfo in pkginfolist:
pn = pkginfo['PN']
pv = pkginfo['PV']
pr = pkginfo['PR']
if pn in self.pn_path.keys():
pniter = self.get_iter(self.pn_path[pn])
else:
pniter = self.append(None)
self.set(pniter, self.COL_NAME, pn + '-' + pv + '-' + pr,
self.COL_INC, False)
self.pn_path[pn] = self.get_path(pniter)
pkg = pkginfo['PKG']
pkgv = pkginfo['PKGV']
pkgr = pkginfo['PKGR']
pkgsize = pkginfo['PKGSIZE_%s' % pkg] if 'PKGSIZE_%s' % pkg in pkginfo.keys() else "0"
pkg_rename = pkginfo['PKG_%s' % pkg] if 'PKG_%s' % pkg in pkginfo.keys() else ""
section = pkginfo['SECTION_%s' % pkg] if 'SECTION_%s' % pkg in pkginfo.keys() else ""
summary = pkginfo['SUMMARY_%s' % pkg] if 'SUMMARY_%s' % pkg in pkginfo.keys() else ""
rdep = pkginfo['RDEPENDS_%s' % pkg] if 'RDEPENDS_%s' % pkg in pkginfo.keys() else ""
rrec = pkginfo['RRECOMMENDS_%s' % pkg] if 'RRECOMMENDS_%s' % pkg in pkginfo.keys() else ""
rprov = pkginfo['RPROVIDES_%s' % pkg] if 'RPROVIDES_%s' % pkg in pkginfo.keys() else ""
if 'ALLOW_EMPTY_%s' % pkg in pkginfo.keys():
allow_empty = pkginfo['ALLOW_EMPTY_%s' % pkg]
elif 'ALLOW_EMPTY' in pkginfo.keys():
allow_empty = pkginfo['ALLOW_EMPTY']
else:
allow_empty = ""
if pkgsize == "0" and not allow_empty:
continue
if len(pkgsize) > 3:
size = '%.1f' % (int(pkgsize)*1.0/1024) + ' MB'
else:
size = pkgsize + ' KB'
it = self.append(pniter)
self.pkg_path[pkg] = self.get_path(it)
self.set(it, self.COL_NAME, pkg, self.COL_VER, pkgv,
self.COL_REV, pkgr, self.COL_RNM, pkg_rename,
self.COL_SEC, section, self.COL_SUM, summary,
self.COL_RDEP, rdep + ' ' + rrec,
self.COL_RPROV, rprov, self.COL_SIZE, size,
self.COL_BINB, "", self.COL_INC, False)
self.emit("packagelist-populated")
"""
Check whether the item at item_path is included or not
"""
def path_included(self, item_path):
return self[item_path][self.COL_INC]
"""
Update the model, send out the notification.
"""
def selection_change_notification(self):
self.emit("package-selection-changed")
"""
Mark a certain package as selected.
All its dependencies are marked as selected.
The recipe provides the package is marked as selected.
If user explicitly selects a recipe, all its providing packages are selected
"""
def include_item(self, item_path, binb=""):
if self.path_included(item_path):
return
item_name = self[item_path][self.COL_NAME]
item_rdep = self[item_path][self.COL_RDEP]
self[item_path][self.COL_INC] = True
self.selection_change_notification()
it = self.get_iter(item_path)
# If user explicitly selects a recipe, all its providing packages are selected.
if not self[item_path][self.COL_VER] and binb == "User Selected":
child_it = self.iter_children(it)
while child_it:
child_path = self.get_path(child_it)
child_included = self.path_included(child_path)
if not child_included:
self.include_item(child_path, binb="User Selected")
child_it = self.iter_next(child_it)
return
# The recipe provides the package is also marked as selected
parent_it = self.iter_parent(it)
if parent_it:
parent_path = self.get_path(parent_it)
self[parent_path][self.COL_INC] = True
item_bin = self[item_path][self.COL_BINB].split(', ')
if binb and not binb in item_bin:
item_bin.append(binb)
self[item_path][self.COL_BINB] = ', '.join(item_bin).lstrip(', ')
if item_rdep:
# Ensure all of the items deps are included and, where appropriate,
# add this item to their COL_BINB
for dep in item_rdep.split(" "):
if dep.startswith('('):
continue
# If the contents model doesn't already contain dep, add it
dep_path = self.find_path_for_item(dep)
if not dep_path:
continue
dep_included = self.path_included(dep_path)
if dep_included and not dep in item_bin:
# don't set the COL_BINB to this item if the target is an
# item in our own COL_BINB
dep_bin = self[dep_path][self.COL_BINB].split(', ')
if not item_name in dep_bin:
dep_bin.append(item_name)
self[dep_path][self.COL_BINB] = ', '.join(dep_bin).lstrip(', ')
elif not dep_included:
self.include_item(dep_path, binb=item_name)
"""
Mark a certain package as de-selected.
All other packages that depends on this package are marked as de-selected.
If none of the packages provided by the recipe, the recipe should be marked as de-selected.
If user explicitly de-select a recipe, all its providing packages are de-selected.
"""
def exclude_item(self, item_path):
if not self.path_included(item_path):
return
self[item_path][self.COL_INC] = False
self.selection_change_notification()
item_name = self[item_path][self.COL_NAME]
item_rdep = self[item_path][self.COL_RDEP]
it = self.get_iter(item_path)
# If user explicitly de-select a recipe, all its providing packages are de-selected.
if not self[item_path][self.COL_VER]:
child_it = self.iter_children(it)
while child_it:
child_path = self.get_path(child_it)
child_included = self[child_path][self.COL_INC]
if child_included:
self.exclude_item(child_path)
child_it = self.iter_next(child_it)
return
# If none of the packages provided by the recipe, the recipe should be marked as de-selected.
parent_it = self.iter_parent(it)
peer_iter = self.iter_children(parent_it)
enabled = 0
while peer_iter:
peer_path = self.get_path(peer_iter)
if self[peer_path][self.COL_INC]:
enabled = 1
break
peer_iter = self.iter_next(peer_iter)
if not enabled:
parent_path = self.get_path(parent_it)
self[parent_path][self.COL_INC] = False
# All packages that depends on this package are de-selected.
if item_rdep:
for dep in item_rdep.split(" "):
if dep.startswith('('):
continue
dep_path = self.find_path_for_item(dep)
if not dep_path:
continue
dep_bin = self[dep_path][self.COL_BINB].split(', ')
if item_name in dep_bin:
dep_bin.remove(item_name)
self[dep_path][self.COL_BINB] = ', '.join(dep_bin).lstrip(', ')
item_bin = self[item_path][self.COL_BINB].split(', ')
if item_bin:
for binb in item_bin:
binb_path = self.find_path_for_item(binb)
if not binb_path:
continue
self.exclude_item(binb_path)
"""
Package model may be incomplete, therefore when calling the
set_selected_packages(), some packages will not be set included.
Return the un-set packages list.
"""
def set_selected_packages(self, packagelist):
left = []
for pn in packagelist:
if pn in self.pkg_path.keys():
path = self.pkg_path[pn]
self.include_item(item_path=path,
binb="User Selected")
else:
left.append(pn)
return left
def get_selected_packages(self):
packagelist = []
it = self.get_iter_first()
while it:
child_it = self.iter_children(it)
while child_it:
if self.get_value(child_it, self.COL_INC):
name = self.get_value(child_it, self.COL_NAME)
packagelist.append(name)
child_it = self.iter_next(child_it)
it = self.iter_next(it)
return packagelist
"""
Return the selected package size, unit is KB.
"""
def get_packages_size(self):
packages_size = 0
it = self.get_iter_first()
while it:
child_it = self.iter_children(it)
while child_it:
if self.get_value(child_it, self.COL_INC):
str_size = self.get_value(child_it, self.COL_SIZE)
if not str_size:
continue
unit = str_size.split()
if unit[1] == 'MB':
size = float(unit[0])*1024
else:
size = float(unit[0])
packages_size += size
child_it = self.iter_next(child_it)
it = self.iter_next(it)
return "%f" % packages_size
"""
Empty self.contents by setting the include of each entry to None
"""
def reset(self):
self.pkgs_size = 0
it = self.get_iter_first()
while it:
self.set(it, self.COL_INC, False)
child_it = self.iter_children(it)
while child_it:
self.set(child_it,
self.COL_INC, False,
self.COL_BINB, "")
child_it = self.iter_next(child_it)
it = self.iter_next(it)
self.selection_change_notification()
#
# RecipeListModel
#
class RecipeListModel(gtk.ListStore):
"""
This class defines an gtk.ListStore subclass which will convert the output
of the bb.event.TargetsTreeGenerated event into a gtk.ListStore whilst also
providing convenience functions to access gtk.TreeModel subclasses which
provide filtered views of the data.
"""
(COL_NAME, COL_DESC, COL_LIC, COL_GROUP, COL_DEPS, COL_BINB, COL_TYPE, COL_INC, COL_IMG, COL_INSTALL, COL_PN) = range(11)
__dummy_image__ = "--select a base image--"
__gsignals__ = {
"recipelist-populated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"recipe-selection-changed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
}
"""
"""
def __init__(self):
gtk.ListStore.__init__ (self,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_BOOLEAN,
gobject.TYPE_BOOLEAN,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING)
"""
Find the model path for the item_name
Returns the path in the model or None
"""
def find_path_for_item(self, item_name):
if self.non_target_name(item_name) or item_name not in self.pn_path.keys():
return None
else:
return self.pn_path[item_name]
def find_item_for_path(self, item_path):
return self[item_path][self.COL_NAME]
"""
Helper method to determine whether name is a target pn
"""
def non_target_name(self, name):
if name and ('-native' in name):
return True
return False
"""
Helper function to determine whether an item is an item specified by filter
"""
def tree_model_filter(self, model, it, filter):
name = model.get_value(it, self.COL_NAME)
if self.non_target_name(name):
return False
for key in filter.keys():
if model.get_value(it, key) not in filter[key]:
return False
return True
def sort_func(self, model, iter1, iter2):
val1 = model.get_value(iter1, RecipeListModel.COL_NAME)
val2 = model.get_value(iter2, RecipeListModel.COL_NAME)
return val1 > val2
"""
Create, if required, and return a filtered gtk.TreeModelSort
containing only the items which are items specified by filter
"""
def tree_model(self, filter):
model = self.filter_new()
model.set_visible_func(self.tree_model_filter, filter)
sort = gtk.TreeModelSort(model)
sort.set_default_sort_func(self.sort_func)
return sort
def convert_vpath_to_path(self, view_model, view_path):
filtered_model_path = view_model.convert_path_to_child_path(view_path)
filtered_model = view_model.get_model()
# get the path of the original model
path = filtered_model.convert_path_to_child_path(filtered_model_path)
return path
def convert_path_to_vpath(self, view_model, path):
it = view_model.get_iter_first()
while it:
name = self.find_item_for_path(path)
view_name = view_model.get_value(it, RecipeListModel.COL_NAME)
if view_name == name:
view_path = view_model.get_path(it)
return view_path
it = view_model.iter_next(it)
return None
def map_runtime(self, event_model, runtime, rdep_type, name):
if rdep_type not in ['pkg', 'pn'] or runtime not in ['rdepends', 'rrecs']:
return
package_depends = event_model["%s-%s" % (runtime, rdep_type)].get(name, [])
pn_depends = []
for package_depend in package_depends:
if 'task-' not in package_depend and package_depend in event_model["packages"].keys():
pn_depends.append(event_model["packages"][package_depend]["pn"])
else:
pn_depends.append(package_depend)
return list(set(pn_depends))
def subpkg_populate(self, event_model, pkg, desc, lic, group, atype, pn):
pn_depends = self.map_runtime(event_model, "rdepends", "pkg", pkg)
pn_depends += self.map_runtime(event_model, "rrecs", "pkg", pkg)
self.set(self.append(), self.COL_NAME, pkg, self.COL_DESC, desc,
self.COL_LIC, lic, self.COL_GROUP, group,
self.COL_DEPS, " ".join(pn_depends), self.COL_BINB, "",
self.COL_TYPE, atype, self.COL_INC, False,
self.COL_IMG, False, self.COL_INSTALL, "", self.COL_PN, pn)
"""
The populate() function takes as input the data from a
bb.event.TargetsTreeGenerated event and populates the RecipeList.
Once the population is done it emits gsignal recipelist-populated
to notify any listeners that the model is ready
"""
def populate(self, event_model):
# First clear the model, in case repopulating
self.clear()
# dummy image for prompt
self.set(self.append(), self.COL_NAME, self.__dummy_image__,
self.COL_DESC, "",
self.COL_LIC, "", self.COL_GROUP, "",
self.COL_DEPS, "", self.COL_BINB, "",
self.COL_TYPE, "image", self.COL_INC, False,
self.COL_IMG, False, self.COL_INSTALL, "", self.COL_PN, self.__dummy_image__)
for item in event_model["pn"]:
name = item
desc = event_model["pn"][item]["description"]
lic = event_model["pn"][item]["license"]
group = event_model["pn"][item]["section"]
install = []
if ('task-' in name):
if ('lib32-' in name or 'lib64-' in name):
atype = 'mltask'
else:
atype = 'task'
for pkg in event_model["pn"][name]["packages"]:
self.subpkg_populate(event_model, pkg, desc, lic, group, atype, name)
continue
elif ('-image-' in name):
atype = 'image'
depends = event_model["depends"].get(item, [])
rdepends = self.map_runtime(event_model, 'rdepends', 'pn', name)
depends = depends + rdepends
install = event_model["rdepends-pn"].get(item, [])
elif ('meta-' in name):
atype = 'toolchain'
elif (name == 'dummy-image' or name == 'dummy-toolchain'):
atype = 'dummy'
else:
if ('lib32-' in name or 'lib64-' in name):
atype = 'mlrecipe'
else:
atype = 'recipe'
depends = event_model["depends"].get(item, [])
depends += self.map_runtime(event_model, 'rdepends', 'pn', item)
for pkg in event_model["pn"][name]["packages"]:
depends += self.map_runtime(event_model, 'rdepends', 'pkg', item)
depends += self.map_runtime(event_model, 'rrecs', 'pkg', item)
self.set(self.append(), self.COL_NAME, item, self.COL_DESC, desc,
self.COL_LIC, lic, self.COL_GROUP, group,
self.COL_DEPS, " ".join(depends), self.COL_BINB, "",
self.COL_TYPE, atype, self.COL_INC, False,
self.COL_IMG, False, self.COL_INSTALL, " ".join(install), self.COL_PN, item)
self.pn_path = {}
it = self.get_iter_first()
while it:
pn = self.get_value(it, self.COL_NAME)
path = self.get_path(it)
self.pn_path[pn] = path
it = self.iter_next(it)
self.emit("recipelist-populated")
"""
Update the model, send out the notification.
"""
def selection_change_notification(self):
self.emit("recipe-selection-changed")
def path_included(self, item_path):
return self[item_path][self.COL_INC]
"""
Append a certain image into the combobox
"""
def image_list_append(self, name, deps, install):
# check whether a certain image is there
if not name or self.find_path_for_item(name):
return
it = self.append()
self.set(it, self.COL_NAME, name, self.COL_DESC, "",
self.COL_LIC, "", self.COL_GROUP, "",
self.COL_DEPS, deps, self.COL_BINB, "",
self.COL_TYPE, "image", self.COL_INC, False,
self.COL_IMG, False, self.COL_INSTALL, install,
self.COL_PN, name)
self.pn_path[name] = self.get_path(it)
"""
Add this item, and any of its dependencies, to the image contents
"""
def include_item(self, item_path, binb="", image_contents=False):
if self.path_included(item_path):
return
item_name = self[item_path][self.COL_NAME]
item_deps = self[item_path][self.COL_DEPS]
self[item_path][self.COL_INC] = True
self.selection_change_notification()
item_bin = self[item_path][self.COL_BINB].split(', ')
if binb and not binb in item_bin:
item_bin.append(binb)
self[item_path][self.COL_BINB] = ', '.join(item_bin).lstrip(', ')
# We want to do some magic with things which are brought in by the
# base image so tag them as so
if image_contents:
self[item_path][self.COL_IMG] = True
if item_deps:
# Ensure all of the items deps are included and, where appropriate,
# add this item to their COL_BINB
for dep in item_deps.split(" "):
# If the contents model doesn't already contain dep, add it
dep_path = self.find_path_for_item(dep)
if not dep_path:
continue
dep_included = self.path_included(dep_path)
if dep_included and not dep in item_bin:
# don't set the COL_BINB to this item if the target is an
# item in our own COL_BINB
dep_bin = self[dep_path][self.COL_BINB].split(', ')
if not item_name in dep_bin:
dep_bin.append(item_name)
self[dep_path][self.COL_BINB] = ', '.join(dep_bin).lstrip(', ')
elif not dep_included:
self.include_item(dep_path, binb=item_name, image_contents=image_contents)
def exclude_item(self, item_path):
if not self.path_included(item_path):
return
self[item_path][self.COL_INC] = False
self.selection_change_notification()
item_name = self[item_path][self.COL_NAME]
item_deps = self[item_path][self.COL_DEPS]
if item_deps:
for dep in item_deps.split(" "):
dep_path = self.find_path_for_item(dep)
if not dep_path:
continue
dep_bin = self[dep_path][self.COL_BINB].split(', ')
if item_name in dep_bin:
dep_bin.remove(item_name)
self[dep_path][self.COL_BINB] = ', '.join(dep_bin).lstrip(', ')
item_bin = self[item_path][self.COL_BINB].split(', ')
if item_bin:
for binb in item_bin:
binb_path = self.find_path_for_item(binb)
if not binb_path:
continue
self.exclude_item(binb_path)
def reset(self):
it = self.get_iter_first()
while it:
self.set(it,
self.COL_INC, False,
self.COL_BINB, "",
self.COL_IMG, False)
it = self.iter_next(it)
self.selection_change_notification()
"""
Returns two lists. One of user selected recipes and the other containing
all selected recipes
"""
def get_selected_recipes(self):
allrecipes = []
userrecipes = []
it = self.get_iter_first()
while it:
if self.get_value(it, self.COL_INC):
name = self.get_value(it, self.COL_PN)
type = self.get_value(it, self.COL_TYPE)
if type != "image":
allrecipes.append(name)
sel = "User Selected" in self.get_value(it, self.COL_BINB)
if sel:
userrecipes.append(name)
it = self.iter_next(it)
return list(set(userrecipes)), list(set(allrecipes))
def set_selected_recipes(self, recipelist):
for pn in recipelist:
if pn in self.pn_path.keys():
path = self.pn_path[pn]
self.include_item(item_path=path,
binb="User Selected")
def get_selected_image(self):
it = self.get_iter_first()
while it:
if self.get_value(it, self.COL_INC):
name = self.get_value(it, self.COL_PN)
type = self.get_value(it, self.COL_TYPE)
if type == "image":
sel = "User Selected" in self.get_value(it, self.COL_BINB)
if sel:
return name
it = self.iter_next(it)
return None
def set_selected_image(self, img):
if img == None:
return
path = self.find_path_for_item(img)
self.include_item(item_path=path,
binb="User Selected",
image_contents=True)

View File

@@ -0,0 +1,87 @@
#!/usr/bin/env python
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2012 Intel Corporation
#
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
from bb.ui.crumbs.hobcolor import HobColors
from bb.ui.crumbs.hobwidget import hwc
#
# HobPage: the super class for all Hob-related pages
#
class HobPage (gtk.VBox):
def __init__(self, builder, title = None):
super(HobPage, self).__init__(False, 0)
self.builder = builder
self.builder_width, self.builder_height = self.builder.size_request()
if title == None:
self.title = "HOB -- Image Creator"
else:
self.title = title
self.box_group_area = gtk.VBox(False, 15)
self.box_group_area.set_size_request(self.builder_width - 73 - 73, self.builder_height - 88 - 15 - 15)
self.group_align = gtk.Alignment(xalign = 0, yalign=0.5, xscale=1, yscale=1)
self.group_align.set_padding(15, 15, 73, 73)
self.group_align.add(self.box_group_area)
self.box_group_area.set_homogeneous(False)
def add_onto_top_bar(self, widget = None, padding = 0):
# the top button occupies 1/7 of the page height
# setup an event box
eventbox = gtk.EventBox()
style = eventbox.get_style().copy()
style.bg[gtk.STATE_NORMAL] = eventbox.get_colormap().alloc_color(HobColors.LIGHT_GRAY, False, False)
eventbox.set_style(style)
eventbox.set_size_request(-1, 88)
hbox = gtk.HBox()
label = gtk.Label()
label.set_markup("<span font_desc=\'14\'>%s</span>" % self.title)
hbox.pack_start(label, expand=False, fill=False, padding=20)
if widget != None:
# add the widget in the event box
hbox.pack_end(widget, expand=False, fill=False, padding=padding)
eventbox.add(hbox)
return eventbox
def span_tag(self, px="12px", weight="normal", forground="#1c1c1c"):
span_tag = "weight=\'%s\' foreground=\'%s\' font_desc=\'%s\'" % (weight, forground, px)
return span_tag
def append_toolbar_button(self, toolbar, buttonname, icon_disp, icon_hovor, tip, cb):
# Create a button and append it on the toolbar according to button name
icon = gtk.Image()
icon_display = icon_disp
icon_hover = icon_hovor
pix_buffer = gtk.gdk.pixbuf_new_from_file(icon_display)
icon.set_from_pixbuf(pix_buffer)
tip_text = tip
button = toolbar.append_element(gtk.TOOLBAR_CHILD_RADIOBUTTON, None,
buttonname, tip_text, "Private text", icon,
cb, None)
return toolbar, button

View File

@@ -1,335 +0,0 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import glib
from bb.ui.crumbs.configurator import Configurator
class HobPrefs(gtk.Dialog):
"""
"""
def empty_combo_text(self, combo_text):
model = combo_text.get_model()
if model:
model.clear()
def output_type_toggled_cb(self, check, handler):
ot = check.get_label()
enabled = check.get_active()
if enabled:
self.selected_image_types = handler.add_image_output_type(ot)
else:
self.selected_image_types = handler.remove_image_output_type(ot)
self.configurator.setConfVar('IMAGE_FSTYPES', "%s" % " ".join(self.selected_image_types).lstrip(" "))
self.reload_required = True
def sdk_machine_combo_changed_cb(self, combo, handler):
sdk_mach = combo.get_active_text()
if sdk_mach != self.curr_sdk_mach:
self.curr_sdk_mach = sdk_mach
self.configurator.setConfVar('SDKMACHINE', sdk_mach)
handler.set_sdk_machine(sdk_mach)
def update_sdk_machines(self, handler, sdk_machines):
active = 0
# disconnect the signal handler before updating the combo model
if self.sdk_machine_handler_id:
self.sdk_machine_combo.disconnect(self.sdk_machine_handler_id)
self.sdk_machine_handler_id = None
self.empty_combo_text(self.sdk_machine_combo)
for sdk_machine in sdk_machines:
self.sdk_machine_combo.append_text(sdk_machine)
if sdk_machine == self.curr_sdk_mach:
self.sdk_machine_combo.set_active(active)
active = active + 1
self.sdk_machine_handler_id = self.sdk_machine_combo.connect("changed", self.sdk_machine_combo_changed_cb, handler)
def distro_combo_changed_cb(self, combo, handler):
distro = combo.get_active_text()
if distro != self.curr_distro:
self.curr_distro = distro
self.configurator.setConfVar('DISTRO', distro)
handler.set_distro(distro)
self.reload_required = True
def update_distros(self, handler, distros):
active = 0
# disconnect the signal handler before updating combo model
if self.distro_handler_id:
self.distro_combo.disconnect(self.distro_handler_id)
self.distro_handler_id = None
self.empty_combo_text(self.distro_combo)
for distro in distros:
self.distro_combo.append_text(distro)
if distro == self.curr_distro:
self.distro_combo.set_active(active)
active = active + 1
self.distro_handler_id = self.distro_combo.connect("changed", self.distro_combo_changed_cb, handler)
def package_format_combo_changed_cb(self, combo, handler):
package_format = combo.get_active_text()
if package_format != self.curr_package_format:
self.curr_package_format = package_format
self.configurator.setConfVar('PACKAGE_CLASSES', 'package_%s' % package_format)
handler.set_package_format(package_format)
self.reload_required = True
def update_package_formats(self, handler, formats):
active = 0
# disconnect the signal handler before updating the model
if self.package_handler_id:
self.package_combo.disconnect(self.package_handler_id)
self.package_handler_id = None
self.empty_combo_text(self.package_combo)
for format in formats:
self.package_combo.append_text(format)
if format == self.curr_package_format:
self.package_combo.set_active(active)
active = active + 1
self.package_handler_id = self.package_combo.connect("changed", self.package_format_combo_changed_cb, handler)
def include_gplv3_cb(self, toggle):
excluded = toggle.get_active()
orig_incompatible = self.configurator.getConfVar('INCOMPATIBLE_LICENSE')
new_incompatible = ""
if excluded:
if not orig_incompatible:
new_incompatible = "GPLv3"
elif not orig_incompatible.find('GPLv3'):
new_incompatible = "%s GPLv3" % orig_incompatible
else:
new_incompatible = orig_incompatible.replace('GPLv3', '')
if new_incompatible != orig_incompatible:
self.handler.set_incompatible_license(new_incompatible)
self.configurator.setConfVar('INCOMPATIBLE_LICENSE', new_incompatible)
self.reload_required = True
def change_bb_threads_cb(self, spinner):
val = spinner.get_value_as_int()
self.handler.set_bbthreads(val)
self.configurator.setConfVar('BB_NUMBER_THREADS', val)
def change_make_threads_cb(self, spinner):
val = spinner.get_value_as_int()
self.handler.set_pmake(val)
self.configurator.setConfVar('PARALLEL_MAKE', "-j %s" % val)
def toggle_toolchain_cb(self, check):
enabled = check.get_active()
toolchain = '0'
if enabled:
toolchain = '1'
self.handler.toggle_toolchain(enabled)
self.configurator.setConfVar('HOB_BUILD_TOOLCHAIN', toolchain)
def toggle_headers_cb(self, check):
enabled = check.get_active()
headers = '0'
if enabled:
headers = '1'
self.handler.toggle_toolchain_headers(enabled)
self.configurator.setConfVar('HOB_BUILD_TOOLCHAIN_HEADERS', headers)
def set_parent_window(self, parent):
self.set_transient_for(parent)
def write_changes(self):
self.configurator.writeConf()
def prefs_response_cb(self, dialog, response):
if self.reload_required:
glib.idle_add(self.handler.reload_data)
self.reload_required = False
def __init__(self, configurator, handler, curr_sdk_mach, curr_distro, pclass,
pmake, bbthread, selected_image_types, all_image_types,
gplv3disabled, build_toolchain, build_toolchain_headers):
"""
"""
gtk.Dialog.__init__(self, "Preferences", None,
gtk.DIALOG_DESTROY_WITH_PARENT,
(gtk.STOCK_CLOSE, gtk.RESPONSE_OK))
self.set_border_width(6)
self.vbox.set_property("spacing", 12)
self.action_area.set_property("spacing", 12)
self.action_area.set_property("border-width", 6)
self.handler = handler
self.configurator = configurator
self.curr_sdk_mach = curr_sdk_mach
self.curr_distro = curr_distro
self.curr_package_format = pclass
self.pmake = pmake
self.bbthread = bbthread
self.selected_image_types = selected_image_types.split(" ")
self.gplv3disabled = gplv3disabled
self.build_toolchain = build_toolchain
self.build_toolchain_headers = build_toolchain_headers
self.reload_required = False
self.distro_handler_id = None
self.sdk_machine_handler_id = None
self.package_handler_id = None
left = gtk.SizeGroup(gtk.SIZE_GROUP_HORIZONTAL)
right = gtk.SizeGroup(gtk.SIZE_GROUP_HORIZONTAL)
label = gtk.Label()
label.set_markup("<b>Policy</b>")
label.show()
frame = gtk.Frame()
frame.set_label_widget(label)
frame.set_shadow_type(gtk.SHADOW_NONE)
frame.show()
self.vbox.pack_start(frame)
pbox = gtk.VBox(False, 12)
pbox.show()
frame.add(pbox)
hbox = gtk.HBox(False, 12)
hbox.show()
pbox.pack_start(hbox, expand=False, fill=False, padding=6)
# Distro selector
label = gtk.Label("Distribution:")
label.show()
hbox.pack_start(label, expand=False, fill=False, padding=6)
self.distro_combo = gtk.combo_box_new_text()
self.distro_combo.set_tooltip_text("Select the Yocto distribution you would like to use")
self.distro_combo.show()
hbox.pack_start(self.distro_combo, expand=False, fill=False, padding=6)
# Exclude GPLv3
check = gtk.CheckButton("Exclude GPLv3 packages")
check.set_tooltip_text("Check this box to prevent GPLv3 packages from being included in your image")
check.show()
check.set_active(self.gplv3disabled)
check.connect("toggled", self.include_gplv3_cb)
hbox.pack_start(check, expand=False, fill=False, padding=6)
hbox = gtk.HBox(False, 12)
hbox.show()
pbox.pack_start(hbox, expand=False, fill=False, padding=6)
# Package format selector
label = gtk.Label("Package format:")
label.show()
hbox.pack_start(label, expand=False, fill=False, padding=6)
self.package_combo = gtk.combo_box_new_text()
self.package_combo.set_tooltip_text("""The package format is that used in creation
of the root filesystem and also dictates the package manager used in your image""")
self.package_combo.show()
hbox.pack_start(self.package_combo, expand=False, fill=False, padding=6)
if all_image_types:
# Image output type selector
label = gtk.Label("Image output types:")
label.show()
hbox.pack_start(label, expand=False, fill=False, padding=6)
chk_cnt = 3
for it in all_image_types.split(" "):
chk_cnt = chk_cnt + 1
if chk_cnt % 6 == 0:
hbox = gtk.HBox(False, 12)
hbox.show()
pbox.pack_start(hbox, expand=False, fill=False, padding=6)
chk = gtk.CheckButton(it)
if it in self.selected_image_types:
chk.set_active(True)
chk.set_tooltip_text("Build an %s image" % it)
chk.connect("toggled", self.output_type_toggled_cb, handler)
chk.show()
hbox.pack_start(chk, expand=False, fill=False, padding=3)
# BitBake
label = gtk.Label()
label.set_markup("<b>BitBake</b>")
label.show()
frame = gtk.Frame()
frame.set_label_widget(label)
frame.set_shadow_type(gtk.SHADOW_NONE)
frame.show()
self.vbox.pack_start(frame)
pbox = gtk.VBox(False, 12)
pbox.show()
frame.add(pbox)
hbox = gtk.HBox(False, 12)
hbox.show()
pbox.pack_start(hbox, expand=False, fill=False, padding=6)
label = gtk.Label("BitBake threads:")
label.show()
# NOTE: may be a good idea in future to intelligently cap the maximum
# values but we need more data to make an educated decision, for now
# set a high maximum as a value for upper bounds is required by the
# gtk.Adjustment
spin_max = 30 # seems like a high enough arbitrary number
hbox.pack_start(label, expand=False, fill=False, padding=6)
bbadj = gtk.Adjustment(value=self.bbthread, lower=1, upper=spin_max, step_incr=1)
bbspinner = gtk.SpinButton(adjustment=bbadj, climb_rate=1, digits=0)
bbspinner.show()
bbspinner.connect("value-changed", self.change_bb_threads_cb)
hbox.pack_start(bbspinner, expand=False, fill=False, padding=6)
label = gtk.Label("Make threads:")
label.show()
hbox.pack_start(label, expand=False, fill=False, padding=6)
madj = gtk.Adjustment(value=self.pmake, lower=1, upper=spin_max, step_incr=1)
makespinner = gtk.SpinButton(adjustment=madj, climb_rate=1, digits=0)
makespinner.connect("value-changed", self.change_make_threads_cb)
makespinner.show()
hbox.pack_start(makespinner, expand=False, fill=False, padding=6)
# Toolchain
label = gtk.Label()
label.set_markup("<b>External Toolchain</b>")
label.show()
frame = gtk.Frame()
frame.set_label_widget(label)
frame.set_shadow_type(gtk.SHADOW_NONE)
frame.show()
self.vbox.pack_start(frame)
pbox = gtk.VBox(False, 12)
pbox.show()
frame.add(pbox)
hbox = gtk.HBox(False, 12)
hbox.show()
pbox.pack_start(hbox, expand=False, fill=False, padding=6)
toolcheck = gtk.CheckButton("Build external development toolchain with image")
toolcheck.show()
toolcheck.set_active(self.build_toolchain)
toolcheck.connect("toggled", self.toggle_toolchain_cb)
hbox.pack_start(toolcheck, expand=False, fill=False, padding=6)
hbox = gtk.HBox(False, 12)
hbox.show()
pbox.pack_start(hbox, expand=False, fill=False, padding=6)
label = gtk.Label("Toolchain host:")
label.show()
hbox.pack_start(label, expand=False, fill=False, padding=6)
self.sdk_machine_combo = gtk.combo_box_new_text()
self.sdk_machine_combo.set_tooltip_text("Select the host architecture of the external machine")
self.sdk_machine_combo.show()
hbox.pack_start(self.sdk_machine_combo, expand=False, fill=False, padding=6)
# headerscheck = gtk.CheckButton("Include development headers with toolchain")
# headerscheck.show()
# headerscheck.set_active(self.build_toolchain_headers)
# headerscheck.connect("toggled", self.toggle_headers_cb)
# hbox.pack_start(headerscheck, expand=False, fill=False, padding=6)
self.connect("response", self.prefs_response_cb)

View File

@@ -0,0 +1,805 @@
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011-2012 Intel Corporation
#
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import gobject
import os
import os.path
from bb.ui.crumbs.hobcolor import HobColors
class hwc:
MAIN_WIN_WIDTH = 1024
MAIN_WIN_HEIGHT = 700
class hic:
HOB_ICON_BASE_DIR = os.path.join(os.path.dirname(os.path.dirname(os.path.dirname(__file__))), ("ui/icons/"))
ICON_RCIPE_DISPLAY_FILE = os.path.join(HOB_ICON_BASE_DIR, ('recipe/recipe_display.png'))
ICON_RCIPE_HOVER_FILE = os.path.join(HOB_ICON_BASE_DIR, ('recipe/recipe_hover.png'))
ICON_PACKAGES_DISPLAY_FILE = os.path.join(HOB_ICON_BASE_DIR, ('packages/packages_display.png'))
ICON_PACKAGES_HOVER_FILE = os.path.join(HOB_ICON_BASE_DIR, ('packages/packages_hover.png'))
ICON_LAYERS_DISPLAY_FILE = os.path.join(HOB_ICON_BASE_DIR, ('layers/layers_display.png'))
ICON_LAYERS_HOVER_FILE = os.path.join(HOB_ICON_BASE_DIR, ('layers/layers_hover.png'))
ICON_TEMPLATES_DISPLAY_FILE = os.path.join(HOB_ICON_BASE_DIR, ('templates/templates_display.png'))
ICON_TEMPLATES_HOVER_FILE = os.path.join(HOB_ICON_BASE_DIR, ('templates/templates_hover.png'))
ICON_IMAGES_DISPLAY_FILE = os.path.join(HOB_ICON_BASE_DIR, ('images/images_display.png'))
ICON_IMAGES_HOVER_FILE = os.path.join(HOB_ICON_BASE_DIR, ('images/images_hover.png'))
ICON_SETTINGS_DISPLAY_FILE = os.path.join(HOB_ICON_BASE_DIR, ('settings/settings_display.png'))
ICON_SETTINGS_HOVER_FILE = os.path.join(HOB_ICON_BASE_DIR, ('settings/settings_hover.png'))
ICON_INFO_DISPLAY_FILE = os.path.join(HOB_ICON_BASE_DIR, ('info/info_display.png'))
ICON_INFO_HOVER_FILE = os.path.join(HOB_ICON_BASE_DIR, ('info/info_hover.png'))
ICON_INDI_CONFIRM_FILE = os.path.join(HOB_ICON_BASE_DIR, ('indicators/confirmation.png'))
ICON_INDI_ERROR_FILE = os.path.join(HOB_ICON_BASE_DIR, ('indicators/error.png'))
class HobWidget:
@classmethod
def resize_widget(cls, screen, widget, widget_width, widget_height):
screen_width, screen_height = screen.get_size_request()
ratio_height = screen_width * hwc.MAIN_WIN_HEIGHT/hwc.MAIN_WIN_WIDTH
if ratio_height < screen_height:
screen_height = ratio_height
widget_width = widget_width * screen_width/hwc.MAIN_WIN_WIDTH
widget_height = widget_height * screen_height/hwc.MAIN_WIN_HEIGHT
widget.set_size_request(widget_width, widget_height)
@classmethod
def _toggle_cb(cls, cell, path, model, column):
it = model.get_iter(path)
val = model.get_value(it, column)
val = not val
model.set(it, column, val)
@classmethod
def _pkgfmt_up_clicked_cb(cls, button, tree_selection):
(model, it) = tree_selection.get_selected()
if not it:
return
path = model.get_path(it)
if path[0] <= 0:
return
pre_it = model.get_iter_first()
if not pre_it:
return
else:
while model.iter_next(pre_it) :
if model.get_value(model.iter_next(pre_it), 1) != model.get_value(it, 1):
pre_it = model.iter_next(pre_it)
else:
break
cur_index = model.get_value(it, 0)
pre_index = cur_index
if pre_it:
model.set(pre_it, 0, pre_index)
cur_index = cur_index - 1
model.set(it, 0, cur_index)
@classmethod
def _pkgfmt_down_clicked_cb(cls, button, tree_selection):
(model, it) = tree_selection.get_selected()
if not it:
return
next_it = model.iter_next(it)
if not next_it:
return
cur_index = model.get_value(it, 0)
next_index = cur_index
model.set(next_it, 0, next_index)
cur_index = cur_index + 1
model.set(it, 0, cur_index)
@classmethod
def _tree_selection_changed_cb(cls, tree_selection, button1, button2):
(model, it) = tree_selection.get_selected()
inc = model.get_value(it, 2)
if inc:
button1.set_sensitive(True)
button2.set_sensitive(True)
else:
button1.set_sensitive(False)
button2.set_sensitive(False)
@classmethod
def _sort_func(cls, model, iter1, iter2, data):
val1 = model.get_value(iter1, 0)
val2 = model.get_value(iter2, 0)
inc1 = model.get_value(iter1, 2)
inc2 = model.get_value(iter2, 2)
if inc1 != inc2:
return inc2 - inc1
else:
return val1 - val2
@classmethod
def gen_pkgfmt_widget(cls, curr_package_format, all_package_format, tooltip=""):
pkgfmt_hbox = gtk.HBox(False, 15)
pkgfmt_store = gtk.ListStore(int, str, gobject.TYPE_BOOLEAN)
for format in curr_package_format.split():
pkgfmt_store.set(pkgfmt_store.append(), 1, format, 2, True)
for format in all_package_format:
if format not in curr_package_format:
pkgfmt_store.set(pkgfmt_store.append(), 1, format, 2, False)
pkgfmt_tree = gtk.TreeView(pkgfmt_store)
pkgfmt_tree.set_headers_clickable(True)
pkgfmt_tree.set_headers_visible(False)
tree_selection = pkgfmt_tree.get_selection()
tree_selection.set_mode(gtk.SELECTION_SINGLE)
col = gtk.TreeViewColumn('NO')
col.set_sort_column_id(0)
col.set_sort_order(gtk.SORT_ASCENDING)
col.set_clickable(False)
col1 = gtk.TreeViewColumn('TYPE')
col1.set_min_width(130)
col1.set_max_width(140)
col2 = gtk.TreeViewColumn('INCLUDED')
col2.set_min_width(60)
col2.set_max_width(70)
pkgfmt_tree.append_column(col1)
pkgfmt_tree.append_column(col2)
cell = gtk.CellRendererText()
cell1 = gtk.CellRendererText()
cell1.set_property('width-chars', 10)
cell2 = gtk.CellRendererToggle()
cell2.set_property('activatable', True)
cell2.connect("toggled", cls._toggle_cb, pkgfmt_store, 2)
col.pack_start(cell, True)
col1.pack_start(cell1, True)
col2.pack_end(cell2, True)
col.set_attributes(cell, text=0)
col1.set_attributes(cell1, text=1)
col2.set_attributes(cell2, active=2)
pkgfmt_store.set_sort_func(0, cls._sort_func, None)
pkgfmt_store.set_sort_column_id(0, gtk.SORT_ASCENDING)
scroll = gtk.ScrolledWindow()
scroll.set_policy(gtk.POLICY_NEVER, gtk.POLICY_AUTOMATIC)
scroll.set_shadow_type(gtk.SHADOW_IN)
scroll.add(pkgfmt_tree)
scroll.set_size_request(200,60)
pkgfmt_hbox.pack_start(scroll, False, False, 0)
vbox = gtk.VBox(False, 5)
pkgfmt_hbox.pack_start(vbox, False, False, 15)
up = gtk.Button()
image = gtk.Image()
image.set_from_stock(gtk.STOCK_GO_UP, gtk.ICON_SIZE_MENU)
up.set_image(image)
up.set_size_request(50,30)
up.connect("clicked", cls._pkgfmt_up_clicked_cb, tree_selection)
vbox.pack_start(up, False, False, 5)
down = gtk.Button()
image = gtk.Image()
image.set_from_stock(gtk.STOCK_GO_DOWN, gtk.ICON_SIZE_MENU)
down.set_image(image)
down.set_size_request(50,30)
down.connect("clicked", cls._pkgfmt_down_clicked_cb, tree_selection)
vbox.pack_start(down, False, False, 5)
tree_selection.connect("changed", cls._tree_selection_changed_cb, up, down)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
image.set_tooltip_text(tooltip)
pkgfmt_hbox.pack_start(image, expand=False, fill=False)
pkgfmt_hbox.show_all()
return pkgfmt_hbox, pkgfmt_store
@classmethod
def gen_combo_widget(cls, curr_item, all_item, tooltip=""):
hbox = gtk.HBox(False, 10)
combo = gtk.combo_box_new_text()
hbox.pack_start(combo, expand=False, fill=False)
index = 0
for item in all_item or []:
combo.append_text(item)
if item == curr_item:
combo.set_active(index)
index += 1
image = gtk.Image()
image.show()
image.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
image.set_tooltip_text(tooltip)
hbox.pack_start(image, expand=False, fill=False)
hbox.show_all()
return hbox, combo
@classmethod
def gen_label_widget(cls, content):
label = gtk.Label()
label.set_alignment(0, 0)
label.set_markup(content)
label.show()
return label
@classmethod
def _select_path_cb(cls, action, parent, entry):
dialog = gtk.FileChooserDialog("", parent,
gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER,
(gtk.STOCK_OK, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
response = dialog.run()
if response == gtk.RESPONSE_YES:
path = dialog.get_filename()
entry.set_text(path)
dialog.destroy()
@classmethod
def gen_entry_widget(cls, split_model, content, parent, tooltip=""):
hbox = gtk.HBox(False, 10)
entry = gtk.Entry()
entry.set_text(content)
if split_model:
hbox.pack_start(entry, expand=True, fill=True)
else:
table = gtk.Table(1, 10, True)
hbox.pack_start(table, expand=True, fill=True)
table.attach(entry, 0, 9, 0, 1)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_OPEN,gtk.ICON_SIZE_BUTTON)
open_button = gtk.Button()
open_button.set_image(image)
open_button.connect("clicked", cls._select_path_cb, parent, entry)
table.attach(open_button, 9, 10, 0, 1)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
image.set_tooltip_text(tooltip)
hbox.pack_start(image, expand=False, fill=False)
hbox.show_all()
return hbox, entry
@classmethod
def gen_spinner_widget(cls, content, lower, upper, tooltip=""):
hbox = gtk.HBox(False, 10)
adjust = gtk.Adjustment(value=content, lower=lower, upper=upper, step_incr=1)
spinner = gtk.SpinButton(adjustment=adjust, climb_rate=1, digits=0)
spinner.set_value(content)
hbox.pack_start(spinner, expand=False, fill=False)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
image.set_tooltip_text(tooltip)
hbox.pack_start(image, expand=False, fill=False)
hbox.show_all()
return hbox, spinner
@classmethod
def conf_error(cls, parent, lbl):
dialog = CrumbsDialog(parent, lbl)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
response = dialog.run()
dialog.destroy()
@classmethod
def _add_layer_cb(cls, action, layer_store, parent):
dialog = gtk.FileChooserDialog("Add new layer", parent,
gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER,
(gtk.STOCK_OK, gtk.RESPONSE_YES,
gtk.STOCK_CANCEL, gtk.RESPONSE_NO))
label = gtk.Label("Select the layer you wish to add")
label.show()
dialog.set_extra_widget(label)
response = dialog.run()
path = dialog.get_filename()
dialog.destroy()
lbl = "<b>Error</b>\nUnable to load layer <i>%s</i> because " % path
if response == gtk.RESPONSE_YES:
import os
import os.path
layers = []
it = layer_store.get_iter_first()
while it:
layers.append(layer_store.get_value(it, 0))
it = layer_store.iter_next(it)
if not path:
lbl += "it is an invalid path."
elif not os.path.exists(path+"/conf/layer.conf"):
lbl += "there is no layer.conf inside the directory."
elif path in layers:
lbl += "it is already in loaded layers."
else:
layer_store.append([path])
return
cls.conf_error(parent, lbl)
@classmethod
def _del_layer_cb(cls, action, tree_selection, layer_store):
model, iter = tree_selection.get_selected()
if iter:
layer_store.remove(iter)
@classmethod
def _toggle_layer_cb(cls, cell, path, layer_store):
name = layer_store[path][0]
toggle = not layer_store[path][1]
layer_store[path][1] = toggle
@classmethod
def gen_layer_widget(cls, split_model, layers, layers_avail, window, tooltip=""):
hbox = gtk.HBox(False, 10)
layer_tv = gtk.TreeView()
layer_tv.set_rules_hint(True)
layer_tv.set_headers_visible(False)
tree_selection = layer_tv.get_selection()
tree_selection.set_mode(gtk.SELECTION_SINGLE)
col0= gtk.TreeViewColumn('Path')
cell0 = gtk.CellRendererText()
cell0.set_padding(5,2)
col0.pack_start(cell0, True)
col0.set_attributes(cell0, text=0)
layer_tv.append_column(col0)
scroll = gtk.ScrolledWindow()
scroll.set_policy(gtk.POLICY_NEVER, gtk.POLICY_AUTOMATIC)
scroll.set_shadow_type(gtk.SHADOW_IN)
scroll.add(layer_tv)
table_layer = gtk.Table(2, 10, False)
hbox.pack_start(table_layer, expand=True, fill=True)
if split_model:
table_layer.attach(scroll, 0, 10, 0, 2)
layer_store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_BOOLEAN)
for layer in layers:
layer_store.set(layer_store.append(), 0, layer, 1, True)
for layer in layers_avail:
if layer not in layers:
layer_store.set(layer_store.append(), 0, layer, 1, False)
col1 = gtk.TreeViewColumn('Included')
layer_tv.append_column(col1)
cell1 = gtk.CellRendererToggle()
cell1.connect("toggled", cls._toggle_layer_cb, layer_store)
col1.pack_start(cell1, True)
col1.set_attributes(cell1, active=1)
else:
table_layer.attach(scroll, 0, 10, 0, 1)
layer_store = gtk.ListStore(gobject.TYPE_STRING)
for layer in layers:
layer_store.set(layer_store.append(), 0, layer)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_ADD,gtk.ICON_SIZE_MENU)
add_button = gtk.Button()
add_button.set_image(image)
add_button.connect("clicked", cls._add_layer_cb, layer_store, window)
table_layer.attach(add_button, 0, 5, 1, 2, gtk.EXPAND | gtk.FILL, 0, 0, 0)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_REMOVE,gtk.ICON_SIZE_MENU)
del_button = gtk.Button()
del_button.set_image(image)
del_button.connect("clicked", cls._del_layer_cb, tree_selection, layer_store)
table_layer.attach(del_button, 5, 10, 1, 2, gtk.EXPAND | gtk.FILL, 0, 0, 0)
layer_tv.set_model(layer_store)
hbox.show_all()
return hbox, layer_store
@classmethod
def _toggle_single_cb(cls, cell, select_path, treeview, toggle_column):
model = treeview.get_model()
if not model:
return
iter = model.get_iter_first()
while iter:
path = model.get_path(iter)
model[path][toggle_column] = False
iter = model.iter_next(iter)
model[select_path][toggle_column] = True
@classmethod
def gen_imgtv_widget(cls, col0_width, col1_width):
vbox = gtk.VBox(False, 10)
imgsel_tv = gtk.TreeView()
imgsel_tv.set_rules_hint(True)
imgsel_tv.set_headers_visible(False)
tree_selection = imgsel_tv.get_selection()
tree_selection.set_mode(gtk.SELECTION_SINGLE)
col0= gtk.TreeViewColumn('Image name')
cell0 = gtk.CellRendererText()
cell0.set_padding(5,2)
col0.pack_start(cell0, True)
col0.set_attributes(cell0, text=0)
col0.set_max_width(col0_width)
col0.set_min_width(col0_width)
imgsel_tv.append_column(col0)
col1= gtk.TreeViewColumn('Select')
cell1 = gtk.CellRendererToggle()
cell1.set_padding(5,2)
cell1.connect("toggled", cls._toggle_single_cb, imgsel_tv, 1)
col1.pack_start(cell1, True)
col1.set_attributes(cell1, active=1)
col1.set_max_width(col1_width)
col1.set_min_width(col1_width)
imgsel_tv.append_column(col1)
scroll = gtk.ScrolledWindow()
scroll.set_policy(gtk.POLICY_NEVER, gtk.POLICY_AUTOMATIC)
scroll.set_shadow_type(gtk.SHADOW_IN)
scroll.add(imgsel_tv)
vbox.pack_start(scroll, expand=True, fill=True)
return vbox, imgsel_tv
@classmethod
def gen_images_widget(cls, col0_width, col1_width, col2_width):
vbox = gtk.VBox(False, 10)
imgsel_tv = gtk.TreeView()
imgsel_tv.set_rules_hint(True)
imgsel_tv.set_headers_visible(False)
tree_selection = imgsel_tv.get_selection()
tree_selection.set_mode(gtk.SELECTION_SINGLE)
col0= gtk.TreeViewColumn('Image name')
cell0 = gtk.CellRendererText()
cell0.set_padding(5,2)
col0.pack_start(cell0, True)
col0.set_attributes(cell0, text=0)
col0.set_max_width(col0_width)
col0.set_min_width(col0_width)
imgsel_tv.append_column(col0)
col1= gtk.TreeViewColumn('Image size')
cell1 = gtk.CellRendererText()
cell1.set_padding(5,2)
col1.pack_start(cell1, True)
col1.set_attributes(cell1, text=1)
col1.set_max_width(col1_width)
col1.set_min_width(col1_width)
imgsel_tv.append_column(col1)
col2= gtk.TreeViewColumn('Select')
cell2 = gtk.CellRendererToggle()
cell2.set_padding(5,2)
cell2.connect("toggled", cls._toggle_single_cb, imgsel_tv, 2)
col2.pack_start(cell2, True)
col2.set_attributes(cell2, active=2)
col2.set_max_width(col2_width)
col2.set_min_width(col2_width)
imgsel_tv.append_column(col2)
scroll = gtk.ScrolledWindow()
scroll.set_policy(gtk.POLICY_NEVER, gtk.POLICY_AUTOMATIC)
scroll.set_shadow_type(gtk.SHADOW_IN)
scroll.add(imgsel_tv)
vbox.pack_start(scroll, expand=True, fill=True)
return vbox, imgsel_tv
@classmethod
def _on_add_item_clicked(cls, button, model):
new_item = ["##KEY##", "##VALUE##"]
iter = model.append()
model.set (iter,
0, new_item[0],
1, new_item[1],
)
@classmethod
def _on_remove_item_clicked(cls, button, treeview):
selection = treeview.get_selection()
model, iter = selection.get_selected()
if iter:
path = model.get_path(iter)[0]
model.remove(iter)
@classmethod
def _on_cell_edited(cls, cell, path_string, new_text, model):
it = model.get_iter_from_string(path_string)
column = cell.get_data("column")
model.set(it, column, new_text)
@classmethod
def gen_editable_settings(cls, setting, tooltip=""):
setting_hbox = gtk.HBox(False, 10)
vbox = gtk.VBox(False, 10)
setting_hbox.pack_start(vbox, expand=True, fill=True)
setting_store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING)
for key in setting.keys():
setting_store.set(setting_store.append(), 0, key, 1, setting[key])
setting_tree = gtk.TreeView(setting_store)
setting_tree.set_headers_visible(True)
setting_tree.set_size_request(300, 100)
col = gtk.TreeViewColumn('Key')
col.set_min_width(100)
col.set_max_width(150)
col.set_resizable(True)
col1 = gtk.TreeViewColumn('Value')
col1.set_min_width(100)
col1.set_max_width(150)
col1.set_resizable(True)
setting_tree.append_column(col)
setting_tree.append_column(col1)
cell = gtk.CellRendererText()
cell.set_property('width-chars', 10)
cell.set_property('editable', True)
cell.set_data("column", 0)
cell.connect("edited", cls._on_cell_edited, setting_store)
cell1 = gtk.CellRendererText()
cell1.set_property('width-chars', 10)
cell1.set_property('editable', True)
cell1.set_data("column", 1)
cell1.connect("edited", cls._on_cell_edited, setting_store)
col.pack_start(cell, True)
col1.pack_end(cell1, True)
col.set_attributes(cell, text=0)
col1.set_attributes(cell1, text=1)
scroll = gtk.ScrolledWindow()
scroll.set_shadow_type(gtk.SHADOW_IN)
scroll.set_policy(gtk.POLICY_AUTOMATIC, gtk.POLICY_AUTOMATIC)
scroll.add(setting_tree)
vbox.pack_start(scroll, expand=True, fill=True)
# some buttons
hbox = gtk.HBox(True, 4)
vbox.pack_start(hbox, False, False)
button = gtk.Button(stock=gtk.STOCK_ADD)
button.connect("clicked", cls._on_add_item_clicked, setting_store)
hbox.pack_start(button)
button = gtk.Button(stock=gtk.STOCK_REMOVE)
button.connect("clicked", cls._on_remove_item_clicked, setting_tree)
hbox.pack_start(button)
image = gtk.Image()
image.set_from_stock(gtk.STOCK_INFO, gtk.ICON_SIZE_BUTTON)
image.set_tooltip_text(tooltip)
setting_hbox.pack_start(image, expand=False, fill=False)
return setting_hbox, setting_store
class HobViewTable (gtk.VBox):
"""
A VBox to contain the table for different recipe views and package view
"""
def __init__(self, columns, reset_clicked_cb=None, toggled_cb=None):
gtk.VBox.__init__(self, False, 6)
self.table_tree = gtk.TreeView()
self.table_tree.set_headers_visible(True)
self.table_tree.set_headers_clickable(True)
self.table_tree.set_enable_search(True)
self.table_tree.set_search_column(0)
self.table_tree.get_selection().set_mode(gtk.SELECTION_SINGLE)
for i in range(len(columns)):
col = gtk.TreeViewColumn(columns[i]['col_name'])
col.set_clickable(True)
col.set_resizable(True)
col.set_sort_column_id(columns[i]['col_id'])
col.set_min_width(columns[i]['col_min'])
col.set_max_width(columns[i]['col_max'])
self.table_tree.append_column(col)
if columns[i]['col_style'] == 'toggle':
cell = gtk.CellRendererToggle()
cell.set_property('activatable', True)
cell.connect("toggled", toggled_cb, self.table_tree)
col.pack_end(cell, True)
col.set_attributes(cell, active=columns[i]['col_id'])
elif columns[i]['col_style'] == 'text':
cell = gtk.CellRendererText()
col.pack_start(cell, True)
col.set_attributes(cell, text=columns[i]['col_id'])
scroll = gtk.ScrolledWindow()
scroll.set_policy(gtk.POLICY_NEVER, gtk.POLICY_ALWAYS)
scroll.set_shadow_type(gtk.SHADOW_IN)
scroll.add(self.table_tree)
self.pack_start(scroll, True, True, 0)
hbox = gtk.HBox(False, 5)
button = gtk.Button("Reset")
button.connect('clicked', reset_clicked_cb)
hbox.pack_end(button, False, False, 0)
self.pack_start(hbox, False, False, 0)
class HobViewBar (gtk.EventBox):
"""
A EventBox with the specified gray background color is associated with a notebook.
And the toolbar to simulate the tabs.
"""
def __init__(self, notebook):
if not notebook:
return
self.notebook = notebook
# setup an event box
gtk.EventBox.__init__(self)
self.set_border_width(2)
style = self.get_style().copy()
style.bg[gtk.STATE_NORMAL] = self.get_colormap().alloc_color (HobColors.GRAY, False, False)
self.set_style(style)
hbox = gtk.HBox()
self.add(hbox)
# setup a tool bar in the event box
self.toolbar = gtk.Toolbar()
self.toolbar.set_orientation(gtk.ORIENTATION_HORIZONTAL)
self.toolbar.set_style(gtk.TOOLBAR_TEXT)
self.toolbar.set_border_width(5)
self.toolbuttons = []
for index in range(self.notebook.get_n_pages()):
child = self.notebook.get_nth_page(index)
label = self.notebook.get_tab_label_text(child)
tip_text = 'switch to ' + label + ' page'
toolbutton = self.toolbar.append_element(gtk.TOOLBAR_CHILD_RADIOBUTTON, None,
label, tip_text, "Private text", None,
self.toolbutton_cb, index)
toolbutton.set_size_request(200, 100)
self.toolbuttons.append(toolbutton)
# set the default current page
self.modify_toolbuttons_bg(0)
self.notebook.set_current_page(0)
self.toolbar.append_space()
# add the tool bar into the event box
hbox.pack_start(self.toolbar, expand=False, fill=False)
self.search = gtk.Entry()
self.align = gtk.Alignment(xalign=0.5, yalign=0.5)
self.align.add(self.search)
hbox.pack_end(self.align, expand=False, fill=False)
self.label = gtk.Label(" Search: ")
self.label.set_alignment(0.5, 0.5)
hbox.pack_end(self.label, expand=False, fill=False)
def toolbutton_cb(self, widget, index):
if index >= self.notebook.get_n_pages():
return
self.notebook.set_current_page(index)
self.modify_toolbuttons_bg(index)
def modify_toolbuttons_bg(self, index):
if index >= len(self.toolbuttons):
return
for i in range(0, len(self.toolbuttons)):
toolbutton = self.toolbuttons[i]
if i == index:
self.modify_toolbutton_bg(toolbutton, True)
else:
self.modify_toolbutton_bg(toolbutton)
def modify_toolbutton_bg(self, toolbutton, active=False):
if active:
toolbutton.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.WHITE))
toolbutton.modify_bg(gtk.STATE_ACTIVE, gtk.gdk.Color(HobColors.WHITE))
toolbutton.modify_bg(gtk.STATE_SELECTED, gtk.gdk.Color(HobColors.WHITE))
toolbutton.modify_bg(gtk.STATE_PRELIGHT, gtk.gdk.Color(HobColors.WHITE))
else:
toolbutton.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.GRAY))
toolbutton.modify_bg(gtk.STATE_ACTIVE, gtk.gdk.Color(HobColors.GRAY))
toolbutton.modify_bg(gtk.STATE_SELECTED, gtk.gdk.Color(HobColors.GRAY))
toolbutton.modify_bg(gtk.STATE_PRELIGHT, gtk.gdk.Color(HobColors.GRAY))
class HobXpmLabelButtonBox(gtk.EventBox):
""" label: name of buttonbox
description: the simple description
"""
def __init__(self, display_file="", hover_file="", label="", description=""):
gtk.EventBox.__init__(self)
self._base_state_flags = gtk.STATE_NORMAL
self.set_events(gtk.gdk.MOTION_NOTIFY | gtk.gdk.BUTTON_PRESS | gtk.gdk.EXPOSE)
self.connect("expose-event", self.cb)
self.connect("enter-notify-event", self.pointer_enter_cb)
self.connect("leave-notify-event", self.pointer_leave_cb)
self.icon_hover = gtk.Image()
self.icon_hover.set_name("icon_image")
if type(hover_file) == str:
pixbuf = gtk.gdk.pixbuf_new_from_file(hover_file)
self.icon_hover.set_from_pixbuf(pixbuf)
self.icon_display = gtk.Image()
self.icon_display.set_name("icon_image")
if type(display_file) == str:
pixbuf = gtk.gdk.pixbuf_new_from_file(display_file)
self.icon_display.set_from_pixbuf(pixbuf)
self.tb = gtk.Table(2, 10, True)
self.tb.set_row_spacing(1, False)
self.tb.set_col_spacing(1, False)
self.add(self.tb)
self.tb.attach(self.icon_display, 0, 2, 0, 2, 0, 0)
self.tb.attach(self.icon_hover, 0, 2, 0, 2, 0, 0)
lbl = gtk.Label()
lbl.set_alignment(0.0, 0.5)
lbl.set_markup("<span foreground=\'#1C1C1C\' font_desc=\'18px\'>%s</span>" % label)
self.tb.attach(lbl, 2, 10, 0, 1)
lbl = gtk.Label()
lbl.set_alignment(0.0, 0.5)
lbl.set_markup("<span foreground=\'#1C1C1C\' font_desc=\'14px\'>%s</span>" % description)
self.tb.attach(lbl, 2, 10, 1, 2)
def pointer_enter_cb(self, *args):
#if not self.is_focus():
self.set_state(gtk.STATE_PRELIGHT)
self._base_state_flags = gtk.STATE_PRELIGHT
self.icon_hover.show()
self.icon_display.hide()
def pointer_leave_cb(self, *args):
self.set_state(gtk.STATE_NORMAL)
self._base_state_flags = gtk.STATE_NORMAL
self.icon_display.show()
self.icon_hover.hide()
def cb(self, w,e):
""" Hide items - first time """
pass

View File

@@ -0,0 +1,358 @@
#!/usr/bin/env python
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2012 Intel Corporation
#
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import glib
from bb.ui.crumbs.progressbar import HobProgressBar
from bb.ui.crumbs.hobcolor import HobColors
from bb.ui.crumbs.hobwidget import hic, HobXpmLabelButtonBox
from bb.ui.crumbs.hoblistmodel import RecipeListModel
from bb.ui.crumbs.hobpages import HobPage
from bb.ui.crumbs.hig import CrumbsDialog, BinbDialog, \
AdvancedSettingDialog, LayerSelectionDialog
#
# ImageConfigurationPage
#
class ImageConfigurationPage (HobPage):
__dummy_machine__ = "--select a machine--"
def __init__(self, builder):
super(ImageConfigurationPage, self).__init__(builder, "Image configuration")
self.image_combo_id = None
self.create_visual_elements()
def create_visual_elements(self):
# create visual elements
self.toolbar = gtk.Toolbar()
self.toolbar.set_orientation(gtk.ORIENTATION_HORIZONTAL)
self.toolbar.set_style(gtk.TOOLBAR_BOTH)
_, template_button = self.append_toolbar_button(self.toolbar,
"Template",
hic.ICON_TEMPLATES_DISPLAY_FILE,
hic.ICON_TEMPLATES_HOVER_FILE,
"Load a hob building template saved before",
self.template_button_clicked_cb)
_, my_images_button = self.append_toolbar_button(self.toolbar,
"My images",
hic.ICON_IMAGES_DISPLAY_FILE,
hic.ICON_IMAGES_HOVER_FILE,
"Open images built out previously for running or deployment",
self.my_images_button_clicked_cb)
_, settings_button = self.append_toolbar_button(self.toolbar,
"Settings",
hic.ICON_SETTINGS_DISPLAY_FILE,
hic.ICON_SETTINGS_HOVER_FILE,
"Other advanced settings for build",
self.settings_button_clicked_cb)
self.config_top_button = self.add_onto_top_bar(self.toolbar)
self.gtable = gtk.Table(40, 40, True)
self.create_config_machine()
self.create_config_baseimg()
self.config_build_button = self.create_config_build_button()
def _remove_all_widget(self):
children = self.gtable.get_children() or []
for child in children:
self.gtable.remove(child)
children = self.box_group_area.get_children() or []
for child in children:
self.box_group_area.remove(child)
children = self.get_children() or []
for child in children:
self.remove(child)
def _pack_components(self):
self._remove_all_widget()
self.pack_start(self.config_top_button, expand=False, fill=False)
self.pack_start(self.group_align, expand=True, fill=True)
self.box_group_area.pack_start(self.gtable, expand=True, fill=True)
self.box_group_area.pack_end(self.config_build_button, expand=False, fill=False)
def show_machine(self):
self._pack_components()
self.set_config_machine_layout()
self.show_all()
self.progress_bar.reset()
self.progress_bar.hide()
self.config_build_button.hide_all()
def update_progress_bar(self, title, fraction, status=True):
self.progress_bar.update(fraction)
self.progress_bar.set_title(title)
self.progress_bar.set_rcstyle(status)
def show_info_populating(self):
self._pack_components()
self.set_config_machine_layout()
self.show_all()
self.config_build_button.hide_all()
def show_info_populated(self):
self._pack_components()
self.set_config_machine_layout()
self.set_config_baseimg_layout()
self.show_all()
self.progress_bar.reset()
self.progress_bar.hide()
def create_config_machine(self):
self.machine_title = gtk.Label()
self.machine_title.set_alignment(0.0, 0.5)
mark = "<span %s>Select a machine</span>" % self.span_tag('24px', 'bold')
self.machine_title.set_markup(mark)
self.machine_title_desc = gtk.Label()
self.machine_title_desc.set_alignment(0, 0.5)
mark = ("<span %s>This is the profile of the target machine for which you"
" are building the image.\n</span>") % (self.span_tag(px='14px'))
self.machine_title_desc.set_markup(mark)
self.machine_combo = gtk.combo_box_new_text()
self.machine_combo.connect("changed", self.machine_combo_changed_cb)
icon_file = hic.ICON_LAYERS_DISPLAY_FILE
hover_file = hic.ICON_LAYERS_HOVER_FILE
self.layer_button = HobXpmLabelButtonBox(icon_file, hover_file,
"Layers", "Add support for machines, software, etc")
self.layer_button.connect("button-release-event", self.layer_button_clicked_cb)
icon_file = hic.ICON_INFO_DISPLAY_FILE
self.layer_info_icon = gtk.Image()
pix_buffer = gtk.gdk.pixbuf_new_from_file(icon_file)
self.layer_info_icon.set_from_pixbuf(pix_buffer)
markup = "Layers are a powerful mechanism to extend the Yocto Project "
markup += "with your own functionality.\n"
markup += "For more on layers, check:\n"
markup += "http://www.yoctoproject.org/docs/current/poky-ref-manual/"
markup += "poky-ref-manual.html#usingpoky-changes-layers."
self.layer_info_icon.set_tooltip_markup(markup)
self.progress_bar = HobProgressBar()
self.machine_separator = gtk.HSeparator()
def set_config_machine_layout(self):
self.gtable.attach(self.machine_title, 0, 40, 0, 4)
self.gtable.attach(self.machine_title_desc, 0, 40, 4, 6)
self.gtable.attach(self.machine_combo, 0, 12, 6, 9)
self.gtable.attach(self.layer_button, 12, 36, 6, 10)
self.gtable.attach(self.layer_info_icon, 36, 40, 6, 9)
self.gtable.attach(self.progress_bar, 0, 40, 13, 17)
self.gtable.attach(self.machine_separator, 0, 40, 12, 13)
def create_config_baseimg(self):
self.image_title = gtk.Label()
self.image_title.set_alignment(0, 1.0)
mark = "<span %s>Select a base image</span>" % self.span_tag('24px', 'bold')
self.image_title.set_markup(mark)
self.image_title_desc = gtk.Label()
self.image_title_desc.set_alignment(0, 0.5)
mark = ("<span %s>Base images are a starting point for the type of image you want. "
"You can build them as \n"
"they are or customize them to your specific needs.\n</span>") % self.span_tag('14px')
self.image_title_desc.set_markup(mark)
self.image_combo = gtk.combo_box_new_text()
self.image_combo_id = self.image_combo.connect("changed", self.image_combo_changed_cb)
self.image_desc = gtk.Label()
self.image_desc.set_alignment(0, 0)
self.image_desc.set_line_wrap(True)
# button to view recipes
icon_file = hic.ICON_RCIPE_DISPLAY_FILE
hover_file = hic.ICON_RCIPE_HOVER_FILE
self.view_recipes_button = HobXpmLabelButtonBox(icon_file, hover_file,
"View Recipes", "Add/remove recipes and collections")
self.view_recipes_button.connect("button-release-event", self.view_recipes_button_clicked_cb)
# button to view packages
icon_file = hic.ICON_PACKAGES_DISPLAY_FILE
hover_file = hic.ICON_PACKAGES_HOVER_FILE
self.view_packages_button = HobXpmLabelButtonBox(icon_file, hover_file,
"View Packages", "Add/remove packages")
self.view_packages_button.connect("button-release-event", self.view_packages_button_clicked_cb)
self.image_separator = gtk.HSeparator()
def set_config_baseimg_layout(self):
self.gtable.attach(self.image_title, 0, 40, 13, 17)
self.gtable.attach(self.image_title_desc, 0, 40, 17, 22)
self.gtable.attach(self.image_combo, 0, 12, 22, 25)
self.gtable.attach(self.image_desc, 14, 38, 22, 27)
self.gtable.attach(self.view_recipes_button, 0, 20, 28, 32)
self.gtable.attach(self.view_packages_button, 20, 40, 28, 32)
self.gtable.attach(self.image_separator, 0, 40, 35, 36)
def create_config_build_button(self):
# Create the "Build packages" and "Just bake" buttons at the bottom
button_box = gtk.HBox(False, 5)
# create button "Just bake"
just_bake_button = gtk.Button()
label = gtk.Label()
mark = "<span %s>Just bake</span>" % self.span_tag('24px', 'bold')
label.set_markup(mark)
just_bake_button.set_image(label)
just_bake_button.set_size_request(205, 49)
just_bake_button.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.ORANGE))
just_bake_button.modify_bg(gtk.STATE_PRELIGHT, gtk.gdk.Color(HobColors.ORANGE))
just_bake_button.modify_bg(gtk.STATE_SELECTED, gtk.gdk.Color(HobColors.ORANGE))
just_bake_button.set_tooltip_text("Build image to get your target image")
just_bake_button.set_flags(gtk.CAN_DEFAULT)
just_bake_button.grab_default()
just_bake_button.connect("clicked", self.just_bake_button_clicked_cb)
button_box.pack_end(just_bake_button, expand=False, fill=False)
label = gtk.Label(" or ")
button_box.pack_end(label, expand=False, fill=False)
# create button "Build Packages"
build_packages_button = gtk.LinkButton("Build packages first based on recipe selection "
"for late customization on packages for the target image", "Build Packages")
build_packages_button.connect("clicked", self.build_packages_button_clicked_cb)
button_box.pack_end(build_packages_button, expand=False, fill=False)
return button_box
def machine_combo_changed_cb(self, machine_combo):
combo_item = machine_combo.get_active_text()
if not combo_item or combo_item == self.__dummy_machine__:
self.builder.switch_page(self.builder.MACHINE_SELECTION)
else:
self.builder.configuration.curr_mach = combo_item
# Do reparse recipes
self.builder.switch_page(self.builder.RCPPKGINFO_POPULATING)
def update_machine_combo(self):
all_machines = [self.__dummy_machine__] + self.builder.parameters.all_machines
model = self.machine_combo.get_model()
model.clear()
for machine in all_machines:
self.machine_combo.append_text(machine)
self.machine_combo.set_active(0)
def switch_machine_combo(self):
model = self.machine_combo.get_model()
active = 0
while active < len(model):
if model[active][0] == self.builder.configuration.curr_mach:
self.machine_combo.set_active(active)
return
active += 1
self.machine_combo.set_active(0)
def image_combo_changed_idle_cb(self, selected_image, selected_recipes, selected_packages):
self.builder.update_recipe_model(selected_image, selected_recipes)
self.builder.update_package_model(selected_packages)
self.builder.window_sensitive(True)
def image_combo_changed_cb(self, combo):
self.builder.window_sensitive(False)
selected_image = self.image_combo.get_active_text()
if not selected_image:
return
selected_recipes = []
image_path = self.builder.recipe_model.pn_path[selected_image]
image_iter = self.builder.recipe_model.get_iter(image_path)
selected_packages = self.builder.recipe_model.get_value(image_iter, self.builder.recipe_model.COL_INSTALL).split()
mark = ("<span %s>%s</span>\n") % (self.span_tag('14px'), self.builder.recipe_model.get_value(image_iter, self.builder.recipe_model.COL_DESC))
self.image_desc.set_markup(mark)
self.builder.recipe_model.reset()
self.builder.package_model.reset()
glib.idle_add(self.image_combo_changed_idle_cb, selected_image, selected_recipes, selected_packages)
def _image_combo_connect_signal(self):
if not self.image_combo_id:
self.image_combo_id = self.image_combo.connect("changed", self.image_combo_changed_cb)
def _image_combo_disconnect_signal(self):
if self.image_combo_id:
self.image_combo.disconnect(self.image_combo_id)
self.image_combo_id = None
def update_image_combo(self, recipe_model, selected_image):
# Update the image combo according to the images in the recipe_model
# populate image combo
filter = {RecipeListModel.COL_TYPE : ['image']}
image_model = recipe_model.tree_model(filter)
active = 0
cnt = 0
it = image_model.get_iter_first()
self._image_combo_disconnect_signal()
model = self.image_combo.get_model()
model.clear()
# append and set active
while it:
path = image_model.get_path(it)
image_name = image_model[path][recipe_model.COL_NAME]
self.image_combo.append_text(image_name)
if image_name == selected_image:
active = cnt
it = image_model.iter_next(it)
cnt = cnt + 1
self._image_combo_connect_signal()
self.image_combo.set_active(-1)
self.image_combo.set_active(active)
def layer_button_clicked_cb(self, event, data):
# Create a layer selection dialog
self.builder.show_layer_selection_dialog()
def view_recipes_button_clicked_cb(self, event, data):
self.builder.show_recipes()
def view_packages_button_clicked_cb(self, event, data):
self.builder.show_packages()
def just_bake_button_clicked_cb(self, button):
self.builder.just_bake()
def build_packages_button_clicked_cb(self, button):
self.builder.build_packages()
def template_button_clicked_cb(self, button):
self.builder.show_load_template_dialog()
def my_images_button_clicked_cb(self, button):
self.builder.show_load_my_images_dialog()
def settings_button_clicked_cb(self, button):
# Create an advanced settings dialog
self.builder.show_adv_settings_dialog()

View File

@@ -0,0 +1,294 @@
#!/usr/bin/env python
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2012 Intel Corporation
#
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gobject
import gtk
from bb.ui.crumbs.hobcolor import HobColors
from bb.ui.crumbs.hobwidget import hic, HobWidget
from bb.ui.crumbs.hobpages import HobPage
#
# ImageDetailsPage
#
class ImageDetailsPage (HobPage):
class DetailBox (gtk.EventBox):
def __init__(self, varlist, vallist, icon = None, button = None, color = HobColors.LIGHT_GRAY):
gtk.EventBox.__init__(self)
# set color
style = self.get_style().copy()
style.bg[gtk.STATE_NORMAL] = self.get_colormap().alloc_color(color, False, False)
self.set_style(style)
self.hbox = gtk.HBox()
self.hbox.set_border_width(15)
self.add(self.hbox)
# pack the icon and the text on the left
row = len(varlist)
self.table = gtk.Table(row, 20, True)
self.table.set_size_request(100, -1)
self.hbox.pack_start(self.table, expand=True, fill=True, padding=15)
colid = 0
if icon != None:
self.table.attach(icon, colid, colid + 2, 0, 1)
colid = colid + 2
for line in range(0, row):
self.table.attach(self.text2label(varlist[line], vallist[line]), colid, 20, line, line + 1)
# pack the button on the right
if button != None:
self.hbox.pack_end(button, expand=False, fill=False)
def text2label(self, variable, value):
# append the name:value to the left box
# such as "Name: hob-core-minimal-variant-2011-12-15-beagleboard"
markup = "<span weight=\'bold\'>%s</span>" % variable
markup += "<span weight=\'normal\' foreground=\'#1c1c1c\' font_desc=\'14px\'>%s</span>" % value
label = gtk.Label()
label.set_alignment(0.0, 0.5)
label.set_markup(markup)
return label
def __init__(self, builder):
super(ImageDetailsPage, self).__init__(builder, "Image details")
self.image_store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_BOOLEAN)
self.create_visual_elements()
def create_visual_elements(self):
# create visual elements
# create the toolbar
self.toolbar = gtk.Toolbar()
self.toolbar.set_orientation(gtk.ORIENTATION_HORIZONTAL)
self.toolbar.set_style(gtk.TOOLBAR_BOTH)
_, my_images_button = self.append_toolbar_button(self.toolbar,
"My images",
hic.ICON_IMAGES_DISPLAY_FILE,
hic.ICON_IMAGES_HOVER_FILE,
"Open images built out previously for running or deployment",
self.my_images_button_clicked_cb)
self.details_top_buttons = self.add_onto_top_bar(self.toolbar)
def _remove_all_widget(self):
children = self.get_children() or []
for child in children:
self.remove(child)
children = self.box_group_area.get_children() or []
for child in children:
self.box_group_area.remove(child)
def _size_to_string(self, size):
if len(str(int(size))) > 6:
size_str = '%.1f' % (size*1.0/(1024*1024)) + ' MB'
elif len(str(int(size))) > 3:
size_str = '%.1f' % (size*1.0/1024) + ' KB'
else:
size_str = str(size) + ' B'
return size_str
def show_page(self, step):
build_succeeded = (step == self.builder.IMAGE_GENERATED)
image_addr = self.builder.parameters.image_addr
image_names = self.builder.parameters.image_names
if build_succeeded:
image_addr = self.builder.parameters.image_addr
image_names = self.builder.parameters.image_names
machine = self.builder.configuration.curr_mach
base_image = self.builder.recipe_model.get_selected_image()
layers = self.builder.configuration.layers
pkg_num = "%s" % len(self.builder.package_model.get_selected_packages())
else:
pkg_num = "N/A"
self._remove_all_widget()
self.pack_start(self.details_top_buttons, expand=False, fill=False)
self.pack_start(self.group_align, expand=True, fill=True)
if build_succeeded:
# building is the previous step
icon = gtk.Image()
pixmap_path = hic.ICON_INDI_CONFIRM_FILE
color = HobColors.RUNNING
pix_buffer = gtk.gdk.pixbuf_new_from_file(pixmap_path)
icon.set_from_pixbuf(pix_buffer)
varlist = [""]
vallist = ["Your image is ready"]
build_result = self.DetailBox(varlist=varlist, vallist=vallist, icon=icon, button=None, color=color)
self.box_group_area.pack_start(build_result, expand=False, fill=False)
# Name
self.image_store.clear()
for image_name in image_names:
image_size = self._size_to_string(os.stat(os.path.join(image_addr, image_name)).st_size)
self.image_store.set(self.image_store.append(), 0, image_name, 1, image_size, 2, False)
images_widget, treeview = HobWidget.gen_images_widget(600, 200, 100)
treeview.set_model(self.image_store)
self.box_group_area.pack_start(images_widget, expand=False, fill=False)
# Machine, Base image and Layers
layer_num_limit = 15
varlist = ["Machine: ", "Base image: ", "Layers: "]
vallist = []
if build_succeeded:
vallist.append(machine)
vallist.append(base_image)
i = 0
for layer in layers:
varlist.append(" - ")
if i > layer_num_limit:
break
i += 1
vallist.append("")
i = 0
for layer in layers:
if i > layer_num_limit:
break
elif i == layer_num_limit:
vallist.append("and more...")
else:
vallist.append(layer)
i += 1
edit_config_button = gtk.LinkButton("Changes settings for build", "Edit configuration")
edit_config_button.connect("clicked", self.edit_config_button_clicked_cb)
setting_detail = self.DetailBox(varlist=varlist, vallist=vallist, icon=None, button=edit_config_button)
self.box_group_area.pack_start(setting_detail, expand=False, fill=False)
# Packages included, and Total image size
varlist = ["Packages included: ", "Total image size: "]
vallist = []
vallist.append(pkg_num)
vallist.append(image_size)
if build_succeeded:
edit_packages_button = gtk.LinkButton("Change package selection for customization", "Edit packages")
edit_packages_button.connect("clicked", self.edit_packages_button_clicked_cb)
else: # get to this page from "My images"
edit_packages_button = None
package_detail = self.DetailBox(varlist=varlist, vallist=vallist, icon=None, button=edit_packages_button)
self.box_group_area.pack_start(package_detail, expand=False, fill=False)
if build_succeeded:
buttonlist = ["Build new image", "Save as template", "Run image", "Deploy image"]
else: # get to this page from "My images"
buttonlist = ["Build new image", "Run image", "Deploy image"]
details_bottom_buttons = self.create_bottom_buttons(buttonlist)
self.box_group_area.pack_end(details_bottom_buttons, expand=False, fill=False)
self.show_all()
def create_bottom_buttons(self, buttonlist):
# Create the buttons at the bottom
bottom_buttons = gtk.HBox(False, 5)
created = False
# create button "Deploy image"
name = "Deploy image"
if name in buttonlist:
deploy_button = gtk.Button()
label = gtk.Label()
mark = "<span %s>Deploy image</span>" % self.span_tag('24px', 'bold')
label.set_markup(mark)
deploy_button.set_image(label)
deploy_button.set_size_request(205, 49)
deploy_button.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.ORANGE))
deploy_button.modify_bg(gtk.STATE_PRELIGHT, gtk.gdk.Color(HobColors.ORANGE))
deploy_button.modify_bg(gtk.STATE_SELECTED, gtk.gdk.Color(HobColors.ORANGE))
deploy_button.set_tooltip_text("Deploy image to get your target board")
deploy_button.set_flags(gtk.CAN_DEFAULT)
deploy_button.grab_default()
deploy_button.connect("clicked", self.deploy_button_clicked_cb)
bottom_buttons.pack_end(deploy_button, expand=False, fill=False)
created = True
name = "Run image"
if name in buttonlist:
if created == True:
# separator
label = gtk.Label(" or ")
bottom_buttons.pack_end(label, expand=False, fill=False)
# create button "Run image"
run_button = gtk.LinkButton("Launch and boot the image in the QEMU emulator", "Run image")
run_button.connect("clicked", self.run_button_clicked_cb)
bottom_buttons.pack_end(run_button, expand=False, fill=False)
created = True
name = "Save as template"
if name in buttonlist:
if created == True:
# separator
label = gtk.Label(" or ")
bottom_buttons.pack_end(label, expand=False, fill=False)
# create button "Save as template"
save_button = gtk.LinkButton("Save the hob build template for future use", "Save as template")
save_button.connect("clicked", self.save_button_clicked_cb)
bottom_buttons.pack_end(save_button, expand=False, fill=False)
create = True
name = "Build new image"
if name in buttonlist:
# create button "Build new image"
build_new_button = gtk.LinkButton("Initiate another new build from the beginning", "Build new image")
build_new_button.connect("clicked", self.build_new_button_clicked_cb)
bottom_buttons.pack_start(build_new_button, expand=False, fill=False)
return bottom_buttons
def _get_selected_image(self):
image_name = ""
iter = self.image_store.get_iter_first()
while iter:
path = self.image_store.get_path(iter)
if self.image_store[path][2]:
image_name = self.image_store[path][0]
break
iter = self.image_store.iter_next(iter)
return image_name
def save_button_clicked_cb(self, button):
self.builder.show_save_template_dialog()
def deploy_button_clicked_cb(self, button):
image_name = self._get_selected_image()
self.builder.deploy_image(image_name)
def run_button_clicked_cb(self, button):
image_name = self._get_selected_image()
self.builder.runqemu_image(image_name)
def build_new_button_clicked_cb(self, button):
self.builder.initiate_new_build()
def edit_config_button_clicked_cb(self, button):
self.builder.show_configuration()
def edit_packages_button_clicked_cb(self, button):
self.builder.show_packages(ask=False)
def my_images_button_clicked_cb(self, button):
self.builder.show_load_my_images_dialog()

View File

@@ -1,153 +0,0 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gobject
import gtk
from bb.ui.crumbs.configurator import Configurator
from bb.ui.crumbs.hig import CrumbsDialog
class LayerEditor(gtk.Dialog):
"""
Gtk+ Widget for enabling and disabling layers.
Layers are added through using an open dialog to find the layer.conf
Disabled layers are deleted from conf/bblayers.conf
"""
def __init__(self, configurator, parent=None):
gtk.Dialog.__init__(self, "Layers", None,
gtk.DIALOG_DESTROY_WITH_PARENT,
(gtk.STOCK_CLOSE, gtk.RESPONSE_OK))
# We want to show a little more of the treeview in the default,
# emptier, case
self.set_size_request(-1, 300)
self.set_border_width(6)
self.vbox.set_property("spacing", 0)
self.action_area.set_property("border-width", 6)
self.configurator = configurator
self.newly_added = {}
# Label to inform users that meta is enabled but that you can't
# disable it as it'd be a *bad* idea
msg = "As the core of the build system the <i>meta</i> layer must always be included and therefore can't be viewed or edited here."
lbl = gtk.Label()
lbl.show()
lbl.set_use_markup(True)
lbl.set_markup(msg)
lbl.set_line_wrap(True)
lbl.set_justify(gtk.JUSTIFY_FILL)
self.vbox.pack_start(lbl, expand=False, fill=False, padding=6)
# Create a treeview in which to list layers
# ListStore of Name, Path, Enabled
self.layer_store = gtk.ListStore(gobject.TYPE_STRING, gobject.TYPE_STRING, gobject.TYPE_BOOLEAN)
self.tv = gtk.TreeView(self.layer_store)
self.tv.set_headers_visible(True)
col0 = gtk.TreeViewColumn('Name')
self.tv.append_column(col0)
col1 = gtk.TreeViewColumn('Path')
self.tv.append_column(col1)
col2 = gtk.TreeViewColumn('Enabled')
self.tv.append_column(col2)
cell0 = gtk.CellRendererText()
col0.pack_start(cell0, True)
col0.set_attributes(cell0, text=0)
cell1 = gtk.CellRendererText()
col1.pack_start(cell1, True)
col1.set_attributes(cell1, text=1)
cell2 = gtk.CellRendererToggle()
cell2.connect("toggled", self._toggle_layer_cb)
col2.pack_start(cell2, True)
col2.set_attributes(cell2, active=2)
self.tv.show()
self.vbox.pack_start(self.tv, expand=True, fill=True, padding=0)
tb = gtk.Toolbar()
tb.set_icon_size(gtk.ICON_SIZE_SMALL_TOOLBAR)
tb.set_style(gtk.TOOLBAR_BOTH)
tb.set_tooltips(True)
tb.show()
icon = gtk.Image()
icon.set_from_stock(gtk.STOCK_ADD, gtk.ICON_SIZE_SMALL_TOOLBAR)
icon.show()
tb.insert_item("Add Layer", "Add new layer", None, icon,
self._find_layer_cb, None, -1)
self.vbox.pack_start(tb, expand=False, fill=False, padding=0)
def set_parent_window(self, parent):
self.set_transient_for(parent)
def load_current_layers(self, data):
for layer, path in self.configurator.enabled_layers.items():
if layer != 'meta':
self.layer_store.append([layer, path, True])
def save_current_layers(self):
self.configurator.writeLayerConf()
def _toggle_layer_cb(self, cell, path):
name = self.layer_store[path][0]
toggle = not self.layer_store[path][2]
if toggle:
self.configurator.addLayer(name, path)
else:
self.configurator.disableLayer(name)
self.layer_store[path][2] = toggle
def _find_layer_cb(self, button):
self.find_layer(self)
def find_layer(self, parent):
def conf_error(parent, lbl):
dialog = CrumbsDialog(parent, lbl)
dialog.add_button(gtk.STOCK_OK, gtk.RESPONSE_OK)
response = dialog.run()
dialog.destroy()
dialog = gtk.FileChooserDialog("Add new layer", parent,
gtk.FILE_CHOOSER_ACTION_OPEN,
(gtk.STOCK_CANCEL, gtk.RESPONSE_NO,
gtk.STOCK_OPEN, gtk.RESPONSE_YES))
label = gtk.Label("Select the layer.conf of the layer you wish to add")
label.show()
dialog.set_extra_widget(label)
response = dialog.run()
path = dialog.get_filename()
dialog.destroy()
lbl = "<b>Error</b>\nUnable to load layer <i>%s</i> because " % path
if response == gtk.RESPONSE_YES:
# FIXME: verify we've actually got a layer conf?
if path.endswith("layer.conf"):
name, layerpath = self.configurator.addLayerConf(path)
if name and layerpath:
self.newly_added[name] = layerpath
self.layer_store.append([name, layerpath, True])
return
elif name:
return
else:
lbl += "there was a problem parsing the layer.conf."
else:
lbl += "it is not a layer.conf file."
conf_error(parent, lbl)

View File

@@ -0,0 +1,226 @@
#!/usr/bin/env python
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2012 Intel Corporation
#
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import glib
from bb.ui.crumbs.hobcolor import HobColors
from bb.ui.crumbs.hobwidget import HobViewBar, HobViewTable
from bb.ui.crumbs.hoblistmodel import PackageListModel
from bb.ui.crumbs.hobpages import HobPage
#
# PackageSelectionPage
#
class PackageSelectionPage (HobPage):
pages = [
{
'name' : 'All packages',
'filter' : {},
'columns' : [{
'col_name' : 'Name',
'col_id' : PackageListModel.COL_NAME,
'col_style': 'text',
'col_min' : 100,
'col_max' : 400
}, {
'col_name' : 'size',
'col_id' : PackageListModel.COL_SIZE,
'col_style': 'text',
'col_min' : 100,
'col_max' : 500
}, {
'col_name' : 'Included',
'col_id' : PackageListModel.COL_INC,
'col_style': 'toggle',
'col_min' : 50,
'col_max' : 50
}]
}, {
'name' : 'Included',
'filter' : { PackageListModel.COL_INC : [True] },
'columns' : [{
'col_name' : 'Name',
'col_id' : PackageListModel.COL_NAME,
'col_style': 'text',
'col_min' : 100,
'col_max' : 300
}, {
'col_name' : 'Brought by',
'col_id' : PackageListModel.COL_BINB,
'col_style': 'text',
'col_min' : 100,
'col_max' : 350
}, {
'col_name' : 'size',
'col_id' : PackageListModel.COL_SIZE,
'col_style': 'text',
'col_min' : 100,
'col_max' : 300
}, {
'col_name' : 'Included',
'col_id' : PackageListModel.COL_INC,
'col_style': 'toggle',
'col_min' : 50,
'col_max' : 50
}]
}
]
def __init__(self, builder):
super(PackageSelectionPage, self).__init__(builder, "Package Selection")
# set invisiable members
self.package_model = self.builder.package_model
# create visual elements
self.create_visual_elements()
def create_visual_elements(self):
self.label = gtk.Label("Packages included: 0\nSelected packages size: 0 MB")
self.eventbox = self.add_onto_top_bar(self.label, 73)
self.pack_start(self.eventbox, expand=False, fill=False)
self.pack_start(self.group_align, expand=True, fill=True)
# set visiable members
self.grid = gtk.Table(10, 1, True)
self.grid.set_col_spacings(3)
self.ins = gtk.Notebook()
self.ins.set_show_tabs(False)
self.tables = [] # we need to modify table when the dialog is shown
# append the tab
for i in range(len(self.pages)):
columns = self.pages[i]['columns']
tab = HobViewTable(columns, self.reset_clicked_cb, self.table_toggled_cb)
filter = self.pages[i]['filter']
tab.table_tree.set_model(self.package_model.tree_model(filter))
label = gtk.Label(self.pages[i]['name'])
self.ins.append_page(tab, label)
self.tables.append(tab)
self.grid.attach(self.ins, 0, 1, 1, 10, gtk.FILL | gtk.EXPAND, gtk.FILL | gtk.EXPAND, 1, 1)
# a black bar associated with the notebook
self.topbar = HobViewBar(self.ins)
self.grid.attach(self.topbar, 0, 1, 0, 1, gtk.FILL | gtk.EXPAND, gtk.FILL | gtk.EXPAND, 1, 1)
# set the search entry for each table
for tab in self.tables:
tab.table_tree.set_search_entry(self.topbar.search)
inctab_tree_view = self.tables[len(self.pages)-1].table_tree
inctab_tree_selection = inctab_tree_view.get_selection()
inctab_tree_selection.connect("changed", self.tree_selection_cb, inctab_tree_view)
# add all into the dialog
self.box_group_area.add(self.grid)
button_box = gtk.HBox(False, 5)
self.box_group_area.pack_start(button_box, expand=False, fill=False)
self.build_image_button = gtk.Button()
label = gtk.Label()
mark = "<span %s>Build image</span>" % self.span_tag('24px', 'bold')
label.set_markup(mark)
self.build_image_button.set_image(label)
self.build_image_button.set_size_request(205, 49)
self.build_image_button.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.ORANGE))
self.build_image_button.modify_bg(gtk.STATE_PRELIGHT, gtk.gdk.Color(HobColors.ORANGE))
self.build_image_button.modify_bg(gtk.STATE_SELECTED, gtk.gdk.Color(HobColors.ORANGE))
self.build_image_button.set_tooltip_text("Build image to get your target image")
self.build_image_button.set_flags(gtk.CAN_DEFAULT)
self.build_image_button.grab_default()
self.build_image_button.connect("clicked", self.build_image_clicked_cb)
button_box.pack_end(self.build_image_button, expand=False, fill=False)
self.back_button = gtk.LinkButton("Go back to Image Configuration screen", "<< Back to image configuration")
self.back_button.connect("clicked", self.back_button_clicked_cb)
button_box.pack_start(self.back_button, expand=False, fill=False)
def tree_selection_cb(self, tree_selection, tree_view):
tree_model = tree_view.get_model()
path, column = tree_view.get_cursor()
if not path or column == tree_view.get_column(2):
return
it = tree_model.get_iter(path)
binb = tree_model.get_value(it, PackageListModel.COL_BINB)
if binb:
self.builder.show_binb_dialog(binb)
def build_image_clicked_cb(self, button):
self.builder.build_image()
def back_button_clicked_cb(self, button):
self.builder.show_configuration()
def _expand_all(self):
for tab in self.tables:
tab.table_tree.expand_all()
def refresh_selection(self):
self._expand_all()
self.builder.configuration.selected_packages = self.package_model.get_selected_packages()
selected_packages_num = len(self.builder.configuration.selected_packages)
selected_packages_size = float(self.package_model.get_packages_size())
selected_packages_size_str = self._size_to_string(selected_packages_size)
image_overhead_factor = self.builder.configuration.image_overhead_factor
image_rootfs_size = self.builder.configuration.image_rootfs_size
image_extra_size = self.builder.configuration.image_extra_size
base_size = image_overhead_factor * selected_packages_size
image_total_size = max(base_size, image_rootfs_size) + image_extra_size
image_total_size_str = self._size_to_string(image_total_size)
self.label.set_text("Packages included: %s\nSelected packages size: %s\nTotal image size: %s" %
(selected_packages_num, selected_packages_size_str, image_total_size_str))
"""
Helper function to convert the package size to string format.
The unit of size is KB
"""
def _size_to_string(self, size):
if len(str(int(size))) > 3:
size_str = '%.1f' % (size*1.0/1024) + ' MB'
else:
size_str = str(size) + ' KB'
return size_str
# Callback functions
def reset_clicked_cb(self, button):
self.package_model.reset()
self.builder.reset_package_model()
def toggle_item_idle_cb(self, path):
if not self.package_model.path_included(path):
self.package_model.include_item(item_path=path, binb="User Selected")
else:
self.package_model.exclude_item(item_path=path)
self.builder.window_sensitive(True)
def table_toggled_cb(self, cell, view_path, view_tree):
# Click to include a package
self.builder.window_sensitive(False)
view_model = view_tree.get_model()
path = self.package_model.convert_vpath_to_path(view_model, view_path)
glib.idle_add(self.toggle_item_idle_cb, path)

View File

@@ -0,0 +1,52 @@
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
#
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
from bb.ui.crumbs.hobcolor import HobColors
class HobProgressBar (gtk.ProgressBar):
def __init__(self):
gtk.ProgressBar.__init__(self)
self.set_rcstyle(True)
self.percentage = 0
def set_rcstyle(self, status):
rcstyle = gtk.RcStyle()
rcstyle.fg[2] = gtk.gdk.Color(HobColors.BLACK)
if status:
rcstyle.bg[3] = gtk.gdk.Color(HobColors.RUNNING)
else:
rcstyle.bg[3] = gtk.gdk.Color(HobColors.ERROR)
self.modify_style(rcstyle)
def set_title(self, text=None):
if not text:
text = ""
text += " %.0f%%" % self.percentage
self.set_text(text)
def reset(self):
self.set_fraction(0)
self.set_text("")
self.set_rcstyle(True)
self.percentage = 0
def update(self, fraction):
self.percentage = int(fraction * 100)
self.set_fraction(fraction)

View File

@@ -0,0 +1,221 @@
#!/usr/bin/env python
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2012 Intel Corporation
#
# Authored by Dongxiao Xu <dongxiao.xu@intel.com>
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import glib
from bb.ui.crumbs.hobcolor import HobColors
from bb.ui.crumbs.hobwidget import HobWidget, HobViewBar, HobViewTable
from bb.ui.crumbs.hoblistmodel import RecipeListModel
from bb.ui.crumbs.hobpages import HobPage
#
# RecipeSelectionPage
#
class RecipeSelectionPage (HobPage):
pages = [
{
'name' : 'Recipe',
'filter' : { RecipeListModel.COL_TYPE : ['recipe'] },
'columns' : [{
'col_name' : 'Recipe',
'col_id' : RecipeListModel.COL_NAME,
'col_style': 'text',
'col_min' : 100,
'col_max' : 400
}, {
'col_name' : 'License',
'col_id' : RecipeListModel.COL_LIC,
'col_style': 'text',
'col_min' : 100,
'col_max' : 400
}, {
'col_name' : 'Group',
'col_id' : RecipeListModel.COL_GROUP,
'col_style': 'text',
'col_min' : 100,
'col_max' : 400
}, {
'col_name' : 'Included',
'col_id' : RecipeListModel.COL_INC,
'col_style': 'toggle',
'col_min' : 50,
'col_max' : 50
}]
}, {
'name' : 'Recipe Collection',
'filter' : { RecipeListModel.COL_TYPE : ['task'] },
'columns' : [{
'col_name' : 'Recipe Collection',
'col_id' : RecipeListModel.COL_NAME,
'col_style': 'text',
'col_min' : 100,
'col_max' : 400
}, {
'col_name' : 'Description',
'col_id' : RecipeListModel.COL_DESC,
'col_style': 'text',
'col_min' : 100,
'col_max' : 400
}, {
'col_name' : 'Included',
'col_id' : RecipeListModel.COL_INC,
'col_style': 'toggle',
'col_min' : 50,
'col_max' : 50
}]
}, {
'name' : 'Included',
'filter' : { RecipeListModel.COL_INC : [True],
RecipeListModel.COL_TYPE : ['recipe', 'task'] },
'columns' : [{
'col_name' : 'Recipe',
'col_id' : RecipeListModel.COL_NAME,
'col_style': 'text',
'col_min' : 100,
'col_max' : 400
}, {
'col_name' : 'Brought by',
'col_id' : RecipeListModel.COL_BINB,
'col_style': 'text',
'col_min' : 100,
'col_max' : 500
}, {
'col_name' : 'Included',
'col_id' : RecipeListModel.COL_INC,
'col_style': 'toggle',
'col_min' : 50,
'col_max' : 50
}]
}
]
def __init__(self, builder = None):
super(RecipeSelectionPage, self).__init__(builder, "Recipe Selection")
# set invisiable members
self.recipe_model = self.builder.recipe_model
# create visual elements
self.create_visual_elements()
def create_visual_elements(self):
self.label = gtk.Label("Recipes included: %s" % len(self.builder.configuration.selected_recipes))
self.eventbox = self.add_onto_top_bar(self.label, 73)
self.pack_start(self.eventbox, expand=False, fill=False)
self.pack_start(self.group_align, expand=True, fill=True)
# set visiable members
self.grid = gtk.Table(10, 1, True)
self.grid.set_col_spacings(3)
# draw the left part of the window
# a notebook
self.ins = gtk.Notebook()
self.ins.set_show_tabs(False)
self.tables = [] # we need modify table when the dialog is shown
# append the tabs in order
for i in range(len(self.pages)):
columns = self.pages[i]['columns']
tab = HobViewTable(columns, self.reset_clicked_cb, self.table_toggled_cb)
filter = self.pages[i]['filter']
tab.table_tree.set_model(self.recipe_model.tree_model(filter))
label = gtk.Label(self.pages[i]['name'])
self.ins.append_page(tab, label)
self.tables.append(tab)
self.grid.attach(self.ins, 0, 1, 1, 10, gtk.FILL | gtk.EXPAND, gtk.FILL | gtk.EXPAND)
# a black bar associated with the notebook
self.topbar = HobViewBar(self.ins)
self.grid.attach(self.topbar, 0, 1, 0, 1, gtk.FILL | gtk.EXPAND, gtk.FILL | gtk.EXPAND)
# set the search entry for each table
for tab in self.tables:
tab.table_tree.set_search_entry(self.topbar.search)
inctab_tree_view = self.tables[len(self.pages)-1].table_tree
inctab_tree_selection = inctab_tree_view.get_selection()
inctab_tree_selection.connect("changed", self.tree_selection_cb, inctab_tree_view)
# add all into the window
self.box_group_area.add(self.grid)
button_box = gtk.HBox(False, 5)
self.box_group_area.pack_end(button_box, expand=False, fill=False)
self.build_packages_button = gtk.Button()
label = gtk.Label()
mark = "<span %s>Build packages</span>" % self.span_tag('24px', 'bold')
label.set_markup(mark)
self.build_packages_button.set_image(label)
self.build_packages_button.set_size_request(205, 49)
self.build_packages_button.modify_bg(gtk.STATE_NORMAL, gtk.gdk.Color(HobColors.ORANGE))
self.build_packages_button.modify_bg(gtk.STATE_PRELIGHT, gtk.gdk.Color(HobColors.ORANGE))
self.build_packages_button.modify_bg(gtk.STATE_SELECTED, gtk.gdk.Color(HobColors.ORANGE))
self.build_packages_button.set_tooltip_text("Build packages for customization")
self.build_packages_button.set_flags(gtk.CAN_DEFAULT)
self.build_packages_button.grab_default()
self.build_packages_button.connect("clicked", self.build_packages_clicked_cb)
button_box.pack_end(self.build_packages_button, expand=False, fill=False)
self.back_button = gtk.LinkButton("Go back to Image Configuration screen", "<< Back to image configuration")
self.back_button.connect("clicked", self.back_button_clicked_cb)
button_box.pack_start(self.back_button, expand=False, fill=False)
def tree_selection_cb(self, tree_selection, tree_view):
tree_model = tree_view.get_model()
path, column = tree_view.get_cursor()
if not path or column == tree_view.get_column(2):
return
it = tree_model.get_iter(path)
binb = tree_model.get_value(it, RecipeListModel.COL_BINB)
if binb:
self.builder.show_binb_dialog(binb)
def build_packages_clicked_cb(self, button):
self.builder.build_packages()
def back_button_clicked_cb(self, button):
self.builder.show_configuration()
def refresh_selection(self):
self.builder.configuration.selected_image = self.recipe_model.get_selected_image()
_, self.builder.configuration.selected_recipes = self.recipe_model.get_selected_recipes()
self.label.set_text("Recipes included: %s" % len(self.builder.configuration.selected_recipes))
# Callback functions
def reset_clicked_cb(self, button):
self.builder.reset_recipe_model()
def toggle_item_idle_cb(self, path):
if not self.recipe_model.path_included(path):
self.recipe_model.include_item(item_path=path, binb="User Selected", image_contents=False)
else:
self.recipe_model.exclude_item(item_path=path)
self.builder.window_sensitive(True)
def table_toggled_cb(self, cell, view_path, view_tree):
# Click to include a recipe
self.builder.window_sensitive(False)
view_model = view_tree.get_model()
path = self.recipe_model.convert_vpath_to_path(view_model, view_path)
glib.idle_add(self.toggle_item_idle_cb, path)

View File

@@ -25,12 +25,7 @@ import logging
import time
import urllib
import urllib2
class Colors(object):
OK = "#ffffff"
RUNNING = "#aaffaa"
WARNING ="#f88017"
ERROR = "#ffaaaa"
from bb.ui.crumbs.hobcolor import HobColors
class RunningBuildModel (gtk.TreeStore):
(COL_LOG, COL_PACKAGE, COL_TASK, COL_MESSAGE, COL_ICON, COL_COLOR, COL_NUM_ACTIVE) = range(7)
@@ -58,7 +53,10 @@ class RunningBuild (gobject.GObject):
()),
'build-complete' : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
())
()),
'task-started' : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_PYOBJECT,)),
}
pids_to_task = {}
tasks_to_iter = {}
@@ -108,13 +106,13 @@ class RunningBuild (gobject.GObject):
if event.levelno >= logging.ERROR:
icon = "dialog-error"
color = Colors.ERROR
color = HobColors.ERROR
elif event.levelno >= logging.WARNING:
icon = "dialog-warning"
color = Colors.WARNING
color = HobColors.WARNING
else:
icon = None
color = Colors.OK
color = HobColors.OK
# if we know which package we belong to, we'll append onto its list.
# otherwise, we'll jump to the top of the master list
@@ -152,7 +150,7 @@ class RunningBuild (gobject.GObject):
None,
"Package: %s" % (package),
None,
Colors.OK,
HobColors.OK,
0))
self.tasks_to_iter[(package, None)] = parent
@@ -160,7 +158,7 @@ class RunningBuild (gobject.GObject):
# such.
# @todo if parent is already in error, don't mark it green
self.model.set(parent, self.model.COL_ICON, "gtk-execute",
self.model.COL_COLOR, Colors.RUNNING)
self.model.COL_COLOR, HobColors.RUNNING)
# Add an entry in the model for this task
i = self.model.append (parent, (None,
@@ -168,7 +166,7 @@ class RunningBuild (gobject.GObject):
task,
"Task: %s" % (task),
"gtk-execute",
Colors.RUNNING,
HobColors.RUNNING,
0))
# update the parent's active task count
@@ -179,10 +177,6 @@ class RunningBuild (gobject.GObject):
# that we need to attach to a task.
self.tasks_to_iter[(package, task)] = i
# If we don't handle these the GUI does not proceed
elif isinstance(event, bb.build.TaskInvalid):
return
elif isinstance(event, bb.build.TaskBase):
current = self.tasks_to_iter[(package, task)]
parent = self.tasks_to_iter[(package, None)]
@@ -194,20 +188,20 @@ class RunningBuild (gobject.GObject):
if isinstance(event, bb.build.TaskFailed):
# Mark the task and parent as failed
icon = "dialog-error"
color = Colors.ERROR
color = HobColors.ERROR
logfile = event.logfile
if logfile and os.path.exists(logfile):
with open(logfile) as f:
logdata = f.read()
self.model.append(current, ('pastebin', None, None, logdata, 'gtk-error', Colors.OK, 0))
self.model.append(current, ('pastebin', None, None, logdata, 'gtk-error', HobColors.OK, 0))
for i in (current, parent):
self.model.set(i, self.model.COL_ICON, icon,
self.model.COL_COLOR, color)
else:
icon = None
color = Colors.OK
color = HobColors.OK
# Mark the task as inactive
self.model.set(current, self.model.COL_ICON, icon,
@@ -219,7 +213,7 @@ class RunningBuild (gobject.GObject):
if self.model.get(parent, self.model.COL_ICON) != 'dialog-error':
self.model.set(parent, self.model.COL_ICON, icon)
if num_active == 0:
self.model.set(parent, self.model.COL_COLOR, Colors.OK)
self.model.set(parent, self.model.COL_COLOR, HobColors.OK)
# Clear the iters and the pids since when the task goes away the
# pid will no longer be used for messages
@@ -234,8 +228,12 @@ class RunningBuild (gobject.GObject):
None,
"Build Started (%s)" % time.strftime('%m/%d/%Y %H:%M:%S'),
None,
Colors.OK,
HobColors.OK,
0))
if pbar:
pbar.update(0, None, bb.event.getName(event))
pbar.set_title()
elif isinstance(event, bb.event.BuildCompleted):
failures = int (event._failures)
self.model.prepend(None, (None,
@@ -243,7 +241,7 @@ class RunningBuild (gobject.GObject):
None,
"Build Completed (%s)" % time.strftime('%m/%d/%Y %H:%M:%S'),
None,
Colors.OK,
HobColors.OK,
0))
# Emit the appropriate signal depending on the number of failures
@@ -254,6 +252,8 @@ class RunningBuild (gobject.GObject):
# Emit a generic "build-complete" signal for things wishing to
# handle when the build is finished
self.emit("build-complete")
if pbar:
pbar.set_text(event.msg)
elif isinstance(event, bb.command.CommandFailed):
if event.error.startswith("Exited with"):
@@ -280,6 +280,15 @@ class RunningBuild (gobject.GObject):
pbar.update(event.current, self.progress_total)
elif isinstance(event, bb.event.ParseCompleted) and pbar:
pbar.hide()
#using runqueue events as many as possible to update the progress bar
elif isinstance(event, (bb.runqueue.runQueueTaskStarted, bb.runqueue.sceneQueueTaskStarted)):
message = {}
message["eventname"] = bb.event.getName(event)
num_of_completed = event.stats.completed + event.stats.failed
message["current"] = num_of_completed
message["total"] = event.stats.total
message["title"] = ""
self.emit("task-started", message)
return

View File

@@ -1,620 +0,0 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
#
# Authored by Joshua Lock <josh@linux.intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gtk
import gobject
import re
class BuildRep(gobject.GObject):
def __init__(self, userpkgs, allpkgs, base_image=None):
gobject.GObject.__init__(self)
self.base_image = base_image
self.allpkgs = allpkgs
self.userpkgs = userpkgs
def loadRecipe(self, pathname):
contents = []
packages = ""
base_image = ""
with open(pathname, 'r') as f:
contents = f.readlines()
pkg_pattern = "^\s*(IMAGE_INSTALL)\s*([+=.?]+)\s*(\".*?\")"
img_pattern = "^\s*(require)\s+(\S+.bb)"
for line in contents:
matchpkg = re.search(pkg_pattern, line)
matchimg = re.search(img_pattern, line)
if matchpkg:
packages = packages + matchpkg.group(3).strip('"')
if matchimg:
base_image = os.path.basename(matchimg.group(2)).split(".")[0]
self.base_image = base_image
self.userpkgs = packages
def writeRecipe(self, writepath, model):
template = """
# Recipe generated by the HOB
require %s
IMAGE_INSTALL += "%s"
"""
empty_template = """
# Recipe generated by the HOB
inherit core-image
IMAGE_INSTALL = "%s"
"""
if self.base_image and not self.base_image == "empty":
meta_path = model.find_image_path(self.base_image)
recipe = template % (meta_path, self.userpkgs)
else:
recipe = empty_template % self.allpkgs
if os.path.exists(writepath):
os.rename(writepath, "%s~" % writepath)
with open(writepath, 'w') as r:
r.write(recipe)
return writepath
class TaskListModel(gtk.ListStore):
"""
This class defines an gtk.ListStore subclass which will convert the output
of the bb.event.TargetsTreeGenerated event into a gtk.ListStore whilst also
providing convenience functions to access gtk.TreeModel subclasses which
provide filtered views of the data.
"""
(COL_NAME, COL_DESC, COL_LIC, COL_GROUP, COL_DEPS, COL_BINB, COL_TYPE, COL_INC, COL_IMG, COL_PATH, COL_PN) = range(11)
__gsignals__ = {
"tasklist-populated" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
()),
"contents-changed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_INT,)),
"image-changed" : (gobject.SIGNAL_RUN_LAST,
gobject.TYPE_NONE,
(gobject.TYPE_STRING,)),
}
"""
"""
def __init__(self):
self.contents = None
self.tasks = None
self.packages = None
self.images = None
self.selected_image = None
gtk.ListStore.__init__ (self,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_STRING,
gobject.TYPE_BOOLEAN,
gobject.TYPE_BOOLEAN,
gobject.TYPE_STRING,
gobject.TYPE_STRING)
"""
Helper method to determine whether name is a target pn
"""
def non_target_name(self, name):
if ('-native' in name) or ('-cross' in name) or name.startswith('virtual/'):
return True
return False
def contents_changed_cb(self, tree_model, path, it=None):
pkg_cnt = self.contents.iter_n_children(None)
self.emit("contents-changed", pkg_cnt)
def contents_model_filter(self, model, it):
if not model.get_value(it, self.COL_INC) or model.get_value(it, self.COL_TYPE) == 'image':
return False
name = model.get_value(it, self.COL_NAME)
if self.non_target_name(name):
return False
else:
return True
"""
Create, if required, and return a filtered gtk.TreeModel
containing only the items which are to be included in the
image
"""
def contents_model(self):
if not self.contents:
self.contents = self.filter_new()
self.contents.set_visible_func(self.contents_model_filter)
self.contents.connect("row-inserted", self.contents_changed_cb)
self.contents.connect("row-deleted", self.contents_changed_cb)
return self.contents
"""
Helper function to determine whether an item is a task
"""
def task_model_filter(self, model, it):
if model.get_value(it, self.COL_TYPE) == 'task':
return True
else:
return False
"""
Create, if required, and return a filtered gtk.TreeModel
containing only the items which are tasks
"""
def tasks_model(self):
if not self.tasks:
self.tasks = self.filter_new()
self.tasks.set_visible_func(self.task_model_filter)
return self.tasks
"""
Helper function to determine whether an item is an image
"""
def image_model_filter(self, model, it):
if model.get_value(it, self.COL_TYPE) == 'image':
return True
else:
return False
"""
Create, if required, and return a filtered gtk.TreeModel
containing only the items which are images
"""
def images_model(self):
if not self.images:
self.images = self.filter_new()
self.images.set_visible_func(self.image_model_filter)
return self.images
"""
Helper function to determine whether an item is a package
"""
def package_model_filter(self, model, it):
if model.get_value(it, self.COL_TYPE) != 'package':
return False
else:
name = model.get_value(it, self.COL_NAME)
if self.non_target_name(name):
return False
return True
"""
Create, if required, and return a filtered gtk.TreeModel
containing only the items which are packages
"""
def packages_model(self):
if not self.packages:
self.packages = self.filter_new()
self.packages.set_visible_func(self.package_model_filter)
return self.packages
"""
The populate() function takes as input the data from a
bb.event.TargetsTreeGenerated event and populates the TaskList.
Once the population is done it emits gsignal tasklist-populated
to notify any listeners that the model is ready
"""
def populate(self, event_model):
# First clear the model, in case repopulating
self.clear()
for item in event_model["pn"]:
atype = 'package'
name = item
summary = event_model["pn"][item]["summary"]
lic = event_model["pn"][item]["license"]
group = event_model["pn"][item]["section"]
filename = event_model["pn"][item]["filename"]
if ('task-' in name):
atype = 'task'
elif ('-image-' in name):
atype = 'image'
# Create a combined list of build and runtime dependencies and
# then remove any duplicate entries and any entries for -dev
# packages
depends = event_model["depends"].get(item, [])
rdepends = event_model["rdepends-pn"].get(item, [])
packages = {}
for pkg in event_model["packages"]:
if event_model["packages"][pkg]["pn"] == name:
deps = []
deps.extend(depends)
deps.extend(event_model["rdepends-pkg"].get(pkg, []))
deps.extend(rdepends)
deps = self.squish(deps)
# rdepends-pn includes pn-dev
if ("%s-dev" % item) in deps:
deps.remove("%s-dev" % item)
# rdepends-on includes pn
if pkg in deps:
deps.remove(pkg)
packages[pkg] = deps
for p in packages:
self.set(self.append(), self.COL_NAME, p, self.COL_DESC, summary,
self.COL_LIC, lic, self.COL_GROUP, group,
self.COL_DEPS, " ".join(packages[p]), self.COL_BINB, "",
self.COL_TYPE, atype, self.COL_INC, False,
self.COL_IMG, False, self.COL_PATH, filename,
self.COL_PN, item)
self.emit("tasklist-populated")
"""
Load a BuildRep into the model
"""
def load_image_rep(self, rep):
# Unset everything
it = self.get_iter_first()
while it:
path = self.get_path(it)
self[path][self.COL_INC] = False
self[path][self.COL_IMG] = False
it = self.iter_next(it)
# Iterate the images and disable them all
it = self.images.get_iter_first()
while it:
path = self.images.convert_path_to_child_path(self.images.get_path(it))
name = self[path][self.COL_NAME]
if name == rep.base_image:
self.include_item(path, image_contents=True)
else:
self[path][self.COL_INC] = False
it = self.images.iter_next(it)
# Mark all of the additional packages for inclusion
packages = rep.userpkgs.split(" ")
it = self.get_iter_first()
while it:
path = self.get_path(it)
name = self[path][self.COL_NAME]
if name in packages:
self.include_item(path, binb="User Selected")
packages.remove(name)
it = self.iter_next(it)
self.emit("image-changed", rep.base_image)
"""
squish lst so that it doesn't contain any duplicate entries
"""
def squish(self, lst):
seen = {}
for l in lst:
seen[l] = 1
return seen.keys()
"""
Mark the item at path as not included
NOTE:
path should be a gtk.TreeModelPath into self (not a filtered model)
"""
def remove_item_path(self, path):
self[path][self.COL_BINB] = ""
self[path][self.COL_INC] = False
"""
Recursively called to mark the item at opath and any package which
depends on it for removal.
NOTE: This method dumbly removes user selected packages and since we don't
do significant reverse dependency tracking it's easier and simpler to save
the items marked as user selected and re-add them once the removal sweep is
complete.
"""
def mark(self, opath):
usersel = {}
removed = []
it = self.get_iter_first()
# The name of the item we're removing, so that we can use it to find
# other items which either depend on it, or were brought in by it
marked_name = self[opath][self.COL_NAME]
# Remove the passed item
self.remove_item_path(opath)
# Remove all dependent packages, update binb
while it:
path = self.get_path(it)
it = self.iter_next(it)
inc = self[path][self.COL_INC]
deps = self[path][self.COL_DEPS]
binb = self[path][self.COL_BINB].split(', ')
itype = self[path][self.COL_TYPE]
itname = self[path][self.COL_NAME]
# We ignore anything that isn't a package
if not itype == "package":
continue
# If the user added this item and it's not the item we're removing
# we should keep it and its dependencies, the easiest way to do so
# is to save its name and re-mark it for inclusion once dependency
# processing is complete
if "User Selected" in binb:
usersel[itname] = self[path][self.COL_IMG]
# If the iterated item is included and depends on the removed
# item it should also be removed.
# FIXME: need to ensure partial name matching doesn't happen
if inc and marked_name in deps and itname not in removed:
# found a dependency, remove it
removed.append(itname)
self.mark(path)
# If the iterated item was brought in by the removed (passed) item
# try and find an alternative dependee and update the binb column
if inc and marked_name in binb:
binb.remove(marked_name)
self[path][self.COL_BINB] = ', '.join(binb).lstrip(', ')
# Re-add any removed user selected items
for u in usersel:
npath = self.find_path_for_item(u)
self.include_item(item_path=npath,
binb="User Selected",
image_contents=usersel[u])
"""
Remove items from contents if the have an empty COL_BINB (brought in by)
caused by all packages they are a dependency of being removed.
If the item isn't a package we leave it included.
"""
def sweep_up(self):
it = self.contents.get_iter_first()
while it:
binb = self.contents.get_value(it, self.COL_BINB)
itype = self.contents.get_value(it, self.COL_TYPE)
remove = False
if itype == 'package' and not binb:
oit = self.contents.convert_iter_to_child_iter(it)
opath = self.get_path(oit)
self.mark(opath)
remove = True
# When we remove a package from the contents model we alter the
# model, so continuing to iterate is bad. *Furthermore* it's
# likely that the removal has affected an already iterated item
# so we should start from the beginning anyway.
# Only when we've managed to iterate the entire contents model
# without removing any items do we allow the loop to exit.
if remove:
it = self.contents.get_iter_first()
else:
it = self.contents.iter_next(it)
"""
Check whether the item at item_path is included or not
"""
def contents_includes_path(self, item_path):
return self[item_path][self.COL_INC]
"""
Add this item, and any of its dependencies, to the image contents
"""
def include_item(self, item_path, binb="", image_contents=False):
item_name = self[item_path][self.COL_NAME]
item_deps = self[item_path][self.COL_DEPS]
self[item_path][self.COL_INC] = True
item_bin = self[item_path][self.COL_BINB].split(', ')
if binb and not binb in item_bin:
item_bin.append(binb)
self[item_path][self.COL_BINB] = ', '.join(item_bin).lstrip(', ')
# We want to do some magic with things which are brought in by the
# base image so tag them as so
if image_contents:
self[item_path][self.COL_IMG] = True
if self[item_path][self.COL_TYPE] == 'image':
self.selected_image = item_name
if item_deps:
# Ensure all of the items deps are included and, where appropriate,
# add this item to their COL_BINB
for dep in item_deps.split(" "):
# If the contents model doesn't already contain dep, add it
dep_path = self.find_path_for_item(dep)
if not dep_path:
continue
dep_included = self.contents_includes_path(dep_path)
if dep_included and not dep in item_bin:
# don't set the COL_BINB to this item if the target is an
# item in our own COL_BINB
dep_bin = self[dep_path][self.COL_BINB].split(', ')
if not item_name in dep_bin:
dep_bin.append(item_name)
self[dep_path][self.COL_BINB] = ', '.join(dep_bin).lstrip(', ')
elif not dep_included:
self.include_item(dep_path, binb=item_name, image_contents=image_contents)
"""
Find the model path for the item_name
Returns the path in the model or None
"""
def find_path_for_item(self, item_name):
# We don't include virtual/* or *-native items in the model so save a
# heavy iteration loop by exiting early for these items
if self.non_target_name(item_name):
return None
it = self.get_iter_first()
while it:
if (self.get_value(it, self.COL_NAME) == item_name):
return self.get_path(it)
else:
it = self.iter_next(it)
return None
"""
Empty self.contents by setting the include of each entry to None
"""
def reset(self):
# Deselect images - slightly more complex logic so that we don't
# have to iterate all of the contents of the main model, instead
# just iterate the images model.
if self.selected_image:
iit = self.images.get_iter_first()
while iit:
pit = self.images.convert_iter_to_child_iter(iit)
self.set(pit, self.COL_INC, False)
iit = self.images.iter_next(iit)
self.selected_image = None
it = self.contents.get_iter_first()
while it:
oit = self.contents.convert_iter_to_child_iter(it)
self.set(oit,
self.COL_INC, False,
self.COL_BINB, "",
self.COL_IMG, False)
# As we've just removed the first item...
it = self.contents.get_iter_first()
"""
Returns two lists. One of user selected packages and the other containing
all selected packages
"""
def get_selected_packages(self):
allpkgs = []
userpkgs = []
it = self.contents.get_iter_first()
while it:
sel = "User Selected" in self.contents.get_value(it, self.COL_BINB)
name = self.contents.get_value(it, self.COL_NAME)
allpkgs.append(name)
if sel:
userpkgs.append(name)
it = self.contents.iter_next(it)
return userpkgs, allpkgs
"""
Return a squished (uniquified) list of the PN's of all selected items
"""
def get_selected_pn(self):
pns = []
it = self.contents.get_iter_first()
while it:
if self.contents.get_value(it, self.COL_BINB):
pns.append(self.contents.get_value(it, self.COL_PN))
it = self.contents.iter_next(it)
return self.squish(pns)
def image_contents_removed(self):
it = self.get_iter_first()
while it:
sel = self.get_value(it, self.COL_INC)
img = self.get_value(it, self.COL_IMG)
if img and not sel:
return True
it = self.iter_next(it)
return False
def get_build_rep(self):
userpkgs, allpkgs = self.get_selected_packages()
# If base image contents have been removed start from an empty rootfs
if not self.selected_image or self.image_contents_removed():
image = "empty"
else:
image = self.selected_image
return BuildRep(" ".join(userpkgs), " ".join(allpkgs), image)
def find_reverse_depends(self, pn):
revdeps = []
it = self.contents.get_iter_first()
while it:
name = self.contents.get_value(it, self.COL_NAME)
itype = self.contents.get_value(it, self.COL_TYPE)
deps = self.contents.get_value(it, self.COL_DEPS)
it = self.contents.iter_next(it)
if not itype == 'package':
continue
if pn in deps:
revdeps.append(name)
if pn in revdeps:
revdeps.remove(pn)
return revdeps
def set_selected_image(self, img):
self.selected_image = img
path = self.find_path_for_item(img)
self.include_item(item_path=path,
binb="User Selected",
image_contents=True)
self.emit("image-changed", self.selected_image)
def set_selected_packages(self, pkglist):
selected = pkglist
it = self.get_iter_first()
while it:
name = self.get_value(it, self.COL_NAME)
if name in pkglist:
pkglist.remove(name)
path = self.get_path(it)
self.include_item(item_path=path,
binb="User Selected")
if len(pkglist) == 0:
return
it = self.iter_next(it)
def find_image_path(self, image):
it = self.images.get_iter_first()
while it:
image_name = self.images.get_value(it, self.COL_NAME)
if image_name == image:
path = self.images.get_value(it, self.COL_PATH)
meta_pattern = "(\S*)/(meta*/)(\S*)"
meta_match = re.search(meta_pattern, path)
if meta_match:
_, lyr, bbrel = path.partition(meta_match.group(2))
if bbrel:
path = bbrel
return path
it = self.images.iter_next(it)

View File

@@ -0,0 +1,180 @@
#
# BitBake Graphical GTK User Interface
#
# Copyright (C) 2011 Intel Corporation
#
# Authored by Shane Wang <shane.wang@intel.com>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
import gobject
import os
import re
class File(gobject.GObject):
def __init__(self, pathfilename, suffix):
if not pathfilename.endswith(suffix):
pathfilename = "%s%s" % (pathfilename, suffix)
gobject.GObject.__init__(self)
self.pathfilename = pathfilename
def readFile(self):
if not os.path.isfile(self.pathfilename):
return None
if not os.path.exists(self.pathfilename):
return None
with open(self.pathfilename, 'r') as f:
contents = f.readlines()
f.close()
return contents
def writeFile(self, contents):
if os.path.exists(self.pathfilename):
orig = "%s.orig" % self.pathfilename
if os.path.exists(orig):
os.remove(orig)
os.rename(self.pathfilename, orig)
with open(self.pathfilename, 'w') as f:
f.write(contents)
f.close()
class ConfigFile(File):
"""
This object does save general config file. (say bblayers.conf, or local.conf). Again, it is the base class for other template files and image bb files.
"""
def __init__(self, pathfilename, suffix = None, header = None):
if suffix:
File.__init__(self, pathfilename, suffix)
else:
File.__init__(self, pathfilename, ".conf")
if header:
self.header = header
else:
self.header = "# Config generated by the HOB\n\n"
self.dictionary = {}
def setVar(self, var, val):
if isinstance(val, list):
liststr = ""
if val:
i = 0
for value in val:
if i < len(val) - 1:
liststr += "%s " % value
else:
liststr += "%s" % value
i += 1
self.dictionary[var] = liststr
else:
self.dictionary[var] = val
def save(self):
contents = self.header
for var, val in self.dictionary.items():
contents += "%s = \"%s\"\n" % (var, val)
File.writeFile(self, contents)
class HobTemplateFile(ConfigFile):
"""
This object does save or load hob specific file.
"""
def __init__(self, pathfilename):
ConfigFile.__init__(self, pathfilename, ".hob", "# Hob Template generated by the HOB\n\n")
def getVar(self, var):
if var in self.dictionary:
return self.dictionary[var]
else:
return ""
def load(self):
contents = ConfigFile.readFile(self)
self.dictionary.clear()
pattern = "^\s*(\S+)\s*=\s*(\".*?\")"
for line in contents:
match = re.search(pattern, line)
if match:
var = match.group(1)
val = match.group(2).strip('"')
self.dictionary[var] = val
return self.dictionary
class RecipeFile(ConfigFile):
"""
This object is for image bb file.
"""
def __init__(self, pathfilename):
ConfigFile.__init__(self, pathfilename, ".bb", "# Recipe generated by the HOB\n\ninherit core-image\n")
class TemplateMgr(gobject.GObject):
__gLocalVars__ = ["MACHINE", "PACKAGE_CLASSES", "DISTRO", "DL_DIR", "SSTATE_DIR", "SSTATE_MIRROR", "PARALLEL_MAKE", "BB_NUMBER_THREAD"]
__gBBLayersVars__ = ["BBLAYERS"]
__gRecipeVars__ = ["DEPENDS", "IMAGE_INSTALL"]
def __init__(self):
gobject.GObject.__init__(self)
self.template_hob = None
self.bblayers_conf = None
self.local_conf = None
self.image_bb = None
def open(self, filename, path):
self.template_hob = HobTemplateFile("%s/%s%s%s" % (path, "template-", filename, ".hob"))
self.bblayers_conf = ConfigFile("%s/%s%s%s" % (path, "bblayers-", filename, ".conf"))
self.local_conf = ConfigFile("%s/%s%s%s" % (path, "local-", filename, ".conf"))
self.image_bb = RecipeFile("%s/%s%s%s" % (path, "hob-image-", filename, ".bb"))
def setVar(self, var, val):
if var in TemplateMgr.__gLocalVars__:
self.local_conf.setVar(var, val)
if var in TemplateMgr.__gBBLayersVars__:
self.bblayers_conf.setVar(var, val)
if var in TemplateMgr.__gRecipeVars__:
self.image_bb.setVar(var, val)
self.template_hob.setVar(var, val)
def save(self):
self.local_conf.save()
self.bblayers_conf.save()
self.image_bb.save()
self.template_hob.save()
def load(self, path):
self.template_hob = HobTemplateFile(path)
self.dictionary = self.template_hob.load()
def getVar(self, var):
return self.template_hob.getVar(var)
def destroy(self):
if self.template_hob:
del self.template_hob
template_hob = None
if self.bblayers_conf:
del self.bblayers_conf
self.bblayers_conf = None
if self.local_conf:
del self.local_conf
self.local_conf = None
if self.image_bb:
del self.image_bb
self.image_bb = None

1111
bitbake/lib/bb/ui/hob.py Normal file → Executable file

File diff suppressed because it is too large Load Diff

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

View File

@@ -64,6 +64,12 @@ def new_progress(msg, maxval):
else:
return NonInteractiveProgress(msg, maxval)
def pluralise(singular, plural, qty):
if(qty == 1):
return singular % qty
else:
return plural % qty
def main(server, eventHandler):
# Get values of variables which control our output
@@ -104,13 +110,17 @@ def main(server, eventHandler):
parseprogress = None
cacheprogress = None
shutdown = 0
interrupted = False
return_value = 0
errors = 0
warnings = 0
taskfailures = []
while True:
try:
event = eventHandler.waitEvent(0.25)
if event is None:
if shutdown > 1:
break
continue
helper.eventHandler(event)
if isinstance(event, bb.runqueue.runQueueExitWait):
@@ -127,7 +137,7 @@ def main(server, eventHandler):
if event.levelno >= format.ERROR:
errors = errors + 1
return_value = 1
if event.levelno >= format.WARNING:
elif event.levelno == format.WARNING:
warnings = warnings + 1
# For "normal" logging conditions, don't show note logs from tasks
# but do show them if the user has changed the default log level to
@@ -142,7 +152,7 @@ def main(server, eventHandler):
logfile = event.logfile
if logfile and os.path.exists(logfile):
print("ERROR: Logfile of failure stored in: %s" % logfile)
if 1 or includelogs:
if includelogs and not event.errprinted:
print("Log data follows:")
f = open(logfile, "r")
lines = []
@@ -192,18 +202,19 @@ def main(server, eventHandler):
print("Loaded %d entries from dependency cache." % event.num_entries)
continue
if isinstance(event, bb.command.CommandCompleted):
break
if isinstance(event, bb.command.CommandFailed):
return_value = event.exitcode
errors = errors + 1
logger.error("Command execution failed: %s", event.error)
break
shutdown = 2
continue
if isinstance(event, bb.command.CommandExit):
if not return_value:
return_value = event.exitcode
continue
if isinstance(event, bb.cooker.CookerExit):
break
if isinstance(event, (bb.command.CommandCompleted, bb.cooker.CookerExit)):
shutdown = 2
continue
if isinstance(event, bb.event.MultipleProviders):
logger.info("multiple providers are available for %s%s (%s)", event._is_runtime and "runtime " or "",
event._item,
@@ -227,6 +238,10 @@ def main(server, eventHandler):
logger.error("%s", reason)
continue
if isinstance(event, bb.runqueue.sceneQueueTaskStarted):
logger.info("Running setscene task %d of %d (%s)" % (event.stats.completed + event.stats.active + event.stats.failed + 1, event.stats.total, event.taskstring))
continue
if isinstance(event, bb.runqueue.runQueueTaskStarted):
if event.noexec:
tasktype = 'noexec task'
@@ -240,10 +255,16 @@ def main(server, eventHandler):
continue
if isinstance(event, bb.runqueue.runQueueTaskFailed):
taskfailures.append(event.taskstring)
logger.error("Task %s (%s) failed with exit code '%s'",
event.taskid, event.taskstring, event.exitcode)
continue
if isinstance(event, bb.runqueue.sceneQueueTaskFailed):
logger.warn("Setscene task %s (%s) failed with exit code '%s' - real task will be run instead",
event.taskid, event.taskstring, event.exitcode)
continue
# ignore
if isinstance(event, (bb.event.BuildBase,
bb.event.StampUpdate,
@@ -251,7 +272,10 @@ def main(server, eventHandler):
bb.event.RecipeParsed,
bb.event.RecipePreFinalise,
bb.runqueue.runQueueEvent,
bb.runqueue.runQueueExitWait)):
bb.runqueue.runQueueExitWait,
bb.event.OperationStarted,
bb.event.OperationCompleted,
bb.event.OperationProgress)):
continue
logger.error("Unknown event: %s", event)
@@ -261,19 +285,34 @@ def main(server, eventHandler):
if ioerror.args[0] == 4:
pass
except KeyboardInterrupt:
if shutdown == 2:
print("\nThird Keyboard Interrupt, exit.\n")
break
if shutdown == 1:
print("\nSecond Keyboard Interrupt, stopping...\n")
server.runCommand(["stateStop"])
if shutdown == 0:
interrupted = True
print("\nKeyboard Interrupt, closing down...\n")
server.runCommand(["stateShutdown"])
shutdown = shutdown + 1
pass
summary = ""
if taskfailures:
summary += pluralise("\nSummary: %s task failed:",
"\nSummary: %s tasks failed:", len(taskfailures))
for failure in taskfailures:
summary += "\n %s" % failure
if warnings:
print("Summary: There were %s WARNING messages shown.\n" % warnings)
summary += pluralise("\nSummary: There was %s WARNING message shown.",
"\nSummary: There were %s WARNING messages shown.", warnings)
if return_value:
print("Summary: There were %s ERROR messages shown, returning a non-zero exit code.\n" % errors)
summary += pluralise("\nSummary: There was %s ERROR message shown, returning a non-zero exit code.",
"\nSummary: There were %s ERROR messages shown, returning a non-zero exit code.", errors)
if summary:
print(summary)
if interrupted:
print("Execution was interrupted, returning a non-zero exit code.")
if return_value == 0:
return_value = 1
return return_value

View File

@@ -28,13 +28,14 @@ import socket, threading, pickle
from SimpleXMLRPCServer import SimpleXMLRPCServer, SimpleXMLRPCRequestHandler
class BBUIEventQueue:
def __init__(self, BBServer):
def __init__(self, BBServer, clientinfo=("localhost, 0")):
self.eventQueue = []
self.eventQueueLock = threading.Lock()
self.eventQueueNotify = threading.Event()
self.BBServer = BBServer
self.clientinfo = clientinfo
self.t = threading.Thread()
self.t.setDaemon(True)
@@ -72,7 +73,7 @@ class BBUIEventQueue:
def startCallbackHandler(self):
server = UIXMLRPCServer()
server = UIXMLRPCServer(self.clientinfo)
self.host, self.port = server.socket.getsockname()
server.register_function( self.system_quit, "event.quit" )
@@ -98,7 +99,7 @@ class BBUIEventQueue:
class UIXMLRPCServer (SimpleXMLRPCServer):
def __init__( self, interface = ("localhost", 0) ):
def __init__( self, interface ):
self.quit = False
SimpleXMLRPCServer.__init__( self,
interface,

View File

@@ -32,11 +32,52 @@ class BBUIHelper:
if isinstance(event, bb.build.TaskSucceeded):
del self.running_tasks[event.pid]
self.needUpdate = True
if isinstance(event, bb.build.TaskFailed):
if isinstance(event, bb.build.TaskFailed) or isinstance(event, bb.build.TaskFailedSilent):
del self.running_tasks[event.pid]
self.failed_tasks.append( { 'title' : "%s %s" % (event._package, event._task)})
self.needUpdate = True
def getTasks(self):
self.needUpdate = False
return (self.running_tasks, self.failed_tasks)
def findServerDetails(self):
import sys
import optparse
from bb.server.xmlrpc import BitbakeServerInfo, BitBakeServerConnection
host = ""
port = 0
bind = ""
parser = optparse.OptionParser(
usage = """%prog -H host -P port -B bindaddr""")
parser.add_option("-H", "--host", help = "Bitbake server's IP address",
action = "store", dest = "host", default = None)
parser.add_option("-P", "--port", help = "Bitbake server's Port number",
action = "store", dest = "port", default = None)
parser.add_option("-B", "--bind", help = "Hob2 local bind address",
action = "store", dest = "bind", default = None)
options, args = parser.parse_args(sys.argv)
for key, val in options.__dict__.items():
if key == 'host' and val:
host = val
elif key == 'port' and val:
port = int(val)
elif key == 'bind' and val:
bind = val
if not host or not port or not bind:
parser.print_usage()
sys.exit(1)
serverinfo = BitbakeServerInfo(host, port)
clientinfo = (bind, 0)
connection = BitBakeServerConnection(serverinfo, clientinfo)
server = connection.connection
eventHandler = connection.events
return server, eventHandler, host, bind

View File

@@ -25,6 +25,7 @@ import errno
import logging
import bb
import bb.msg
import multiprocessing
from commands import getstatusoutput
from contextlib import contextmanager
@@ -862,3 +863,6 @@ def contains(variable, checkvalues, truevalue, falsevalue, d):
if checkvalues.issubset(val):
return truevalue
return falsevalue
def cpu_count():
return multiprocessing.cpu_count()

View File

@@ -1,7 +1,12 @@
import os,sys,logging
import signal, time, atexit, threading
from SimpleXMLRPCServer import SimpleXMLRPCServer, SimpleXMLRPCRequestHandler
import xmlrpclib,sqlite3
import xmlrpclib
try:
import sqlite3
except ImportError:
from pysqlite2 import dbapi2 as sqlite3
import bb.server.xmlrpc
import prserv
@@ -263,7 +268,7 @@ def is_local_special(host, port):
def auto_start(d):
global singleton
if d.getVar('USE_PR_SERV', True) == '0':
if (not d.getVar('PRSERV_HOST', True)) or (not d.getVar('PRSERV_PORT', True)):
return True
if is_local_special(d.getVar('PRSERV_HOST', True), int(d.getVar('PRSERV_PORT', True))) and not singleton:

View File

@@ -14,4 +14,4 @@ PACKAGES += "${PN}-tools"
FILES_${PN}-tools = "${bindir}"
FILES_${PN} = "${libdir}/*.so.*"
export VERBOSE=1
export VERBOSE="1"

17
meta-hob/COPYING.MIT Normal file
View File

@@ -0,0 +1,17 @@
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.

9
meta-hob/conf/layer.conf Normal file
View File

@@ -0,0 +1,9 @@
# We have a conf and classes directory, add to BBPATH
BBPATH := "${BBPATH}:${LAYERDIR}"
# We have a packages directory, add to BBFILES
BBFILES := "${BBFILES} ${LAYERDIR}/recipes-*/*/*.bb"
BBFILE_COLLECTIONS += "hob"
BBFILE_PATTERN_hob := "^${LAYERDIR}/"
BBFILE_PRIORITY_hob = "1"

View File

@@ -0,0 +1 @@
inherit image

View File

@@ -0,0 +1,10 @@
DESCRIPTION = "dummy toolchain"
LICENSE = "MIT"
PR = "r0"
LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58 \
file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
IMAGETEST ?= "dummy"
inherit populate_sdk imagetest-${IMAGETEST}

View File

@@ -0,0 +1,7 @@
#
# OELAYOUT_ABI allows us to notify users when the format of TMPDIR changes in
# an incompatible way. Such changes should usually be detailed in the commit
# that breaks the format and have been previously discussed on the mailing list
# with general agreement from the core team.
#
OELAYOUT_ABI = "8"

View File

@@ -55,6 +55,11 @@ ENABLE_WIDEC="false"
# eglibc->bash->gettext->libc-posix-clang-wchar dependency.
USE_NLS="no"
# -dev packages require pkgconfig, but it pulls in glib->dbus->shadow
# which breaks with tiny's minimal libc.
# -dev packages are not currently supported on poky-tiny.
ASSUME_PROVIDED += "pkgconfig$"
# Reconfigure eglibc for a smaller installation
# Comment out any of the lines below to disable them in the build
DISTRO_FEATURES_LIBC_TINY = "libc-libm libc-crypt"

View File

@@ -12,12 +12,12 @@ LOCALCONF_VERSION = "1"
DISTRO_FEATURES_append = " largefile opengl"
PREFERRED_VERSION_linux-yocto ?= "2.6.37+git%"
PREFERRED_VERSION_linux-yocto_qemux86 ?= "3.0%"
PREFERRED_VERSION_linux-yocto_qemux86-64 ?= "3.0%"
PREFERRED_VERSION_linux-yocto_qemuarm ?= "3.0%"
PREFERRED_VERSION_linux-yocto_qemumips ?= "3.0%"
PREFERRED_VERSION_linux-yocto_qemuppc ?= "3.0%"
PREFERRED_VERSION_linux-yocto ?= "3.0%"
PREFERRED_VERSION_linux-yocto_qemux86 ?= "3.2%"
PREFERRED_VERSION_linux-yocto_qemux86-64 ?= "3.2%"
PREFERRED_VERSION_linux-yocto_qemuarm ?= "3.2%"
PREFERRED_VERSION_linux-yocto_qemumips ?= "3.2%"
PREFERRED_VERSION_linux-yocto_qemuppc ?= "3.2%"
SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${TARGET_ARCH}"
SDKPATH = "/opt/${DISTRO}/${SDK_VERSION}"
@@ -44,19 +44,19 @@ QEMU_TARGETS ?= "arm i386 mips mipsel ppc x86_64"
# Other QEMU_TARGETS "mips64 mips64el sh4"
PREMIRRORS ?= "\
bzr://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
cvs://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
git://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
hg://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
osc://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
p4://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
svk://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
svn://.*/.* http://autobuilder.yoctoproject.org/sources/ \n"
bzr://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
cvs://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
git://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
hg://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
osc://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
p4://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
svk://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
svn://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n"
MIRRORS =+ "\
ftp://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
http://.*/.* http://autobuilder.yoctoproject.org/sources/ \n \
https://.*/.* http://autobuilder.yoctoproject.org/sources/ \n"
ftp://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
http://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
https://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n"
# The CONNECTIVITY_CHECK_URI's are used to test whether we can succesfully
# fetch from the network (and warn you if not). To disable the test set
@@ -65,3 +65,5 @@ CONNECTIVITY_CHECK_URIS ?= "git://git.yoctoproject.org/yocto-firewall-test;proto
https://eula-downloads.yoctoproject.org/index.php \
http://bugzilla.yoctoproject.org/report.cgi"
# Default hash policy for distro
BB_SIGNATURE_HANDLER ?= 'OEBasicHash'

View File

@@ -1,5 +1,5 @@
# We have a conf and classes directory, add to BBPATH
BBPATH := "${BBPATH}:${LAYERDIR}"
BBPATH := "${LAYERDIR}:${BBPATH}"
# We have a packages directory, add to BBFILES
BBFILES := "${BBFILES} ${LAYERDIR}/recipes-*/*/*.bb \

View File

@@ -115,8 +115,12 @@
#DEFAULTTUNE_virtclass-multilib-lib32 = "x86"
# The network based PR service host and port
# Uncomment the following lines to enable PRservice.
# Set PRSERV_HOST to 'localhost' and PRSERV_PORT to '0' to automatically
# start local PRService.
# Set to other values to use remote PRService.
#PRSERV_HOST = "localhost"
#PRSERV_PORT = "8585"
#PRSERV_PORT = "0"
# Additional image generation features
#
@@ -130,3 +134,51 @@
# do update(remove/add some pkgs) on it. NOTE: This is not suggested
# when you want to create a productive rootfs
#INC_RPM_IMAGE_GEN = "1"
# 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"
#
# Disk space monitor, take action when the disk space or the amount of
# inode is running low, it is enabled when BB_DISKMON_DIRS is set.
#
# Set the directories to monitor for disk usage, if more than one
# directories are mounted in the same device, then only one directory
# would be monitored since the monitor is based on the device.
# The format is:
# "action,directory,minimum_space,minimum_free_inode"
#
# The "action" must be set and should be one of:
# ABORT: Immediately abort
# STOPTASKS: The new tasks can't be executed any more, will stop the build
# when the running tasks have been done.
# WARN: show warnings (see BB_DISKMON_WARNINTERVAL for more information)
#
# The "directory" must be set, any directory is OK.
#
# Either "minimum_space" or "minimum_free_inode" (or both of them)
# should be set, otherwise the monitor would not be enabled,
# the unit can be G, M, K or none, but do NOT use GB, MB or KB
# (B is not needed).
#BB_DISKMON_DIRS = "STOPTASKS,${TMPDIR},1G,100K WARN,${SSTATE_DIR},1G,100K"
#
# Set disk space and inode interval (only works when the action is "WARN",
# the unit can be G, M, or K, but do NOT use the GB, MB or KB
# (B is not needed), the format is:
# "disk_space_interval,disk_inode_interval", the default value is
# "50M,5K" which means that it would warn when the free space is
# lower than the minimum space(or inode), and would repeat the warning
# when the disk space reduces 50M (or the amount of inode reduces 5k).
#BB_DISKMON_WARNINTERVAL = "50M,5K"

View File

@@ -12,9 +12,6 @@ XSERVER = "xserver-xorg-lite \
# Ship all kernel modules by default
MACHINE_EXTRA_RRECOMMENDS = " kernel-modules"
# Setup sane default mixer settings
MACHINE_EXTRA_RRECOMMENDS += "beagleboard-audio"
# Allow for MMC booting (required by the NAND-less Beagleboard XM)
EXTRA_IMAGEDEPENDS += "u-boot x-load"

View File

@@ -5,7 +5,7 @@
require conf/machine/include/tune-mips32.inc
MACHINE_FEATURES = "kernel26 screen keyboard pci usbhost ext2 ext3 \
serial usbgadget"
serial"
KERNEL_IMAGETYPE = "vmlinux"
KERNEL_ALT_IMAGETYPE = "vmlinux.bin"

View File

@@ -0,0 +1 @@
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"

View File

@@ -0,0 +1,656 @@
state.omap3beagle {
control.1 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Option 2 (voice/audio)'
comment.item.1 'Option 1 (audio)'
iface MIXER
name 'Codec Operation Mode'
value 'Option 1 (audio)'
}
control.2 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 63'
comment.dbmin -6300
comment.dbmax 0
iface MIXER
name 'DAC1 Digital Fine Playback Volume'
value.0 0
value.1 0
}
control.3 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 63'
comment.dbmin -6300
comment.dbmax 0
iface MIXER
name 'DAC2 Digital Fine Playback Volume'
value.0 50
value.1 50
}
control.4 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 2'
comment.dbmin 0
comment.dbmax 1200
iface MIXER
name 'DAC1 Digital Coarse Playback Volume'
value.0 0
value.1 0
}
control.5 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 2'
comment.dbmin 0
comment.dbmax 1200
iface MIXER
name 'DAC2 Digital Coarse Playback Volume'
value.0 2
value.1 2
}
control.6 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 18'
comment.dbmin -2400
comment.dbmax 1200
iface MIXER
name 'DAC1 Analog Playback Volume'
value.0 0
value.1 0
}
control.7 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 18'
comment.dbmin -2400
comment.dbmax 1200
iface MIXER
name 'DAC2 Analog Playback Volume'
value.0 15
value.1 15
}
control.8 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'DAC1 Analog Playback Switch'
value.0 false
value.1 false
}
control.9 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'DAC2 Analog Playback Switch'
value.0 true
value.1 true
}
control.10 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 49'
comment.dbmin -3700
comment.dbmax 1200
iface MIXER
name 'DAC Voice Digital Downlink Volume'
value 0
}
control.11 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 18'
comment.dbmin -2400
comment.dbmax 1200
iface MIXER
name 'DAC Voice Analog Downlink Volume'
value 18
}
control.12 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'DAC Voice Analog Downlink Switch'
value false
}
control.13 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 3'
comment.dbmin -1200
comment.dbmax 600
iface MIXER
name 'PreDriv Playback Volume'
value.0 0
value.1 0
}
control.14 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 3'
comment.dbmin -1200
comment.dbmax 600
iface MIXER
name 'Headset Playback Volume'
value.0 3
value.1 3
}
control.15 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 3'
comment.dbmin -1200
comment.dbmax 600
iface MIXER
name 'Carkit Playback Volume'
value.0 0
value.1 0
}
control.16 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 3'
comment.dbmin -600
comment.dbmax 1200
iface MIXER
name 'Earpiece Playback Volume'
value 0
}
control.17 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 31'
comment.dbmin 0
comment.dbmax 3100
iface MIXER
name 'TX1 Digital Capture Volume'
value.0 12
value.1 12
}
control.18 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 31'
comment.dbmin 0
comment.dbmax 3100
iface MIXER
name 'TX2 Digital Capture Volume'
value.0 0
value.1 0
}
control.19 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 5'
comment.dbmin 0
comment.dbmax 3000
iface MIXER
name 'Analog Capture Volume'
value.0 0
value.1 0
}
control.20 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Voice high priority'
comment.item.1 'HiFi high priority'
iface MIXER
name 'AVADC Clock Priority'
value 'Voice high priority'
}
control.21 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 '27/20/14 ms'
comment.item.1 '55/40/27 ms'
comment.item.2 '109/81/55 ms'
comment.item.3 '218/161/109 ms'
comment.item.4 '437/323/218 ms'
comment.item.5 '874/645/437 ms'
comment.item.6 '1748/1291/874 ms'
comment.item.7 '3495/2581/1748 ms'
iface MIXER
name 'HS ramp delay'
value '27/20/14 ms'
}
control.22 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Vibra H-bridge direction'
comment.item.1 'Audio data MSB'
iface MIXER
name 'Vibra H-bridge mode'
value 'Vibra H-bridge direction'
}
control.23 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Positive polarity'
comment.item.1 'Negative polarity'
iface MIXER
name 'Vibra H-bridge direction'
value 'Positive polarity'
}
control.24 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Right Sub Mic Capture Switch'
value false
}
control.25 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Right AUXR Capture Switch'
value true
}
control.26 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Left Main Mic Capture Switch'
value false
}
control.27 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Left Headset Mic Capture Switch'
value false
}
control.28 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Left AUXL Capture Switch'
value true
}
control.29 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Left Carkit Mic Capture Switch'
value false
}
control.30 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 Analog
comment.item.1 Digimic1
iface MIXER
name 'TX2 Capture Route'
value Analog
}
control.31 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 Analog
comment.item.1 Digimic0
iface MIXER
name 'TX1 Capture Route'
value Analog
}
control.32 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Local vibrator'
comment.item.1 Audio
iface MIXER
name 'Vibra Route'
value 'Local vibrator'
}
control.33 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 AudioL1
comment.item.1 AudioR1
comment.item.2 AudioL2
comment.item.3 AudioR2
iface MIXER
name 'Vibra Mux'
value AudioL1
}
control.34 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HandsfreeR Switch'
value false
}
control.35 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 Voice
comment.item.1 AudioR1
comment.item.2 AudioR2
comment.item.3 AudioL2
iface MIXER
name 'HandsfreeR Mux'
value Voice
}
control.36 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HandsfreeL Switch'
value false
}
control.37 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 Voice
comment.item.1 AudioL1
comment.item.2 AudioL2
comment.item.3 AudioR2
iface MIXER
name 'HandsfreeL Mux'
value Voice
}
control.38 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'CarkitR Mixer Voice'
value false
}
control.39 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'CarkitR Mixer AudioR1'
value false
}
control.40 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'CarkitR Mixer AudioR2'
value false
}
control.41 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'CarkitL Mixer Voice'
value false
}
control.42 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'CarkitL Mixer AudioL1'
value false
}
control.43 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'CarkitL Mixer AudioL2'
value false
}
control.44 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HeadsetR Mixer Voice'
value false
}
control.45 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HeadsetR Mixer AudioR1'
value false
}
control.46 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HeadsetR Mixer AudioR2'
value true
}
control.47 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HeadsetL Mixer Voice'
value false
}
control.48 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HeadsetL Mixer AudioL1'
value false
}
control.49 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'HeadsetL Mixer AudioL2'
value true
}
control.50 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveR Mixer Voice'
value false
}
control.51 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveR Mixer AudioR1'
value false
}
control.52 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveR Mixer AudioR2'
value false
}
control.53 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveR Mixer AudioL2'
value false
}
control.54 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveL Mixer Voice'
value false
}
control.55 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveL Mixer AudioL1'
value false
}
control.56 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveL Mixer AudioL2'
value false
}
control.57 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PredriveL Mixer AudioR2'
value false
}
control.58 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Earpiece Mixer Voice'
value false
}
control.59 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Earpiece Mixer AudioL1'
value false
}
control.60 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Earpiece Mixer AudioL2'
value false
}
control.61 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Earpiece Mixer AudioR1'
value false
}
control.62 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 41'
comment.dbmin -5100
comment.dbmax -1000
iface MIXER
name 'Voice Digital Loopback Volume'
value 0
}
control.63 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 7'
comment.dbmin -2400
comment.dbmax 0
iface MIXER
name 'Right Digital Loopback Volume'
value 0
}
control.64 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 7'
comment.dbmin -2400
comment.dbmax 0
iface MIXER
name 'Left Digital Loopback Volume'
value 0
}
control.65 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Voice Analog Loopback Switch'
value false
}
control.66 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Left2 Analog Loopback Switch'
value false
}
control.67 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Right2 Analog Loopback Switch'
value false
}
control.68 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Left1 Analog Loopback Switch'
value false
}
control.69 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Right1 Analog Loopback Switch'
value false
}
}

View File

@@ -1,33 +0,0 @@
SUMMARY = "Provide a basic init script to enable audio"
DESCRIPTION = "Set the volume and unmute the Front mixer setting during boot."
SECTION = "base"
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
PR = "r5"
inherit update-rc.d
RDEPENDS_${PN} = "alsa-utils-amixer"
SRC_URI = "file://beagleboard-audio"
INITSCRIPT_NAME = "beagleboard-audio"
INITSCRIPT_PARAMS = "defaults 90"
COMPATIBLE_MACHINE = "beagleboard"
INHIBIT_DEFAULT_DEPS = "1"
do_install() {
install -d ${D}${sysconfdir} \
${D}${sysconfdir}/init.d
install -m 0755 ${WORKDIR}/beagleboard-audio ${D}${sysconfdir}/init.d
cat ${WORKDIR}/${INITSCRIPT_NAME} | \
sed -e 's,/etc,${sysconfdir},g' \
-e 's,/usr/sbin,${sbindir},g' \
-e 's,/var,${localstatedir},g' \
-e 's,/usr/bin,${bindir},g' \
-e 's,/usr,${prefix},g' > ${D}${sysconfdir}/init.d/${INITSCRIPT_NAME}
chmod 755 ${D}${sysconfdir}/init.d/${INITSCRIPT_NAME}
}

View File

@@ -1,44 +0,0 @@
#!/bin/sh
### BEGIN INIT INFO
# Provides: beagleboard mixer setup
# Required-Start: $syslog
# Required-Stop: $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Initialize the beagleboard audio mixer
# Description: Unmute FRONT and set volume to ~70%.
### END INIT INFO
# Author: Darren Hart <dvhart@linux.intel.com>
# Based on /etc/init.d/skeleton
PATH=/sbin:/usr/sbin:/bin:/usr/bin
DESC="Audio mixer settings"
NAME=beagleboard-audio
AMIXER=`which amixer`
SCRIPTNAME=/etc/init.d/$NAME
# Exit if amixer is not installed
[ -x "$AMIXER" ] || exit 0
do_start() {
# Enable the Headset (Audio Out)
$AMIXER sset "Headset" 2 > /dev/null
$AMIXER sset "HeadsetL Mixer AudioL1" on > /dev/null
$AMIXER sset "HeadsetR Mixer AudioR1" on > /dev/null
}
case "$1" in
start)
echo "$NAME: setting default mixer settings."
do_start
;;
stop)
;;
*)
echo "Usage: $SCRIPTNAME {start|stop}" >&2
exit 3
;;
esac
exit 0

View File

@@ -0,0 +1,914 @@
/* Yocto Project logo for psplash
*
* Created using make-image-header.sh (distributed with psplash)
*/
/* GdkPixbuf RGBA C-Source image dump 1-byte-run-length-encoded */
#define POKY_IMG_ROWSTRIDE (1708)
#define POKY_IMG_WIDTH (427)
#define POKY_IMG_HEIGHT (214)
#define POKY_IMG_BYTES_PER_PIXEL (4) /* 3:RGB, 4:RGBA */
#define POKY_IMG_RLE_PIXEL_DATA ((uint8*) \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\237\350\354\340\377\1\350\354\342\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\254\350\354\340\377\2\241\243" \
"\244\377;AC\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\252\350\354\340\377\2\275\277\277\377LQR\377\202.46\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\250\350\354\340" \
"\377\2\321\322\323\377]ac\377\204.46\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\246\350\354\340\377\3\346\347\347\377" \
"w{|\377/57\377\205.46\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\245\350\354\340\377\2\223\226\227\3775;=\377\207.46" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\243" \
"\350\354\340\377\2\253\255\256\377BHJ\377\211.46\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\241\350\354\340\377\2\304" \
"\306\306\377PUW\377\213.46\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\240\350\354\340\377\1\306\310\311\377\215.46\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\240\350" \
"\354\340\377\1\302\303\304\377\215.46\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\240\350\354\340\377\1\302\303\304\377" \
"\215.46\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\240\350\354\340\377\1\302\303\304\377\215.46\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\240\350\354\340\377\1\302\303" \
"\304\377\215.46\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\240\350\354\340\377\1\302\303\304\377\215.46\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\240\350\354\340\377" \
"\1\302\303\304\377\215.46\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\240\350\354\340\377\1\302\303\304\377\215.46\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\240\350" \
"\354\340\377\1\302\303\304\377\215.46\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\240\350\354\340\377\1\302\303\304\377" \
"\215.46\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\240\350\354\340\377\1\302\303\304\377\215.46\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\240\350\354\340\377\1\302\303" \
"\304\377\215.46\377\377\350\354\340\377\305\350\354\340\377\1\346\347" \
"\347\377\256\350\354\340\377\1\341\342\343\377\377\350\354\340\377\252" \
"\350\354\340\377\1\302\303\304\377\215.46\377\377\350\354\340\377\304" \
"\350\354\340\377\3\220\223\224\3775;=\377\244\247\250\377\254\350\354" \
"\340\377\4\302\303\304\377179\377\205\210\212\377\350\354\342\377\377" \
"\350\354\340\377\250\350\354\340\377\1\302\303\304\377\215.46\377\377" \
"\350\354\340\377\302\350\354\340\377\2\250\253\253\377>DF\377\202.46" \
"\377\1@FG\377\254\350\354\340\377\1Y^`\377\202.46\377\2;AC\377\241\243" \
"\244\377\377\350\354\340\377\247\350\354\340\377\1\302\303\304\377\215" \
".46\377\377\350\354\340\377\300\350\354\340\377\2\303\305\305\377PUW" \
"\377\205.46\377\1\230\233\234\377\252\350\354\340\377\1\303\305\305\377" \
"\205.46\377\2LQR\377\275\277\277\377\244\350\354\340\377\16\350\352\351" \
"\377\313\314\315\377\254\257\257\377\224\227\230\377\214\220\221\377" \
"\202\205\206\377w{|\377uy{\377\202\205\206\377\213\216\217\377\223\226" \
"\227\377\253\255\256\377\310\312\312\377\346\346\347\377\362\350\354" \
"\340\377\1\302\303\304\377\215.46\377\267\350\354\340\377\16\352\354" \
"\345\377\315\316\317\377\257\262\263\377\225\230\231\377\216\221\222" \
"\377\202\205\206\377x|}\377txy\377\202\205\206\377\211\214\215\377\221" \
"\224\225\377\247\252\253\377\305\306\307\377\342\343\343\377\370\350" \
"\354\340\377\2\327\330\330\377bgh\377\207.46\377\1""9\77A\377\252\350" \
"\354\340\377\1]ac\377\207.46\377\2bgh\377\327\330\330\377\236\350\354" \
"\340\377\4\323\324\324\377\237\242\243\377kop\3779>@\377\216.46\377\4" \
"7=\77\377fjl\377\232\235\236\377\316\317\320\377\303\350\354\340\377" \
"\7\352\354\346\377\332\333\334\377\303\305\305\377\271\273\274\377\263" \
"\265\266\377\253\256\257\377\247\252\253\377\244\235\240\241\377\1}\200" \
"\202\377\215.46\377\1\227\232\233\377\221\235\240\241\377\1\335\336\336" \
"\377\240\350\354\340\377\4\330\332\332\377\244\247\250\377ptu\377>CE" \
"\377\216.46\377\4""4:<\377_de\377\224\230\231\377\311\312\313\377\362" \
"\350\354\340\377\3\352\353\347\377~\202\203\377068\377\211.46\377\1\216" \
"\221\222\377\250\350\354\340\377\1\306\310\311\377\211.46\377\3""068" \
"\377~\202\203\377\352\353\347\377\231\350\354\340\377\3\332\333\334\377" \
"\214\220\221\377CIJ\377\226.46\377\3>CE\377\207\212\213\377\321\322\323" \
"\377\272\350\354\340\377\6\324\325\325\377\257\261\262\377\213\217\220" \
"\377gkl\377FKM\37728:\377\313.46\377\1\265\267\270\377\235\350\354\340" \
"\377\3\341\342\342\377\224\230\231\377JOQ\377\226.46\377\3""9\77A\377" \
"}\200\202\377\312\313\314\377\356\350\354\340\377\2\225\230\231\3778" \
">\77\377\213.46\377\2""5;=\377\350\352\351\377\247\350\354\340\377\1" \
"_de\377\213.46\377\2""8>\77\377\232\235\236\377\226\350\354\340\377\2" \
"\264\266\266\377V[]\377\234.46\377\2PUV\377\253\256\257\377\264\350\354" \
"\340\377\4\322\323\324\377\235\237\240\377gkl\3776<>\377\321.46\377\1" \
"\265\267\270\377\233\350\354\340\377\2\277\301\302\377`ef\377\234.46" \
"\377\2GMN\377\240\243\244\377\354\350\354\340\377\1BHJ\377\215.46\377" \
"\1\202\205\206\377\246\350\354\340\377\1\311\312\313\377\215.46\377\1" \
"CIJ\377\224\350\354\340\377\2\241\243\244\377FKM\377\240.46\377\2@FG" \
"\377\231\233\234\377\257\350\354\340\377\3\325\326\327\377\214\220\221" \
"\377EJL\377\325.46\377\1\265\267\270\377\231\350\354\340\377\2\255\257" \
"\260\377NSU\377\240.46\377\3""9\77A\377\220\223\224\377\350\354\342\377" \
"\351\350\354\340\377\1\251\253\254\377\215.46\377\2""179\377\341\342" \
"\343\377\245\350\354\340\377\1bfh\377\215.46\377\1\244\247\250\377\222" \
"\350\354\340\377\2\275\277\277\377LQR\377\244.46\377\2BHJ\377\264\267" \
"\267\377\253\350\354\340\377\2\253\256\257\377PUV\377\330.46\377\1\265" \
"\267\270\377\227\350\354\340\377\2\313\314\315\377UY[\377\244.46\377" \
"\2;AC\377\247\252\253\377\351\350\354\340\377\1LQS\377\215.46\377\1x" \
"|}\377\244\350\354\340\377\1\314\316\316\377\215.46\377\1BGI\377\221" \
"\350\354\340\377\2\346\347\347\377hmn\377\250.46\377\2]ac\377\340\341" \
"\341\377\247\350\354\340\377\2\235\237\240\377BGI\377\332.46\377\1\265" \
"\267\270\377\225\350\354\340\377\2\350\354\342\377txz\377\250.46\377" \
"\2PUW\377\324\326\326\377\347\350\354\340\377\1\270\272\272\377\215." \
"46\377\2""068\377\330\332\332\377\243\350\354\340\377\1eik\377\215.4" \
"6\377\1\242\244\245\377\220\350\354\340\377\2\275\277\277\377=BD\377" \
"\252.46\377\2""8>\77\377\261\263\264\377\244\350\354\340\377\2\265\267" \
"\270\377BHJ\377\334.46\377\1\265\267\270\377\224\350\354\340\377\2\313" \
"\315\315\377EJL\377\252.46\377\2""28:\377\240\243\244\377\347\350\354" \
"\340\377\1V[]\377\215.46\377\1kpq\377\242\350\354\340\377\1\316\317\320" \
"\377\215.46\377\1@FG\377\220\350\354\340\377\1\210\214\215\377\256.4" \
"6\377\1y}\177\377\241\350\354\340\377\2\336\337\337\377aeg\377\336.4" \
"6\377\1\265\267\270\377\223\350\354\340\377\2\231\234\235\377068\377" \
"\255.46\377\1imo\377\346\350\354\340\377\1\304\306\306\377\216.46\377" \
"\1\317\321\321\377\241\350\354\340\377\1glm\377\215.46\377\1\236\241" \
"\242\377\217\350\354\340\377\1ptu\377\260.46\377\1chi\377\237\350\354" \
"\340\377\2\264\267\267\3778>\77\377\337.46\377\1\265\267\270\377\222" \
"\350\354\340\377\1\202\205\206\377\260.46\377\2TYZ\377\352\353\347\377" \
"\345\350\354\340\377\1chi\377\215.46\377\1bfh\377\240\350\354\340\377" \
"\1\321\322\323\377\215.46\377\1>DF\377\217\350\354\340\377\1_de\377\262" \
".46\377\2TYZ\377\352\353\347\377\234\350\354\340\377\1\202\205\206\377" \
"\341.46\377\1\265\267\270\377\221\350\354\340\377\1ptv\377\262.46\377" \
"\2HMO\377\337\340\340\377\344\350\354\340\377\2\322\323\324\377/57\377" \
"\215.46\377\1\304\306\306\377\237\350\354\340\377\1kop\377\215.46\377" \
"\1\234\237\240\377\216\350\354\340\377\1aeg\377\264.46\377\1SXY\377\233" \
"\350\354\340\377\1fjl\377\342.46\377\1\265\267\270\377\220\350\354\340" \
"\377\1ptu\377\264.46\377\2EJL\377\350\351\351\377\344\350\354\340\377" \
"\1ptv\377\215.46\377\1V[]\377\236\350\354\340\377\1\324\326\326\377\215" \
".46\377\1=BD\377\216\350\354\340\377\1nrs\377\226.46\377\12=BD\377`e" \
"f\377\200\204\205\377\220\223\224\377\233\236\237\377\234\237\240\377" \
"\220\223\224\377\202\205\206\377bgh\377>DF\377\226.46\377\1dij\377\231" \
"\350\354\340\377\1_de\377\231.46\377\3""39;\377EJL\377Y^`\377\202fjl" \
"\377\1swx\377\244txy\377\1_de\377\215.46\377\1ptu\377\221txy\377\1\316" \
"\317\320\377\217\350\354\340\377\1\204\210\211\377\226.46\377\12""9\77" \
"A\377[`a\377}\200\202\377\220\223\224\377\231\234\235\377\235\240\241" \
"\377\220\223\224\377\205\210\212\377fjl\377BHJ\377\226.46\377\1SXY\377" \
"\344\350\354\340\377\2\335\336\336\377068\377\215.46\377\1\271\273\274" \
"\377\235\350\354\340\377\1lqr\377\215.46\377\1\231\233\234\377\215\350" \
"\354\340\377\1\207\213\214\377\224.46\377\3PUW\377\234\237\240\377\327" \
"\330\330\377\212\350\354\340\377\3\332\333\334\377\236\241\242\377PU" \
"V\377\224.46\377\1x|}\377\227\350\354\340\377\1[`a\377\225.46\377\5K" \
"PR\377\177\203\204\377\247\252\253\377\311\312\313\377\352\354\346\377" \
"\252\350\354\340\377\1\302\303\304\377\215.46\377\241\350\354\340\377" \
"\1\237\242\243\377\224.46\377\3JOQ\377\226\231\232\377\320\322\322\377" \
"\212\350\354\340\377\3\336\337\337\377\242\245\246\377Y]_\377\224.46" \
"\377\1eik\377\344\350\354\340\377\1~\201\202\377\215.46\377\1OTV\377" \
"\234\350\354\340\377\2\326\327\330\377/57\377\214.46\377\1;AC\377\215" \
"\350\354\340\377\1\271\273\274\377\222.46\377\3/57\377ptu\377\314\316" \
"\316\377\220\350\354\340\377\2\312\313\314\377jnp\377\223.46\377\1\254" \
"\257\257\377\225\350\354\340\377\1y|~\377\222.46\377\4/57\377]ac\377" \
"\247\252\253\377\346\347\347\377\257\350\354\340\377\1\302\303\304\377" \
"\215.46\377\240\350\354\340\377\2\316\317\320\377068\377\222.46\377\2" \
"fjl\377\305\306\307\377\220\350\354\340\377\3\323\324\324\377txy\377" \
"068\377\222.46\377\1\225\230\231\377\343\350\354\340\377\2\347\350\350" \
"\3775:<\377\215.46\377\1\256\260\261\377\233\350\354\340\377\1ptu\377" \
"\215.46\377\1\226\231\232\377\214\350\354\340\377\2\344\345\345\377:" \
"@B\377\221.46\377\2gkl\377\332\333\334\377\224\350\354\340\377\2\324" \
"\326\326\377^ce\377\221.46\377\2""6<>\377\335\336\337\377\223\350\354" \
"\340\377\1\235\240\241\377\221.46\377\3""39;\377\177\203\204\377\341" \
"\342\342\377\262\350\354\340\377\1\302\303\304\377\215.46\377\237\350" \
"\354\340\377\2\350\354\342\377FKM\377\221.46\377\2[`a\377\321\322\323" \
"\377\224\350\354\340\377\2\335\336\337\377kop\377\221.46\377\2""068\377" \
"\314\316\316\377\343\350\354\340\377\1\213\217\220\377\215.46\377\1F" \
"KM\377\232\350\354\340\377\2\331\332\333\377/57\377\214.46\377\1:@B\377" \
"\215\350\354\340\377\1^ce\377\220.46\377\2;AC\377\265\267\270\377\230" \
"\350\354\340\377\2\251\253\254\3775;=\377\220.46\377\1Y]_\377\222\350" \
"\354\340\377\2\325\326\327\377068\377\220.46\377\2ptu\377\346\346\347" \
"\377\264\350\354\340\377\1\302\303\304\377\215.46\377\237\350\354\340" \
"\377\1txz\377\220.46\377\2""6<>\377\250\253\253\377\230\350\354\340\377" \
"\2\270\272\272\377<BC\377\220.46\377\1GMN\377\343\350\354\340\377\2\350" \
"\354\342\3779\77A\377\215.46\377\1\244\247\250\377\231\350\354\340\377" \
"\1rvw\377\215.46\377\1\223\226\227\377\214\350\354\340\377\1\261\263" \
"\264\377\220.46\377\2X]^\377\344\345\345\377\232\350\354\340\377\2\327" \
"\330\330\377HMO\377\220.46\377\1\255\257\260\377\221\350\354\340\377" \
"\1UY[\377\217.46\377\2<BC\377\274\276\276\377\266\350\354\340\377\1\302" \
"\303\304\377\215.46\377\236\350\354\340\377\1\311\312\313\377\220.46" \
"\377\2LQS\377\330\332\332\377\232\350\354\340\377\2\342\343\343\377S" \
"XY\377\220.46\377\1\224\230\231\377\343\350\354\340\377\1\230\233\234" \
"\377\215.46\377\1@FG\377\230\350\354\340\377\2\332\333\334\377068\377" \
"\214.46\377\1""9>@\377\215\350\354\340\377\1AFH\377\217.46\377\1gkl\377" \
"\235\350\354\340\377\2\352\353\347\377OTV\377\217.46\377\1\77EG\377\220" \
"\350\354\340\377\1\232\235\236\377\217.46\377\2MRT\377\340\341\341\377" \
"\267\350\354\340\377\1\302\303\304\377\215.46\377\236\350\354\340\377" \
"\1OTV\377\217.46\377\2W\\]\377\350\354\342\377\235\350\354\340\377\1" \
"\\ab\377\217.46\377\2""5:<\377\346\346\347\377\343\350\354\340\377\1" \
"AFH\377\215.46\377\1\230\233\234\377\227\350\354\340\377\1uy{\377\215" \
".46\377\1\220\224\225\377\214\350\354\340\377\1\217\222\223\377\217." \
"46\377\1imo\377\237\350\354\340\377\2\352\354\346\377LQR\377\217.46\377" \
"\1\220\224\225\377\217\350\354\340\377\1""9>@\377\216.46\377\2OTV\377" \
"\351\354\343\377\270\350\354\340\377\1\302\303\304\377\215.46\377\235" \
"\350\354\340\377\1\246\251\252\377\217.46\377\1[`a\377\240\350\354\340" \
"\377\1[`a\377\217.46\377\1{\177\200\377\343\350\354\340\377\1\246\251" \
"\252\377\215.46\377\2""9\77A\377\350\354\342\377\225\350\354\340\377" \
"\2\335\336\337\377068\377\214.46\377\2""8>\77\377\351\354\343\377\214" \
"\350\354\340\377\1""9>@\377\216.46\377\1QVX\377\241\350\354\340\377\2" \
"\341\342\343\377\77EG\377\216.46\377\1;AC\377\216\350\354\340\377\1\224" \
"\230\231\377\216.46\377\2GLN\377\350\351\351\377\271\350\354\340\377" \
"\1\302\303\304\377\215.46\377\235\350\354\340\377\1GLN\377\216.46\377" \
"\2EJL\377\350\351\351\377\240\350\354\340\377\2\351\354\343\377JOQ\377" \
"\216.46\377\2""179\377\346\347\347\377\343\350\354\340\377\1INP\377\215" \
".46\377\1\216\221\222\377\225\350\354\340\377\1x|}\377\215.46\377\1\216" \
"\221\222\377\214\350\354\340\377\1\230\233\234\377\216.46\377\2""7=\77" \
"\377\337\340\340\377\242\350\354\340\377\2\312\313\314\377068\377\216" \
".46\377\1\242\244\245\377\215\350\354\340\377\1;AC\377\215.46\377\2""0" \
"68\377\316\317\320\377\272\350\354\340\377\1\302\303\304\377\215.46\377" \
"\234\350\354\340\377\1\257\261\262\377\216.46\377\2""068\377\317\320" \
"\320\377\242\350\354\340\377\2\330\332\332\3775:<\377\216.46\377\1\213" \
"\216\217\377\343\350\354\340\377\1\264\266\266\377\215.46\377\2""5;=" \
"\377\350\352\351\377\223\350\354\340\377\2\337\340\340\377068\377\214" \
".46\377\2""6<>\377\352\354\346\377\214\350\354\340\377\1>DF\377\216." \
"46\377\1\246\250\251\377\244\350\354\340\377\1\216\221\222\377\216.4" \
"6\377\1GLN\377\214\350\354\340\377\1\246\251\252\377\216.46\377\1\223" \
"\226\227\377\273\350\354\340\377\1\302\303\304\377\215.46\377\234\350" \
"\354\340\377\1OTV\377\216.46\377\1\220\223\224\377\244\350\354\340\377" \
"\1\244\247\250\377\216.46\377\1""8>\77\377\344\350\354\340\377\1UY[\377" \
"\215.46\377\1\202\205\206\377\223\350\354\340\377\1z~\177\377\215.46" \
"\377\1\213\216\217\377\214\350\354\340\377\1\271\273\274\377\216.46\377" \
"\1Z_a\377\246\350\354\340\377\1JOQ\377\216.46\377\1\310\312\312\377\213" \
"\350\354\340\377\1[`a\377\215.46\377\1BHJ\377\274\350\354\340\377\1\302" \
"\303\304\377\215.46\377\233\350\354\340\377\1\320\322\322\377\216.46" \
"\377\1HMO\377\246\350\354\340\377\1\\ab\377\216.46\377\1\260\263\263" \
"\377\343\350\354\340\377\1\302\303\304\377\215.46\377\2""179\377\341" \
"\342\342\377\221\350\354\340\377\2\341\342\343\377179\377\214.46\377" \
"\2""5;=\377\352\353\347\377\214\350\354\340\377\1nrs\377\216.46\377\1" \
"\316\317\320\377\246\350\354\340\377\1\273\275\276\377\216.46\377\1|" \
"\200\201\377\212\350\354\340\377\1\341\342\343\377\216.46\377\1\253\255" \
"\256\377\274\350\354\340\377\1\302\303\304\377\215.46\377\233\350\354" \
"\340\377\1\204\210\211\377\216.46\377\1\270\272\272\377\246\350\354\340" \
"\377\2\321\322\323\377/57\377\215.46\377\1eik\377\344\350\354\340\377" \
"\1_de\377\215.46\377\1x|}\377\221\350\354\340\377\1~\201\202\377\215" \
".46\377\1\210\214\215\377\214\350\354\340\377\2\350\354\342\37728:\377" \
"\215.46\377\1hmn\377\250\350\354\340\377\1X]^\377\215.46\377\1""9>@\377" \
"\212\350\354\340\377\1\231\234\235\377\215.46\377\1;AC\377\275\350\354" \
"\340\377\1\302\303\304\377\215.46\377\233\350\354\340\377\1=BD\377\215" \
".46\377\1PUW\377\250\350\354\340\377\1ost\377\215.46\377\2""068\377\351" \
"\352\350\377\343\350\354\340\377\1\316\317\320\377\215.46\377\2""068" \
"\377\330\332\332\377\217\350\354\340\377\2\343\344\344\377179\377\214" \
".46\377\2""4:<\377\350\352\351\377\214\350\354\340\377\1\265\267\270" \
"\377\216.46\377\1\305\306\307\377\250\350\354\340\377\1\271\273\273\377" \
"\216.46\377\1\303\305\305\377\211\350\354\340\377\1eik\377\215.46\377" \
"\1\207\212\213\377\275\350\354\340\377\1\302\303\304\377\215.46\377\232" \
"\350\354\340\377\1\313\314\315\377\216.46\377\1\260\263\263\377\250\350" \
"\354\340\377\1\317\320\320\377\216.46\377\1\254\257\257\377\344\350\354" \
"\340\377\1nrs\377\215.46\377\1kpq\377\217\350\354\340\377\1\200\204\205" \
"\377\215.46\377\1\205\210\212\377\215\350\354\340\377\1\201\204\206\377" \
"\215.46\377\1MRT\377\252\350\354\340\377\1BHJ\377\215.46\377\1\217\222" \
"\223\377\211\350\354\340\377\1""6<>\377\215.46\377\1\312\313\314\377" \
"\275\350\354\340\377\1\302\303\304\377\215.46\377\232\350\354\340\377" \
"\1\226\231\232\377\215.46\377\1=BD\377\252\350\354\340\377\1W\\]\377" \
"\215.46\377\1x|}\377\344\350\354\340\377\2\333\334\334\377068\377\215" \
".46\377\1\317\320\320\377\215\350\354\340\377\2\345\346\346\37739;\377" \
"\214.46\377\2""39;\377\347\350\350\377\215\350\354\340\377\1LQR\377\215" \
".46\377\1\225\230\231\377\252\350\354\340\377\1\211\214\215\377\215." \
"46\377\1\\ab\377\210\350\354\340\377\1\321\322\323\377\215.46\377\1:" \
"@B\377\276\350\354\340\377\1\302\303\304\377\215.46\377\232\350\354\340" \
"\377\1bgh\377\215.46\377\1\177\203\204\377\252\350\354\340\377\1\237" \
"\242\243\377\215.46\377\1DIK\377\345\350\354\340\377\1z~\177\377\215" \
".46\377\1bfh\377\215\350\354\340\377\1\203\207\210\377\215.46\377\1\203" \
"\207\210\377\215\350\354\340\377\1\352\354\346\377\216.46\377\1\335\336" \
"\336\377\252\350\354\340\377\1\316\317\320\377\215.46\377\1""179\377" \
"\210\350\354\340\377\1\246\251\252\377\215.46\377\1imo\377\276\350\354" \
"\340\377\1\302\303\304\377\215.46\377\232\350\354\340\377\1""5:<\377" \
"\215.46\377\1\306\310\311\377\252\350\354\340\377\1\344\345\345\377\216" \
".46\377\1\344\345\345\377\252\350\354\340\377\5\304\336\373\377\236\311" \
"\370\377\220\301\367\377\234\310\370\377\273\331\372\377\265\350\354" \
"\340\377\2\344\345\345\37739;\377\215.46\377\1\304\306\306\377\213\350" \
"\354\340\377\2\347\350\350\37739;\377\214.46\377\2""28:\377\345\346\346" \
"\377\215\350\354\340\377\1\313\315\315\377\215.46\377\1@FG\377\254\350" \
"\354\340\377\1""6<>\377\215.46\377\1\331\332\333\377\207\350\354\340" \
"\377\1\212\215\216\377\215.46\377\1\222\225\226\377\276\350\354\340\377" \
"\1\302\303\304\377\215.46\377\231\350\354\340\377\1\341\342\343\377\215" \
".46\377\1""28:\377\254\350\354\340\377\1HMO\377\215.46\377\1\302\304" \
"\305\377\250\350\354\340\377\2\262\324\371\377[\244\363\377\205O\235" \
"\362\377\2U\240\362\377\236\311\370\377\264\350\354\340\377\1\211\214" \
"\215\377\215.46\377\1V[]\377\213\350\354\340\377\1\205\210\212\377\215" \
".46\377\1\200\204\205\377\216\350\354\340\377\1\253\256\257\377\215." \
"46\377\1quw\377\254\350\354\340\377\1chi\377\215.46\377\1\275\277\277" \
"\377\207\350\354\340\377\1mqs\377\215.46\377\1\270\272\272\377\276\350" \
"\354\340\377\1\302\303\304\377\215.46\377\231\350\354\340\377\1\302\304" \
"\305\377\215.46\377\1[`a\377\254\350\354\340\377\1y}\177\377\215.46\377" \
"\1\246\250\251\377\247\350\354\340\377\1\214\277\366\377\211O\235\362" \
"\377\1u\262\365\377\263\350\354\340\377\2\352\354\345\3779>@\377\215" \
".46\377\1\271\273\273\377\211\350\354\340\377\2\350\352\351\3775:<\377" \
"\214.46\377\2""179\377\343\344\344\377\216\350\354\340\377\1\217\222" \
"\223\377\215.46\377\1\231\233\234\377\254\350\354\340\377\1\212\215\216" \
"\377\215.46\377\1\235\240\241\377\207\350\354\340\377\1QVX\377\215.4" \
"6\377\1\320\322\322\377\276\350\354\340\377\1\302\303\304\377\215.46" \
"\377\231\350\354\340\377\1\246\250\251\377\215.46\377\1\202\205\206\377" \
"\254\350\354\340\377\1\237\242\243\377\215.46\377\1\207\212\213\377\246" \
"\350\354\340\377\1\236\311\370\377\213O\235\362\377\1\177\270\366\377" \
"\263\350\354\340\377\1\225\230\231\377\215.46\377\1OTV\377\211\350\354" \
"\340\377\1\210\214\215\377\215.46\377\1}\200\202\377\217\350\354\340" \
"\377\1y|~\377\215.46\377\1\264\267\267\377\254\350\354\340\377\1\246" \
"\251\252\377\215.46\377\1\206\211\212\377\207\350\354\340\377\1;AC\377" \
"\215.46\377\1\347\350\350\377\276\350\354\340\377\1\302\303\304\377\215" \
".46\377\231\350\354\340\377\1\216\221\222\377\215.46\377\1\235\240\241" \
"\377\254\350\354\340\377\1\274\276\276\377\215.46\377\1nrs\377\245\350" \
"\354\340\377\2\342\357\375\377Q\236\362\377\214O\235\362\377\1\304\336" \
"\373\377\263\350\354\340\377\1>DF\377\215.46\377\1\256\260\261\377\207" \
"\350\354\340\377\2\352\353\347\3775;=\377\214.46\377\2""179\377\341\342" \
"\342\377\217\350\354\340\377\1kpq\377\215.46\377\1\313\315\315\377\254" \
"\350\354\340\377\1\276\300\301\377\215.46\377\1{\177\200\377\207\350" \
"\354\340\377\1""179\377\215.46\377\277\350\354\340\377\1\302\303\304" \
"\377\215.46\377\231\350\354\340\377\1\204\210\211\377\215.46\377\1\267" \
"\271\272\377\254\350\354\340\377\1\326\327\330\377\215.46\377\1eik\377" \
"\245\350\354\340\377\1\232\307\370\377\215O\235\362\377\1z\265\365\377" \
"\263\350\354\340\377\1\243\246\247\377\215.46\377\1FKM\377\207\350\354" \
"\340\377\1\213\216\217\377\215.46\377\1y}\177\377\220\350\354\340\377" \
"\1bgh\377\215.46\377\1\332\333\334\377\254\350\354\340\377\1\314\316" \
"\316\377\215.46\377\1quw\377\207\350\354\340\377\216.46\377\277\350\354" \
"\340\377\1\302\303\304\377\215.46\377\231\350\354\340\377\1y|~\377\215" \
".46\377\1\302\303\304\377\254\350\354\340\377\1\341\342\343\377\215." \
"46\377\1[`a\377\245\350\354\340\377\1i\254\364\377\215O\235\362\377\1" \
"Q\236\362\377\264\350\354\340\377\1GMN\377\215.46\377\1\243\246\247\377" \
"\205\350\354\340\377\2\352\354\346\3776<>\377\214.46\377\2""068\377\337" \
"\340\340\377\220\350\354\340\377\1Y^`\377\215.46\377\1\341\342\343\377" \
"\254\350\354\340\377\1\324\326\326\377\215.46\377\1hmn\377\207\350\354" \
"\340\377\215.46\377\1""8>\77\377\277\350\354\340\377\1\302\303\304\377" \
"\215.46\377\231\350\354\340\377\1ptu\377\215.46\377\1\314\316\316\377" \
"\254\350\354\340\377\1\351\352\350\377\215.46\377\1QVX\377\245\350\354" \
"\340\377\1U\240\362\377\216O\235\362\377\1\344\360\375\377\263\350\354" \
"\340\377\1\260\263\263\377\215.46\377\1@FG\377\205\350\354\340\377\1" \
"\216\221\222\377\215.46\377\1w{|\377\221\350\354\340\377\1Y]_\377\215" \
".46\377\1\342\343\343\377\254\350\354\340\377\1\325\326\327\377\215." \
"46\377\1glm\377\206\350\354\340\377\1\351\352\350\377\215.46\377\1""5" \
";=\377\277\350\354\340\377\1\302\303\304\377\215.46\377\231\350\354\340" \
"\377\1ptu\377\215.46\377\1\315\316\317\377\254\350\354\340\377\1\352" \
"\353\347\377\215.46\377\1QVX\377\245\350\354\340\377\1U\240\362\377\216" \
"O\235\362\377\1\345\361\375\377\264\350\354\340\377\1PUW\377\215.46\377" \
"\1\230\233\234\377\203\350\354\340\377\2\351\354\343\3778>\77\377\214" \
".46\377\2""068\377\335\336\336\377\221\350\354\340\377\1bfh\377\215." \
"46\377\1\332\333\334\377\254\350\354\340\377\1\314\316\316\377\215.4" \
"6\377\1quw\377\207\350\354\340\377\216.46\377\277\350\354\340\377\1\302" \
"\303\304\377\215.46\377\231\350\354\340\377\1x|}\377\215.46\377\1\302" \
"\303\304\377\254\350\354\340\377\1\341\342\343\377\215.46\377\1Z_a\377" \
"\245\350\354\340\377\1l\255\364\377\215O\235\362\377\1R\237\362\377\265" \
"\350\354\340\377\1\275\277\300\377\215.46\377\2""9\77A\377\350\354\342" \
"\377\202\350\354\340\377\1\220\224\225\377\215.46\377\1txz\377\222\350" \
"\354\340\377\1kpq\377\215.46\377\1\314\316\316\377\254\350\354\340\377" \
"\1\277\301\302\377\215.46\377\1z~\177\377\207\350\354\340\377\216.46" \
"\377\1\352\354\345\377\276\350\354\340\377\1\302\303\304\377\215.46\377" \
"\231\350\354\340\377\1\204\210\211\377\215.46\377\1\271\273\273\377\254" \
"\350\354\340\377\1\327\330\330\377\215.46\377\1dij\377\245\350\354\340" \
"\377\1\236\311\370\377\215O\235\362\377\1\177\270\366\377\266\350\354" \
"\340\377\1]ac\377\215.46\377\4\215\220\221\377\350\354\340\377\350\354" \
"\342\3779>@\377\214.46\377\2/57\377\332\333\334\377\222\350\354\340\377" \
"\1w{|\377\215.46\377\1\265\267\270\377\254\350\354\340\377\1\250\253" \
"\253\377\215.46\377\1\205\210\212\377\207\350\354\340\377\1""068\377" \
"\215.46\377\1\341\342\342\377\276\350\354\340\377\1\302\303\304\377\215" \
".46\377\231\350\354\340\377\1\215\220\221\377\215.46\377\1\237\242\243" \
"\377\254\350\354\340\377\1\276\300\301\377\215.46\377\1mqs\377\245\350" \
"\354\340\377\2\350\362\375\377S\237\362\377\214O\235\362\377\1\315\343" \
"\373\377\266\350\354\340\377\1\313\315\315\377\215.46\377\3""5;=\377" \
"\350\352\351\377\223\226\227\377\215.46\377\1quw\377\223\350\354\340" \
"\377\1\216\221\222\377\215.46\377\1\231\234\235\377\254\350\354\340\377" \
"\1\214\220\221\377\215.46\377\1\234\237\240\377\207\350\354\340\377\1" \
"AFH\377\215.46\377\1\321\322\323\377\276\350\354\340\377\1\302\303\304" \
"\377\215.46\377\231\350\354\340\377\1\244\247\250\377\215.46\377\1\203" \
"\207\210\377\254\350\354\340\377\1\241\243\244\377\215.46\377\1\205\210" \
"\212\377\246\350\354\340\377\1\253\320\371\377\213O\235\362\377\1\214" \
"\277\366\377\270\350\354\340\377\1imo\377\215.46\377\2uy{\377:@B\377" \
"\214.46\377\2/57\377\330\332\332\377\223\350\354\340\377\1\252\254\255" \
"\377\215.46\377\1txy\377\254\350\354\340\377\1gkl\377\215.46\377\1\272" \
"\274\275\377\207\350\354\340\377\1W\\]\377\215.46\377\1\251\253\254\377" \
"\276\350\354\340\377\1\302\303\304\377\215.46\377\231\350\354\340\377" \
"\1\301\302\303\377\215.46\377\1^ce\377\254\350\354\340\377\1}\200\202" \
"\377\215.46\377\1\243\246\247\377\247\350\354\340\377\1\231\306\367\377" \
"\211O\235\362\377\1\200\270\366\377\271\350\354\340\377\2\327\330\330" \
"\377068\377\232.46\377\1nrs\377\224\350\354\340\377\1\311\312\313\377" \
"\215.46\377\1CIJ\377\254\350\354\340\377\1""8>\77\377\215.46\377\1\330" \
"\331\331\377\207\350\354\340\377\1kpq\377\215.46\377\1\177\203\204\377" \
"\276\350\354\340\377\1\302\303\304\377\215.46\377\231\350\354\340\377" \
"\1\337\340\340\377\215.46\377\1""4:<\377\254\350\354\340\377\1LQR\377" \
"\215.46\377\1\301\302\303\377\250\350\354\340\377\2\303\336\373\377d" \
"\251\364\377\205O\235\362\377\2Z\243\363\377\260\323\371\377\273\350" \
"\354\340\377\1x|}\377\231.46\377\2/57\377\325\326\327\377\224\350\354" \
"\340\377\1\351\352\350\377\216.46\377\1\340\341\341\377\252\350\354\340" \
"\377\1\321\322\323\377\215.46\377\1""068\377\210\350\354\340\377\1\213" \
"\217\220\377\215.46\377\1V[]\377\276\350\354\340\377\1\302\303\304\377" \
"\215.46\377\232\350\354\340\377\1""39;\377\215.46\377\1\312\313\314\377" \
"\252\350\354\340\377\1\350\351\351\377\216.46\377\1\341\342\342\377\252" \
"\350\354\340\377\5\323\346\374\377\255\321\371\377\236\311\370\377\251" \
"\317\371\377\313\342\373\377\275\350\354\340\377\2\342\343\343\37728" \
":\377\230.46\377\1kpq\377\226\350\354\340\377\1INP\377\215.46\377\1\232" \
"\235\236\377\252\350\354\340\377\1\214\220\221\377\215.46\377\1X]^\377" \
"\210\350\354\340\377\1\261\263\264\377\215.46\377\1""179\377\276\350" \
"\354\340\377\1\302\303\304\377\215.46\377\232\350\354\340\377\1_de\377" \
"\215.46\377\1\204\210\211\377\252\350\354\340\377\1\243\246\247\377\215" \
".46\377\1BGI\377\356\350\354\340\377\1\204\210\211\377\230.46\377\1\323" \
"\324\324\377\226\350\354\340\377\1}\200\202\377\215.46\377\1QVX\377\252" \
"\350\354\340\377\1GLN\377\215.46\377\1\214\220\221\377\210\350\354\340" \
"\377\1\330\331\331\377\216.46\377\1\253\256\257\377\275\350\354\340\377" \
"\1\302\303\304\377\215.46\377\232\350\354\340\377\1\224\227\230\377\215" \
".46\377\1\77EG\377\252\350\354\340\377\1[`a\377\215.46\377\1txz\377\356" \
"\350\354\340\377\2\352\353\347\3776<>\377\226.46\377\1imo\377\227\350" \
"\354\340\377\1\262\264\265\377\216.46\377\1\313\314\315\377\250\350\354" \
"\340\377\1\276\300\301\377\216.46\377\1\300\302\302\377\211\350\354\340" \
"\377\1;AC\377\215.46\377\1_de\377\275\350\354\340\377\1\302\303\304\377" \
"\215.46\377\232\350\354\340\377\1\306\310\311\377\216.46\377\1\265\267" \
"\270\377\250\350\354\340\377\1\324\325\325\377\216.46\377\1\251\253\254" \
"\377\357\350\354\340\377\1\223\226\227\377\226.46\377\1\320\322\322\377" \
"\227\350\354\340\377\2\352\354\350\377179\377\215.46\377\1ost\377\250" \
"\350\354\340\377\1]ac\377\215.46\377\1""6<>\377\212\350\354\340\377\1" \
"mqs\377\215.46\377\2/57\377\341\342\343\377\274\350\354\340\377\1\302" \
"\303\304\377\215.46\377\233\350\354\340\377\1""9\77A\377\215.46\377\1" \
"V[]\377\250\350\354\340\377\1txz\377\215.46\377\2/57\377\346\346\347" \
"\377\360\350\354\340\377\1=BD\377\224.46\377\1fjl\377\231\350\354\340" \
"\377\1imo\377\215.46\377\2/57\377\324\325\325\377\246\350\354\340\377" \
"\1\303\305\305\377\216.46\377\1x|}\377\212\350\354\340\377\1\246\251" \
"\252\377\216.46\377\1y}\177\377\274\350\354\340\377\1\302\303\304\377" \
"\215.46\377\233\350\354\340\377\1\200\204\205\377\216.46\377\1\276\300" \
"\301\377\246\350\354\340\377\2\330\331\331\377068\377\215.46\377\1`e" \
"f\377\361\350\354\340\377\1\237\242\243\377\224.46\377\1\316\317\320" \
"\377\231\350\354\340\377\1\264\267\267\377\216.46\377\1aeg\377\246\350" \
"\354\340\377\1OTV\377\216.46\377\1\303\305\305\377\212\350\354\340\377" \
"\2\351\352\350\377068\377\215.46\377\2/57\377\323\324\324\377\273\350" \
"\354\340\377\1\302\303\304\377\215.46\377\233\350\354\340\377\1\313\315" \
"\315\377\216.46\377\1NSU\377\246\350\354\340\377\1chi\377\216.46\377" \
"\1\253\256\257\377\362\350\354\340\377\1DIK\377\222.46\377\1chi\377\233" \
"\350\354\340\377\1;AC\377\216.46\377\1\257\262\263\377\244\350\354\340" \
"\377\1\230\233\234\377\216.46\377\1BHJ\377\214\350\354\340\377\1aeg\377" \
"\216.46\377\1]ac\377\273\350\354\340\377\1\302\303\304\377\215.46\377" \
"\234\350\354\340\377\1JOQ\377\216.46\377\1\231\233\234\377\244\350\354" \
"\340\377\1\256\260\261\377\216.46\377\1""5;=\377\363\350\354\340\377" \
"\1\256\260\261\377\222.46\377\1\313\314\315\377\233\350\354\340\377\1" \
"\224\227\230\377\216.46\377\2:@B\377\346\346\347\377\242\350\354\340" \
"\377\2\322\323\324\377179\377\216.46\377\1\235\240\241\377\214\350\354" \
"\340\377\1\262\264\265\377\217.46\377\1\220\223\224\377\272\350\354\340" \
"\377\1\302\303\304\377\215.46\377\234\350\354\340\377\1\252\254\255\377" \
"\216.46\377\2""39;\377\326\327\330\377\242\350\354\340\377\2\340\341" \
"\341\3778>\77\377\216.46\377\1\207\212\213\377\364\350\354\340\377\1" \
"OTV\377\220.46\377\1`ef\377\234\350\354\340\377\2\350\354\342\3778>\77" \
"\377\216.46\377\1Y]_\377\241\350\354\340\377\2\350\351\351\377EJL\377" \
"\216.46\377\1;AC\377\216\350\354\340\377\1BHJ\377\216.46\377\2/57\377" \
"\264\267\267\377\271\350\354\340\377\1\302\303\304\377\215.46\377\235" \
"\350\354\340\377\1EJL\377\216.46\377\2KPR\377\351\354\343\377\241\350" \
"\354\340\377\1NSU\377\216.46\377\2""179\377\346\346\347\377\364\350\354" \
"\340\377\1\272\274\275\377\220.46\377\1\307\311\311\377\235\350\354\340" \
"\377\1\220\223\224\377\217.46\377\1swx\377\240\350\354\340\377\1SXY\377" \
"\217.46\377\1\220\224\225\377\216\350\354\340\377\1\233\236\237\377\217" \
".46\377\2""6<>\377\301\302\303\377\270\350\354\340\377\1\302\303\304" \
"\377\215.46\377\1\352\354\350\377\234\350\354\340\377\1\246\251\252\377" \
"\217.46\377\1bfh\377\240\350\354\340\377\1chi\377\217.46\377\1z~\177" \
"\377\366\350\354\340\377\1Y]_\377\216.46\377\1^ce\377\237\350\354\340" \
"\377\1BGI\377\217.46\377\1lqr\377\235\350\354\340\377\2\352\354\350\377" \
"SXY\377\217.46\377\1BGI\377\220\350\354\340\377\1@FG\377\217.46\377\2" \
"068\377\246\251\252\377\267\350\354\340\377\1\302\303\304\377\215.46" \
"\377\1\335\336\337\377\235\350\354\340\377\1QVX\377\217.46\377\1\\ab" \
"\377\236\350\354\340\377\1_de\377\217.46\377\2""6<>\377\346\347\347\377" \
"\366\350\354\340\377\1\311\312\313\377\216.46\377\1\304\306\306\377\237" \
"\350\354\340\377\1\265\267\270\377\220.46\377\2W\\]\377\344\345\345\377" \
"\232\350\354\340\377\2\326\327\330\377HMO\377\220.46\377\1\261\263\264" \
"\377\220\350\354\340\377\1\247\252\253\377\221.46\377\1\202\206\207\377" \
"\242\350\354\340\377\2\264\267\267\377\276\300\301\377\222\350\354\340" \
"\377\1\310\312\312\377\215.46\377\1\267\271\272\377\235\350\354\340\377" \
"\2\314\316\316\377/57\377\217.46\377\2LQS\377\330\331\331\377\232\350" \
"\354\340\377\2\341\342\342\377SXY\377\220.46\377\1\231\233\234\377\367" \
"\350\354\340\377\2\341\342\343\377068\377\214.46\377\1[`a\377\241\350" \
"\354\340\377\1eik\377\220.46\377\2;AC\377\263\265\266\377\230\350\354" \
"\340\377\2\246\251\252\3775:<\377\220.46\377\1]ac\377\222\350\354\340" \
"\377\1Y]_\377\221.46\377\2BHJ\377\264\267\267\377\235\350\354\340\377" \
"\5\331\332\333\377\207\213\214\377=BD\377.46\377FKM\377\222\350\354\340" \
"\377\1\327\330\330\377\215.46\377\1uy{\377\220\350\354\340\377\1\350" \
"\354\342\377\215\350\354\340\377\1|\200\201\377\220.46\377\2""5:<\377" \
"\245\247\250\377\230\350\354\340\377\2\265\267\270\377;AC\377\220.46" \
"\377\1KPR\377\370\350\354\340\377\1\205\210\212\377\215.46\377\1\302" \
"\303\304\377\241\350\354\340\377\2\350\351\351\377>DF\377\221.46\377" \
"\2fjl\377\335\336\336\377\224\350\354\340\377\2\327\330\330\377^bd\377" \
"\221.46\377\2""9\77A\377\342\343\343\377\222\350\354\340\377\2\332\333" \
"\334\37739;\377\222.46\377\2W\\]\377\257\262\263\377\230\350\354\340" \
"\377\3\320\322\322\377\217\222\223\377MRT\377\205.46\377\1\246\250\251" \
"\377\221\350\354\340\377\1\347\350\350\377\215.46\377\2""179\377\324" \
"\326\326\377\215\350\354\340\377\3\235\240\241\377CIJ\377txz\377\216" \
"\350\354\340\377\1KPR\377\221.46\377\2[`a\377\324\325\325\377\224\350" \
"\354\340\377\2\341\342\342\377kop\377\221.46\377\2""39;\377\323\324\324" \
"\377\367\350\354\340\377\2\350\354\342\3775;=\377\214.46\377\1Y]_\377" \
"\243\350\354\340\377\2\303\305\305\377/57\377\221.46\377\3""068\377{" \
"\177\200\377\332\333\334\377\220\350\354\340\377\3\325\326\327\377tx" \
"z\377/57\377\222.46\377\1\270\272\272\377\224\350\354\340\377\1\244\247" \
"\250\377\224.46\377\3>DF\377\206\211\212\377\277\301\302\377\221\350" \
"\354\340\377\4\325\326\327\377\245\247\250\377txy\377BGI\377\210.46\377" \
"\1BGI\377\222\350\354\340\377\1/57\377\215.46\377\2CIJ\377\330\332\332" \
"\377\211\350\354\340\377\3\302\304\305\377|\200\201\3777=\77\377\202" \
".46\377\2""068\377\332\333\334\377\215\350\354\340\377\2\326\327\330" \
"\3774:<\377\221.46\377\3/57\377ptv\377\320\322\322\377\220\350\354\340" \
"\377\3\336\337\337\377\201\204\206\377179\377\222.46\377\1\237\242\243" \
"\377\370\350\354\340\377\1\224\227\230\377\215.46\377\1\277\301\302\377" \
"\244\350\354\340\377\1\224\227\230\377\224.46\377\3TYZ\377\232\235\236" \
"\377\317\320\320\377\212\350\354\340\377\3\321\322\323\377\232\235\236" \
"\377SXY\377\224.46\377\1\207\212\213\377\226\350\354\340\377\1vz{\377" \
"\226.46\377\21""179\377\\ab\377~\201\202\377\233\236\237\377\272\274" \
"\275\377\313\315\315\377\325\326\327\377\333\334\334\377\343\344\344" \
"\377\331\332\333\377\315\316\317\377\301\302\303\377\264\266\266\377" \
"\224\230\231\377uy{\377V[]\3776<>\377\215.46\377\1\236\241\242\377\221" \
"\350\354\340\377\1PUW\377\216.46\377\12""179\377y}\177\377\274\276\276" \
"\377\337\340\340\377\343\344\344\377\332\333\334\377\305\306\307\377" \
"\235\237\240\377rvw\377<BC\377\206.46\377\1quw\377\216\350\354\340\377" \
"\1\253\256\257\377\224.46\377\3NSU\377\223\226\227\377\312\313\314\377" \
"\212\350\354\340\377\3\327\330\330\377\241\243\244\377]ac\377\224.46" \
"\377\1ptu\377\371\350\354\340\377\1=BD\377\214.46\377\1V[]\377\246\350" \
"\354\340\377\1|\200\201\377\226.46\377\12""39;\377PUV\377nrs\377~\201" \
"\202\377\207\212\213\377\210\214\215\377~\202\203\377ost\377RWY\3774" \
":<\377\226.46\377\1nrs\377\230\350\354\340\377\1aeg\377\263.46\377\1" \
">CE\377\221\350\354\340\377\1\204\210\211\377\236.46\377\2/57\377\330" \
"\331\331\377\216\350\354\340\377\1\220\224\225\377\226.46\377\12""28" \
":\377LQS\377kop\377|\200\201\377\205\210\212\377\211\214\215\377\200" \
"\204\205\377ptv\377UZ\\\3776<>\377\226.46\377\1[`a\377\371\350\354\340" \
"\377\1\225\230\231\377\215.46\377\1\274\276\276\377\247\350\354\340\377" \
"\1nrs\377\264.46\377\1[`a\377\232\350\354\340\377\1UZ\\\377\263.46\377" \
"\1\231\233\234\377\220\350\354\340\377\1\270\272\272\377\237.46\377\1" \
"ost\377\217\350\354\340\377\1\204\210\211\377\264.46\377\2PUW\377\351" \
"\354\343\377\370\350\354\340\377\2\350\354\342\3779>@\377\214.46\377" \
"\1TYZ\377\251\350\354\340\377\1nrs\377\262.46\377\1bfh\377\234\350\354" \
"\340\377\1_de\377\262.46\377\1:@B\377\221\350\354\340\377\1BHJ\377\236" \
".46\377\2/57\377\326\327\330\377\217\350\354\340\377\1\177\203\204\377" \
"\262.46\377\2SXY\377\351\352\350\377\371\350\354\340\377\1\213\217\220" \
"\377\215.46\377\1\271\273\274\377\252\350\354\340\377\1\177\203\204\377" \
"\260.46\377\1quw\377\236\350\354\340\377\1rvw\377\262.46\377\1\222\225" \
"\226\377\220\350\354\340\377\1\231\234\235\377\237.46\377\1mqs\377\220" \
"\350\354\340\377\1\224\227\230\377\260.46\377\1bfh\377\372\350\354\340" \
"\377\2\350\352\351\3775:<\377\214.46\377\1QVX\377\254\350\354\340\377" \
"\2\231\233\234\377068\377\254.46\377\2/57\377\214\220\221\377\240\350" \
"\354\340\377\2\237\242\243\377068\377\260.46\377\2""7=\77\377\352\354" \
"\345\377\220\350\354\340\377\1BHJ\377\237.46\377\1\323\324\324\377\220" \
"\350\354\340\377\2\253\256\257\3774:<\377\255.46\377\1y|~\377\373\350" \
"\354\340\377\1\202\205\206\377\215.46\377\1\266\270\271\377\255\350\354" \
"\340\377\2\312\313\314\377CIJ\377\252.46\377\2>CE\377\277\301\302\377" \
"\242\350\354\340\377\2\322\323\324\377PUV\377\260.46\377\1\213\216\217" \
"\377\220\350\354\340\377\2\307\311\311\377/57\377\236.46\377\1jnp\377" \
"\221\350\354\340\377\2\330\331\331\377LQS\377\252.46\377\2""6<>\377\257" \
"\262\263\377\373\350\354\340\377\2\342\343\343\377179\377\214.46\377" \
"\1NSU\377\257\350\354\340\377\2\351\354\343\377quw\377\250.46\377\2f" \
"jl\377\346\347\347\377\245\350\354\340\377\2\224\230\231\3775;=\377\255" \
".46\377\2W\\]\377\265\267\270\377\221\350\354\340\377\1\227\232\233\377" \
"\237.46\377\1\321\322\323\377\222\350\354\340\377\2\200\204\205\377/" \
"57\377\247.46\377\2Y^`\377\335\336\336\377\374\350\354\340\377\1ptu\377" \
"\215.46\377\1\264\267\267\377\261\350\354\340\377\2\304\306\306\377L" \
"QR\377\244.46\377\2FKM\377\271\273\274\377\250\350\354\340\377\3\346" \
"\347\347\377|\200\201\37728:\377\250.46\377\3""28:\377vz{\377\317\321" \
"\321\377\224\350\354\340\377\1\235\237\240\377\234.46\377\3/57\377qu" \
"w\377\341\342\342\377\223\350\354\340\377\2\321\322\323\377V[]\377\244" \
".46\377\2>DF\377\253\256\257\377\375\350\354\340\377\1\306\307\310\377" \
"\215.46\377\1MRT\377\264\350\354\340\377\2\242\245\246\377CIJ\377\240" \
".46\377\2>CE\377\231\233\234\377\254\350\354\340\377\3\346\346\347\377" \
"\207\213\214\377:@B\377\243.46\377\4/57\377Y^`\377\235\240\241\377\352" \
"\353\347\377\227\350\354\340\377\2\266\270\271\377>CE\377\230.46\377" \
"\3""179\377quw\377\324\326\326\377\227\350\354\340\377\2\255\257\260" \
"\377KPR\377\240.46\377\3""9>@\377\215\220\221\377\350\354\342\377\376" \
"\350\354\340\377\1OTV\377\215.46\377\1\262\264\265\377\266\350\354\340" \
"\377\2\252\254\255\377KPR\377\234.46\377\2DIK\377\242\244\245\377\261" \
"\350\354\340\377\3\256\260\261\377dij\377068\377\235.46\377\4""068\377" \
"`ef\377\243\246\247\377\346\347\347\377\233\350\354\340\377\3\352\354" \
"\345\377z~\177\37728:\377\224.46\377\3HMO\377\224\230\231\377\350\351" \
"\351\377\233\350\354\340\377\2\265\267\270\377SXY\377\234.46\377\2>C" \
"E\377\226\231\232\377\377\350\354\340\377\2\350\354\340\377\227\232\233" \
"\377\215.46\377\1PUW\377\271\350\354\340\377\3\317\320\320\377\210\214" \
"\215\377BHJ\377\226.46\377\3>CE\377\201\204\206\377\312\313\314\377\265" \
"\350\354\340\377\4\350\354\342\377\257\261\262\377x|}\377BHJ\377\226" \
".46\377\5""6<>\377`ef\377\220\223\224\377\277\301\302\377\350\354\342" \
"\377\240\350\354\340\377\3\347\350\350\377\220\223\224\377HMO\377\216" \
".46\377\4""179\377[`a\377\224\227\230\377\326\327\330\377\240\350\354" \
"\340\377\3\330\331\331\377\220\223\224\377HMO\377\226.46\377\3""9>@\377" \
"z~\177\377\301\302\303\377\377\350\354\340\377\202\350\354\340\377\2" \
"\332\333\334\37739;\377\215.46\377\1\275\277\277\377\274\350\354\340" \
"\377\4\326\327\330\377\244\247\250\377swx\377CIJ\377\216.46\377\4@FG" \
"\377nrs\377\240\243\244\377\321\322\323\377\274\350\354\340\377\7\350" \
"\352\351\377\306\307\310\377\242\244\245\377\177\203\204\377Y^`\377B" \
"HJ\3775;=\377\211.46\377\6CIJ\377_de\377z~\177\377\226\231\232\377\262" \
"\264\265\377\325\326\327\377\250\350\354\340\377\6\336\337\337\377\246" \
"\251\252\377\205\210\212\377fjl\377LQS\377DIK\377\202<BC\377\6GLN\377" \
"SXY\377eik\377\204\210\211\377\242\245\246\377\311\312\313\377\247\350" \
"\354\340\377\4\333\334\334\377\251\253\254\377x|}\377HMO\377\216.46\377" \
"\4;AC\377imo\377\232\235\236\377\314\316\316\377\377\350\354\340\377" \
"\205\350\354\340\377\1UZ\\\377\215.46\377\1\\ab\377\302\350\354\340\377" \
"\14\330\331\331\377\274\276\276\377\244\247\250\377\235\237\240\377\220" \
"\223\224\377\210\214\215\377\207\212\213\377\220\223\224\377\234\237" \
"\240\377\243\246\247\377\271\273\273\377\326\327\330\377\311\350\354" \
"\340\377\5\352\354\345\377\340\341\341\377\325\326\327\377\341\342\342" \
"\377\343\344\344\377\353\350\354\340\377\15\333\334\334\377\276\300\301" \
"\377\246\250\251\377\235\240\241\377\220\224\225\377\211\214\215\377" \
"\205\210\212\377\220\223\224\377\232\235\236\377\242\244\245\377\265" \
"\267\270\377\323\324\324\377\350\354\342\377\377\350\354\340\377\210" \
"\350\354\340\377\1\205\210\212\377\216.46\377\1\313\315\315\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\235\350\354\340" \
"\377\1\264\267\267\377\216.46\377\1txz\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\235\350\354\340\377\2\322\323\324\377" \
"5:<\377\215.46\377\2""9>@\377\350\352\351\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\234\350\354\340\377\2\334\335\335" \
"\377\77EG\377\216.46\377\1\243\246\247\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\234\350\354\340\377\2\335\336\337\377" \
"@FG\377\216.46\377\1V[]\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\234\350\354\340\377\2\336\337\337\377BGI\377\216.46" \
"\377\2""6<>\377\335\336\336\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\233\350\354\340\377\2\333\334\334\377BHJ\377\217" \
".46\377\1\252\254\255\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\233\350\354\340\377\2\277\301\302\3779>@\377\217.46" \
"\377\1ptu\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\233\350\354\340\377\2\215\220\221\377/57\377\217.46\377\1LQS\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\232\350" \
"\354\340\377\2\304\306\306\377PUW\377\220.46\377\2\77EG\377\341\342\343" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\230" \
"\350\354\340\377\2\335\336\336\377imo\377\221.46\377\2""5:<\377\322\323" \
"\324\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\227\350\354\340\377\3\312\313\314\377vz{\377179\377\221.46\377\2""2" \
"8:\377\275\277\277\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\225\350\354\340\377\3\341\342\343\377\237\242\243\377MR" \
"T\377\223.46\377\2""068\377\271\273\274\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\223\350\354\340\377\3\310\312\312\377" \
"\215\220\221\377OTV\377\225.46\377\2""068\377\264\267\267\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\221\350\354\340" \
"\377\3\217\222\223\377Y^`\377179\377\227.46\377\2""5:<\377\275\277\300" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\222" \
"\350\354\340\377\1\201\204\206\377\230.46\377\2;AC\377\313\315\315\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\223\350" \
"\354\340\377\2\341\342\343\377179\377\226.46\377\2NSU\377\335\336\337" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\225" \
"\350\354\340\377\1x|}\377\225.46\377\1ptu\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\227\350\354\340\377\2\333\334\334" \
"\377/57\377\222.46\377\2""9>@\377\252\254\255\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\231\350\354\340\377\1ptu\377" \
"\221.46\377\2eik\377\344\345\345\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\232\350\354\340\377\1\324\325\325\377\217" \
".46\377\2PUW\377\275\277\277\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\235\350\354\340\377\1gkl\377\214.46\377\2LQ" \
"S\377\260\263\263\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\237\350\354\340\377\1\313\315\315\377\211.46\377\3""068" \
"\377jnp\377\275\277\277\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\242\350\354\340\377\1^ce\377\205.46\377\4""8>\77\377" \
"kpq\377\253\255\256\377\350\352\351\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\244\350\354\340\377\6\302\304\305\377.4" \
"6\377;AC\377bgh\377\224\230\231\377\314\316\316\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\251\350\354\340\377\1\345\346" \
"\346\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\337\350\354\340\377\1\352\354\350\377\210\325\326\327\377\1\341" \
"\342\342\377\232\350\354\340\377\1\341\342\343\377\207\325\326\327\377" \
"\1\343\344\344\377\244\350\354\340\377\2\314\316\316\377\267\271\272" \
"\377\202\244\247\250\377\2\267\271\272\377\315\316\317\377\236\350\354" \
"\340\377\1\350\351\351\377\204\343\344\344\377\224\350\354\340\377\1" \
"\332\333\334\377\217\325\326\327\377\232\350\354\340\377\3\300\302\302" \
"\377\235\237\240\377\206\211\212\377\202\202\205\206\377\3\212\215\216" \
"\377\242\245\246\377\307\311\311\377\225\350\354\340\377\1\344\345\345" \
"\377\223\325\326\327\377\1\335\336\336\377\377\350\354\340\377\302\350" \
"\354\340\377\1\235\237\240\377\212.46\377\3KPR\377\213\216\217\377\335" \
"\336\337\377\226\350\354\340\377\1kpq\377\211.46\377\3BGI\377txy\377" \
"\271\273\273\377\235\350\354\340\377\3\265\267\270\377lqr\3776<>\377" \
"\206.46\377\3""6<>\377nrs\377\270\272\272\377\233\350\354\340\377\1S" \
"XY\377\204.46\377\224\350\354\340\377\1GLN\377\217.46\377\1\331\332\333" \
"\377\226\350\354\340\377\3\267\271\272\377fjl\377068\377\210.46\377\4" \
"068\377aeg\377\246\251\252\377\350\354\342\377\221\350\354\340\377\1" \
"x|}\377\223.46\377\1SXY\377\377\350\354\340\377\302\350\354\340\377\1" \
"\235\237\240\377\214.46\377\2""179\377\213\217\220\377\225\350\354\340" \
"\377\1kpq\377\214.46\377\2PUW\377\326\327\330\377\231\350\354\340\377" \
"\2\275\277\300\377PUV\377\214.46\377\2RWY\377\277\301\302\377\231\350" \
"\354\340\377\1SXY\377\204.46\377\224\350\354\340\377\1GLN\377\217.46" \
"\377\1\332\333\334\377\224\350\354\340\377\2\312\313\314\377QVX\377\216" \
".46\377\2""6<>\377\207\213\214\377\220\350\354\340\377\1txz\377\223." \
"46\377\1SXY\377\377\350\354\340\377\302\350\354\340\377\1\235\237\240" \
"\377\216.46\377\1swx\377\224\350\354\340\377\1kpq\377\215.46\377\2""7" \
"=\77\377\317\321\321\377\227\350\354\340\377\1\210\214\215\377\220.4" \
"6\377\1\211\214\215\377\230\350\354\340\377\1SXY\377\204.46\377\224\350" \
"\354\340\377\1GLN\377\217.46\377\1\334\335\335\377\223\350\354\340\377" \
"\2\225\230\231\377068\377\220.46\377\1JOQ\377\220\350\354\340\377\1k" \
"pq\377\223.46\377\1SXY\377\377\350\354\340\377\302\350\354\340\377\1" \
"\235\237\240\377\204.46\377\1@FG\377\202JOQ\377\2FKM\377068\377\206." \
"46\377\1\257\261\262\377\223\350\354\340\377\1kpq\377\204.46\377\1GL" \
"N\377\202JOQ\377\1AFH\377\206.46\377\1GMN\377\226\350\354\340\377\1g" \
"lm\377\207.46\377\4<BC\377QVX\377RWY\377>CE\377\207.46\377\1glm\377\227" \
"\350\354\340\377\1SXY\377\204.46\377\224\350\354\340\377\1GLN\377\203" \
".46\377\1/57\377\213<BC\377\1\350\351\351\377\222\350\354\340\377\1\204" \
"\210\211\377\207.46\377\6INP\377fjl\377txy\377imo\377QVX\37728:\377\205" \
".46\377\1\255\257\260\377\220\350\354\340\377\1uy{\377\206<BC\377\1;" \
"AC\377\204.46\377\1""068\377\207<BC\377\1^ce\377\377\350\354\340\377" \
"\302\350\354\340\377\1\235\237\240\377\204.46\377\1\265\267\270\377\204" \
"\350\354\340\377\2\250\253\253\3776<>\377\204.46\377\1SXY\377\223\350" \
"\354\340\377\1kpq\377\204.46\377\1\346\347\347\377\203\350\354\340\377" \
"\2\352\354\345\377\207\213\214\377\205.46\377\1\271\273\274\377\224\350" \
"\354\340\377\1z~\177\377\205.46\377\3""5;=\377\213\217\220\377\327\330" \
"\330\377\204\350\354\340\377\3\334\335\335\377\223\226\227\3778>\77\377" \
"\205.46\377\1y|~\377\226\350\354\340\377\1SXY\377\204.46\377\224\350" \
"\354\340\377\1GLN\377\203.46\377\1:@B\377\235\350\354\340\377\1\240\243" \
"\244\377\205.46\377\3:@B\377\224\230\231\377\344\345\345\377\206\350" \
"\354\340\377\5\306\307\310\377\202\205\206\377:@B\377.46\377GMN\377\231" \
"\350\354\340\377\204.46\377\1SXY\377\377\350\354\340\377\312\350\354" \
"\340\377\1\235\237\240\377\204.46\377\1\265\267\270\377\205\350\354\340" \
"\377\1\255\257\260\377\205.46\377\1\351\354\343\377\222\350\354\340\377" \
"\1kpq\377\204.46\377\1\346\347\347\377\205\350\354\340\377\1z~\177\377" \
"\204.46\377\1\210\214\215\377\223\350\354\340\377\1\257\262\263\377\205" \
".46\377\2^bd\377\350\352\351\377\210\350\354\340\377\2\351\354\343\377" \
"glm\377\205.46\377\1\253\256\257\377\225\350\354\340\377\1SXY\377\204" \
".46\377\224\350\354\340\377\1GLN\377\203.46\377\1:@B\377\234\350\354" \
"\340\377\2\332\333\334\37728:\377\204.46\377\2[`a\377\347\350\350\377" \
"\213\350\354\340\377\2\237\242\243\377\264\266\266\377\231\350\354\340" \
"\377\204.46\377\1SXY\377\377\350\354\340\377\312\350\354\340\377\1\235" \
"\237\240\377\204.46\377\1\265\267\270\377\206\350\354\340\377\205.46" \
"\377\1\330\331\331\377\222\350\354\340\377\1kpq\377\204.46\377\1\346" \
"\347\347\377\205\350\354\340\377\1\310\312\312\377\204.46\377\1quw\377" \
"\223\350\354\340\377\1BGI\377\204.46\377\1gkl\377\214\350\354\340\377" \
"\1txy\377\204.46\377\1AFH\377\225\350\354\340\377\1SXY\377\204.46\377" \
"\224\350\354\340\377\1GLN\377\203.46\377\1:@B\377\234\350\354\340\377" \
"\1jnp\377\204.46\377\1UZ\\\377\250\350\354\340\377\204.46\377\1SXY\377" \
"\377\350\354\340\377\312\350\354\340\377\1\235\237\240\377\204.46\377" \
"\1\265\267\270\377\205\350\354\340\377\1\352\354\345\377\205.46\377\1" \
"\340\341\341\377\222\350\354\340\377\1kpq\377\204.46\377\1\346\347\347" \
"\377\205\350\354\340\377\1\271\273\273\377\204.46\377\1\201\204\206\377" \
"\222\350\354\340\377\1\234\237\240\377\204.46\377\1CIJ\377\216\350\354" \
"\340\377\1PUV\377\204.46\377\1\233\236\237\377\224\350\354\340\377\1" \
"SXY\377\204.46\377\224\350\354\340\377\1GLN\377\203.46\377\1:@B\377\233" \
"\350\354\340\377\1\341\342\342\377\204.46\377\2""179\377\335\336\337" \
"\377\250\350\354\340\377\204.46\377\1SXY\377\377\350\354\340\377\312" \
"\350\354\340\377\1\235\237\240\377\204.46\377\1\265\267\270\377\205\350" \
"\354\340\377\1\222\225\226\377\204.46\377\1""068\377\223\350\354\340" \
"\377\1kpq\377\204.46\377\1\346\347\347\377\205\350\354\340\377\1bfh\377" \
"\204.46\377\1\235\237\240\377\222\350\354\340\377\1V[]\377\204.46\377" \
"\1\253\256\257\377\216\350\354\340\377\1\273\275\276\377\204.46\377\1" \
"TYZ\377\224\350\354\340\377\1SXY\377\204.46\377\224\350\354\340\377\1" \
"GLN\377\203.46\377\1:@B\377\233\350\354\340\377\1\231\233\234\377\204" \
".46\377\1y}\177\377\251\350\354\340\377\204.46\377\1SXY\377\377\350\354" \
"\340\377\312\350\354\340\377\1\235\237\240\377\204.46\377\1\265\267\270" \
"\377\203\350\354\340\377\3\345\346\346\377\206\211\212\377/57\377\204" \
".46\377\1[`a\377\223\350\354\340\377\1kpq\377\204.46\377\1\346\347\347" \
"\377\203\350\354\340\377\2\323\324\324\377fjl\377\204.46\377\2/57\377" \
"\336\337\337\377\221\350\354\340\377\1\345\346\346\377\204.46\377\1""9" \
"\77A\377\220\350\354\340\377\1BHJ\377\204.46\377\1\341\342\342\377\223" \
"\350\354\340\377\1SXY\377\204.46\377\224\350\354\340\377\1GLN\377\203" \
".46\377\1:@B\377\233\350\354\340\377\1gkl\377\204.46\377\1\300\302\302" \
"\377\251\350\354\340\377\204.46\377\1SXY\377\377\350\354\340\377\312" \
"\350\354\340\377\1\235\237\240\377\204.46\377\1""7=\77\377\203<BC\377" \
"\1/57\377\206.46\377\1\257\262\263\377\223\350\354\340\377\1kpq\377\204" \
".46\377\1:@B\377\202<BC\377\1""9>@\377\206.46\377\1\200\204\205\377\222" \
"\350\354\340\377\1\302\303\304\377\204.46\377\1rvw\377\220\350\354\340" \
"\377\1~\202\203\377\204.46\377\1\274\276\276\377\223\350\354\340\377" \
"\1SXY\377\204.46\377\224\350\354\340\377\1GLN\377\203.46\377\1""179\377" \
"\211fjl\377\1\311\312\313\377\221\350\354\340\377\1@FG\377\204.46\377" \
"\1\352\354\345\377\251\350\354\340\377\204.46\377\1SXY\377\377\350\354" \
"\340\377\312\350\354\340\377\1\235\237\240\377\216.46\377\1eik\377\224" \
"\350\354\340\377\1kpq\377\215.46\377\1ptv\377\223\350\354\340\377\1\256" \
"\260\261\377\204.46\377\1\217\222\223\377\220\350\354\340\377\1\235\237" \
"\240\377\204.46\377\1\246\250\251\377\223\350\354\340\377\1SXY\377\204" \
".46\377\224\350\354\340\377\1GLN\377\215.46\377\1\265\267\270\377\221" \
"\350\354\340\377\1""179\377\203.46\377\1""39;\377\252\350\354\340\377" \
"\204.46\377\1SXY\377\377\350\354\340\377\312\350\354\340\377\1\235\237" \
"\240\377\215.46\377\1ptu\377\225\350\354\340\377\1kpq\377\213.46\377" \
"\2:@B\377\255\257\260\377\224\350\354\340\377\1\236\241\242\377\204." \
"46\377\1\235\237\240\377\220\350\354\340\377\1\251\253\254\377\204.4" \
"6\377\1\231\233\234\377\223\350\354\340\377\1SXY\377\204.46\377\224\350" \
"\354\340\377\1GLN\377\215.46\377\1\265\267\270\377\221\350\354\340\377" \
"\204.46\377\1:@B\377\252\350\354\340\377\204.46\377\1SXY\377\377\350" \
"\354\340\377\312\350\354\340\377\1\235\237\240\377\212.46\377\3""8>\77" \
"\377ost\377\310\312\312\377\226\350\354\340\377\1kpq\377\213.46\377\2" \
"7=\77\377\352\354\350\377\224\350\354\340\377\1\257\262\263\377\204." \
"46\377\1\214\220\221\377\220\350\354\340\377\1\231\234\235\377\204.4" \
"6\377\1\251\253\254\377\223\350\354\340\377\1SXY\377\204.46\377\224\350" \
"\354\340\377\1GLN\377\215.46\377\1\265\267\270\377\221\350\354\340\377" \
"\1""5;=\377\203.46\377\1""068\377\252\350\354\340\377\204.46\377\1SX" \
"Y\377\377\350\354\340\377\312\350\354\340\377\1\235\237\240\377\204." \
"46\377\1x|}\377\202\253\256\257\377\3\254\257\257\377\300\302\302\377" \
"\326\327\330\377\231\350\354\340\377\1kpq\377\204.46\377\1\302\303\304" \
"\377\202\325\326\327\377\1\204\210\211\377\204.46\377\1\202\206\207\377" \
"\224\350\354\340\377\1\304\306\306\377\204.46\377\1kpq\377\220\350\354" \
"\340\377\1z~\177\377\204.46\377\1\275\277\277\377\223\350\354\340\377" \
"\1SXY\377\204.46\377\224\350\354\340\377\1GLN\377\203.46\377\1""6<>\377" \
"\211\271\273\274\377\1\346\347\347\377\221\350\354\340\377\1INP\377\204" \
".46\377\1\331\332\333\377\251\350\354\340\377\204.46\377\1SXY\377\377" \
"\350\354\340\377\312\350\354\340\377\1\235\237\240\377\204.46\377\1\251" \
"\253\254\377\236\350\354\340\377\1kpq\377\204.46\377\1\346\347\347\377" \
"\202\350\354\340\377\2\350\354\342\3779\77A\377\203.46\377\2""179\377" \
"\336\337\337\377\223\350\354\340\377\2\351\352\350\377068\377\203.46" \
"\377\1""5;=\377\220\350\354\340\377\1=BD\377\203.46\377\2/57\377\347" \
"\350\350\377\223\350\354\340\377\1SXY\377\204.46\377\224\350\354\340" \
"\377\1GLN\377\203.46\377\1:@B\377\233\350\354\340\377\1swx\377\204.4" \
"6\377\1\235\240\241\377\251\350\354\340\377\204.46\377\1SXY\377\377\350" \
"\354\340\377\312\350\354\340\377\1\235\237\240\377\204.46\377\1\251\253" \
"\254\377\236\350\354\340\377\1kpq\377\204.46\377\1\346\347\347\377\203" \
"\350\354\340\377\1\224\230\231\377\204.46\377\1ptu\377\224\350\354\340" \
"\377\1\\ab\377\204.46\377\1\242\244\245\377\216\350\354\340\377\1\260" \
"\263\263\377\204.46\377\1Y^`\377\224\350\354\340\377\1SXY\377\204.46" \
"\377\224\350\354\340\377\1GLN\377\203.46\377\1:@B\377\233\350\354\340" \
"\377\1\250\253\253\377\204.46\377\1HMO\377\251\350\354\340\377\204.4" \
"6\377\1SXY\377\377\350\354\340\377\312\350\354\340\377\1\235\237\240" \
"\377\204.46\377\1\251\253\254\377\236\350\354\340\377\1kpq\377\204.4" \
"6\377\1\346\347\347\377\204\350\354\340\377\1<BC\377\204.46\377\1\317" \
"\320\320\377\223\350\354\340\377\1\245\247\250\377\204.46\377\2<BC\377" \
"\346\347\347\377\214\350\354\340\377\2\351\354\343\377FKM\377\204.46" \
"\377\1\243\246\247\377\224\350\354\340\377\1SXY\377\204.46\377\224\350" \
"\354\340\377\1GLN\377\203.46\377\1:@B\377\234\350\354\340\377\1""5:<" \
"\377\204.46\377\1\230\233\234\377\250\350\354\340\377\204.46\377\1SX" \
"Y\377\377\350\354\340\377\312\350\354\340\377\1\235\237\240\377\204." \
"46\377\1\251\253\254\377\236\350\354\340\377\1kpq\377\204.46\377\1\346" \
"\347\347\377\204\350\354\340\377\1\233\236\237\377\204.46\377\1^bd\377" \
"\224\350\354\340\377\1INP\377\204.46\377\1W\\]\377\214\350\354\340\377" \
"\1chi\377\204.46\377\1HMO\377\225\350\354\340\377\1SXY\377\204.46\377" \
"\224\350\354\340\377\1GLN\377\203.46\377\1:@B\377\234\350\354\340\377" \
"\1\205\210\212\377\204.46\377\2""068\377\267\271\272\377\215\350\354" \
"\340\377\1\330\332\332\377\231\350\354\340\377\204.46\377\1SXY\377\377" \
"\350\354\340\377\312\350\354\340\377\1\235\237\240\377\204.46\377\1\251" \
"\253\254\377\236\350\354\340\377\1kpq\377\204.46\377\1\346\347\347\377" \
"\205\350\354\340\377\1@FG\377\204.46\377\1\274\276\276\377\223\350\354" \
"\340\377\1\274\276\276\377\205.46\377\2MRT\377\327\330\330\377\210\350" \
"\354\340\377\2\335\336\336\377UY[\377\205.46\377\1\272\274\275\377\225" \
"\350\354\340\377\1=BD\377\203.46\377\1""6<>\377\224\350\354\340\377\1" \
"GLN\377\203.46\377\1:@B\377\235\350\354\340\377\1AFH\377\204.46\377\2" \
"/57\377\217\222\223\377\212\350\354\340\377\4\274\276\276\377bgh\377" \
".46\377\327\330\330\377\230\350\354\340\377\204.46\377\1SXY\377\377\350" \
"\354\340\377\312\350\354\340\377\1\235\237\240\377\204.46\377\1\251\253" \
"\254\377\236\350\354\340\377\1kpq\377\204.46\377\1\346\347\347\377\205" \
"\350\354\340\377\1\240\243\244\377\204.46\377\1MRT\377\224\350\354\340" \
"\377\1\220\224\225\377\205.46\377\3""068\377y}\177\377\302\304\305\377" \
"\204\350\354\340\377\3\306\307\310\377\200\204\205\377179\377\205.46" \
"\377\1\220\223\224\377\223\350\354\340\377\3\306\307\310\377\257\261" \
"\262\377hmn\377\204.46\377\1_de\377\224\350\354\340\377\1GLN\377\203" \
".46\377\1""9>@\377\213\343\344\344\377\222\350\354\340\377\2\313\315" \
"\315\37739;\377\205.46\377\12@FG\377\212\215\216\377\302\303\304\377" \
"\341\342\342\377\350\354\340\377\347\350\350\377\320\322\322\377\253" \
"\256\257\377w{|\377=BD\377\203.46\377\1\212\215\216\377\230\350\354\340" \
"\377\204.46\377\1SXY\377\377\350\354\340\377\312\350\354\340\377\1\235" \
"\237\240\377\204.46\377\1\264\266\266\377\236\350\354\340\377\1kpq\377" \
"\204.46\377\1\346\347\347\377\206\350\354\340\377\1BHJ\377\204.46\377" \
"\1\251\253\254\377\224\350\354\340\377\1txz\377\210.46\377\2""7=\77\377" \
"8>\77\377\210.46\377\1txz\377\224\350\354\340\377\1SXY\377\206.46\377" \
"\1\251\253\254\377\224\350\354\340\377\1GLN\377\217.46\377\1\320\322" \
"\322\377\222\350\354\340\377\2\276\300\301\3775;=\377\221.46\377\1@F" \
"G\377\230\350\354\340\377\204.46\377\1SXY\377\377\350\354\340\377\312" \
"\350\354\340\377\1\235\237\240\377\204.46\377\1\265\267\270\377\236\350" \
"\354\340\377\1kpq\377\204.46\377\1\346\347\347\377\206\350\354\340\377" \
"\1\246\251\252\377\204.46\377\1AFH\377\225\350\354\340\377\2\232\235" \
"\236\377068\377\216.46\377\2""068\377\232\235\236\377\225\350\354\340" \
"\377\1X]^\377\205.46\377\1LQS\377\225\350\354\340\377\1GLN\377\217.4" \
"6\377\1\316\317\320\377\223\350\354\340\377\2\324\325\325\377NSU\377" \
"\220.46\377\2""068\377\321\322\323\377\227\350\354\340\377\204.46\377" \
"\1SXY\377\377\350\354\340\377\312\350\354\340\377\1\235\237\240\377\204" \
".46\377\1\265\267\270\377\236\350\354\340\377\1kpq\377\204.46\377\1\346" \
"\347\347\377\207\350\354\340\377\1GLN\377\204.46\377\1\226\231\232\377" \
"\225\350\354\340\377\2\317\320\320\377`ef\377\214.46\377\2bgh\377\317" \
"\321\321\377\226\350\354\340\377\1_de\377\204.46\377\2:@B\377\332\333" \
"\334\377\225\350\354\340\377\1GLN\377\217.46\377\1\316\317\320\377\225" \
"\350\354\340\377\2\236\241\242\377BGI\377\214.46\377\3""8>\77\377~\201" \
"\202\377\335\336\337\377\230\350\354\340\377\204.46\377\1SXY\377\377" \
"\350\354\340\377\312\350\354\340\377\1\235\237\240\377\204.46\377\1\265" \
"\267\270\377\236\350\354\340\377\1kpq\377\204.46\377\1\346\347\347\377" \
"\207\350\354\340\377\1\254\257\257\377\204.46\377\2""8>\77\377\352\354" \
"\350\377\226\350\354\340\377\3\311\312\313\377\200\204\205\377EJL\377" \
"\206.46\377\3EJL\377\203\207\210\377\313\314\315\377\230\350\354\340" \
"\377\1_de\377\202.46\377\3/57\377fjl\377\342\343\343\377\226\350\354" \
"\340\377\1SXY\377\217<BC\377\1\307\311\311\377\227\350\354\340\377\4" \
"\275\277\300\377~\201\202\377OTV\377068\377\204.46\377\4""39;\377QVX" \
"\377\201\204\206\377\270\272\272\377\233\350\354\340\377\204.46\377\1" \
"SXY\377\377\350\354\340\377\377\350\354\340\377\234\350\354\340\377\2" \
"\345\346\346\377\317\321\321\377\202\275\277\300\377\2\317\321\321\377" \
"\345\346\346\377\233\350\354\340\377\4\302\304\305\377\255\257\260\377" \
"\301\302\303\377\346\346\347\377\304\350\354\340\377\4\346\347\347\377" \
"\327\330\330\377\335\336\337\377\347\350\350\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354" \
"\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377" \
"\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350" \
"\354\340\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340" \
"\377\377\350\354\340\377\377\350\354\340\377\377\350\354\340\377\377" \
"\350\354\340\377\377\350\354\340\377\246\350\354\340\377")

View File

@@ -0,0 +1,4 @@
FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
PRINC = "1"

View File

@@ -4,13 +4,13 @@ FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"
COMPATIBLE_MACHINE_atom-pc = "atom-pc"
KMACHINE_atom-pc = "atom-pc"
KBRANCH_atom-pc = "yocto/standard/preempt-rt/base"
SRCREV_machine_pn-linux-yocto-rt_atom-pc = "0b805cce57f61a244eb3b8fce460b14f1be442b3"
SRCREV_machine_pn-linux-yocto-rt_atom-pc = "2f9d925f5681eaae7f341cc1270c739e8b329c03"
# mpc8315e-rdb support
COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
KMACHINE_mpc8315e-rdb = "fsl-mpc8315e-rdb"
KBRANCH_mpc8315e-rdb = "yocto/standard/preempt-rt/base"
SRCREV_machine_pn-linux-yocto-rt_mpc8315e-rdb = "0b805cce57f61a244eb3b8fce460b14f1be442b3"
SRCREV_machine_pn-linux-yocto-rt_mpc8315e-rdb = "2f9d925f5681eaae7f341cc1270c739e8b329c03"
# beagleboard support - 3.0 support has not yet been completed, build failure
#COMPATIBLE_MACHINE_beagleboard = "beagleboard"
@@ -22,4 +22,4 @@ SRCREV_machine_pn-linux-yocto-rt_mpc8315e-rdb = "0b805cce57f61a244eb3b8fce460b14
COMPATIBLE_MACHINE_routerstationpro = "routerstationpro"
KMACHINE_routerstationpro = "routerstationpro"
KBRANCH_routerstationpro = "yocto/standard/preempt-rt/routerstationpro"
SRCREV_machine_pn-linux-yocto-rt_routerstationpro = "43dcdffebb64d9ce2f5cdcb18bb74bd9c301133f"
SRCREV_machine_pn-linux-yocto-rt_routerstationpro = "ac9de3df165099542c26a5c0a60cac4fb9965cb2"

View File

@@ -4,10 +4,10 @@ KMACHINE_mpc8315e-rdb = "yocto/standard/fsl-mpc8315e-rdb"
KMACHINE_beagleboard = "yocto/standard/beagleboard"
SRCREV_machine_atom-pc ?= "1e18e44adbe79b846e382370eb29bc4b8cd5a1a0"
SRCREV_machine_routerstationpro ?= "8f38705810634a84326d3a3ebe9653951aa4bf61"
SRCREV_machine_mpc8315e-rdb ?= "58ffdb8000e34d2ba7c3ef278b26680b0886e8b5"
SRCREV_machine_beagleboard ?= "6b4bf6173b0bd2d1619a8218bac66ebc4681dd35"
SRCREV_machine_atom-pc ?= "9a49e496c5e01bf4265e6adcd98f9ab177041ed1"
SRCREV_machine_routerstationpro ?= "3bce4d3144c0501efedb6de61599d81acc0946d6"
SRCREV_machine_mpc8315e-rdb ?= "6ee43f85afcd4499b441ff8aa0a54a0706eabf00"
SRCREV_machine_beagleboard ?= "368e38c673ffac8b37fc2a2d4c1e4a1e6f8abf19"
COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
COMPATIBLE_MACHINE_routerstationpro = "routerstationpro"

View File

@@ -0,0 +1,19 @@
KMACHINE_atom-pc = "atom-pc"
KMACHINE_routerstationpro = "routerstationpro"
KMACHINE_mpc8315e-rdb = "fsl-mpc8315e-rdb"
KMACHINE_beagleboard = "beagleboard"
KBRANCH_atom-pc = "standard/default/common-pc/atom-pc"
KBRANCH_routerstationpro = "standard/default/routerstationpro"
KBRANCH_mpc8315e-rdb = "standard/default/fsl-mpc8315e-rdb"
KBRANCH_beagleboard = "standard/default/beagleboard"
SRCREV_machine_atom-pc ?= "417fc778a86e81303bab5883b919ee422ec51c04"
SRCREV_machine_routerstationpro ?= "e015d29f374cd986e15f636b6b84b514d95d76ed"
SRCREV_machine_mpc8315e-rdb ?= "2349967f408cc60db2b1c89fcefffc81428f9341"
SRCREV_machine_beagleboard ?= "417fc778a86e81303bab5883b919ee422ec51c04"
COMPATIBLE_MACHINE_mpc8315e-rdb = "mpc8315e-rdb"
COMPATIBLE_MACHINE_routerstationpro = "routerstationpro"
COMPATIBLE_MACHINE_beagleboard = "beagleboard"
COMPATIBLE_MACHINE_atom-pc = "atom-pc"

View File

@@ -102,6 +102,8 @@ autotools_do_configure() {
if [ -e ${S}/configure.in -o -e ${S}/configure.ac ]; then
olddir=`pwd`
cd ${S}
# Remove any previous copy of the m4 macros
rm -rf ${B}/aclocal-copy/
if [ x"${acpaths}" = xdefault ]; then
acpaths=
for i in `find ${S} -maxdepth 2 -name \*.m4|grep -v 'aclocal.m4'| \
@@ -149,7 +151,7 @@ autotools_do_configure() {
else if grep "^[[:space:]]*AM_GNU_GETTEXT" $CONFIGURE_AC >/dev/null; then
# We'd call gettextize here if it wasn't so broken...
cp ${STAGING_DATADIR}/gettext/config.rpath ${AUTOTOOLS_AUXDIR}/
if [ ! -e ${S}/po/Makefile.in.in ]; then
if [ -d ${S}/po/ -a ! -e ${S}/po/Makefile.in.in ]; then
cp ${STAGING_DATADIR}/gettext/po/Makefile.in.in ${S}/po/
fi
fi

View File

@@ -9,7 +9,7 @@ inherit utility-tasks
inherit metadata_scm
inherit logging
OE_IMPORTS += "os sys time oe.path oe.utils oe.data oe.packagegroup"
OE_IMPORTS += "os sys time oe.path oe.utils oe.data oe.packagegroup oe.sstatesig"
OE_IMPORTS[type] = "list"
def oe_import(d):
@@ -349,12 +349,12 @@ python () {
if license == "INVALID":
bb.fatal('This recipe does not have the LICENSE field set (%s)' % pn)
commercial_license = " %s " % d.getVar('COMMERCIAL_LICENSE', 1)
import re
pnr = "[ \t]%s[ \t]" % pn.replace('+', "\+")
if commercial_license and re.search(pnr, commercial_license):
bb.debug(1, "Skipping %s because it's commercially licensed" % pn)
raise bb.parse.SkipPackage("because it may require a commercial license to ship in a product (listed in COMMERCIAL_LICENSE)")
unmatched_license_flag = check_license_flags(d)
if unmatched_license_flag:
bb.debug(1, "Skipping %s because it has a restricted license not"
" whitelisted in LICENSE_FLAGS_WHITELIST" % pn)
raise bb.parse.SkipPackage("because it has a restricted license not"
" whitelisted in LICENSE_FLAGS_WHITELIST")
# If we're building a target package we need to use fakeroot (pseudo)
# in order to capture permissions, owners, groups and special files
@@ -379,7 +379,7 @@ python () {
import re
this_host = d.getVar('HOST_SYS', 1)
if not re.match(need_host, this_host):
raise bb.parse.SkipPackage("incompatible with host %s" % this_host)
raise bb.parse.SkipPackage("incompatible with host %s (not in COMPATIBLE_HOST)" % this_host)
need_machine = d.getVar('COMPATIBLE_MACHINE', 1)
if need_machine:
@@ -388,7 +388,7 @@ python () {
if this_machine and not re.match(need_machine, this_machine):
this_soc_family = d.getVar('SOC_FAMILY', 1)
if (this_soc_family and not re.match(need_machine, this_soc_family)) or not this_soc_family:
raise bb.parse.SkipPackage("incompatible with machine %s" % this_machine)
raise bb.parse.SkipPackage("incompatible with machine %s (not in COMPATIBLE_MACHINE)" % this_machine)
dont_want_license = d.getVar('INCOMPATIBLE_LICENSE', 1)
@@ -453,13 +453,15 @@ python () {
# We always try to scan SRC_URI for urls with machine overrides
# unless the package sets SRC_URI_OVERRIDES_PACKAGE_ARCH=0
#
override = d.getVar('SRC_URI_OVERRIDES_PACKAGE_ARCH', 1)
override = d.getVar('SRC_URI_OVERRIDES_PACKAGE_ARCH', True)
if override != '0':
paths = []
for p in [ "${PF}", "${P}", "${PN}", "files", "" ]:
path = bb.data.expand(os.path.join("${FILE_DIRNAME}", p, "${MACHINE}"), d)
if os.path.isdir(path):
paths.append(path)
fpaths = (d.getVar('FILESPATH', True) or '').split(':')
machine = d.getVar('MACHINE', True)
for p in fpaths:
if os.path.basename(p) == machine and os.path.isdir(p):
paths.append(p)
if len(paths) != 0:
for s in srcuri.split():
if not s.startswith("file://"):
@@ -468,7 +470,7 @@ python () {
local = fetcher.localpath(s)
for mp in paths:
if local.startswith(mp):
#bb.note("overriding PACKAGE_ARCH from %s to %s" % (pkg_arch, mach_arch))
#bb.note("overriding PACKAGE_ARCH from %s to %s for %s" % (pkg_arch, mach_arch, pn))
d.setVar('PACKAGE_ARCH', "${MACHINE_ARCH}")
return

View File

@@ -38,8 +38,9 @@ BOOTDD_EXTRA_SPACE ?= "16384"
AUTO_SYSLINUXCFG = "1"
LABELS = "boot"
APPEND = "root=/dev/sda2"
TIMEOUT = "10"
SYSLINUX_ROOT ?= "root=/dev/sda2"
SYSLINUX_TIMEOUT = "10" # 1 second
SYSLINUXCFG = "${HDDDIR}/syslinux.cfg"
SYSLINUXMENU = "${HDDDIR}/menu"
@@ -50,6 +51,7 @@ build_boot_dd() {
install -d ${HDDDIR}
install -m 0644 ${STAGING_DIR_HOST}/kernel/bzImage ${HDDDIR}/vmlinuz
install -m 0644 ${S}/syslinux.cfg ${HDDDIR}/syslinux.cfg
install -m 444 ${STAGING_LIBDIR}/syslinux/ldlinux.sys ${HDDDIR}/ldlinux.sys
BLOCKS=`du -bks ${HDDDIR} | cut -f 1`

View File

@@ -8,13 +8,13 @@
# End result is two things:
#
# 1. A .hddimg file which is an msdos filesystem containing syslinux, a kernel,
# an initrd and a rootfs image. These can be written to harddisks directly and
# an initrd and a rootfs image. These can be written to harddisks directly and
# also booted on USB flash disks (write them there with dd).
#
# 2. A CD .iso image
# Boot process is that the initrd will boot and process which label was selected
# in syslinux. Actions based on the label are then performed (e.g. installing to
# Boot process is that the initrd will boot and process which label was selected
# in syslinux. Actions based on the label are then performed (e.g. installing to
# an hdd)
# External variables (also used by syslinux.bbclass)
@@ -29,14 +29,14 @@ do_bootimg[depends] += "dosfstools-native:do_populate_sysroot \
PACKAGES = " "
EXCLUDE_FROM_WORLD = "1"
HDDDIR = "${S}/hdd/boot"
ISODIR = "${S}/cd"
HDDDIR = "${S}/hddimg"
ISODIR = "${S}/iso"
BOOTIMG_VOLUME_ID ?= "boot"
BOOTIMG_EXTRA_SPACE ?= "512"
EFI = ${@base_contains("MACHINE_FEATURES", "efi", "1", "0", d)}
EFI_CLASS = ${@base_contains("MACHINE_FEATURES", "efi", "grub-efi", "dummy", d)}
EFI = "${@base_contains("MACHINE_FEATURES", "efi", "1", "0", d)}"
EFI_CLASS = "${@base_contains("MACHINE_FEATURES", "efi", "grub-efi", "dummy", d)}"
# Include legacy boot if MACHINE_FEATURES includes "pcbios" or if it does not
# contain "efi". This way legacy is supported by default if neither is
@@ -52,12 +52,28 @@ def pcbios_class(d):
return "syslinux"
return "dummy"
PCBIOS = ${@pcbios(d)}
PCBIOS_CLASS = ${@pcbios_class(d)}
PCBIOS = "${@pcbios(d)}"
PCBIOS_CLASS = "${@pcbios_class(d)}"
inherit ${PCBIOS_CLASS}
inherit ${EFI_CLASS}
populate() {
DEST=$1
install -d ${DEST}
# Install bzImage, initrd, and rootfs.img in DEST for all loaders to use.
install -m 0644 ${STAGING_DIR_HOST}/kernel/bzImage ${DEST}/vmlinuz
if [ -n "${INITRD}" ] && [ -s "${INITRD}" ]; then
install -m 0644 ${INITRD} ${DEST}/initrd
fi
if [ -n "${ROOTFS}" ] && [ -s "${ROOTFS}" ]; then
install -m 0644 ${ROOTFS} ${DEST}/rootfs.img
fi
}
build_iso() {
# Only create an ISO if we have an INITRD and NOISO was not set
@@ -66,7 +82,7 @@ build_iso() {
return
fi
install -d ${ISODIR}
populate ${ISODIR}
if [ "${PCBIOS}" = "1" ]; then
syslinux_iso_populate
@@ -95,7 +111,8 @@ build_iso() {
build_hddimg() {
# Create an HDD image
if [ "${NOHDD}" != "1" ] ; then
install -d ${HDDDIR}
populate ${HDDDIR}
if [ "${PCBIOS}" = "1" ]; then
syslinux_hddimg_populate
fi
@@ -103,19 +120,49 @@ build_hddimg() {
grubefi_hddimg_populate
fi
# Determine the 1024 byte block count for the final image.
BLOCKS=`du --apparent-size -ks ${HDDDIR} | cut -f 1`
SIZE=`expr $BLOCKS + ${BOOTIMG_EXTRA_SPACE}`
# Calculate the size required for the final image including the
# data and filesystem overhead.
# Sectors: 512 bytes
# Blocks: 1024 bytes
# Determine the sector count just for the data
SECTORS=$(expr $(du --apparent-size -ks ${HDDDIR} | cut -f 1) \* 2)
# Account for the filesystem overhead. This includes directory
# entries in the clusters as well as the FAT itself.
# Assumptions:
# FAT32 (12 or 16 may be selected by mkdosfs, but the extra
# padding will be minimal on those smaller images and not
# worth the logic here to caclulate the smaller FAT sizes)
# < 16 entries per directory
# 8.3 filenames only
# 32 bytes per dir entry
DIR_BYTES=$(expr $(find ${HDDDIR} | tail -n +2 | wc -l) \* 32)
# 32 bytes for every end-of-directory dir entry
DIR_BYTES=$(expr $DIR_BYTES + $(expr $(find ${HDDDIR} -type d | tail -n +2 | wc -l) \* 32))
# 4 bytes per FAT entry per sector of data
FAT_BYTES=$(expr $SECTORS \* 4)
# 4 bytes per FAT entry per end-of-cluster list
FAT_BYTES=$(expr $FAT_BYTES + $(expr $(find ${HDDDIR} -type d | tail -n +2 | wc -l) \* 4))
# Use a ceiling function to determine FS overhead in sectors
DIR_SECTORS=$(expr $(expr $DIR_BYTES + 511) / 512)
# There are two FATs on the image
FAT_SECTORS=$(expr $(expr $(expr $FAT_BYTES + 511) / 512) \* 2)
SECTORS=$(expr $SECTORS + $(expr $DIR_SECTORS + $FAT_SECTORS))
# Determine the final size in blocks accounting for some padding
BLOCKS=$(expr $(expr $SECTORS / 2) + ${BOOTIMG_EXTRA_SPACE})
# Ensure total sectors is an integral number of sectors per
# track or mcopy will complain. Sectors are 512 bytes, and and
# we generate images with 32 sectors per track. This calculation
# is done in blocks, which are twice the size of sectors, thus
# the 16 instead of 32.
SIZE=$(expr $SIZE + $(expr 16 - $(expr $SIZE % 16)))
# track or mcopy will complain. Sectors are 512 bytes, and we
# generate images with 32 sectors per track. This calculation is
# done in blocks, thus the mod by 16 instead of 32.
BLOCKS=$(expr $BLOCKS + $(expr 16 - $(expr $BLOCKS % 16)))
IMG=${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.hddimg
mkdosfs -n ${BOOTIMG_VOLUME_ID} -S 512 -C ${IMG} ${SIZE}
mkdosfs -n ${BOOTIMG_VOLUME_ID} -S 512 -C ${IMG} ${BLOCKS}
# Copy HDDDIR recursively into the image file directly
mcopy -i ${IMG} -s ${HDDDIR}/* ::/

View File

@@ -123,8 +123,16 @@ python buildhistory_emit_pkghistory() {
except EnvironmentError:
return None
def squashspaces(string):
return re.sub("\s+", " ", string)
def sortpkglist(string):
pkgiter = re.finditer(r'[a-zA-Z0-9.+-]+( \([><=]+ [^ )]+\))?', string, 0)
pkglist = [p.group(0) for p in pkgiter]
pkglist.sort()
return ' '.join(pkglist)
def sortlist(string):
items = string.split(' ')
items.sort()
return ' '.join(items)
pn = d.getVar('PN', True)
pe = d.getVar('PE', True) or "0"
@@ -136,7 +144,7 @@ python buildhistory_emit_pkghistory() {
rcpinfo.pe = pe
rcpinfo.pv = pv
rcpinfo.pr = pr
rcpinfo.depends = squashspaces(d.getVar('DEPENDS', True) or "")
rcpinfo.depends = sortlist(squashspaces(d.getVar('DEPENDS', True) or ""))
rcpinfo.packages = packages
write_recipehistory(rcpinfo, d)
write_latestlink(None, pe, pv, pr, d)
@@ -164,8 +172,8 @@ python buildhistory_emit_pkghistory() {
pkginfo.pe = pe
pkginfo.pv = pv
pkginfo.pr = pr
pkginfo.rdepends = squashspaces(getpkgvar(pkg, 'RDEPENDS') or "")
pkginfo.rrecommends = squashspaces(getpkgvar(pkg, 'RRECOMMENDS') or "")
pkginfo.rdepends = sortpkglist(squashspaces(getpkgvar(pkg, 'RDEPENDS') or ""))
pkginfo.rrecommends = sortpkglist(squashspaces(getpkgvar(pkg, 'RRECOMMENDS') or ""))
pkginfo.files = squashspaces(getpkgvar(pkg, 'FILES') or "")
# Gather information about packaged files
@@ -178,6 +186,7 @@ python buildhistory_emit_pkghistory() {
fstat = os.lstat(os.path.join(root, f))
pkginfo.size += fstat.st_size
filelist.append(os.sep + os.path.join(relpth, f))
filelist.sort()
pkginfo.filelist = " ".join(filelist)
write_pkghistory(pkginfo, d)
@@ -278,12 +287,12 @@ buildhistory_get_image_installed() {
echo $pkgsize $pkg >> ${BUILDHISTORY_DIR_IMAGE}/installed-package-sizes.tmp
fi
deps=`list_package_depends $pkg`
deps=`list_package_depends $pkg | sort | uniq`
for dep in $deps ; do
echo "$pkg OPP $dep;" | sed -e 's:-:_:g' -e 's:\.:_:g' -e 's:+::g' | sed 's:OPP:->:g' >> ${BUILDHISTORY_DIR_IMAGE}/depends.dot
done
recs=`list_package_recommends $pkg`
recs=`list_package_recommends $pkg | sort | uniq`
for rec in $recs ; do
echo "$pkg OPP $rec [style=dotted];" | sed -e 's:-:_:g' -e 's:\.:_:g' -e 's:+::g' | sed 's:OPP:->:g' >> ${BUILDHISTORY_DIR_IMAGE}/depends.dot
done
@@ -310,7 +319,15 @@ buildhistory_get_image_installed() {
buildhistory_get_imageinfo() {
# List the files in the image, but exclude date/time etc.
# This awk script is somewhat messy, but handles where the size is not printed for device files under pseudo
( cd ${IMAGE_ROOTFS} && find . -ls | awk '{ if ( $7 ~ /[0-9]/ ) printf "%s %10-s %10-s %10s %s %s %s\n", $3, $5, $6, $7, $11, $12, $13 ; else printf "%s %10-s %10-s %10s %s %s %s\n", $3, $5, $6, 0, $10, $11, $12 }' > ${BUILDHISTORY_DIR_IMAGE}/files-in-image.txt )
( cd ${IMAGE_ROOTFS} && find . -ls | awk '{ if ( $7 ~ /[0-9]/ ) printf "%s %10-s %10-s %10s %s %s %s\n", $3, $5, $6, $7, $11, $12, $13 ; else printf "%s %10-s %10-s %10s %s %s %s\n", $3, $5, $6, 0, $10, $11, $12 }' | sort -k5 > ${BUILDHISTORY_DIR_IMAGE}/files-in-image.txt )
# Record some machine-readable meta-information about the image
echo -n > ${BUILDHISTORY_DIR_IMAGE}/image-info.txt
cat >> ${BUILDHISTORY_DIR_IMAGE}/image-info.txt <<END
${@buildhistory_get_imagevars(d)}
END
imagesize=`du -ks ${IMAGE_ROOTFS} | awk '{ print $1 }'`
echo "IMAGESIZE = $imagesize" >> ${BUILDHISTORY_DIR_IMAGE}/image-info.txt
# Add some configuration information
echo "${MACHINE}: ${IMAGE_BASENAME} configured for ${DISTRO} ${DISTRO_VERSION}" > ${BUILDHISTORY_DIR_IMAGE}/build-id
@@ -330,6 +347,27 @@ def buildhistory_get_layers(d):
return layertext
def squashspaces(string):
import re
return re.sub("\s+", " ", string).strip()
def buildhistory_get_imagevars(d):
imagevars = "DISTRO DISTRO_VERSION USER_CLASSES IMAGE_CLASSES IMAGE_FEATURES IMAGE_LINGUAS IMAGE_INSTALL BAD_RECOMMENDATIONS ROOTFS_POSTPROCESS_COMMAND IMAGE_POSTPROCESS_COMMAND"
listvars = "USER_CLASSES IMAGE_CLASSES IMAGE_FEATURES IMAGE_LINGUAS IMAGE_INSTALL BAD_RECOMMENDATIONS"
imagevars = imagevars.split()
listvars = listvars.split()
ret = ""
for var in imagevars:
value = d.getVar(var, True) or ""
if var in listvars:
# Squash out spaces
value = squashspaces(value)
ret += "%s = %s\n" % (var, value)
return ret.rstrip('\n')
buildhistory_commit() {
if [ ! -d ${BUILDHISTORY_DIR} ] ; then
# Code above that creates this dir never executed, so there can't be anything to commit
@@ -345,7 +383,7 @@ buildhistory_commit() {
repostatus=`git status --porcelain`
if [ "$repostatus" != "" ] ; then
git add ${BUILDHISTORY_DIR}/*
HOSTNAME=`cat /etc/hostname 2>/dev/null || echo unknown`
HOSTNAME=`hostname 2>/dev/null || echo unknown`
git commit ${BUILDHISTORY_DIR}/ -m "Build ${BUILDNAME} of ${DISTRO} ${DISTRO_VERSION} for machine ${MACHINE} on $HOSTNAME" --author "${BUILDHISTORY_COMMIT_AUTHOR}" > /dev/null
if [ "${BUILDHISTORY_PUSH_REPO}" != "" ] ; then
git push -q ${BUILDHISTORY_PUSH_REPO}

View File

@@ -1,6 +1,6 @@
BUILDSTATS_BASE = ${TMPDIR}/buildstats/
BNFILE = ${BUILDSTATS_BASE}/.buildname
DEVFILE = ${BUILDSTATS_BASE}/.device
BUILDSTATS_BASE = "${TMPDIR}/buildstats/"
BNFILE = "${BUILDSTATS_BASE}/.buildname"
DEVFILE = "${BUILDSTATS_BASE}/.device"
################################################################################
# Build statistics gathering.
@@ -61,11 +61,13 @@ def set_device(e):
# we do not collect diskstats as the method to collect meaningful statistics
# for these fs types requires a bit more research.
############################################################################
for line in open("/proc/diskstats", "r"):
if majordev == int(line.split()[0]) and minordev == int(line.split()[1]):
rdev=line.split()[2]
else:
rdev="NoLogicalDevice"
rdev="NoLogicalDevice"
try:
for line in open("/proc/diskstats", "r"):
if majordev == int(line.split()[0]) and minordev == int(line.split()[1]):
rdev=line.split()[2]
except:
pass
file = open(e.data.getVar('DEVFILE', True), "w")
file.write(rdev)
file.close()
@@ -82,12 +84,15 @@ def get_diskstats(dev):
# For info on what these are, see kernel doc file iostats.txt
############################################################################
DSTAT_KEYS = ['ReadsComp', 'ReadsMerged', 'SectRead', 'TimeReads', 'WritesComp', 'SectWrite', 'TimeWrite', 'IOinProgress', 'TimeIO', 'WTimeIO']
for x in open("/proc/diskstats", "r"):
if dev in x:
diskstats_val = x.rstrip().split()[4:]
diskstats = dict(itertools.izip(DSTAT_KEYS, diskstats_val))
try:
for x in open("/proc/diskstats", "r"):
if dev in x:
diskstats_val = x.rstrip().split()[4:]
except IOError as e:
return
diskstats = dict(itertools.izip(DSTAT_KEYS, diskstats_val))
return diskstats
def set_diskdata(var, dev, data):
data.setVar(var, get_diskstats(dev))

View File

@@ -43,7 +43,7 @@ set( CMAKE_CXX_FLAGS_RELEASE "${OECMAKE_CXX_FLAGS_RELEASE}" CACHE STRING "CXXFLA
# only search in the paths provided so cmake doesnt pick
# up libraries and tools from the native build machine
set( CMAKE_FIND_ROOT_PATH ${STAGING_DIR_HOST} ${STAGING_DIR_NATIVE} ${CROSS_DIR} ${OECMAKE_PERLNATIVE_DIR} ${OECMAKE_EXTRA_ROOT_PATH} )
set( CMAKE_FIND_ROOT_PATH ${STAGING_DIR_HOST} ${STAGING_DIR_NATIVE} ${CROSS_DIR} ${OECMAKE_PERLNATIVE_DIR} ${OECMAKE_EXTRA_ROOT_PATH} ${EXTERNAL_TOOLCHAIN})
set( CMAKE_FIND_ROOT_PATH_MODE_PROGRAM ONLY )
set( CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY )
set( CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY )

Some files were not shown because too many files have changed in this diff Show More