From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from 93-97-173-237.zone5.bethere.co.uk ([93.97.173.237] helo=tim.rpsys.net) by linuxtogo.org with esmtp (Exim 4.72) (envelope-from ) id 1RqQe1-0004VN-W6 for openembedded-core@lists.openembedded.org; Thu, 26 Jan 2012 15:49:46 +0100 Received: from localhost (localhost [127.0.0.1]) by tim.rpsys.net (8.13.6/8.13.8) with ESMTP id q0QEfwPx023260 for ; Thu, 26 Jan 2012 14:41:58 GMT Received: from tim.rpsys.net ([127.0.0.1]) by localhost (tim.rpsys.net [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 22440-08 for ; Thu, 26 Jan 2012 14:41:53 +0000 (GMT) Received: from [192.168.3.10] ([192.168.3.10]) (authenticated bits=0) by tim.rpsys.net (8.13.6/8.13.8) with ESMTP id q0QEfnGL023254 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Thu, 26 Jan 2012 14:41:50 GMT Message-ID: <1327588911.19643.387.camel@ted> From: Richard Purdie To: openembedded-core Date: Thu, 26 Jan 2012 14:41:51 +0000 X-Mailer: Evolution 3.2.2- Mime-Version: 1.0 X-Virus-Scanned: amavisd-new at rpsys.net Subject: [PATCH] useradd.bbclass: Execute user addition code before do_package_setscene, not after do_populate_sysroot_setscene X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.11 Precedence: list Reply-To: Patches and discussions about the oe-core layer List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 26 Jan 2012 14:49:46 -0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit The user addition needs to happen before the do_package files are extracted by do_package_setscene since those are the ones we need to preserve the file ownership information for. This patch ensures this happens. Signed-off-by: Richard Purdie --- diff --git a/meta/classes/useradd.bbclass b/meta/classes/useradd.bbclass index e460f56..6ee575e 100644 --- a/meta/classes/useradd.bbclass +++ b/meta/classes/useradd.bbclass @@ -96,7 +96,7 @@ useradd_sysroot () { } useradd_sysroot_sstate () { - if [ "${BB_CURRENTTASK}" = "populate_sysroot_setscene" ] + if [ "${BB_CURRENTTASK}" = "package_setscene" ] then useradd_sysroot fi @@ -106,7 +106,7 @@ do_install[prefuncs] += "${SYSROOTFUNC}" SYSROOTFUNC = "useradd_sysroot" SYSROOTFUNC_virtclass-native = "" SYSROOTFUNC_virtclass-nativesdk = "" -SSTATEPOSTINSTFUNCS += "${SYSROOTPOSTFUNC}" +SSTATEPREINSTFUNCS += "${SYSROOTPOSTFUNC}" SYSROOTPOSTFUNC = "useradd_sysroot_sstate" SYSROOTPOSTFUNC_virtclass-native = "" SYSROOTPOSTFUNC_virtclass-nativesdk = ""