summaryrefslogtreecommitdiffstats
path: root/cmake-e/cmake/Modules/FindEdje.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake-e/cmake/Modules/FindEdje.cmake')
-rw-r--r--cmake-e/cmake/Modules/FindEdje.cmake28
1 files changed, 28 insertions, 0 deletions
diff --git a/cmake-e/cmake/Modules/FindEdje.cmake b/cmake-e/cmake/Modules/FindEdje.cmake
new file mode 100644
index 0000000..927b31d
--- /dev/null
+++ b/cmake-e/cmake/Modules/FindEdje.cmake
@@ -0,0 +1,28 @@
+# - Try to find edje
+# Once done this will define
+# EDJE_FOUND - System has edje
+# EDJE_INCLUDE_DIRS - The edje include directories
+# EDJE_LIBRARIES - The libraries needed to use edje
+# EDJE_DEFINITIONS - Compiler switches required for using edje
+
+find_package(PkgConfig)
+pkg_check_modules(PC_LIBEDJE QUIET edje)
+set(EDJE_DEFINITIONS ${PC_LIBEDJE_CFLAGS_OTHER})
+
+find_path(EDJE_INCLUDE_DIR Edje.h
+ HINTS ${PC_LIBEDJE_INCLUDEDIR} ${PC_LIBEDJE_INCLUDE_DIRS}
+ PATH_SUFFIXES edje )
+
+find_library(EDJE_LIBRARY NAMES edje
+ HINTS ${PC_LIBEDJE_LIBDIR} ${PC_LIBEDJE_LIBRARY_DIRS} )
+
+set(EDJE_LIBRARIES ${EDJE_LIBRARY} )
+set(EDJE_INCLUDE_DIRS ${EDJE_INCLUDE_DIR} )
+
+include(FindPackageHandleStandardArgs)
+# handle the QUIETLY and REQUIRED arguments and set EDJE_FOUND to TRUE
+# if all listed variables are TRUE
+find_package_handle_standard_args(edje DEFAULT_MSG
+ EDJE_LIBRARY EDJE_INCLUDE_DIR)
+
+mark_as_advanced(EDJE_INCLUDE_DIR EDJE_LIBRARY )