aboutsummaryrefslogtreecommitdiffstats
path: root/cmake/cmake.d
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/cmake.d')
-rw-r--r--cmake/cmake.d/03-macros.cmake9
1 files changed, 9 insertions, 0 deletions
diff --git a/cmake/cmake.d/03-macros.cmake b/cmake/cmake.d/03-macros.cmake
index 6e223b2..88d6dd4 100644
--- a/cmake/cmake.d/03-macros.cmake
+++ b/cmake/cmake.d/03-macros.cmake
@@ -121,6 +121,15 @@ macro(configure_files_in_dir dir)
endforeach()
endmacro(configure_files_in_dir)
+macro(add_required_module PKG_CONFIG)
+ string(REGEX REPLACE "[<>]?=.*$" "" XPREFIX ${PKG_CONFIG})
+ PKG_CHECK_MODULES(${XPREFIX} REQUIRED ${PKG_CONFIG})
+
+ INCLUDE_DIRECTORIES(${${XPREFIX}_INCLUDE_DIRS})
+ list(APPEND link_libraries ${${XPREFIX}_LDFLAGS})
+ add_compile_options (${${XPREFIX}_CFLAGS})
+endmacro(add_required_module)
+
# Create custom target dedicated for HTML5 and DATA AGL target type
macro(add_input_files INPUT_FILES)
set(XML_LIST ${INPUT_FILES})