All of lore.kernel.org
 help / color / mirror / Atom feed
From: Riku Voipio <riku.voipio@linaro.org>
To: Masahiro Yamada <yamada.masahiro@socionext.com>
Cc: Linux Kbuild mailing list <linux-kbuild@vger.kernel.org>,
	debian-kernel <debian-kernel@lists.debian.org>
Subject: Re: [PATCH v4] scripts/package/builddeb: split generating packaging and build
Date: Wed, 28 Mar 2018 11:58:56 +0300	[thread overview]
Message-ID: <CAAqcGHn6mHHMGmcBFfRdwNSJwPaOfmnidw_T_hRKS66V47aryg@mail.gmail.com> (raw)
In-Reply-To: <CAK7LNASuGcv0rhX+NZ4q7D_hkq7=HqeZ2j5hOiW=F1VXeenwYA@mail.gmail.com>

On 27 March 2018 at 18:23, Masahiro Yamada
<yamada.masahiro@socionext.com> wrote:
> Riku,
>
> 2018-03-27 22:28 GMT+09:00 Riku Voipio <riku.voipio@linaro.org>:
>
>>> If I use GNU Make 4.2
>>>
>>> $ cat deb_pkg_log.txt
>>> MAKEFLAGS for deb-pkg: rR -I/home/masahiro/ref/linux -j8
>>> --jobserver-auth=3,4 --no-print-directory -- obj=scripts/package
>>> MAKEFLAGS for mkdebian internal: rR -I/home/masahiro/ref/linux -j
>>> --jobserver-fds=5,6 --no-print-directory -- obj=scripts/package
>>
>> I'll make a wild guess, and "outside" make is your 4.2 build while the
>> intdeb-pkg ends up calling the make 4.0 that comes with your ubuntu?
>> observe the --jobserver-auth vs ---jobsserver-fds arguments.
>>
>
> Ah, you are right!
>
>
> Probably this
>
>>
>> -if [ "x$1" = "xdeb-pkg" ]
>> -then
>> -    cat <<EOF > debian/rules
>> -#!/usr/bin/make -f

This is actually mandated in Debian policy:

https://www.debian.org/doc/debian-policy/#main-building-script-debian-rules

> So, if I type "make" from the command line, /home/masahiro/bin/make is chosen.
> Then, the outer Makefile is executed by Make 4.2.
>
> But, due to the shebang '#!/usr/bin/make -f'
> debian/rules is executed by older Make.
>
> Due to the incompatibility of MAKEFLAGS, Make went insane.
>
> Hmm, do you have an idea for solution?

One option:

+++ b/scripts/package/mkdebian
cat <<EOF > debian/rules
-#!/usr/bin/make -f
#!$(which $MAKE)  -f

This will let people build with whatever make they please, with the
price that the resulting source package will not build elsewhere.

Option 2 is to error out if "which $MAKE" != /usr/bin/make

> I would be possible to forcibly overwrite MAKEFLAGS

I think one goal is to keep deb-pkg simple, and fudging MAKEFLAGS
would go against that goal.

Riku

  reply	other threads:[~2018-03-28  8:58 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-21 10:10 [PATCH v4] scripts/package/builddeb: split generating packaging and build riku.voipio
2018-03-27  9:07 ` Masahiro Yamada
     [not found]   ` <CAAqcGHkvKssjFmG0ebz5uBeO_PGeov5_C6MutW65ONp5riFwRg@mail.gmail.com>
2018-03-27 13:28     ` Fwd: " Riku Voipio
2018-03-27 15:23       ` Masahiro Yamada
2018-03-28  8:58         ` Riku Voipio [this message]
2018-03-29  0:20           ` Ben Hutchings
2018-03-29  7:36             ` Riku Voipio
2018-04-05  4:37           ` Masahiro Yamada

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAAqcGHn6mHHMGmcBFfRdwNSJwPaOfmnidw_T_hRKS66V47aryg@mail.gmail.com \
    --to=riku.voipio@linaro.org \
    --cc=debian-kernel@lists.debian.org \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=yamada.masahiro@socionext.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.