Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 870193 - dev-lang/spidermonkey-91.13.0:91 - error: expected one of ! or ::, found keyword mod
Summary: dev-lang/spidermonkey-91.13.0:91 - error: expected one of ! or ::, found keyw...
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:
Depends on:
Blocks:
 
Reported: 2022-09-15 07:26 UTC by Toralf Förster
Modified: 2022-09-22 02:20 UTC (History)
0 users

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


Attachments
emerge-info.txt (emerge-info.txt,18.30 KB, text/plain)
2022-09-15 07:26 UTC, Toralf Förster
Details
dev-lang:spidermonkey-91.13.0:20220914-222053.log.bz2 (dev-lang:spidermonkey-91.13.0:20220914-222053.log.bz2,38.83 KB, application/x-bzip)
2022-09-15 07:26 UTC, Toralf Förster
Details
emerge-history.txt (emerge-history.txt,97.96 KB, text/plain)
2022-09-15 07:26 UTC, Toralf Förster
Details
environment (environment,147.96 KB, text/plain)
2022-09-15 07:26 UTC, Toralf Förster
Details
etc.portage.tar.bz2 (etc.portage.tar.bz2,11.68 KB, application/x-bzip)
2022-09-15 07:26 UTC, Toralf Förster
Details
logs.tar.bz2 (logs.tar.bz2,14.40 KB, application/x-bzip)
2022-09-15 07:26 UTC, Toralf Förster
Details
temp.tar.bz2 (temp.tar.bz2,72.34 KB, application/x-bzip)
2022-09-15 07:26 UTC, Toralf Förster
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Toralf Förster gentoo-dev 2022-09-15 07:26:05 UTC
/var/tmp/portage/dev-lang/spidermonkey-91.13.0/work/firefox-91.13.0/js/src/debugger/Environment.cpp:144:29: note: 'environment' declared here
  144 |   RootedDebuggerEnvironment environment(
      |                             ^~~~~~~~~~~
/var/tmp/portage/dev-lang/spidermonkey-91.13.0/work/firefox-91.13.0/js/src/debugger/Environment.cpp:144:29: note: 'cx' declared here
error: expected one of `!` or `::`, found keyword `mod`
   --> /var/tmp/portage/dev-lang/spidermonkey-91.13.0/work/firefox-91.13.0/third_party/rust/packed_simd/src/lib.rs:337:7
    |

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.1_desktop_gnome_systemd-j4-20220913-150005

  -------------------------------------------------------------------

gcc-config -l:
 [1] x86_64-pc-linux-gnu-12.2.0 *
clang/llvm (if any):
clang version 15.0.0
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/lib/llvm/15/bin
/usr/lib/llvm/15
15.0.0
Python 3.10.7
Available Ruby profiles:
  [1]   ruby27 (with Rubygems)
  [2]   ruby31 (with Rubygems) *
Available Rust versions:
  [1]   rust-bin-1.63.0 *
The following VMs are available for generation-2:
*)	OpenJDK 17.0.5_p5 [openjdk-17]
2)	Eclipse Temurin JDK 17.0.4.1_p1 [openjdk-bin-17]
3)	Eclipse Temurin JDK 8.345_p01 [openjdk-bin-8]
Available Java Virtual Machines:
  [1]   openjdk-17  system-vm
  [2]   openjdk-bin-8 
  [3]   openjdk-bin-17 

The Glorious Glasgow Haskell Compilation System, version 9.0.2
php cli (if any):
GNU Make 4.3.90

  HEAD of ::gentoo
commit 8c9fdaf614a76a7b0c11e4df160166594ff92317
Author: Repository mirror & CI <repomirrorci@gentoo.org>
Date:   Wed Sep 14 22:16:58 2022 +0000

    2022-09-14 22:16:58 UTC

emerge -qpvO dev-lang/spidermonkey
[ebuild  N    ] dev-lang/spidermonkey-102.2.0  USE="jit -clang -debug -lto -test"
Comment 1 Toralf Förster gentoo-dev 2022-09-15 07:26:06 UTC
Created attachment 805258 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2022-09-15 07:26:07 UTC
Created attachment 805261 [details]
dev-lang:spidermonkey-91.13.0:20220914-222053.log.bz2
Comment 3 Toralf Förster gentoo-dev 2022-09-15 07:26:08 UTC
Created attachment 805264 [details]
emerge-history.txt
Comment 4 Toralf Förster gentoo-dev 2022-09-15 07:26:10 UTC
Created attachment 805267 [details]
environment
Comment 5 Toralf Förster gentoo-dev 2022-09-15 07:26:12 UTC
Created attachment 805270 [details]
etc.portage.tar.bz2
Comment 6 Toralf Förster gentoo-dev 2022-09-15 07:26:13 UTC
Created attachment 805273 [details]
logs.tar.bz2
Comment 7 Toralf Förster gentoo-dev 2022-09-15 07:26:14 UTC
Created attachment 805276 [details]
temp.tar.bz2
Comment 8 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2022-09-15 22:26:04 UTC
FWIW I heard somewhere 91.13 might be the last in that series but no idea if that's right.
Comment 9 Yun Pan 2022-09-16 11:44:37 UTC
I can confirm this as well. I failed to build spidermonkey 91.13.0 and it gave similar logs... After some digging I found that it may be caused by rust 1.63.0 
ref: https://github.com/rust-lang/packed_simd/issues/343
Comment 10 Joonas Niilola gentoo-dev 2022-09-16 18:45:19 UTC
Yeah upstream has no plans for fixing this on 91, 
https://bugzilla.mozilla.org/show_bug.cgi?id=1783784#c7

I wonder if anything in gentoo tree depends on :91 or if it can be cleaned soon... or we have to find a patch somewhere.
Comment 11 cyrillic 2022-09-16 23:16:57 UTC
For now, this problem can be fixed by commenting-out the "--enable-rust-simd" part in the ebuild. As far as I know, this does not even have much impact on performance.

This also works for spidermonkey-102.2 although I hear that this will not be a problem when ${mozilla}-102.3 is released.
Comment 12 Richard Hanulewicz 2022-09-17 05:24:21 UTC
I have done some investigation into this. On the current testing branch ~amd64, both spidermonkey 91 and 102 are not compiling due to this error. The problem appears to be that spidermonkey tries to pull in Rust crate 'packed_simd_2' version 3.7.0, which is not compatible with Rust 1.63. It looks like 'packed_simd_2' version 3.8.0 may have fixed this according to what I am reading on other forums, so I tried to change the dependency version in the spidermonkey sources myself but Rust wouldn't honor the change due to it changing the checksome of the Cargo.toml file. 

I really didn't feel like figuring out Rust's patch system just to get my system up and running so I settled for ...

... the easy solution: Mask Rust 1.63.
Comment 13 Joonas Niilola gentoo-dev 2022-09-17 05:30:46 UTC
(In reply to cyrillic from comment #11)
> For now, this problem can be fixed by commenting-out the
> "--enable-rust-simd" part in the ebuild. As far as I know, this does not
> even have much impact on performance.

I actually think this is the best solution for now... until something else breaks. Since SM-91 will not get any kind of releases from upstream.


> 
> This also works for spidermonkey-102.2 although I hear that this will not be
> a problem when ${mozilla}-102.3 is released.

Yeah this particular error is fixed in 102.3.
Comment 14 Larry the Git Cow gentoo-dev 2022-09-17 06:50:06 UTC
The bug has been closed via the following commit(s):

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

commit 0538461291fdff27fe805d20eea2975ab3a69caf
Author:     Joonas Niilola <juippis@gentoo.org>
AuthorDate: 2022-09-17 06:46:56 +0000
Commit:     Joonas Niilola <juippis@gentoo.org>
CommitDate: 2022-09-17 06:50:03 +0000

    dev-lang/spidermonkey: fix compiling 91.13.0 with rust-1.63
    
     - disabling rust-simd from 91.13.0 - while it may have some performance
       issues, it doesn't look like upstream is going to patch 91 series anymore.
    
    Closes: https://bugs.gentoo.org/870193
    Closes: https://github.com/gentoo/gentoo/pull/27085
    Signed-off-by: Joonas Niilola <juippis@gentoo.org>

 dev-lang/spidermonkey/spidermonkey-91.13.0.ebuild | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

Additionally, it has been referenced in the following commit(s):

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

commit c3b8050e2049e643f1a5b7c03cabf2dca104261d
Author:     Joonas Niilola <juippis@gentoo.org>
AuthorDate: 2022-09-17 06:48:34 +0000
Commit:     Joonas Niilola <juippis@gentoo.org>
CommitDate: 2022-09-17 06:50:04 +0000

    dev-lang/spidermonkey: fix compiling 102.2.0 with rust-1.63
    
     - by disabling rust-simd, just a temporary fix for now, 102.3.0 release will
       fix it properly.
    
    Bug: https://bugs.gentoo.org/870193
    Closes: https://github.com/gentoo/gentoo/pull/27085
    Signed-off-by: Joonas Niilola <juippis@gentoo.org>

 dev-lang/spidermonkey/spidermonkey-102.2.0.ebuild | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
Comment 15 Toralf Förster gentoo-dev 2022-09-21 16:12:15 UTC
FWIW dev-lang/spidermonkey-78.15.0 
seems to have the same problem