Demonstrative example of building Qt with CMake and GitHub Actions
- CMake
- C++ compiler of your choice
. - Root directory
.github/workflows - GitHub Actions workflows
The project is built automatically using GitHub Actions on push and pull request. The workflow is defined at .github/workflows/cmake.yml, and configured to build using the latest Windows GitHub Runned (windows-latest) using CMake.
Once required tools are installed, this minimum reproducible project can be built via command-line using the following commands:
- mkdir build
- cd build
- cmake -G "MinGW Makefiles" ..
- cmake --build .
The project should now be built in a location appropriate to your C++ compiler. For example, the build location for MinGW should be ./build/hello-cmake-qt.exe.
Ensure that your C++ compiler and CMake are in your PATH environment variable so that the executables are visible.