aboutsummaryrefslogtreecommitdiffstats
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorHugo Parente Lima <hugo.pl@gmail.com>2010-12-14 18:23:33 -0200
committerHugo Parente Lima <hugo.pl@gmail.com>2012-03-08 16:47:58 -0300
commitd4318366f11c910edc9d305d1c9db3924677bf4d (patch)
tree7929552ec13ba7f64ecda68d7713e5efec5c1bd9 /CMakeLists.txt
parent42d887ff86c9eb56a721d7cb979c4242f4f4953e (diff)
Fix bug#491 - "pyside doesn't respect BUILD_TESTS"
Reviewer: Lauro Moura <lauro.neto@openbossa.org> Marcelo Lira <marcelo.lira@openbossa.org>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt8
1 files changed, 5 insertions, 3 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 5a6f6f583..db2bb3aea 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -20,6 +20,7 @@ if(USE_XVFB)
endif()
endif()
+option(BUILD_TESTS "Build tests." TRUE)
option(ENABLE_VERSION_SUFFIX "Used to use current version in suffix to generated files. This is used to allow multiples versions installed simultaneous." FALSE)
set(LIB_SUFFIX "" CACHE STRING "Define suffix of directory name (32/64)" )
set(LIB_INSTALL_DIR "${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX}" CACHE PATH "The subdirectory relative to the install prefix where libraries will be installed (default is /lib${LIB_SUFFIX})" FORCE)
@@ -147,15 +148,16 @@ endif()
set(GENERATOR_EXTRA_FLAGS --generatorSet=shiboken --enable-parent-ctor-heuristic --enable-pyside-extensions --enable-return-value-heuristic)
-enable_testing()
-
add_subdirectory(libpyside)
if(QT_QTUITOOLS_FOUND AND QT_QTDESIGNER_FOUND)
add_subdirectory(plugins)
endif()
# project directories
add_subdirectory(PySide)
-add_subdirectory(tests)
+if (BUILD_TESTS)
+ enable_testing()
+ add_subdirectory(tests)
+endif ()
find_program(DOT_EXEC dot)
if (QT_SRC_DIR AND DOT_EXEC)