-
Notifications
You must be signed in to change notification settings - Fork 69
/
CMakeLists.txt
119 lines (108 loc) · 3.56 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
find_package(GTest REQUIRED)
set(PXR_PACKAGE AL_USDMayaTestPlugin)
list(APPEND AL_maya_test_headers
test_usdmaya.h
)
list(APPEND AL_maya_test_source
plugin.cpp
AL/maya/test_DiffCore.cpp
AL/maya/test_EventHandler.cpp
AL/maya/test_MatrixToSRT.cpp
AL/maya/test_MayaEventManager.cpp
AL/usdmaya/commands/test_ExportCommands.cpp
AL/usdmaya/commands/test_LayerCommands.cpp
AL/usdmaya/commands/test_ProxyShapeSelect.cpp
AL/usdmaya/commands/test_InternalProxySelection.cpp
AL/usdmaya/commands/test_ProxyShapeImport.cpp
AL/usdmaya/commands/test_LayerManagerCommands.cpp
AL/usdmaya/fileio/export_blendshape.cpp
AL/usdmaya/fileio/export_constraints.cpp
AL/usdmaya/fileio/export_ik.cpp
AL/usdmaya/fileio/export_import_instancing.cpp
AL/usdmaya/fileio/export_lattice.cpp
AL/usdmaya/fileio/export_nonlinear.cpp
AL/usdmaya/fileio/export_unmerged.cpp
AL/usdmaya/fileio/export_multiple_shapes.cpp
AL/usdmaya/fileio/import_instances.cpp
AL/usdmaya/fileio/test_activeInActiveTranslators.cpp
AL/usdmaya/nodes/test_ActiveInactive.cpp
AL/usdmaya/nodes/test_LayerManager.cpp
AL/usdmaya/nodes/test_ProxyShape.cpp
AL/usdmaya/nodes/test_ProxyUsdGeomCamera.cpp
AL/usdmaya/nodes/test_Transform.cpp
AL/usdmaya/nodes/test_TransformMatrix.cpp
AL/usdmaya/nodes/test_TranslatorContext.cpp
AL/usdmaya/nodes/test_ExtraDataPlugin.cpp
AL/usdmaya/nodes/test_ProxyShapeSelectabilityDB.cpp
AL/usdmaya/nodes/proxy/test_PrimFilter.cpp
AL/usdmaya/test_SelectabilityDB.cpp
AL/usdmaya/test_DiffGeom.cpp
AL/usdmaya/test_DiffPrimVar.cpp
AL/usdmaya/commands/test_TranslateCommand.cpp
test_translators_AnimationTranslator.cpp
test_translators_CameraTranslator.cpp
test_translators_DgTranslator.cpp
test_translators_MeshTranslator.cpp
test_translators_NurbsCurveTranslator.cpp
test_translators_TransformTranslator.cpp
test_translators_Translator.cpp
test_translators_PythonBindings.cpp
test_usdmaya_AttributeType.cpp
test_usdmaya.cpp
)
add_library(${PXR_PACKAGE} ${AL_maya_test_source})
target_compile_definitions(${PXR_PACKAGE}
PRIVATE
AL_USDMAYA_UNITTEST
AL_USDMAYATEST_PLUGIN_EXPORT
AL_USDMAYA_TEST_DATA="${CMAKE_CURRENT_SOURCE_DIR}/test_data"
)
target_link_libraries(${PXR_PACKAGE}
AL_EventSystem
AL_USDMayaUtils
AL_MayaUtils
AL_USDUtils
AL_USDMaya #Adding this recursively pulls in lots of things
AL_MayaTest
AL_USDMayaSchemas
AL_USDMayaSchemasTest
${GTEST_LIBRARIES}
)
target_include_directories(${PXR_PACKAGE}
PRIVATE
${GTEST_INCLUDE_DIRS}
${MAYA_INCLUDE_DIRS}
"../../lib/AL_USDMaya"
"../../schemas"
${MAYATEST_INCLUDE_LOCATION}
)
if(MSVC)
set_target_properties(${PXR_PACKAGE} PROPERTIES SUFFIX ".mll")
else()
set(rpath "$ORIGIN:$ORIGIN/../lib")
if (CMAKE_INSTALL_RPATH)
set(rpath "${CMAKE_INSTALL_RPATH}:${rpath}")
endif()
set_target_properties(${PXR_PACKAGE}
PROPERTIES
PREFIX ""
INSTALL_RPATH "${rpath}"
)
endif()
install(TARGETS
${PXR_PACKAGE}
LIBRARY
DESTINATION plugin
RUNTIME
DESTINATION plugin
)
add_test(
NAME TestAL_USDMaya
COMMAND
${CMAKE_CURRENT_SOURCE_DIR}/run_mayaplugin_tests.sh
${CMAKE_INSTALL_PREFIX}
${CMAKE_CURRENT_SOURCE_DIR}
)
if(NOT SKIP_USDMAYA_TESTS)
add_subdirectory(py)
endif()