summaryrefslogtreecommitdiffstats
path: root/src/CMakeLists.txt
diff options
context:
space:
mode:
authorTai Vuong <tvuong@audiokinetic.com>2017-09-12 16:33:39 -0400
committerTai Vuong <tvuong@audiokinetic.com>2017-09-12 16:33:39 -0400
commitd69dc9732886074e9f400961b500e70d5c8305d7 (patch)
treeec5d4bb353814d442e3e4d84430a5343fee7b0c8 /src/CMakeLists.txt
parent9098015429bcc87a7b624ade16732848a9d90f67 (diff)
Pre-AudioWorkshop Demo
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r--src/CMakeLists.txt21
1 files changed, 18 insertions, 3 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index cbfe5dc..c0f6ca9 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -27,11 +27,19 @@ macro(SET_TARGET_GENSKEL TARGET_NAME API_DEF_NAME)
endmacro(SET_TARGET_GENSKEL)
+FIND_PACKAGE(PkgConfig REQUIRED)
+PKG_CHECK_MODULES(GLIB_PKG REQUIRED glib-2.0)
+
+# get_cmake_property(_variableNames VARIABLES)
+# foreach (_variableName ${_variableNames})
+# message(STATUS "${_variableName}=${${_variableName}}")
+# endforeach()
+
# Add target to project dependency list
-PROJECT_TARGET_ADD(audiohighlevel-afb)
+PROJECT_TARGET_ADD(audiohighlevel)
# Define project Targets
- ADD_LIBRARY(${TARGET_NAME} MODULE ahl-binding.c ahl-deviceenum.c)
+ ADD_LIBRARY(${TARGET_NAME} MODULE ahl-binding.c ahl-deviceenum.c ahl-config.c ahl-policy.c)
# Generate API-v2 hat from OpenAPI json definition
SET_TARGET_GENSKEL(${TARGET_NAME} ahl-apidef)
@@ -44,9 +52,16 @@ PROJECT_TARGET_ADD(audiohighlevel-afb)
OUTPUT_NAME ${TARGET_NAME}
)
+ # Define target includes
+ TARGET_INCLUDE_DIRECTORIES(${TARGET_NAME}
+ PUBLIC ${GLIB_PKG_INCLUDE_DIRS}
+ )
+
# Library dependencies (include updates automatically)
+ # Find package for GLIB does not seem to export
TARGET_LINK_LIBRARIES(${TARGET_NAME}
- afb-utilities
+ afb-utilities
+ ${GLIB_PKG_LIBRARIES}
${link_libraries}
)