Received: by 2002:ab2:69cc:0:b0:1fd:c486:4f03 with SMTP id n12csp415103lqp; Tue, 11 Jun 2024 08:07:57 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWtlIch9fhNLlB2WkOdCT/8SonE93OY6h2Wwi6mhvsyh0v1k14r1uZ2oDFhYvMxtRaZ9KUhPqH0qNU6ivcR33BrZ8L+4IGH2NdfqsB6OQ== X-Google-Smtp-Source: AGHT+IE3Dnak7vLcst4STuXWUrc94aXjAuhbcRKGQYkqr3NqfW7+lv4HYj305xcfWnCW9AMCggvI X-Received: by 2002:a05:6a21:194:b0:1b7:a9d4:f4fd with SMTP id adf61e73a8af0-1b7a9d4f653mr5578734637.40.1718118477666; Tue, 11 Jun 2024 08:07:57 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718118477; cv=pass; d=google.com; s=arc-20160816; b=SjNfJSjvVx0bw0L6BVXzf8dvu53rnPPOHNb1K7ncsVr2KvC5zoyDwxx7INTue/XofJ rK4hO1GvJBRbCAsSDI8RbkbKvqVcx8YBPS8wImU+3JNmORYVAc3O+NT98kzC71R31zQD zq3QeMQFre1XZ2LyRw/PbWSnIB2yeusg0q2lUxLEM41ejrWWYbng697bANQ32mp8HjAO XN7+nGz/f8HdipP4fHYfkC+O3PuHTxkVH7WZBpl1VlaCbaadkvvgWyKKHIJq+LTDhweI 9VxElGgvfRlgBAQOcX/M2Hl7KQTPtQJlod/teRf6UIbQNNp175rZBQKkh5l7Q023cPqC SNsQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=5aQ+u1zO0FTJRW4VogWH8HTwVtGNixVyTo50zAO2dqI=; fh=WlJ1yBqzxWhCJHj/xzI5tuX+Tdfzs2XGSJNfKoMKZYI=; b=dRV0tL/GCbsxDRIqAcphQjIbIMKLR7DwhfGpNgezLM7082dfuyJagMLI5X9GoQciLj BkfLsOaGFTmmZfQehVYYLF91Bvcj+yjPjCkq//dWNKkZD9VsvUylblxJ1G0Hv/EGUoTv 9/EhQUCwO+E4q/r7ZcYFR5qvblXcMRiDElr2LhE4/0Jxibo+166iJ65/47IxVE74b2Sq gba0/xJ+05zU/mX5TSmAUPpSSq7lKemZKeyLWk474j5KgW7PIpVXisolNqHBpUdQ4pYg i3MFAuk6m5y+c+iPU5PryF/K6yxw8CyZfi1tmtEQf+BU9EV/P2sj29X10i9H95aHizeF IpQw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lK++gawO; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-210109-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-210109-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id 41be03b00d2f7-6de262c008fsi9577744a12.391.2024.06.11.08.07.57 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 11 Jun 2024 08:07:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-210109-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=lK++gawO; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-210109-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-210109-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 36460B23B75 for ; Tue, 11 Jun 2024 15:01:03 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id DFF781B5A4; Tue, 11 Jun 2024 15:00:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="lK++gawO" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 129FFA94C; Tue, 11 Jun 2024 15:00:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718118056; cv=none; b=MPMEzKpqGTxu1iCKK90uII6G98Mj2N38wiKjzFnB9x+SKRoMCfM4ShK7RhWBve69odV1vtvp5BWZsqU+CqtIDE1P+5SKcJnkB9yBLYjPKxK1yTPi9IYaYcb1LSfllF0rvgTyovj8wozD6vXlJOklG0xSv8YUUatC3lNciYUBL8s= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718118056; c=relaxed/simple; bh=6AxpCQRp4CcCzGPTkvMdBUk76WhbB3R46k9hHy1H/X0=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=k+1Rw1eBj0X1wMaNBBo7PLpWftl0G9/hLKbgKPcYHHStRs/nNSCuSaB8Ea60wyQrA3OZGr0JHcqtLPOKefYrchQLmysYA8RhFe1lOQBmqkFmVNtVNeDpB5+JKh2loYnGPD0ZRBcuQ7uOXCiqX1OijiYpEbro5vcOHScCPjwbVWo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=lK++gawO; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 8ADADC2BD10; Tue, 11 Jun 2024 15:00:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1718118055; bh=6AxpCQRp4CcCzGPTkvMdBUk76WhbB3R46k9hHy1H/X0=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=lK++gawOAE6NEeUaxXIDX1T+5GPz34SU9iKWri2aDHHa3CmTKMrOp2okkSwkADM9S JmKpnWzCct8hWUkOXbieudG/cbwiXYqgbYWUSxJC9lyeshc1Aun1yBc6RTao6Ma+bs BxZyiZD0Q+evT1i5rc2eTh0jzQfwGzc+eT/6nKvN81H+YNRcDQoEmu0EJlE9TfrO0N MKtsBhhyOwixBOL51EmvBqayqIzO5qfWRNLtDUclcivUJuBDUXMX+VELO/t8SpX1wS TPN8DiwtAmYMqWFMFDIkuwzRDxXMimOaMjPDQNGd4SdkEX0l7MEHvMJRkHlF79xOy+ a88HWDgcLa0tg== Received: by mail-lf1-f51.google.com with SMTP id 2adb3069b0e04-52bc3130ae6so4242459e87.3; Tue, 11 Jun 2024 08:00:55 -0700 (PDT) X-Forwarded-Encrypted: i=1; AJvYcCVowPU0khFPiMVTqCRWWRoYOiTYibzZF/duiL48hW1fWMVPrmVraJR16TNZWebJJYYDPCfRrmM0mm3pyd2pCgIOiIXDQoQW1823ItPU X-Gm-Message-State: AOJu0Yyf/+zQ3X9O0Vga1XngHC5FfFHEtRyKsKIaUgGtti5Juocgs7Mz GAaUENWLh7qPhDbpxHcXVgCSZ6hJSD9tWTLl84a2HMz+MNmNj1CBn3eTDS5G+188j3GSDLiryZa cSsUgUBKs+yLC95eBGBG513YGAfE= X-Received: by 2002:a05:6512:1191:b0:52c:856d:dd18 with SMTP id 2adb3069b0e04-52c856debdfmr5745187e87.4.1718118054270; Tue, 11 Jun 2024 08:00:54 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240610163856.693110-1-aquini@redhat.com> In-Reply-To: <20240610163856.693110-1-aquini@redhat.com> From: Masahiro Yamada Date: Wed, 12 Jun 2024 00:00:18 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] kbuild: rpm-pkg: fix rpmbuild warnings for kernel.spec To: Rafael Aquini Cc: linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org, Nathan Chancellor , Nicolas Schier Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Tue, Jun 11, 2024 at 1:39=E2=80=AFAM Rafael Aquini w= rote: > > Newer revisions of rpmbuild are throwing warnings about the current > kernel.spec template having an unversioned kernel-headers in the > 'Obsoletes:' field and not being able to source the epoch's date from > the spec's missing '%changelog' section: > > $ make srcrpm-pkg > UPD include/config/kernel.release > GEN rpmbuild/SPECS/kernel.spec > UPD .tmp_HEAD > ARCHIVE linux.tar.gz > rpmbuild -bs rpmbuild/SPECS/kernel.spec --define=3D'_topdir /mnt/nfs/wo= rk/kernel/linux/rpmbuild' > warning: line 34: It's not recommended to have unversioned Obsoletes: O= bsoletes: kernel-headers > warning: source_date_epoch_from_changelog set but %changelog is missing > Wrote: /mnt/nfs/work/kernel/linux/rpmbuild/SRPMS/kernel-6.10.0_rc3-1.sr= c.rpm > > RPM build warnings: > line 34: It's not recommended to have unversioned Obsoletes: Obsole= tes: kernel-headers > source_date_epoch_from_changelog set but %changelog is missing > > This patch addresses both RPM build warnings. > > Signed-off-by: Rafael Aquini > --- > scripts/package/kernel.spec | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/scripts/package/kernel.spec b/scripts/package/kernel.spec > index e095eb1e290e..4d58b29c03ad 100644 > --- a/scripts/package/kernel.spec > +++ b/scripts/package/kernel.spec > @@ -1,3 +1,5 @@ > +%global source_date_epoch_from_changelog 0 > Another possibility might be to add %changelog section. In Debian packaging, debian/changelog is a requirement. scripts/package/mkdebian generates a very small debian/changelog with a single log entry. > # _arch is undefined if /usr/lib/rpm/platform/*/macros was not included. > %{!?_arch: %define _arch dummy} > %{!?make: %define make make} > @@ -27,7 +29,7 @@ The Linux Kernel, the operating system core itself > %package headers > Summary: Header files for the Linux kernel for use by glibc > Group: Development/System > -Obsoletes: kernel-headers > +Obsoletes: kernel-headers < %{version} No objection to this fix. > Provides: kernel-headers =3D %{version} > %description headers > Kernel-headers includes the C header files that specify the interface > -- > 2.45.1 > --=20 Best Regards Masahiro Yamada