mirror of
https://github.com/sqlitebrowser/sqlitebrowser.git
synced 2026-01-25 21:40:25 -06:00
A wiki article pointed out that whitespace will only be preserved for parameters in CMake commands if passed strings will be appropriately quoted or escaped. http://cmake.org/Wiki/CMake/Language_Syntax#CMake_splits_arguments_unless_you_use_quotation_marks_or_escapes. Quoting was added so that more places should also handle file names correctly which contain space characters or semicolons eventually. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
34 lines
635 B
CMake
34 lines
635 B
CMake
cmake_minimum_required(VERSION 2.8.9)
|
|
|
|
if(USE_QT5)
|
|
set(CMAKE_AUTOMOC ON)
|
|
set(CMAKE_INCLUDE_CURRENT_DIR ON)
|
|
find_package(Qt5Widgets REQUIRED)
|
|
else()
|
|
find_package(Qt4 COMPONENTS QtCore QtGui REQUIRED)
|
|
include("${QT_USE_FILE}")
|
|
add_definitions(${QT_DEFINITIONS})
|
|
endif()
|
|
|
|
set(QCUSTOMPLOT_SRC
|
|
qcustomplot.cpp
|
|
)
|
|
|
|
set(QCUSTOMPLOT_HDR
|
|
)
|
|
|
|
set(QCUSTOMPLOT_MOC_HDR
|
|
qcustomplot.h
|
|
)
|
|
|
|
if(NOT USE_QT5)
|
|
QT4_WRAP_CPP(QCUSTOMPLOT_MOC ${QCUSTOMPLOT_MOC_HDR})
|
|
endif()
|
|
|
|
add_library(qcustomplot ${QCUSTOMPLOT_SRC} ${QCUSTOMPLOT_HDR} ${QCUSTOMPLOT_MOC})
|
|
|
|
if(USE_QT5)
|
|
qt5_use_modules(qcustomplot Widgets PrintSupport)
|
|
endif()
|
|
|