-
Notifications
You must be signed in to change notification settings - Fork 14
/
CMakeLists.txt
51 lines (38 loc) · 1.13 KB
/
CMakeLists.txt
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
cmake_minimum_required(VERSION 3.13)
cmake_policy(SET CMP0074 NEW) # recognize <Package>_Root variables
project(spReticleLoc VERSION $ENV{SPDEV_COMPONENT_VERSION})
find_package(Maya REQUIRED)
set(PLUGIN_NAME "spReticleLoc")
#if (DEFINED ENV{SPK_PKG_VERSION})
# message(STATUS "SPK_PKG_VERSION: $ENV{SPK_PKG_VERSION}")
# add_definitions(-DPACKAGE_VERSION=$ENV{SPK_PKG_VERSION})
#endif()
# Needed by some Maya include files:
#add_definitions(-DLINUX)
file(GLOB SPRETICLELOC_SOURCES *.cpp)
add_library(
${PLUGIN_NAME}
SHARED
${SPRETICLELOC_SOURCES}
)
target_link_libraries(
${PLUGIN_NAME}
PRIVATE
Maya::OpenMaya
Maya::OpenMayaAnim
Maya::OpenMayaUI
)
target_include_directories(${PLUGIN_NAME} PRIVATE ${LIBS_INCLUDE})
file(MAKE_DIRECTORY scripts/maya/others)
install(FILES
AEspReticleLocTemplate.mel
DESTINATION scripts/maya/others
)
file(MAKE_DIRECTORY scripts/maya/spReticleLoc)
install(FILES
spReticleLoc.mel
spReticleLocWindows.mel
DESTINATION scripts/maya/spReticleLoc
)
set_target_properties(${PLUGIN_NAME} PROPERTIES PREFIX "")
install(TARGETS ${PLUGIN_NAME} DESTINATION plugins/maya)