Skip to content
This repository has been archived by the owner on Dec 10, 2019. It is now read-only.

Compiling

Symeon Huang edited this page Aug 2, 2017 · 19 revisions

Dependencies

  • Qt >= 5.2 (qt5-qtbase-devel and cmake in Fedora, qtbase5-dev and cmake in Debian/Ubuntu)
  • Botan-1.10 (botan-devel in Fedora, libbotan1.10-dev in Debian/Ubuntu)
    • Or Botan-2 >= 2.2.0
  • A C++ Compiler that supports C++11 features (i.e. GCC >= 4.8)

Building

Building on GNU/Linux

Download and extract the latest source code tarball from release (DON'T use master branch code in production environment beacause it's always under development. You may be able to use stable branch if you wish so)

mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr
make -j4
sudo make install

The above procedures will compile and install both libQtShadowsocks and shadowsocks-libQtShadowsocks. If you're a packager, you might need to split it into two or three packages depending on your distribution's guidelines.

Botan-1.10 vs Botan-2

libQtShadowsocks is compiled against Botan-1.10 by default, to use Botan-2, you need to pass an additional argument -DUSE_BOTAN2=ON to cmake command.

Building on macOS

Requirements

Setup Environment

Install Qt and other dependencies if you don't have them installed.

brew update
brew install qt5 botan

libQtShadowsocks Installation

mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=/usr/local
make all
make install
Clone this wiki locally