Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp2020277rwl; Fri, 31 Mar 2023 23:30:19 -0700 (PDT) X-Google-Smtp-Source: AKy350YFwCQHl5NmPi1j7V1/irL1JYnVQ13c8KGz3YWiPmaFwTbdugfMIb88x1J6NttaRP8UOZFu X-Received: by 2002:a17:90a:448a:b0:240:c4e6:2b2f with SMTP id t10-20020a17090a448a00b00240c4e62b2fmr7376967pjg.0.1680330619256; Fri, 31 Mar 2023 23:30:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680330619; cv=none; d=google.com; s=arc-20160816; b=v9dmWxQqhtKeFMNfnLo5dvccSO11S+aNxembDBMbbPTDA4Uo5ITdzSUhHCYguuROre 8+CLzZeiJD+yCfayC4Ulhdd6CcY1fFCMQLpjMSLGKh+U8SMhdJ9Jj1QD+2XCDWamUy2U yRelAS3jBMasfRgOlkGGjkBw257RnO4cKWSJMapxh0WVpKZ61MWt4LelBYbh2DXW7sI6 A6kDqXoIYZIGVmgKKZXDbgHU1lH1urnDtFuQSZwX88+MJhk+3iMOnqsRjaWbr/imJIWX yEU+whmxgNdXdzKVXfM540nByZJMiy1yVWB02VHjgYw2uqu+dx7sh6m+HYG30dFopChq 9f1A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=CL7UTP2fqdeEenfAvHgLQUYHHlUvB4b2aE4mvsLKpn4=; b=huc7EOfkSUt5n06rhywfJw62ipg80BPitjEGYdhdecLJBj85Jar1fgGKS7L+jt6pYY Mw2uJb4hnL4rfWRqUqSJRRVs9oh0fPpvR/nl6EY9EqDWucVqh72Eat9tuGhgacfiERIi ys7ApNeO+nNdnIS+PmWVdPcODwgP+w/Tj8v04UWNTWByMODYu3NHktWRTtwaoG63IkEZ bvvD5IODjkThC43NTNhlu9SAACBDhktqi0IMOUtkrIMUr+GdXQHkMdx4L4vly9NmCamd EuEaeLhKTi05VK61oXIHWCPGajy+MAE4jt90aFHrnmbBrf+NjW6u3Bot0h3gMSZq8Cng XSww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=sci3SLV5; 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 w23-20020a17090aea1700b0023cfb718146si3849318pjy.30.2023.03.31.23.30.06; Fri, 31 Mar 2023 23:30:19 -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=sci3SLV5; 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 S233074AbjDAGW6 (ORCPT + 99 others); Sat, 1 Apr 2023 02:22:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42914 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231926AbjDAGW5 (ORCPT ); Sat, 1 Apr 2023 02:22:57 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9FDC310D3; Fri, 31 Mar 2023 23:22:56 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 2938C603F7; Sat, 1 Apr 2023 06:22:56 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 75DF9C433D2; Sat, 1 Apr 2023 06:22:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1680330175; bh=C4wrTt4zKss+4MIQ4zd/7UCc8iEP633HVcG1T+mQhiY=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=sci3SLV5e2aXT5PUIjsGGDa2+eckoillSpkBvvRdjZlRDGuGJ+Zpp9OXnRfbmQ3fY 9VVezGsnMsZiznZa+bfAdurrfmAosQ9Gsdp0/r7BvPbJux5JcqwdBmyphmsP+RlEJi c4Up6nQnLjcarI/Jrw0v5JEsGuIW4rPk/q2rBaGFmu7nh/slpaFKS8FiLAbiKwSAid 9VlTVg1BZYX1yeJNxGBCnwzhFZBA8P7zMfNH55KCtTV89pQjQuN5u1HHmYSehicHbd wKwC6IzCrXtNwWH3Tx/xyhiKDW6m17KIZbHpk+QKVK64qEzRYQkaJncSUiR2BchEdW OX9U3KgUztNzA== Received: by mail-oi1-f180.google.com with SMTP id l18so18272411oic.13; Fri, 31 Mar 2023 23:22:55 -0700 (PDT) X-Gm-Message-State: AO0yUKXq23bSMMHQW5caKcsjSkHGs39HVRxavlJjmvJoogzOVCMxFjMd 9N5/cC70FmBYRdnVU7Yt+qBlZ1Q1LLrQstIdtI0= X-Received: by 2002:a05:6808:14d5:b0:384:a13:952a with SMTP id f21-20020a05680814d500b003840a13952amr9469531oiw.11.1680330174630; Fri, 31 Mar 2023 23:22:54 -0700 (PDT) MIME-Version: 1.0 References: <1de9eccd-8570-3b69-4be2-347e862bcc33@mailbox.org> In-Reply-To: <1de9eccd-8570-3b69-4be2-347e862bcc33@mailbox.org> From: Masahiro Yamada Date: Sat, 1 Apr 2023 15:22:18 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [Question] Restore previous "local tag" behaviour To: Tor Vic Cc: "linux-kernel@vger.kernel.org" , Linux Kbuild mailing list Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-5.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable 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 On Tue, Mar 28, 2023 at 2:44=E2=80=AFAM Tor Vic wrote= : > > Hi, > > When I'm building my kernels, I used to tag my personal releases with a > similar annotated tag commit as with vanilla kernel, just appending > "-tv" or similar to it, i.e. "v6.3-rc4" becomes "v6.3-rc4-tv". I do not understand what you want to achieve. Let's say you wanted to release "v6.0-rc4-tv", which consists of v6.0-rc4 with 331 extra commits. $ git checkout v6.0-rc5^ HEAD is now at 4ed9c1e971b1 Merge tag 'kbuild-fixes-v6.0-2' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild $ git describe v6.0-rc4-331-g4ed9c1e971b1 $ make kernelrelease 6.0.0-rc4-00331-g4ed9c1e971b1 Then, you released it as "v6.0-rc4-tv". $ git tag -a v6.0-rc4-tv -m "Linux v6.0-rc4-tv" $ make kernelrelease 6.0.0-rc4 Then, kernelrelease becomes clean '6.0.0-rc4'. Is this what you want? It is apparently wrong since there are 331 commits between v6.0-rc4 and v6.0-rc4-tv. That is what 6ab7e1f95e96 _fixed_. The behavior is now clearer and correct. $ git describe v6.3-rc4-174-g2bac7dc169af $ git tag -a v6.3-rc4-tv -m "Linux v6.3-rc4-tv" $ make kernelrelease 6.3.0-rc4-00174-g2bac7dc169af If you wanted to make a "-tv" release, you would want to change the version field in Makefile before tagging. diff --git a/Makefile b/Makefile index da2586d4c728..8639036f5095 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,7 @@ VERSION =3D 6 PATCHLEVEL =3D 3 SUBLEVEL =3D 0 -EXTRAVERSION =3D -rc4 +EXTRAVERSION =3D -rc4-tv NAME =3D Hurr durr I'ma ninja sloth # *DOCUMENTATION* Then, kernelrelease shows it is a "-tv" release. $ make kernelrelease 6.3.0-rc4-tv > This has worked just fine so far, but... > > Since commit 6ab7e1f95e96f0c688ae132b0e9a16c0f206689d ("setlocalversion: > use only the correct release tag for git-describe"), this is not taken > into account anymore, it uses the "git describe" tag instead of using > the actually tagged commit as "kernelrelease". > > Is there a way to restore the previous behaviour without having to > revert this (and preceding) commits? > > I know that we can disable CONFIG_LOCALVERSION_AUTO=3Dy and append > directly to CONFIG_LOCALVERSION, but maybe someone knows how to use the > "old" way of using tags...? > > In other words, when I have a local tag, I want "kernelrelease" to use > just that tag, and when I don't tag anything, it should just use the > standard "git describe" tag. Again, I do not understand. git tag is not stable information. If you call it "a release", you would want to work in the same way with/without git even if most kernel developers are working in a git tree. The mainline kernel, stable-kernel, linux-next are released in https://kernel.org/ (and GitHub allows users to download a tarball of a tagged commit.) A released tarball (of course, there is no tag there), produces the same kernelrelease as the git tree does. You are requiring the kernelrelease be different with/without the *-tv tag. That is not what the release would look like. The mainline kernel and stable kernel increment the version field in Makefile. linux-next has "localversion-next" at the top of the tree. > For the moment I have just reverted the related commits as they don't > serve any purpose for my needs. > > Cheers, > > Tor Vic --=20 Best Regards Masahiro Yamada