lordmauve / wasabi2d

Cutting-edge 2D game framework for Python
https://wasabi2d.readthedocs.io/
GNU Lesser General Public License v3.0
154 stars 24 forks source link

Setup error on Debian #66

Open beucismis opened 3 years ago

beucismis commented 3 years ago

Hello, I am getting an error with the wasabi2d installation.

Debian version: bullseye/sid Python version: 3.9.2 PIP version: 20.3.4

 $ pip3 install wasabi2d
Collecting wasabi2d
  Using cached wasabi2d-1.4.0-py3-none-any.whl (298 kB)
Collecting bresenham==0.2.*
  Downloading bresenham-0.2.1-py3-none-any.whl (3.7 kB)
Requirement already satisfied: sortedcontainers in ./.local/lib/python3.9/site-packages (from wasabi2d) (2.3.0)
Collecting mapbox-earcut==0.12.10
  Using cached mapbox_earcut-0.12.10-cp39-cp39-manylinux2010_x86_64.whl (96 kB)
Collecting pygame==2.0.0.dev10
  Using cached pygame-2.0.0.dev10.tar.gz (5.6 MB)
    ERROR: Command errored out with exit status 1:
     command: /usr/bin/python3 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-o8vyhmj2/pygame_46cf6a6402e2487680e0f991a35bc21f/setup.py'"'"'; __file__='"'"'/tmp/pip-install-o8vyhmj2/pygame_46cf6a6402e2487680e0f991a35bc21f/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-_u5dyow0
         cwd: /tmp/pip-install-o8vyhmj2/pygame_46cf6a6402e2487680e0f991a35bc21f/
    Complete output (29 lines):

    WARNING, No "Setup" File Exists, Running "buildconfig/config.py"
    Using UNIX configuration...

    /bin/sh: 1: sdl2-config: not found
    /bin/sh: 1: sdl2-config: not found
    /bin/sh: 1: sdl2-config: not found
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-install-o8vyhmj2/pygame_46cf6a6402e2487680e0f991a35bc21f/setup.py", line 306, in <module>
        buildconfig.config.main(AUTO_CONFIG)
      File "/tmp/pip-install-o8vyhmj2/pygame_46cf6a6402e2487680e0f991a35bc21f/buildconfig/config.py", line 221, in main
        deps = CFG.main(**kwds)
      File "/tmp/pip-install-o8vyhmj2/pygame_46cf6a6402e2487680e0f991a35bc21f/buildconfig/config_unix.py", line 194, in main
        DependencyProg('SDL', 'SDL_CONFIG', 'sdl2-config', '2.0', ['sdl']),
      File "/tmp/pip-install-o8vyhmj2/pygame_46cf6a6402e2487680e0f991a35bc21f/buildconfig/config_unix.py", line 39, in __init__
        self.ver = config[0].strip()
    IndexError: list index out of range

    Hunting dependencies...

    ---
    For help with compilation see:
        https://www.pygame.org/wiki/Compilation
    To contribute to pygame development see:
        https://www.pygame.org/contribute.html
    ---

    ----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/fd/87/6ffe2a745a4a1032594b3caab942edb4244d5a02d314fb8d2258e3a403fd/pygame-2.0.0.dev10.tar.gz#sha256=c4437da0c3d5e73a1f1e3c4a4313f7e8ca7eae472a1686840b1f34989ffae08a (from https://pypi.org/simple/pygame/). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
merwok commented 2 years ago

This is the important error in the traceback:

/bin/sh: 1: sdl2-config: not found

which means you need to install libsdl2-dev before wasabi2d.

lordmauve commented 2 years ago

This is due to the available selection of wheels in the version of PyGame that is being pinned by the stable version of Wasabi2D. If you explicitly install a newer PyGame (e.g. 2.1.0) then Wasabi2D will work fine with it.

I'll leave this issue open pending a new release of Wasabi2D.