-# Additional compile settings
-#####################################################################
-
-# This sets -fPIC and friends if required by the installed Qt5 library
-if (Qt5_POSITION_INDEPENDENT_CODE)
- set(CMAKE_POSITION_INDEPENDENT_CODE ON)
- set(CMAKE_REQUIRED_FLAGS "-DQT_NO_VERSION_TAGGING")
-endif()
-
-# Needed to compile with mingw without kde
-if (MINGW AND NOT WITH_KDE)
- add_definitions(-D_WIN32_WINNT=0x0500)
- message(STATUS "Added _WIN32_WINNT=0x0500 definition for MinGW")
- # workaround for bug in mingw gcc 4.0
- add_definitions(-U__STRICT_ANSI__)
-endif()
-
-# Sanitize compiler flags - old versions of KDE set -ansi, which breaks -std=c++11
-if (CMAKE_COMPILER_IS_GNUCXX)
- string(REPLACE "-ansi" "" CMAKE_CXX_FLAGS ${CMAKE_CXX_FLAGS})
-endif()
-
-# Setup LDAP Authentication support.
-#####################################################################
-if (WITH_LDAP)
- find_package(Ldap)
- if (LDAP_FOUND)
- message(STATUS "Enabling LDAP authentication support")
- else()
- message(STATUS "Disabling LDAP authentication support")
- endif()
-else()
- message(STATUS "Not enabling LDAP authentication support")