CMakeLists.txt 1.25 KB
Newer Older
Tobias WEBER's avatar
Tobias WEBER committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#
# @author Tobias Weber <tweber@ill.fr>
# @date 6-apr-2018
# @license see 'LICENSE' file
#

project(in20tools)
cmake_minimum_required(VERSION 3.0)


message("Build type: ${CMAKE_BUILD_TYPE}")

if(NOT "${CMAKE_BUILD_TYPE}" STREQUAL "Release")
	set(CMAKE_VERBOSE_MAKEFILE TRUE)
endif()


set(CMAKE_CXX_STANDARD 17)
add_definitions(-std=c++17)



# -----------------------------------------------------------------------------
Tobias WEBER's avatar
Tobias WEBER committed
24
25
26
27
28
# Boost
find_package(Boost REQUIRED COMPONENTS system filesystem iostreams REQUIRED)
add_definitions(${Boost_CXX_FLAGS})

# Qt
Tobias WEBER's avatar
Tobias WEBER committed
29
30
31
32
33
34
35
36
37
find_package(Qt5Core REQUIRED)
find_package(Qt5Gui REQUIRED)
find_package(Qt5Widgets REQUIRED)
find_package(Qt5PrintSupport REQUIRED)
set(CMAKE_AUTOMOC ON)
set(CMAKE_AUTOUIC ON)
# -----------------------------------------------------------------------------


Tobias WEBER's avatar
Tobias WEBER committed
38
39
40
41
42
include_directories(
	"${PROJECT_SOURCE_DIR}" "${PROJECT_SOURCE_DIR}/ext"
	"${Boost_INCLUDE_DIRS}" "${Boost_INCLUDE_DIRS}/.."
)

Tobias WEBER's avatar
Tobias WEBER committed
43
44
45

add_executable(in20
	tools/in20/main.cpp tools/in20/mainwnd.cpp tools/in20/mainwnd.h
Tobias WEBER's avatar
Tobias WEBER committed
46
	tools/in20/filebrowser.cpp tools/in20/filebrowser.h
Tobias WEBER's avatar
Tobias WEBER committed
47
48
49

	ext/tlibs/log/log.cpp ext/tlibs/file/loadinstr.cpp

Tobias WEBER's avatar
Tobias WEBER committed
50
51
52
53
54
	ext/qcp/qcustomplot.cpp ext/qcp/qcustomplot.h
)


target_link_libraries(in20
Tobias WEBER's avatar
Tobias WEBER committed
55
	${Boost_LIBRARIES}
Tobias WEBER's avatar
Tobias WEBER committed
56
57
	Qt5::Core Qt5::Gui Qt5::Widgets Qt5::PrintSupport
)