linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Christian Borntraeger <borntraeger@de.ibm.com>
To: Kees Cook <keescook@chromium.org>, Jonathan Corbet <corbet@lwn.net>
Cc: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>,
	linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org,
	Heiko Carstens <heiko.carstens@de.ibm.com>,
	Vasily Gorbik <gor@linux.ibm.com>,
	Linux-Next Mailing List <linux-next@vger.kernel.org>,
	Stephen Rothwell <sfr@canb.auug.org.au>
Subject: Re: [PATCH v3] docs: Use make invocation's -j argument for parallelism
Date: Fri, 4 Oct 2019 12:58:49 +0200	[thread overview]
Message-ID: <db3becb5-805f-b215-6c37-7b4db1fbd72f@de.ibm.com> (raw)
In-Reply-To: <0d2433cc-8f97-174f-4835-1fead9e7fe16@de.ibm.com>



On 04.10.19 10:04, Christian Borntraeger wrote:
> 
> On 25.09.19 01:29, Kees Cook wrote:
>> While sphinx 1.7 and later supports "-jauto" for parallelism, this
>> effectively ignores the "-j" flag used in the "make" invocation, which
>> may cause confusion for build systems. Instead, extract the available
>> parallelism from "make"'s job server (since it is not exposed in any
>> special variables) and use that for the "sphinx-build" run. Now things
>> work correctly for builds where -j is specified at the top-level:
>>
>> 	make -j16 htmldocs
>>
>> If -j is not specified, continue to fallback to "-jauto" if available.
>>
>> Signed-off-by: Kees Cook <keescook@chromium.org>
>> ---
>> v3: python2, specific exceptions, correct SPDX, blocking writer
>> v2: retain "-jauto" default behavior with top-level -j is missing.              
> [...]
>> diff --git a/scripts/jobserver-count b/scripts/jobserver-count
>> new file mode 100755
>> index 000000000000..0b482d6884d2
>> --- /dev/null
>> +++ b/scripts/jobserver-count
>> @@ -0,0 +1,58 @@
>> +#!/usr/bin/env python
> 
> 
> This breaks our daily linux-next build for an fedora 30 rpm on s390x:
> 
> + /usr/lib/rpm/redhat/brp-mangle-shebangs
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/profile2linkerlist.pl from /usr/bin/env perl to #!/usr/bin/perl
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/headerdep.pl from /usr/bin/env perl to #!/usr/bin/perl
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/package/buildtar from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/package/builddeb from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/package/mkspec from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/package/mkdebian from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/checksyscalls.sh from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/gen_ksymdeps.sh from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/makelst from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/checkversion.pl from /usr/bin/env perl to #!/usr/bin/perl
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/gcc-plugin.sh from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/gfp-translate from /bin/bash to #!/usr/bin/bash
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/tags.sh from /bin/bash to #!/usr/bin/bash
> *** ERROR: ambiguous python shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/jobserver-count: #!/usr/bin/env python. Change it to python3 (or python2) explicitly.
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/adjust_autoksyms.sh from /bin/sh to #!/usr/bin/sh
> mangling shebang in /usr/src/kernels/5.4.0-20191004.rc1.git155.311ef88adfa3.301.fc30.s390x+next/scripts/kernel-doc from /usr/bin/env perl to #!/usr/bin/perl
> [...]


Ok, adding something like 

+pathfix.py -pni "%{__python3} %{py3_shbang_opts}" scripts/jobserver-count

to the spec file fixed the problem. 

Question is, if we want to make the python version more specific or not.


  reply	other threads:[~2019-10-04 10:58 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-24 23:29 [PATCH v3] docs: Use make invocation's -j argument for parallelism Kees Cook
2019-10-01 12:39 ` Jonathan Corbet
2019-10-04  8:04 ` Christian Borntraeger
2019-10-04 10:58   ` Christian Borntraeger [this message]
2019-10-04  9:15 ` Rasmus Villemoes
2019-10-04 16:08   ` Kees Cook
2019-10-06 19:33     ` Rasmus Villemoes
2019-10-15 20:55       ` Rasmus Villemoes

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=db3becb5-805f-b215-6c37-7b4db1fbd72f@de.ibm.com \
    --to=borntraeger@de.ibm.com \
    --cc=corbet@lwn.net \
    --cc=gor@linux.ibm.com \
    --cc=heiko.carstens@de.ibm.com \
    --cc=keescook@chromium.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=mchehab+samsung@kernel.org \
    --cc=sfr@canb.auug.org.au \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).