mbox series

[Unstable/Noble,0/1] Fix annotation mismatch when bash is used (plan-B: remove arch-has-odm-enabled.sh)

Message ID 20240301091635.1193894-1-masahiro.yamada@canonical.com
Headers show
Series Fix annotation mismatch when bash is used (plan-B: remove arch-has-odm-enabled.sh) | expand

Message

Masahiro Yamada March 1, 2024, 9:16 a.m. UTC
If /bin/sh is a symlink to /bin/bash, the annotation check fails
because debian/scripts/misc/arch-has-odm-enabled.sh always fails.

I am not sure if debian/scripts/misc/arch-has-odm-enabled.sh is
necessary in the first place.

It was introduced by the following commit.

I may have missed something, but I could not understand what
makes CONFIG_UBUNTU_ODM_DRIVERS so special.

Devivative kernels can inherit CONFIG options
(by including annotations, or it should have been possible
with older config fragments).

---------------------->8--------------------------
commit e2655225df60595146886c0f0d75073df5f0db32
Author: Stefan Bader <stefan.bader@canonical.com>
Date:   Fri Jun 11 18:01:28 2021 +0800

    UBUNTU: [Packaging] Add support for ODM drivers

    BugLink: https://bugs.launchpad.net/bugs/1912789

    We want to be able to selectively turn on ODM driver support for those
    kernels/arches we have to but otherwise not inherit this to other
    derivatives. This is done by a new config option which we will have to
    depend on in the new drivers config options. Support is toggled by
    changing a makefile rule variable. The new config option will be hidden
    as long as not at least one of the arches supported turns on the rule
    variable.

    Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
    Acked-by: Marcelo Henrique Cerri <marcelo.cerri@canonical.com>
    Acked-by: Andy Whitcroft <apw@canonical.com>
    Signed-off-by: Kelsey Skunberg <kelsey.skunberg@canonical.com>
    (cherry picked from commit 4aeffc246531a666c1fad1925ebf1a6e68a704e4
    focal)
    Signed-off-by: Chia-Lin Kao (AceLan) <acelan.kao@canonical.com>
    Acked-by: Stefan Bader <stefan.bader@canonical.com>
    Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
    Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
---------------------->8--------------------------



Masahiro Yamada (1):
  UBUNTU: [Packaging] remove debian/scripts/misc/arch-has-odm-enabled.sh

 debian.master/config/annotations            |  2 +-
 debian.master/rules.d/amd64.mk              |  1 -
 debian/rules.d/0-common-vars.mk             |  4 ----
 debian/rules.d/1-maintainer.mk              |  1 -
 debian/rules.d/2-binary-arch.mk             |  3 ---
 debian/scripts/misc/arch-has-odm-enabled.sh | 26 ---------------------
 ubuntu/Kconfig                              |  2 +-
 7 files changed, 2 insertions(+), 37 deletions(-)
 delete mode 100755 debian/scripts/misc/arch-has-odm-enabled.sh

Comments

Masahiro Yamada March 9, 2024, 3:28 a.m. UTC | #1
On Fri, Mar 1, 2024 at 6:16 PM Masahiro Yamada
<masahiro.yamada@canonical.com> wrote:
>
>
> If /bin/sh is a symlink to /bin/bash, the annotation check fails
> because debian/scripts/misc/arch-has-odm-enabled.sh always fails.


Ping?

There are two ways for fixing the bug.
(Plan A or Plan B)





> I am not sure if debian/scripts/misc/arch-has-odm-enabled.sh is
> necessary in the first place.
>
> It was introduced by the following commit.
>
> I may have missed something, but I could not understand what
> makes CONFIG_UBUNTU_ODM_DRIVERS so special.
>
> Devivative kernels can inherit CONFIG options
> (by including annotations, or it should have been possible
> with older config fragments).
>
> ---------------------->8--------------------------
> commit e2655225df60595146886c0f0d75073df5f0db32
> Author: Stefan Bader <stefan.bader@canonical.com>
> Date:   Fri Jun 11 18:01:28 2021 +0800
>
>     UBUNTU: [Packaging] Add support for ODM drivers
>
>     BugLink: https://bugs.launchpad.net/bugs/1912789
>
>     We want to be able to selectively turn on ODM driver support for those
>     kernels/arches we have to but otherwise not inherit this to other
>     derivatives. This is done by a new config option which we will have to
>     depend on in the new drivers config options. Support is toggled by
>     changing a makefile rule variable. The new config option will be hidden
>     as long as not at least one of the arches supported turns on the rule
>     variable.
>
>     Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
>     Acked-by: Marcelo Henrique Cerri <marcelo.cerri@canonical.com>
>     Acked-by: Andy Whitcroft <apw@canonical.com>
>     Signed-off-by: Kelsey Skunberg <kelsey.skunberg@canonical.com>
>     (cherry picked from commit 4aeffc246531a666c1fad1925ebf1a6e68a704e4
>     focal)
>     Signed-off-by: Chia-Lin Kao (AceLan) <acelan.kao@canonical.com>
>     Acked-by: Stefan Bader <stefan.bader@canonical.com>
>     Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
>     Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
> ---------------------->8--------------------------
>
>
>
> Masahiro Yamada (1):
>   UBUNTU: [Packaging] remove debian/scripts/misc/arch-has-odm-enabled.sh
>
>  debian.master/config/annotations            |  2 +-
>  debian.master/rules.d/amd64.mk              |  1 -
>  debian/rules.d/0-common-vars.mk             |  4 ----
>  debian/rules.d/1-maintainer.mk              |  1 -
>  debian/rules.d/2-binary-arch.mk             |  3 ---
>  debian/scripts/misc/arch-has-odm-enabled.sh | 26 ---------------------
>  ubuntu/Kconfig                              |  2 +-
>  7 files changed, 2 insertions(+), 37 deletions(-)
>  delete mode 100755 debian/scripts/misc/arch-has-odm-enabled.sh
>
> --
> 2.40.1
>
Andrea Righi March 9, 2024, 6:40 a.m. UTC | #2
On Fri, Mar 01, 2024 at 06:16:34PM +0900, Masahiro Yamada wrote:
> 
> If /bin/sh is a symlink to /bin/bash, the annotation check fails
> because debian/scripts/misc/arch-has-odm-enabled.sh always fails.
> 
> I am not sure if debian/scripts/misc/arch-has-odm-enabled.sh is
> necessary in the first place.
> 
> It was introduced by the following commit.
> 
> I may have missed something, but I could not understand what
> makes CONFIG_UBUNTU_ODM_DRIVERS so special.
> 
> Devivative kernels can inherit CONFIG options
> (by including annotations, or it should have been possible
> with older config fragments).
> 
> ---------------------->8--------------------------
> commit e2655225df60595146886c0f0d75073df5f0db32
> Author: Stefan Bader <stefan.bader@canonical.com>
> Date:   Fri Jun 11 18:01:28 2021 +0800
> 
>     UBUNTU: [Packaging] Add support for ODM drivers
> 
>     BugLink: https://bugs.launchpad.net/bugs/1912789
> 
>     We want to be able to selectively turn on ODM driver support for those
>     kernels/arches we have to but otherwise not inherit this to other
>     derivatives. This is done by a new config option which we will have to
>     depend on in the new drivers config options. Support is toggled by
>     changing a makefile rule variable. The new config option will be hidden
>     as long as not at least one of the arches supported turns on the rule
>     variable.
> 
>     Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
>     Acked-by: Marcelo Henrique Cerri <marcelo.cerri@canonical.com>
>     Acked-by: Andy Whitcroft <apw@canonical.com>
>     Signed-off-by: Kelsey Skunberg <kelsey.skunberg@canonical.com>
>     (cherry picked from commit 4aeffc246531a666c1fad1925ebf1a6e68a704e4
>     focal)
>     Signed-off-by: Chia-Lin Kao (AceLan) <acelan.kao@canonical.com>
>     Acked-by: Stefan Bader <stefan.bader@canonical.com>
>     Acked-by: Kleber Sacilotto de Souza <kleber.souza@canonical.com>
>     Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
> ---------------------->8--------------------------

I would say let's go with this plan and see if anything breaks.

Honestly I don't expect any breakage, this seems very reasonable and if
something else is really expecting to find the script of the rule
variable, it should be fixed to use the config instead.

Therefore, applied to noble/linux and noble/linux-unstable.

Thanks,
-Andrea