From patchwork Fri Dec 13 23:21:55 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 181609 Delivered-To: patch@linaro.org Received: by 2002:ac9:44c4:0:0:0:0:0 with SMTP id t4csp1377043och; Fri, 13 Dec 2019 15:22:06 -0800 (PST) X-Google-Smtp-Source: APXvYqwVR3rtoPUCxSJFBUGH5wzGcfGpZLPs9iWZSiLBLd1qfRJqSUhOnLbeJXS05o3KVw3//Ani X-Received: by 2002:a62:8602:: with SMTP id x2mr2295442pfd.39.1576279325928; Fri, 13 Dec 2019 15:22:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576279325; cv=none; d=google.com; s=arc-20160816; b=Oc0kbbhxV5J4/AIVjmcImi2gXMEwZo5Jm9JkyrpR094YuRSlI1heRv305zgEQxSr5I GmInMPvFzZQeuaWHnok6ejf4zZB1Dg8lVP0u/lsFxayQd/0jyv4wSu7D/0K1QHtX3oQC 1M+8veg4awtFxr+xy9+uoNkSYQwbsOG39ApbvoA7DKfCGYMNNuP+EwkwHim9Sxmbzo2r 9Np2DZxyMLh7NRX82/+cm2fA50XXACOiv+xUBF4IISkmQP2+xQmdGH1yiha72DxnIaM4 rFoqbxhdAbBIrL32mEp2GTFgO8yU5rjQqZITlCmcAkeHmwWVtWaYOC2KTpnXg5gl4U5a pJTQ== 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=l0gMJXZvDot7Fb1kG/PlqmexPP2ypmyM4rDMH77+XxY=; b=jGLrOKSIjultM78fdT0b7EzoaDfOgEaXAN4YSb8HeXL4KJDiBk+CXmt9j7yuHemDJn obAxAnn9Pos83RqCJotlWambkc4Mb0canED0f3YP2ZXsZZkl8LC/Gn2tiehCZr0O1+/I fFDPPvsQB4kT/z/TjRuhbRmgWdmtm+gpAEHY2uExhu1lE/Z1hyJe6giP0kNQYxCAJQdh +MuijEH6saOiFUHC90QXrQKtjVfQvxliy5zrReaGqAlP4adnDzN12u9NvXSYyCWAvT35 JplXfGQA7m3aCuI/K8aM7ZMCEawRUqGGIEsSIFi0QoKBwazt7jZlfqjfpoSCiFcFeCgg PkLQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=c7IkSIUP; 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=NONE dis=NONE) header.from=intel.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id f10si8856195pje.57.2019.12.13.15.22.05; Fri, 13 Dec 2019 15:22:05 -0800 (PST) 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=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=c7IkSIUP; 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=NONE dis=NONE) header.from=intel.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 309437F8B9; Fri, 13 Dec 2019 23:22:01 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wr1-f66.google.com (mail-wr1-f66.google.com [209.85.221.66]) by mail.openembedded.org (Postfix) with ESMTP id DCE8A7CE26 for ; Fri, 13 Dec 2019 23:21:59 +0000 (UTC) Received: by mail-wr1-f66.google.com with SMTP id y11so492179wrt.6 for ; Fri, 13 Dec 2019 15:22:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=7tUIRugy7/gE58w7d7w3UAA6Qj3aK4jFurRyb5vTqqk=; b=c7IkSIUP4EHPXvTA3luqUIa69sJMd+ViomqNHmikBqwxJ9Se+zRvEigr79WLYTGB6k eicwsoF9+mILAiFaAx/t9X8l79fXUJVeZI7gazvQHK3DnI6nspTI9xcBfM272Ql5KjVC Whg05JoO6eNX7Nq47yntA2FwZaui4X6hoG1rSCVmux9YY7ohnCwFsNLKDvE0DSjU+7cp /vV3Mc+PyDmWwLzAfhg528fPi/HnwmDPXXuTkx70HFP3kQPncr34lCyZmx9g0kiAVfp+ gaqxP2v+KWnveFxeAFgca/J8z7xtXgcI7fXB7+AFYfzYVnpLzKweal95tmY4jpyWyiAs E8vA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=7tUIRugy7/gE58w7d7w3UAA6Qj3aK4jFurRyb5vTqqk=; b=cc3OKAmMhGCuj/4epvCXUkI0+z0P31NGTjDw05/Jvjiu9EDCwPjKguX9OdbulQLMhO Gl6NN9u87wcGFfRBWYURNtQwTBNn+/F/QumGAABW5HI23ELJC3l7oQmr6ybzCodPNzyV v5OrhxAVkUPyPmWqo4wxVxTCKP4nv4QoXCADQDL3bBnvcG4/0C2cK7Hx/3gjQsNXHOUW pjKUzdagQ4l3G0omgiyjKhltT53LY+1x72+kIAAdyu/LANoxT5yyifzNlSJYlRPvyWgL W8D3pxHcqYMdDeXxwpLqn2wLE2+eZWyKeVJGAzf6o0g3Ff3OtNIfkgkvKnTXNrQqXup7 HXzg== X-Gm-Message-State: APjAAAWdamJZvXCQNsnO4t5LQ+o0td+Hykx+VGOGCY6g1kctdadicOU9 ynKfKasS411u+qBSuDDQZ/r9OLoHzao= X-Received: by 2002:a5d:4e0a:: with SMTP id p10mr15078437wrt.229.1576279320101; Fri, 13 Dec 2019 15:22:00 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id z6sm11180507wmz.12.2019.12.13.15.21.58 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Dec 2019 15:21:58 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Fri, 13 Dec 2019 23:21:55 +0000 Message-Id: <20191213232156.28367-1-ross.burton@intel.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Subject: [OE-core] [RFC PATCH 1/2] podfix: class to remove Pod::Man versions from manpages 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 Manpages generated by Pod::Man contain the version number, which isn't reproducible if we're using the host Perl to generate manpage. One option is to always depend on perl-native when generating manpages but this is a heavy dependency, so instead strip out the versions in do_install(). Signed-off-by: Ross Burton --- meta/classes/podfix.bbclass | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 meta/classes/podfix.bbclass -- 2.20.1 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/classes/podfix.bbclass b/meta/classes/podfix.bbclass new file mode 100644 index 00000000000..54fff6a0a23 --- /dev/null +++ b/meta/classes/podfix.bbclass @@ -0,0 +1,32 @@ +python pod_strip_version() { + import re + + def opener(filename, mode): + if filename.endswith(".gz"): + import gzip + return gzip.open(filename, mode) + elif filename.endswith(".bz2"): + import bz2 + return bz2.open(filename, mode) + else: + return open(filename, mode) + + bad_re = re.compile(rb"Automatically generated by Pod::Man( [0-9]+.+)") + + for root, dirs, files in os.walk(d.expand("${D}${mandir}")): + for filename in files: + filename = os.path.join(root, filename) + with opener(filename, "rb") as manfile: + manpage = manfile.read() + m = bad_re.search(manpage) + if not m: + continue + + bb.note("podfix: stripping version from %s" % filename) + os.unlink(filename) + with opener(filename, "wb") as manfile: + manfile.write(manpage[:m.start(1)]) + manfile.write(manpage[m.end(1):]) +} + +do_install[postfuncs] += "pod_strip_version" From patchwork Fri Dec 13 23:21:56 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Burton X-Patchwork-Id: 181610 Delivered-To: patch@linaro.org Received: by 2002:ac9:44c4:0:0:0:0:0 with SMTP id t4csp1377284och; Fri, 13 Dec 2019 15:22:21 -0800 (PST) X-Google-Smtp-Source: APXvYqx+YDfXtwOvgl4D6/6Z2VVsmEP9SudbJ+aQJtCE5VfAZk+g6u1MC1pkEafEXbwMMjXEFVjl X-Received: by 2002:aa7:801a:: with SMTP id j26mr2308432pfi.50.1576279341287; Fri, 13 Dec 2019 15:22:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576279341; cv=none; d=google.com; s=arc-20160816; b=tBFHQAHNrnwnvJi0FwZaRaT6asvg+QzzElQcKBTpptZhggP00tYMAtgflEBhukQW+Y NgFlBzWdQM+5O6URPR36xuRWlMZL+ORDqQRy5O0uNTMr8yP+AE61KRUQL5RdM7o3Xryj ZXZKpfzEu7yIHiHQdXJLZV3Z1w9CjBpsJQrm3MXUoAWFS6JMBYGdCdDZQrkCfuqMjYbT 0xzVR4q1eat1GGCLGzym7T7KbZu/jr3PQLoV3X0jN2kGoeeIlPupAYGgs1lxEMsbECVE g7h0Vi3cb3SgzdF5xjOZ7HdNzGsUXLOVbfVi5k/af0U9JmV7PhJd1ZhRqPCYWb4D8tRp yrgg== 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:references:in-reply-to:message-id:date:to:from :dkim-signature:delivered-to; bh=QokV0zghPGdyXhedD+2qwVhORichRxGdUjkQZNU5IIk=; b=iBwSCkVRebVCH/NMASk7by7/afi2zt+nuvX8C+aNVSkkeCzf3s9/Evk/afnhlY6T6e IcoL3yUG3GYZT17SqX66R25/Vc0kMuqGAdgVj2F1omow/w2UuGxj3Ljg+SuyqCUtEen/ dcWnjfhWM4aKfGQYh/mtMUnE5CqCaGIR17+d4WIM4VlvSI47RkKCMcveRcLsBMsMSUfE oEB8E6M4Jby9XXfFZi0Jkn1ZfBxRHa+/NpHgRmi1FFO4zruYoZNxv0dIpDnGRQAZlWjl u2KHvpUbi6Fk6Y7YOnd5vr5z5UNIX9UXj9i+dUXBQRlDEonCFFoOCU9Oh7VH7p/zJTyX qfJA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=OaRq0XOx; 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=NONE dis=NONE) header.from=intel.com Return-Path: Received: from mail.openembedded.org (mail.openembedded.org. [140.211.169.62]) by mx.google.com with ESMTP id v5si8626857pjn.88.2019.12.13.15.22.20; Fri, 13 Dec 2019 15:22:21 -0800 (PST) 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=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=OaRq0XOx; 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=NONE dis=NONE) header.from=intel.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 36FA57F938; Fri, 13 Dec 2019 23:22:18 +0000 (UTC) X-Original-To: openembedded-core@lists.openembedded.org Delivered-To: openembedded-core@lists.openembedded.org Received: from mail-wr1-f65.google.com (mail-wr1-f65.google.com [209.85.221.65]) by mail.openembedded.org (Postfix) with ESMTP id 5D5C97CE26 for ; Fri, 13 Dec 2019 23:22:00 +0000 (UTC) Received: by mail-wr1-f65.google.com with SMTP id q10so462463wrm.11 for ; Fri, 13 Dec 2019 15:22:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:in-reply-to:references:mime-version :content-transfer-encoding; bh=2isAA5pABOTrwzgaeD4jKu484NnMq4KG4UHw/clgnLQ=; b=OaRq0XOxTlFchwgOAbNAvi+rxO1/Fmibn3Us3PTZCu1mVeTnqcnXg86GITh7EjMjiC ADU+TEE2ZQDLN7xECukKSQIlgbv0/+AU4GJaiAeTyonX9y3RuP3GotMy8vSLopw/o62q JqKkVbC4k4uZxa7htR6MlqGOT8i5PoLMzxLOop1avC2oOde91QgDPmglcbsZRQg7YJ1z yRMYS/Y0omXEYI+2n4JWNS5bxuXjuBy/YbvT3zR2KO69Z9aRd0RbT2DVhB2l9S1gNLLt N5QA/WxG2Tu6yzcwWw0ZYj7GwCMVnyaqPj1KzJ8yX1KEL5ek6c2HzYJFDVwfC5FLjE+E Z1xQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=2isAA5pABOTrwzgaeD4jKu484NnMq4KG4UHw/clgnLQ=; b=fqHMolFSCx9oXL3cVtuBBTQr27fueX3MRQo0ImCOjpYSpOv03sR4+OTMv0mX8iNMdG HhRdblK5S2MvluxYZH+hQgvJRtqP4lwX2cLlJHuTVn/LqE1FRnKs0WTtUdLJOgzC1xOV gdI7LaSYSlxy7P+teBlaU3I/b2rx4m7R0CBZbTdRafKXzJOKrRc7DZepqmoXe/U0vOe6 QcLRbD0ZNdaYITwX7hMRSoKdAbTeuwoFGnUDkfUhV5VlYLnlbfze/Em+psGEuXehxvrn V8BOWe9Mjc3/a0ddxnr36Zo/hJMare6DgatjoZkX4RzdP6BR66uDPyQnzRVnxKmL8W2H h+ZQ== X-Gm-Message-State: APjAAAX+B4ElVQ3u1nB6gNuysopbFDtRiMjZJ59iIJv297w6Ir9KNqX4 6JtigYz9/vNg2MJNukhlr+0ntLNwYa4= X-Received: by 2002:a5d:4044:: with SMTP id w4mr15204196wrp.322.1576279320934; Fri, 13 Dec 2019 15:22:00 -0800 (PST) Received: from flashheart.burtonini.com (35.106.2.81.in-addr.arpa. [81.2.106.35]) by smtp.gmail.com with ESMTPSA id z6sm11180507wmz.12.2019.12.13.15.22.00 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 13 Dec 2019 15:22:00 -0800 (PST) From: Ross Burton To: openembedded-core@lists.openembedded.org Date: Fri, 13 Dec 2019 23:21:56 +0000 Message-Id: <20191213232156.28367-2-ross.burton@intel.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191213232156.28367-1-ross.burton@intel.com> References: <20191213232156.28367-1-ross.burton@intel.com> MIME-Version: 1.0 Subject: [OE-core] [RFC PATCH 2/2] reproducible_build_simple: inherit podfix 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 When doing reproducible builds inherit podfix to remove the possibility of differing Perl versions causing manpages to change. Signed-off-by: Ross Burton --- meta/classes/reproducible_build_simple.bbclass | 1 + 1 file changed, 1 insertion(+) -- 2.20.1 -- _______________________________________________ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core diff --git a/meta/classes/reproducible_build_simple.bbclass b/meta/classes/reproducible_build_simple.bbclass index 8a60deef3d6..d0842f0f902 100644 --- a/meta/classes/reproducible_build_simple.bbclass +++ b/meta/classes/reproducible_build_simple.bbclass @@ -8,3 +8,4 @@ export SOURCE_DATE_EPOCH ??= "1520598896" REPRODUCIBLE_TIMESTAMP_ROOTFS ??= "1520598896" +inherit podfix