[OE-core] [PATCH] useradd: Allow overriding USERADDDEPENDS for native
If I want to be able to override USERADDDEPENDS from another bbclass, I need to give USERADDDEPENDS a default value and use DEPENDS_append for the different types of class. This is one example of what I need to be able to do in another .bbclass: USERADDDEPENDS_class-native = " base-files-native base-passwd-native... DEPENDS_append_class-native = " pseudo-native" Signed-off-by: Fabrice Coulon --- meta/classes/useradd.bbclass | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/meta/classes/useradd.bbclass b/meta/classes/useradd.bbclass index 4577e56..ca31616 100644 --- a/meta/classes/useradd.bbclass +++ b/meta/classes/useradd.bbclass @@ -3,11 +3,8 @@ inherit useradd_base # base-passwd-cross provides the default passwd and group files in the # target sysroot, and shadow -native and -sysroot provide the utilities # and support files needed to add and modify user and group accounts -DEPENDS_append = "${USERADDDEPENDS}" -USERADDDEPENDS = " base-files shadow-native shadow-sysroot shadow" -USERADDDEPENDS_class-cross = "" -USERADDDEPENDS_class-native = "" -USERADDDEPENDS_class-nativesdk = "" +USERADDDEPENDS ?= " base-files shadow-native shadow-sysroot shadow" +DEPENDS_append_class-target = "${USERADDDEPENDS}" # This preinstall function can be run in four different contexts: # -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] useradd: Allow overriding USERADDDEPENDS for native
If I want to be able to override USERADDDEPENDS from another bbclass, I need to give USERADDDEPENDS a default value and use DEPENDS_append for the different types of class. This is one example of what I need to be able to do in another .bbclass: USERADDDEPENDS_class-native = " base-files-native base-passwd-native... DEPENDS_append_class-native = " pseudo-native" Signed-off-by: Fabrice Coulon --- meta/classes/useradd.bbclass | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/meta/classes/useradd.bbclass b/meta/classes/useradd.bbclass index 4577e56..e27ca04 100644 --- a/meta/classes/useradd.bbclass +++ b/meta/classes/useradd.bbclass @@ -3,11 +3,8 @@ inherit useradd_base # base-passwd-cross provides the default passwd and group files in the # target sysroot, and shadow -native and -sysroot provide the utilities # and support files needed to add and modify user and group accounts +USERADDDEPENDS ?= " base-files shadow-native shadow-sysroot shadow" DEPENDS_append = "${USERADDDEPENDS}" -USERADDDEPENDS = " base-files shadow-native shadow-sysroot shadow" -USERADDDEPENDS_class-cross = "" -USERADDDEPENDS_class-native = "" -USERADDDEPENDS_class-nativesdk = "" # This preinstall function can be run in four different contexts: # -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] useradd_base: Make perform_groupmems work with native
I have a problem when using useradd_base.bbclass together with native. ${sysconfdir} is BUILDDIR/tmp/sysroots/x86_64-linux/etc for native, and ${sysconfdir} is "/etc" for target. rootdir is BUILDDIR/tmp/sysroots/x86_64-linux for native, so, $rootdir${sysconfdir} is not correct for native since it contains a duplication of the path to the sysroots. The solution was to replace instances of $rootdir${sysconfdir} with one variable that is correctly set depending if we inherit from native or not. Signed-off-by: Fabrice Coulon --- meta/classes/useradd_base.bbclass | 19 +++ 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/meta/classes/useradd_base.bbclass b/meta/classes/useradd_base.bbclass index ab3cd35..30ae1a8 100644 --- a/meta/classes/useradd_base.bbclass +++ b/meta/classes/useradd_base.bbclass @@ -74,20 +74,23 @@ perform_groupmems () { local groupname=`echo "$opts" | awk '{ for (i = 1; i < NF; i++) if ($i == "-g" || $i == "--group") print $(i+1) }'` local username=`echo "$opts" | awk '{ for (i = 1; i < NF; i++) if ($i == "-a" || $i == "--add") print $(i+1) }'` bbnote "${PN}: Running groupmems command with group $groupname and user $username" + + local sysroots_sysconfdir="${@'$sysconfdir' if bb.data.inherits_class('native', d) else '$rootdir$sysconfdir'}" + # groupmems fails if /etc/gshadow does not exist local gshadow="" - if [ -f $rootdir${sysconfdir}/gshadow ]; then + if [ -f ${sysroots_sysconfdir}/gshadow ]; then gshadow="yes" else gshadow="no" - touch $rootdir${sysconfdir}/gshadow + touch ${sysroots_sysconfdir}/gshadow fi - local mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*" $rootdir/etc/group || true`" + local mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*" ${sysroots_sysconfdir}/group || true`" if test "x$mem_exists" = "x"; then local count=0 while true; do eval $PSEUDO groupmems $opts || true - mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*" $rootdir/etc/group || true`" + mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*" ${sysroots_sysconfdir}/group || true`" if test "x$mem_exists" = "x"; then bbwarn "${PN}: groupmems command did not succeed. Retrying..." else @@ -96,8 +99,8 @@ perform_groupmems () { count=`expr $count + 1` if test $count = $retries; then if test "x$gshadow" = "xno"; then - rm -f $rootdir${sysconfdir}/gshadow - rm -f $rootdir${sysconfdir}/gshadow- + rm -f ${sysroots_sysconfdir}/gshadow + rm -f ${sysroots_sysconfdir}/gshadow- fi bbfatal "${PN}: Tried running groupmems command $retries times without success, giving up" fi @@ -107,8 +110,8 @@ perform_groupmems () { bbnote "${PN}: group $groupname already contains $username, not re-adding it" fi if test "x$gshadow" = "xno"; then - rm -f $rootdir${sysconfdir}/gshadow - rm -f $rootdir${sysconfdir}/gshadow- + rm -f ${sysroots_sysconfdir}/gshadow + rm -f ${sysroots_sysconfdir}/gshadow- fi } -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
Re: [OE-core] [PATCH] useradd_base: Make perform_groupmems work with native
On 12/07/2015 04:30 PM, Christopher Larson wrote: On Mon, Dec 7, 2015 at 3:39 AM, Fabrice Coulon mailto:fabrice.cou...@axis.com>> wrote: I have a problem when using useradd_base.bbclass together with native. ${sysconfdir} is BUILDDIR/tmp/sysroots/x86_64-linux/etc for native, and ${sysconfdir} is "/etc" for target. rootdir is BUILDDIR/tmp/sysroots/x86_64-linux for native, so, $rootdir${sysconfdir} is not correct for native. The solution for me was to replace instances of $rootdir${sysconfdir} with $rootdir/etc under perform_groupmems. Signed-off-by: Fabrice Coulon mailto:fabrice.cou...@axis.com>> Hardcoding a path is *not* an appropriate fix. I agree that hardcoding a path is not OK but maybe you should not see this as a fix but more like a question/discussion. The problem is that "/etc" is hardcoded in 13 other places in meta/classes/useradd_base.bbclass. Do you know how to solve this so that it will work well for native? -- 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
[OE-core] [PATCH] useradd_base: Make perform_groupmems work with native
I have a problem when using useradd_base.bbclass together with native. ${sysconfdir} is BUILDDIR/tmp/sysroots/x86_64-linux/etc for native, and ${sysconfdir} is "/etc" for target. rootdir is BUILDDIR/tmp/sysroots/x86_64-linux for native, so, $rootdir${sysconfdir} is not correct for native. The solution for me was to replace instances of $rootdir${sysconfdir} with $rootdir/etc under perform_groupmems. Signed-off-by: Fabrice Coulon --- meta/classes/useradd_base.bbclass | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/meta/classes/useradd_base.bbclass b/meta/classes/useradd_base.bbclass index ab3cd35..0c5ba67 100644 --- a/meta/classes/useradd_base.bbclass +++ b/meta/classes/useradd_base.bbclass @@ -76,11 +76,11 @@ perform_groupmems () { bbnote "${PN}: Running groupmems command with group $groupname and user $username" # groupmems fails if /etc/gshadow does not exist local gshadow="" - if [ -f $rootdir${sysconfdir}/gshadow ]; then + if [ -f $rootdir/etc/gshadow ]; then gshadow="yes" else gshadow="no" - touch $rootdir${sysconfdir}/gshadow + touch $rootdir/etc/gshadow fi local mem_exists="`grep "^$groupname:[^:]*:[^:]*:\([^,]*,\)*$username\(,[^,]*\)*" $rootdir/etc/group || true`" if test "x$mem_exists" = "x"; then @@ -96,8 +96,8 @@ perform_groupmems () { count=`expr $count + 1` if test $count = $retries; then if test "x$gshadow" = "xno"; then - rm -f $rootdir${sysconfdir}/gshadow - rm -f $rootdir${sysconfdir}/gshadow- + rm -f $rootdir/etc/gshadow + rm -f $rootdir/etc/gshadow- fi bbfatal "${PN}: Tried running groupmems command $retries times without success, giving up" fi @@ -107,8 +107,8 @@ perform_groupmems () { bbnote "${PN}: group $groupname already contains $username, not re-adding it" fi if test "x$gshadow" = "xno"; then - rm -f $rootdir${sysconfdir}/gshadow - rm -f $rootdir${sysconfdir}/gshadow- + rm -f $rootdir/etc/gshadow + rm -f $rootdir/etc/gshadow- fi } -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
Re: [OE-core] [PATCH] pseudo: Make it possible to override the append in a bbappend
On 12/02/2015 08:05 PM, Andre McCurdy wrote: On Wed, Dec 2, 2015 at 5:22 AM, Fabrice Coulon wrote: I need this in order to avoid a conflict when used with base-passwd-native. Doesn't something like this work from your .bbappend? do_install_append_class-native () { # Remove to avoid conflict with base-passwd-native rm -f ${D}${sysconfdir}/passwd ${D}${sysconfdir}/group } Yes it works. I don't need to change the recipe, it's enough with this in a bbappend. Thanks! -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] pseudo: Make it possible to override the append in a bbappend
I need this in order to avoid a conflict when used with base-passwd-native. Signed-off-by: Fabrice Coulon --- meta/recipes-devtools/pseudo/pseudo_1.7.4.bb | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/meta/recipes-devtools/pseudo/pseudo_1.7.4.bb b/meta/recipes-devtools/pseudo/pseudo_1.7.4.bb index d68e0af..87e624e 100644 --- a/meta/recipes-devtools/pseudo/pseudo_1.7.4.bb +++ b/meta/recipes-devtools/pseudo/pseudo_1.7.4.bb @@ -11,9 +11,13 @@ SRC_URI[sha256sum] = "f33ff84da328f943155f22cfd49030ef4ad85ad35fc2d9419a203521b6 PSEUDO_EXTRA_OPTS ?= "--enable-force-async --without-passwd-fallback" -do_install_append_class-native () { +append_class_native() { install -d ${D}${sysconfdir} # The fallback files should never be modified install -m 444 ${WORKDIR}/fallback-passwd ${D}${sysconfdir}/passwd install -m 444 ${WORKDIR}/fallback-group ${D}${sysconfdir}/group } + +do_install_append_class-native () { + append_class_native +} -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] base-passwd: Make it possible to build and install native
In order to be able to install the package base-passwd-native in the sysroot, make it possible to override the install options specifying the owner and group names for native. This change is needed for introducing pseudo-native support. I.e., to be able to install, chown, into the sysroot with users and groups that are not available on the build host by default. Signed-off-by: Fabrice Coulon --- meta/recipes-core/base-passwd/base-passwd_3.5.29.bb | 14 +++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/meta/recipes-core/base-passwd/base-passwd_3.5.29.bb b/meta/recipes-core/base-passwd/base-passwd_3.5.29.bb index ac9bd81..1ec0c81 100644 --- a/meta/recipes-core/base-passwd/base-passwd_3.5.29.bb +++ b/meta/recipes-core/base-passwd/base-passwd_3.5.29.bb @@ -21,18 +21,26 @@ inherit autotools SSTATEPOSTINSTFUNCS += "base_passwd_sstate_postinst" +# Make it possible to build base-passwd-native +BBCLASSEXTEND += "native" +# Make it possible to override these install options for class native +OWN = "root" +GROUP = "root" +INSTALL_OPTS = "-o ${OWN} -g ${GROUP}" +INSTALL_OPTS_class-native = "" + do_install () { install -d -m 755 ${D}${sbindir} - install -o root -g root -p -m 755 ${B}/update-passwd ${D}${sbindir}/ + install ${INSTALL_OPTS} -p -m 755 ${B}/update-passwd ${D}${sbindir}/ install -d -m 755 ${D}${mandir}/man8 ${D}${mandir}/pl/man8 install -p -m 644 ${S}/man/update-passwd.8 ${D}${mandir}/man8/ install -p -m 644 ${S}/man/update-passwd.pl.8 \ ${D}${mandir}/pl/man8/update-passwd.8 gzip -9 ${D}${mandir}/man8/* ${D}${mandir}/pl/man8/* install -d -m 755 ${D}${datadir}/base-passwd - install -o root -g root -p -m 644 ${S}/passwd.master ${D}${datadir}/base-passwd/ + install ${INSTALL_OPTS} -p -m 644 ${S}/passwd.master ${D}${datadir}/base-passwd/ sed -i 's#:/root:#:${ROOT_HOME}:#' ${D}${datadir}/base-passwd/passwd.master - install -o root -g root -p -m 644 ${S}/group.master ${D}${datadir}/base-passwd/ + install ${INSTALL_OPTS} -p -m 644 ${S}/group.master ${D}${datadir}/base-passwd/ install -d -m 755 ${D}${docdir}/${BPN} install -p -m 644 ${S}/debian/changelog ${D}${docdir}/${BPN}/ -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] gstreamer1.0: Convert tests and valgrind config opts to PACKAGECONFIGs
I need to be able to run unit tests and build with valgrind support. Signed-off-by: Fabrice Coulon --- meta/recipes-multimedia/gstreamer/gstreamer1.0.inc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc b/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc index aa95d57..7f36865 100644 --- a/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc +++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc @@ -11,11 +11,12 @@ inherit autotools pkgconfig gettext PACKAGECONFIG[debug] = "--enable-debug,--disable-debug" PACKAGECONFIG[check] = "--enable-check,--disable-check" +PACKAGECONFIG[tests] = "--enable-tests,--disable-tests" +PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind,valgrind," EXTRA_OECONF = "--disable-docbook --disable-gtk-doc \ --disable-dependency-tracking \ ---disable-examples --disable-tests \ ---disable-valgrind \ +--disable-examples \ " RRECOMMENDS_${PN}_qemux86+= "kernel-module-snd-ens1370 kernel-module-snd-rawmidi" @@ -26,4 +27,3 @@ CACHED_CONFIGUREVARS += "ac_cv_header_valgrind_valgrind_h=no" FILES_${PN} += " ${libdir}/gstreamer-1.0/*.so ${datadir}/bash-completion/completions/ ${datadir}/bash-completion/helpers/gst*" FILES_${PN}-dev += " ${libdir}/gstreamer-1.0/*.la ${libdir}/gstreamer-1.0/*.a ${libdir}/gstreamer-1.0/include" FILES_${PN}-dbg += " ${libdir}/gstreamer-1.0/.debug/ ${libexecdir}/gstreamer-1.0/.debug/ ${datadir}/bash-completion/helpers/.debug/" - -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] gstreamer1.0: Convert tests and valgrind config opts to PACKAGECONFIGs
I need to be able to run unit tests and build with valgrind support. Signed-off-by: Fabrice Coulon --- meta/recipes-multimedia/gstreamer/gstreamer1.0.inc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc b/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc index aa95d57..5a67bfd 100644 --- a/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc +++ b/meta/recipes-multimedia/gstreamer/gstreamer1.0.inc @@ -11,11 +11,12 @@ inherit autotools pkgconfig gettext PACKAGECONFIG[debug] = "--enable-debug,--disable-debug" PACKAGECONFIG[check] = "--enable-check,--disable-check" +PACKAGECONFIG[tests] = "--enable-tests,--disable-tests" +PACKAGECONFIG[valgrind] = "--enable-valgrind,--disable-valgrind" EXTRA_OECONF = "--disable-docbook --disable-gtk-doc \ --disable-dependency-tracking \ ---disable-examples --disable-tests \ ---disable-valgrind \ +--disable-examples \ " RRECOMMENDS_${PN}_qemux86+= "kernel-module-snd-ens1370 kernel-module-snd-rawmidi" @@ -26,4 +27,3 @@ CACHED_CONFIGUREVARS += "ac_cv_header_valgrind_valgrind_h=no" FILES_${PN} += " ${libdir}/gstreamer-1.0/*.so ${datadir}/bash-completion/completions/ ${datadir}/bash-completion/helpers/gst*" FILES_${PN}-dev += " ${libdir}/gstreamer-1.0/*.la ${libdir}/gstreamer-1.0/*.a ${libdir}/gstreamer-1.0/include" FILES_${PN}-dbg += " ${libdir}/gstreamer-1.0/.debug/ ${libexecdir}/gstreamer-1.0/.debug/ ${datadir}/bash-completion/helpers/.debug/" - -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] meta/lib/oe/package.py: fix files ownership in packages
This fix solves the problem with the ownership of files in packages. The do_install task was producing correct and expected output but when the files were being put in, e.g. a rpm package, the ownership could be different than that in the do_install task. [YOCTO #7428] Signed-off-by: Peter Kjellerstedt Signed-off-by: Fabrice Coulon --- meta/lib/oe/package.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/lib/oe/package.py b/meta/lib/oe/package.py index 7c728fc..8bc56c6 100644 --- a/meta/lib/oe/package.py +++ b/meta/lib/oe/package.py @@ -31,7 +31,7 @@ def runstrip(arg): extraflags = "--remove-section=.comment --remove-section=.note" # Use mv to break hardlinks -stripcmd = "'%s' %s '%s' -o '%s.tmp' && mv '%s.tmp' '%s'" % (strip, extraflags, file, file, file, file) +stripcmd = "'%s' %s '%s' -o '%s.tmp' && chown --reference='%s' '%s.tmp' && mv '%s.tmp' '%s'" % (strip, extraflags, file, file, file, file, file, file) bb.debug(1, "runstrip: %s" % stripcmd) ret = subprocess.call(stripcmd, shell=True) -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] meta/lib/oe/package.py: Fix for bug 7428
This fix solves the problem with the ownership of files in packages. The do_install task was producing correct and expected output but when the files were being put in, e.g. a rpm package, the ownership could be different than that in the do_install task. Signed-off-by: Peter Kjellerstedt Signed-off-by: Fabrice Coulon --- meta/lib/oe/package.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/lib/oe/package.py b/meta/lib/oe/package.py index 7c728fc..8bc56c6 100644 --- a/meta/lib/oe/package.py +++ b/meta/lib/oe/package.py @@ -31,7 +31,7 @@ def runstrip(arg): extraflags = "--remove-section=.comment --remove-section=.note" # Use mv to break hardlinks -stripcmd = "'%s' %s '%s' -o '%s.tmp' && mv '%s.tmp' '%s'" % (strip, extraflags, file, file, file, file) +stripcmd = "'%s' %s '%s' -o '%s.tmp' && chown --reference='%s' '%s.tmp' && mv '%s.tmp' '%s'" % (strip, extraflags, file, file, file, file, file, file) bb.debug(1, "runstrip: %s" % stripcmd) ret = subprocess.call(stripcmd, shell=True) -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] curl: add PACKAGECONFIG option to use libssh2
From: Fabrice Coulon The user can enable libssh2 via conf/local.conf or custom distro configuration, this will pull in libssh2, which is not used by default. For example, a curl_x.y.z.bbappend file containing the following line: PACKAGECONFIG += "libssh2" Signed-off-by: Fabrice Coulon Signed-off-by: Olof Johansson --- meta/recipes-support/curl/curl_7.37.1.bb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/recipes-support/curl/curl_7.37.1.bb b/meta/recipes-support/curl/curl_7.37.1.bb index e2852e3..39ded80 100644 --- a/meta/recipes-support/curl/curl_7.37.1.bb +++ b/meta/recipes-support/curl/curl_7.37.1.bb @@ -28,9 +28,9 @@ PACKAGECONFIG[ssl] = "--with-ssl --with-random=/dev/urandom,--without-ssl,openss PACKAGECONFIG[gnutls] = "--with-gnutls,--without-gnutls,gnutls" PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_LIBDIR}/../,--without-zlib,zlib" PACKAGECONFIG[rtmpdump] = "--with-librtmp,--without-librtmp,rtmpdump" +PACKAGECONFIG[libssh2] = "--with-libssh2,--without-libssh2,libssh2" -EXTRA_OECONF = "--without-libssh2 \ ---without-libidn \ +EXTRA_OECONF = "--without-libidn \ --enable-crypto-auth \ --disable-ldap \ --disable-ldaps \ -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH] useradd-staticids.bbclass: Fix for Bug 6633
From: Fabrice Coulon When using the useradd-staticids.bbclass under meta/classes, this error occurs: " - : Username does not have a static uid defined." There was a problem with the regular expression for parsing parameters, it was sometimes returning an empty string. I have fixed this by skipping empty strings. Signed-off-by: Fabrice Coulon --- meta/classes/useradd-staticids.bbclass | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/meta/classes/useradd-staticids.bbclass b/meta/classes/useradd-staticids.bbclass index a89cb10..421a70a 100644 --- a/meta/classes/useradd-staticids.bbclass +++ b/meta/classes/useradd-staticids.bbclass @@ -58,7 +58,9 @@ def update_useradd_static_config(d): newparams = [] for param in re.split('''[ \t]*;[ \t]*(?=(?:[^'"]|'[^']*'|"[^"]*")*$)''', params): -param=param.strip() +param = param.strip() +if not param: +continue try: uaargs = parser.parse_args(re.split('''[ \t]*(?=(?:[^'"]|'[^']*'|"[^"]*")*$)''', param)) except: @@ -194,7 +196,9 @@ def update_useradd_static_config(d): newparams = [] for param in re.split('''[ \t]*;[ \t]*(?=(?:[^'"]|'[^']*'|"[^"]*")*$)''', params): -param=param.strip() +param = param.strip() +if not param: +continue try: # If we're processing multiple lines, we could have left over values here... gaargs = parser.parse_args(re.split('''[ \t]*(?=(?:[^'"]|'[^']*'|"[^"]*")*$)''', param)) -- 1.9.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core