Skip to content

Cythonize error when building with nyan #1769

Open
@Urbaner3

Description

@Urbaner3
   13  ./configure --download-nyan
   14  make
   15  make clean
   16  pip3 install cython --break-system-packages
   17  sudo pip3 install cython --break-system-packages
   18  sudo apt install python3-setuptools python3-distutils
   19  pip3 install --user setuptools
   20  sudo apt install python3-stdlib
   21  make
   22  history | tail

When I am building openage in ubuntu 24.10 laptop, the following error message shows up.

urbaner@urbaner-framwork:~/openage$ make cythonize 
make --no-print-directory -C bin cythonize
[  0%] cythonize.py: compiling .pyx files to .cpp
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "/home/urbaner/openage/buildsystem/cythonize.py", line 238, in <module>
    main()
  File "/home/urbaner/openage/buildsystem/cythonize.py", line 210, in main
    cythonize_wrapper(modules, args.force_optimized_lib, **cythonize_args)
  File "/home/urbaner/openage/buildsystem/cythonize.py", line 90, in cythonize_wrapper
    cythonize(src_modules, **kwargs)
  File "/usr/lib/python3/dist-packages/Cython/Build/Dependencies.py", line 1010, in cythonize
    module_list, module_metadata = create_extension_list(
                                   ^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/Cython/Build/Dependencies.py", line 784, in create_extension_list
    from distutils.extension import Extension
ModuleNotFoundError: No module named 'distutils'
make[4]: *** [CMakeFiles/cythonize.dir/build.make:120:py/cythonize_timefile] 錯誤 1
make[3]: *** [CMakeFiles/Makefile2:3523:CMakeFiles/cythonize.dir/all] 錯誤 2
make[2]: *** [CMakeFiles/Makefile2:3529:CMakeFiles/cythonize.dir/rule] 錯誤 2
make[1]: *** [Makefile:602:cythonize] 錯誤 2
make: *** [Makefile:64:cythonize] 錯誤 2
## 錯誤 is error is Chinese.

I tried to install cython with pip for 22.04 distribution has older version.
It's a minor bug on building, and I failed at 86% of finish, almost there.
Any missing info, I'm open to guys, good luck to all issues solving.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: buildsystemRelated to our cmake/python buildsystembugBehaving differently as it should behavelang: cythonImplemented using Cython code

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions