Detect log4cxx in top-level CMakeLists
authorBrendan Shanks <bshanks@audiovox.com>
Fri, 21 Mar 2014 02:33:59 +0000 (19:33 -0700)
committerJustin Dickow <jjdickow@gmail.com>
Fri, 21 Mar 2014 02:39:19 +0000 (22:39 -0400)
SDL_Core/CMakeLists.txt

index 1007e06..a604099 100644 (file)
@@ -113,6 +113,17 @@ pkg_check_modules(GLIB2 REQUIRED glib-2.0)
 add_definitions(${GLIB2_CFLAGS})
 endif()
 
+# Find log4cxx
+if(UNIX)
+    find_package(PkgConfig)
+    pkg_check_modules(LOG4CXX REQUIRED liblog4cxx)
+    include_directories(${LOG4CXX_INCLUDE_DIRS})
+    link_directories(${LOG4CXX_LIBRARY_DIRS})
+elseif(WIN32)
+#   Add finding log4cxx here
+endif(UNIX)
+
+
 # --- Interface generator
 
 find_package(PythonInterp)