-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCMakeLists.txt
More file actions
27 lines (23 loc) · 875 Bytes
/
CMakeLists.txt
File metadata and controls
27 lines (23 loc) · 875 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
cmake_minimum_required(VERSION 3.21)
project (Plugin.Core.SamplePlugin)
# Top-level plugin build is not supported yet.
# If the plugin is only built as subdirectory, this snippet is not needed and may be discarded.
if (PROJECT_IS_TOP_LEVEL)
set (CMAKE_CXX_STANDARD 17)
find_package (Urho3D REQUIRED)
endif ()
file (GLOB SOURCE_FILES *.h *.cpp)
add_plugin (${PROJECT_NAME} "${SOURCE_FILES}")
if (URHO3D_CSHARP)
set (DEST_BIN_DIR_CONFIG bin)
set (DEST_LIBRARY_DIR_CONFIG bin)
target_include_directories (${PROJECT_NAME} PRIVATE ${CMAKE_CURRENT_SOURCE_DIR})
csharp_bind_target(
TARGET ${PROJECT_NAME}
SWIG ${CMAKE_CURRENT_SOURCE_DIR}/CSharp/Plugin.i
CSPROJ ${CMAKE_CURRENT_SOURCE_DIR}/CSharp/Plugin.csproj
NAMESPACE Urho3DNet
)
endif ()
# Generate Visual Studio props file for csproj.
rbfx_configure_cmake_props()