Skip to content
Permalink
Browse files

native/CMakeLists.txt cleanup (#8380)

  • Loading branch information
3nids committed Oct 31, 2018
1 parent a003f4f commit cb5c326da9b0a81c35a0ad15253e4720c8ef130b
Showing with 24 additions and 33 deletions.
  1. +24 −33 src/native/CMakeLists.txt
@@ -4,7 +4,7 @@
SET(NATIVE_LINK_LIBS)

IF(UNIX AND NOT APPLE AND NOT ANDROID)
FIND_PACKAGE(Qt5DBus REQUIRED)
FIND_PACKAGE(Qt5DBus REQUIRED)
ENDIF(UNIX AND NOT APPLE AND NOT ANDROID)

IF(APPLE)
@@ -36,7 +36,11 @@ SET(QGIS_NATIVE_SRCS
qgsnative.cpp
)

SET (QGIS_NATIVE_MOC_HDRS
SET(QGIS_NATIVE_MOC_HDRS
qgsnative.h
)

SET(QGIS_NATIVE_HDRS
qgsnative.h
)

@@ -51,57 +55,44 @@ IF(APPLE)
SET(QGIS_NATIVE_SRCS ${QGIS_NATIVE_SRCS}
${QGIS_APP_OBJC_SRCS}
)
SET (QGIS_NATIVE_MOC_HDRS
${QGIS_NATIVE_MOC_HDRS}
mac/qgsmacnative.h
)
SET (QGIS_NATIVE_HDRS ${QGIS_NATIVE_HDRS}
mac/qgsmacnative.h
mac/cocoainitializer.h
)
ENDIF(APPLE)

IF(MSVC)
SET(QGIS_APP_WIN32_SRCS
SET(QGIS_NATIVE_SRCS ${QGIS_NATIVE_SRCS}
../../external/wintoast/src/wintoastlib.cpp
win/qgswinnative.cpp
)
SET (QGIS_NATIVE_MOC_HDRS
${QGIS_NATIVE_MOC_HDRS}
win/qgswinnative.h
)
SET(QGIS_NATIVE_SRCS ${QGIS_NATIVE_SRCS}
${QGIS_APP_WIN32_SRCS}
SET (QGIS_NATIVE_HDRS ${QGIS_NATIVE_HDRS}
win/qgswinnative.h
)
ENDIF(MSVC)

IF(UNIX AND NOT APPLE AND NOT ANDROID)
SET(QGIS_APP_LINUX_SRCS
linux/qgslinuxnative.cpp
)
SET(QGIS_NATIVE_SRCS ${QGIS_NATIVE_SRCS}
${QGIS_APP_LINUX_SRCS}
)
ENDIF(UNIX AND NOT APPLE AND NOT ANDROID)

SET(QGIS_NATIVE_HDRS
qgsnative.h
)

QT5_WRAP_CPP(QGIS_NATIVE_MOC_SRCS ${QGIS_NATIVE_MOC_HDRS})

# install headers

IF(APPLE)
SET (QGIS_NATIVE_HDRS ${QGIS_NATIVE_HDRS}
mac/qgsmacnative.h
mac/cocoainitializer.h
linux/qgslinuxnative.cpp
)
ENDIF(APPLE)

IF(MSVC)
SET (QGIS_NATIVE_HDRS ${QGIS_NATIVE_HDRS}
win/qgswinnative.h
SET (QGIS_NATIVE_MOC_HDRS
${QGIS_NATIVE_MOC_HDRS}
linux/qgslinuxnative.h
)
ENDIF(MSVC)

IF(UNIX)
SET (QGIS_NATIVE_HDRS ${QGIS_NATIVE_HDRS}
linux/qgslinuxnative.h
)
ENDIF(UNIX)
ENDIF(UNIX AND NOT APPLE AND NOT ANDROID)

QT5_WRAP_CPP(QGIS_NATIVE_MOC_SRCS ${QGIS_NATIVE_MOC_HDRS})

INCLUDE_DIRECTORIES(
${CMAKE_CURRENT_SOURCE_DIR}

0 comments on commit cb5c326

Please sign in to comment.
You can’t perform that action at this time.