Patch: Suppress irrelevant warning when generating a debian package
Creating a Debian package by compiling the kernel using make bindeb-pkg without creating debug information creates a warning that no debug package was created.
This patch excludes the debug package from the control file, if no debug package is created by this configuration.
By making a contribution to this project, I certify that:
The contribution was created in whole or in part by me and I have the right to submit it under the open source license indicated in the file.
---
The condition to include the debug package is copied from the file builddeb in the same directory.
scripts/package/mkdebian +0 -0
@@ -198,7 +198,10 @@ Description: Linux support headers for userspace
development
This package provides userspaces headers from the Linux kernel. These
headers
are used by the installed headers for GNU glibc and other system libraries.
Multi-Arch: same
+EOF
+if [ -n "$BUILD_DEBUG" ] ; then
+cat <<EOF >> debian/control
Package: $dbg_packagename
Section: debug
Architecture: $debarch
@@ -206,6 +209,7 @@ Description: Linux kernel debugging symbols for $version
This package will come in handy if you need to debug the kernel. It provides all the necessary debug symbols for the kernel and its modules.
EOF
+fi
cat <<EOF > debian/rules
#!$(command -v $MAKE) -f
Quoted 6 lines · Reinhard Karcher
Creating a Debian package by compiling the kernel using make bindeb-pkg without creating debug information creates a warning that no debug package was created.
This patch excludes the debug package from the control file, if no debug package is created by this configuration.
OK, this seems correct.
Quoted 3 lines
By making a contribution to this project, I certify that:
The contribution was created in whole or in part by me and I have the right to submit it under the open source license indicated in the file.
Please drop this.
Signed-off-by implies this.
No need to explain this in an individual patch.
Quoted 15 lines
Signed-off-by Reinhard Karcher <[email protected]>---
The condition to include the debug package is copied from the file builddeb in the same directory.scripts/package/mkdebian +0
-0@@ -198,7 +198,10 @@ Description: Linux support headers for userspacedevelopment
This package provides userspaces headers from the Linux kernel. These
headers
are used by the installed headers for GNU glibc and other system libraries.
Multi-Arch: same
scripts/package/mkdebian
Quoted 3 lines
scripts/package/mkdebian +2
-0+EOF +if [ -n "$BUILD_DEBUG" ] ; then
This file does not define BUILD_DEBUG.
So, this conditional is always false, isn't it?
It should be:
if is_enabled CONFIG_DEBUG_INFO; then
Quoted 15 lines
scripts/package/mkdebian +2
-0+cat <<EOF >> debian/control Package: $dbg_packagename Section: debug Architecture: $debarch@@ -206,6 +209,7 @@ Description: Linux kernel debugging symbols for $version This package will come in handy if you need to debug the kernel. It provides all the necessary debug symbols for the kernel and its modules. EOF +fi cat <<EOF > debian/rules #!$(command -v $MAKE) -f
Signature · 2 lines
Best Regards Masahiro Yamada
Am Sonntag, 29. März 2020, 14:01 schrieb Masahiro Yamada:
Quoted 9 lines
Quoted 4 lines
By making a contribution to this project, I certify that:
The contribution was created in whole or in part by me and I have the right to submit it under the open source license indicated in the file.Please drop this.
Signed-off-by implies this.
No need to explain this in an individual patch.
Droped in attached new version.
Quoted 9 lines
Quoted 1 line
+if [ -n "$BUILD_DEBUG" ] ; then
This file does not define
BUILD_DEBUG.
So, this conditional is always false, isn't it?It should be:
if
is_enabledCONFIG_DEBUG_INFO; then
The definition of BUILD_DEBUG is copied from builddeb too. See attached patch.
--
Best regards
Reinhard Karcher
from Reinhard.Karcher [email protected]
Creating a Debian package by compiling the kernel make bindeb-pkg
without creating debug information creates a warning that no debug package was created
This patch excludes the debug package from the control file, if no debug package is created by this configuration
scripts/package/mkdebian +5 -0
@@ -96,6 +96,7 @@ fi sourcename=$KDEB_SOURCENAME packagename=linux-image-$version kernel_headers_packagename=linux-headers-$version +BUILD_DEBUG=$(if_enabled_echo CONFIG_DEBUG_INFO Yes) dbg_packagename=$packagename-dbg debarch= set_debarch
@@ -198,7 +199,10 @@ Description: Linux support headers for userspace development This package provides userspaces headers from the Linux kernel. These headers are used by the installed headers for GNU glibc and other system libraries. Multi-Arch: same +EOF +if [ -n "$BUILD_DEBUG" ] ; then +cat <<EOF >> debian/control Package: $dbg_packagename Section: debug Architecture: $debarch
@@ -206,6 +210,7 @@ Description: Linux kernel debugging symbols for $version This package will come in handy if you need to debug the kernel. It provides all the necessary debug symbols for the kernel and its modules. EOF +fi cat <<EOF > debian/rules #!$(command -v $MAKE) -f
Re: Bug#954778: Patch: Suppress irrelevant warning when generating a debian package
Quoted 19 lines · Reinhard Karcher
Am Sonntag, 29. März 2020, 14:01 schrieb Masahiro Yamada:
Quoted 9 lines
Quoted 4 lines
By making a contribution to this project, I certify that:
The contribution was created in whole or in part by me and I have the right to submit it under the open source license indicated in the file.Please drop this.
Signed-off-by implies this.
No need to explain this in an individual patch.Droped in attached new version.
Quoted 5 lines
Quoted 1 line
+if [ -n "$BUILD_DEBUG" ] ; then
This file does not define
BUILD_DEBUG.
So, this conditional is always false, isn't it?
Quoted 7 lines
Quoted 4 lines
It should be:
if
is_enabledCONFIG_DEBUG_INFO; thenThe definition of
BUILD_DEBUGis copied from builddeb too. See attached patch.
No.
I want you to directly use
if is_enabled CONFIG_DEBUG_INFO; then
...
fi
I guess builddeb used BUILD_DEBUG
to avoid running grep twice.
It does not apply to mkdebian.
Signature · 2 lines
Best Regards Masahiro Yamada
Re: Bug#954778: Patch: Suppress irrelevant warning when generating a debian package
Am Sonntag, 29. März 2020, 15:30 schrieb Masahiro Yamada:
Quoted 7 lines
I want you to directly use
if
is_enabledCONFIG_DEBUG_INFO; then
...
fi
Corrected patch attached
--
Best regards
Reinhard Karcher
from Reinhard.Karcher [email protected]
Creating a Debian package by compiling the kernel make bindeb-pkg
without creating debug information creates a warning that no debug package was created
This patch excludes the debug package from the control file, if no debug package is created by this configuration
scripts/package/mkdebian +4 -0
@@ -198,7 +198,10 @@ Description: Linux support headers for userspace development This package provides userspaces headers from the Linux kernel. These headers are used by the installed headers for GNU glibc and other system libraries. Multi-Arch: same +EOF +if is_enabled CONFIG_DEBUG_INFO; then +cat <<EOF >> debian/control Package: $dbg_packagename Section: debug Architecture: $debarch
@@ -206,6 +209,7 @@ Description: Linux kernel debugging symbols for $version This package will come in handy if you need to debug the kernel. It provides all the necessary debug symbols for the kernel and its modules. EOF +fi cat <<EOF > debian/rules #!$(command -v $MAKE) -f
Re: Bug#954778: Patch: Suppress irrelevant warning when generating a debian package
In reply to Masahiro YamadaThere was a blank line missing between the package definitions. Sorry for late testing.
--
Best regards
Reinhard Karcher
from Reinhard.Karcher [email protected]
Creating a Debian package by compiling the kernel make bindeb-pkg
without creating debug information creates a warning that no debug package was created
This patch excludes the debug package from the control file, if no debug package is created by this configuration
scripts/package/mkdebian +5 -0
@@ -198,6 +198,10 @@ Description: Linux support headers for userspace development This package provides userspaces headers from the Linux kernel. These headers are used by the installed headers for GNU glibc and other system libraries. Multi-Arch: same +EOF + +if is_enabled CONFIG_DEBUG_INFO; then +cat <<EOF >> debian/control Package: $dbg_packagename Section: debug
@@ -206,6 +210,7 @@ Description: Linux kernel debugging symbols for $version This package will come in handy if you need to debug the kernel. It provides all the necessary debug symbols for the kernel and its modules. EOF +fi cat <<EOF > debian/rules #!$(command -v $MAKE) -f
Re: Bug#954778: Patch: Suppress irrelevant warning when generating a debian package
Quoted 7 lines · Reinhard Karcher
There was a blank line missing between the package definitions. Sorry for late testing.
--
Best regards
Reinhard Karcher
The attached patch is not in a correct patch format.
This time, I manually crufted the format, and applied.
But, next time, please send it to ML instead of attachment, in a correct format.
git supports useful commands to do this.
[1] "git format-patch" to create a patch
[2] "git send-email" to send it to ML
I reworded the log as follows:
------------------>8---------------
kbuild: deb-pkg: fix warning when CONFIG_DEBUG_INFO is unset
Creating a Debian package without CONFIG_DEBUG_INFO produces a warning that no debug package was created.
This patch excludes the debug package from the control file, if no debug package is created by this configuration.
------------------>8---------------
Signature · 2 lines
Best Regards Masahiro Yamada