diff options
author | Sybren A. Stüvel <sybren@stuvel.eu> | 2017-04-21 17:20:01 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@stuvel.eu> | 2017-04-21 17:20:01 +0300 |
commit | e6ee3fd9240b96a558988d443af6f6f52073e0b4 (patch) | |
tree | 6eb6b98adf91c288e9c717959d502640a6fae03f /tests/python/CMakeLists.txt | |
parent | 349cafac5243e1958f211cf67ee803cd3421a830 (diff) |
Alembic unit tests: don't depend on ALEMBIC_ROOT_DIR being defined by user
By mistake, the code relied on ALEMBIC_ROOT_DIR being defined by the user
running the tests. Now CMake macros are used to correctly find the Alembic
root directory.
Diffstat (limited to 'tests/python/CMakeLists.txt')
-rw-r--r-- | tests/python/CMakeLists.txt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/python/CMakeLists.txt b/tests/python/CMakeLists.txt index 30d593bd8d6..da795c8c020 100644 --- a/tests/python/CMakeLists.txt +++ b/tests/python/CMakeLists.txt @@ -444,6 +444,13 @@ if(WITH_CYCLES) endif() if(WITH_ALEMBIC) + find_package_wrapper(Alembic) + if(NOT ALEMBIC_FOUND) + message(FATAL_ERROR "Alembic is enabled but cannot be found") + endif() + get_filename_component(real_include_dir ${ALEMBIC_INCLUDE_DIR} REALPATH) + get_filename_component(ALEMBIC_ROOT_DIR ${real_include_dir} DIRECTORY) + add_test(script_alembic_import ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_alembic_import_test.py -- |