CMakeLists.txt 995 Bytes
Newer Older
Tobias WEBER's avatar
Tobias WEBER committed
1 2 3 4 5
#
# @author Tobias Weber
# @date dec-2019
# @license GPLv3, see 'LICENSE' file
#
Tobias WEBER's avatar
Tobias WEBER committed
6 7 8
# cmake -DCMAKE_BUILD_TYPE=Release ..
# mingw64-cmake -DCMAKE_BUILD_TYPE=Release ..
#
Tobias WEBER's avatar
Tobias WEBER committed
9 10 11 12 13 14

cmake_minimum_required(VERSION 3.0)
project(moldyn)

set(CMAKE_VERBOSE_MAKEFILE TRUE)

Tobias WEBER's avatar
defines  
Tobias WEBER committed
15

Tobias WEBER's avatar
Tobias WEBER committed
16
#find_package(Boost REQUIRED COMPONENTS system REQUIRED)
Tobias WEBER's avatar
Tobias WEBER committed
17 18 19
find_package(Boost REQUIRED)
find_package(Qt5 REQUIRED COMPONENTS Core Gui Widgets OpenGL)

Tobias WEBER's avatar
defines  
Tobias WEBER committed
20

Tobias WEBER's avatar
Tobias WEBER committed
21 22 23 24 25 26
set(CMAKE_AUTOUIC TRUE)
set(CMAKE_AUTOMOC TRUE)

set(CMAKE_CXX_STANDARD 20)
add_definitions(-std=c++2a -fconcepts)
add_definitions(${Boost_CXX_FLAGS})
Tobias WEBER's avatar
Tobias WEBER committed
27
add_definitions(-DBOOST_SYSTEM_NO_DEPRECATED -DBOOST_ERROR_CODE_HEADER_ONLY)
Tobias WEBER's avatar
defines  
Tobias WEBER committed
28 29
add_definitions(-D_GL_MAJ_VER=3 -D_GL_MIN_VER=3 -D_GL_SUFFIX=_Core)

Tobias WEBER's avatar
Tobias WEBER committed
30 31 32 33 34 35 36 37 38 39 40 41 42

include_directories(
	"${PROJECT_SOURCE_DIR}" "${Boost_INCLUDE_DIRS}/.." "../.."
	"ext"
)


add_executable(moldyn
	moldyn.cpp moldyn.h
	../../libs/_cxx20/glplot.cpp ../../libs/_cxx20/glplot.h)

target_link_libraries(moldyn ${Boost_LIBRARIES})
qt5_use_modules(moldyn Core Gui Widgets OpenGL)