Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp37939078rwd; Wed, 12 Jul 2023 00:15:20 -0700 (PDT) X-Google-Smtp-Source: APBJJlEVH+vOET7R6Hwg9mehZ1SjpdE7vQs1Cb9df4HVz7AVroqqZOWXk3bhbuaO+7AQdsSdmEB6 X-Received: by 2002:aa7:cd4e:0:b0:51e:234:cb69 with SMTP id v14-20020aa7cd4e000000b0051e0234cb69mr16152128edw.15.1689146120429; Wed, 12 Jul 2023 00:15:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1689146120; cv=none; d=google.com; s=arc-20160816; b=hKY+Pto4b/ovehScel37mbZZDylN8HTFmRpg4Yl6DCSH/ykx+JFDPazr3RVJppVptK 2cMygzEKkD/QrRTQrB4oMYVUYoTUpzqRg6Q+GYk41lsL9Y/Kr0zIQst9MGOjCTufdfv/ TJ/W5g7t4K6WOafp3ggjJTzFLZd1qV3p+ZPyGczoBhjXg/tEx27LBVj6Ls/DQeKhjXgo tqv5kwyWY8QpeJFwx/kFEVL6qnV3Nx1kBzR+AArV1Gh/tgqXvakH+OilQfqxYjqXWYHX FNnRup7EKlND/4eW18crNbXkui6Dz2WcPPHfFtWLVgMR0FrOjG5ILkebH3SsKZaj/btj Tbtw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:reply-to:cc:to:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=wcQ9uU1uqM3j/Mwjru4dJWlzQFhn4SNkKwFdc2Pyu0E=; fh=RRL/mt06F9zy31ttmgUQRrOiFT03PcGdcCJaPO05CCA=; b=dezB6DD1MvVU2BhR80NhPoJJBEmJobBkFXZigVheiBtMPXru119JU+/71Uxb3ASTbC tu39OzfS/xnC2p1EzziRFsmPkO1FQo8Pr6cASbw3gpXcmND3zVPNsVK3aVCnP7NCgsvK 5b4SUAWEW6ho50hIdc8pcl2PRL3CXd8xzpfFXXAF3A0Oq6A4/TwfuNOIpSQysyEnjPbz x0nYdi22klTqY7v9H8IFnR8Ql9HcNneNHAMFseUv/4V7LTr9XacjVZONS1k0Su6bwEcj NPTOQzyrTPQMcWtRGuDMnrMP7Jqpz1gjrshypyDegxCmvG7UsXh/4SlMZNDYSMSoxE5R Nq4g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UPjhm3r0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id n16-20020aa7c690000000b0051a318aa40asi3757524edq.502.2023.07.12.00.14.56; Wed, 12 Jul 2023 00:15:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=UPjhm3r0; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231766AbjGLGmc (ORCPT + 99 others); Wed, 12 Jul 2023 02:42:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39166 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230308AbjGLGmX (ORCPT ); Wed, 12 Jul 2023 02:42:23 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CBB8719B; Tue, 11 Jul 2023 23:42:22 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 6A530616E3; Wed, 12 Jul 2023 06:42:22 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPS id BE665C433CB; Wed, 12 Jul 2023 06:42:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1689144141; bh=Lts7Ttry/DWypJyUuGIPywZ4oz1JjOWCv4NgY2hLjS8=; h=From:Date:Subject:To:Cc:Reply-To:From; b=UPjhm3r0ruTcSU8J/DisQuvVFubBpmkrQiRG66SNPMUZWT3Z/wPH1lRv6QTCidhPT 4p5mM4KYSLep6ITrOE6dfkpqT+13PI1ojUBBLOyYhbjDudjaoCW+y7Qg4GpOAu4S1O c32vGGvFK9tdXdAp46iIDy2sgLv0uDvsT41U6eYcsIxXzfDlbj1j2RpqpS0VvjHCmZ do69/LbC//53GfcfddojTfRaK2mkDRg8Y+0BFwBKEpkG+DMf0DrNZTx0DiTLM5q8QT sMOe9EO3iIqDyPBYXfmUpj8waqwj6l5w6m0IipXUkEy2LqSnZ1AA2TIb0k6dGUNyvB 4DAa+sSNLWlNQ== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id A56FFEB64DA; Wed, 12 Jul 2023 06:42:21 +0000 (UTC) From: Janne Grunau via B4 Relay Date: Wed, 12 Jul 2023 08:42:20 +0200 Subject: [PATCH] kbuild: rpm-pkg: Add dtbs support MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20230712-kbuild_rpm_dtbs-v1-1-99693e8faaaf@jannau.net> X-B4-Tracking: v=1; b=H4sIAEtLrmQC/6tWKk4tykwtVrJSqFYqSi3LLM7MzwNyDHUUlJIzE vPSU3UzU4B8JSMDI2MDc0Mj3eyk0syclPiigtz4lJKkYt0UA1PTRGNzC4OkpFQloK6CotS0zAq widGxtbUAJFQ7cGEAAAA= To: Masahiro Yamada , Nathan Chancellor , Nick Desaulniers , Nicolas Schier Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=openpgp-sha256; l=2064; i=j@jannau.net; h=from:subject:message-id; bh=pqGGqDq9keUrENGYOALz/M+BMKf1FbSWOisiewqrdWw=; b=owJ4nJvAy8zAJbZQ2uZ2r35qGuNptSSGlHXePilL8v9Nb7kXvHy/hEax8s0vUYeldk7jW13n1 KO9OHr5Mo2OUhYGMS4GWTFFliTtlx0Mq2sUY2ofhMHMYWUCGcLAxSkAEzknx8jw4oDAK1Hh2vur 3s03twqYv7793qWJ7fafPl+ut0lvVmo1YPgrx3zOoOFWRt/0e78kL5m05J+Yc/s9/yHTrvka6ks WqacxAwBrX0jq X-Developer-Key: i=j@jannau.net; a=openpgp; fpr=8B336A6BE4E5695E89B8532B81E806F586338419 X-Endpoint-Received: by B4 Relay for j@jannau.net/default with auth_id=62 X-Original-From: Janne Grunau Reply-To: X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Janne Grunau Based on the dtbs support in builddeb. Both Fedora and openSUSE kernel rpm install their dtbs in "/boot/dtb-${KERNELRELEASE}". There seems no other popular rpm based distributions which would benefit from dtbs support and are not derived from those two. Signed-off-by: Janne Grunau --- scripts/package/mkspec | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/scripts/package/mkspec b/scripts/package/mkspec index 8049f0e2c110..a170b0c0a93f 100755 --- a/scripts/package/mkspec +++ b/scripts/package/mkspec @@ -28,6 +28,14 @@ else M=DEL fi +# Only some architectures with OF support have the dtbs_install target +if grep -q CONFIG_OF_EARLY_FLATTREE=y include/config/auto.conf && \ + [ -d "${srctree}/arch/${SRCARCH}/boot/dts" ]; then + D= +else + D=DEL +fi + __KERNELRELEASE=$(echo $KERNELRELEASE | sed -e "s/-/_/g") EXCLUDES="$RCS_TAR_IGNORE --exclude=*vmlinux* --exclude=*.mod \ --exclude=*.o --exclude=*.ko --exclude=*.cmd --exclude=Documentation \ @@ -38,6 +46,8 @@ EXCLUDES="$RCS_TAR_IGNORE --exclude=*vmlinux* --exclude=*.mod \ # Labels: # $S: this line is enabled only when building source package # $M: this line is enabled only when CONFIG_MODULES is enabled +# $D: this line is enabled only when CONFIG_OF_EARLY_FLATTREE is enabled and +# the arch has a dts directory sed -e '/^DEL/d' -e 's/^\t*//' <