Openembedded Core Discussions
 help / color / mirror / Atom feed
* [PATCH v3 0/2] Bug fixes
@ 2012-06-13 11:20 Laurentiu Palcu
  2012-06-13 11:20 ` [PATCH v3 1/2] sanity.bbclass: warn the user if BBPATH contains wrong entries Laurentiu Palcu
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Laurentiu Palcu @ 2012-06-13 11:20 UTC (permalink / raw)
  To: openembedded-core

Version 3 - bump connman PR. Thanks Ross for reminding me! :)

Version 2 adds comments in connman.inc and xserver-nodm-init.bb to inform
that xuser's USERADD_PARAMs must be in sync, as suggested by Ross.

This patchset contains two bug fixes for:
	- Yocto #2467
	- Yocto #1465

Laurentiu Palcu (2):
  sanity.bbclass: warn the user if BBPATH contains wrong entries
  connman: make useradd parameters consistent with rootless X

 meta/classes/sanity.bbclass                        |   11 +++++++++++
 meta/recipes-connectivity/connman/connman.inc      |    6 ++++--
 .../x11-common/xserver-nodm-init.bb                |    2 ++
 3 files changed, 17 insertions(+), 2 deletions(-)

-- 
1.7.9.5




^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PATCH v3 1/2] sanity.bbclass: warn the user if BBPATH contains wrong entries
  2012-06-13 11:20 [PATCH v3 0/2] Bug fixes Laurentiu Palcu
@ 2012-06-13 11:20 ` Laurentiu Palcu
  2012-06-13 11:20 ` [PATCH v3 2/2] connman: make useradd parameters consistent with rootless X Laurentiu Palcu
  2012-06-13 13:56 ` [PATCH v3 0/2] Bug fixes Richard Purdie
  2 siblings, 0 replies; 5+ messages in thread
From: Laurentiu Palcu @ 2012-06-13 11:20 UTC (permalink / raw)
  To: openembedded-core

If BBPATH references the working directory, the user is warned and asked
to fix the problem.

[Yocto #1465]

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
---
 meta/classes/sanity.bbclass |   11 +++++++++++
 1 file changed, 11 insertions(+)

diff --git a/meta/classes/sanity.bbclass b/meta/classes/sanity.bbclass
index f79fc3f..6ed1e6f 100644
--- a/meta/classes/sanity.bbclass
+++ b/meta/classes/sanity.bbclass
@@ -387,6 +387,17 @@ def check_sanity(sanity_data):
     if "." in paths or "" in paths:
         messages = messages + "PATH contains '.' or '', which will break the build, please remove this."
 
+    bbpaths = sanity_data.getVar('BBPATH', True).split(":")
+    if "." in bbpaths or "" in bbpaths:
+        # TODO: change the following message to fatal when all BBPATH issues
+        # are fixed
+        bb.warn("BBPATH references the current directory, either through "    \
+                "an empty entry, or a '.'.\n\t This is unsafe and means your "\
+                "layer configuration is adding empty elements to BBPATH.\n\t "\
+                "Please check your layer.conf files and other BBPATH "        \
+                "settings to remove the current working directory "           \
+                "references.");
+
     if sanity_data.getVar('TARGET_ARCH', True) == "arm":
         # This path is no longer user-readable in modern (very recent) Linux
         try:
-- 
1.7.9.5




^ permalink raw reply related	[flat|nested] 5+ messages in thread

* [PATCH v3 2/2] connman: make useradd parameters consistent with rootless X
  2012-06-13 11:20 [PATCH v3 0/2] Bug fixes Laurentiu Palcu
  2012-06-13 11:20 ` [PATCH v3 1/2] sanity.bbclass: warn the user if BBPATH contains wrong entries Laurentiu Palcu
@ 2012-06-13 11:20 ` Laurentiu Palcu
  2012-06-13 11:27   ` Burton, Ross
  2012-06-13 13:56 ` [PATCH v3 0/2] Bug fixes Richard Purdie
  2 siblings, 1 reply; 5+ messages in thread
From: Laurentiu Palcu @ 2012-06-13 11:20 UTC (permalink / raw)
  To: openembedded-core

Both connman and rootless X share the same xuser. However, useradd
parameters are not consistent and if connman runs useradd first,
rootless X will be broken.

[Yocto #2467]

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@intel.com>
---
 meta/recipes-connectivity/connman/connman.inc      |    8 ++++++--
 meta/recipes-connectivity/connman/connman_0.79.bb  |    2 +-
 .../x11-common/xserver-nodm-init.bb                |    2 ++
 3 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-connectivity/connman/connman.inc b/meta/recipes-connectivity/connman/connman.inc
index 4fb7b43..3412323 100644
--- a/meta/recipes-connectivity/connman/connman.inc
+++ b/meta/recipes-connectivity/connman/connman.inc
@@ -20,6 +20,8 @@ DEPENDS  = "dbus glib-2.0 ppp iptables gnutls \
             ${@base_contains('DISTRO_FEATURES', '3g','ofono', '', d)} \
             "
 
+INC_PR = "r6"
+
 TIST = "--enable-tist"
 TIST_powerpc = ""
 
@@ -46,9 +48,11 @@ EXTRA_OECONF += "\
 INITSCRIPT_NAME = "connman"
 INITSCRIPT_PARAMS = "start 05 5 2 3 . stop 22 0 1 6 ."
 
+# IMPORTANT: because xuser is shared with rootless X, please make sure the
+# USERADD_PARAM is in sync with the one in xserver-nodm-init.bb
 USERADD_PACKAGES = "${PN}"
-USERADD_PARAM_${PN} = "--system --no-create-home \
-                       --shell /bin/false --groups video,tty,audio \
+USERADD_PARAM_${PN} = "--create-home \
+                       --groups video,tty,audio \
                        --user-group xuser"
 
 inherit autotools pkgconfig update-rc.d useradd
diff --git a/meta/recipes-connectivity/connman/connman_0.79.bb b/meta/recipes-connectivity/connman/connman_0.79.bb
index ec3d147..898fb11 100644
--- a/meta/recipes-connectivity/connman/connman_0.79.bb
+++ b/meta/recipes-connectivity/connman/connman_0.79.bb
@@ -11,4 +11,4 @@ SRC_URI  = "git://git.kernel.org/pub/scm/network/connman/connman.git \
             file://test-set-ipv6-method-api-fix.patch \
             file://connman"
 S = "${WORKDIR}/git"
-PR = "r5"
+PR = "${INC_PR}.0"
diff --git a/meta/recipes-graphics/x11-common/xserver-nodm-init.bb b/meta/recipes-graphics/x11-common/xserver-nodm-init.bb
index 1b95261..8fca056 100644
--- a/meta/recipes-graphics/x11-common/xserver-nodm-init.bb
+++ b/meta/recipes-graphics/x11-common/xserver-nodm-init.bb
@@ -30,6 +30,8 @@ INITSCRIPT_PARAMS = "start 9 5 2 . stop 20 0 1 6 ."
 
 # Use fixed Xusername of xuser for now, this will need to be
 # fixed if the Xusername changes from xuser
+# IMPORTANT: because xuser is shared with connman, please make sure the
+# USERADD_PARAM is in sync with the one in connman.inc
 USERADD_PACKAGES = "${PN}"
 USERADD_PARAM_${PN} = "--create-home \
                        --groups video,tty,audio \
-- 
1.7.9.5




^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PATCH v3 2/2] connman: make useradd parameters consistent with rootless X
  2012-06-13 11:20 ` [PATCH v3 2/2] connman: make useradd parameters consistent with rootless X Laurentiu Palcu
@ 2012-06-13 11:27   ` Burton, Ross
  0 siblings, 0 replies; 5+ messages in thread
From: Burton, Ross @ 2012-06-13 11:27 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On 13 June 2012 12:20, Laurentiu Palcu <laurentiu.palcu@intel.com> wrote:
> Both connman and rootless X share the same xuser. However, useradd
> parameters are not consistent and if connman runs useradd first,
> rootless X will be broken.

Looks good to me, and I'm running it on my test machine which was
reliably running connman postinst first.

Ross



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PATCH v3 0/2] Bug fixes
  2012-06-13 11:20 [PATCH v3 0/2] Bug fixes Laurentiu Palcu
  2012-06-13 11:20 ` [PATCH v3 1/2] sanity.bbclass: warn the user if BBPATH contains wrong entries Laurentiu Palcu
  2012-06-13 11:20 ` [PATCH v3 2/2] connman: make useradd parameters consistent with rootless X Laurentiu Palcu
@ 2012-06-13 13:56 ` Richard Purdie
  2 siblings, 0 replies; 5+ messages in thread
From: Richard Purdie @ 2012-06-13 13:56 UTC (permalink / raw)
  To: Patches and discussions about the oe-core layer

On Wed, 2012-06-13 at 14:20 +0300, Laurentiu Palcu wrote:
> Version 3 - bump connman PR. Thanks Ross for reminding me! :)
> 
> Version 2 adds comments in connman.inc and xserver-nodm-init.bb to inform
> that xuser's USERADD_PARAMs must be in sync, as suggested by Ross.
> 
> This patchset contains two bug fixes for:
> 	- Yocto #2467
> 	- Yocto #1465
> 
> Laurentiu Palcu (2):
>   sanity.bbclass: warn the user if BBPATH contains wrong entries
>   connman: make useradd parameters consistent with rootless X

Merged to master, thanks.

Richard




^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2012-06-13 14:07 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-13 11:20 [PATCH v3 0/2] Bug fixes Laurentiu Palcu
2012-06-13 11:20 ` [PATCH v3 1/2] sanity.bbclass: warn the user if BBPATH contains wrong entries Laurentiu Palcu
2012-06-13 11:20 ` [PATCH v3 2/2] connman: make useradd parameters consistent with rootless X Laurentiu Palcu
2012-06-13 11:27   ` Burton, Ross
2012-06-13 13:56 ` [PATCH v3 0/2] Bug fixes Richard Purdie

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox