From: APTX Date: Mon, 21 Feb 2022 13:17:19 +0000 (+0900) Subject: Update cmake for INTERFACE LIBRARY feature X-Git-Url: https://gitweb.aptx.org/?a=commitdiff_plain;h=9a4503eabd24aad39c947f7bae798ccf225b8363;p=aniplayer.git Update cmake for INTERFACE LIBRARY feature --- diff --git a/CMakeLists.txt b/CMakeLists.txt index c27aec8..09e5b9c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,5 @@ -cmake_minimum_required(VERSION 3.8 FATAL_ERROR) +# 3.19 Due to interface LIBRARY +cmake_minimum_required(VERSION 3.19 FATAL_ERROR) include(FeatureSummary) include(CMakeDependentOption) diff --git a/pluginapi/CMakeLists.txt b/pluginapi/CMakeLists.txt index c25990b..7522ec1 100644 --- a/pluginapi/CMakeLists.txt +++ b/pluginapi/CMakeLists.txt @@ -9,16 +9,10 @@ set(pluginapi_PUBLIC_HEADERS aniplayer/playerfeatureplugininterface.h ) -add_library(pluginapi INTERFACE) +add_library(pluginapi INTERFACE ${pluginapi_PUBLIC_HEADERS}) find_package(Qt5 COMPONENTS Core) -target_link_libraries(pluginapi INTERFACE ${pluginapi_LIBS}) target_link_libraries(pluginapi INTERFACE Qt5::Core) install(FILES ${pluginapi_PUBLIC_HEADERS} DESTINATION include/aniplayer ) - -# IDE hack -#project(pluginapi_ide CXX) -add_custom_target(pluginapi_ide SOURCES ${pluginapi_PUBLIC_HEADERS}) -