[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CA+7wUsxvpRXixzT6WNLQng1rsXMzi9A-wvHGnivMAs5=x2LXOg@mail.gmail.com>
Date: Thu, 3 May 2018 19:08:58 +0200
From: Mathieu Malaterre <malat@...ian.org>
To: Masahiro Yamada <yamada.masahiro@...ionext.com>
Cc: "Malaterre, Mathieu" <malat@...ian.org>,
Riku Voipio <riku.voipio@...aro.org>,
Michal Marek <michal.lkml@...kovi.net>,
linux-kbuild <linux-kbuild@...r.kernel.org>,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] kbuild/debian: Use KBUILD_BUILD_* when set
On Wed, May 2, 2018 at 10:01 PM, Mathieu Malaterre <malat@...ian.org> wrote:
> Be nice to the user and check env vars KBUILD_BUILD_USER &
> KBUILD_BUILD_HOST when those are set.
>
> Since DEBEMAIL accept a syntax where the full name is present, be extra
> nice to user and extract email address only.
>
> Cc: Riku Voipio <riku.voipio@...aro.org>
> Cc: Masahiro Yamada <yamada.masahiro@...ionext.com>
> Signed-off-by: Mathieu Malaterre <malat@...ian.org>
> ---
> v2: update patch since syntax of DEBEMAIL may contain full name
Should be replaced by:
https://lists.debian.org/debian-kernel/2018/05/msg00029.html
> scripts/package/mkdebian | 12 +++++++++++-
> 1 file changed, 11 insertions(+), 1 deletion(-)
>
> diff --git a/scripts/package/mkdebian b/scripts/package/mkdebian
> index 6adb3a16ba3b..3f4e43446db3 100755
> --- a/scripts/package/mkdebian
> +++ b/scripts/package/mkdebian
> @@ -73,9 +73,19 @@ fi
>
> # Try to determine maintainer and email values
> if [ -n "$DEBEMAIL" ]; then
> - email=$DEBEMAIL
> + case "$DEBEMAIL" in
> + *\ * )
> + email=$(echo $DEBEMAIL | cut -d '<' -f2 | cut -d '>' -f1)
> + echo >&2 "Extracting email from DEBEMAIL. Use DEBFULLNAME instead."
> + ;;
> + *)
> + email=$DEBEMAIL
> + ;;
> + esac
> elif [ -n "$EMAIL" ]; then
> email=$EMAIL
> +elif [ -n "$KBUILD_BUILD_USER" ] && [ -n "$KBUILD_BUILD_HOST" ]; then
> + email=$KBUILD_BUILD_USER@...UILD_BUILD_HOST
> else
> email=$(id -nu)@$(hostname -f 2>/dev/null || hostname)
> fi
> --
> 2.11.0
>
Powered by blists - more mailing lists