web-dev-qa-db-ja.com

3.8.2にkivy pythonをインストールします

誤ってPyCharmのターミナルとコマンドラインに同時にインストールを開始しました。ベースと同じエラーがない限り、「ベース」を確認しないでください。

削除しようとすると、次のメッセージが表示されます。

警告:kivyがインストールされていないためスキップします。

Kivyをインストールしようとすると、次のエラーが発生します。

  C:\Users\Michael\Desktop\github\kivy>pip install kivy[base]
    Collecting kivy[base]
      Using cached Kivy-1.11.1.tar.gz (23.6 MB)
      WARNING: Kivy 1.11.1 does not provide the extra 'base'
    Requirement already satisfied: Kivy-Garden>=0.1.4 in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from kivy[base]) (0.1.4)
    Requirement already satisfied: docutils in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from kivy[base]) (0.16)
    Requirement already satisfied: pygments in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from kivy[base]) (2.5.2)
    Requirement already satisfied: requests in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from Kivy-Garden>=0.1.4->kivy[base]) (2.23.0)
    Requirement already satisfied: idna<3,>=2.5 in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from requests->Kivy-Garden>=0.1.4->kivy[base]) (2.9)
    Requirement already satisfied: urllib3!=1.25.0,!=1.25.1,<1.26,>=1.21.1 in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from requests->Kivy-Garden>=0.1.4->kivy[base]) (1.25.8)
    Requirement already satisfied: certifi>=2017.4.17 in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from requests->Kivy-Garden>=0.1.4->kivy[base]) (2019.11.28)
    Requirement already satisfied: chardet<4,>=3.0.2 in c:\users\michael\appdata\local\programs\python\python38-32\lib\site-packages (from requests->Kivy-Garden>=0.1.4->kivy[base]) (3.0.4)
    Building wheels for collected packages: kivy
      Building wheel for kivy (setup.py) ... error
      ERROR: Command errored out with exit status 3221225477:
       command: 'c:\users\michael\appdata\local\programs\python\python38-32\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\Michael\\AppData\\Local\\Temp\\pip-install-7_3s7j11\\kivy\\setup.py'"'"'; __file__='"'"'C:\\Users\\Michael\\AppData\\Local\\Temp\\pip-install-7_3s7j11\\kivy\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d 'C:\Users\Michael\AppData\Local\Temp\pip-wheel-ohpcy0dl'
           cwd: C:\Users\Michael\AppData\Local\Temp\pip-install-7_3s7j11\kivy\
      Complete output (531 lines):
      Using setuptools
      User distribution detected, avoid portable command.
      Using this graphics system: OpenGL
      WARNING: A problem occurred while running pkg-config --libs --cflags gstreamer-1.0 (code 1)

      b'"pkg-config" \xad\xa5 \xef\xa2\xab\xef\xa5\xe2\xe1\xef \xa2\xad\xe3\xe2\xe0\xa5\xad\xad\xa5\xa9 \xa8\xab\xa8 \xa2\xad\xa5\xe8\xad\xa5\xa9\r\n\xaa\xae\xac\xa0\xad\xa4\xae\xa9, \xa8\xe1\xaf\xae\xab\xad\xef\xa5\xac\xae\xa9 \xaf\xe0\xae\xa3\xe0\xa0\xac\xac\xae\xa9 \xa8\xab\xa8 \xaf\xa0\xaa\xa5\xe2\xad\xeb\xac \xe4\xa0\xa9\xab\xae\xac.\r\n'

      WARNING: A problem occurred while running pkg-config --libs --cflags gstreamer-1.0 (code 1)

      b'"pkg-config" \xad\xa5 \xef\xa2\xab\xef\xa5\xe2\xe1\xef \xa2\xad\xe3\xe2\xe0\xa5\xad\xad\xa5\xa9 \xa8\xab\xa8 \xa2\xad\xa5\xe8\xad\xa5\xa9\r\n\xaa\xae\xac\xa0\xad\xa4\xae\xa9, \xa8\xe1\xaf\xae\xab\xad\xef\xa5\xac\xae\xa9 \xaf\xe0\xae\xa3\xe0\xa0\xac\xac\xae\xa9 \xa8\xab\xa8 \xaf\xa0\xaa\xa5\xe2\xad\xeb\xac \xe4\xa0\xa9\xab\xae\xac.\r\n'

      WARNING: A problem occurred while running pkg-config --libs --cflags sdl2 SDL2_ttf SDL2_image SDL2_mixer (code 1)

      b'"pkg-config" \xad\xa5 \xef\xa2\xab\xef\xa5\xe2\xe1\xef \xa2\xad\xe3\xe2\xe0\xa5\xad\xad\xa5\xa9 \xa8\xab\xa8 \xa2\xad\xa5\xe8\xad\xa5\xa9\r\n\xaa\xae\xac\xa0\xad\xa4\xae\xa9, \xa8\xe1\xaf\xae\xab\xad\xef\xa5\xac\xae\xa9 \xaf\xe0\xae\xa3\xe0\xa0\xac\xac\xae\xa9 \xa8\xab\xa8 \xaf\xa0\xaa\xa5\xe2\xad\xeb\xac \xe4\xa0\xa9\xab\xae\xac.\r\n'

      ERROR: Dependency for context.pyx not resolved: config.pxi
      ERROR: Dependency for compiler.pyx not resolved: config.pxi
      ERROR: Dependency for context_instructions.pyx not resolved: config.pxi
      ERROR: Dependency for fbo.pyx not resolved: config.pxi
      ERROR: Dependency for gl_instructions.pyx not resolved: config.pxi
      ERROR: Dependency for instructions.pyx not resolved: config.pxi
      ERROR: Dependency for opengl.pyx not resolved: config.pxi
      ERROR: Dependency for opengl_utils.pyx not resolved: config.pxi
      ERROR: Dependency for shader.pyx not resolved: config.pxi
      ERROR: Dependency for stencil_instructions.pyx not resolved: config.pxi
      ERROR: Dependency for scissor_instructions.pyx not resolved: config.pxi
      ERROR: Dependency for texture.pyx not resolved: config.pxi
      ERROR: Dependency for vbo.pyx not resolved: config.pxi
      ERROR: Dependency for vertex.pyx not resolved: config.pxi
      ERROR: Dependency for vertex_instructions.pyx not resolved: config.pxi
      ERROR: Dependency for cgl.pyx not resolved: config.pxi
      ERROR: Dependency for cgl_mock.pyx not resolved: config.pxi
      ERROR: Dependency for cgl_gl.pyx not resolved: config.pxi
      ERROR: Dependency for cgl_glew.pyx not resolved: config.pxi
      ERROR: Dependency for cgl_sdl2.pyx not resolved: config.pxi
      ERROR: Dependency for svg.pyx not resolved: config.pxi
      fatal: not a git repository (or any of the parent directories): .git
      running bdist_wheel
      running build
      running build_py
      creating build
      creating build\lib.win32-3.8
      creating build\lib.win32-3.8\kivy
      copying kivy\animation.py -> build\lib.win32-3.8\kivy
      copying kivy\app.py -> build\lib.win32-3.8\kivy
      copying kivy\atlas.py -> build\lib.win32-3.8\kivy
      copying kivy\base.py -> build\lib.win32-3.8\kivy
      copying kivy\cache.py -> build\lib.win32-3.8\kivy
      copying kivy\clock.py -> build\lib.win32-3.8\kivy
      copying kivy\compat.py -> build\lib.win32-3.8\kivy
      copying kivy\config.py -> build\lib.win32-3.8\kivy
      copying kivy\context.py -> build\lib.win32-3.8\kivy
      copying kivy\event.py -> build\lib.win32-3.8\kivy
      copying kivy\factory.py -> build\lib.win32-3.8\kivy
      copying kivy\factory_registers.py -> build\lib.win32-3.8\kivy
      copying kivy\geometry.py -> build\lib.win32-3.8\kivy
      copying kivy\gesture.py -> build\lib.win32-3.8\kivy
      copying kivy\interactive.py -> build\lib.win32-3.8\kivy
      copying kivy\loader.py -> build\lib.win32-3.8\kivy
      copying kivy\logger.py -> build\lib.win32-3.8\kivy
      copying kivy\metrics.py -> build\lib.win32-3.8\kivy
      copying kivy\multistroke.py -> build\lib.win32-3.8\kivy
      copying kivy\parser.py -> build\lib.win32-3.8\kivy
      copying kivy\resources.py -> build\lib.win32-3.8\kivy
      copying kivy\support.py -> build\lib.win32-3.8\kivy
      copying kivy\utils.py -> build\lib.win32-3.8\kivy
      copying kivy\vector.py -> build\lib.win32-3.8\kivy
      copying kivy\version.py -> build\lib.win32-3.8\kivy
      copying kivy\weakmethod.py -> build\lib.win32-3.8\kivy
      copying kivy\__init__.py -> build\lib.win32-3.8\kivy
      creating build\lib.win32-3.8\kivy\core
      copying kivy\core\__init__.py -> build\lib.win32-3.8\kivy\core
      creating build\lib.win32-3.8\kivy\core\audio
      copying kivy\core\audio\audio_avplayer.py -> build\lib.win32-3.8\kivy\core\audio
      copying kivy\core\audio\audio_ffpyplayer.py -> build\lib.win32-3.8\kivy\core\audio
      copying kivy\core\audio\audio_gstplayer.py -> build\lib.win32-3.8\kivy\core\audio
      copying kivy\core\audio\audio_pygame.py -> build\lib.win32-3.8\kivy\core\audio
      copying kivy\core\audio\__init__.py -> build\lib.win32-3.8\kivy\core\audio
      creating build\lib.win32-3.8\kivy\core\camera
      copying kivy\core\camera\camera_Android.py -> build\lib.win32-3.8\kivy\core\camera
      copying kivy\core\camera\camera_gi.py -> build\lib.win32-3.8\kivy\core\camera
      copying kivy\core\camera\camera_opencv.py -> build\lib.win32-3.8\kivy\core\camera
      copying kivy\core\camera\camera_picamera.py -> build\lib.win32-3.8\kivy\core\camera
      copying kivy\core\camera\__init__.py -> build\lib.win32-3.8\kivy\core\camera
      creating build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_Android.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_dbusklipper.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_dummy.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_gtk3.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_nspaste.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_pygame.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_sdl2.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_winctypes.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_xclip.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\clipboard_xsel.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\_clipboard_ext.py -> build\lib.win32-3.8\kivy\core\clipboard
      copying kivy\core\clipboard\__init__.py -> build\lib.win32-3.8\kivy\core\clipboard
      creating build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\img_dds.py -> build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\img_ffpyplayer.py -> build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\img_gif.py -> build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\img_pil.py -> build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\img_pygame.py -> build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\img_sdl2.py -> build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\img_tex.py -> build\lib.win32-3.8\kivy\core\image
      copying kivy\core\image\__init__.py -> build\lib.win32-3.8\kivy\core\image
      creating build\lib.win32-3.8\kivy\core\gl
      copying kivy\core\gl\__init__.py -> build\lib.win32-3.8\kivy\core\gl
      creating build\lib.win32-3.8\kivy\core\spelling
      copying kivy\core\spelling\spelling_enchant.py -> build\lib.win32-3.8\kivy\core\spelling
      copying kivy\core\spelling\spelling_osxappkit.py -> build\lib.win32-3.8\kivy\core\spelling
      copying kivy\core\spelling\__init__.py -> build\lib.win32-3.8\kivy\core\spelling
      creating build\lib.win32-3.8\kivy\core\text
      copying kivy\core\text\markup.py -> build\lib.win32-3.8\kivy\core\text
      copying kivy\core\text\text_pango.py -> build\lib.win32-3.8\kivy\core\text
      copying kivy\core\text\text_pil.py -> build\lib.win32-3.8\kivy\core\text
      copying kivy\core\text\text_pygame.py -> build\lib.win32-3.8\kivy\core\text
      copying kivy\core\text\text_sdl2.py -> build\lib.win32-3.8\kivy\core\text
      copying kivy\core\text\__init__.py -> build\lib.win32-3.8\kivy\core\text
      creating build\lib.win32-3.8\kivy\core\video
      creating build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\androidjoystick.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\hidinput.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\leapfinger.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\linuxwacom.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\mactouch.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\mouse.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\mtdev.py -> build\lib.win32-3.8\kivy\input\providers

      copying kivy\input\providers\probesysfs.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\tuio.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\wm_common.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\wm_pen.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\wm_touch.py -> build\lib.win32-3.8\kivy\input\providers
      copying kivy\input\providers\__init__.py -> build\lib.win32-3.8\kivy\input\providers
      creating build\lib.win32-3.8\kivy\lang
      copying kivy\lang\builder.py -> build\lib.win32-3.8\kivy\lang
      copying kivy\lang\parser.py -> build\lib.win32-3.8\kivy\lang
      copying kivy\lang\__init__.py -> build\lib.win32-3.8\kivy\lang
      creating build\lib.win32-3.8\kivy\lib
      copying kivy\lib\ddsfile.py -> build\lib.win32-3.8\kivy\lib
      copying kivy\lib\mtdev.py -> build\lib.win32-3.8\kivy\lib
      copying kivy\lib\__init__.py -> build\lib.win32-3.8\kivy\lib
      creating build\lib.win32-3.8\kivy\lib\gstplayer
      copying kivy\lib\gstplayer\__init__.py -> build\lib.win32-3.8\kivy\lib\gstplayer
      creating build\lib.win32-3.8\kivy\lib\vidcore_lite
      copying kivy\lib\vidcore_lite\__init__.py -> build\lib.win32-3.8\kivy\lib\vidcore_lite
      creating build\lib.win32-3.8\kivy\modules
      copying kivy\modules\console.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\cursor.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\inspector.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\joycursor.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\keybinding.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\monitor.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\recorder.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\screen.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\showborder.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\touchring.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\webdebugger.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\_webdebugger.py -> build\lib.win32-3.8\kivy\modules
      copying kivy\modules\__init__.py -> build\lib.win32-3.8\kivy\modules
      creating build\lib.win32-3.8\kivy\network
        copying kivy\tests\test_uix_asyncimage.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_boxlayout.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_gridlayout.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_layout.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_relativelayout.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_scrollview.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_slider.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_stacklayout.py -> build\lib.win32-3.8\kivy\tests
        copying kivy\tests\test_uix_textinput.py -> build\lib.win32-3.8\kivy\tests

... .. kivy\tools\theming\defaulttheme\vkeyboard_disabled_key_normal.png-> build\lib.win32-3.8\kivy\tools\theming\defaulttheme copy kivy\tools\theming\defaulttheme\vkeyboard_key_down.png-> build \をコピーしていますlib.win32-3.8\kivy\tools\theming\defaulttheme copy kivy\tools\theming\defaulttheme\vkeyboard_key_normal.png-> build\lib.win32-3.8\kivy\tools\theming\defaulttheme running build_ext ------ ----------------------------------エラー:コマンドが終了ステータス3221225477でエラーになりました: 'c:\ users\michael\appdata\local\programs\python\python38-32\python.exe '-u -c' import sys、setuptools、tokenize; sys.argv [0] = '"'" 'C:\ Users\Michael\AppData\Local\Temp\pip-install-7_3s7j11\kivy\setup.py' "'"'; file= '"'" 'C:\ Users\Michael\AppData\Local\Temp\pip-install-7_3s7j11\kivy\setup.py' "'"'; f = getattr(tokenize、 '"'" 'open' "'"'、open)(file); code = f.read()。replace( '"'" '\ r\n' "'"'、 '"'" '\ n' "'"'); f.close(); exec(compile(code、file、 '"'" exec '"'" '))'インストール--record 'C:\ Users\Michael\AppData\Local\Temp\pip-record-j5_4w5bq\install-record.txt' --single-version-externally-managed --compile --install-headers 'c:\ users\michael\appdata\local\programs\python\python38-32\Include\kivy 'コマンドの完全な出力については、ログを確認してください。

1
Michaelan

インストールの問題の解決策は、kivyがpython 3.8.Xと互換性がないことです。したがって、kivyを実行するにはpython 2.7.Xから3.7.Xが必要です。 Windowsの場合と同様に、すべての一般的なインストールプロセスで、コマンドプロンプトに次のように連続して入力します。

python -m pip install --upgrade pip wheel setuptools
python -m pip install docutils pygments pypiwin32 kivy.deps.sdl2 kivy.deps.glew
python -m pip install kivy.deps.gstreamer
python -m pip install kivy.deps.angle
python -m pip install pygame (Note: Optional)
python -m pip install kivy
python -m pip install kivy_examples (Note: Optional)

そして、すべてがうまくいきます。ハッピーコーディング

0