diff mbox

[1/4,Trusty,meta,SRU] UBUNTU: Add HWE kernel meta packages

Message ID 1416342792-13064-1-git-send-email-tim.gardner@canonical.com
State New
Headers show

Commit Message

Tim Gardner Nov. 18, 2014, 8:33 p.m. UTC
From: Tim Gardner <tim.gardner@canonical.com>

BugLink: http://bugs.launchpad.net/bugs/1393877

We messed up when naming HWE meta packages in Precise. We should have
made those package names unique per LTS release because we cannot
now create a HWE meta package of the same name without also creating an
upgrade path that a user probably does not want. For example, upgrading from
12.04.[2-5] to 14.04 (after 14.04.2 is released) would upgrade to an HWE
kernel instead of the 14.04 GA kernel as expected.

Therefore, the HWE meta package name will be made unique by adding the name
of the LTS release, e.g., linux-image-hwe-generic-trusty.

Update to the next HWE kernel by changing HWE_KERNEL_NAME in debian/rules.

Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
---
 meta-source/debian/control.common | 32 ++++++++++++++++++++++++++++++++
 meta-source/debian/rules          |  3 ++-
 2 files changed, 34 insertions(+), 1 deletion(-)

Comments

Chris J Arges Nov. 19, 2014, 5:01 p.m. UTC | #1
On 11/18/2014 02:33 PM, tim.gardner@canonical.com wrote:
> From: Tim Gardner <tim.gardner@canonical.com>
> 
> BugLink: http://bugs.launchpad.net/bugs/1393877
> 
> We messed up when naming HWE meta packages in Precise. We should have
> made those package names unique per LTS release because we cannot
> now create a HWE meta package of the same name without also creating an
> upgrade path that a user probably does not want. For example, upgrading from
> 12.04.[2-5] to 14.04 (after 14.04.2 is released) would upgrade to an HWE
> kernel instead of the 14.04 GA kernel as expected.
> 
> Therefore, the HWE meta package name will be made unique by adding the name
> of the LTS release, e.g., linux-image-hwe-generic-trusty.
> 
> Update to the next HWE kernel by changing HWE_KERNEL_NAME in debian/rules.
> 
> Signed-off-by: Tim Gardner <tim.gardner@canonical.com>
> ---
>  meta-source/debian/control.common | 32 ++++++++++++++++++++++++++++++++
>  meta-source/debian/rules          |  3 ++-
>  2 files changed, 34 insertions(+), 1 deletion(-)
> 
> diff --git a/meta-source/debian/control.common b/meta-source/debian/control.common
> index 0ae5386..827dbec 100644
> --- a/meta-source/debian/control.common
> +++ b/meta-source/debian/control.common
> @@ -358,3 +358,35 @@ Priority: optional
>  Depends: ${misc:Depends}, linux-signed-generic
>  Description: Complete Signed Generic Linux kernel and headers
>   Transistional package for upgrades from 12.04 to 14.04 (Precise to Trusty)
> +
> +#
> +# Reference the current Hardware Enablement LTS generic and virtual kernel flavours.
> +#
> +Package: linux-image-hwe-generic-trusty
> +Architecture: i386 amd64 armhf arm64 powerpc ppc64el
> +Section: kernel
> +Priority: optional
> +Depends: ${misc:Depends}, linux-image-generic-lts-HWE_KERNEL_NAME
> +Description: Depends on the generic hardware enablement kernel image.
> +
> +Package: linux-hwe-generic-trusty
> +Architecture: i386 amd64 armhf arm64 powerpc ppc64el
> +Section: kernel
> +Priority: optional
> +Depends: ${misc:Depends}, linux-image-hwe-generic-trusty, linux-headers-generic-lts-HWE_KERNEL_NAME
> +Description: Depends on the generic hardware enablement kernel image and headers.
> +
> +Package: linux-image-hwe-virtual-trusty
> +Architecture: i386 amd64 armhf arm64 powerpc ppc64el
> +Section: kernel
> +Priority: optional
> +Depends: ${misc:Depends}, linux-image-virtual-lts-HWE_KERNEL_NAME
> +Description: Depends on the virtual hardware enablement kernel image.
> +
> +Package: linux-hwe-virtual-trusty
> +Architecture: i386 amd64 armhf arm64 powerpc ppc64el
> +Section: kernel
> +Priority: optional
> +Depends: ${misc:Depends}, linux-image-hwe-virtual-trusty, linux-headers-virtual-lts-HWE_KERNEL_NAME
> +Description: Depends on the virtual hardware enablement kernel image and headers.
> +
> diff --git a/meta-source/debian/rules b/meta-source/debian/rules
> index b3d3a01..d69dd70 100755
> --- a/meta-source/debian/rules
> +++ b/meta-source/debian/rules
> @@ -8,6 +8,7 @@
>  #
>  
>  RELEASE_NAME=saucy
> +HWE_KERNEL_NAME=utopic
>  

I understand the need to have the -trusty postfix on the kernel; however
when we re-use this code for the 16.04 release we'll need to ensure that
-trusty is replaced with the proper string. Why not re-use the
RELEASE_NAME variable and the sed operation below?

--chris

>  # 5 digit versions (2.6.38.<abi>.<upload>, 3 digit kernel base versions (2.6.38)
>  KERNEL_VERSION=$(shell dpkg-parsechangelog | grep ^Version | sed -e \
> @@ -43,7 +44,7 @@ clean: debian/control
>  debian/control: $(control_files)
>  	rm -f debian/control.tmp
>  	for i in $^; do \
> -		sed 's/RELEASE_NAME/$(RELEASE_NAME)/g' $$i >> debian/control.tmp; \
> +		sed -e 's/RELEASE_NAME/$(RELEASE_NAME)/g' -e 's/HWE_KERNEL_NAME/$(HWE_KERNEL_NAME)/g' $$i >> debian/control.tmp; \
>  		echo >> debian/control.tmp; \
>  	done
>  	rm -f $@
>
diff mbox

Patch

diff --git a/meta-source/debian/control.common b/meta-source/debian/control.common
index 0ae5386..827dbec 100644
--- a/meta-source/debian/control.common
+++ b/meta-source/debian/control.common
@@ -358,3 +358,35 @@  Priority: optional
 Depends: ${misc:Depends}, linux-signed-generic
 Description: Complete Signed Generic Linux kernel and headers
  Transistional package for upgrades from 12.04 to 14.04 (Precise to Trusty)
+
+#
+# Reference the current Hardware Enablement LTS generic and virtual kernel flavours.
+#
+Package: linux-image-hwe-generic-trusty
+Architecture: i386 amd64 armhf arm64 powerpc ppc64el
+Section: kernel
+Priority: optional
+Depends: ${misc:Depends}, linux-image-generic-lts-HWE_KERNEL_NAME
+Description: Depends on the generic hardware enablement kernel image.
+
+Package: linux-hwe-generic-trusty
+Architecture: i386 amd64 armhf arm64 powerpc ppc64el
+Section: kernel
+Priority: optional
+Depends: ${misc:Depends}, linux-image-hwe-generic-trusty, linux-headers-generic-lts-HWE_KERNEL_NAME
+Description: Depends on the generic hardware enablement kernel image and headers.
+
+Package: linux-image-hwe-virtual-trusty
+Architecture: i386 amd64 armhf arm64 powerpc ppc64el
+Section: kernel
+Priority: optional
+Depends: ${misc:Depends}, linux-image-virtual-lts-HWE_KERNEL_NAME
+Description: Depends on the virtual hardware enablement kernel image.
+
+Package: linux-hwe-virtual-trusty
+Architecture: i386 amd64 armhf arm64 powerpc ppc64el
+Section: kernel
+Priority: optional
+Depends: ${misc:Depends}, linux-image-hwe-virtual-trusty, linux-headers-virtual-lts-HWE_KERNEL_NAME
+Description: Depends on the virtual hardware enablement kernel image and headers.
+
diff --git a/meta-source/debian/rules b/meta-source/debian/rules
index b3d3a01..d69dd70 100755
--- a/meta-source/debian/rules
+++ b/meta-source/debian/rules
@@ -8,6 +8,7 @@ 
 #
 
 RELEASE_NAME=saucy
+HWE_KERNEL_NAME=utopic
 
 # 5 digit versions (2.6.38.<abi>.<upload>, 3 digit kernel base versions (2.6.38)
 KERNEL_VERSION=$(shell dpkg-parsechangelog | grep ^Version | sed -e \
@@ -43,7 +44,7 @@  clean: debian/control
 debian/control: $(control_files)
 	rm -f debian/control.tmp
 	for i in $^; do \
-		sed 's/RELEASE_NAME/$(RELEASE_NAME)/g' $$i >> debian/control.tmp; \
+		sed -e 's/RELEASE_NAME/$(RELEASE_NAME)/g' -e 's/HWE_KERNEL_NAME/$(HWE_KERNEL_NAME)/g' $$i >> debian/control.tmp; \
 		echo >> debian/control.tmp; \
 	done
 	rm -f $@