Commit 97355ee5 authored by Sébastien Blin's avatar Sébastien Blin Committed by Andreas Traczyk
Browse files

doc: update INSTALL.md for Qt 6 and fix CI

Change-Id: I41cb36b931a648bc2f3191ba183bcc77e9c0b787
parent 9ada53ac
......@@ -5,18 +5,64 @@ There is basically two ways to build `client-qt`:
+ Use `build.py` script which will build all Jami (daemon/client lib/client-qt)
+ Build only this client.
## Disclaimer
Because the client-qt is multi-platforms and supporting macOS, we need a recent version of Qt to do rendering with Metal. So, Qt 6.2 is necessary.
This version is generally not packaged on a lot of platforms, and to control available plugins and such, we have our own Qt packaged (generated by https://review.jami.net/jami-project and available on https://jami.net on the distributions we support).
So, you will need to get Qt 6.2 first. For this, there is 3 methods:
### Qt from https://jami.net (recommended)
If your distribution is supported, we provide a Qt package (`libqt-jami`) on our repo. Follow instructions https://jami.net/download-jami-linux/ (but instead installing `jami` install `libqt-jami`).
The files will be installed in `/usr/lib/libqt-jami`.
### Qt from your distribution
If Qt 6.2 is available, you can use the packages from your distribution:
It should be (For now qt5 only is packaged by distributions, so names can change).
#### Dependencies, Debian based
```
sudo apt-get install cmake make doxygen g++ gettext libnotify-dev pandoc nasm libqrencode-dev \
libnotify-dev libnm-dev \
qtbase6-dev \
qtmultimedia5-dev libqt6svg6-dev qtwebengine6-dev qtdeclarative6-dev \
qtquickcontrols2-6-dev qml-module-qtquick2 qml-module-qtquick-controls \
qml-module-qtquick-controls2 qml-module-qtquick-dialogs \
qml-module-qtquick-layouts qml-module-qtquick-privatewidgets \
qml-module-qtquick-shapes qml-module-qtquick-window2 \
qml-module-qtquick-templates2 qml-module-qt-labs-platform \
qml-module-qtwebengine qml-module-qtwebchannel \
qml-module-qt-labs-qmlmodels
```
#### Dependencies, Fedora based
```
sudo dnf install qt6-qtsvg-devel qt6-qtwebengine-devel qt6-qtmultimedia-devel qt6-qtdeclarative-devel qt6-qtquickcontrols2-devel qt6-qtquickcontrols qrencode-devel NetworkManager-libnm-devel
```
### Build Qt from sources
https://www.qt.io/product/qt6
## GNU/Linux
Then, you can build the project
### With build.py
```bash
git clone https://review.jami.net/ring-project
git clone https://review.jami.net/jami-project
```
Jami installer uses **python3**. If it's not installed, please install it:
```bash
cd ring-project/
cd jami-project/
./build.py --init
```
......@@ -36,7 +82,7 @@ Then, you can build daemon, lrc and client-qt with:
And you will have the daemon in `daemon/bin/jamid` and the client in `client-qt/build-local/jami-qt`. You also can run it with
If you use a Qt version that is not wide-system installed you need to specify its path after the `--qt` flag, i. e., `./build.py --install --qt /home/<username>/Qt/5.15.0/gcc_64
If you use a Qt version that is not wide-system installed you need to specify its path after the `--qt` flag, i. e., `./build.py --install --qt /home/<username>/Qt/6.2.1/gcc_64
```bash
......@@ -51,27 +97,6 @@ Notes:
In order to use the Qt Client it is necessary to have the Qt version 5.14 or higher. If your system does not have it you can install it [from sources or download the binary installer](https://www.qt.io/download).
## Dependencies, Debian based
```
sudo apt-get install cmake make doxygen g++ gettext libnotify-dev pandoc nasm libqrencode-dev \
libnotify-dev libnm-dev \
qtbase5-dev libqt5sql5-sqlite \ # Qt > 5.14!!!!
qtmultimedia5-dev libqt5svg5-dev qtwebengine5-dev qtdeclarative5-dev \
qtquickcontrols2-5-dev qml-module-qtquick2 qml-module-qtquick-controls \
qml-module-qtquick-controls2 qml-module-qtquick-dialogs \
qml-module-qtquick-layouts qml-module-qtquick-privatewidgets \
qml-module-qtquick-shapes qml-module-qtquick-window2 \
qml-module-qtquick-templates2 qml-module-qt-labs-platform \
qml-module-qtwebengine qml-module-qtwebchannel \
qml-module-qt-labs-qmlmodels
```
## Dependencies, Fedora
```
sudo dnf install qt5-qtsvg-devel qt5-qtwebengine-devel qt5-qtmultimedia-devel qt5-qtdeclarative-devel qt5-qtquickcontrols2-devel qt5-qtquickcontrols qrencode-devel NetworkManager-libnm-devel
```
## Build only this repository
......@@ -83,14 +108,13 @@ cmake ..
make -j
```
cmake can take several options:
+ Variables `QT5_VER` and `QT5_PATH` are used to specify version and path for a custom installation of Qt.
cmake can take some options:
+ If lrc library is installed in a custom directory you can set its path with the variable LRC. Additionally you can specify built library location with `LRC` (otherwise it will seach inside LRC with the suffixes `/lib`, `/build` and `/build-local`).
e.g.
e.g. (with Qt version from https://jami.net)
```
cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=/home/amarok/Projects/jami/install/lrc -DLRC=/home/user/install-lrc
cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_INSTALL_PREFIX=jami-project/install/client-qt -DLRC=jami-project/install/lrc -DCMAKE_PREFIX_PATH=/usr/lib/libqt-jami
```
After the build has finished, you are finally ready to launch jami-qt in your build directory.
......@@ -105,7 +129,7 @@ make install
Only 64-bit MSVC build can be compiled.
> Note: command ```./make-ring.py --init``` is not required on the Windows build <br>
> Note: command ```./build.py --init``` is not required on the Windows build <br>
**Setup Before Building:**
- Download [Qt (Open Source)](https://www.qt.io/download-open-source?hsCtaTracking=9f6a2170-a938-42df-a8e2-a9f0b1d6cdce%7C6cb0de4f-9bb5-4778-ab02-bfb62735f3e5)<br>
......@@ -119,7 +143,7 @@ Only 64-bit MSVC build can be compiled.
| | Qt Version | SDK | Toolset |
|---|---|---|---|
| Minimum requirement: | 5.14.0 | 10.0.16299.0 | V142 |
| Minimum requirement: | 6.2.0 | 10.0.16299.0 | V142 |
- Install [Python3](https://www.python.org/downloads/) for Windows
......@@ -207,6 +231,35 @@ Only 64-bit MSVC build can be compiled.
- For more available options, run scripts with ```-h``` option.
- ```--qtver``` option is available on ```make-lrc.py``` and ```make-client.py```.
## Building On MacOS
**Set up**
- macOS minimum version 10.13
- install python3
- download xcode
- install Qt 6.2
Qt 6.2 can be installed via brew
```brew install qt
```
or downloaded from [Qt (Open Source)](https://www.qt.io/download-open-source?hsCtaTracking=9f6a2170-a938-42df-a8e2-a9f0b1d6cdce%7C6cb0de4f-9bb5-4778-ab02-bfb62735f3e5)
Then, you can build the project
**Build with build.py**
```git clone https://review.jami.net/jami-project
cd jami-project
./build.py --init
./build.py --dependencies --qt
./build.py --install --qt
```
If you use a Qt version that is installed in a different than standard location you need to specify its path
```./build.py --install --qt QT_ROOT_DIRECTORY=your_qt_directory
```
Built client could be find in `client-qt/build-local/Jami`
## Packaging On Native Windows
- To be able to generate a msi package, first download and install [Wixtoolset](https://wixtoolset.org/releases/).
......@@ -235,4 +288,6 @@ Only 64-bit MSVC build can be compiled.
## Debugging
Compile the client with `BUILD=Debug` and compile LibRingClient with
`-DCMAKE_BUILD_TYPE=Debug`
\ No newline at end of file
`-DCMAKE_BUILD_TYPE=Debug`
Then, if you want to enable logging when running `jami-qt` launch it with `-d` or `--debug`
......@@ -10,12 +10,9 @@ RUN apt-get update && \
RUN apt install gnupg dirmngr ca-certificates curl --no-install-recommends
RUN curl -s https://dl.jami.net/public-key.gpg | tee /usr/share/keyrings/jami-archive-keyring.gpg > /dev/null
RUN sh -c "echo 'deb [signed-by=/usr/share/keyrings/jami-archive-keyring.gpg] https://dl.jami.net/nightly/ubuntu_20.04/ jami main' > /etc/apt/sources.list.d/jami.list"
RUN sh -c "echo 'deb [signed-by=/usr/share/keyrings/jami-archive-keyring.gpg] https://dl.jami.net/internal/ubuntu_20.04/ jami main' > /etc/apt/sources.list.d/jami.list"
RUN apt-get update && apt-get install libqt-jami -y
ENV QT5_PATH=/usr/lib/libqt-jami/
ENV QT5_VER=5.15.2
RUN apt-get install -y -o Acquire::Retries=10 \
python3 \
git \
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment