aboutsummaryrefslogtreecommitdiff
path: root/src/CMakeLists.txt
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2014-09-05 14:47:02 -0500
committerTed Gould <ted@gould.cx>2014-09-05 14:47:02 -0500
commitaa563d76b9cf4bf42f15ebef0c660ec9a5854ef6 (patch)
tree200b5ccce5d03c85e64197aac162bbd1f682a41e /src/CMakeLists.txt
parent8e0ddac8a13c77863d21b5de00c2fc8b796b9c99 (diff)
parent415f18f56667eea5c650d209b9ac1464a70ef7f5 (diff)
downloadayatana-indicator-display-aa563d76b9cf4bf42f15ebef0c660ec9a5854ef6.tar.gz
ayatana-indicator-display-aa563d76b9cf4bf42f15ebef0c660ec9a5854ef6.tar.bz2
ayatana-indicator-display-aa563d76b9cf4bf42f15ebef0c660ec9a5854ef6.zip
Add a rotation lock indicator
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r--src/CMakeLists.txt29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
new file mode 100644
index 0000000..982aa49
--- /dev/null
+++ b/src/CMakeLists.txt
@@ -0,0 +1,29 @@
+set (SERVICE_LIB "indicatordisplayservice")
+set (SERVICE_EXEC "indicator-display-service")
+
+add_definitions (-DG_LOG_DOMAIN="${CMAKE_PROJECT_NAME}")
+
+# handwritten source code...
+set (SERVICE_LIB_HANDWRITTEN_SOURCES
+ exporter.cpp
+ rotation-lock.cpp)
+
+add_library (${SERVICE_LIB} STATIC
+ ${SERVICE_LIB_HANDWRITTEN_SOURCES})
+
+# add the bin dir to the include path so that
+# the compiler can find the generated header files
+include_directories (${CMAKE_CURRENT_BINARY_DIR})
+
+link_directories (${SERVICE_DEPS_LIBRARY_DIRS})
+
+set (SERVICE_EXEC_HANDWRITTEN_SOURCES main.cpp)
+add_executable (${SERVICE_EXEC} ${SERVICE_EXEC_HANDWRITTEN_SOURCES})
+target_link_libraries (${SERVICE_EXEC} ${SERVICE_LIB} ${SERVICE_DEPS_LIBRARIES} ${GCOV_LIBS})
+install (TARGETS ${SERVICE_EXEC} RUNTIME DESTINATION ${CMAKE_INSTALL_FULL_PKGLIBEXECDIR})
+
+# add warnings/coverage info on handwritten files
+# but not the generated ones...
+set_property (SOURCE ${SERVICE_LIB_HANDWRITTEN_SOURCES} ${SERVICE_EXEC_HANDWRITTEN_SOURCES}
+ APPEND_STRING PROPERTY COMPILE_FLAGS " -std=c++11 -g ${CXX_WARNING_ARGS} ${GCOV_FLAGS}")
+