diff --git a/Build-QML-Client-on-GNU/Linux.md b/Build-QML-Client-on-GNU/Linux.md new file mode 100644 index 0000000000000000000000000000000000000000..b84ab452a50d99d4526a86705da3c9282c80c02b --- /dev/null +++ b/Build-QML-Client-on-GNU/Linux.md @@ -0,0 +1,69 @@ +Build QML Client on GNU/Linux +============================= +The QML Client has been tested on Ubuntu 20.04, it is necessary to install Qt version >= 5.15, the Daemon and LRC as described below. + +Qt 5.15 +------- +In order to use the QML Client it is necessary to install the Qt version 5.15 or higher. You can install it [from sources or download the binary installer](https://www.qt.io/download). + +Daemon +------ +You can download and install the Jami daemon as described in the [instructions](https://git.jami.net/savoirfairelinux/ring-daemon). + +LRC +--- +It is necessary to compile the *libringclient* with the installed Qt version 5.15. Before compiling you should remove all files in build folder and set the path to Qt libraries, for example, if Qt installation folder is in your home directory: + +```sh +export CMAKE_PREFIX_PATH=~/Qt/5.15.0/gcc_64 +export LD_LIBRARY_PATH=~/Qt/5.15.0/gcc_64/lib +``` + +Then you can download and build LRC library as described in the [instructions](https://git.jami.net/savoirfairelinux/ring-lrc/blob/master/INSTALL): +```sh +cd build +cmake .. +make +``` +Check that *libringclient* uses the correct path for the Qt libraries with: + +```sh +ldd libringclient.so +libQt5DBus.so.5 => /home/<username>/Qt/5.15.0/gcc_64/lib/libQt5DBus.so.5 (0x00007fad4599b000) +(...) +``` + +QML Client +---------- +Once the LRC is build you can download and compile the QML Client as described in the [Windows Client instructions](https://git.jami.net/savoirfairelinux/ring-lrc/blob/master/INSTALL). + +**Note**: If LRC has been built inside its project directory, you need to add the path in the jami-qt.pro: + +Change: + +```sh +isEmpty(LRC) { LRC=../../install/lrc/ } +INCLUDEPATH += $${LRC}/include/libringclient +INCLUDEPATH += $${LRC}/include +INCLUDEPATH += ../src + +To: + +```sh +LIBS += -L$$PWD/../lrc/build-local/ -lringclient +INCLUDEPATH += $$PWD/../lrc/build-local +INCLUDEPATH += $$PWD/../lrc/src +``` + +**Linker issue**: With Ubuntu 20.04, even if the build process finish with success, the linker might give you the following message: + +```sh +/usr/bin/ld: /home/ababi/Qt/5.15.0/gcc_64/lib/libQt5WebEngineCore.so: .dynsym local symbol at index 3 (>= sh_info of 3) +(...) +``` +This has been solved by switching to [gold linker](https://forum.qt.io/topic/109387/gammaray-build-error-on-ubuntu): + +```sh +sudo ln -sf /usr/bin/x86_64-linux-gnu-ld.gold /usr/bin/ld +``` +