Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 687028 - www-client/firefox-67.0 - with make option "-j1": thread 'main' panicked at 'failed printing to stdout: Resource temporarily unavailable (os error 11)'
Summary: www-client/firefox-67.0 - with make option "-j1": thread 'main' panicked at '...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Mozilla Gentoo Team
URL:
Whiteboard:
Keywords:
: 692396 695874 696920 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-05-30 18:24 UTC by Pistos
Modified: 2019-12-02 18:55 UTC (History)
8 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Firefox 67.0 build log (www-client:firefox-67.0:20190530-170701.log.bz2,62.26 KB, application/x-bzip)
2019-05-30 18:29 UTC, Pistos
Details
emerge --info (emerge-info.txt,6.38 KB, text/plain)
2019-05-30 18:31 UTC, Pistos
Details
output of emerge --info (emerge--info.arm,5.29 KB, text/plain)
2019-06-03 16:36 UTC, tt_1
Details
compressed build log (build.log.gz,115.10 KB, application/gzip)
2019-06-03 16:38 UTC, tt_1
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Pistos 2019-05-30 18:24:03 UTC
www-client/firefox-67.0 does not emerge.

Full build log and emerge info at https://bpaste.net/show/1e2192eaa3c2 .
Comment 1 Jeroen Roovers (RETIRED) gentoo-dev 2019-05-30 18:26:54 UTC
(In reply to Pistos from comment #0)
> www-client/firefox-67.0 does not emerge.
> 
> Full build log and emerge info at https://bpaste.net/show/1e2192eaa3c2 .

Please attach those to this bug report directly.
Comment 2 Pistos 2019-05-30 18:29:55 UTC
Created attachment 578116 [details]
Firefox 67.0 build log
Comment 3 Pistos 2019-05-30 18:31:02 UTC
Created attachment 578118 [details]
emerge --info
Comment 4 Jory A. Pratt gentoo-dev 2019-05-30 23:15:12 UTC
Rust team please have a look, I am not seeing any failure with 67.0 or 68.0b* on an x86_64 musl setup.
Comment 5 tt_1 2019-06-03 15:38:51 UTC
I do hit the same bug, but on armv7a. Right now I'm trying to finish the build with 

ebuild /usr/portage/www-client/firefox-67.0 install

to see wether this "low level" approach may be helpfull

I opened an issue at rusts upstream
https://github.com/rust-lang/rust/issues/61468

and will upload my emerge --info and build.log in a minute
Comment 6 tt_1 2019-06-03 16:36:43 UTC
Created attachment 578522 [details]
output of emerge --info

this is from arm, but same error
Comment 7 tt_1 2019-06-03 16:38:22 UTC
Created attachment 578526 [details]
compressed build log

same, this from arm but with the same error
Comment 8 Pistos 2019-06-04 01:53:47 UTC
When I changed from MAKEOPTS="-s -j1 -l 2" to MAKEOPTS="-s -j2 -l 3", the emerge finished successfully.  No idea why that would make a difference, but thank you to @tt_1 for suggesting this.  I will update the bug title accordingly.
Comment 9 tt_1 2019-06-04 17:50:42 UTC
I was able to reproduce on amd64 today, using MAKEOPTS="-j1" to trigger. 

Also its possible to resume the compile with ebuild install/merge command, which produces a fully working firefox binary.
Comment 10 tt_1 2019-06-06 17:32:11 UTC
MAKEOPTS="-j2 -l 1" seems to be working as a workaround, if you're working with a memory restrained system and can't go beyond one job at a time.
Comment 11 fkater 2019-08-06 07:47:05 UTC
I have the same issue with firefox-68.0.1. The workaround WFM:

MAKEOPTS="-j5 -l1"

It seems that "-l1" is the critical part here. "-j5" or "-j1" only did not help.
Comment 12 Georgy Yakovlev archtester gentoo-dev 2019-08-21 20:34:24 UTC
*** Bug 692396 has been marked as a duplicate of this bug. ***
Comment 13 Georgy Yakovlev archtester gentoo-dev 2019-08-22 23:46:03 UTC
can you guys try building it without makeopts workaround, but with

FEATURES="-pid-sandbox" ?
Comment 14 Paul Osmialowski 2019-08-23 11:44:00 UTC
@Georgy, I've tried to follow your advice and removed MAKEOPTS introducing FEATURES="-pid-sandbox". Unfortunately, re-building firefox now is failing with different error:

```
18:42.54 [style 0.0.1] cargo:rerun-if-changed=/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff/dist/include/js/Utility.h
18:42.54 [style 0.0.1] cargo:rerun-if-changed=/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff/dist/include/mozilla/Range.h
18:42.54 thread 'main' panicked at 'stack backtrace:
18:42.54    0:       0x556b6ac0f4 - <unknown>
18:42.54    1:       0x556b6b1d14 - <unknown>
18:42.54    2:       0x556b6b1adc - <unknown>
18:42.54    3:       0x556b6b2440 - <unknown>
18:42.54    4:       0x556b6b203c - <unknown>
18:42.55    5:       0x556b6b1fa0 - <unknown>
18:42.55    6:       0x556b6aa764 - <unknown>
18:42.55    7:       0x556b2c9804 - <unknown>
18:42.55    8:       0x556b2f4158 - <unknown>
18:42.55    9:       0x556b6b8ad0 - <unknown>
18:42.55   10:       0x556b390ffc - <unknown>
18:42.55   11:       0x556b2c7e54 - <unknown>
18:42.55   12:       0x556b35e350 - <unknown>
18:42.55   13:       0x556b1181a0 - <unknown>
18:42.55   14:       0x556b1170f8 - <unknown>
18:42.56   15:       0x556b0b84e4 - <unknown>
18:42.56   16:       0x556b0a84a8 - <unknown>
18:42.56   17:       0x556b0e1550 - <unknown>
18:42.56   18:       0x556b0b922c - <unknown>
18:42.56   19:       0x556b6b1ebc - <unknown>
18:42.56   20:       0x556b6b8ad0 - <unknown>
18:42.56   21:       0x556b6b65f0 - <unknown>
18:42.56   22:       0x556b0e3894 - <unknown>
18:42.56   23:       0x7fa62e14f0 - __libc_start_main
18:42.56                                at ../csu/libc-start.c:308
18:42.56   24:       0x556b09c47c - <unknown>
19:32.02 [style 0.0.1] cargo:rerun-if-changed=/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff/dist/include/nsIRunnable.h
19:32.03 gmake[4]: *** [/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/config/makefiles/rust.mk:240: force-cargo-library-build] Error 101
19:32.03 gmake[4]: Leaving directory '/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff/toolkit/library/rust'
19:32.03 gmake[3]: *** [/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/config/recurse.mk:74: toolkit/library/rust/target] Error 2
19:32.03 gmake[3]: Leaving directory '/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff'
19:32.03 gmake[2]: *** [/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/config/recurse.mk:34: compile] Error 2
19:32.04 gmake[2]: Leaving directory '/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff'
19:32.04 gmake[1]: *** [/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/config/rules.mk:413: default] Error 2
19:32.04 gmake[1]: Leaving directory '/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff'
19:32.04 gmake: *** [client.mk:125: build] Error 2
19:32.06 11 compiler warnings present.
```
Comment 15 Paul Osmialowski 2019-08-23 12:40:52 UTC
The issue above has gone after reboot. Now the old thing is back (when trying FEATURES="-pid-sandbox"):

18:38.92 [style 0.0.1] cargo:rerun-if-changed=/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff/dist/include/js/CallArgs.h
19:38.81 thread 'main' panicked at 'failed printing to stdout: Resource temporarily unavailable (os error 11)', [style 0.0.1] cargo:rerun-if-changed=/var/tmp/portage/www-client/firefox-68.0.2/work/firefox-68.0.2/ff/dist/include/mozilla/ReverseIterator.h
Comment 16 Georgy Yakovlev archtester gentoo-dev 2019-08-24 04:37:13 UTC
thanks, I just had an idea and since you still hit it with pid-sandbox disabled my idea was wrong. still can't reproduce on my machines.

EAGAIN with stdout usually means some program in process tree set non-blocking mode on the inherited file descriptor.

maybe cargo does something like that if -j1 passed, will try poking it.
Comment 17 Karol Ostrovsky 2019-09-18 07:06:41 UTC
I have the same issue with www-client/firefox-68.1.0.  The workaround with MAKEOPTS="-j2 -l1" helped.
Comment 18 Stefan Strogin gentoo-dev 2019-09-30 19:12:06 UTC
*** Bug 695874 has been marked as a duplicate of this bug. ***
Comment 19 tt_1 2019-09-30 19:22:40 UTC
Only MAKEOPTS="-j1" is broken on arm, aarch64 and even amd64. If you can afford it memorywise, go for MAKEOPTS="-j2", it should work.
Comment 20 Georgy Yakovlev archtester gentoo-dev 2019-10-08 18:40:58 UTC
*** Bug 696920 has been marked as a duplicate of this bug. ***
Comment 21 Larry the Git Cow gentoo-dev 2019-10-08 21:14:12 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=dfda5d7a4371ec0a092cd8c37ccf0035318bc503

commit dfda5d7a4371ec0a092cd8c37ccf0035318bc503
Author:     Thomas Deutschmann <whissi@gentoo.org>
AuthorDate: 2019-10-08 21:09:36 +0000
Commit:     Thomas Deutschmann <whissi@gentoo.org>
CommitDate: 2019-10-08 21:13:57 +0000

    mail-client/thunderbird: force at least MAKEOPTS=-j2
    
    Bug: https://bugs.gentoo.org/687028
    Package-Manager: Portage-2.3.76, Repoman-2.3.17
    Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>

 mail-client/thunderbird/thunderbird-60.9.0.ebuild | 8 +++++++-
 mail-client/thunderbird/thunderbird-68.1.1.ebuild | 8 +++++++-
 2 files changed, 14 insertions(+), 2 deletions(-)

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=97644d196d7bd5dba9ab1526df934648b281750d

commit 97644d196d7bd5dba9ab1526df934648b281750d
Author:     Thomas Deutschmann <whissi@gentoo.org>
AuthorDate: 2019-10-08 21:06:26 +0000
Commit:     Thomas Deutschmann <whissi@gentoo.org>
CommitDate: 2019-10-08 21:13:55 +0000

    www-client/firefox: force at least MAKEOPTS=-j2
    
    Bug: https://bugs.gentoo.org/687028
    Package-Manager: Portage-2.3.76, Repoman-2.3.17
    Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>

 www-client/firefox/firefox-60.9.0.ebuild | 9 ++++++++-
 www-client/firefox/firefox-68.1.0.ebuild | 8 +++++++-
 www-client/firefox/firefox-69.0.2.ebuild | 8 +++++++-
 3 files changed, 22 insertions(+), 3 deletions(-)
Comment 22 Larry the Git Cow gentoo-dev 2019-10-08 21:18:50 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/proj/mozilla.git/commit/?id=7145ef907d11a39d6cd06a239d06040ddbdeb2ea

commit 7145ef907d11a39d6cd06a239d06040ddbdeb2ea
Author:     Thomas Deutschmann <whissi@gentoo.org>
AuthorDate: 2019-10-08 21:16:28 +0000
Commit:     Thomas Deutschmann <whissi@gentoo.org>
CommitDate: 2019-10-08 21:16:28 +0000

    www-client/firefox: force at least MAKEOPTS=-j2
    
    Bug: https://bugs.gentoo.org/687028
    Package-Manager: Portage-2.3.76, Repoman-2.3.17
    Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>

 www-client/firefox/firefox-70.0_beta12.ebuild | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
Comment 23 tt_1 2019-10-26 18:44:14 UTC
I got a tip over here: 

https://github.com/rust-lang/rust/issues/57632#issuecomment-546614184 

that this could be solved by the patch in https://bugzilla.mozilla.org/show_bug.cgi?id=1500436

you might want to try?
Comment 24 tt_1 2019-10-27 08:22:09 UTC
I've started a test emerge, and got over the point of failure. So this most likely is your fix.
Comment 25 tt_1 2019-11-01 11:26:17 UTC
the fix is included from firefox-69.0 on, so the hack can be removed from >=firefox-70.0.
Comment 26 tt_1 2019-11-09 21:25:06 UTC
I annoyed a few people at upstream, they uplifted the fix to the upcoming firefox-68.3.0 ; can the reporter please state wether this is also fixing his problem?
Comment 27 Arnold Troeger 2019-11-10 03:13:01 UTC
Trying now.
Comment 28 Georgy Yakovlev archtester gentoo-dev 2019-11-10 20:07:18 UTC
glad it was found finally.
re-assigning bug to mozilla guys, leaving rust@ in cc.
Comment 29 tt_1 2019-12-02 18:34:29 UTC
It's working for me with firefox-68.3.0, and did so too with >=firefox-70.0.1

so, can the hack be removed, please? I'm in need of -j1 on a low end machine.
Comment 30 Larry the Git Cow gentoo-dev 2019-12-02 18:55:49 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d2c5a3099cccc05a7e25c396b768d9bd1057b423

commit d2c5a3099cccc05a7e25c396b768d9bd1057b423
Author:     Thomas Deutschmann <whissi@gentoo.org>
AuthorDate: 2019-12-02 18:55:27 +0000
Commit:     Thomas Deutschmann <whissi@gentoo.org>
CommitDate: 2019-12-02 18:55:42 +0000

    www-client/firefox: dropping -j1 workaround
    
    Closes: https://bugs.gentoo.org/687028
    Package-Manager: Portage-2.3.80, Repoman-2.3.19
    Signed-off-by: Thomas Deutschmann <whissi@gentoo.org>

 www-client/firefox/firefox-68.3.0.ebuild | 8 +-------
 www-client/firefox/firefox-71.0.ebuild   | 8 +-------
 2 files changed, 2 insertions(+), 14 deletions(-)