mirror of
https://github.com/ankitects/anki.git
synced 2025-09-18 14:02:21 -04:00
Start installing PyQt6 into the Linux ARM64 venv by default
Now that an ARM wheel is on PyPI, we no longer need to rely on a system PyQt to build on ARM. The install is skipped when PYTHONPATH is set, so older distros with glibc <2.39 can continue to use the system packages instead.
This commit is contained in:
parent
256822bbb1
commit
6966da14c2
2 changed files with 10 additions and 7 deletions
|
@ -28,8 +28,8 @@ pub fn setup_venv(build: &mut Build) -> Result<()> {
|
|||
]
|
||||
} else if cfg!(target_os = "macos") {
|
||||
inputs!["python/requirements.qt6_mac.txt",]
|
||||
} else if cfg!(all(target_os = "linux", target_arch = "aarch64")) {
|
||||
// system-provided Qt on ARM64
|
||||
} else if std::env::var("PYTHONPATH").is_ok() {
|
||||
// assume we have a system-provided Qt
|
||||
inputs![]
|
||||
} else {
|
||||
// normal linux
|
||||
|
|
|
@ -52,13 +52,16 @@ To play and record audio during development, install mpv and lame.
|
|||
|
||||
## ARM64 support
|
||||
|
||||
Other platforms download PyQt binary wheels from PyPI. There are no PyQt wheels available
|
||||
for ARM Linux, so you will need to rely on your system-provided libraries instead. Your distro
|
||||
will need to have Python 3.9 or later.
|
||||
If you're on a glibc 2.39+ system, you can skip the rest of this section.
|
||||
|
||||
After installing the system libraries (eg 'sudo apt install python3-pyqt6.qt{quick,webengine} python3-venv'),
|
||||
If your system has an older glibc, you won't be able to use the PyQt wheels that are
|
||||
available in pip/PyPy, and will need to use your system-installed PyQt instead.
|
||||
Your distro will also need to have Python 3.9 or later.
|
||||
|
||||
After installing the system libraries (eg:
|
||||
'sudo apt install python3-pyqt6.qt{quick,webengine} python3-venv pyqt6-dev-tools'),
|
||||
find the place they are installed (eg '/usr/lib/python3/dist-packages'). On modern Ubuntu, you'll
|
||||
need 'sudo apt remove python3-protobuf'. Then before running any commands like './run', tell Anki where
|
||||
also need 'sudo apt remove python3-protobuf'. Then before running any commands like './run', tell Anki where
|
||||
the packages can be found:
|
||||
|
||||
```
|
||||
|
|
Loading…
Reference in a new issue