Compiling Evoplex
The instructions below assume that you have already downloaded the source code, and installed all dependencies.
Evoplex uses CMake to allow easy and portable compilation. In this document, we explain how you can compile the source code from command-line or by using QtCreator, which is a free, open-source and cross-platform IDE suitable for projects using the Qt Framework.
Note that if you installed the dependencies correctly, you should already have QtCreator installed on your computer.
Need help? click here
Instructions for Linux and macOS
Show/Hide
Building from the command-line
Assuming you are at ~/evoplex/
and the source code is at ~/evoplex/evoplex/
,
- Create a folder
mkdir build
- Access the folder
cd build
- Run
cmake ../evoplex/
- Run
cmake --build .
To run Evoplex:
- On Linux:
./bin/evoplex
- On macOS:
./bin/evoplex.app/Contents/MacOS/evoplex
Build using QtCreator
- In the toolbar, click on
File => Open File or Project...
- In the
~/evoplex/evoplex/
directory, select theCMakeLists.txt
file - Open the
Projects
panel (it may open automatically when you first open the CMake file)- Select the desired modes (eg., Release)
- Choose the directory in which Evoplex will be built (eg.,
~/evoplex/build/
) - Click on
Configure Project
- Optionally, you may want to set the
-j N
variable in theProject
panel to allow building it in parallel (faster), where N is the number of working threads (e.g., 8). - Click on Build
Instructions for Windows
Show/Hide
Building from the command-line
If you installed Git and all dependencies correctly, you should have Git Bash installed on your computer.
- Open Git Bash
- Access the root Evoplex directory, eg.,
cd /c/evoplex/
- Create a build directory and access it, ie.,
mkdir build && cd build
- Assuming the repository is at
C:/evoplex/evoplex
; run cmake to generate the build filescmake.exe -G "Visual Studio 15 2017 Win64" ../evoplex
- Finally, build it!
cmake.exe --build . --config Release --target ALL_BUILD -- /maxcpucount:8
- Now, to run Evoplex:
./releases/evoplex
Building with QtCreator
I. Configuring QtCreator
If you installed all dependencies correctly,
- In QtCreator, open
Tools => Options...
in the toolbar - Open the 'Kits' tab in the
Build&Run
panel. - Click on the auto-detected kit (eg., Desktop Qt 5.9.5 MSVC2017 64bit)
- Make sure the compiler (C and C++) is set correctly. For example:
- C
Microsoft Visual C++ Compiler 15.0 (amd64)
- C++
Microsoft Visual C++ Compiler 15.0 (amd64)
- C
- Make sure that the path to the
CMake Tool
was detected (eg.,C:\Program Files\CMake\bin\cmake.exe
) - Make sure the CMake generator is set to your version of Visual Studio (eg.,
Visual Studio 15 2017 Win64
). Leave the fieldsPlatform
andToolset
blank.
- Make sure the compiler (C and C++) is set correctly. For example:
- Click OK
II. Configuring QtCreator for Evoplex
- In the toolbar, click on
File => Open File or Project...
- In the
C:\evoplex\evoplex\
directory, select theCMakeLists.txt
file - Open the
Projects
panel (it may open automatically when you first open the CMake file)- Select the desired modes (eg., Release)
- Choose the directory in which Evoplex will be built (eg.,
C:/evoplex/build/
) - Click on
Configure Project
- Wait until the project loads, go back to the 'Projects' panel. There, make sure you target
ALL_BUILD
in the build steps. Optionally, you may want to set the/maxcpucount:N
variable to build it in parallel, where N is the number of working threads.