kbuild: deb-pkg: Fix build error caused by lack of positionnal argument
PATCH 1/1 kbuild: deb-pkg: Fix build error caused by lack of positionnal argument
Since 8ef052389f7f ("kbuild: package: add -e and -u options to some shell scripts"), building a debian package on my arm64 box fails:
$ make -j20 bindeb-pkg UPD include/config/kernel.release GEN debian ./scripts/package/mkdebian: 138: 1: parameter not set make[2]: *** [scripts/Makefile.package:98: debian] Error 2 make[1]: *** [/home/maz/hot-poop/arm-platforms/Makefile:1538: bindeb-pkg] Error 2 make: *** [Makefile:224: __sub-make] Error 2
Applying the same pattern for substitution of undefined variables seems to paper over the issue and brings the script back to life.
--- scripts/package/mkdebian | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
scripts/package/mkdebian +1 -1
@@ -135,7 +135,7 @@ else fi maintainer="${name} <${email}>" -if [ "$1" = --need-source ]; then +if [ "${1:+set}" = --need-source ]; then gen_source fi
Signature · 1 line
2.39.2
Quoted 28 lines · Marc Zyngier
Since
8ef052389f7f("kbuild: package: add -e and -u options to some shell scripts"), building a debian package on my arm64 box fails:$ make -j20 bindeb-pkg UPD include/config/kernel.release GEN debian ./scripts/package/mkdebian: 138: 1: parameter not set make[2]: *** [scripts/Makefile.package:98: debian] Error 2 make[1]: *** [/home/maz/hot-poop/arm-platforms/Makefile:1538: bindeb-pkg] Error 2 make: *** [Makefile:224: __sub-make] Error 2Applying the same pattern for substitution of undefined variables seems to paper over the issue and brings the script back to life.
Fixes 8ef052389f7f ("kbuild: package: add -e and -u options to some shell scripts")Signed-off-by Marc Zyngier <[email protected]>Cc Masahiro Yamada <[email protected]>Cc Nicolas Schier <[email protected]>--- scripts/package/mkdebian | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)scripts/package/mkdebian +0
-0
scripts/package/mkdebian else · line 141
Quoted 8 lines
scripts/package/mkdebian +1
-1@@ -135,7 +135,7 @@ else fi maintainer="${name} <${email}>" -if [ "$1" = --need-source ]; then +if [ "${1:+set}" = --need-source ]; then gen_source fi
This is wrong.
It will break 'make srcdeb-pkg' because
"set" = "--need-source" is always false.
I will squash the following.
while [ $# -gt 0 ]; do
case "$1" in
--need-source)
gen_source
shift
;;
*)
break
;;
esacdone
Thanks for the report.
Signature · 2 lines
Best Regards Masahiro Yamada
Quoted 60 lines · Masahiro Yamada
Quoted 28 lines · Marc Zyngier
Since
8ef052389f7f("kbuild: package: add -e and -u options to some shell scripts"), building a debian package on my arm64 box fails:$ make -j20 bindeb-pkg UPD include/config/kernel.release GEN debian ./scripts/package/mkdebian: 138: 1: parameter not set make[2]: *** [scripts/Makefile.package:98: debian] Error 2 make[1]: *** [/home/maz/hot-poop/arm-platforms/Makefile:1538: bindeb-pkg] Error 2 make: *** [Makefile:224: __sub-make] Error 2Applying the same pattern for substitution of undefined variables seems to paper over the issue and brings the script back to life.
Fixes 8ef052389f7f ("kbuild: package: add -e and -u options to some shell scripts")Signed-off-by Marc Zyngier <[email protected]>Cc Masahiro Yamada <[email protected]>Cc Nicolas Schier <[email protected]>--- scripts/package/mkdebian | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)scripts/package/mkdebian +0
-0scripts/package/mkdebian else · line 141
Quoted 8 lines
scripts/package/mkdebian +1
-1@@ -135,7 +135,7 @@ else fi maintainer="${name} <${email}>" -if [ "$1" = --need-source ]; then +if [ "${1:+set}" = --need-source ]; then gen_source fiThis is wrong.
It will break 'make srcdeb-pkg' because
"set" = "--need-source" is always false.I will squash the following.
while [ $# -gt 0 ]; do
case "$1" in --need-source) gen_source shift ;; *) break ;; esac
Quoted 4 lines
done
Thanks for the report.
This seems to work for me.
M.
Signature · 1 line
Without deviation from the norm, progress is not possible.