← Back to team overview

ayatana-commits team mailing list archive

[Merge] lp:~ballogy/libindicate-qt/make-examples-and-tests-optional into lp:libindicate-qt

 

György Balló has proposed merging lp:~ballogy/libindicate-qt/make-examples-and-tests-optional into lp:libindicate-qt.

Requested reviews:
  Aurélien Gâteau (agateau)

For more details, see:
https://code.launchpad.net/~ballogy/libindicate-qt/make-examples-and-tests-optional/+merge/82829

This change makes it possible to disable building examples and tests with '-DBUILD_EXAMPLES=OFF' and '-DBUILD_TESTS=OFF' switches.
-- 
https://code.launchpad.net/~ballogy/libindicate-qt/make-examples-and-tests-optional/+merge/82829
Your team ayatana-commits is subscribed to branch lp:libindicate-qt.
=== modified file 'CMakeLists.txt'
--- CMakeLists.txt	2010-03-08 09:02:19 +0000
+++ CMakeLists.txt	2011-11-20 20:25:26 +0000
@@ -36,8 +36,16 @@
     DESTINATION lib${LIB_SUFFIX}/pkgconfig)
 
 add_subdirectory(src)
-add_subdirectory(examples)
-add_subdirectory(tests)
+
+option( BUILD_EXAMPLES "build examples" ON )
+if (BUILD_EXAMPLES)
+    add_subdirectory(examples)
+endif (BUILD_EXAMPLES)
+
+option( BUILD_TESTS "build tests" ON )
+if (BUILD_TESTS)
+    add_subdirectory(tests)
+endif (BUILD_TESTS)
 
 # Packaging
 set(ARCHIVE_NAME libindicate-qt-${indicate_qt_VERSION})


Follow ups