From patchwork Tue Oct 8 05:06:29 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Khem Raj X-Patchwork-Id: 175446 Delivered-To: patch@linaro.org Received: by 2002:a92:7e96:0:0:0:0:0 with SMTP id q22csp5221545ill; Mon, 7 Oct 2019 22:06:47 -0700 (PDT) X-Google-Smtp-Source: APXvYqzd+XH+by43b3nz8665jgMJnNEqewQHLD2UhFtVNELNwgFybdcKHl1mdIqKactnurnxfWh5 X-Received: by 2002:a63:d754:: with SMTP id w20mr19408224pgi.74.1570511207476; Mon, 07 Oct 2019 22:06:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570511207; cv=none; d=google.com; s=arc-20160816; b=RWMSpXm5kZXvCcpwZUlZSn/q3Wo2S9LlEsbKIBFoSr3GpoEAjvRdm89FoRMPPgeB80 CkvBvK4FdVByafUHI6sZYJqYTPp6dFBPtCItaD6z2XygquH1+t7YuzO2xmYBJNu3fFM3 yP3K5g/zc5ZI9tJpRmYeccFmzq6hwNBlZAem6PNtP7Pp5jqXCiYN9kljbLa9uujsf0vb sZB8YpDE6xasawPrRdt4XCbqCd8lBhVPYKF35BnMwvlcY8yRQ6DxS7OLoOzgM3PqZ/Yi VRVdwsZiK5SLlrKwVDUireHEKelVApaqN396OT4KayFS+tyruRhe8p6rA6cF8CZEcV0+ 6QFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=errors-to:sender:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :mime-version:message-id:date:to:from:dkim-signature:delivered-to; bh=KGxLgpsyvlaQ04v5A2Kz4VxjcmonmkCtrbCJpxJT5zQ=; b=cOBvQl8e4zSR/axtlKbFhw4APx0THQUpObpbXD4dIk76/oHxtwjeuhYis24Lf5FY0e 9okBmNmCW1oE8RPHl4ocPbmK1gucRJk1VWoW4s2QRsa8aOy2fv7t5yypi1WkdPtRcjuA 0aRlJOc3ezFdqlInJX7J8utF6/zx34uKoxmLp+XJKoD/CaHvTHyoJ60bKTnaEHZBaDyh 4DYvCtsoLrs3KWbzd5hU0Sb7LFWRaMIIxuK2mjyOS7RezZ9m8UxYQDXuAe6BTRd0qQb+ 5tEW7C6T4BUMBvcw7mmodHRyakjvqY/V/jXFg+PjQtsrwbvoqRI3f0jY8KToJVoIsihv NUsw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=oeeKoEyB; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id i3si19218237pfe.244.2019.10.07.22.06.46; Mon, 07 Oct 2019 22:06:47 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) client-ip=140.211.169.62; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=oeeKoEyB; spf=pass (google.com: best guess record for domain of openembedded-core-bounces@lists.openembedded.org designates 140.211.169.62 as permitted sender) smtp.mailfrom=openembedded-core-bounces@lists.openembedded.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from ec2-34-214-78-129.us-west-2.compute.amazonaws.com (localhost [127.0.0.1]) by mail.openembedded.org (Postfix) with ESMTP id EA1087F2BC; Tue, 8 Oct 2019 05:06:42 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-pf1-f193.google.com (mail-pf1-f193.google.com [209.85.210.193]) by mail.openembedded.org (Postfix) with ESMTP id 2D53B7DE8F for ; Tue, 8 Oct 2019 05:06:41 +0000 (UTC) Received: by mail-pf1-f193.google.com with SMTP id v4so10092737pff.6 for ; Mon, 07 Oct 2019 22:06:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=c4S34ruHHchM42msZhy0XGTuiW9fWBqqqmMy3eLC47c=; b=oeeKoEyBwd+8hhC5NPsvEYMh2L77x+GhUf6aeYyE7R4VZlBanbCi5H0iXegrl5XgP2 /OFfrBh3G+8Crnd8wyFQG32OxkZCkW7SBheS3MOi7htXWMV+Hu9ZR93tzio4PeP93AeH tna1GvV/rcxeHYBSk6KuV8l0wBKYrY+bi1Z9K3pJ9aLAdWJ/Z2kvf9lefZCrUsOiKM8w O4s0iQmGivBsVReNpExEx/ZlPQbS6lz1/D7TRq14nk3xaJewJsJRld5O5gnhABiAUHhE YfmtKvUAJS/tRl9WmnaDpVOUm/i9DotoeQqv+Fnk9AQiI0t8otwV3efi2djH/tdZ6+n/ iHRw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=c4S34ruHHchM42msZhy0XGTuiW9fWBqqqmMy3eLC47c=; b=f0wzuas+pohMPv4YI4FmUJtSRaDNCIu1E+3LpRJxw9YfnWqTivR/UGFN9+U/zAGZQa FyRpBwxUKSTKEbPfwwv0qhb4UI75eyq94+w+pnhD+KV5gX1YXw+UqX6hLOZf5QHUf+t4 ZuntavSn09LSJSEnakCqMyd934SdKaiorXzV3c2PG5RDE0V0cxv+np/TRF0Z0BLaszwj uDi2v2eruQByLLTzITmrutCZVOUlK5FU9887nVsSFY+syREcdgqTL2Mw6cHiROlTtsHE d8ieTIPA2q8LE7EN781xv8dDVvbqk9+KTJKqUzhzEmkRoP5DAB8QSpD9ed2SzMxymGWY P6eg== X-Gm-Message-State: APjAAAXMjTPY+nFhkdT4LlhCp30CtOXxwn0QXqQYloH/XHifRuom055/ yZm8xIxj8DgU3Odc3GQmeT1NMZxIbPw= X-Received: by 2002:a65:4884:: with SMTP id n4mr21854773pgs.348.1570511202607; Mon, 07 Oct 2019 22:06:42 -0700 (PDT) Received: from apollo.hsd1.ca.comcast.net ([2601:646:8500:1c20::7275]) by smtp.gmail.com with ESMTPSA id 2sm16341679pfo.91.2019.10.07.22.06.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 07 Oct 2019 22:06:42 -0700 (PDT) From: Khem Raj To: openembedded-core@lists.openembedded.org Date: Mon, 7 Oct 2019 22:06:29 -0700 Message-Id: <20191008050629.588374-1-raj.khem@gmail.com> X-Mailer: git-send-email 2.23.0 MIME-Version: 1.0 Subject: [OE-core] [PATCH V2] perl: Handle PACKAGES_DYNAMIC for perl-native X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: openembedded-core-bounces@lists.openembedded.org Errors-To: openembedded-core-bounces@lists.openembedded.org A perl module recipe extending to provide native version causes target perl dependencies to be pulled into native build if the module recipe has RDEPENDS_${PN} = "perl-module-XXXX" e.g. libxml-sax-base-perl recipe. The reason is that native bbclass empties out PACKAGES_DYNAMIC and perl's PACKAGES_DYNAMIC_class-target is greedy enough to usurp native modules as well. Eventually we end up with errors like when sstate is used across machines * ERROR: libxml-sax-base-perl-native different signature for task do_populate_sysroot.sigdata between qemux86copy and qemuarm Therefore, to fix this native case needs to handled specially when re-assigning module dependencies in split_perl_packages(), where the modules are named correctly for native case and have a single dependency on perl-native, secondly, PACKAGES_DYNAMIC for target case needs to be reined in to spare, -native modules, thirdly, let perl-native take over the case for providing native modules This will fix several sstate signature errors like above with external perl modules providing native variants and having runtime dependencies on modules which are provided by perl proper Signed-off-by: Khem Raj --- v2: Use anon python to set PACKAGES_DYNAMIC instead of forcevariable override meta/recipes-devtools/perl/perl_5.30.0.bb | 18 ++++++++++++++---- 1 file changed, 14 insertions(+), 4 deletions(-) -- 2.23.0 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/recipes-devtools/perl/perl_5.30.0.bb b/meta/recipes-devtools/perl/perl_5.30.0.bb index a221bce52b..ba2a8437d4 100644 --- a/meta/recipes-devtools/perl/perl_5.30.0.bb +++ b/meta/recipes-devtools/perl/perl_5.30.0.bb @@ -265,13 +265,23 @@ python split_perl_packages () { # Read the pre-generated dependency file, and use it to set module dependecies for line in open(d.expand("${WORKDIR}") + '/perl-rdepends.txt').readlines(): splitline = line.split() - module = splitline[0].replace("RDEPENDS_perl", "RDEPENDS_${PN}") - depends = splitline[2].strip('"').replace("perl-module", "${PN}-module") + if bb.data.inherits_class('native', d): + module = splitline[0] + '-native' + depends = "perl-native" + else: + module = splitline[0].replace("RDEPENDS_perl", "RDEPENDS_${PN}") + depends = splitline[2].strip('"').replace("perl-module", "${PN}-module") d.appendVar(d.expand(module), " " + depends) } -PACKAGES_DYNAMIC_class-target += "^perl-module-.*" -PACKAGES_DYNAMIC_class-nativesdk += "^nativesdk-perl-module-.*" +python() { + if d.getVar('CLASSOVERRIDE') == "class-target": + d.setVar("PACKAGES_DYNAMIC", "^perl-module-.*(?