- Dependencies
- Linux
- BSD
- macOS
- Windows
- Compile-time switches
Name | Version | Modules |
---|---|---|
Qt | >= 6.2.0 | concurrent, core, gui, network, svg, widget, xml |
GCC/MinGW | >= 11 | C++17 enabled |
toxcore | >= 0.2.20 | core, av |
FFmpeg | >= 2.6.0 | avformat, avdevice, avcodec, avutil, swscale |
CMake | >= 3.10 | |
OpenAL Soft | >= 1.16.0 | |
qrencode | >= 3.0.3 | |
sqlcipher | >= 3.2.0 | |
pkg-config | >= 0.28 |
They can be disabled/enabled by passing arguments to cmake
command when
building qTox.
If they are missing, qTox is built without support for the functionality.
Name | Version |
---|---|
sonnet | >= 6.0 |
Use -DSPELL_CHECK=OFF
to disable it.
Note: Specified version was tested and works well. You can try to use older version, but in this case you may have some errors (including a complete lack of spell check).
Name | Version |
---|---|
libXScrnSaver | >= 1.2 |
libX11 | >= 1.6.0 |
Disabled if dependencies are missing during compilation.
Easy qTox install is provided for variety of distributions:
PKGBUILD is available in the community
repo, to install:
pacman -S qtox
qTox is available in the Main repo, to install:
sudo apt install qtox
qTox is available in the RPM Fusion repo, to install:
dnf install qtox
qTox is available in Gentoo.
To install:
emerge qtox
qTox is available in openSUSE Factory.
To install in openSUSE 15.0 or newer:
zypper in qtox
To install in openSUSE 42.3:
zypper ar -f https://download.opensuse.org/repositories/server:/messaging/openSUSE_Leap_42.3 server:messaging
zypper in qtox
qTox SlackBuild and all of its dependencies can be found here: http://slackbuilds.org/repository/14.2/network/qTox/
If your distribution is not listed, or you want / need to compile qTox, there are provided instructions.
Most of the dependencies should be available through your package manager.
qTox is available in the Universe repo, to install:
sudo apt install qtox
In order to clone the qTox repository you need Git.
sudo pacman -S --needed git
sudo apt-get install git
sudo dnf install git
sudo zypper install git
sudo apt-get install git
Afterwards open a new terminal, change to a directory of your choice and clone the repository:
cd /home/$USER
git clone https://github.com/qTox/qTox.git qTox
cd qTox
The following steps assumes that you cloned the repository at
/home/$USER/qTox
. If you decided to choose another location, replace
corresponding parts.
Development can be done within one of the many provided docker containers. See the available configurations in docker-compose.yml. These docker images have all the required dependencies for development already installed. Run docker compose run --rm ubuntu_lts
and proceed to compiling qTox. If you want to avoid compiling as root in the docker image, you can run USER_ID=$(id -u) GROUP_ID=$(id -g) docker compose run --rm ubuntu_lts
instead.
NOTE: qtox will not run in the docker container unless your x11 session allows connections from other users. If X11 is giving you issues in the docker image, try xhost +
on your host machine
Please see https://github.com/TokTok/dockerfiles/tree/master/qtox/docker for your distribution for an up to date list of commands to set up your build environment
Provided that you have all required dependencies installed, you can simply run:
git clone https://github.com/TokTok/c-toxcore.git toxcore
cd toxcore
# Note: See https://github.com/TokTok/dockerfiles/blob/master/qtox/download/download_toxcore.sh
# for which version should be checked out.
cmake -B_build -H. -GNinja -DBOOTSTRAP_DAEMON=OFF
cmake --build _build
sudo cmake --install _build
# we don't know what whether user runs 64 or 32 bits, and on some distros
# (Fedora, openSUSE) lib/ doesn't link to lib64/, so add both
echo '/usr/local/lib64/' | sudo tee -a /etc/ld.so.conf.d/locallib.conf
echo '/usr/local/lib/' | sudo tee -a /etc/ld.so.conf.d/locallib.conf
sudo ldconfig
Make sure that all the dependencies are installed. If you experience problems with compiling, it's most likely due to missing dependencies, so please make sure that you did install all of them.
If you are compiling on Fedora 25, you must add libtoxcore to the
PKG_CONFIG_PATH
environment variable manually:
# we don't know what whether user runs 64 or 32 bits, and on some distros
# (Fedora, openSUSE) lib/ doesn't link to lib64/, so add both
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/lib64/pkgconfig"
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:/usr/local/lib/pkgconfig"
Run in qTox directory to compile:
cmake -B_build -H.
cmake --build _build
Now you can start compiled qTox with _build/qtox
Congratulations, you've compiled qTox :)
If the compiling process stops with a missing dependency like:
... libswscale/swscale.h missing
try:
apt-file search libswscale/swscale.h
And install the package that provides the missing file.
Start make again. Repeat if necessary until all dependencies are installed. If
you can, please note down all additional dependencies you had to install that
aren't listed here, and let us know what is missing ;)
See AppArmor to enable confinement for increased security.
qTox is available as a binary package. To install the qTox package:
pkg install qTox
The qTox port is also available at net-im/qTox
. To build and install qTox
from sources using the port:
cd /usr/ports/net-im/qTox
make install clean
Supported macOS versions: >=10.15.
Compiling qTox on macOS for development requires 2 tools: Xcode and homebrew.
Install homebrew if you don't have it:
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
First, clone qTox.
git clone https://github.com/qTox/qTox
cd qTox
Then install required dependencies available via brew
.
brew bundle --file macos/Brewfile
Then, install toxcore.
git clone --depth=1 https://github.com/TokTok/dockerfiles
dockerfiles/qtox/build_toxcore_linux.sh
Finally, build qTox.
cmake -B_build -H. -GNinja -DCMAKE_PREFIX_PATH=$(brew --prefix qt@6)
cmake --build _build
cmake --install _build
qTox.dmg
should be in your _build
directory. You can install qTox from the dmg
to your Applications folder, or run qTox directly from the dmg.
Only cross-compiling from Linux is supported and tested in CI, but building under MSYS should also work.
They are passed as an argument to cmake
command. E.g. with a switch SWITCH
that has value ON
it would be passed to cmake
in a following manner:
cmake -DSWITCH=ON
Look at the beginning of CMakeLists.txt
for a list of options. Options that
are ON
by default can be turned off by passing -DSWITCH=OFF
.