[OE-core] [PATCH] libvorbis: remove legacy options

2015-08-27 Thread Stefan Müller-Klieser
Those code fragments date back to ancient times. EXTRA_OECONF is not
required anymore and we should give gcc another try to do it right.
Testing on cortex-a8 with thumb and -O2 reveals a performance boost of
82 percent during encoding in comparison to -O0. -O4 gives another 7
percent.

Signed-off-by: Stefan Müller-Klieser s.mueller-klie...@phytec.de
---
- this requires patch 0fe770ef9817319bb82 from master-next. It is
  already for version 1.3.5

 meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb | 7 ---
 1 file changed, 7 deletions(-)

diff --git a/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb 
b/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
index b7a0667..636e0f3 100644
--- a/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
+++ b/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
@@ -15,10 +15,3 @@ SRC_URI[md5sum] = 28cb28097c07a735d6af56e598e1c90f
 SRC_URI[sha256sum] = 
54f94a9527ff0a88477be0a71c0bab09a4c3febe0ed878b24824906cd4b0e1d1
 
 inherit autotools pkgconfig
-
-# vorbisfile.c reveals a problem in the gcc register spilling for the
-# thumb instruction set...
-FULL_OPTIMIZATION_thumb = -O0
-
-EXTRA_OECONF = --with-ogg-libraries=${STAGING_LIBDIR} \
---with-ogg-includes=${STAGING_INCDIR}
-- 
1.9.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH] libnotify: add (R)PROVIDES/RCONFLICTS/RREPLACES for meta-gnome's libnotify

2015-08-27 Thread Andreas Müller
Avoid package feed issues caused by removing meta-gnome's libnotify3

Signed-off-by: Andreas Müller schnitzelt...@googlemail.com
---
 meta/recipes-gnome/libnotify/libnotify_0.7.6.bb | 6 ++
 1 file changed, 6 insertions(+)

diff --git a/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb 
b/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb
index 5d7b4ce..6d9c596 100644
--- a/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb
+++ b/meta/recipes-gnome/libnotify/libnotify_0.7.6.bb
@@ -10,3 +10,9 @@ inherit gnomebase distro_features_check gtk-doc
 SRC_URI[archive.md5sum] = a4997019d08f46f3bf57b78e6f795a59
 SRC_URI[archive.sha256sum] = 
0ef61ca400d30e28217979bfa0e73a7406b19c32dd76150654ec5b2bdf47d837
 
+# there were times, we had two versions of libnotify (oe-core libnotify:0.6.x /
+# meta-gnome libnotify3: 0.7.x)
+PROVIDES += libnotify3
+RPROVIDES_${PN} += libnotify3
+RCONFLICTS_${PN} += libnotify3
+RREPLACES_${PN} += libnotify3
-- 
2.1.0

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 2/6] gmp: Bring back version 4.2.1 (LGPL 2.1+)

2015-08-27 Thread Jussi Kukkonen
gmp 4.2.1 was removed in f181c6ce8b apparently accidentally: It
was not noticed that 4.2.1 is LGPL 2.1 (and not GPL) so provides
a useful alternative to the newer GPLv2 | LGPLv3 version.

* Reintroduce 4.2.1. The source includes files that are GPL but the
  library package is LGPL 2.1+
* Also reintroduce the two patches removed in f181c6ce8b.
* Refactor gmp.inc: gmp 6.0.0 build should not be affected in any way.
* Update 6.0.0 license from GPLv2 | LGPLv3 to GPLv2+ | LGPLv3+.

[YOCTO #8197]

Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
---
 .../gmp/gmp-4.2.1/disable-stdc.patch   | 39 +++
 .../gmp/gmp-4.2.1/gmp_fix_for_automake-1.12.patch  | 56 ++
 .../gmp/{gmp = gmp-6.0.0}/amd64.patch |  0
 .../append_user_provided_flags.patch   |  0
 .../gmp/{gmp = gmp-6.0.0}/configure.patch |  0
 .../gmp/{gmp = gmp-6.0.0}/gmp-6.0.0-ppc64.patch   |  0
 .../gmp/{gmp = gmp-6.0.0}/use-includedir.patch|  0
 meta/recipes-support/gmp/gmp.inc   | 19 +---
 meta/recipes-support/gmp/gmp_4.2.1.bb  | 15 ++
 meta/recipes-support/gmp/gmp_6.0.0.bb  | 33 ++---
 10 files changed, 137 insertions(+), 25 deletions(-)
 create mode 100644 meta/recipes-support/gmp/gmp-4.2.1/disable-stdc.patch
 create mode 100644 
meta/recipes-support/gmp/gmp-4.2.1/gmp_fix_for_automake-1.12.patch
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/amd64.patch (100%)
 rename meta/recipes-support/gmp/{gmp = 
gmp-6.0.0}/append_user_provided_flags.patch (100%)
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/configure.patch (100%)
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/gmp-6.0.0-ppc64.patch (100%)
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/use-includedir.patch (100%)
 create mode 100644 meta/recipes-support/gmp/gmp_4.2.1.bb

diff --git a/meta/recipes-support/gmp/gmp-4.2.1/disable-stdc.patch 
b/meta/recipes-support/gmp/gmp-4.2.1/disable-stdc.patch
new file mode 100644
index 000..5decb1c
--- /dev/null
+++ b/meta/recipes-support/gmp/gmp-4.2.1/disable-stdc.patch
@@ -0,0 +1,39 @@
+This patch was removed in f181c6ce8b3 when gmp 4.2.1 was mistakenly
+dropped.
+
+Upstream is not interested in patches for ancient versions.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
+
+# extern inline in traditional gcc means that the function should be 
+# inlined wherever it's seen, while in C99, extern inline means that i
+# the function should only be inlined where the inline definition is 
+# seen while in other places it's not inlined:
+# http://gcc.gnu.org/ml/gcc/2006-11/msg6.html
+#
+# gmp checks --std=gnu99 to use C99 convention however it internally 
+# defines some extern inline functions in gmp.h, which is included
+# by mainly .c files and finally lead a flood of redefinition function
+# errors when linking objects together.
+#
+# So disable C99/ANSI detection to stick to tranditional gcc behavior
+#
+# by Kevin Tian kevin.t...@intel.com, 2010-08-13
+#
+# (this patch is licensed under GPLv2+)
+
+diff --git a/configure.in b/configure.in
+index 450cc92..aab0b59 100644
+--- a/configure.in
 b/configure.in
+@@ -1869,9 +1869,7 @@ AC_SUBST(DEFN_LONG_LONG_LIMB)
+ 
+ # The C compiler and preprocessor, put into ANSI mode if possible.
+ AC_PROG_CC
+-AC_PROG_CC_STDC
+ AC_PROG_CPP
+-GMP_H_ANSI
+ 
+ 
+ # The C compiler on the build system, and associated tests.
diff --git a/meta/recipes-support/gmp/gmp-4.2.1/gmp_fix_for_automake-1.12.patch 
b/meta/recipes-support/gmp/gmp-4.2.1/gmp_fix_for_automake-1.12.patch
new file mode 100644
index 000..63aed05
--- /dev/null
+++ b/meta/recipes-support/gmp/gmp-4.2.1/gmp_fix_for_automake-1.12.patch
@@ -0,0 +1,56 @@
+automake 1.12 has depricated automatic de-ANSI-fication support
+
+this patch avoids these kinds of errors:
+
+| configure.in:2240: error: automatic de-ANSI-fication support has been removed
+| Makefile.am:28: error: automatic de-ANSI-fication support has been removed
+
+Signed-Off-By: Nitin A Kamble nitin.a.kam...@intel.com
+2012/05/02
+
+
+This patch was removed in f181c6ce8b3 when gmp 4.2.1 was mistakenly
+dropped.
+
+Upstream is not interested in patches for ancient versions.
+
+Upstream-Status: Inappropriate
+Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
+
+
+Index: gmp-4.2.1/configure.in
+===
+--- gmp-4.2.1.orig/configure.in
 gmp-4.2.1/configure.in
+@@ -67,7 +67,7 @@ dnl
+ dnl  Note that there's a copy of these options in the top-level Makefile.am,
+ dnl  so update there too if changing anything.
+ dnl
+-AM_INIT_AUTOMAKE([1.8 gnu no-dependencies $(top_builddir)/ansi2knr])
++AM_INIT_AUTOMAKE([1.8 gnu no-dependencies])
+ AM_CONFIG_HEADER(config.h:config.in)
+ AM_MAINTAINER_MODE
+ 
+@@ -2022,9 +2022,6 @@ fi
+ echo   MPN_PATH=\$path\
+ 
+ 
+-# Automake ansi2knr support.
+-AM_C_PROTOTYPES
+-
+ GMP_PROG_AR
+ GMP_PROG_NM
+ 
+Index: 

[OE-core] [PATCH 3/6] nettle: Add (LGPLv3) version 3.1.1

2015-08-27 Thread Jussi Kukkonen
Newer nettle versions are LGPLv3+ | GPLv2+. Add 3.1.1 but also
keep version 2.7.1 since it's LGPLv2.1+

Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
---
 meta/recipes-support/nettle/nettle.inc  | 26 ++
 meta/recipes-support/nettle/nettle_2.7.1.bb | 20 ++--
 meta/recipes-support/nettle/nettle_3.1.1.bb | 11 +++
 3 files changed, 39 insertions(+), 18 deletions(-)
 create mode 100644 meta/recipes-support/nettle/nettle.inc
 create mode 100644 meta/recipes-support/nettle/nettle_3.1.1.bb

diff --git a/meta/recipes-support/nettle/nettle.inc 
b/meta/recipes-support/nettle/nettle.inc
new file mode 100644
index 000..0579b6c
--- /dev/null
+++ b/meta/recipes-support/nettle/nettle.inc
@@ -0,0 +1,26 @@
+SUMMARY = A low level cryptographic library
+HOMEPAGE = http://www.lysator.liu.se/~nisse/nettle/;
+SECTION = libs
+
+LIC_FILES_CHKSUM = file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
+
file://serpent-decrypt.c;beginline=53;endline=67;md5=bcfd4745d53ca57f82907089898e390d
 \
+
file://serpent-set-key.c;beginline=56;endline=70;md5=bcfd4745d53ca57f82907089898e390d
+
+DEPENDS += gmp
+
+SRC_URI = http://www.lysator.liu.se/~nisse/archive/${BP}.tar.gz;
+
+SRC_URI[md5sum] = 003d5147911317931dd453520eb234a5
+SRC_URI[sha256sum] = 
bc71ebd43435537d767799e414fce88e521b7278d48c860651216e1fc6555b40
+
+EXTRA_OECONF = --disable-openssl
+
+do_configure_prepend() {
+   if [ ! -e ${S}/acinclude.m4 -a -e ${S}/aclocal.m4 ]; then
+   cp ${S}/aclocal.m4 ${S}/acinclude.m4
+   fi
+}
+
+inherit autotools
+
+BBCLASSEXTEND = native nativesdk
diff --git a/meta/recipes-support/nettle/nettle_2.7.1.bb 
b/meta/recipes-support/nettle/nettle_2.7.1.bb
index 7823df9..ae2574a 100644
--- a/meta/recipes-support/nettle/nettle_2.7.1.bb
+++ b/meta/recipes-support/nettle/nettle_2.7.1.bb
@@ -1,6 +1,5 @@
-SUMMARY = A low level cryptographic library
-HOMEPAGE = http://www.lysator.liu.se/~nisse/nettle/;
-SECTION = libs
+require nettle.inc
+
 LICENSE = LGPLv2.1  GPLv2
 LICENSE_${PN} = LGPLv2.1+
 
@@ -8,21 +7,6 @@ LIC_FILES_CHKSUM = 
file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
 
file://serpent-decrypt.c;beginline=53;endline=67;md5=bcfd4745d53ca57f82907089898e390d
 \
 
file://serpent-set-key.c;beginline=56;endline=70;md5=bcfd4745d53ca57f82907089898e390d
 
-DEPENDS += gmp
-
-SRC_URI = http://www.lysator.liu.se/~nisse/archive/${BP}.tar.gz;
-
 SRC_URI[md5sum] = 003d5147911317931dd453520eb234a5
 SRC_URI[sha256sum] = 
bc71ebd43435537d767799e414fce88e521b7278d48c860651216e1fc6555b40
 
-EXTRA_OECONF = --disable-openssl
-
-do_configure_prepend() {
-   if [ ! -e ${S}/acinclude.m4 -a -e ${S}/aclocal.m4 ]; then
-   cp ${S}/aclocal.m4 ${S}/acinclude.m4
-   fi
-}
-
-inherit autotools
-
-BBCLASSEXTEND = native nativesdk
diff --git a/meta/recipes-support/nettle/nettle_3.1.1.bb 
b/meta/recipes-support/nettle/nettle_3.1.1.bb
new file mode 100644
index 000..7d7134f
--- /dev/null
+++ b/meta/recipes-support/nettle/nettle_3.1.1.bb
@@ -0,0 +1,11 @@
+require nettle.inc
+
+LICENSE = LGPLv3+ | GPLv2+
+
+LIC_FILES_CHKSUM = 
file://COPYING.LESSERv3;md5=6a6a8e020838b23406c81b19c1d46df6 \
+file://COPYINGv2;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
+
file://serpent-decrypt.c;beginline=14;endline=36;md5=ca0d220bc413e1842ecc507690ce416e
 \
+
file://serpent-set-key.c;beginline=14;endline=36;md5=ca0d220bc413e1842ecc507690ce416e
+
+SRC_URI[md5sum] = b40fa88dc32f37a182b6b42092ebb144
+SRC_URI[sha256sum] = 
5fd4d25d64d8ddcb85d0d897572af73b05b4d163c6cc49438a5bfbb8ff293d4c
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 5/6] gnutls: Upgrade 3.3.14 - 3.3.17.1

2015-08-27 Thread Jussi Kukkonen
Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
---
 meta/recipes-support/gnutls/{gnutls_3.3.14.bb = gnutls_3.3.17.1.bb} | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
 rename meta/recipes-support/gnutls/{gnutls_3.3.14.bb = gnutls_3.3.17.1.bb} 
(59%)

diff --git a/meta/recipes-support/gnutls/gnutls_3.3.14.bb 
b/meta/recipes-support/gnutls/gnutls_3.3.17.1.bb
similarity index 59%
rename from meta/recipes-support/gnutls/gnutls_3.3.14.bb
rename to meta/recipes-support/gnutls/gnutls_3.3.17.1.bb
index f41d183..0185797 100644
--- a/meta/recipes-support/gnutls/gnutls_3.3.14.bb
+++ b/meta/recipes-support/gnutls/gnutls_3.3.17.1.bb
@@ -4,5 +4,5 @@ SRC_URI += file://correct_rpl_gettimeofday_signature.patch \
 file://configure.ac-fix-sed-command.patch \
 file://use-pkg-config-to-locate-zlib.patch \

-SRC_URI[md5sum] = 7f4465f8c564cf9cb8f5cb38b909f7ca
-SRC_URI[sha256sum] = 
0dfa0030faad8909c1e904105198232d6bc0123cae8cf4933b2bac85ee7cec52
+SRC_URI[md5sum] = 8d01c7e7f2cbc5871fdca832d2260b6b
+SRC_URI[sha256sum] = 
b40f158030a92f450a07b20300a3996710ca19800848d9f6fd62493170c5bbb4
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 1/6] nettle: Fix binary license to LGPLv2.1+

2015-08-27 Thread Jussi Kukkonen
* Set the nettle binary package license to LGPLv2.1+:
  There are GPL files in the sources but none of these are used
  to produce the files we ship.
* Remove the useless package specific licenses: none of the named
  packages are actually produced and the licenses do not affect
  the overall license of either the sources or the binary package.

Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
---
 meta/recipes-support/nettle/nettle_2.7.1.bb | 9 +
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/meta/recipes-support/nettle/nettle_2.7.1.bb 
b/meta/recipes-support/nettle/nettle_2.7.1.bb
index f9d331f..7823df9 100644
--- a/meta/recipes-support/nettle/nettle_2.7.1.bb
+++ b/meta/recipes-support/nettle/nettle_2.7.1.bb
@@ -2,14 +2,7 @@ SUMMARY = A low level cryptographic library
 HOMEPAGE = http://www.lysator.liu.se/~nisse/nettle/;
 SECTION = libs
 LICENSE = LGPLv2.1  GPLv2
-
-LICENSE_${PN}-cast = CC0
-LICENSE_${PN}-gosthash = MIT
-
-# both public and GPL license listed
-LICENSE_${PN}-md2 = CC0  LGPLv2.1+
-LICENSE_${PN}-md4 = CC0  LGPLv2.1+
-
+LICENSE_${PN} = LGPLv2.1+
 
 LIC_FILES_CHKSUM = file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
 
file://serpent-decrypt.c;beginline=53;endline=67;md5=bcfd4745d53ca57f82907089898e390d
 \
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 0/6] Bring back LGPLv2 gmp, upgrade gnutls stack

2015-08-27 Thread Jussi Kukkonen
This patch set is the result of gnutls/nettle/gmp license discussion
on the mailing list. The end result is that gnutls stack is available
as LGPLv2.1 and also as the newest versions (where nettle and gmp are
LGPLv3 | GPLv2).

In more detail:
 * Re-introduce an older LGPLv2 version of gmp
 * Fix nettle binary package license
 * Upgrade gnutls and nettle (keep LGPLv2 nettle as well)

gmp 4.2.1 was in better shape than I expected but it's still
software that was last updated 9 years ago and is used in a crypto
context... If there are other solutions to this problem I'll be
happy to hear them out.

Most of the commits depend on the ones before them either via version
incompatibilities or via applying on top of each other. I've smoke
tested two combinations of versions:
 * everything upgraded to newest
 * everything at LGPLv2.1 versions


Cheers,
 Jussi



The following changes since commit 778fc612cb584d17da02ecc115c4e6edba995602:

  libnotify: update to version 0.7.6 (2015-08-26 07:36:15 +0100)

are available in the git repository at:

  git://git.yoctoproject.org/poky-contrib jku/lgpl-all-the-things
  
http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=jku/lgpl-all-the-things

Jussi Kukkonen (6):
  nettle: Fix binary license to LGPLv2.1+
  gmp: Bring back version 4.2.1 (LGPL 2.1+)
  nettle: Add (LGPLv3) version 3.1.1
  nettle: Add ptests
  gnutls: Upgrade 3.3.14 - 3.3.17.1
  mirrors.bbclass: Update gnutls mirrors

 meta/classes/mirrors.bbclass   |  5 +-
 .../gmp/gmp-4.2.1/disable-stdc.patch   | 39 +++
 .../gmp/gmp-4.2.1/gmp_fix_for_automake-1.12.patch  | 56 ++
 .../gmp/{gmp = gmp-6.0.0}/amd64.patch |  0
 .../append_user_provided_flags.patch   |  0
 .../gmp/{gmp = gmp-6.0.0}/configure.patch |  0
 .../gmp/{gmp = gmp-6.0.0}/gmp-6.0.0-ppc64.patch   |  0
 .../gmp/{gmp = gmp-6.0.0}/use-includedir.patch|  0
 meta/recipes-support/gmp/gmp.inc   | 19 +---
 meta/recipes-support/gmp/gmp_4.2.1.bb  | 15 ++
 meta/recipes-support/gmp/gmp_6.0.0.bb  | 33 ++---
 .../{gnutls_3.3.14.bb = gnutls_3.3.17.1.bb}   |  4 +-
 ...d-target-to-only-build-tests-not-run-them.patch | 43 +
 meta/recipes-support/nettle/files/run-ptest| 36 ++
 meta/recipes-support/nettle/nettle.inc | 43 +
 meta/recipes-support/nettle/nettle_2.7.1.bb| 29 ++-
 meta/recipes-support/nettle/nettle_3.1.1.bb| 11 +
 17 files changed, 276 insertions(+), 57 deletions(-)
 create mode 100644 meta/recipes-support/gmp/gmp-4.2.1/disable-stdc.patch
 create mode 100644 
meta/recipes-support/gmp/gmp-4.2.1/gmp_fix_for_automake-1.12.patch
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/amd64.patch (100%)
 rename meta/recipes-support/gmp/{gmp = 
gmp-6.0.0}/append_user_provided_flags.patch (100%)
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/configure.patch (100%)
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/gmp-6.0.0-ppc64.patch (100%)
 rename meta/recipes-support/gmp/{gmp = gmp-6.0.0}/use-includedir.patch (100%)
 create mode 100644 meta/recipes-support/gmp/gmp_4.2.1.bb
 rename meta/recipes-support/gnutls/{gnutls_3.3.14.bb = gnutls_3.3.17.1.bb} 
(59%)
 create mode 100644 
meta/recipes-support/nettle/files/Add-target-to-only-build-tests-not-run-them.patch
 create mode 100644 meta/recipes-support/nettle/files/run-ptest
 create mode 100644 meta/recipes-support/nettle/nettle.inc
 create mode 100644 meta/recipes-support/nettle/nettle_3.1.1.bb

-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 6/6] mirrors.bbclass: Update gnutls mirrors

2015-08-27 Thread Jussi Kukkonen
* Remove mirror sites that no longer exist
* Update the gnutls.org path so the gnupg mirror gets used

Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
---
 meta/classes/mirrors.bbclass | 5 +
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/meta/classes/mirrors.bbclass b/meta/classes/mirrors.bbclass
index 081c982..b96c071 100644
--- a/meta/classes/mirrors.bbclass
+++ b/meta/classes/mirrors.bbclass
@@ -27,10 +27,7 @@ ftp://ftp.gnupg.org/gcrypt/ 
http://gulus.USherbrooke.ca/pub/appl/GnuPG/ \n \
 ftp://dante.ctan.org/tex-archive ftp://ftp.fu-berlin.de/tex/CTAN \n \
 ftp://dante.ctan.org/tex-archive http://sunsite.sut.ac.jp/pub/archives/ctan/ 
\n \
 ftp://dante.ctan.org/tex-archive http://ctan.unsw.edu.au/ \n \
-ftp://ftp.gnutls.org/pub/gnutls ftp://ftp.gnupg.org/gcrypt/gnutls/ \n \
-ftp://ftp.gnutls.org/pub/gnutls 
http://www.mirrors.wiretapped.net/security/network-security/gnutls/ \n \
-ftp://ftp.gnutls.org/pub/gnutls 
ftp://ftp.mirrors.wiretapped.net/pub/security/network-security/gnutls/ \n \
-ftp://ftp.gnutls.org/pub/gnutls http://josefsson.org/gnutls/releases/ \n \
+ftp://ftp.gnutls.org/gcrypt/gnutls ftp://ftp.gnupg.org/gcrypt/gnutls/ \n \
 http://ftp.info-zip.org/pub/infozip/src/ 
http://mirror.switch.ch/ftp/mirror/infozip/src/ \n \
 http://ftp.info-zip.org/pub/infozip/src/ 
ftp://sunsite.icm.edu.pl/pub/unix/archiving/info-zip/src/ \n \
 ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/  
ftp://ftp.cerias.purdue.edu/pub/tools/unix/sysutils/lsof/ \n \
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 3/3] devtool: run kernel dependencies

2015-08-27 Thread Markus Lehtonen
Hi,

On 27/08/15 15:45, Paul Eggleton paul.eggle...@linux.intel.com wrote:

Hi Markus,

On Thursday 27 August 2015 14:49:50 Markus Lehtonen wrote:
 The kernel package needs kern-tools-native in order for it's
 do_kernel_metadata. Thus, devtool extract for kernel in a pristine
 environment fails. With the current bb.tinfoil implementation it is not
 possible to run arbitrary bitbake commands - e.g. run
 bitbake kern-tools-native -c populate_sysroot in our case. This patch
 implements an ugly workaround for that problem, basically by hardcoding
 this dependency and running the required bitbake task(s) before tinfoil
 is initialized.
 
 [YOCTO #6658]
 
 Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
 ---
  scripts/lib/devtool/standard.py | 19 ++-
  1 file changed, 18 insertions(+), 1 deletion(-)
 
 diff --git a/scripts/lib/devtool/standard.py
 b/scripts/lib/devtool/standard.py index 3725d87..bf24e32 100644
 --- a/scripts/lib/devtool/standard.py
 +++ b/scripts/lib/devtool/standard.py
 @@ -197,6 +197,8 @@ def extract(args, config, basepath, workspace):
  Entry point for the devtool 'extract' subcommand
  import bb
 
 +_check_extract_deps(config, basepath, args.recipename)
 +
  tinfoil = setup_tinfoil()
 
  rd = _parse_recipe(config, tinfoil, args.recipename, True)
 @@ -237,6 +239,20 @@ class BbTaskExecutor(object):
  self.executed.append(func)
 
 
 +def _check_extract_deps(config, basepath, recipename):
 +HACK: Ugly workaround for making sure that requirements are met
when
 +   trying to extract a package
 +tinfoil = setup_tinfoil()
 +rd = _parse_recipe(config, tinfoil, recipename, True)
 +if bb.data.inherits_class('kernel-yocto', rd):
 +tinfoil.shutdown()

Hmm, surely you need to call shutdown() in the non-kernel case as well?
Otherwise won't the lock still be in place when this function returns and
then 
setup_tinfoil() is called a second time?

Argh, I was a bit too hasty with this one. You can find a new version of
this patch attached as well as in the git repository at:

  git://git.openembedded.org/openembedded-core-contrib
marquiz/devtool/kernel
  
http://git.openembedded.org/openembedded-core-contrib/log/?h=marquiz/devtoo
l/kernel



Thanks,
  Markus



0001-devtool-run-kernel-dependencies.patch
Description: Binary data
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH V3 0/3] Add UEFI firmware for qemux86*

2015-08-27 Thread Paul Eggleton
On Thursday 27 August 2015 15:19:57 Patrick Ohly wrote:
 On Tue, 2015-07-14 at 20:07 +,
 
 leonardo.sandoval.gonza...@linux.intel.com wrote:
  From: Leonardo Sandoval leonardo.sandoval.gonza...@linux.intel.com
  
  These patches include:
  1. iasl recipe taken from luv-yocto repository into OE-Core (the only
  
 change done was the LICENSE, from Intel-ACPI to BSD | GPLv2)
  
  2. OVMF recipe (taken from luv-yocto repository) into OE-Core
  3. Boot script: Instrumenting runqemu to include
  OECORE_MACHINE_SYSROOT,
  so the OVMF BIOS can be found.
 
 I've tried out these patches. Mostly it worked as advertised and I'd
 love to use EFI with qemu, so I'd like to see this merged.
 
 I noticed that git format-patches from your branch followed by git
 am mangles the
 meta/recipes-core/ovmf/ovmf/0001-BaseTools-Force-tools-variables-to-host-too
 lchain.patch because it is a mixture of Unix line ends (patch boiler plate)
 and DOS line ends (actual patches). The file ended up with all Unix line
 ends, which then failed during do_patch. I solved that by checking out your
 branch and copying the file. Whoever merges needs to be careful here. This
 might also be a problem for combo-layer, so perhaps a solution not based on
 patching the makefiles may be needed.

Good to note this - FYI the --keep-cr option is what you need to add to your 
git am command line in order to avoid this problem. combo-layer does this 
already (we hit this same problem with patches to files with DOS line endings a 
while back).

This is one reason why using the branch is usually a lot easier and safer than 
applying emails as patches (assuming the submitter sends a pull request with a 
branch - I'd encourage everyone sending series of more than a couple of 
patches to do this using the create-pull-request/send-pull-request scripts if 
they aren't already).

Cheers,
Paul
-- 

Paul Eggleton
Intel Open Source Technology Centre
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH v2 1/2] devtool: upgrade feature

2015-08-27 Thread Leonardo Sandoval



On 08/26/2015 07:04 PM, Paul Eggleton wrote:

On Wednesday 26 August 2015 07:43:23
leonardo.sandoval.gonza...@linux.intel.com wrote:

From: Leonardo Sandoval leonardo.sandoval.gonza...@linux.intel.com

Upgrades a recipe to a particular version and downloads the source code
into srctree. User can avoid patching the source code. These are the
general steps of the upgrade function:
* Extract current recipe source code into srctree and create branch
* Extract upgrade recipe source code into srctree and rebase with
  previous branch. This step also creates a temporal recipe (created
  using recipetool), containing the correct checksums.
* Creates the new recipe under the workspace


OK, I haven't tested this yet but some comments just looking over the code
below.


Ok, let me know if you find something when testing.





[YOCTO #7642]

Signed-off-by: Leonardo Sandoval
leonardo.sandoval.gonza...@linux.intel.com ---
  scripts/lib/devtool/standard.py |   4 +-
  scripts/lib/devtool/upgrade.py  | 314
 2 files changed, 317
insertions(+), 1 deletion(-)
  create mode 100644 scripts/lib/devtool/upgrade.py

diff --git a/scripts/lib/devtool/standard.py
b/scripts/lib/devtool/standard.py index ea21877..cd5a3ed 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -205,6 +205,8 @@ def extract(args, config, basepath, workspace):

  srctree = os.path.abspath(args.srctree)
  initial_rev = _extract_source(srctree, args.keep_temp, args.branch, rd)
+logger.info('Source tree extracted to %s' % srctree)
+
  if initial_rev:
  return 0
  else:
@@ -360,7 +362,6 @@ def _extract_source(srctree, keep_temp, devbranch, d):
  bb.process.run('git checkout patches', cwd=srcsubdir)

  shutil.move(srcsubdir, srctree)
-logger.info('Source tree extracted to %s' % srctree)
  finally:
  bb.logger.setLevel(origlevel)

@@ -439,6 +440,7 @@ def modify(args, config, basepath, workspace):
  initial_rev = _extract_source(args.srctree, False, args.branch, rd)
if not initial_rev:
  return 1
+logger.info('Source tree extracted to %s' % srctree)
  # Get list of commits since this revision
  (stdout, _) = bb.process.run('git rev-list --reverse %s..HEAD' %
initial_rev, cwd=args.srctree) commits = stdout.split()
diff --git a/scripts/lib/devtool/upgrade.py b/scripts/lib/devtool/upgrade.py
new file mode 100644
index 000..9bef984
--- /dev/null
+++ b/scripts/lib/devtool/upgrade.py
@@ -0,0 +1,314 @@
+# Development tool - upgrade command plugin
+#
+# Copyright (C) 2014-2015 Intel Corporation
+#
+# 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.
+#
+# DESCRIPTION
+# Created a new recipe under workspace/recipes/recipename and place the
+# source code into srctree.
+# The upgrade feature executes the following steps:
+# * Extract current recipe source code into srctree and create branch
+# * Extract upgrade recipe source code into srctree and rebase with
+#   previous branch. This step also creates a temporal recipe (created
+#   using recipetool), containing the correct checksums.
+# * Creates the new recipe under the workspace
+Devtool upgrade plugin
+
+import os
+import sys
+import re
+import shutil
+import tempfile
+import logging
+import argparse
+import scriptutils
+import errno
+from devtool import standard
+from devtool import exec_build_env_command, setup_tinfoil, DevtoolError
+
+logger = logging.getLogger('devtool')
+
+def plugin_init(pluginlist):
+Plugin initialization
+pass
+
+def _extract_upgrade_source(args, devbranch, config, basepath, d,
recipepostfix='tmp'): +Extract sources of a recipe with PV given on
args.version
+
+On the target source tree folder, a new branch
(devbranch_args.version) +and tag (devbranch-base_args.version)
will be created. In case patches +are applied, another tag is created
(devbranch-patched_args.version). +
+Returns: 1) The (git) initial revision ID
+ 2) The full path of a temporal recipe containing the correct
checksums +
+import oe.recipeutils
+
+initial_rev = None
+srctree = os.path.abspath(args.srctree)
+
+pn = d.getVar('PN', True)
+
+standard._check_compatible_recipe(pn, d)
+
+recipepath = os.path.join(config.workspace_path, 'recipes', 

Re: [OE-core] [PATCH v2 1/2] devtool: upgrade feature

2015-08-27 Thread Otavio Salvador
On Thu, Aug 27, 2015 at 10:24 AM, Leonardo Sandoval
leonardo.sandoval.gonza...@linux.intel.com wrote:
 On 08/26/2015 07:04 PM, Paul Eggleton wrote:
 We already have code for editing recipes like this in recipeutils (and in
 lib/bb/utils as well) - in fact I see you're using patch_recipe() later
 on, so
 why do it by hand here?


 can 'oe.recipeutils.patch_recipe' patch variable's flags? I did not try but
 looking at the function definition, seems like it does not.

So add this feature there if you need it.

-- 
Otavio Salvador O.S. Systems
http://www.ossystems.com.brhttp://code.ossystems.com.br
Mobile: +55 (53) 9981-7854Mobile: +1 (347) 903-9750
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] devtool: add package plugin that lets you create package via devtool

2015-08-27 Thread Paul Eggleton
Hi Brendan,

On Wednesday 19 August 2015 17:33:27 brendan.le.f...@intel.com wrote:
 From: Brendan Le Foll brendan.le.f...@intel.com
 
 Signed-off-by: Brendan Le Foll brendan.le.f...@intel.com
 ---
  scripts/lib/devtool/package.py | 63
 ++ 1 file changed, 63 insertions(+)
  create mode 100644 scripts/lib/devtool/package.py
 
 diff --git a/scripts/lib/devtool/package.py b/scripts/lib/devtool/package.py
 new file mode 100644
 index 000..18b9eb0
 --- /dev/null
 +++ b/scripts/lib/devtool/package.py
 @@ -0,0 +1,63 @@
 +# Development tool - package command plugin
 +#
 +# Copyright (C) 2014-2015 Intel Corporation
 +#
 +# 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.
 +Devtool plugin containing the package subcommands
 +
 +import os
 +import subprocess
 +import logging
 +from devtool import exec_build_env_command, setup_tinfoil, DevtoolError
 +
 +logger = logging.getLogger('devtool')
 +
 +def plugin_init(pluginlist):
 +Plugin initialization
 +pass
 +
 +def package(args, config, basepath, workspace):
 +Entry point for the devtool 'package' subcommand
 +import re
 +import bb
 +if not args.recipename in workspace:
 +raise DevtoolError(no recipe named %s in your workspace %
 +   args.recipename)
 +
 +try:
 +image_pkgtype = exec_build_env_command(config.init_path, basepath,
 'bitbake -e %s | grep IMAGE_PKGTYPE' % (args.recipename), watch=False) +   
 except bb.process.ExecutionError as e:
 +logger.error('Unable to get IMAGE_PKGTYPE for image')
 +return e.exitcode
 +
 +image_pkgtype = str(image_pkgtype).split('=', 1)[1].split('', 2)[1]
 +if image_pkgtype not in (rpm, ipk, tar, deb):
 +logger.error('Invalid package format (%s) found' % image_pkgtype)
 +return 1

Instead of this, how about:

tinfoil = setup_tinfoil()
try:
tinfoil.prepare(config_only=True)
image_pkgtype = tinfoil.config_data.getVar('IMAGE_PKGTYPE', True)
finally:
tinfoil.shutdown()

 +package_task = config.get('Package', 'package_task', 'package_write_%s'
 % image_pkgtype) 

Hmm, shouldn't the config be for image_pkgtype rather than this? (Since even if 
this is set we'd still be using the IMAGE_PKGTYPE value for the directory path 
in the message later on).

 +try:
 +exec_build_env_command(config.init_path, basepath, 'bitbake -c %s
 %s' % (package_task, args.recipename), watch=True) 
 +except
 bb.process.ExecutionError as e:
 +# We've already seen the output since watch=True, so just ensure we
 return something to the user
 +return e.exitcode
 +logger.info('Your packages are in %s/tmp/deploy/%s' % (basepath,
 image_pkgtype))
 +
 +return 0
 +
 +def register_commands(subparsers, context):
 +Register devtool subcommands from the package plugin
 +parser_package = subparsers.add_parser('package', help='Package a
 recipe output files')

I would suggest:

help='Create packages for a recipe',
description='Creates packages for a recipe\'s output files'

 +parser_package.add_argument('recipename', help='Recipe to package') 
 +parser_package.set_defaults(func=package)

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 2/2] devtool: implement build-image plugin

2015-08-27 Thread Paul Eggleton
Hi Ed,

On Monday 24 August 2015 10:33:31 Ed Bartosh wrote:
 Implemented new plugin to build image from workspace packages.
 
 Plugin creates image.bbappend file, adds
 all workspace packages to the image using IMAGE_INSTALL_append
 variable in bbappend file. After that it runs 'bitbake image'.
 
 Signed-off-by: Ed Bartosh ed.bart...@linux.intel.com
 ---
  scripts/lib/devtool/build-image.py | 56
 ++ 1 file changed, 56 insertions(+)
  create mode 100644 scripts/lib/devtool/build-image.py
 
 diff --git a/scripts/lib/devtool/build-image.py
 b/scripts/lib/devtool/build-image.py new file mode 100644
 index 000..d8e7b12
 --- /dev/null
 +++ b/scripts/lib/devtool/build-image.py
 @@ -0,0 +1,56 @@
 +# Development tool - build-image plugin
 +#
 +# Copyright (C) 2015 Intel Corporation
 +#
 +# 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.
 +
 +Devtool plugin containing the build-image subcommand.
 +
 +import os
 +import logging
 +
 +from bb.process import ExecutionError
 +from devtool import exec_build_env_command, add_md5
 +
 +LOG = logging.getLogger('devtool')

I recall you mentioning pylint had a problem with logger - we're using that 
throughout the devtool code (and elsewhere). LOG just looks a bit weird. 
What is it complaining about specifically?

 +def plugin_init(pluginlist):
 +Plugin initialization
 +pass
 +
 +def build_image(args, config, basepath, workspace):
 +Entry point for the devtool 'build-image' subcommand.
 +image = args.recipe
 +appendfile = os.path.join(config.workspace_path, 'appends',
 +  '%s.bbappend' % image)
 +with open(appendfile, 'w') as afile:
 +afile.write('IMAGE_INSTALL_append =  %s\n' % \
 +' '.join(workspace.keys()))

Some notes here:

1) Recipes that aren't for the target somehow need to be filtered out (e.g. 
native recipes). I'd imagine the way to do that would be to parse each one and 
check if class-target is in d.getVar('OVERRIDES', True).split(':').

2) We're making a direct mapping between recipe name and main package for the 
recipe. That'll work for most recipes but there will be some where that's not 
valid. I'm tempted to say that since we're parsing the recipe anyway, for now 
we should do a quick check of PACKAGES to ensure we're not adding something 
that'll cause the build to fail.

3) It would be nice to add an option to add all the packages in PACKAGES for 
each recipe to the image; and a separate option to just add the non-dev/-dbg/-
staticdev packages. Perhaps we should leave this as a future enhancement 
though.

4) If there's no target recipes in the workspace then print something like No 
recipes in workspace, building image image unmodified. On the other hand if  
there are we should report Building image image with the following 
additional packages: packagelist'

5) If there are recipes can you add the following so that the build system 
prints something every time the image recipe gets built:

do_rootfs[prefuncs] += devtool_warn_image_extended
python devtool_warn_image_extended() {
bb.plain('NOTE: %s: building with additional packages due to devtool 
build-image, delete /path/to/bbappend to clear this' % d.getVar('PN', True))
}

 +add_md5(config, image, appendfile)

This isn't actually doing much if we can't use devtool reset is it? (Since 
the recipe isn't officially in the workspace; we could make it so, but then 
we'd 
need to ensure the other commands either behave themselves or error out as 
appropriate if called with an image recipe that's in the workspace.)

 +try:
 +exec_build_env_command(config.init_path, basepath,
 +   'bitbake %s' % image, watch=True)
 +except ExecutionError as err:
 +return err.exitcode
 +
 +LOG.info('Successfully built %s', image)
 +
 +def register_commands(subparsers, context):
 +Register devtool subcommands from the build-image plugin
 +parser_package = subparsers.add_parser('build-image', help='Build
 image') 
 +parser_package.add_argument('recipe', help='Image recipe to
 build') 
 +parser_package.set_defaults(func=build_image)
 +

Can you please change help for the command to 'Build image including workspace 
recipe packages' and add description='Builds an image, extending it to include 
packages from recipes in the 

Re: [OE-core] [PATCH 1/1] mtd-utils: add xattr PACKAGECONFIG and fix acl dependency

2015-08-27 Thread Patrick Ohly
On Thu, 2015-08-27 at 06:32 -0700, Khem Raj wrote:
 On Wed, Aug 26, 2015 at 11:43 PM, Patrick Ohly patrick.o...@intel.com wrote:
  The one in bb.utils.contains()? That is there intentionally: it's for
  the xattr enabled case, in which case nothing gets added to
  EXTRA_OEMAKE.
 
 is it required to have extra  ?
 can it work without it

bb.utils.contains() expects exactly 5 parameters and has no defaults, so
no, that empty string cannot be omitted.

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.



-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH v2 0/1] Add recipe whitelisting class

2015-08-27 Thread Paul Eggleton
Changes since the RFC version:
* Check BPN in addition to PN for matching, to make it easier in the
  multilib case
* Use PNWHITELIST_LAYERS to specify which layers to apply whitelisting to,
  and consider an empty whitelist value to be no recipes whitelisted (so
  you can set up empty whitelists for layers not yet in your
  configuration if you wish to do so). This also makes setting
  PNWHITELIST without an override practical.
* Touch up the comments

The following changes since commit f07045fcae859c902434062d1725f1348f42d1dd:

  oeqa/oetest.py: add better package search for hasPackage() (2015-08-26 
08:26:37 +0100)

are available in the git repository at:

  git://git.openembedded.org/openembedded-core-contrib paule/whitelist
  
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=paule/whitelist

Paul Eggleton (1):
  classes/whitelist: add class to allow whitelisting recipes from a
layer

 meta/classes/whitelist.bbclass | 34 ++
 1 file changed, 34 insertions(+)
 create mode 100644 meta/classes/whitelist.bbclass

-- 
2.1.0

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH v2 1/1] classes/whitelist: add class to allow whitelisting recipes from a layer

2015-08-27 Thread Paul Eggleton
Allow restricting recipes brought from a layer to a specified list. This
is similar in operation to blacklist.bbclass, but instead specifies a
per-layer whitelist of recipes (matched by PN or BPN) that are able to
be built from the layer - anything else is skipped. This is potentially
useful where you want to bring in a select set of recipes from a larger
layer e.g. meta-oe.

Implements [YOCTO #8150].

Signed-off-by: Paul Eggleton paul.eggle...@linux.intel.com
---
 meta/classes/whitelist.bbclass | 34 ++
 1 file changed, 34 insertions(+)
 create mode 100644 meta/classes/whitelist.bbclass

diff --git a/meta/classes/whitelist.bbclass b/meta/classes/whitelist.bbclass
new file mode 100644
index 000..ab6ac73
--- /dev/null
+++ b/meta/classes/whitelist.bbclass
@@ -0,0 +1,34 @@
+# Class that allows you to restrict the recipes brought from a layer to
+# a specified list. This is similar in operation to blacklist.bbclass
+# but note the difference in how PNWHITELIST is set - we don't use varflags
+# here, the recipe name goes in the value and we use an override for the
+# layer name (although this is not strictly required - you can have one
+# PNWHITELIST value shared by all of the layers specified in
+# PNWHITELIST_LAYERS). The layer name used here is actually the name that
+# gets added to BBFILE_COLLECTIONS in the layer's layer.conf, which may
+# differ from how the layer is otherwise known - e.g. meta-oe uses
+# openembedded-layer.
+#
+# INHERIT += whitelist
+# PNWHITELIST_LAYERS = layername
+# PNWHITELIST_layername = recipe1 recipe2
+#
+# If you would prefer to set a reason message other than the default, you
+# can do so:
+#
+# PNWHITELIST_REASON_layername = not supported by ${DISTRO}
+
+python() {
+layer = bb.utils.get_file_layer(d.getVar('FILE', True), d)
+if layer:
+layers = (d.getVar('PNWHITELIST_LAYERS', True) or '').split()
+if layer in layers:
+localdata = bb.data.createCopy(d)
+localdata.setVar('OVERRIDES', layer)
+whitelist = (localdata.getVar('PNWHITELIST', True) or '').split()
+if not (d.getVar('PN', True) in whitelist or d.getVar('BPN', True) 
in whitelist):
+reason = localdata.getVar('PNWHITELIST_REASON', True)
+if not reason:
+reason = 'not in PNWHITELIST for layer %s' % layer
+raise bb.parse.SkipRecipe(reason)
+}
-- 
2.1.0

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 3/3] devtool: run kernel dependencies

2015-08-27 Thread Paul Eggleton
Hi Markus,

On Thursday 27 August 2015 14:49:50 Markus Lehtonen wrote:
 The kernel package needs kern-tools-native in order for it's
 do_kernel_metadata. Thus, devtool extract for kernel in a pristine
 environment fails. With the current bb.tinfoil implementation it is not
 possible to run arbitrary bitbake commands - e.g. run
 bitbake kern-tools-native -c populate_sysroot in our case. This patch
 implements an ugly workaround for that problem, basically by hardcoding
 this dependency and running the required bitbake task(s) before tinfoil
 is initialized.
 
 [YOCTO #6658]
 
 Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
 ---
  scripts/lib/devtool/standard.py | 19 ++-
  1 file changed, 18 insertions(+), 1 deletion(-)
 
 diff --git a/scripts/lib/devtool/standard.py
 b/scripts/lib/devtool/standard.py index 3725d87..bf24e32 100644
 --- a/scripts/lib/devtool/standard.py
 +++ b/scripts/lib/devtool/standard.py
 @@ -197,6 +197,8 @@ def extract(args, config, basepath, workspace):
  Entry point for the devtool 'extract' subcommand
  import bb
 
 +_check_extract_deps(config, basepath, args.recipename)
 +
  tinfoil = setup_tinfoil()
 
  rd = _parse_recipe(config, tinfoil, args.recipename, True)
 @@ -237,6 +239,20 @@ class BbTaskExecutor(object):
  self.executed.append(func)
 
 
 +def _check_extract_deps(config, basepath, recipename):
 +HACK: Ugly workaround for making sure that requirements are met when
 +   trying to extract a package
 +tinfoil = setup_tinfoil()
 +rd = _parse_recipe(config, tinfoil, recipename, True)
 +if bb.data.inherits_class('kernel-yocto', rd):
 +tinfoil.shutdown()

Hmm, surely you need to call shutdown() in the non-kernel case as well? 
Otherwise won't the lock still be in place when this function returns and then 
setup_tinfoil() is called a second time?

 +try:
 +stdout, _ = exec_build_env_command(config.init_path, basepath,
 +   'bitbake kern-tools-native')
 +except bb.process.ExecutionError as err:
 +raise DevtoolError(Failed to build kern-tools-native:\n%s %
 +   err.stdout)
 +
  def _extract_source(srctree, keep_temp, devbranch, d):
  Extract sources of a recipe
  import bb.event
 @@ -422,7 +438,8 @@ def modify(args, config, basepath, workspace):
  raise DevtoolError(directory %s does not exist or not a directory
  (specify -x to extract source from recipe) % args.srctree)
 -
 +if args.extract:
 +_check_extract_deps(config, basepath, args.recipename)
  tinfoil = setup_tinfoil()
 
  rd = _parse_recipe(config, tinfoil, args.recipename, True)

Cheers,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 1/1] mtd-utils: add xattr PACKAGECONFIG and fix acl dependency

2015-08-27 Thread Khem Raj
On Wed, Aug 26, 2015 at 11:43 PM, Patrick Ohly patrick.o...@intel.com wrote:
 The one in bb.utils.contains()? That is there intentionally: it's for
 the xattr enabled case, in which case nothing gets added to
 EXTRA_OEMAKE.

is it required to have extra  ?
can it work without it
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 4/6] nettle: Add ptests

2015-08-27 Thread Jussi Kukkonen
Use the nettle testsuite as ptests. Skip sha1-huge-test because
it can take 20 minutes to finish.

Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
---
 ...d-target-to-only-build-tests-not-run-them.patch | 43 ++
 meta/recipes-support/nettle/files/run-ptest| 36 ++
 meta/recipes-support/nettle/nettle.inc | 21 ++-
 3 files changed, 98 insertions(+), 2 deletions(-)
 create mode 100644 
meta/recipes-support/nettle/files/Add-target-to-only-build-tests-not-run-them.patch
 create mode 100644 meta/recipes-support/nettle/files/run-ptest

diff --git 
a/meta/recipes-support/nettle/files/Add-target-to-only-build-tests-not-run-them.patch
 
b/meta/recipes-support/nettle/files/Add-target-to-only-build-tests-not-run-them.patch
new file mode 100644
index 000..9495d02
--- /dev/null
+++ 
b/meta/recipes-support/nettle/files/Add-target-to-only-build-tests-not-run-them.patch
@@ -0,0 +1,43 @@
+From 46edf01cc98db9f9feec984897836dfdd26bdc8d Mon Sep 17 00:00:00 2001
+From: Jussi Kukkonen jussi.kukko...@intel.com
+Date: Wed, 12 Aug 2015 23:27:27 +0300
+Subject: [PATCH] Add target to only build tests (not run them)
+
+Upstream-Status: ?
+
+Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com
+---
+ Makefile.in   | 3 +++
+ testsuite/Makefile.in | 2 ++
+ 2 files changed, 5 insertions(+)
+
+diff --git a/Makefile.in b/Makefile.in
+index 08efb7d..7909342 100644
+--- a/Makefile.in
 b/Makefile.in
+@@ -55,6 +55,9 @@ clean distclean mostlyclean maintainer-clean tags:
+ echo Making $@ in $$d ; (cd $$d  $(MAKE) $@); done
+   $(MAKE) $@-here
+ 
++buildtest:
++  echo Making $@ in testsuite ; (cd testsuite  $(MAKE) $@)
++
+ check-here:
+   true
+ 
+diff --git a/testsuite/Makefile.in b/testsuite/Makefile.in
+index 6bc1907..bb65bf0 100644
+--- a/testsuite/Makefile.in
 b/testsuite/Makefile.in
+@@ -116,6 +116,8 @@ $(TARGETS) $(EXTRA_TARGETS): testutils.$(OBJEXT) 
../nettle-internal.$(OBJEXT) \
+ # data.
+ VALGRIND = valgrind --error-exitcode=1 --leak-check=full --show-reachable=yes 
@IF_ASM@ --partial-loads-ok=yes
+ 
++buildtest: $(TS_ALL)
++
+ # The PATH update is for locating dlls on w*ndows.
+ check: $(TS_ALL)
+   LD_LIBRARY_PATH=../.lib PATH=../.lib:$$PATH srcdir=$(srcdir) \
+-- 
+2.1.4
+
diff --git a/meta/recipes-support/nettle/files/run-ptest 
b/meta/recipes-support/nettle/files/run-ptest
new file mode 100644
index 000..b90bed6
--- /dev/null
+++ b/meta/recipes-support/nettle/files/run-ptest
@@ -0,0 +1,36 @@
+#! /bin/sh
+
+cd testsuite
+
+failed=0
+all=0
+
+for f in *-test; do
+if [ $f = sha1-huge-test ] ; then
+echo SKIP: $f (skipped for ludicrous run time)
+continue
+fi
+
+./$f
+case $? in
+0)
+echo PASS: $f
+all=$((all + 1))
+;;
+77)
+echo SKIP: $f
+;;
+*)
+echo FAIL: $f
+failed=$((failed + 1))
+all=$((all + 1))
+;;
+esac
+done
+
+if [ $failed -eq 0 ] ; then
+  echo All $all tests passed
+else
+  echo $failed of $all tests failed
+fi
+
diff --git a/meta/recipes-support/nettle/nettle.inc 
b/meta/recipes-support/nettle/nettle.inc
index 0579b6c..fafff6d 100644
--- a/meta/recipes-support/nettle/nettle.inc
+++ b/meta/recipes-support/nettle/nettle.inc
@@ -8,19 +8,36 @@ LIC_FILES_CHKSUM = 
file://COPYING.LIB;md5=2d5025d4aa3495befef8f17206a5b0a1 \
 
 DEPENDS += gmp
 
-SRC_URI = http://www.lysator.liu.se/~nisse/archive/${BP}.tar.gz;
+SRC_URI = http://www.lysator.liu.se/~nisse/archive/${BP}.tar.gz \
+   file://Add-target-to-only-build-tests-not-run-them.patch \
+   file://run-ptest \
+   
 
 SRC_URI[md5sum] = 003d5147911317931dd453520eb234a5
 SRC_URI[sha256sum] = 
bc71ebd43435537d767799e414fce88e521b7278d48c860651216e1fc6555b40
 
 EXTRA_OECONF = --disable-openssl
 
+inherit autotools ptest
+
 do_configure_prepend() {
if [ ! -e ${S}/acinclude.m4 -a -e ${S}/aclocal.m4 ]; then
cp ${S}/aclocal.m4 ${S}/acinclude.m4
fi
 }
 
-inherit autotools
+do_compile_ptest() {
+oe_runmake buildtest
+}
+
+do_install_ptest() {
+install -d ${D}${PTEST_PATH}/testsuite/
+install ${S}/testsuite/gold-bug.txt ${D}${PTEST_PATH}/testsuite/
+install ${S}/testsuite/*-test ${D}${PTEST_PATH}/testsuite/
+# tools can be found in PATH, not in ../tools/
+sed -i -e 's|../tools/||' ${D}${PTEST_PATH}/testsuite/*-test
+install ${B}/testsuite/*-test ${D}${PTEST_PATH}/testsuite/
+}
+
 
 BBCLASSEXTEND = native nativesdk
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH V3 0/3] Add UEFI firmware for qemux86*

2015-08-27 Thread Patrick Ohly
On Tue, 2015-07-14 at 20:07 +,
leonardo.sandoval.gonza...@linux.intel.com wrote:
 From: Leonardo Sandoval leonardo.sandoval.gonza...@linux.intel.com
 
 These patches include:
 
 1. iasl recipe taken from luv-yocto repository into OE-Core (the only 
change done was the LICENSE, from Intel-ACPI to BSD | GPLv2)
 2. OVMF recipe (taken from luv-yocto repository) into OE-Core
 3. Boot script: Instrumenting runqemu to include OECORE_MACHINE_SYSROOT, 
 so the OVMF BIOS can be found.

I've tried out these patches. Mostly it worked as advertised and I'd
love to use EFI with qemu, so I'd like to see this merged.

I noticed that git format-patches from your branch followed by git
am mangles the
meta/recipes-core/ovmf/ovmf/0001-BaseTools-Force-tools-variables-to-host-toolchain.patch
 because it is a mixture of Unix line ends (patch boiler plate) and DOS line 
ends (actual patches). The file ended up with all Unix line ends, which then 
failed during do_patch. I solved that by checking out your branch and copying 
the file. Whoever merges needs to be careful here. This might also be a problem 
for combo-layer, so perhaps a solution not based on patching the makefiles may 
be needed.

When I use runqemu, it ends up invoking qemu with -vga vmware. With
that, I don't see any output from TianoCore and booting hangs. It boots
when disabling graphical output (serial nographic as parameter of
runqemu) or when explicitly selecting a different graphics
('qemuparams=-vga std'). Might be worthwhile adding to the commit
message.

It wasn't clear from the description whether one had to build ovmf or
ovmf-native - it's the former (obvious after thinking about it some
more, because the code runs on the target).

Do you happen to know how non-volatile EFI variables are handled? There
are several posts from around 2012 saying that qemu does not support
storing nvram persistently (for example, [1]). I've not seen anything
more recent directly contradicting that, but there seems to be
something, at least in Fedora [2]. That patch mentions that OVMF [...]
works in two
modes: 1) Code and UEFI variable store is mixed in one file. 

I'm probably doing something wrong (haven't tried this before), but when
I do a setvar foobar =foobar in the EFI shell, I just get a unable
to set: Invalid Parameter error, with and without -nv.

[1] http://blog.hansenpartnership.com/uefi-secure-boot/
[2] http://www.redhat.com/archives/libvir-list/2014-August/msg00960.html


-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.



-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 6/6] mirrors.bbclass: Update gnutls mirrors

2015-08-27 Thread Christopher Larson
On Thu, Aug 27, 2015 at 6:06 AM, Jussi Kukkonen jussi.kukko...@intel.com
wrote:

 * Remove mirror sites that no longer exist
 * Update the gnutls.org path so the gnupg mirror gets used

 Signed-off-by: Jussi Kukkonen jussi.kukko...@intel.com


Hmm, I can't help but wonder if these app-specific mirrors should be moved
to the recipes or classes that need them, rather than in the global default
MIRRORS..
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] runqemu-internal: Fixes unary operator expected in new TCPSERIAL_PORTNUM

2015-08-27 Thread Burton, Ross
On 27 August 2015 at 17:27, Aníbal Limón anibal.li...@linux.intel.com
wrote:

 ping


It's in the queue - ross/mut is *giant* at this point but I just want to
see master pass once with all green...

Ross
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] runqemu-internal: Fixes unary operator expected in new TCPSERIAL_PORTNUM

2015-08-27 Thread Aníbal Limón

ping

On 26/08/15 09:48, Aníbal Limón wrote:

If $TCPSERIAL_PORTNUM is empty string causes an error because
expands the expresion to,

$TCPSERIAL_PORTNUM ==  - == 

Signed-off-by: Aníbal Limón anibal.li...@linux.intel.com
---
  scripts/runqemu-internal | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/runqemu-internal b/scripts/runqemu-internal
index b317358..1b1bc9e 100755
--- a/scripts/runqemu-internal
+++ b/scripts/runqemu-internal
@@ -620,7 +620,7 @@ if [ x$QEMUOPTIONS = x ]; then
  return 1
  fi
  
-if [ $TCPSERIAL_PORTNUM !=  ]; then

+if [ $TCPSERIAL_PORTNUM !=  ]; then
  if [ $MACHINE = qemuarm64 ]; then
  QEMUOPTIONS=$QEMUOPTIONS -device virtio-serial-device -chardev 
socket,id=virtcon,port=$TCPSERIAL_PORTNUM,host=127.0.0.1 -device 
virtconsole,chardev=virtcon
  else


--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH] bind: remove dependency on bind in bind-dev

2015-08-27 Thread Ross Burton
bind doesn't ship shared libraries only static libraries, so the default
dependency on PN from PN-dev is pointless and means that an image with bind-dev
installed (via dhcp-dev's automatic dependency) ends up with named installed and
started on boot which is rarely intended.

If and when we ship bind's shared libraries we should ensure that the libraries
go into a separate package.

Also remove an old comment about --enable-exportlib.

Signed-off-by: Ross Burton ross.bur...@intel.com
---
 meta/recipes-connectivity/bind/bind_9.10.2-P3.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-connectivity/bind/bind_9.10.2-P3.bb 
b/meta/recipes-connectivity/bind/bind_9.10.2-P3.bb
index 52244b0..151eec0 100644
--- a/meta/recipes-connectivity/bind/bind_9.10.2-P3.bb
+++ b/meta/recipes-connectivity/bind/bind_9.10.2-P3.bb
@@ -24,7 +24,6 @@ SRC_URI = 
ftp://ftp.isc.org/isc/bind9/${PV}/${BPN}-${PV}.tar.gz \
 SRC_URI[md5sum] = a810d5d65fbdcf28dcda80d646913c3a
 SRC_URI[sha256sum] = 
78079a66dda455ffecfe93ef72d1ffc947f17b1c453d55ec06b860b49a5e1d4a
 
-# --enable-exportlib is necessary for building dhcp
 ENABLE_IPV6 = --enable-ipv6=${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', 
'yes', 'no', d)}
 EXTRA_OECONF =  ${ENABLE_IPV6} --with-randomdev=/dev/random --disable-threads 
\
  --disable-devpoll --disable-epoll --with-gost=no \
@@ -49,6 +48,7 @@ SYSTEMD_SERVICE_${PN} = named.service
 PARALLEL_MAKE = 
 
 RDEPENDS_${PN} = python-core
+RDEPENDS_${PN}-dev = 
 
 PACKAGE_BEFORE_PN += ${PN}-utils
 FILES_${PN}-utils = ${bindir}/host ${bindir}/dig
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH v2] bb.utils.movefile: specify dest file name

2015-08-27 Thread Benjamin Esquivel
Hey guys, I would like to get this reviewed/integrated for closing this
bug :)

Benjamin

On Fri, 2015-08-21 at 10:05 +, Benjamin Esquivel wrote:
  When moving a file via the python os.rename function it is required
  to specify the path including the file name at the end.
  Failure to provide this file name at the destination argument of the
  os.rename function raises an OSError exception.
 
  [YOCTO#8180]
 
 Signed-off-by: Benjamin Esquivel benjamin.esqui...@linux.intel.com
 ---
  bitbake/lib/bb/utils.py | 6 +-e
  1 file changed, 5 insertions(+), 1 deletion(-)
 diff --git a/bitbake/lib/bb/utils.py b/bitbake/lib/bb/utils.py
 index 5b94432..5ed8e01 100644
 --- a/bitbake/lib/bb/utils.py
 +++ b/bitbake/lib/bb/utils.py
 @@ -741,7 +741,11 @@ def movefile(src, dest, newmtime = None, sstat =
 None):
  renamefailed = 1
  if sstat[stat.ST_DEV] == dstat[stat.ST_DEV]:
  try:
 -os.rename(src, dest)
 +# os.rename needs to know the destination path with file
 name
 +srcfname = os.path.basename(src)
 +destfname = os.path.join(dest, srcfname) if
 os.path.isdir(dest) \
 +else dest
 +os.rename(src, destfname)
  renamefailed = 0
  except Exception as e:
  if e[0] != errno.EXDEV:
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] selftest/manifest.py: Test to verify rootfs manifest

2015-08-27 Thread Benjamin Esquivel
Hey Paul, thanks for looking at this, check the comments below.

On Thu, 2015-08-27 at 09:34 +0100, Paul Eggleton wrote:
 Hi Benjamin / Mariano,
 
 On Wednesday 26 August 2015 12:26:02 Benjamin Esquivel wrote:
  Adding a new test to verify if the packages in the
  manifest files actually exists in pkgdata.
   -adding a setUpClass for when more tests get created here
   -check for the paths and fail gracefully if not there
   -skip the test when there are no manifest files to check
   -debug prints for failure analysis
  
  [YOCTO#8028]
  
  Signed-off-by: Benjamin Esquivel benjamin.esqui...@linux.intel.com
  
  Signed-off-by: Mariano Lopez mariano.lo...@linux.intel.com
  ---
   meta/lib/oeqa/selftest/manifest.py | 52
  ++ 1 file changed, 52
  insertions(+)
   create mode 100644 meta/lib/oeqa/selftest/manifest.py
  
  diff --git a/meta/lib/oeqa/selftest/manifest.py
  b/meta/lib/oeqa/selftest/manifest.py new file mode 100644
  index 000..c2bc945
  --- /dev/null
  +++ b/meta/lib/oeqa/selftest/manifest.py
  @@ -0,0 +1,52 @@
  +import unittest
  +import os
  +from glob import glob
  +
  +from oeqa.selftest.base import oeSelfTest
  +from oeqa.utils.commands import get_bb_var
  +from oeqa.utils.decorators import testcase
  +
  +class VerifyManifest(oeSelfTest):
  +'''Tests for the manifest files and contents of an image'''
  +
  +@classmethod
  +def setUpClass(self):
  +
  +# get directory locations from variable values and check
  them
  +self.deploy_dir_image = get_bb_var('DEPLOY_DIR_IMAGE');
  +if not self.deploy_dir_image \
  +or not os.path.isdir(self.deploy_dir_image):
  +raise unittest.SkipTest({}: DEPLOY_DIR_IMAGE does not
  exist:
  {}\ +.format(VerifyManifest,
  self.deploy_dir_image))
  +
  +self.pkgdata_dir = get_bb_var('PKGDATA_DIR');
  +if not self.pkgdata_dir \
  +or not os.path.isdir(self.pkgdata_dir):
  +raise unittest.SkipTest({}: PKGDATA_DIR does not
  exist: {}\
  +.format(VerifyManifest, self.pkgdata_dir))
  +
  +# get the manifest files
  +# no need to try: since glob would return an empty list if
  +# the path is non-existant
  +self.manifest_files = glob(%s/*.manifest %
  self.deploy_dir_image)
  +self.log.debug(manifest files:
  {}.format(self.manifest_files)) +
 if not self.manifest_files:
  +raise unittest.SkipTest({}: No manifest files found
  in: {}\
  +.format(VerifyManifest, self.deploy_dir_image))
  +
  +
  +def test_manifest_entries(self):
  +'''Verifying the manifest entries as packages '''
  +testname = self.id().split('.')[-1]
  +rundir = os.path.join(self.pkgdata_dir, runtime-reverse)
  +
  +errmsg = ERROR: Package %s is in manifest but not in
  pkgdata
  +for manifest in self.manifest_files:
  +with open(manifest, r) as mfile:
  +for manifest_entries in mfile:
  +pkg = manifest_entries.split()[0]
  +pkgfile = os.path.join(rundir, pkg)
  +self.log.debug({}: looking for {}\
  +.format(testname, pkgfile))
  +self.assertTrue(os.path.isfile(pkgfile),
  +errmsg % pkg)
 
 Shouldn't this test actually be building an image (e.g. using
 bitbake('core-image-minimal') ) in order to ensure there's a manifest
 file for 
 it to look at? Then you can make the test fail rather than skipping
 if the file 
 isn't there or doesn't contain a small set of packages we know should
 be 
 listed.
The reason the actual build of an image was not included in the test is
because it is abstracted from it. That's why it contains checks for
when the manifests are not there it skips the test instead of failing.

This would give you the chance to write some level of abstraction that
is able to have test subjects (i.e. subject A: core-image-minimal with
systemd and ipk). Otherwise you're locking the test to a single
scenario which is usually the most common. All the corner cases are
hidden from that scope of testing.

On the other hand, if we had that design I'm talking about we could
easily have a default behavior that does exactly what you're proposing.

What do you think?
 
 
 Also while you're adding this could you add a similar test function
 for the 
 SDK (both host + target manifests).
 
I believe we could add many more tests that's why I started splitting
common tasks to the setup function of the test.

I'll add this in the next patch version.

 Paul
 
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] bind: remove dependency on bind in bind-dev

2015-08-27 Thread Khem Raj
On Thu, Aug 27, 2015 at 9:01 AM, Ross Burton ross.bur...@intel.com wrote:
 bind doesn't ship shared libraries only static libraries, so the default
 dependency on PN from PN-dev is pointless and means that an image with 
 bind-dev
 installed (via dhcp-dev's automatic dependency) ends up with named installed 
 and
 started on boot which is rarely intended.

I see similar issues in meta-oe I wish this could be abstracted out to
a general solution would be awesome
detecting if there are no .so in PN detach PN-dev from it.
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 1/5] iw: add recipe from meta-networking

2015-08-27 Thread Christopher Larson
From: Christopher Larson chris_lar...@mentor.com

iw uses cfg80211/nl80211, which is the way of the future. wireless-tools uses
WEXT, which uses ioctl, which is in deep maintenance mode. See
http://wireless.kernel.org/en/developers/Documentation/Wireless-Extensions.
Also https://wireless.wiki.kernel.org/en/users/Documentation/iw indicates The
old tool iwconfing, which uses Wireless Extensions interface, is deprecated
and it's strongly recommended to switch to iw and nl80211.

Signed-off-by: Christopher Larson chris_lar...@mentor.com
---
 sh-don-t-use-git-describe-for-versioning.patch | 43 ++
 meta/recipes-connectivity/iw/iw_4.1.bb | 23 
 2 files changed, 66 insertions(+)
 create mode 100644 
meta/recipes-connectivity/iw/iw/0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch
 create mode 100644 meta/recipes-connectivity/iw/iw_4.1.bb

diff --git 
a/meta/recipes-connectivity/iw/iw/0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch
 
b/meta/recipes-connectivity/iw/iw/0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch
new file mode 100644
index 000..e64dd0a
--- /dev/null
+++ 
b/meta/recipes-connectivity/iw/iw/0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch
@@ -0,0 +1,43 @@
+From 5310abba864cfe3a8b65af130729447604190b29 Mon Sep 17 00:00:00 2001
+From: Koen Kooi k...@dominion.thruhere.net
+Date: Tue, 29 Nov 2011 17:03:27 +0100
+Subject: [PATCH] iw: version.sh: don't use git describe for versioning
+
+It will detect top-level git repositories like the Angstrom setup-scripts and 
break.
+
+Upstream-Status: Unknown
+
+Signed-off-by: Koen Kooi k...@dominion.thruhere.net
+---
+ version.sh | 16 +---
+ 1 file changed, 1 insertion(+), 15 deletions(-)
+
+diff --git a/version.sh b/version.sh
+index 11d124b..5d423c4 100755
+--- a/version.sh
 b/version.sh
+@@ -3,21 +3,7 @@
+ VERSION=3.15
+ OUT=$1
+ 
+-if [ -d .git ]  head=`git rev-parse --verify HEAD 2/dev/null`; then
+-  git update-index --refresh --unmerged  /dev/null
+-  descr=$(git describe)
+-
+-  # on git builds check that the version number above
+-  # is correct...
+-  [ ${descr%%-*} = v$VERSION ] || exit 2
+-
+-  v=${descr#v}
+-  if git diff-index --name-only HEAD | read dummy ; then
+-  v=$v-dirty
+-  fi
+-else
+-  v=$VERSION
+-fi
++v=$VERSION
+ 
+ echo '#include iw.h'  $OUT
+ echo const char iw_version[] = \$v\;  $OUT
+-- 
+1.7.7.3
diff --git a/meta/recipes-connectivity/iw/iw_4.1.bb 
b/meta/recipes-connectivity/iw/iw_4.1.bb
new file mode 100644
index 000..e1e7c12e
--- /dev/null
+++ b/meta/recipes-connectivity/iw/iw_4.1.bb
@@ -0,0 +1,23 @@
+SUMMARY = nl80211 based CLI configuration utility for wireless devices
+DESCRIPTION = iw is a new nl80211 based CLI configuration utility for \
+wireless devices. It supports almost all new drivers that have been added \
+to the kernel recently. 
+HOMEPAGE = http://wireless.kernel.org/en/users/Documentation/iw;
+SECTION = base
+LICENSE = BSD
+LIC_FILES_CHKSUM = file://COPYING;md5=878618a5c4af25e9b93ef0be1a93f774
+
+DEPENDS = libnl pkgconfig
+
+SRC_URI = http://www.kernel.org/pub/software/network/iw/${BP}.tar.gz \
+   
file://0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch \
+
+
+SRC_URI[md5sum] = 68c282285c71c956069957e9ca10a6a7
+SRC_URI[sha256sum] = 
14bfc627b37f7f607e4ffa63a70ded15fa2ea85177f703cb17d7fe36f9c8f33d
+
+EXTRA_OEMAKE = 
+
+do_install() {
+oe_runmake DESTDIR=${D} install
+}
-- 
2.2.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 3/5] iw: obey our target path variables

2015-08-27 Thread Christopher Larson
From: Christopher Larson chris_lar...@mentor.com

Signed-off-by: Christopher Larson chris_lar...@mentor.com
---
 meta/recipes-connectivity/iw/iw_4.1.bb | 8 ++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-connectivity/iw/iw_4.1.bb 
b/meta/recipes-connectivity/iw/iw_4.1.bb
index 556af2b..8e27862 100644
--- a/meta/recipes-connectivity/iw/iw_4.1.bb
+++ b/meta/recipes-connectivity/iw/iw_4.1.bb
@@ -18,8 +18,12 @@ SRC_URI[sha256sum] = 
14bfc627b37f7f607e4ffa63a70ded15fa2ea85177f703cb17d7fe36f9
 
 inherit pkgconfig
 
-EXTRA_OEMAKE = 
+EXTRA_OEMAKE = \
+'PREFIX=${prefix}' \
+'SBINDIR=${sbindir}' \
+'MANDIR=${mandir}' \
+
 
 do_install() {
-oe_runmake DESTDIR=${D} install
+oe_runmake 'DESTDIR=${D}' install
 }
-- 
2.2.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 2/5] iw: inherit pkgconfig

2015-08-27 Thread Christopher Larson
From: Christopher Larson chris_lar...@mentor.com

We want the dep on pkgconfig-native, not pkgconfig, and the convention is to
inherit pkgconfig when running pkg-config at build time.

Signed-off-by: Christopher Larson chris_lar...@mentor.com
---
 meta/recipes-connectivity/iw/iw_4.1.bb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/meta/recipes-connectivity/iw/iw_4.1.bb 
b/meta/recipes-connectivity/iw/iw_4.1.bb
index e1e7c12e..556af2b 100644
--- a/meta/recipes-connectivity/iw/iw_4.1.bb
+++ b/meta/recipes-connectivity/iw/iw_4.1.bb
@@ -7,7 +7,7 @@ SECTION = base
 LICENSE = BSD
 LIC_FILES_CHKSUM = file://COPYING;md5=878618a5c4af25e9b93ef0be1a93f774
 
-DEPENDS = libnl pkgconfig
+DEPENDS = libnl
 
 SRC_URI = http://www.kernel.org/pub/software/network/iw/${BP}.tar.gz \

file://0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch \
@@ -16,6 +16,8 @@ SRC_URI = 
http://www.kernel.org/pub/software/network/iw/${BP}.tar.gz \
 SRC_URI[md5sum] = 68c282285c71c956069957e9ca10a6a7
 SRC_URI[sha256sum] = 
14bfc627b37f7f607e4ffa63a70ded15fa2ea85177f703cb17d7fe36f9c8f33d
 
+inherit pkgconfig
+
 EXTRA_OEMAKE = 
 
 do_install() {
-- 
2.2.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH v2 1/2] devtool: upgrade feature

2015-08-27 Thread Leonardo Sandoval



On 08/27/2015 08:29 AM, Otavio Salvador wrote:

On Thu, Aug 27, 2015 at 10:24 AM, Leonardo Sandoval
leonardo.sandoval.gonza...@linux.intel.com wrote:

On 08/26/2015 07:04 PM, Paul Eggleton wrote:

We already have code for editing recipes like this in recipeutils (and in
lib/bb/utils as well) - in fact I see you're using patch_recipe() later
on, so
why do it by hand here?



can 'oe.recipeutils.patch_recipe' patch variable's flags? I did not try but
looking at the function definition, seems like it does not.


So add this feature there if you need it.

Hi Otavio!

you are completely right. I gave it some hours today without much luck. 
What I have right now is that it appends the new checksums at the end of 
the recipe instead of replacing them. This works fine because the last 
assignment is the one remaining after the parsing stage, but not really 
elegant to have duplicate values in a single recipe.


Paul,
For this particular feature, I believe we should focus on bitbake's 
edit_metadata function instead of recipeutils's patch_recipe. In 
general, we should refactor many things on the devtool code, now that 
many stuff is just in a single file (standard.py). This seems to me like 
work for me targeting 2.1 release.





--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 4/5] iw: support and enable separate build dir

2015-08-27 Thread Christopher Larson
From: Christopher Larson chris_lar...@mentor.com

Signed-off-by: Christopher Larson chris_lar...@mentor.com
---
 .../iw/iw/separate-objdir.patch| 55 ++
 meta/recipes-connectivity/iw/iw_4.1.bb |  4 ++
 2 files changed, 59 insertions(+)
 create mode 100644 meta/recipes-connectivity/iw/iw/separate-objdir.patch

diff --git a/meta/recipes-connectivity/iw/iw/separate-objdir.patch 
b/meta/recipes-connectivity/iw/iw/separate-objdir.patch
new file mode 100644
index 000..e29e461
--- /dev/null
+++ b/meta/recipes-connectivity/iw/iw/separate-objdir.patch
@@ -0,0 +1,55 @@
+From 9e27fc2e1b3dc8c36ef6a502edffc3a3d84d9dd9 Mon Sep 17 00:00:00 2001
+From: Christopher Larson chris_lar...@mentor.com
+Date: Wed, 26 Aug 2015 17:23:48 -0700
+Subject: [PATCH] Support separation of SRCDIR and OBJDIR
+
+Typical use of VPATH to locate the sources.
+
+Signed-off-by: Christopher Larson chris_lar...@mentor.com
+
+---
+ Makefile   | 7 +--
+ version.sh | 2 +-
+ 2 files changed, 6 insertions(+), 3 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 548591a..da8d33a 100644
+--- a/Makefile
 b/Makefile
+@@ -1,5 +1,8 @@
+ MAKEFLAGS += --no-print-directory
+ 
++SRCDIR ?= $(dir $(lastword $(MAKEFILE_LIST)))
++OBJDIR ?= $(PWD)
++VPATH = $(SRCDIR)
+ PREFIX ?= /usr
+ SBINDIR ?= $(PREFIX)/sbin
+ MANDIR ?= $(PREFIX)/share/man
+@@ -95,11 +98,11 @@ VERSION_OBJS := $(filter-out version.o, $(OBJS))
+ version.c: version.sh $(patsubst %.o,%.c,$(VERSION_OBJS)) nl80211.h iw.h 
Makefile \
+   $(wildcard .git/index .git/refs/tags)
+   @$(NQ) ' GEN ' $@
+-  $(Q)./version.sh $@
++  $(Q)cd $(SRCDIR)  ./version.sh $(OBJDIR)/$@
+ 
+ %.o: %.c iw.h nl80211.h
+   @$(NQ) ' CC  ' $@
+-  $(Q)$(CC) $(CFLAGS) -c -o $@ $
++  $(Q)$(CC) -I$(SRCDIR) $(CFLAGS) -c -o $@ $
+ 
+ ifeq ($(IW_ANDROID_BUILD),)
+ iw:   $(OBJS)
+diff --git a/version.sh b/version.sh
+index 5354383..fa954cf 100755
+--- a/version.sh
 b/version.sh
+@@ -5,5 +5,5 @@ OUT=$1
+ 
+ v=$VERSION
+ 
+-echo '#include iw.h'  $OUT
++echo '#include iw.h'  $OUT
+ echo const char iw_version[] = \$v\;  $OUT
+-- 
+2.2.1
+
diff --git a/meta/recipes-connectivity/iw/iw_4.1.bb 
b/meta/recipes-connectivity/iw/iw_4.1.bb
index 8e27862..fafb0e3 100644
--- a/meta/recipes-connectivity/iw/iw_4.1.bb
+++ b/meta/recipes-connectivity/iw/iw_4.1.bb
@@ -11,6 +11,7 @@ DEPENDS = libnl
 
 SRC_URI = http://www.kernel.org/pub/software/network/iw/${BP}.tar.gz \

file://0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch \
+   file://separate-objdir.patch \
 
 
 SRC_URI[md5sum] = 68c282285c71c956069957e9ca10a6a7
@@ -19,10 +20,13 @@ SRC_URI[sha256sum] = 
14bfc627b37f7f607e4ffa63a70ded15fa2ea85177f703cb17d7fe36f9
 inherit pkgconfig
 
 EXTRA_OEMAKE = \
+-f '${S}/Makefile' \
+\
 'PREFIX=${prefix}' \
 'SBINDIR=${sbindir}' \
 'MANDIR=${mandir}' \
 
+B = ${WORKDIR}/build
 
 do_install() {
 oe_runmake 'DESTDIR=${D}' install
-- 
2.2.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 5/5] packagegroup-base: pull in iw as well as wireless-tools

2015-08-27 Thread Christopher Larson
From: Christopher Larson chris_lar...@mentor.com

As was discussed in the commit which adds iw:

iw uses cfg80211/nl80211, which is the way of the future. wireless-tools uses
WEXT, which uses ioctl, which is in deep maintenance mode. See
http://wireless.kernel.org/en/developers/Documentation/Wireless-Extensions.
Also https://wireless.wiki.kernel.org/en/users/Documentation/iw indicates The
old tool iwconfing, which uses Wireless Extensions interface, is deprecated
and it's strongly recommended to switch to iw and nl80211.

wireless-tools is kept as well for now for compatibility reasons, until we
have verified that all the network configuration mechanisms are using iw.

This adds VIRTUAL-RUNTIME_wireless-tools as a distro convenience.

Signed-off-by: Christopher Larson chris_lar...@mentor.com
---
 meta/conf/distro/include/default-providers.inc   | 1 +
 meta/recipes-core/packagegroups/packagegroup-base.bb | 6 +-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/meta/conf/distro/include/default-providers.inc 
b/meta/conf/distro/include/default-providers.inc
index 8d92c2e..9f84d5c 100644
--- a/meta/conf/distro/include/default-providers.inc
+++ b/meta/conf/distro/include/default-providers.inc
@@ -22,6 +22,7 @@ VIRTUAL-RUNTIME_update-alternatives ?= 
update-alternatives-opkg
 VIRTUAL-RUNTIME_apm ?= apm
 VIRTUAL-RUNTIME_alsa-state ?= alsa-state
 VIRTUAL-RUNTIME_getopt ?= util-linux-getopt
+VIRTUAL-RUNTIME_wireless-tools ?= iw wireless-tools
 
 #
 # Default recipe providers
diff --git a/meta/recipes-core/packagegroups/packagegroup-base.bb 
b/meta/recipes-core/packagegroups/packagegroup-base.bb
index 262d65f..c5530aa 100644
--- a/meta/recipes-core/packagegroups/packagegroup-base.bb
+++ b/meta/recipes-core/packagegroups/packagegroup-base.bb
@@ -48,6 +48,10 @@ PACKAGES = ' \
 # Override by distro if needed
 VIRTUAL-RUNTIME_keymaps ?= keymaps
 
+# Override by distro if needed. iw is the future, but wireless-tools is kept
+# for now as well for compatibility.
+VIRTUAL-RUNTIME_wireless-tools ?= iw wireless-tools
+
 #
 # packagegroup-base contain stuff needed for base system (machine related)
 #
@@ -292,7 +296,7 @@ RRECOMMENDS_packagegroup-base-ipsec = \
 #
 SUMMARY_packagegroup-base-wifi = WiFi support
 RDEPENDS_packagegroup-base-wifi = \
-wireless-tools \
+${VIRTUAL-RUNTIME_wireless-tools} \
 ${@bb.utils.contains('COMBINED_FEATURES', 'pcmcia', 'hostap-utils', '',d)} 
\
 ${@bb.utils.contains('COMBINED_FEATURES', 'pci', 'hostap-utils', '',d)} \
 wpa-supplicant
-- 
2.2.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH V3 0/3] Add UEFI firmware for qemux86*

2015-08-27 Thread Leonardo Sandoval



On 08/27/2015 08:19 AM, Patrick Ohly wrote:

On Tue, 2015-07-14 at 20:07 +,
leonardo.sandoval.gonza...@linux.intel.com wrote:

From: Leonardo Sandoval leonardo.sandoval.gonza...@linux.intel.com

These patches include:

 1. iasl recipe taken from luv-yocto repository into OE-Core (the only
change done was the LICENSE, from Intel-ACPI to BSD | GPLv2)
 2. OVMF recipe (taken from luv-yocto repository) into OE-Core
 3. Boot script: Instrumenting runqemu to include OECORE_MACHINE_SYSROOT,
 so the OVMF BIOS can be found.


I've tried out these patches. Mostly it worked as advertised and I'd
love to use EFI with qemu, so I'd like to see this merged.

I noticed that git format-patches from your branch followed by git
am mangles the
meta/recipes-core/ovmf/ovmf/0001-BaseTools-Force-tools-variables-to-host-toolchain.patch
 because it is a mixture of Unix line ends (patch boiler plate) and DOS line 
ends (actual patches). The file ended up with all Unix line ends, which then 
failed during do_patch. I solved that by checking out your branch and copying 
the file. Whoever merges needs to be careful here. This might also be a problem 
for combo-layer, so perhaps a solution not based on patching the makefiles may 
be needed.



I believe Paul has answered this. I also got some trouble, in fact the 
reason I sent V3 was because I patch incorrectly V2. it is a pain these 
line endings.



When I use runqemu, it ends up invoking qemu with -vga vmware. With
that, I don't see any output from TianoCore and booting hangs. It boots
when disabling graphical output (serial nographic as parameter of
runqemu) or when explicitly selecting a different graphics
('qemuparams=-vga std'). Might be worthwhile adding to the commit
message.


In the 3/3 commit's description, there is a command line with the 
nographic parameter. I did not test with any other kernel command line.




It wasn't clear from the description whether one had to build ovmf or
ovmf-native - it's the former (obvious after thinking about it some
more, because the code runs on the target).



you are right. It is not obvious.


Do you happen to know how non-volatile EFI variables are handled? There
are several posts from around 2012 saying that qemu does not support
storing nvram persistently (for example, [1]). I've not seen anything
more recent directly contradicting that, but there seems to be
something, at least in Fedora [2]. That patch mentions that OVMF [...]
works in two
modes: 1) Code and UEFI variable store is mixed in one file. 



sorry, I do not know.


I'm probably doing something wrong (haven't tried this before), but when
I do a setvar foobar =foobar in the EFI shell, I just get a unable
to set: Invalid Parameter error, with and without -nv.

[1] http://blog.hansenpartnership.com/uefi-secure-boot/
[2] http://www.redhat.com/archives/libvir-list/2014-August/msg00960.html



--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 0/5] Add 'iw' recipe and include in packagegroup-base

2015-08-27 Thread Christopher Larson
From: Christopher Larson chris_lar...@mentor.com

iw uses cfg80211/nl80211, which is the way of the future. wireless-tools uses
WEXT, which uses ioctl, which is in deep maintenance mode. See
http://wireless.kernel.org/en/developers/Documentation/Wireless-Extensions.
Also https://wireless.wiki.kernel.org/en/users/Documentation/iw indicates The
old tool iwconfing, which uses Wireless Extensions interface, is deprecated
and it's strongly recommended to switch to iw and nl80211.

See also the mailing list thread '[OE-core] iw in place of wireless-tools'.

The following changes since commit f07045fcae859c902434062d1725f1348f42d1dd:

  oeqa/oetest.py: add better package search for hasPackage() (2015-08-26 
08:26:37 +0100)

are available in the git repository at:

  git://github.com/kergoth/openembedded-core add-iw
  https://github.com/kergoth/openembedded-core/tree/add-iw

Christopher Larson (5):
  iw: add recipe from meta-networking
  iw: inherit pkgconfig
  iw: obey our target path variables
  iw: support and enable separate build dir
  packagegroup-base: pull in iw as well as wireless-tools

 meta/conf/distro/include/default-providers.inc |  1 +
 sh-don-t-use-git-describe-for-versioning.patch | 43 +
 .../iw/iw/separate-objdir.patch| 55 ++
 meta/recipes-connectivity/iw/iw_4.1.bb | 33 +
 .../packagegroups/packagegroup-base.bb |  6 ++-
 5 files changed, 137 insertions(+), 1 deletion(-)
 create mode 100644 
meta/recipes-connectivity/iw/iw/0001-iw-version.sh-don-t-use-git-describe-for-versioning.patch
 create mode 100644 meta/recipes-connectivity/iw/iw/separate-objdir.patch
 create mode 100644 meta/recipes-connectivity/iw/iw_4.1.bb

-- 
2.2.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] mtd-utils: add acl dependency

2015-08-27 Thread Pushpal Sidhu
I see that there is a pending patch posted today to address this
(subject: OE-core] [PATCH 1/1] mtd-utils: add xattr PACKAGECONFIG and
fix acl dependency). Sorry for the noise.

- Pushpal

On Thu, Aug 27, 2015 at 3:22 PM, Pushpal Sidhu psi...@gateworks.com wrote:
 Without this DEPEND, build will break for mtd-utils-ubifs as shown below:
...
CC  mkfs.jffs2.o
  mkfs.jffs2.c:70:21: fatal error: sys/acl.h: No such file or directory
   #include sys/acl.h

 This was introduced in commit cbf8dcc9f326faca0fbc8efe52f2920022576631 when
 reintroducing xattr support.

 Signed-off-by: Pushpal Sidhu psi...@gateworks.com
 ---
  meta/recipes-devtools/mtd/mtd-utils_git.bb | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

 diff --git a/meta/recipes-devtools/mtd/mtd-utils_git.bb 
 b/meta/recipes-devtools/mtd/mtd-utils_git.bb
 index 8d4892a..72ce9ed 100644
 --- a/meta/recipes-devtools/mtd/mtd-utils_git.bb
 +++ b/meta/recipes-devtools/mtd/mtd-utils_git.bb
 @@ -5,7 +5,7 @@ LICENSE = GPLv2+
  LIC_FILES_CHKSUM = file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
  
 file://include/common.h;beginline=1;endline=17;md5=ba05b07912a44ea2bf81ce409380049c

 -DEPENDS = zlib lzo e2fsprogs util-linux
 +DEPENDS = zlib lzo e2fsprogs util-linux acl

  PV = 1.5.1+git${SRCPV}

 --
 2.5.0

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH] mtd-utils: add acl dependency

2015-08-27 Thread Pushpal Sidhu
Without this DEPEND, build will break for mtd-utils-ubifs as shown below:
   ...
   CC  mkfs.jffs2.o
 mkfs.jffs2.c:70:21: fatal error: sys/acl.h: No such file or directory
  #include sys/acl.h

This was introduced in commit cbf8dcc9f326faca0fbc8efe52f2920022576631 when
reintroducing xattr support.

Signed-off-by: Pushpal Sidhu psi...@gateworks.com
---
 meta/recipes-devtools/mtd/mtd-utils_git.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-devtools/mtd/mtd-utils_git.bb 
b/meta/recipes-devtools/mtd/mtd-utils_git.bb
index 8d4892a..72ce9ed 100644
--- a/meta/recipes-devtools/mtd/mtd-utils_git.bb
+++ b/meta/recipes-devtools/mtd/mtd-utils_git.bb
@@ -5,7 +5,7 @@ LICENSE = GPLv2+
 LIC_FILES_CHKSUM = file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3 \
 
file://include/common.h;beginline=1;endline=17;md5=ba05b07912a44ea2bf81ce409380049c
 
-DEPENDS = zlib lzo e2fsprogs util-linux
+DEPENDS = zlib lzo e2fsprogs util-linux acl
 
 PV = 1.5.1+git${SRCPV}
 
-- 
2.5.0

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH] gcc-source: exlude from world

2015-08-27 Thread Randy MacLeod
Exclude all versions of gcc-source from world builds so that:
   bitbake -c stage world
will work. gcc-source deletes most bitbake build stages
since it is a source-only package.

Signed-off-by: Randy MacLeod randy.macl...@windriver.com
---
 meta/recipes-devtools/gcc/gcc-source_4.8.bb | 2 ++
 meta/recipes-devtools/gcc/gcc-source_4.9.bb | 2 ++
 meta/recipes-devtools/gcc/gcc-source_5.2.bb | 2 ++
 3 files changed, 6 insertions(+)

diff --git a/meta/recipes-devtools/gcc/gcc-source_4.8.bb 
b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_4.8.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
@@ -1,2 +1,4 @@
 require recipes-devtools/gcc/gcc-${PV}.inc
 require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1
diff --git a/meta/recipes-devtools/gcc/gcc-source_4.9.bb 
b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_4.9.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
@@ -1,2 +1,4 @@
 require recipes-devtools/gcc/gcc-${PV}.inc
 require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1
diff --git a/meta/recipes-devtools/gcc/gcc-source_5.2.bb 
b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_5.2.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
@@ -1,2 +1,4 @@
 require recipes-devtools/gcc/gcc-${PV}.inc
 require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1
-- 
2.4.2

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 5/5] packagegroup-base: pull in iw as well as wireless-tools

2015-08-27 Thread Khem Raj

 On Aug 27, 2015, at 11:48 AM, Christopher Larson kerg...@gmail.com wrote:
 
 From: Christopher Larson chris_lar...@mentor.com
 
 As was discussed in the commit which adds iw:
 
 iw uses cfg80211/nl80211, which is the way of the future. wireless-tools uses
 WEXT, which uses ioctl, which is in deep maintenance mode. See
 http://wireless.kernel.org/en/developers/Documentation/Wireless-Extensions.
 Also https://wireless.wiki.kernel.org/en/users/Documentation/iw indicates The
 old tool iwconfing, which uses Wireless Extensions interface, is deprecated
 and it's strongly recommended to switch to iw and nl80211.
 
 wireless-tools is kept as well for now for compatibility reasons, until we
 have verified that all the network configuration mechanisms are using iw.
 
 This adds VIRTUAL-RUNTIME_wireless-tools as a distro convenience.
 
 Signed-off-by: Christopher Larson chris_lar...@mentor.com
 ---
 meta/conf/distro/include/default-providers.inc   | 1 +
 meta/recipes-core/packagegroups/packagegroup-base.bb | 6 +-
 2 files changed, 6 insertions(+), 1 deletion(-)
 
 diff --git a/meta/conf/distro/include/default-providers.inc 
 b/meta/conf/distro/include/default-providers.inc
 index 8d92c2e..9f84d5c 100644
 --- a/meta/conf/distro/include/default-providers.inc
 +++ b/meta/conf/distro/include/default-providers.inc
 @@ -22,6 +22,7 @@ VIRTUAL-RUNTIME_update-alternatives ?= 
 update-alternatives-opkg
 VIRTUAL-RUNTIME_apm ?= apm
 VIRTUAL-RUNTIME_alsa-state ?= alsa-state
 VIRTUAL-RUNTIME_getopt ?= util-linux-getopt
 +VIRTUAL-RUNTIME_wireless-tools ?= iw wireless-tools
 
 #
 # Default recipe providers
 diff --git a/meta/recipes-core/packagegroups/packagegroup-base.bb 
 b/meta/recipes-core/packagegroups/packagegroup-base.bb
 index 262d65f..c5530aa 100644
 --- a/meta/recipes-core/packagegroups/packagegroup-base.bb
 +++ b/meta/recipes-core/packagegroups/packagegroup-base.bb
 @@ -48,6 +48,10 @@ PACKAGES = ' \
 # Override by distro if needed
 VIRTUAL-RUNTIME_keymaps ?= keymaps
 
 +# Override by distro if needed. iw is the future, but wireless-tools is kept
 +# for now as well for compatibility.
 +VIRTUAL-RUNTIME_wireless-tools ?= iw wireless-tools”

wouldn’t the define from default-providers.inc be enough ?

 +
 #
 # packagegroup-base contain stuff needed for base system (machine related)
 #
 @@ -292,7 +296,7 @@ RRECOMMENDS_packagegroup-base-ipsec = \
 #
 SUMMARY_packagegroup-base-wifi = WiFi support
 RDEPENDS_packagegroup-base-wifi = \
 -wireless-tools \
 +${VIRTUAL-RUNTIME_wireless-tools} \
 ${@bb.utils.contains('COMBINED_FEATURES', 'pcmcia', 'hostap-utils', 
 '',d)} \
 ${@bb.utils.contains('COMBINED_FEATURES', 'pci', 'hostap-utils', '',d)} \
 wpa-supplicant
 --
 2.2.1
 
 --
 ___
 Openembedded-core mailing list
 Openembedded-core@lists.openembedded.org
 http://lists.openembedded.org/mailman/listinfo/openembedded-core



signature.asc
Description: Message signed with OpenPGP using GPGMail
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] gcc-source: exlude from world

2015-08-27 Thread Khem Raj
On Thu, Aug 27, 2015 at 8:17 PM, Randy MacLeod
randy.macl...@windriver.com wrote:

 I've sent the parent email to fix
 $ bitbake -c stage world.
 I've confirmed that my change works for:
 $ bitbake -c configure world

 I wasn't sure if I should leave gcc-source as
 is or change it to be similar to kernel-devsrc
 because meta/recipes-devtools/gcc/gcc-source.inc does:

 deltask do_configure
 deltask do_compile
 deltask do_package

if a task is deleted and you do -c that-task then you should get an
error. deltask would create no stamps as opposed to noop tasks. May be
it can be turned into warning ( not convinced for that too)
but excluding it world doesn't sound a good solution here.

 ...

 whereas meta/recipes-kernel/linux/kernel-devsrc.bb does:
 # There's nothing to do here, except install the source where we can package
 it
 do_fetch[noexec] = 1
 do_unpack[noexec] = 1
 do_patch[noexec] = 1
 ...

 The kernel-devsrc approach doesn't break world builds
 but it's probably slightly less efficient.

 Also do people care about consistency in naming:
   gcc-source.inc vs
   kernel-devsrc.bb
 ? There are only two such 'source' packages so it's not a big deal.

 ../Randy



 On 2015-08-27 11:09 PM, Randy MacLeod wrote:

 Exclude all versions of gcc-source from world builds so that:
 bitbake -c stage world
 will work. gcc-source deletes most bitbake build stages
 since it is a source-only package.

 Signed-off-by: Randy MacLeod randy.macl...@windriver.com
 ---
   meta/recipes-devtools/gcc/gcc-source_4.8.bb | 2 ++
   meta/recipes-devtools/gcc/gcc-source_4.9.bb | 2 ++
   meta/recipes-devtools/gcc/gcc-source_5.2.bb | 2 ++
   3 files changed, 6 insertions(+)

 diff --git a/meta/recipes-devtools/gcc/gcc-source_4.8.bb
 b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
 index 234b82e..b890fa3 100644
 --- a/meta/recipes-devtools/gcc/gcc-source_4.8.bb
 +++ b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
 @@ -1,2 +1,4 @@
   require recipes-devtools/gcc/gcc-${PV}.inc
   require recipes-devtools/gcc/gcc-source.inc
 +
 +EXCLUDE_FROM_WORLD = 1
 diff --git a/meta/recipes-devtools/gcc/gcc-source_4.9.bb
 b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
 index 234b82e..b890fa3 100644
 --- a/meta/recipes-devtools/gcc/gcc-source_4.9.bb
 +++ b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
 @@ -1,2 +1,4 @@
   require recipes-devtools/gcc/gcc-${PV}.inc
   require recipes-devtools/gcc/gcc-source.inc
 +
 +EXCLUDE_FROM_WORLD = 1
 diff --git a/meta/recipes-devtools/gcc/gcc-source_5.2.bb
 b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
 index 234b82e..b890fa3 100644
 --- a/meta/recipes-devtools/gcc/gcc-source_5.2.bb
 +++ b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
 @@ -1,2 +1,4 @@
   require recipes-devtools/gcc/gcc-${PV}.inc
   require recipes-devtools/gcc/gcc-source.inc
 +
 +EXCLUDE_FROM_WORLD = 1



 --
 # Randy MacLeod. SMTS, Linux, Wind River
 Direct: 613.963.1350 | 350 Terry Fox Drive, Suite 200, Ottawa, ON, Canada,
 K2K 2W5

 --
 ___
 Openembedded-core mailing list
 Openembedded-core@lists.openembedded.org
 http://lists.openembedded.org/mailman/listinfo/openembedded-core
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [RFC PATCH 1/2] android-tools: import android-tools from meta-smartphone into oe-core

2015-08-27 Thread Khem Raj
On Wed, Aug 26, 2015 at 8:48 AM, Nicolas Dechesne
nicolas.deche...@linaro.org wrote:
 The following changes were done to trim down the recipe size:
 * removed adbd support
 * removed android-tools-conf

 The main idea is to keep only what is strictly needed for make_ext4fs tool.

 Signed-off-by: Nicolas Dechesne nicolas.deche...@linaro.org
 ---
  .../android-tools/disable-selinux-support.patch| 137 
 +
  .../android-tools/reboot-syscall.patch |  25 
  .../android-tools/remove-libselinux.patch  |  13 ++
  .../android-tools/android-tools_4.2.2.bb   |  51 
  4 files changed, 226 insertions(+)
  create mode 100644 
 meta/recipes-devtools/android-tools/android-tools/disable-selinux-support.patch
  create mode 100644 
 meta/recipes-devtools/android-tools/android-tools/reboot-syscall.patch
  create mode 100644 
 meta/recipes-devtools/android-tools/android-tools/remove-libselinux.patch
  create mode 100644 meta/recipes-devtools/android-tools/android-tools_4.2.2.bb

 diff --git 
 a/meta/recipes-devtools/android-tools/android-tools/disable-selinux-support.patch
  
 b/meta/recipes-devtools/android-tools/android-tools/disable-selinux-support.patch
 new file mode 100644
 index 000..738f575
 --- /dev/null
 +++ 
 b/meta/recipes-devtools/android-tools/android-tools/disable-selinux-support.patch
 @@ -0,0 +1,137 @@
 +diff --git a/extras/ext4_utils/make_ext4fs.c 
 b/extras/ext4_utils/make_ext4fs.c
 +index b2d1426..94e92d6 100644
 +--- a/extras/ext4_utils/make_ext4fs.c
  b/extras/ext4_utils/make_ext4fs.c
 +@@ -59,9 +59,11 @@
 +
 + #else
 +
 ++#if 0
 + #include selinux/selinux.h
 + #include selinux/label.h
 + #include selinux/android.h
 ++#endif
 +

Can this be config,ed out insread of if 0 ?

 + #define O_BINARY 0
 +
 +@@ -178,6 +180,7 @@ static u32 build_directory_structure(const char 
 *full_path, const char *dir_path
 +   error(can't set android permissions - built without 
 android support);
 + #endif
 +   }
 ++#if 0
 + #ifndef USE_MINGW
 +   if (sehnd) {
 +   if (selabel_lookup(sehnd, dentries[i].secon, 
 dentries[i].path, stat.st_mode)  0) {
 +@@ -188,6 +191,7 @@ static u32 build_directory_structure(const char 
 *full_path, const char *dir_path
 +   printf(Labeling %s as %s\n, 
 dentries[i].path, dentries[i].secon);
 +   }
 + #endif
 ++#endif
 +
 +   if (S_ISREG(stat.st_mode)) {
 +   dentries[i].file_type = EXT4_FT_REG_FILE;
 +@@ -229,10 +233,12 @@ static u32 build_directory_structure(const char 
 *full_path, const char *dir_path
 +   dentries[0].file_type = EXT4_FT_DIR;
 +   dentries[0].uid = 0;
 +   dentries[0].gid = 0;
 ++#if 0
 +   if (sehnd) {
 +   if (selabel_lookup(sehnd, dentries[0].secon, 
 dentries[0].path, dentries[0].mode)  0)
 +   error(cannot lookup security context for 
 %s, dentries[0].path);
 +   }
 ++#endif
 +   entries++;
 +   dirs++;
 +   }
 +@@ -270,9 +276,11 @@ static u32 build_directory_structure(const char 
 *full_path, const char *dir_path
 +   dentries[i].mtime);
 +   if (ret)
 +   error(failed to set permissions on %s\n, 
 dentries[i].path);
 ++#if 0
 +   ret = inode_set_selinux(entry_inode, dentries[i].secon);
 +   if (ret)
 +   error(failed to set SELinux context on %s\n, 
 dentries[i].path);
 ++#endif
 +
 +   free(dentries[i].path);
 +   free(dentries[i].full_path);
 +@@ -562,6 +570,7 @@ int make_ext4fs_internal(int fd, const char *_directory,
 +   root_mode = S_IRWXU | S_IRGRP | S_IXGRP | S_IROTH | S_IXOTH;
 +   inode_set_permissions(root_inode_num, root_mode, 0, 0, 0);
 +
 ++#if 0
 + #ifndef USE_MINGW
 +   if (sehnd) {
 +   char *secontext = NULL;
 +@@ -578,6 +587,7 @@ int make_ext4fs_internal(int fd, const char *_directory,
 +   freecon(secontext);
 +   }
 + #endif
 ++#endif
 +
 +   ext4_update_free();
 +
 +diff --git a/extras/ext4_utils/make_ext4fs_main.c 
 b/extras/ext4_utils/make_ext4fs_main.c
 +index b6c740d..ce31764 100644
 +--- a/extras/ext4_utils/make_ext4fs_main.c
  b/extras/ext4_utils/make_ext4fs_main.c
 +@@ -29,6 +29,7 @@
 + #include private/android_filesystem_config.h
 + #endif
 +
 ++#if 0
 + #ifndef USE_MINGW
 + #include selinux/selinux.h
 + #include selinux/label.h
 +@@ -36,6 +37,7 @@
 + #else
 + struct selabel_handle;
 + #endif
 ++#endif
 +
 + #include make_ext4fs.h
 + #include ext4_utils.h
 +@@ -72,9 +74,11 @@ int main(int argc, char **argv)
 +   int exitcode;
 +   int verbose = 0;
 +   struct selabel_handle *sehnd = NULL;
 ++#if 0
 + #ifndef USE_MINGW
 +   struct selinux_opt seopts[] = { { SELABEL_OPT_PATH,  } };
 + #endif
 ++#endif
 +
 +   while 

Re: [OE-core] default gui with core-image-weston?

2015-08-27 Thread Khem Raj

 On Aug 27, 2015, at 9:36 PM, Arslan, Fahad fahad_ars...@mentor.com wrote:
 
 Hi,
 
 I'm looking for weston based image recipe that provides GUI, so if I build 
 core-image-weston will it provide any graphical interface on display attached 
 to the target.
 

yes



signature.asc
Description: Message signed with OpenPGP using GPGMail
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 1/3] dbus: merge .bb and .inc

2015-08-27 Thread Khem Raj
On Thu, Aug 27, 2015 at 2:12 AM, Andrew Shadura
andrew.shad...@collabora.co.uk wrote:
 The split is no longer necessary, and only makes it more complicated to
 do changes in external layers.

 Signed-off-by: Andrew Shadura andrew.shad...@collabora.co.uk
 ---
  meta/recipes-core/dbus/dbus.inc   | 170 -
  meta/recipes-core/dbus/dbus_1.8.20.bb | 171 
 +-
  2 files changed, 170 insertions(+), 171 deletions(-)
  delete mode 100644 meta/recipes-core/dbus/dbus.inc

can you send patch generated with -M 1


 diff --git a/meta/recipes-core/dbus/dbus.inc b/meta/recipes-core/dbus/dbus.inc
 deleted file mode 100644
 index 3971081..000
 --- a/meta/recipes-core/dbus/dbus.inc
 +++ /dev/null
 @@ -1,170 +0,0 @@
 -SUMMARY = D-Bus message bus
 -DESCRIPTION = D-Bus is a message bus system, a simple way for applications 
 to talk to one another. In addition to interprocess communication, D-Bus 
 helps coordinate process lifecycle; it makes it simple and reliable to code a 
 \single instance\ application or daemon, and to launch applications and 
 daemons on demand when their services are needed.
 -HOMEPAGE = http://dbus.freedesktop.org;
 -SECTION = base
 -LICENSE = AFL-2 | GPLv2+
 -LIC_FILES_CHKSUM = file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
 -
 file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c
 -DEPENDS = expat virtual/libintl
 -RDEPENDS_dbus_class-native = 
 -RDEPENDS_dbus_class-nativesdk = 
 -PACKAGES += ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', '${PN}-ptest', 
 '', d)}
 -ALLOW_EMPTY_dbus-ptest = 1
 -RDEPENDS_dbus-ptest_class-target = dbus-test-ptest
 -
 -SRC_URI = http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
 -   file://tmpdir.patch \
 -   file://dbus-1.init \
 -   file://os-test.patch \
 -   file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
 -
 -
 -inherit useradd autotools pkgconfig gettext update-rc.d
 -
 -INITSCRIPT_NAME = dbus-1
 -INITSCRIPT_PARAMS = start 02 5 3 2 . stop 20 0 1 6 .
 -
 -python __anonymous() {
 -if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
 -d.setVar(INHIBIT_UPDATERCD_BBCLASS, 1)
 -}
 -
 -USERADD_PACKAGES = ${PN}
 -GROUPADD_PARAM_${PN} = -r netdev
 -USERADD_PARAM_${PN} = --system --home ${localstatedir}/lib/dbus \
 -   --no-create-home --shell /bin/false \
 -   --user-group messagebus
 -
 -CONFFILES_${PN} = ${sysconfdir}/dbus-1/system.conf 
 ${sysconfdir}/dbus-1/session.conf
 -
 -DEBIANNAME_${PN} = dbus-1
 -
 -PACKAGES =+ ${PN}-lib
 -
 -OLDPKGNAME = dbus-x11
 -OLDPKGNAME_class-nativesdk = 
 -
 -# for compatibility
 -RPROVIDES_${PN} = ${OLDPKGNAME}
 -RREPLACES_${PN} += ${OLDPKGNAME}
 -
 -FILES_${PN} = ${bindir}/dbus-daemon* \
 -   ${bindir}/dbus-uuidgen \
 -   ${bindir}/dbus-cleanup-sockets \
 -   ${bindir}/dbus-send \
 -   ${bindir}/dbus-monitor \
 -   ${bindir}/dbus-launch \
 -   ${bindir}/dbus-run-session \
 -   ${libexecdir}/dbus* \
 -   ${sysconfdir} \
 -   ${localstatedir} \
 -   ${datadir}/dbus-1/services \
 -   ${datadir}/dbus-1/system-services \
 -   ${systemd_unitdir}/system/
 -FILES_${PN}-lib = ${libdir}/lib*.so.*
 -RRECOMMENDS_${PN}-lib = ${PN}
 -FILES_${PN}-dev += ${libdir}/dbus-1.0/include ${bindir}/dbus-glib-tool
 -
 -pkg_postinst_dbus() {
 -   # If both systemd and sysvinit are enabled, mask the dbus-1 init 
 script
 -if ${@bb.utils.contains('DISTRO_FEATURES','systemd 
 sysvinit','true','false',d)}; then
 -   if [ -n $D ]; then
 -   OPTS=--root=$D
 -   fi
 -   systemctl $OPTS mask dbus-1.service
 -   fi
 -
 -   if [ -z $D ]  [ -e /etc/init.d/populate-volatile.sh ] ; then
 -   /etc/init.d/populate-volatile.sh update
 -   fi
 -}
 -
 -EXTRA_OECONF = --disable-tests \
 ---disable-xml-docs \
 ---disable-doxygen-docs \
 ---disable-libaudit \
 ---disable-systemd \
 ---without-dbus-glib
 -
 -EXTRA_OECONF_append_class-native =  --disable-selinux
 -
 -PACKAGECONFIG ??= ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 
 'systemd', '', d)} \
 -   ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', 
 d)}
 -PACKAGECONFIG_class-native = 
 -PACKAGECONFIG_class-nativesdk = 
 -
 -# Would like to --enable-systemd but that's a circular build-dependency 
 between
 -# systemd-dbus
 -PACKAGECONFIG[systemd] = 
 --with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir
 -PACKAGECONFIG[x11] = --with-x --enable-x11-autolaunch,--without-x 
 --disable-x11-autolaunch, virtual/libx11 libsm
 -
 -do_install() {
 -   autotools_do_install
 -
 -   if 

Re: [OE-core] [PATCH] libvorbis: remove legacy options

2015-08-27 Thread Khem Raj

 On Aug 27, 2015, at 7:46 AM, Stefan Müller-Klieser 
 s.mueller-klie...@phytec.de wrote:
 
 Those code fragments date back to ancient times. EXTRA_OECONF is not
 required anymore and we should give gcc another try to do it right.
 Testing on cortex-a8 with thumb and -O2 reveals a performance boost of
 82 percent during encoding in comparison to -O0. -O4 gives another 7
 percent.
 

looks good.

 Signed-off-by: Stefan Müller-Klieser s.mueller-klie...@phytec.de
 ---
 - this requires patch 0fe770ef9817319bb82 from master-next. It is
  already for version 1.3.5
 
 meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb | 7 ---
 1 file changed, 7 deletions(-)
 
 diff --git a/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb 
 b/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
 index b7a0667..636e0f3 100644
 --- a/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
 +++ b/meta/recipes-multimedia/libvorbis/libvorbis_1.3.5.bb
 @@ -15,10 +15,3 @@ SRC_URI[md5sum] = 28cb28097c07a735d6af56e598e1c90f
 SRC_URI[sha256sum] = 
 54f94a9527ff0a88477be0a71c0bab09a4c3febe0ed878b24824906cd4b0e1d1
 
 inherit autotools pkgconfig
 -
 -# vorbisfile.c reveals a problem in the gcc register spilling for the
 -# thumb instruction set...
 -FULL_OPTIMIZATION_thumb = -O0
 -
 -EXTRA_OECONF = --with-ogg-libraries=${STAGING_LIBDIR} \
 ---with-ogg-includes=${STAGING_INCDIR}
 --
 1.9.1
 
 --
 ___
 Openembedded-core mailing list
 Openembedded-core@lists.openembedded.org
 http://lists.openembedded.org/mailman/listinfo/openembedded-core



signature.asc
Description: Message signed with OpenPGP using GPGMail
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] default gui with core-image-weston?

2015-08-27 Thread Arslan, Fahad
Hi,

I'm looking for weston based image recipe that provides GUI, so if I build 
core-image-weston will it provide any graphical interface on display attached 
to the target.

Thanks,
Fahad
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] gcc-source: exlude from world

2015-08-27 Thread Saul Wold

On 08/27/2015 08:09 PM, Randy MacLeod wrote:

Exclude all versions of gcc-source from world builds so that:
bitbake -c stage world
will work. gcc-source deletes most bitbake build stages
since it is a source-only package.


I think this is missing a [YOCTO #7878] as this is trying to address 
that bug, correct?


Sau!



Signed-off-by: Randy MacLeod randy.macl...@windriver.com
---
  meta/recipes-devtools/gcc/gcc-source_4.8.bb | 2 ++
  meta/recipes-devtools/gcc/gcc-source_4.9.bb | 2 ++
  meta/recipes-devtools/gcc/gcc-source_5.2.bb | 2 ++
  3 files changed, 6 insertions(+)

diff --git a/meta/recipes-devtools/gcc/gcc-source_4.8.bb 
b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_4.8.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
@@ -1,2 +1,4 @@
  require recipes-devtools/gcc/gcc-${PV}.inc
  require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1
diff --git a/meta/recipes-devtools/gcc/gcc-source_4.9.bb 
b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_4.9.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
@@ -1,2 +1,4 @@
  require recipes-devtools/gcc/gcc-${PV}.inc
  require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1
diff --git a/meta/recipes-devtools/gcc/gcc-source_5.2.bb 
b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_5.2.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
@@ -1,2 +1,4 @@
  require recipes-devtools/gcc/gcc-${PV}.inc
  require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1


--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] gcc-source: exlude from world

2015-08-27 Thread Randy MacLeod


I've sent the parent email to fix
$ bitbake -c stage world.
I've confirmed that my change works for:
$ bitbake -c configure world

I wasn't sure if I should leave gcc-source as
is or change it to be similar to kernel-devsrc
because meta/recipes-devtools/gcc/gcc-source.inc does:

deltask do_configure
deltask do_compile
deltask do_package
...

whereas meta/recipes-kernel/linux/kernel-devsrc.bb does:
# There's nothing to do here, except install the source where we can 
package it

do_fetch[noexec] = 1
do_unpack[noexec] = 1
do_patch[noexec] = 1
...

The kernel-devsrc approach doesn't break world builds
but it's probably slightly less efficient.

Also do people care about consistency in naming:
  gcc-source.inc vs
  kernel-devsrc.bb
? There are only two such 'source' packages so it's not a big deal.

../Randy


On 2015-08-27 11:09 PM, Randy MacLeod wrote:

Exclude all versions of gcc-source from world builds so that:
bitbake -c stage world
will work. gcc-source deletes most bitbake build stages
since it is a source-only package.

Signed-off-by: Randy MacLeod randy.macl...@windriver.com
---
  meta/recipes-devtools/gcc/gcc-source_4.8.bb | 2 ++
  meta/recipes-devtools/gcc/gcc-source_4.9.bb | 2 ++
  meta/recipes-devtools/gcc/gcc-source_5.2.bb | 2 ++
  3 files changed, 6 insertions(+)

diff --git a/meta/recipes-devtools/gcc/gcc-source_4.8.bb 
b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_4.8.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_4.8.bb
@@ -1,2 +1,4 @@
  require recipes-devtools/gcc/gcc-${PV}.inc
  require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1
diff --git a/meta/recipes-devtools/gcc/gcc-source_4.9.bb 
b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_4.9.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_4.9.bb
@@ -1,2 +1,4 @@
  require recipes-devtools/gcc/gcc-${PV}.inc
  require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1
diff --git a/meta/recipes-devtools/gcc/gcc-source_5.2.bb 
b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
index 234b82e..b890fa3 100644
--- a/meta/recipes-devtools/gcc/gcc-source_5.2.bb
+++ b/meta/recipes-devtools/gcc/gcc-source_5.2.bb
@@ -1,2 +1,4 @@
  require recipes-devtools/gcc/gcc-${PV}.inc
  require recipes-devtools/gcc/gcc-source.inc
+
+EXCLUDE_FROM_WORLD = 1




--
# Randy MacLeod. SMTS, Linux, Wind River
Direct: 613.963.1350 | 350 Terry Fox Drive, Suite 200, Ottawa, ON, 
Canada, K2K 2W5

--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 1/1] mtd-utils: add xattr PACKAGECONFIG and fix acl dependency

2015-08-27 Thread Patrick Ohly
On Wed, 2015-08-26 at 12:02 -0700, Andre McCurdy wrote:
 On Wed, Aug 26, 2015 at 9:10 AM, Patrick Ohly patrick.o...@intel.com wrote:
  The unconditional removal of -DWITHOUT_XATTR accidentally introduced a
  compile-time dependency on acl, because sys/acl.h gets
  included. This caused random compile failures.
 
  To fix this, we introduce a proper PACKAGECONFIG for the xattr
  support, with the distro's xattr feature determining the
  default. Setting the define must be done with custom code because
  PACKAGECONFIG can only influence configure parameters.
 
  The acl distro feature is not checked because although enabling
  xattr support now triggers a build of acl, nothing from it will not
  get included in the resulting target image.
 
 Typo?

Yes, the not needs to be removed. Can whoever merges the patch fix
that or should I send a revised version?

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.



-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 1/1] mtd-utils: add xattr PACKAGECONFIG and fix acl dependency

2015-08-27 Thread Patrick Ohly
On Wed, 2015-08-26 at 12:16 -0700, Khem Raj wrote:
 
 On Aug 26, 2015 9:11 AM, Patrick Ohly patrick.o...@intel.com
 wrote:
  +EXTRA_OEMAKE = 'CC=${CC}' 'RANLIB=${RANLIB}' 'AR=${AR}' 'CFLAGS=${CFLAGS} 
  ${@bb.utils.contains('PACKAGECONFIG', 'xattr', '', '-DWITHOUT_XATTR', d)} 
  -I${S}/include' 'BUILDDIR=${S}'
 
 Do I see a spurious  in the middle

The one in bb.utils.contains()? That is there intentionally: it's for
the xattr enabled case, in which case nothing gets added to
EXTRA_OEMAKE.

-- 
Best Regards, Patrick Ohly

The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.



-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 2/3] dbus: update the recipes to 1.10.0

2015-08-27 Thread Jussi Kukkonen
On 27 August 2015 at 12:12, Andrew Shadura andrew.shad...@collabora.co.uk
wrote:

 Signed-off-by: Andrew Shadura andrew.shad...@collabora.co.uk
 ---
  meta/recipes-core/dbus/dbus-test_1.10.0.bb  |  61 
  meta/recipes-core/dbus/dbus-test_1.8.20.bb  |  61 
  meta/recipes-core/dbus/dbus/python-config.patch |  13 +-
  meta/recipes-core/dbus/dbus_1.10.0.bb   | 177

  meta/recipes-core/dbus/dbus_1.8.20.bb   | 173
---
  5 files changed, 245 insertions(+), 240 deletions(-)


Could you please configure your git so that it tries harder to find
renames: it's hard to see the changes otherwise. Something like this would
work in git config (the other option is renames=copies):


[diff]
renames = true


Thanks,
  Jussi
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 2/3] dbus: update the recipes to 1.10.0

2015-08-27 Thread Andrew Shadura
On 27/08/15 13:22, Jussi Kukkonen wrote:
 Could you please configure your git so that it tries harder to find
 renames: it's hard to see the changes otherwise. Something like this
 would work in git config (the other option is renames=copies):

Right, thanks for the suggestion. Resubmitting that patch.

-- 
Cheers,
  Andrew
From 863fb3ce148485e3838b68fc5bb1531465ac37bb Mon Sep 17 00:00:00 2001
From: Andrew Shadura andrew.shad...@collabora.co.uk
Date: Wed, 29 Jul 2015 16:00:37 +0100
Subject: [PATCH 2/3] dbus: update the recipes to 1.10.0

Signed-off-by: Andrew Shadura andrew.shad...@collabora.co.uk
---
 .../dbus/{dbus-test_1.8.20.bb = dbus-test_1.10.0.bb}  |  6 +++---
 meta/recipes-core/dbus/dbus/python-config.patch| 13 +++--
 meta/recipes-core/dbus/{dbus_1.8.20.bb = dbus_1.10.0.bb}  | 14 +-
 3 files changed, 19 insertions(+), 14 deletions(-)
 rename meta/recipes-core/dbus/{dbus-test_1.8.20.bb = dbus-test_1.10.0.bb} (91%)
 rename meta/recipes-core/dbus/{dbus_1.8.20.bb = dbus_1.10.0.bb} (93%)

diff --git a/meta/recipes-core/dbus/dbus-test_1.8.20.bb b/meta/recipes-core/dbus/dbus-test_1.10.0.bb
similarity index 91%
rename from meta/recipes-core/dbus/dbus-test_1.8.20.bb
rename to meta/recipes-core/dbus/dbus-test_1.10.0.bb
index 704070b..7dec16e 100644
--- a/meta/recipes-core/dbus/dbus-test_1.8.20.bb
+++ b/meta/recipes-core/dbus/dbus-test_1.10.0.bb
@@ -5,7 +5,7 @@ LICENSE = AFL-2 | GPLv2+
 LIC_FILES_CHKSUM = file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
 file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c
 
-DEPENDS = python-pygobject dbus dbus-glib
+DEPENDS = python-pygobject dbus
 
 RDEPENDS_${PN} += make
 RDEPENDS_${PN}-dev = 
@@ -18,8 +18,8 @@ SRC_URI = http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
file://clear-guid_from_server-if-send_negotiate_unix_f.patch \

 
-SRC_URI[md5sum] = b49890bbabedab3a1c3f4f73c7ff8b2b
-SRC_URI[sha256sum] = 5c4fbf4c64621c96e871da91d2b729a5b00536e116d3c4612a469d924b1b703a
+SRC_URI[md5sum] = 5af6297348107a906c8449817a728b3b
+SRC_URI[sha256sum] = 1dfb9745fb992f1ccd43c920490de8caddf6726a6222e8b803be6098293f924b
 
 S=${WORKDIR}/dbus-${PV}
 FILESEXTRAPATHS =. ${FILE_DIRNAME}/dbus:
diff --git a/meta/recipes-core/dbus/dbus/python-config.patch b/meta/recipes-core/dbus/dbus/python-config.patch
index 2944002..fbb4ede 100644
--- a/meta/recipes-core/dbus/dbus/python-config.patch
+++ b/meta/recipes-core/dbus/dbus/python-config.patch
@@ -6,19 +6,20 @@ Disable the python module check for cross compiling.
 Upstream-Status: Inappropriate [oe specific]
 
 Signed-off-by: Mark Hatle mark.ha...@windriver.com
+Signed-off-by: Andrew Shadura andrew.shad...@collabora.co.uk
 
 dbus-1.6.8/configure.ac.orig	2013-07-11 14:15:58.834554799 -0500
-+++ dbus-1.6.8/configure.ac	2013-07-11 14:14:40.969554848 -0500
-@@ -257,13 +257,6 @@
+--- a/configure.ac
 b/configure.ac
+@@ -267,13 +267,6 @@
# full test coverage is required, Python is a hard dependency
-   AC_MSG_NOTICE([Full test coverage (--enable-tests=yes) requires Python, dbus-python, pygobject])
+   AC_MSG_NOTICE([Full test coverage (--enable-tests=yes) requires Python, dbus-python, pygi])
AM_PATH_PYTHON([2.6])
 -  AC_MSG_CHECKING([for Python modules for full test coverage])
--  if $PYTHON -c import dbus, gobject, dbus.mainloop.glib; then
+-  if $PYTHON -c import dbus, gi.repository.GObject, dbus.mainloop.glib; then
 -AC_MSG_RESULT([yes])
 -  else
 -AC_MSG_RESULT([no])
--AC_MSG_ERROR([cannot import dbus, gobject, dbus.mainloop.glib Python modules])
+-AC_MSG_ERROR([cannot import dbus, gi.repository.GObject, dbus.mainloop.glib Python modules])
 -  fi
  else
# --enable-tests not given: do not abort if Python is missing
diff --git a/meta/recipes-core/dbus/dbus_1.8.20.bb b/meta/recipes-core/dbus/dbus_1.10.0.bb
similarity index 93%
rename from meta/recipes-core/dbus/dbus_1.8.20.bb
rename to meta/recipes-core/dbus/dbus_1.10.0.bb
index 207a018..cbfdf05 100644
--- a/meta/recipes-core/dbus/dbus_1.8.20.bb
+++ b/meta/recipes-core/dbus/dbus_1.10.0.bb
@@ -19,8 +19,8 @@ SRC_URI = http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
 
 
-SRC_URI[md5sum] = b49890bbabedab3a1c3f4f73c7ff8b2b
-SRC_URI[sha256sum] = 5c4fbf4c64621c96e871da91d2b729a5b00536e116d3c4612a469d924b1b703a
+SRC_URI[md5sum] = 5af6297348107a906c8449817a728b3b
+SRC_URI[sha256sum] = 1dfb9745fb992f1ccd43c920490de8caddf6726a6222e8b803be6098293f924b
 
 inherit useradd autotools pkgconfig gettext update-rc.d
 
@@ -58,15 +58,20 @@ FILES_${PN} = ${bindir}/dbus-daemon* \
${bindir}/dbus-monitor \
${bindir}/dbus-launch \
${bindir}/dbus-run-session \
+   ${bindir}/dbus-update-activation-environment \
${libexecdir}/dbus* \
${sysconfdir} \
${localstatedir} \
 

Re: [OE-core] [PATCH 2/3] dbus: update the recipes to 1.10.0

2015-08-27 Thread Alexander Kanavin

On 08/27/2015 02:37 PM, Andrew Shadura wrote:

On 27/08/15 13:22, Jussi Kukkonen wrote:

Could you please configure your git so that it tries harder to find
renames: it's hard to see the changes otherwise. Something like this
would work in git config (the other option is renames=copies):


Right, thanks for the suggestion. Resubmitting that patch.


Whenever you change something else than the version number and tarball 
checksums (e.g. build options, or dependencies, or adding/removing 
patches), it's good to explain in the commit log message what was 
updated and why. So you provide answers to the 'why' questions before 
people ask them :)


Regards,
Alex

--
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 3/3] devtool: run kernel dependencies

2015-08-27 Thread Markus Lehtonen
The kernel package needs kern-tools-native in order for it's
do_kernel_metadata. Thus, devtool extract for kernel in a pristine
environment fails. With the current bb.tinfoil implementation it is not
possible to run arbitrary bitbake commands - e.g. run
bitbake kern-tools-native -c populate_sysroot in our case. This patch
implements an ugly workaround for that problem, basically by hardcoding
this dependency and running the required bitbake task(s) before tinfoil
is initialized.

[YOCTO #6658]

Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
---
 scripts/lib/devtool/standard.py | 19 ++-
 1 file changed, 18 insertions(+), 1 deletion(-)

diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index 3725d87..bf24e32 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -197,6 +197,8 @@ def extract(args, config, basepath, workspace):
 Entry point for the devtool 'extract' subcommand
 import bb
 
+_check_extract_deps(config, basepath, args.recipename)
+
 tinfoil = setup_tinfoil()
 
 rd = _parse_recipe(config, tinfoil, args.recipename, True)
@@ -237,6 +239,20 @@ class BbTaskExecutor(object):
 self.executed.append(func)
 
 
+def _check_extract_deps(config, basepath, recipename):
+HACK: Ugly workaround for making sure that requirements are met when
+   trying to extract a package
+tinfoil = setup_tinfoil()
+rd = _parse_recipe(config, tinfoil, recipename, True)
+if bb.data.inherits_class('kernel-yocto', rd):
+tinfoil.shutdown()
+try:
+stdout, _ = exec_build_env_command(config.init_path, basepath,
+   'bitbake kern-tools-native')
+except bb.process.ExecutionError as err:
+raise DevtoolError(Failed to build kern-tools-native:\n%s %
+   err.stdout)
+
 def _extract_source(srctree, keep_temp, devbranch, d):
 Extract sources of a recipe
 import bb.event
@@ -422,7 +438,8 @@ def modify(args, config, basepath, workspace):
 raise DevtoolError(directory %s does not exist or not a directory 
(specify -x to extract source from recipe) %
args.srctree)
-
+if args.extract:
+_check_extract_deps(config, basepath, args.recipename)
 tinfoil = setup_tinfoil()
 
 rd = _parse_recipe(config, tinfoil, args.recipename, True)
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 0/3] devtool: improvements to kernel support

2015-08-27 Thread Markus Lehtonen
This patchset contains few patches to slightly improve the support for kernel
packages in devtool. The last of which is an ugly hack - to be removed after a
future tinfoil rewrite when running arbitrary bitbake task functions becomes
possible.

Markus Lehtonen (3):
  devtool: make required tasks be run in kernel build
  devtool: extract: correct initial rev for kernel packages
  devtool: run kernel dependencies

 scripts/lib/devtool/standard.py | 54 +++--
 1 file changed, 36 insertions(+), 18 deletions(-)

-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 1/3] devtool: make required tasks be run in kernel build

2015-08-27 Thread Markus Lehtonen
Set SRCTREECOVEREDTASKS appropriately in the workspace .bbappend file
for kernel recipes. This tries to ensure that all needed tasks (esp.
configure and patch) are run when building the kernel - tasks which
would normally be disabled by externalsrc.bbclass.

[YOCTO #6658]

Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
---
 scripts/lib/devtool/standard.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index e1c5584..00d0b2c 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -500,6 +500,8 @@ def modify(args, config, basepath, workspace):
 if b_is_s:
 f.write('EXTERNALSRC_BUILD_pn-%s = %s\n' % (args.recipename, 
srctree))
 
+if bb.data.inherits_class('kernel', rd):
+f.write('SRCTREECOVEREDTASKS = do_validate_branches 
do_kernel_checkout do_shared_workdir do_fetch do_unpack\n')
 if initial_rev:
 f.write('\n# initial_rev: %s\n' % initial_rev)
 for commit in commits:
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 2/3] devtool: extract: correct initial rev for kernel packages

2015-08-27 Thread Markus Lehtonen
Change handling of kernel packages so that the initial rev is parsed
correctly. Also, the devtool-specific git tags (devtool-base and
devtoo-patched) are now generated for kernel packages as well.

[YOCTO #6658]

Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
---
 scripts/lib/devtool/standard.py | 33 -
 1 file changed, 16 insertions(+), 17 deletions(-)

diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index 00d0b2c..3725d87 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -300,6 +300,10 @@ def _extract_source(srctree, keep_temp, devbranch, d):
 task_executor.exec_func('do_fetch', False)
 logger.info('Unpacking...')
 task_executor.exec_func('do_unpack', False)
+if bb.data.inherits_class('kernel-yocto', d):
+# Extra step for kernel to populate the source directory
+logger.info('Doing kernel checkout...')
+task_executor.exec_func('do_kernel_checkout', False)
 srcsubdir = crd.getVar('S', True)
 if srcsubdir == workdir:
 # Find non-patch sources that were unpacked to srctree directory
@@ -329,26 +333,21 @@ def _extract_source(srctree, keep_temp, devbranch, d):
 else:
 os.rmdir(patchdir)
 
-if bb.data.inherits_class('kernel-yocto', d):
-(stdout, _) = bb.process.run('git --git-dir=%s rev-parse HEAD' % 
crd.expand('${WORKDIR}/git'), cwd=srcsubdir)
-initial_rev = stdout.rstrip()
-else:
-if not os.listdir(srcsubdir):
-raise DevtoolError(no source unpacked to S, perhaps the %s 
-   recipe doesn't use any source? % pn)
+if not os.listdir(srcsubdir):
+raise DevtoolError(no source unpacked to S, perhaps the %s 
+   recipe doesn't use any source? % pn)
 
-if not os.path.exists(os.path.join(srcsubdir, '.git')):
-bb.process.run('git init', cwd=srcsubdir)
-bb.process.run('git add .', cwd=srcsubdir)
-bb.process.run('git commit -q -m Initial commit from upstream 
at version %s' % crd.getVar('PV', True), cwd=srcsubdir)
+if not os.path.exists(os.path.join(srcsubdir, '.git')):
+bb.process.run('git init', cwd=srcsubdir)
+bb.process.run('git add .', cwd=srcsubdir)
+bb.process.run('git commit -q -m Initial commit from upstream at 
version %s' % crd.getVar('PV', True), cwd=srcsubdir)
 
-(stdout, _) = bb.process.run('git rev-parse HEAD', cwd=srcsubdir)
-initial_rev = stdout.rstrip()
-
-bb.process.run('git checkout -b %s' % devbranch, cwd=srcsubdir)
-bb.process.run('git tag -f devtool-base', cwd=srcsubdir)
+(stdout, _) = bb.process.run('git rev-parse HEAD', cwd=srcsubdir)
+initial_rev = stdout.rstrip()
 
-crd.setVar('PATCHTOOL', 'git')
+bb.process.run('git checkout -b %s' % devbranch, cwd=srcsubdir)
+bb.process.run('git tag -f devtool-base', cwd=srcsubdir)
+crd.setVar('PATCHTOOL', 'git')
 
 logger.info('Patching...')
 task_executor.exec_func('do_patch', False)
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 1/3] package_rpm: support signing of rpm packages

2015-08-27 Thread Mark Hatle
On 8/26/15 10:11 PM, Markus Lehtonen wrote:
 Without pasting the whole patch:

 --- createrepo-0.4.11.orig/dumpMetadata.py
 +++ createrepo-0.4.11/dumpMetadata.py
 @@ -92,7 +92,7 @@ def returnHdr(ts, package):
 -ts.setVSFlags((rpm.RPMVSF_NOMD5|rpm.RPMVSF_NEEDPAYLOAD))
 +
 ts.setVSFlags((rpm.RPMVSF_NOMD5|rpm.RPMVSF_NEEDPAYLOAD|rpm.RPMVSF_NODSA|rp
 m.RPMVSF_NORSA|rpm.RPMVSF_NODSAHEADER|rpm.RPMVSF_NORSAHEADER))

 I can send up this change if you think it's useful in this case (and would
 eliminate these steps.)
 
 I can introduce a separate patch in the next version of this patchset.
 

The patch we use is attached.  (it's just a patch, not a proper git commit..)

 
 

 (The reason I question the steps is purely because we've seen in the past
 these
 temporary RPM databases seem to be fragile at times.  So anything we can
 do to
 avoid that is probably good.)
 
 Yes.
 
 
 Thanks,
   Markus
 
 

createrepo: Disable GPG signature validation

If the packages are signed, and the signature is not in the rpm-native
RPMDB, an error will occur.  We want to avoid this failure mode 
when building the native version of createrepo.

This only affects the feed generation and will not change any later
validations during use/install from the package feed.

Upstream-status: Inappropriate [no longer maintained version]

Signed-off-by: Mark Hatle mark.ha...@windriver.com

Index: createrepo-0.4.11/dumpMetadata.py
===
--- createrepo-0.4.11.orig/dumpMetadata.py
+++ createrepo-0.4.11/dumpMetadata.py
@@ -92,7 +92,7 @@ def returnHdr(ts, package):
 fdno = package # let's assume this is an fdno and go with it :)
 except OSError:
 raise MDError, Error opening file
-ts.setVSFlags((rpm.RPMVSF_NOMD5|rpm.RPMVSF_NEEDPAYLOAD))
+
ts.setVSFlags((rpm.RPMVSF_NOMD5|rpm.RPMVSF_NEEDPAYLOAD|rpm.RPMVSF_NODSA|rpm.RPMVSF_NORSA|rpm.RPMVSF_NODSAHEADER|rpm.RPMVSF_NORSAHEADER))
 try:
 hdr = ts.hdrFromFdno(fdno)
 except rpm.error:
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 1/3] dbus: merge .bb and .inc

2015-08-27 Thread Andrew Shadura
The split is no longer necessary, and only makes it more complicated to
do changes in external layers.

Signed-off-by: Andrew Shadura andrew.shad...@collabora.co.uk
---
 meta/recipes-core/dbus/dbus.inc   | 170 -
 meta/recipes-core/dbus/dbus_1.8.20.bb | 171 +-
 2 files changed, 170 insertions(+), 171 deletions(-)
 delete mode 100644 meta/recipes-core/dbus/dbus.inc

diff --git a/meta/recipes-core/dbus/dbus.inc b/meta/recipes-core/dbus/dbus.inc
deleted file mode 100644
index 3971081..000
--- a/meta/recipes-core/dbus/dbus.inc
+++ /dev/null
@@ -1,170 +0,0 @@
-SUMMARY = D-Bus message bus
-DESCRIPTION = D-Bus is a message bus system, a simple way for applications to 
talk to one another. In addition to interprocess communication, D-Bus helps 
coordinate process lifecycle; it makes it simple and reliable to code a 
\single instance\ application or daemon, and to launch applications and 
daemons on demand when their services are needed.
-HOMEPAGE = http://dbus.freedesktop.org;
-SECTION = base
-LICENSE = AFL-2 | GPLv2+
-LIC_FILES_CHKSUM = file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
-
file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c
-DEPENDS = expat virtual/libintl
-RDEPENDS_dbus_class-native = 
-RDEPENDS_dbus_class-nativesdk = 
-PACKAGES += ${@bb.utils.contains('DISTRO_FEATURES', 'ptest', '${PN}-ptest', 
'', d)}
-ALLOW_EMPTY_dbus-ptest = 1
-RDEPENDS_dbus-ptest_class-target = dbus-test-ptest
-
-SRC_URI = http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
-   file://tmpdir.patch \
-   file://dbus-1.init \
-   file://os-test.patch \
-   file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
-
-
-inherit useradd autotools pkgconfig gettext update-rc.d
-
-INITSCRIPT_NAME = dbus-1
-INITSCRIPT_PARAMS = start 02 5 3 2 . stop 20 0 1 6 .
-
-python __anonymous() {
-if not bb.utils.contains('DISTRO_FEATURES', 'sysvinit', True, False, d):
-d.setVar(INHIBIT_UPDATERCD_BBCLASS, 1)
-}
-
-USERADD_PACKAGES = ${PN}
-GROUPADD_PARAM_${PN} = -r netdev
-USERADD_PARAM_${PN} = --system --home ${localstatedir}/lib/dbus \
-   --no-create-home --shell /bin/false \
-   --user-group messagebus
-
-CONFFILES_${PN} = ${sysconfdir}/dbus-1/system.conf 
${sysconfdir}/dbus-1/session.conf
-
-DEBIANNAME_${PN} = dbus-1
-
-PACKAGES =+ ${PN}-lib
-
-OLDPKGNAME = dbus-x11
-OLDPKGNAME_class-nativesdk = 
-
-# for compatibility
-RPROVIDES_${PN} = ${OLDPKGNAME}
-RREPLACES_${PN} += ${OLDPKGNAME}
-
-FILES_${PN} = ${bindir}/dbus-daemon* \
-   ${bindir}/dbus-uuidgen \
-   ${bindir}/dbus-cleanup-sockets \
-   ${bindir}/dbus-send \
-   ${bindir}/dbus-monitor \
-   ${bindir}/dbus-launch \
-   ${bindir}/dbus-run-session \
-   ${libexecdir}/dbus* \
-   ${sysconfdir} \
-   ${localstatedir} \
-   ${datadir}/dbus-1/services \
-   ${datadir}/dbus-1/system-services \
-   ${systemd_unitdir}/system/
-FILES_${PN}-lib = ${libdir}/lib*.so.*
-RRECOMMENDS_${PN}-lib = ${PN}
-FILES_${PN}-dev += ${libdir}/dbus-1.0/include ${bindir}/dbus-glib-tool
-
-pkg_postinst_dbus() {
-   # If both systemd and sysvinit are enabled, mask the dbus-1 init script
-if ${@bb.utils.contains('DISTRO_FEATURES','systemd 
sysvinit','true','false',d)}; then
-   if [ -n $D ]; then
-   OPTS=--root=$D
-   fi
-   systemctl $OPTS mask dbus-1.service
-   fi
-
-   if [ -z $D ]  [ -e /etc/init.d/populate-volatile.sh ] ; then
-   /etc/init.d/populate-volatile.sh update
-   fi
-}
-
-EXTRA_OECONF = --disable-tests \
---disable-xml-docs \
---disable-doxygen-docs \
---disable-libaudit \
---disable-systemd \
---without-dbus-glib
-
-EXTRA_OECONF_append_class-native =  --disable-selinux
-
-PACKAGECONFIG ??= ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 
'systemd', '', d)} \
-   ${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'x11', '', 
d)}
-PACKAGECONFIG_class-native = 
-PACKAGECONFIG_class-nativesdk = 
-
-# Would like to --enable-systemd but that's a circular build-dependency between
-# systemd-dbus
-PACKAGECONFIG[systemd] = 
--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir
-PACKAGECONFIG[x11] = --with-x --enable-x11-autolaunch,--without-x 
--disable-x11-autolaunch, virtual/libx11 libsm
-
-do_install() {
-   autotools_do_install
-
-   if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', 
d)}; then
-   install -d ${D}${sysconfdir}/init.d
-   sed 's:@bindir@:${bindir}:'  ${WORKDIR}/dbus-1.init 
${WORKDIR}/dbus-1.init.sh
-   install -m 0755 ${WORKDIR}/dbus-1.init.sh 

[OE-core] [PATCH 2/3] dbus: update the recipes to 1.10.0

2015-08-27 Thread Andrew Shadura
Signed-off-by: Andrew Shadura andrew.shad...@collabora.co.uk
---
 meta/recipes-core/dbus/dbus-test_1.10.0.bb  |  61 
 meta/recipes-core/dbus/dbus-test_1.8.20.bb  |  61 
 meta/recipes-core/dbus/dbus/python-config.patch |  13 +-
 meta/recipes-core/dbus/dbus_1.10.0.bb   | 177 
 meta/recipes-core/dbus/dbus_1.8.20.bb   | 173 ---
 5 files changed, 245 insertions(+), 240 deletions(-)
 create mode 100644 meta/recipes-core/dbus/dbus-test_1.10.0.bb
 delete mode 100644 meta/recipes-core/dbus/dbus-test_1.8.20.bb
 create mode 100644 meta/recipes-core/dbus/dbus_1.10.0.bb
 delete mode 100644 meta/recipes-core/dbus/dbus_1.8.20.bb

diff --git a/meta/recipes-core/dbus/dbus-test_1.10.0.bb 
b/meta/recipes-core/dbus/dbus-test_1.10.0.bb
new file mode 100644
index 000..7dec16e
--- /dev/null
+++ b/meta/recipes-core/dbus/dbus-test_1.10.0.bb
@@ -0,0 +1,61 @@
+SUMMARY = D-Bus test package (for D-bus functionality testing only)
+HOMEPAGE = http://dbus.freedesktop.org;
+SECTION = base
+LICENSE = AFL-2 | GPLv2+
+LIC_FILES_CHKSUM = file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
+
file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c
+
+DEPENDS = python-pygobject dbus
+
+RDEPENDS_${PN} += make
+RDEPENDS_${PN}-dev = 
+
+SRC_URI = http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
+   file://tmpdir.patch \
+   file://dbus-1.init  \
+   file://run-ptest \
+   file://python-config.patch \
+   file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
+   
+
+SRC_URI[md5sum] = 5af6297348107a906c8449817a728b3b
+SRC_URI[sha256sum] = 
1dfb9745fb992f1ccd43c920490de8caddf6726a6222e8b803be6098293f924b
+
+S=${WORKDIR}/dbus-${PV}
+FILESEXTRAPATHS =. ${FILE_DIRNAME}/dbus:
+
+inherit autotools pkgconfig gettext ptest
+
+EXTRA_OECONF_X = ${@bb.utils.contains('DISTRO_FEATURES', 'x11', '--with-x', 
'--without-x', d)}
+EXTRA_OECONF_X_class-native = --without-x
+
+EXTRA_OECONF = --enable-tests \
+--enable-modular-tests \
+--enable-installed-tests \
+--enable-checks \
+--enable-asserts \
+--enable-verbose-mode \
+--disable-xml-docs \
+--disable-doxygen-docs \
+--disable-libaudit \
+--disable-systemd \
+--without-systemdsystemunitdir \
+--with-dbus-test-dir=${PTEST_PATH} \
+${EXTRA_OECONF_X}
+
+do_install() {
+:
+}
+
+do_install_ptest() {
+   install -d ${D}${PTEST_PATH}/test
+   case1=shell printf refs syslog
+   for i in ${case1}; do install ${B}/test/test-$i ${D}${PTEST_PATH}/test; 
done
+   case2=marshal syntax corrupt dbus-daemon dbus-daemon-eavesdrop 
loopback relay
+   for i in ${case2}; do install ${B}/test/.libs/test-$i 
${D}${PTEST_PATH}/test; done
+   case3=bus bus-system bus-launch-helper
+   for i in ${case3}; do install ${B}/bus/test-$i ${D}${PTEST_PATH}/test; 
done
+   install ${B}/dbus/test-dbus ${D}${PTEST_PATH}/test
+   cp -r ${B}/test/data ${D}${PTEST_PATH}/test
+}
+RDEPENDS_${PN}-ptest += bash
diff --git a/meta/recipes-core/dbus/dbus-test_1.8.20.bb 
b/meta/recipes-core/dbus/dbus-test_1.8.20.bb
deleted file mode 100644
index 704070b..000
--- a/meta/recipes-core/dbus/dbus-test_1.8.20.bb
+++ /dev/null
@@ -1,61 +0,0 @@
-SUMMARY = D-Bus test package (for D-bus functionality testing only)
-HOMEPAGE = http://dbus.freedesktop.org;
-SECTION = base
-LICENSE = AFL-2 | GPLv2+
-LIC_FILES_CHKSUM = file://COPYING;md5=10dded3b58148f3f1fd804b26354af3e \
-
file://dbus/dbus.h;beginline=6;endline=20;md5=7755c9d7abccd5dbd25a6a974538bb3c
-
-DEPENDS = python-pygobject dbus dbus-glib
-
-RDEPENDS_${PN} += make
-RDEPENDS_${PN}-dev = 
-
-SRC_URI = http://dbus.freedesktop.org/releases/dbus/dbus-${PV}.tar.gz \
-   file://tmpdir.patch \
-   file://dbus-1.init  \
-   file://run-ptest \
-   file://python-config.patch \
-   file://clear-guid_from_server-if-send_negotiate_unix_f.patch \
-   
-
-SRC_URI[md5sum] = b49890bbabedab3a1c3f4f73c7ff8b2b
-SRC_URI[sha256sum] = 
5c4fbf4c64621c96e871da91d2b729a5b00536e116d3c4612a469d924b1b703a
-
-S=${WORKDIR}/dbus-${PV}
-FILESEXTRAPATHS =. ${FILE_DIRNAME}/dbus:
-
-inherit autotools pkgconfig gettext ptest
-
-EXTRA_OECONF_X = ${@bb.utils.contains('DISTRO_FEATURES', 'x11', '--with-x', 
'--without-x', d)}
-EXTRA_OECONF_X_class-native = --without-x
-
-EXTRA_OECONF = --enable-tests \
---enable-modular-tests \
---enable-installed-tests \
---enable-checks \
---enable-asserts \
---enable-verbose-mode \
---disable-xml-docs \
---disable-doxygen-docs \
---disable-libaudit \
---disable-systemd \
-

[OE-core] [PATCH 3/3] dbus: add apparmor support

2015-08-27 Thread Andrew Shadura
Signed-off-by: Andrew Shadura andrew.shad...@collabora.co.uk
---
 meta/recipes-core/dbus/dbus_1.10.0.bb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-core/dbus/dbus_1.10.0.bb 
b/meta/recipes-core/dbus/dbus_1.10.0.bb
index cbfdf05..31cbef0 100644
--- a/meta/recipes-core/dbus/dbus_1.10.0.bb
+++ b/meta/recipes-core/dbus/dbus_1.10.0.bb
@@ -104,6 +104,7 @@ PACKAGECONFIG_class-nativesdk = 
 # systemd-dbus
 PACKAGECONFIG[systemd] = 
--with-systemdsystemunitdir=${systemd_unitdir}/system/,--without-systemdsystemunitdir
 PACKAGECONFIG[x11] = --with-x --enable-x11-autolaunch,--without-x 
--disable-x11-autolaunch, virtual/libx11 libsm
+PACKAGECONFIG[apparmor] = --enable-apparmor,--disable-apparmor,libapparmor
 
 do_install() {
autotools_do_install
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH v2 2/4] package_rpm: support signing of rpm packages

2015-08-27 Thread Markus Lehtonen
This patch adds a new bbclass for generating rpm packages that are
signed with a user defined key. The packages are signed as part of the
package_write_rpm task.

In order to enable the feature you need to
1. 'INHERIT +=  sign_rpm' in bitbake config (e.g. local or
   distro)
2. Create a file that contains the passphrase to your gpg secret key
3. 'RPM_GPG_PASSPHRASE_FILE = path_to_file in bitbake config,
   pointing to the passphrase file created in 2.
4. Define GPG key name to use by either defining
   'RPM_GPG_NAME = key_id in bitbake config OR by defining
   %_gpg_name key_id in your ~/.oerpmmacros file
5. 'RPM_GPG_PUBKEY = path_to_pubkey in bitbake config pointing to
   the public key (in armor format)

The user may optionally define GPG_CMD variable in the bitbake
configuration in order to specify a specific gpg binary/wrapper to use.

The sign_rpm.bbclass implements a simple scenario of locally signing the
packages. It could be replaced by a more advanced class that would
utilize a separate signing server for signing the packages, for example.

[YOCTO #8134]

Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
---
 meta/classes/package_rpm.bbclass |  5 
 meta/classes/sign_rpm.bbclass| 60 
 meta/lib/oe/package_manager.py   | 17 
 3 files changed, 82 insertions(+)
 create mode 100644 meta/classes/sign_rpm.bbclass

diff --git a/meta/classes/package_rpm.bbclass b/meta/classes/package_rpm.bbclass
index 8fd0685..3e933ef 100644
--- a/meta/classes/package_rpm.bbclass
+++ b/meta/classes/package_rpm.bbclass
@@ -695,6 +695,8 @@ python do_package_rpm () {
 else:
 d.setVar('PACKAGE_ARCH_EXTEND', package_arch)
 pkgwritedir = d.expand('${PKGWRITEDIRRPM}/${PACKAGE_ARCH_EXTEND}')
+d.setVar('RPM_PKGWRITEDIR', pkgwritedir)
+bb.debug(1, 'PKGWRITEDIR: %s' % d.getVar('RPM_PKGWRITEDIR', True))
 pkgarch = d.expand('${PACKAGE_ARCH_EXTEND}${HOST_VENDOR}-${HOST_OS}')
 magicfile = 
d.expand('${STAGING_DIR_NATIVE}${datadir_native}/misc/magic.mgc')
 bb.utils.mkdirhier(pkgwritedir)
@@ -730,6 +732,9 @@ python do_package_rpm () {
 d.setVar('BUILDSPEC', cmd + \n)
 d.setVarFlag('BUILDSPEC', 'func', '1')
 bb.build.exec_func('BUILDSPEC', d)
+
+if d.getVar('RPM_SIGN_PACKAGES', True) == '1':
+bb.build.exec_func(sign_rpm, d)
 }
 
 python () {
diff --git a/meta/classes/sign_rpm.bbclass b/meta/classes/sign_rpm.bbclass
new file mode 100644
index 000..552af68
--- /dev/null
+++ b/meta/classes/sign_rpm.bbclass
@@ -0,0 +1,60 @@
+inherit sanity
+
+RPM_SIGN_PACKAGES='1'
+
+
+_check_gpg_name () {
+macrodef=`rpm -E '%_gpg_name'`
+[ $macrodef == %_gpg_name ]  return 1 || return 0
+}
+
+
+def rpmsign_wrapper(d, files, passphrase, gpg_name=None):
+import pexpect
+
+# Find the correct rpm binary
+rpm_bin_path = d.getVar('STAGING_BINDIR_NATIVE', True) + '/rpm'
+cmd = rpm_bin_path +  --addsign 
+if gpg_name:
+cmd += --define '%%_gpg_name %s'  % gpg_name
+else:
+try:
+bb.build.exec_func('_check_gpg_name', d)
+except bb.build.FuncFailed:
+raise_sanity_error(You need to define RPM_GPG_NAME in bitbake 
+   config or the %_gpg_name RPM macro defined 
+   (e.g. in  ~/.oerpmmacros, d)
+if d.getVar('GPG_BIN', True):
+cmd += --define '%%__gpg %s'  % d.getVar('GPG_BIN', True)
+cmd += ' '.join(files)
+
+# Need to use pexpect for feeding the passphrase
+proc = pexpect.spawn(cmd)
+try:
+proc.expect_exact('Enter pass phrase:', timeout=15)
+proc.sendline(passphrase)
+proc.expect(pexpect.EOF, timeout=900)
+proc.close()
+except pexpect.TIMEOUT as err:
+bb.debug('rpmsign timeout: %s' % err)
+proc.terminate()
+return proc.exitstatus
+
+
+python sign_rpm () {
+import glob
+
+rpm_gpg_pass_file = (d.getVar(RPM_GPG_PASSPHRASE_FILE, True) or )
+if rpm_gpg_pass_file:
+with open(rpm_gpg_pass_file) as fobj:
+rpm_gpg_passphrase = fobj.readlines()[0].rstrip('\n')
+else:
+raise_sanity_error(You need to define RPM_GPG_PASSPHRASE_FILE in the 
config, d)
+
+rpm_gpg_name = (d.getVar(RPM_GPG_NAME, True) or )
+
+rpms = glob.glob(d.getVar('RPM_PKGWRITEDIR', True) + '/*')
+
+if rpmsign_wrapper(d, rpms, rpm_gpg_passphrase, rpm_gpg_name) != 0:
+raise bb.build.FuncFailed(RPM signing failed)
+}
diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
index 2ab1d78..936887c 100644
--- a/meta/lib/oe/package_manager.py
+++ b/meta/lib/oe/package_manager.py
@@ -108,6 +108,7 @@ class RpmIndexer(Indexer):
 archs = archs.union(set(sdk_pkg_archs))
 
 rpm_createrepo = bb.utils.which(os.getenv('PATH'), createrepo)
+
 index_cmds = []
 rpm_dirs_found = False
 for arch in archs:
@@ -127,9 +128,16 @@ class RpmIndexer(Indexer):
 

[OE-core] [PATCH v2 4/4] package_manager: support for signed RPM package feeds

2015-08-27 Thread Markus Lehtonen
This change makes it possible to create GPG signed RPM package feeds -
i.e. package feed with GPG signed metadata (repodata). All deployed RPM
repositories will be signed and the GPG public key is copied to the rpm
deployment directory.

In order to enable the new feature one needs to define four variables in
bitbake configuration.
1. 'PACKAGE_FEED_SIGN = 1' enabling the feature
2. 'PACKAGE_FEED_GPG_NAME = key_id' defining the GPG key to use for
   signing
3. 'PACKAGE_FEED_GPG_PASSPHRASE_FILE = path_to_file' pointing to a
   file containing the passphrase for the secret signing key
4. 'PACKAGE_FEED_GPG_PUBKEY = path_to_pubkey' pointing to the
   corresponding public key (in armor format)
The user may define GPG_CMD in the bitbake configuration in order to
specify a specific the gpg binary/wrapper to use for signing.

[YOCTO #8134]

Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
---
 meta/lib/oe/package_manager.py | 25 -
 1 file changed, 24 insertions(+), 1 deletion(-)

diff --git a/meta/lib/oe/package_manager.py b/meta/lib/oe/package_manager.py
index 936887c..83c119a 100644
--- a/meta/lib/oe/package_manager.py
+++ b/meta/lib/oe/package_manager.py
@@ -108,8 +108,17 @@ class RpmIndexer(Indexer):
 archs = archs.union(set(sdk_pkg_archs))
 
 rpm_createrepo = bb.utils.which(os.getenv('PATH'), createrepo)
+if self.d.getVar('PACKAGE_FEED_SIGN', True) == '1':
+pkgfeed_gpg_name = self.d.getVar('PACKAGE_FEED_GPG_NAME', True)
+pkgfeed_gpg_pass = 
self.d.getVar('PACKAGE_FEED_GPG_PASSPHRASE_FILE', True)
+else:
+pkgfeed_gpg_name = None
+pkgfeed_gpg_pass = None
+gpg_bin = self.d.getVar('GPG_BIN', True) or \
+  bb.utils.which(os.getenv('PATH'), gpg)
 
 index_cmds = []
+repo_sign_cmds = []
 rpm_dirs_found = False
 for arch in archs:
 dbpath = os.path.join(self.d.getVar('WORKDIR', True), 'rpmdb', 
arch)
@@ -121,6 +130,12 @@ class RpmIndexer(Indexer):
 
 index_cmds.append(%s --dbpath %s --update -q %s % \
  (rpm_createrepo, dbpath, arch_dir))
+if pkgfeed_gpg_name:
+repomd_file = os.path.join(arch_dir, 'repodata', 'repomd.xml')
+gpg_cmd = %s --detach-sign --armor --batch --no-tty --yes  \
+  --passphrase-file '%s' -u '%s' %s % (gpg_bin,
+  pkgfeed_gpg_pass, pkgfeed_gpg_name, repomd_file)
+repo_sign_cmds.append(gpg_cmd)
 
 rpm_dirs_found = True
 
@@ -132,12 +147,20 @@ class RpmIndexer(Indexer):
 result = oe.utils.multiprocess_exec(index_cmds, create_index)
 if result:
 bb.fatal('%s' % ('\n'.join(result)))
-# Copy pubkey to repo
+# Sign repomd
+result = oe.utils.multiprocess_exec(repo_sign_cmds, create_index)
+if result:
+bb.fatal('%s' % ('\n'.join(result)))
+# Copy pubkey(s) to repo
 distro_version = self.d.getVar('DISTRO_VERSION', True) or oe.0
 if self.d.getVar('RPM_SIGN_PACKAGES', True) == '1':
 shutil.copy2(self.d.getVar('RPM_GPG_PUBKEY', True),
  os.path.join(self.deploy_dir,
   'RPM-GPG-KEY-%s' % distro_version))
+if self.d.getVar('PACKAGE_FEED_SIGN', True) == '1':
+shutil.copy2(self.d.getVar('PACKAGE_FEED_GPG_PUBKEY', True),
+ os.path.join(self.deploy_dir,
+  'REPODATA-GPG-KEY-%s' % distro_version))
 
 
 class OpkgIndexer(Indexer):
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH v2 0/4] Sign packages in RPM feeds

2015-08-27 Thread Markus Lehtonen
Second iteration of my patchset. I tried to address the issues pointed out by
Mark:
1. The gpg key is not imported to the (temporary) rpm databases used by
   createrepo. Instead, createrepo is patched to ignore signature
   verification altogether.
2. There is a new optional config variable GPG_BIN which can be used to
   define the gpg binary used for signing.
3. The filename of the public keys (published with the package feed and
   depoyed into the target rootfs as part of os-release package) is now
   postfixed with -${DISTRO_VERSION}.

[YOCTO #8134]

*** BLURB HERE ***

Markus Lehtonen (4):
  createrepo: disable RPM signature validation
  package_rpm: support signing of rpm packages
  os-release: add the public package-signing key
  package_manager: support for signed RPM package feeds

 meta/classes/package_rpm.bbclass   |  5 ++
 meta/classes/sign_rpm.bbclass  | 60 ++
 meta/lib/oe/package_manager.py | 40 +++
 meta/recipes-core/os-release/os-release.bb | 11 
 ...dumpMetadata-disable-signature-validation.patch | 31 +++
 .../createrepo/createrepo_0.4.11.bb| 17 +++---
 6 files changed, 156 insertions(+), 8 deletions(-)
 create mode 100644 meta/classes/sign_rpm.bbclass
 create mode 100644 
meta/recipes-support/createrepo/createrepo/dumpMetadata-disable-signature-validation.patch

-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH v2 1/4] createrepo: disable RPM signature validation

2015-08-27 Thread Markus Lehtonen
Disable RPM signature validation so that it is possible to create
package feeds of signed RPM packages without importing the public part
of the signing key into the RPM database. In any case, the signatures
are validated when the packages in the feed are used (e.g. in image
generation of manually installing packages from the feed).

The original idea idea of this patch is from Mark Hatle
mark.ha...@windriver.com.

[YOCTO #8134]

Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
---
 ...dumpMetadata-disable-signature-validation.patch | 31 ++
 .../createrepo/createrepo_0.4.11.bb| 17 ++--
 2 files changed, 40 insertions(+), 8 deletions(-)
 create mode 100644 
meta/recipes-support/createrepo/createrepo/dumpMetadata-disable-signature-validation.patch

diff --git 
a/meta/recipes-support/createrepo/createrepo/dumpMetadata-disable-signature-validation.patch
 
b/meta/recipes-support/createrepo/createrepo/dumpMetadata-disable-signature-validation.patch
new file mode 100644
index 000..905531f
--- /dev/null
+++ 
b/meta/recipes-support/createrepo/createrepo/dumpMetadata-disable-signature-validation.patch
@@ -0,0 +1,31 @@
+dumpMetadata: disable signature validation
+
+Makes it possible to work on RPM repositories that contain signed packages
+without the need of importing the public part of the signing key into the RPM
+database.
+
+Upstream-Status: Pending
+
+Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
+---
+ dumpMetadata.py | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/dumpMetadata.py b/dumpMetadata.py
+index e40e8ac..ca6a82d 100644
+--- a/dumpMetadata.py
 b/dumpMetadata.py
+@@ -92,7 +92,9 @@ def returnHdr(ts, package):
+ fdno = package # let's assume this is an fdno and go with it :)
+ except OSError:
+ raise MDError, Error opening file
+-ts.setVSFlags((rpm.RPMVSF_NOMD5|rpm.RPMVSF_NEEDPAYLOAD))
++ts.setVSFlags((rpm.RPMVSF_NOMD5|rpm.RPMVSF_NEEDPAYLOAD|
++   rpm.RPMVSF_NODSA|rpm.RPMVSF_NORSA|
++   rpm.RPMVSF_NODSAHEADER|rpm.RPMVSF_NORSAHEADER))
+ try:
+ hdr = ts.hdrFromFdno(fdno)
+ except rpm.error:
+-- 
+2.1.4
+
diff --git a/meta/recipes-support/createrepo/createrepo_0.4.11.bb 
b/meta/recipes-support/createrepo/createrepo_0.4.11.bb
index adc193e..debbaec 100644
--- a/meta/recipes-support/createrepo/createrepo_0.4.11.bb
+++ b/meta/recipes-support/createrepo/createrepo_0.4.11.bb
@@ -9,14 +9,15 @@ RDEPENDS_${PN}_class-target = libxml2-python
 
 PR = r9
 
-SRC_URI= http://createrepo.baseurl.org/download/${BP}.tar.gz \
-  file://fix-native-install.patch \
-  file://python-scripts-should-use-interpreter-from-env.patch \
- file://createrepo-rpm549.patch \
- file://recommends.patch \
- file://createrepo-dbpath.patch \
- file://rpm-createsolvedb.py \
- 
+SRC_URI = http://createrepo.baseurl.org/download/${BP}.tar.gz \
+   file://fix-native-install.patch \
+   file://python-scripts-should-use-interpreter-from-env.patch \
+   file://createrepo-rpm549.patch \
+   file://recommends.patch \
+   file://createrepo-dbpath.patch \
+   file://dumpMetadata-disable-signature-validation.patch \
+   file://rpm-createsolvedb.py \
+   
 
 SRC_URI[md5sum] = 3e9ccf4abcffe3f49af078c83611eda2
 SRC_URI[sha256sum] = 
a73ae11a0dcde8bde36d900bc3f7f8f1083ba752c70a5c61b72d1e1e7608f21b
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH v2 3/4] os-release: add the public package-signing key

2015-08-27 Thread Markus Lehtonen
Adds the public package-signing key into this package. It will be
installed under /etc/pki/rpm-gpg if the RPM signing feature is used. The
key file is not currently directly used by anything in the target
system. It is merely there for possible later use.

[YOCTO #8134]

Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
---
 meta/recipes-core/os-release/os-release.bb | 11 +++
 1 file changed, 11 insertions(+)

diff --git a/meta/recipes-core/os-release/os-release.bb 
b/meta/recipes-core/os-release/os-release.bb
index 87fea6f..f24882a 100644
--- a/meta/recipes-core/os-release/os-release.bb
+++ b/meta/recipes-core/os-release/os-release.bb
@@ -23,15 +23,26 @@ PRETTY_NAME = ${DISTRO_NAME} ${VERSION}
 BUILD_ID ?= ${DATETIME}
 
 python do_compile () {
+import shutil
 with open(d.expand('${B}/os-release'), 'w') as f:
 for field in d.getVar('OS_RELEASE_FIELDS', True).split():
 value = d.getVar(field, True)
 if value:
 f.write('{0}={1}\n'.format(field, value))
+if d.getVar('RPM_SIGN_PACKAGES', True) == '1':
+rpm_gpg_pubkey = d.getVar('RPM_GPG_PUBKEY', True)
+os.mkdir('${B}/rpm-gpg')
+distro_version = self.d.getVar('DISTRO_VERSION', True) or oe.0
+shutil.copy2(rpm_gpg_pubkey, d.expand('${B}/rpm-gpg/RPM-GPG-KEY-%s' % 
distro_version))
 }
 do_compile[vardeps] += ${OS_RELEASE_FIELDS}
 
 do_install () {
 install -d ${D}${sysconfdir}
 install -m 0644 os-release ${D}${sysconfdir}/
+
+if [ -d rpm-gpg ]; then
+install -d ${D}${sysconfdir}/pki
+cp -r rpm-gpg ${D}${sysconfdir}/pki/
+fi
 }
-- 
2.1.4

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 1/1] screen: fix parallel build failure

2015-08-27 Thread kai.kang
From: Kai Kang kai.k...@windriver.com

Backport patch to fix screen parallel build failure.

Signed-off-by: Kai Kang kai.k...@windriver.com
---
 .../screen/0001-fix-for-multijob-build.patch   | 58 ++
 meta/recipes-extended/screen/screen_4.3.1.bb   |  4 +-
 2 files changed, 61 insertions(+), 1 deletion(-)
 create mode 100644 
meta/recipes-extended/screen/screen/0001-fix-for-multijob-build.patch

diff --git 
a/meta/recipes-extended/screen/screen/0001-fix-for-multijob-build.patch 
b/meta/recipes-extended/screen/screen/0001-fix-for-multijob-build.patch
new file mode 100644
index 000..40ecef0
--- /dev/null
+++ b/meta/recipes-extended/screen/screen/0001-fix-for-multijob-build.patch
@@ -0,0 +1,58 @@
+Upstream-Status: Backport
+
+Backport patch to fix parallel build failure and update context to make patch
+coulde be applied.
+
+http://git.savannah.gnu.org/cgit/screen.git/commit?id=c0de6dd
+
+Signed-off-by: Kai Kang kai.k...@windriver.com
+---
+From c0de6dd7970b2c7b426a5c39dcbc31c2bef87232 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Amadeusz=20S=C5=82awi=C5=84ski?= am...@asmblr.net
+Date: Thu, 2 Jan 2014 18:18:06 +0100
+Subject: [PATCH] fix for multijob build
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+make sure that comm.sh script generates comm.h header before doing
+anything else
+
+Signed-off-by: Amadeusz Sławiński am...@asmblr.net
+---
+ Makefile.in | 10 +-
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index ce86cbc..dea16d8 100644
+--- a/Makefile.in
 b/Makefile.in
+@@ -298,7 +298,7 @@ search.o: layout.h viewport.h canvas.h search.c config.h 
screen.h os.h osdef.h a
+  comm.h layer.h term.h image.h display.h window.h mark.h extern.h
+ tty.o: layout.h viewport.h canvas.h tty.c config.h screen.h os.h osdef.h 
ansi.h acls.h comm.h \
+  layer.h term.h image.h display.h window.h extern.h
+-term.o: layout.h viewport.h canvas.h term.c term.h
++term.o: layout.h viewport.h canvas.h term.c term.h comm.h
+ window.o: layout.h viewport.h canvas.h window.c config.h screen.h os.h 
osdef.h ansi.h acls.h \
+  comm.h layer.h term.h image.h display.h window.h extern.h logfile.h
+ utmp.o: layout.h viewport.h canvas.h utmp.c config.h screen.h os.h osdef.h 
ansi.h acls.h \
+@@ -324,7 +324,7 @@ canvas.o: layout.h viewport.h canvas.h canvas.c config.h 
screen.h os.h osdef.h a
+  comm.h layer.h term.h image.h display.h window.h extern.h \
+  braille.h
+ comm.o: layout.h viewport.h canvas.h comm.c config.h acls.h comm.h
+-kmapdef.o: layout.h viewport.h canvas.h kmapdef.c config.h
++kmapdef.o: layout.h viewport.h canvas.h kmapdef.c config.h comm.h
+ acls.o: layout.h viewport.h canvas.h acls.c config.h screen.h os.h osdef.h 
ansi.h acls.h comm.h \
+  layer.h term.h image.h display.h window.h extern.h
+ braille.o: layout.h viewport.h canvas.h braille.c config.h screen.h os.h 
osdef.h ansi.h acls.h \
+@@ -350,7 +350,7 @@ layout.o: layout.h viewport.h canvas.h layout.c config.h 
screen.h os.h osdef.h a
+ viewport.o: layout.h viewport.h canvas.h viewport.c config.h screen.h os.h 
osdef.h ansi.h acls.h \
+  comm.h layer.h term.h image.h display.h window.h extern.h \
+  braille.h
+-list_generic.o: list_generic.h list_generic.c layer.h screen.h osdef.h
+-list_display.o: list_generic.h list_display.c layer.h screen.h osdef.h
+-list_window.o: list_generic.h list_window.c window.h layer.h screen.h osdef.h
++list_generic.o: list_generic.h list_generic.c layer.h screen.h osdef.h comm.h
++list_display.o: list_generic.h list_display.c layer.h screen.h osdef.h comm.h
++list_window.o: list_generic.h list_window.c window.h layer.h screen.h osdef.h 
comm.h
+ 
diff --git a/meta/recipes-extended/screen/screen_4.3.1.bb 
b/meta/recipes-extended/screen/screen_4.3.1.bb
index f95578b..6aea56d 100644
--- a/meta/recipes-extended/screen/screen_4.3.1.bb
+++ b/meta/recipes-extended/screen/screen_4.3.1.bb
@@ -21,7 +21,9 @@ SRC_URI = ${GNU_MIRROR}/screen/screen-${PV}.tar.gz \
file://Remove-redundant-compiler-sanity-checks.patch \
file://Provide-cross-compile-alternatives-for-AC_TRY_RUN.patch \
file://Skip-host-file-system-checks-when-cross-compiling.patch \
-   file://Avoid-mis-identifying-systems-as-SVR4.patch
+   file://Avoid-mis-identifying-systems-as-SVR4.patch \
+   file://0001-fix-for-multijob-build.patch \
+  
 
 SRC_URI[md5sum] = 5bb3b0ff2674e29378c31ad3411170ad
 SRC_URI[sha256sum] = 
fa4049f8aee283de62e283d427f2cfd35d6c369b40f7f45f947dbfd915699d63
-- 
1.9.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 0/1] Fix screen parallel build failure

2015-08-27 Thread kai.kang
From: Kai Kang kai.k...@windriver.com

The following changes since commit 393bd7496d71eb101f21234c1233a2d18fd2c73e:

  oeqa/oetest.py: add better package search for hasPackage() (2015-08-26 
08:28:06 +0100)

are available in the git repository at:

  git://git.yoctoproject.org/poky-contrib kangkai/screen
  http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=kangkai/screen

Kai Kang (1):
  screen: fix parallel build failure

 .../screen/0001-fix-for-multijob-build.patch   | 58 ++
 meta/recipes-extended/screen/screen_4.3.1.bb   |  4 +-
 2 files changed, 61 insertions(+), 1 deletion(-)
 create mode 100644 
meta/recipes-extended/screen/screen/0001-fix-for-multijob-build.patch

-- 
1.9.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [RFC PATCH 2/2] image_types.bbclass: add support for fastboot image type

2015-08-27 Thread Nicolas Dechesne
On Wed, Aug 26, 2015 at 10:31 PM, Andre McCurdy armccu...@gmail.com wrote:

  +IMAGE_CMD_ext4.fastboot () {
  +   if [ ${ROOTFS_SIZE} -lt ${FASTBOOT_PARTITION_SIZE} ]; then
  +   make_ext4fs -l `expr ${FASTBOOT_PARTITION_SIZE} \* 1024` \
  +   ${EXTRA_IMAGECMD} \
  +   
  ${DEPLOY_DIR_IMAGE}/${IMAGE_NAME}.rootfs.ext4.fastboot \
  +   ${IMAGE_ROOTFS}
  +   else
  +   bbfatal Rootfs is too small for partition (Rootfs Actual 
  Size: ${ROOTFS_SIZE}, Partition size: ${FASTBOOT_PARTITION_SIZE})

 Should the error be Rootfs is too LARGE for partition ?

you're right.. wrong copy/paste, will fix.
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH] selftest/manifest.py: Test to verify rootfs manifest

2015-08-27 Thread Paul Eggleton
Hi Benjamin / Mariano,

On Wednesday 26 August 2015 12:26:02 Benjamin Esquivel wrote:
 Adding a new test to verify if the packages in the
 manifest files actually exists in pkgdata.
  -adding a setUpClass for when more tests get created here
  -check for the paths and fail gracefully if not there
  -skip the test when there are no manifest files to check
  -debug prints for failure analysis
 
 [YOCTO#8028]
 
 Signed-off-by: Benjamin Esquivel benjamin.esqui...@linux.intel.com
 Signed-off-by: Mariano Lopez mariano.lo...@linux.intel.com
 ---
  meta/lib/oeqa/selftest/manifest.py | 52
 ++ 1 file changed, 52 insertions(+)
  create mode 100644 meta/lib/oeqa/selftest/manifest.py
 
 diff --git a/meta/lib/oeqa/selftest/manifest.py
 b/meta/lib/oeqa/selftest/manifest.py new file mode 100644
 index 000..c2bc945
 --- /dev/null
 +++ b/meta/lib/oeqa/selftest/manifest.py
 @@ -0,0 +1,52 @@
 +import unittest
 +import os
 +from glob import glob
 +
 +from oeqa.selftest.base import oeSelfTest
 +from oeqa.utils.commands import get_bb_var
 +from oeqa.utils.decorators import testcase
 +
 +class VerifyManifest(oeSelfTest):
 +'''Tests for the manifest files and contents of an image'''
 +
 +@classmethod
 +def setUpClass(self):
 +
 +# get directory locations from variable values and check them
 +self.deploy_dir_image = get_bb_var('DEPLOY_DIR_IMAGE');
 +if not self.deploy_dir_image \
 +or not os.path.isdir(self.deploy_dir_image):
 +raise unittest.SkipTest({}: DEPLOY_DIR_IMAGE does not exist:
 {}\ +.format(VerifyManifest, self.deploy_dir_image))
 +
 +self.pkgdata_dir = get_bb_var('PKGDATA_DIR');
 +if not self.pkgdata_dir \
 +or not os.path.isdir(self.pkgdata_dir):
 +raise unittest.SkipTest({}: PKGDATA_DIR does not exist: {}\
 +.format(VerifyManifest, self.pkgdata_dir))
 +
 +# get the manifest files
 +# no need to try: since glob would return an empty list if
 +# the path is non-existant
 +self.manifest_files = glob(%s/*.manifest % self.deploy_dir_image)
 +self.log.debug(manifest files: {}.format(self.manifest_files)) +
if not self.manifest_files:
 +raise unittest.SkipTest({}: No manifest files found in: {}\
 +.format(VerifyManifest, self.deploy_dir_image))
 +
 +
 +def test_manifest_entries(self):
 +'''Verifying the manifest entries as packages '''
 +testname = self.id().split('.')[-1]
 +rundir = os.path.join(self.pkgdata_dir, runtime-reverse)
 +
 +errmsg = ERROR: Package %s is in manifest but not in pkgdata
 +for manifest in self.manifest_files:
 +with open(manifest, r) as mfile:
 +for manifest_entries in mfile:
 +pkg = manifest_entries.split()[0]
 +pkgfile = os.path.join(rundir, pkg)
 +self.log.debug({}: looking for {}\
 +.format(testname, pkgfile))
 +self.assertTrue(os.path.isfile(pkgfile),
 +errmsg % pkg)

Shouldn't this test actually be building an image (e.g. using
bitbake('core-image-minimal') ) in order to ensure there's a manifest file for 
it to look at? Then you can make the test fail rather than skipping if the file 
isn't there or doesn't contain a small set of packages we know should be 
listed.

Also while you're adding this could you add a similar test function for the 
SDK (both host + target manifests).

Thanks,
Paul

-- 

Paul Eggleton
Intel Open Source Technology Centre
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 3/3] package_manager: support for signed RPM package feeds

2015-08-27 Thread Mark Hatle
On 8/26/15 11:27 PM, Markus Lehtonen wrote:
 Hi Mark,
 
 On 26/08/15 18:10, Mark Hatle mark.ha...@windriver.com wrote:
 
 On 8/26/15 6:18 AM, Markus Lehtonen wrote:
 This change makes it possible to create GPG signed RPM package feeds -
 i.e. package feed with GPG signed metadata (repodata). All deployed RPM
 repositories will be signed and the GPG public key is copied to the rpm
 deployment directory.

 In order to enable the new feature one needs to define four variables in
 bitbake configuration.
 1. 'PACKAGE_FEED_SIGN = 1' enabling the feature
 2. 'PACKAGE_FEED_GPG_NAME = key_id' defining the GPG key to use for
signing
 3. 'PACKAGE_FEED_GPG_PASSPHRASE_FILE = path_to_file' pointing to a
file containing the passphrase for the secret signing key
 4. 'PACKAGE_FEED_GPG_PUBKEY = path_to_pubkey' pointing to the
corresponding public key (in armor format)

 [YOCTO #8134]

 Signed-off-by: Markus Lehtonen markus.lehto...@linux.intel.com
 ---
  meta/lib/oe/package_manager.py | 24 ++--
  1 file changed, 22 insertions(+), 2 deletions(-)

 diff --git a/meta/lib/oe/package_manager.py
 b/meta/lib/oe/package_manager.py
 index 753b3eb..5d7ef54 100644
 --- a/meta/lib/oe/package_manager.py
 +++ b/meta/lib/oe/package_manager.py
 @@ -113,8 +113,15 @@ class RpmIndexer(Indexer):
  rpm_pubkey = self.d.getVar('RPM_GPG_PUBKEY', True)
  else:
  rpm_pubkey = None
 +if self.d.getVar('PACKAGE_FEED_SIGN', True) == '1':
 +pkgfeed_gpg_name = self.d.getVar('PACKAGE_FEED_GPG_NAME',
 True)
 +pkgfeed_gpg_pass =
 self.d.getVar('PACKAGE_FEED_GPG_PASSPHRASE_FILE', True)
 +else:
 +pkgfeed_gpg_name = None
 +pkgfeed_gpg_pass = None
  
  index_cmds = []
 +repo_sign_cmds = []
  key_import_cmds = []
  rpm_dirs_found = False
  for arch in archs:
 @@ -126,10 +133,16 @@ class RpmIndexer(Indexer):
  continue
  
  if rpm_pubkey:
 -key_import_cmds.append(%s --define '_dbpath %s'
 --import %s %
 +key_import_cmds.append(%s --dbpath '%s' --import %s %
 (rpm_bin, dbpath, rpm_pubkey))
  index_cmds.append(%s --dbpath %s --update -q %s % \
   (rpm_createrepo, dbpath, arch_dir))
 +if pkgfeed_gpg_name:
 +repomd_file = os.path.join(arch_dir, 'repodata',
 'repomd.xml')
 +gpg_cmd = gpg2 --detach-sign --armor --batch --no-tty
 --yes  \
 +  --passphrase-file '%s' -u '%s' %s % \
 +  (pkgfeed_gpg_pass, pkgfeed_gpg_name,
 repomd_file)
 +repo_sign_cmds.append(gpg_cmd)

 I've had problems in the past hard coding 'gpg' or 'gpg2' as the name to
 use.

 Can we get this to be dynamic.. even if it's a system level define for
 what
 GPG/PGP program to use?
 
 OK, I can introduce a new variable for defining this.
 
 
 Also I'd forgotten about it until there.  RPM has a similar variable to
 define
 the GPG program to use.  So using that variable (_signature) and
 defaulting to
 the same item would be a good idea.
 
 I think this is not feasible as we're actually using the host's gpg(2)
 here and rpm might not even be available.

Sorry I listed the wrong variable..  What I was referring to was the gpg
program.  See below..

What I'm asking for is similar to the above of replacing:

gpg_cmd = gpg2 --detach-sign --armor --batch --no-tty --yes 

with something like:

gpg_cmd = d.getVar(GPG, True) + --detach-sign --armor --batch --no-tty --yes 


In the sections where you setup the RPM macros you would define signature in the
same way:

(patch 1/3)

if gpg_name:
cmd += --define '%%_gpg_name %s'  % gpg_name

cmd += --define '__gpg %s' --define '%%_gpg_name %s'  % (d.getVar(GPG,
True), gpg_name)

--Mark

 
 Thanks,
Markus
 
 
 
 (One such reason to do this is to write a wrapper that uses an alternative
 keychain for these keys)

  
  rpm_dirs_found = True
  
 @@ -145,10 +158,17 @@ class RpmIndexer(Indexer):
  result = oe.utils.multiprocess_exec(index_cmds, create_index)
  if result:
  bb.fatal('%s' % ('\n'.join(result)))
 -# Copy pubkey to repo
 +# Sign repomd
 +result = oe.utils.multiprocess_exec(repo_sign_cmds,
 create_index)
 +if result:
 +bb.fatal('%s' % ('\n'.join(result)))
 +# Copy pubkey(s) to repo
  if self.d.getVar('RPM_SIGN_PACKAGES', True) == '1':
  shutil.copy2(self.d.getVar('RPM_GPG_PUBKEY', True),
   os.path.join(self.deploy_dir,
 'RPM-GPG-KEY-oe'))
 +if self.d.getVar('PACKAGE_FEED_SIGN', True) == '1':
 +shutil.copy2(self.d.getVar('PACKAGE_FEED_GPG_PUBKEY',
 True),
 + os.path.join(self.deploy_dir,
 'REPODATA-GPG-KEY'))

 I didn't notice this before..  but we shouldn't