Created
September 26, 2017 13:10
-
-
Save veggiesaurus/3aeb1b1d14d2a6be4422b5a675870e10 to your computer and use it in GitHub Desktop.
Dummy CMakeList for CARTA -> CLion editing/debugging
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cmake_minimum_required(VERSION 3.0) | |
project(CartaDummyCmake) # Your project name | |
set(CMAKE_CXX_STANDARD 11) # This is equal to QMAKE_CXX_FLAGS += -std=c++0x | |
# Find includes in corresponding build directories | |
set(CMAKE_INCLUDE_CURRENT_DIR ON) | |
# Instruct CMake to run moc automatically when needed. | |
set(CMAKE_AUTOMOC OFF) | |
# Instruct CMake to run uic automatically when needed. | |
set(CMAKE_AUTOUIC OFF) | |
# This will find the Qt5 files. You will need a QT5_DIR env variable | |
find_package( Qt5Core REQUIRED ) | |
find_package( Qt5Widgets REQUIRED ) | |
find_package( Qt5Gui REQUIRED ) | |
MACRO(HEADER_DIRECTORIES return_list) | |
FILE(GLOB_RECURSE new_list *.h) | |
SET(dir_list "") | |
FOREACH(file_path ${new_list}) | |
GET_FILENAME_COMPONENT(dir_path ${file_path} PATH) | |
SET(dir_list ${dir_list} ${dir_path}) | |
ENDFOREACH() | |
LIST(REMOVE_DUPLICATES dir_list) | |
SET(${return_list} ${dir_list}) | |
ENDMACRO() | |
HEADER_DIRECTORIES(header_dirs) | |
include_directories(${header_dirs}) | |
include_directories("./cpp") | |
include_directories("../../CARTAvis-externals/ThirdParty/ast/include") | |
include_directories("../../CARTAvis-externals/ThirdParty/casacore/include") | |
include_directories("../../CARTAvis-externals/ThirdParty/hdf5/include") | |
include_directories("../../CARTAvis-externals/ThirdParty/highfive/include") | |
include_directories("../../CARTAvis-externals/ThirdParty/imageanalysis/include") | |
include_directories("../../CARTAvis-externals/ThirdParty/qwt/include") | |
include_directories("../../CARTAvis-externals/ThirdParty/rapidjson/include") | |
include_directories("../../CARTAvis-externals/ThirdParty/highfive") | |
FILE(GLOB_RECURSE all_headers *.h) | |
FILE(GLOB_RECURSE all_src *.cpp) | |
add_executable(dummy ${all_headers} ${all_src}) | |
qt5_use_modules( dummy Core Widgets Gui ) | |
add_custom_target(empty) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment