ARM64 Compilation Error

I’m trying to make an Anki build for Orange Pi 5 with Ubuntu 22.04…
However, it displays this error.

Successfully installed build-1.0.3 click-8.1.7 colorama-0.4.6 importlib-metadata-6.8.0 packaging-23.2 pip-23.3.1 pip-tools-7.3.0 pyproject-hooks-1.0.0 setuptools-69.0.2 tomli-2.0.1 wheel-0.42.0 zipp-3.17.0
/usr/lib/python3/dist-packages/pip/_vendor/packaging/version.py:111: DeprecationWarning: Creating a LegacyVersion has been deprecated and will be removed in the next major release
  warnings.warn(
Traceback (most recent call last):
  File "/home/user/anki/out/pyenv/bin/pip-sync", line 5, in <module>
    from piptools.scripts.sync import cli
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/scripts/sync.py", line 22, in <module>
    from ..repositories import PyPIRepository
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/repositories/__init__.py", line 3, in <module>
    from .local import LocalRequirementsRepository
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/repositories/local.py", line 17, in <module>
    from .pypi import PyPIRepository
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/repositories/pypi.py", line 22, in <module>
    from pip._internal.operations.build.build_tracker import get_build_tracker
ModuleNotFoundError: No module named 'pip._internal.operations.build.build_tracker'
Failed with code Some(1): /home/user/anki/out/pyenv/bin/pip-sync python/requirements.dev.txt

Build failed.

Installing via pip is chaotic and crashes all the time.
https://betas.ankiweb.net/#via-pypipip

I’m using N2, I installed all possible dependencies.

Log:

user@orangepi5:~/anki$ ./run
   Compiling libc v0.2.150
   Compiling proc-macro2 v1.0.70
   Compiling unicode-ident v1.0.12
   Compiling cfg-if v1.0.0
   Compiling version_check v0.9.4
   Compiling pin-project-lite v0.2.13
   Compiling pkg-config v0.3.27
   Compiling bytes v1.5.0
   Compiling futures-core v0.3.29
   Compiling itoa v1.0.9
   Compiling futures-task v0.3.29
   Compiling spin v0.9.8
   Compiling typenum v1.17.0
   Compiling unicase v2.6.0
   Compiling adler v1.0.2
   Compiling futures-util v0.3.29
   Compiling num_cpus v1.16.0
   Compiling jobserver v0.1.27
   Compiling mio v0.8.9
   Compiling socket2 v0.5.5
   Compiling quote v1.0.33
   Compiling signal-hook-registry v1.4.1
   Compiling cc v1.0.83
   Compiling syn v2.0.39
   Compiling getrandom v0.2.11
   Compiling once_cell v1.18.0
   Compiling autocfg v1.1.0
   Compiling untrusted v0.9.0
   Compiling tracing-core v0.1.32
   Compiling slab v0.4.9
   Compiling miniz_oxide v0.7.1
   Compiling generic-array v0.14.7
   Compiling syn v1.0.109
   Compiling fnv v1.0.7
   Compiling heck v0.4.1
   Compiling pin-utils v0.1.0
   Compiling http v0.2.11
   Compiling tracing v0.1.40
   Compiling ring v0.17.7
   Compiling backtrace v0.3.69
   Compiling zstd-sys v2.0.9+zstd.1.5.5
   Compiling futures-channel v0.3.29
   Compiling rustix v0.38.26
   Compiling rustls v0.21.9
   Compiling tinyvec_macros v0.1.1
   Compiling doc-comment v0.3.3
   Compiling hashbrown v0.14.3
   Compiling serde v1.0.193
   Compiling gimli v0.28.1
   Compiling equivalent v1.0.1
   Compiling either v1.9.0
   Compiling memchr v2.6.4
   Compiling futures-sink v0.3.29
   Compiling httparse v1.8.0
   Compiling tinyvec v1.6.0
   Compiling indexmap v2.1.0
   Compiling tokio-macros v2.2.0
   Compiling object v0.32.1
   Compiling linux-raw-sys v0.4.12
   Compiling percent-encoding v2.3.1
   Compiling tokio v1.34.0
   Compiling utf8parse v0.2.1
   Compiling try-lock v0.2.4
   Compiling crc32fast v1.3.2
   Compiling bitflags v2.4.1
   Compiling log v0.4.20
   Compiling thiserror v1.0.50
   Compiling rustc-demangle v0.1.23
   Compiling want v0.3.1
   Compiling anstyle-parse v0.2.3
   Compiling form_urlencoded v1.2.1
   Compiling unicode-normalization v0.1.22
   Compiling addr2line v0.21.0
   Compiling mime_guess v2.0.4
   Compiling thiserror-impl v1.0.50
   Compiling lzma-sys v0.1.20
   Compiling http-body v0.4.5
   Compiling socket2 v0.4.10
   Compiling zstd-safe v7.0.0
   Compiling tokio-util v0.7.10
   Compiling anstyle v1.0.4
   Compiling colorchoice v1.0.0
   Compiling unicode-bidi v0.3.13
   Compiling h2 v0.3.22
   Compiling ryu v1.0.15
   Compiling snafu-derive v0.7.5
   Compiling serde_json v1.0.108
   Compiling base64 v0.21.5
   Compiling camino v1.1.6
   Compiling powerfmt v0.2.0
   Compiling anstyle-query v1.0.1
   Compiling tower-service v0.3.2
   Compiling httpdate v1.0.3
   Compiling anstream v0.6.4
   Compiling deranged v0.3.10
   Compiling rustls-pemfile v1.0.4
   Compiling idna v0.5.0
   Compiling hyper v0.14.27
   Compiling block-buffer v0.10.4
   Compiling crypto-common v0.1.6
   Compiling time-core v0.1.2
   Compiling clap_lex v0.6.0
   Compiling snafu v0.7.5
   Compiling openssl-probe v0.1.5
   Compiling fastrand v2.0.1
   Compiling anyhow v1.0.75
   Compiling strsim v0.10.0
   Compiling mime v0.3.17
   Compiling clap_builder v4.4.11
   Compiling tempfile v3.8.1
   Compiling rustls-native-certs v0.6.3
   Compiling time v0.3.30
   Compiling digest v0.10.7
   Compiling flate2 v1.0.28
   Compiling url v2.5.0
   Compiling tokio-socks v0.5.1
   Compiling serde_urlencoded v0.7.1
   Compiling clap_derive v4.4.7
   Compiling itertools v0.12.0
   Compiling xattr v1.0.1
   Compiling filetime v0.2.23
   Compiling cpufeatures v0.2.11
   Compiling encoding_rs v0.8.33
   Compiling byteorder v1.5.0
   Compiling runner v0.0.0 (/home/user/anki/build/runner)
   Compiling ipnet v2.9.0
   Compiling home v0.5.5
   Compiling webpki-roots v0.25.3
   Compiling which v5.0.0
   Compiling anki_process v0.0.0 (/home/user/anki/rslib/process)
   Compiling clap v4.4.11
   Compiling zip v0.6.6
   Compiling sha2 v0.10.8
   Compiling tar v0.4.40
   Compiling anki_io v0.0.0 (/home/user/anki/rslib/io)
   Compiling termcolor v1.4.0
   Compiling junction v1.0.0
   Compiling rustls-webpki v0.101.7
   Compiling sct v0.7.1
   Compiling tokio-rustls v0.24.1
   Compiling hyper-rustls v0.24.2
   Compiling reqwest v0.11.22
   Compiling zstd v0.13.0
   Compiling xz2 v0.1.7
    Finished release [optimized] target(s) in 2m 02s
   Compiling memchr v2.6.4
   Compiling libc v0.2.150
   Compiling proc-macro2 v1.0.70
   Compiling unicode-ident v1.0.12
   Compiling syn v1.0.109
   Compiling rustix v0.38.26
   Compiling bitflags v2.4.1
   Compiling cfg-if v1.0.0
   Compiling linux-raw-sys v0.4.12
   Compiling gimli v0.28.1
   Compiling doc-comment v0.3.3
   Compiling adler v1.0.2
   Compiling miniz_oxide v0.7.1
   Compiling quote v1.0.33
   Compiling object v0.32.1
   Compiling rustc-demangle v0.1.23
   Compiling cc v1.0.83
   Compiling camino v1.1.6
   Compiling addr2line v0.21.0
   Compiling heck v0.4.1
   Compiling aho-corasick v1.1.2
   Compiling regex-syntax v0.8.2
   Compiling fastrand v2.0.1
   Compiling anyhow v1.0.75
   Compiling either v1.9.0
   Compiling tempfile v3.8.1
   Compiling regex-automata v0.4.3
   Compiling bstr v1.8.0
   Compiling log v0.4.20
   Compiling home v0.5.5
   Compiling same-file v1.0.6
   Compiling walkdir v2.4.0
   Compiling which v5.0.0
   Compiling itertools v0.12.0
   Compiling num_cpus v1.16.0
   Compiling dunce v1.0.4
   Compiling lazy_static v1.4.0
   Compiling maplit v1.0.2
   Compiling backtrace v0.3.69
   Compiling globset v0.4.14
   Compiling snafu-derive v0.7.5
   Compiling snafu v0.7.5
   Compiling anki_io v0.0.0 (/home/user/anki/rslib/io)
   Compiling ninja_gen v0.0.0 (/home/user/anki/build/ninja_gen)
   Compiling configure v0.0.0 (/home/user/anki/build/configure)
    Finished dev [unoptimized + debuginfo] target(s) in 59.72s
     Running `out/rust/debug/configure`
failed: pyenv
Collecting build==1.0.3
  Using cached build-1.0.3-py3-none-any.whl (18 kB)
Collecting click==8.1.7
  Using cached click-8.1.7-py3-none-any.whl (97 kB)
Collecting colorama==0.4.6
  Using cached colorama-0.4.6-py2.py3-none-any.whl (25 kB)
Collecting importlib-metadata==6.8.0
  Using cached importlib_metadata-6.8.0-py3-none-any.whl (22 kB)
Collecting packaging==23.2
  Using cached packaging-23.2-py3-none-any.whl (53 kB)
Collecting pip-tools==7.3.0
  Using cached pip_tools-7.3.0-py3-none-any.whl (57 kB)
Collecting pyproject-hooks==1.0.0
  Using cached pyproject_hooks-1.0.0-py3-none-any.whl (9.3 kB)
Collecting tomli==2.0.1
  Using cached tomli-2.0.1-py3-none-any.whl (12 kB)
Collecting wheel==0.42.0
  Using cached wheel-0.42.0-py3-none-any.whl (65 kB)
Collecting zipp==3.17.0
  Using cached zipp-3.17.0-py3-none-any.whl (7.4 kB)
Collecting pip==23.3.1
  Using cached pip-23.3.1-py3-none-any.whl (2.1 MB)
Collecting setuptools==69.0.2
  Using cached setuptools-69.0.2-py3-none-any.whl (819 kB)
Installing collected packages: zipp, wheel, tomli, setuptools, pip, packaging, colorama, click, pyproject-hooks, importlib-metadata, build, pip-tools
  Attempting uninstall: zipp
    Found existing installation: zipp 1.0.0
    Not uninstalling zipp at /usr/lib/python3/dist-packages, outside environment /home/user/anki/out/pyenv
    Can't uninstall 'zipp'. No files were found to uninstall.
  Attempting uninstall: wheel
    Found existing installation: wheel 0.37.1
    Not uninstalling wheel at /usr/lib/python3/dist-packages, outside environment /home/user/anki/out/pyenv
    Can't uninstall 'wheel'. No files were found to uninstall.
  Attempting uninstall: setuptools
    Found existing installation: setuptools 59.6.0
    Not uninstalling setuptools at /usr/lib/python3/dist-packages, outside environment /home/user/anki/out/pyenv
    Can't uninstall 'setuptools'. No files were found to uninstall.
  Attempting uninstall: pip
    Found existing installation: pip 22.0.2
    Not uninstalling pip at /usr/lib/python3/dist-packages, outside environment /home/user/anki/out/pyenv
    Can't uninstall 'pip'. No files were found to uninstall.
  Attempting uninstall: colorama
    Found existing installation: colorama 0.4.4
    Not uninstalling colorama at /usr/lib/python3/dist-packages, outside environment /home/user/anki/out/pyenv
    Can't uninstall 'colorama'. No files were found to uninstall.
  Attempting uninstall: click
    Found existing installation: click 8.0.3
    Not uninstalling click at /usr/lib/python3/dist-packages, outside environment /home/user/anki/out/pyenv
    Can't uninstall 'click'. No files were found to uninstall.
  Attempting uninstall: importlib-metadata
    Found existing installation: importlib-metadata 4.6.4
    Not uninstalling importlib-metadata at /usr/lib/python3/dist-packages, outside environment /home/user/anki/out/pyenv
    Can't uninstall 'importlib-metadata'. No files were found to uninstall.
Successfully installed build-1.0.3 click-8.1.7 colorama-0.4.6 importlib-metadata-6.8.0 packaging-23.2 pip-23.3.1 pip-tools-7.3.0 pyproject-hooks-1.0.0 setuptools-69.0.2 tomli-2.0.1 wheel-0.42.0 zipp-3.17.0
/usr/lib/python3/dist-packages/pip/_vendor/packaging/version.py:111: DeprecationWarning: Creating a LegacyVersion has been deprecated and will be removed in the next major release
  warnings.warn(
Traceback (most recent call last):
  File "/home/user/anki/out/pyenv/bin/pip-sync", line 5, in <module>
    from piptools.scripts.sync import cli
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/scripts/sync.py", line 22, in <module>
    from ..repositories import PyPIRepository
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/repositories/__init__.py", line 3, in <module>
    from .local import LocalRequirementsRepository
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/repositories/local.py", line 17, in <module>
    from .pypi import PyPIRepository
  File "/home/user/anki/out/pyenv/lib/python3.9/site-packages/piptools/repositories/pypi.py", line 22, in <module>
    from pip._internal.operations.build.build_tracker import get_build_tracker
ModuleNotFoundError: No module named 'pip._internal.operations.build.build_tracker'
Failed with code Some(1): /home/user/anki/out/pyenv/bin/pip-sync python/requirements.dev.txt

Build failed.

I’m not sure about that error, but with the following doc tweaks, ./run works successfully for me on Ubuntu 22.04 ARM. When making changes, remove out/ before building again.

What do you mean “chaotic”? Crashes are probably caused by Qt, and if that’s the case a source build will likely fare no better.

1 Like

It crashes all the time until it stops working.

image

po@orangepi5:~$ ~/pyenv/bin/anki
Preparing to run...
Qt info: Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway. 
Starting main loop...
mpv not found, reverting to mplayer
conf key heatmap should be fetched with col.get_config(), and saved with col.set_config()
conf key heatmap should be fetched with col.get_config(), and saved with col.set_config()
conf key heatmap should be fetched with col.get_config(), and saved with col.set_config()

Thank you! Now it seems to be something much more stable.

Unfortunately, compilation on Ubuntu 22.04 still shows the same error as the first post.

So, I decided to compile it on Ubuntu 23.10 with qt6 and it is working perfectly.
It is possible to compile with qt6 using Debian 12+ or Ubuntu 23.10/24.04+

I would like to ask a question, if possible.
Using this command will I have even more stability?

RELEASE=2 ./tools/runopt

The window that shows the first time Ubuntu 22.04 desktop is started did the same thing for me. Ubuntu Desktop on ARM is probably not ready for prime time yet, which is probably why they don’t provide a desktop iso

It has no effect on stability, it will just make things run faster.

@dae Does the default build process create a statically linked binary, or do you need to fiddle with QT installation on any machine you want to run your Anki executable on?

Also, when you built successfully for 22.04, were you using QT5 or QT6?

@langfield

The “python3-pyqt6.qtwebengine” and “pyqt6-dev-tools” is not available in Ubuntu 22.04

https://packages.ubuntu.com/search?suite=noble&section=all&arch=any&keywords=python3-pyqt6.qtwebengine&searchon=names

https://packages.ubuntu.com/search?suite=noble&section=all&arch=any&keywords=pyqt6-dev-tools&searchon=names

Do you folks know what this error is caused by?

ubuntu@ip-172-31-21-69:~/anki$ ./run
    Finished release [optimized] target(s) in 2.90s
[1/1; 1 active; 0.485s] build:configure
[3/60; 4 active; 1.802s] pyenv
FAILED: /home/ubuntu/anki/out/pyenv/bin/black /home/ubuntu/anki/out/pyenv/bin/isort /home/ubuntu/anki/out/pyenv/bin/mypy /home/ubuntu/anki/out/pyenv/bin/pip /home/ubuntu/anki/out/pyenv/bin/pip-compile /home/ubuntu/anki/out/pyenv/bin/pip-sync /home/ubuntu/anki/out/pyenv/bin/protoc-gen-mypy /home/ubuntu/anki/out/pyenv/bin/pylint /home/ubuntu/anki/out/pyenv/bin/pytest /home/ubuntu/anki/out/pyenv/bin/python
/home/ubuntu/anki/out/rust/release/runner pyenv /home/ubuntu/anki/out/extracted/python/bin/python3 /home/ubuntu/anki/out/pyenv  python/requirements.base.txt python/requirements.dev.txt
Failed to execute: /home/ubuntu/anki/out/pyenv/bin/pip-sync python/requirements.dev.txt

Packaged builds are not supported on ARM Linux. Qt is dynamically linked.

You can run the command shown on the last line manually to see if it prints anything useful. If not, and removing out/ and rebuilding doesn’t help, maybe the pip-sync authors will have some advice.

@dae

I’m going to brake again even with the QT6…

Is there any way to check the logs and find what’s missing?

user@orangepi5:~/anki$ ./run 
    Finished release [optimized] target(s) in 0.58s
n2: no work to do

Build succeeded in 0.18s.
Preparing to run...
/home/user/anki/pylib/anki/lang.py:185: DeprecationWarning: Use setlocale(), getencoding() and getlocale() instead
  (sys_lang, enc) = locale.getdefaultlocale()
Serving on http://127.0.0.1:40000
Qt info: 

GL Type: desktop
Surface Type: OpenGL
Surface Profile: CompatibilityProfile
Surface Version: 3.3
QSG RHI Backend: OpenGL
Using Supported QSG Backend: yes
Using Software Dynamic GL: no
Using Multithreaded OpenGL: yes

Init Parameters:
  *  application-name Anki 
  *  browser-subprocess-path /usr/lib/qt6/libexec/QtWebEngineProcess 
  *  create-default-gl-context  
  *  disable-features ConsolidatedMovementXY,InstalledApp,BackgroundFetch,WebOTP,WebPayments,WebUSB,PictureInPicture 
  *  disable-setuid-sandbox  
  *  disable-speech-api  
  *  enable-features NetworkServiceInProcess,TracingServiceInProcess 
  *  enable-threaded-compositing  
  *  in-process-gpu  
  *  remote-allow-origins http://localhost:8080 
  *  use-gl desktop 
 

DevTools listening on ws://127.0.0.1:8080/devtools/browser/d0b8bb29-6224-4904-8a2f-33d51b881f34
/home/user/.local/share/Anki2/addons21/771677663/external/sentry_sdk/integrations/flask.py:30: DeprecationWarning: The '__version__' attribute is deprecated and will be removed in Flask 3.1. Use feature detection or 'importlib.metadata.version("flask")' instead.
  from flask import __version__ as FLASK_VERSION
Starting main loop...
Qt warning: Remote debugging server started successfully. Try pointing a Chromium-based browser to http://127.0.0.1:8080 
1705001377.720 GET /_anki/legacyPageData
1705001377.741 GET /_anki/legacyPageData
1705001377.752 GET /_anki/legacyPageData
1705001377.847 GET /_anki/css/webview.css
1705001377.857 GET /_anki/css/toolbar.css
1705001377.871 GET /_anki/js/webview.js
1705001377.874 GET /_anki/js/vendor/jquery.min.js
1705001377.875 GET /_anki/css/deckbrowser.css
1705001377.876 GET /_anki/js/toolbar.js
1705001377.880 GET /_anki/imgs/refresh.svg
1705001377.886 GET /_anki/css/webview.css
1705001377.906 GET /_anki/js/vendor/jquery-ui.min.js
1705001377.909 GET /_anki/css/toolbar-bottom.css
1705001377.910 GET /_anki/js/deckbrowser.js
1705001377.920 GET /_anki/css/toolbar.css
1705001377.923 GET /_anki/css/webview.css
1705001377.931 GET /_anki/js/vendor/jquery.min.js
1705001377.932 GET /_anki/imgs/gears.svg
1705001377.934 GET /_anki/js/webview.js
1705001377.943 GET /_anki/js/webview.js
1705001377.944 GET /_anki/js/vendor/jquery.min.js
1705001380.330 GET /_anki/legacyPageData
1705001380.337 GET /_anki/legacyPageData
1705001380.397 GET /_anki/js/webview.js
1705001380.400 GET /_anki/css/deckbrowser.css
1705001380.402 GET /_anki/css/webview.css
1705001380.402 GET /_anki/js/vendor/jquery.min.js
1705001380.409 GET /_anki/js/deckbrowser.js
1705001380.411 GET /_anki/js/vendor/jquery-ui.min.js
1705001380.415 GET /_anki/imgs/gears.svg
1705001380.435 GET /_anki/css/webview.css
1705001380.441 GET /_anki/css/toolbar.css
1705001380.443 GET /_anki/css/toolbar-bottom.css
1705001380.448 GET /_anki/js/webview.js
1705001380.443 GET /_anki/js/vendor/jquery.min.js
1705001383.412 GET /_anki/pages/graphs.html
1705001383.435 GET /_anki/pages/graphs.css
1705001383.437 GET /_anki/pages/graphs.js
1705001383.514 POST /_anki/i18nResources
1705001383.587 POST /_anki/getGraphPreferences
1705001383.605 POST /_anki/graphs

Sorry, I don’t know what the problem is, but it’s likely an issue with QtWebEngine in that configuration. The statistics screen works correctly for me on a Debian ARM system.

I finally got this to work on Debian. Here’s some Debian-specific tips:

  • My approach was build from source using ./run, I was not trying to build a binary bundle.
  • I followed these instructions: anki/docs/linux.md at 8f77e5198b2e0a3019fa143e621a80ae62961f20 · ankitects/anki · GitHub
  • It was critical to export those environment variables.
  • Do not use conda. This was hell. I recommend deactivating your environment or removing it entirely before attempting this.
  • Make sure you know that the venv and python binary that the build process is using is in out/pyenv/bin, it is not the system python. However, because of the exports above, it can see the system python packages. Use these binaries to check that the imports work before re-attempting the build.
  • I ran into a bunch of PtQt6 import errors. Probably you want to install things with pip unless they start trying to build qt6 stuff from source with qmake. Don’t actually let pip do this, it’s also hell. If you see it trying, search for the appropriate package name in the Debian sources and install that with apt instead. E.g. python3-pyqt6.qtwebengine.
mal@debian:~/pkgs/anki/out/pyenv/bin$ ./pip install PyQt6-WebEngine
Collecting PyQt6-WebEngine
  Downloading PyQt6_WebEngine-6.6.0.tar.gz (31 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [21 lines of output]
      pyproject.toml: line 7: using '[tool.sip.metadata]' to specify the project metadata is deprecated and will be removed in SIP v7.0.0, use '[project]' instead
      Traceback (most recent call last):
        File "/usr/lib/python3/dist-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/usr/lib/python3/dist-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
        File "/usr/lib/python3/dist-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 152, in prepare_metadata_for_build_wheel
          whl_basename = backend.build_wheel(metadata_directory, config_settings)
        File "/tmp/pip-build-env-tmyncimq/overlay/lib/python3.9/site-packages/sipbuild/api.py", line 46, in build_wheel
          project = AbstractProject.bootstrap('wheel',
        File "/tmp/pip-build-env-tmyncimq/overlay/lib/python3.9/site-packages/sipbuild/abstract_project.py", line 87, in bootstrap
          project.setup(pyproject, tool, tool_description)
        File "/tmp/pip-build-env-tmyncimq/overlay/lib/python3.9/site-packages/sipbuild/project.py", line 587, in setup
          self.apply_user_defaults(tool)
        File "/tmp/pip-build-env-tmyncimq/overlay/lib/python3.9/site-packages/pyqtbuild/project.py", line 70, in apply_user_defaults
          super().apply_user_defaults(tool)
        File "/tmp/pip-build-env-tmyncimq/overlay/lib/python3.9/site-packages/sipbuild/project.py", line 237, in apply_user_defaults
          self.builder.apply_user_defaults(tool)
        File "/tmp/pip-build-env-tmyncimq/overlay/lib/python3.9/site-packages/pyqtbuild/builder.py", line 69, in apply_user_defaults
          raise PyProjectOptionException('qmake',
      sipbuild.pyproject.PyProjectOptionException
      [end of output]

The above error is pip complaining, "I can’t see qmake on the PATH. As mentioned above, you could install qmake6 and then symlink it, but don’t. Trying to build things from source via pip is very annoying and the Debian packagers have already done all that work for you.

sudo apt-get install python3-pyqt6.qtwebengine python3-pyqt6.qtwebchannel python3-pyqt6.qtquick pyqt6-dev-tools

Pretty sure I installed PyQt6-sip (PyQt6-sip · PyPI) via the pip binary in the venv.

@langfield
You forgot 1 package.
That’s why it’s showing an error.

Try this:

sudo apt install python3-pip python3-venv pyqt6-dev-tools python3-pyqt6*

Before running the installation you can check these parameters:

echo $PYTHONPATH
echo $PYTHON_BINARY

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.