Jump to content

0ad SVN - "ERROR: SpiderMonkey build failed"


zyli
 Share

Recommended Posts

$ svn cleanup 0ad

$ svn up 0ad
Updating '0ad':
W wersji 27434.

$ cd 0ad/build/workspaces/

$ ./clean-workspaces.sh 
Cleaning bundled third-party dependencies...
Cleaning Premake5
Cleaning lua-lib
Cleaning luashim-lib
Cleaning zlib-lib
Cleaning zip-lib
Cleaning mbedtls-lib
Cleaning curl-lib
Cleaning example
Cleaning luasocket
Cleaning Premake5
Cleaning lua-lib
Cleaning luashim-lib
Cleaning zlib-lib
Cleaning zip-lib
Cleaning mbedtls-lib
Cleaning curl-lib
Cleaning example
Cleaning luasocket
Cleaning Premake5
Cleaning lua-lib
Cleaning luashim-lib
Cleaning zlib-lib
Cleaning zip-lib
Cleaning mbedtls-lib
Cleaning curl-lib
Cleaning example
Cleaning luasocket
Removing generated stub and test files...
Cleaning build output...

Done. Try running update-workspaces.sh again now.


$ ./update-workspaces.sh 
Updating bundled third-party dependencies...

Building FCollada...

FCollada/FCollada.cpp
FCollada/FColladaPlugin.cpp

[... cut ...]
      
output/libFColladaSR.a

Building SpiderMonkey...

SpiderMonkey build options: --disable-tests
           --disable-jemalloc
           --disable-js-shell
           --without-intl-api
           --enable-shared-js
           --disable-jitspew         
patching file js/src/moz.build
patching file js/src/old-configure
Creating Python 3 environment
created virtual environment CPython3.10.9.final.0-64 in 43ms
  creator CPython3Posix(dest=/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common, clear=False, no_vcs_ignore=False, global=False)
  seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/home/domowy/.local/share/virtualenv)
    added seed packages: pip==20.3.1, setuptools==51.0.0, wheel==0.36.1
  activators BashActivator,CShellActivator,FishActivator,PowerShellActivator,PythonActivator,XonshActivator
/usr/lib/python3/dist-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
Traceback (most recent call last):
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/../js/src/../../configure.py", line 226, in <module>
    sys.exit(main(sys.argv))
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/../js/src/../../configure.py", line 50, in main
    sandbox.run(os.path.join(os.path.dirname(__file__), "moz.configure"))
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 497, in run
    self.include_file(path)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 488, in include_file
    exec_(code, self)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 56, in exec_
    exec(object, globals, locals)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/moz.configure", line 7, in <module>
    include("build/moz.configure/init.configure")
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 848, in include_impl
    self.include_file(what)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 488, in include_file
    exec_(code, self)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 56, in exec_
    exec(object, globals, locals)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build/moz.configure/init.configure", line 234, in <module>
    def virtualenv_python3(env_python, build_env, mozconfig, help):
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 831, in decorator
    depends = DependsFunction(self, func, dependencies, when=when)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 132, in __init__
    sandbox._value_for(self)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 609, in _value_for
    return self._value_for_depends(obj)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 1050, in method_call
    cache[args] = self.func(instance, *args)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 618, in _value_for_depends
    value = obj.result()
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 1050, in method_call
    cache[args] = self.func(instance, *args)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 157, in result
    return self._func(*resolved_args)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 1287, in wrapped
    return new_func(*args, **kwargs)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build/moz.configure/init.configure", line 345, in virtualenv_python3
    manager.build(python)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/virtualenv.py", line 434, in build
    self.create(python)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/virtualenv.py", line 269, in create
    self._disable_pip_outdated_warning()
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/virtualenv.py", line 607, in _disable_pip_outdated_warning
    for file in os.listdir(site_packages)
FileNotFoundError: [Errno 2] No such file or directory: '/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/local/lib/python3.10/dist-packages'
ERROR: SpiderMonkey build failed

System: Debian testing (Bookworm).

$ python3 --version
Python 3.10.9

dpkg -l python3-pip
[.. cut ...]
ii  python3-pip    22.3.1+dfsg-1 all          Python package installer

The previous version (27404) built correctly.

Regards.

Link to comment
Share on other sites

1 hour ago, zyli said:

$ python3 --version
Python 3.10.9

I can build it with 3.10.9 just fine. Possibly a debian specific issues wrt venv.

@Freagarach @dave_k @vv221

sorry to ping you guys but your are the only debian users that come to mind possibly able to investigate and fix this.

The local in

/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/local/lib/python3.10/dist-packages

looks suspicious

Link to comment
Share on other sites

4 hours ago, Freagarach said:

Yeah, I encountered this as well (on python3.11.1). Also: https://trac.wildfiregames.com/ticket/6676 and https://irclogs.wildfiregames.com/%230ad-dev/2023-01-11-QuakeNet-%230ad-dev.log in the morning. I haven't dived deep in this yet (and not my speciality).

Maybe installing venv and pip via package manager will do?

For the removed universal newline issue in python 3.11 I just wrote a patch and I'm now building ...

 

Edit: looking at debian package index, should be python3-virtualenv and python3-pip. Hopefully this prevents the use of bundled venv.

Edited by hyperion
Link to comment
Share on other sites

Unfortunately.

After installing python3-virtualenv - still the same.

dpkg -l python3-virtualenv python3-pip
[...]
+++-==================-=============-============-==================================
ii  python3-pip        22.3.1+dfsg-1 all          Python package installer
ii  python3-virtualenv 20.17.1+ds-1  all          Python virtual environment creator


svn cleanup 0ad

svn up 0ad
Updating '0ad':
W wersji 27439.

cd 0ad/build/workspaces/

./clean-workspaces.sh
[...]

./update-workspaces.sh
[...]

FileNotFoundError: [Errno 2] No such file or directory: '/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/local/lib/python3.10/dist-packages'
ERROR: SpiderMonkey build failed



 

Link to comment
Share on other sites

Was a shot in the blue, thanks for trying.

Looking at the 0ad source mac seems to suffer the same or similar issue as debian and @wraitii solved it by manually updating the bundled venv and injecting it into the build. This has a decent chance to work. Bellow a patch you can give a try. Apply it on top of your svn checkout.

debian-python.patch

Link to comment
Share on other sites

I found some time and tried it.
Unfortunately.
It did not work.
I did it like this:

cd svn

ls -l debian-python.patch 
-rw-r--r-- 1 domowy domowy 7224 01-14 10:02 debian-python.patch

md5sum debian-python.patch 
578798e068535cd54d36dfb92a2c3498  debian-python.patch

cd 0ad/

patch -p1 < ../debian-python.patch 
patching file libraries/source/spidermonkey/Fix-use-of-removed-U-support-in-python-3.11.patch
patching file libraries/source/spidermonkey/patch.sh

cd ..
                                  
svn cleanup 0ad
                                  
svn up 0ad
Updating '0ad':
W wersji 27439.
                                  
cd 0ad/build/workspaces/
                                  
./clean-workspaces.sh 
[...]     
                                  
./update-workspaces.sh
[...]
output/libFColladaSR.a

Building SpiderMonkey...

SpiderMonkey build options: --disable-tests
           --disable-jemalloc
           --disable-js-shell
           --without-intl-api
           --enable-shared-js
           --disable-jitspew         
patching file js/src/moz.build
patching file js/src/old-configure
Collecting virtualenv
  Downloading virtualenv-20.17.1-py3-none-any.whl (8.8 MB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 8.8/8.8 MB 3.1 MB/s eta 0:00:00
Collecting filelock<4,>=3.4.1
  Downloading filelock-3.9.0-py3-none-any.whl (9.7 kB)
Collecting platformdirs<3,>=2.4
  Downloading platformdirs-2.6.2-py3-none-any.whl (14 kB)
Collecting distlib<1,>=0.3.6
  Downloading distlib-0.3.6-py2.py3-none-any.whl (468 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 468.5/468.5 kB 2.4 MB/s eta 0:00:00
Installing collected packages: distlib, platformdirs, filelock, virtualenv
Successfully installed distlib-0.3.6 filelock-3.9.0 platformdirs-2.6.2 virtualenv-20.17.1
patching file python/mozbuild/mozbuild/virtualenv.py
Creating Python 3 environment
created virtual environment CPython3.10.9.final.0-64 in 423ms
  creator CPython3Posix(dest=/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common, clear=False, no_vcs_ignore=False, global=False)
  seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/home/domowy/.local/share/virtualenv)
    added seed packages: pip==22.3.1, setuptools==65.6.3, wheel==0.38.4
  activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator
/usr/lib/python3/dist-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
Traceback (most recent call last):
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/../js/src/../../configure.py", line 226, in <module>
    sys.exit(main(sys.argv))
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/../js/src/../../configure.py", line 50, in main
    sandbox.run(os.path.join(os.path.dirname(__file__), "moz.configure"))
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 497, in run
    self.include_file(path)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 488, in include_file
    exec_(code, self)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 56, in exec_
    exec(object, globals, locals)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/moz.configure", line 7, in <module>
    include("build/moz.configure/init.configure")
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 848, in include_impl
    self.include_file(what)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 488, in include_file
    exec_(code, self)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 56, in exec_
    exec(object, globals, locals)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build/moz.configure/init.configure", line 234, in <module>
    def virtualenv_python3(env_python, build_env, mozconfig, help):
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 831, in decorator
    depends = DependsFunction(self, func, dependencies, when=when)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 132, in __init__
    sandbox._value_for(self)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 609, in _value_for
    return self._value_for_depends(obj)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 1050, in method_call
    cache[args] = self.func(instance, *args)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 618, in _value_for_depends
    value = obj.result()
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/util.py", line 1050, in method_call
    cache[args] = self.func(instance, *args)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 157, in result
    return self._func(*resolved_args)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/configure/__init__.py", line 1287, in wrapped
    return new_func(*args, **kwargs)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build/moz.configure/init.configure", line 345, in virtualenv_python3
    manager.build(python)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/virtualenv.py", line 435, in build
    self.create(python)
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/virtualenv.py", line 270, in create
    self._disable_pip_outdated_warning()
  File "/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/python/mozbuild/mozbuild/virtualenv.py", line 608, in _disable_pip_outdated_warning
    for file in os.listdir(site_packages)
FileNotFoundError: [Errno 2] No such file or directory: '/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/local/lib/python3.10/dist-packages'
ERROR: SpiderMonkey build failed
                                  
                                  
                                  
                                  

 

It still is:

ERROR: SpiderMonkey build failed

Regards

Link to comment
Share on other sites

Ver. 27442 - no changes

 

FileNotFoundError: [Errno 2] No such file or directory: '/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/local/lib/python3.10/dist-packages'
ERROR: SpiderMonkey build failed


 

Link to comment
Share on other sites

4 hours ago, zyli said:

Ver. 27442 - no changes

 

FileNotFoundError: [Errno 2] No such file or directory: '/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/local/lib/python3.10/dist-packages'
ERROR: SpiderMonkey build failed

Just looked at fedoras 0ad package, they explicitly set a dependency on python3-setuptools but don't do anything further with it, maybe installing that package may help

Edit: There seems to be also a python3-setuptools-whl package in debian.

Edited by hyperion
Link to comment
Share on other sites

These packages are already installed:

dpkg -l | grep setuptools
ii  python3-pbr                               5.10.0-2                        all          inject useful and sensible default behaviors into setuptools - Python 3.x
ii  python3-setuptools                        65.5.0-1.1                      all          Python3 Distutils Enhancements
ii  python3-setuptools-whl                    65.5.0-1.1                      all          Python Distutils Enhancements (wheel package)

 

Link to comment
Share on other sites

Results:

python3
Python 3.10.9 (main, Dec  7 2022, 13:47:07) [GCC 12.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import sysconfig
>>> sysconfig.get_default_scheme()
'posix_local'
>>> sysconfig.get_scheme_names()
('deb_system', 'nt', 'nt_user', 'osx_framework_user', 'posix_home', 'posix_local', 'posix_prefix', 'posix_user')
>>> sysconfig._get_preferred_schemes()
{'prefix': 'posix_local', 'home': 'posix_home', 'user': 'posix_user'}
>>> 

and

dpkg -l python3-distutils
[...]
+++-=================-============-============-=================================
ii  python3-distutils 3.10.8-1     all          distutils package for Python 3.x

 

I would like to add that I compile 0AD with SVN quite regularly (weekly?).
All previous builds worked fine up to rev. 27404 incl.
In my case from rev. 27434 problems started - "ERROR: SpiderMonkey build failed".
According to:

https://trac.wildfiregames.com/log/ps?rev=27445

in rev. 27409 made: "[SM91] Update to Spidermonkey 91.1.3".


I believe this is the reason for my failures.
-------------------------------------------

P.S.
The system Debian testing/Bookworm 64bit is up to date.
There is enough disk space (approx. 48 GB for /home/, 23 GB for root).
The filesystem is linux ext4.
I guess that's all.


Regards and thank you for taking the time for me.

Edited by zyli
Link to comment
Share on other sites

Unfortunately, it didn't work.

 

cd svn

echo $DEB_PYTHON_INSTALL_LAYOUT

export DEB_PYTHON_INSTALL_LAYOUT='deb'

echo $DEB_PYTHON_INSTALL_LAYOUT
deb

svn cleanup 0ad

svn up 0ad
Updating '0ad':
W wersji 27447.

echo $DEB_PYTHON_INSTALL_LAYOUT
deb

cd 0ad/build/workspaces/

./clean-workspaces.sh 
[...]
Done. Try running update-workspaces.sh again now.

echo $DEB_PYTHON_INSTALL_LAYOUT
deb

./update-workspaces.sh 
[...]
FileNotFoundError: [Errno 2] No such file or directory: '/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/lib/python3/dist-packages'
ERROR: SpiderMonkey build failed

echo $DEB_PYTHON_INSTALL_LAYOUT
deb

 

  • Sad 1
Link to comment
Share on other sites

Something has changed: the path given by the "FileNotFound" error message earlier:

'/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/local/lib/python3.10/dist-packages'

has now lost its "local" subpath

'/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/lib/python3/dist-packages'

One step forward!

 

@zyli, would I be right in thinking that if you go to

/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/lib/python3

 there is a "site-packages" subdirectory but not "dist-packages"?

Link to comment
Share on other sites

@s0600204
------------

In directory 

/home/domowy/svn/0ad/libraries/source/spidermonkey/mozjs-91.13.1/build-debug/_virtualenvs/common/lib/

there is a directory:

python3.10/        (only one)

and it has one subdirectory:

site-packages/ 

 

@hyperion
------------

Daily build is more of a sid.

There should be a weekly-build (testing) on Monday morning:

https://cdimage.debian.org/cdimage/weekly-builds/amd64/iso-dvd/

 

Regards

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...