Make bmcweb use yocto dependency management
bmcweb will still build with submodules if the right flags are sent
Change-Id: I227e011043a2242db29288b38b9f6069939635d4
Signed-off-by: Ed Tanous <ed.tanous@intel.com>
diff --git a/CMakeLists.txt b/CMakeLists.txt
index db863bb..27c4ce9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -6,7 +6,7 @@
message(CMAKE_MODULE_PATH=${CMAKE_MODULE_PATH})
option(BUILD_STATIC_LIBS "Built static libraries" ON)
-
+option(YOCTO_DEPENDENCIES "Use YOCTO depedencies system" OFF)
option(HUNTER_ENABLED "Enable hunter package pulling" OFF)
include("cmake/HunterGate.cmake")
@@ -78,8 +78,11 @@
include_directories(${ZLIB_INCLUDE_DIRS})
#tinyxml2
-add_subdirectory(tinyxml2)
-
+if(NOT ${YOCTO_DEPENDENCIES})
+ add_subdirectory(tinyxml2)
+else()
+ find_package(tinyxml2 REQUIRED)
+endif()
# PAM
option(WEBSERVER_ENABLE_PAM "enable pam authentication" ON)
if ("${WEBSERVER_ENABLE_PAM}")
@@ -91,8 +94,11 @@
# Boost-dbus
set(BOOST_DBUS_BUILD_UT ${BMCWEB_BUILD_UT})
-add_subdirectory(boost-dbus)
-
+if(NOT ${YOCTO_DEPENDENCIES})
+ add_subdirectory(boost-dbus)
+else()
+ find_package(boost-dbus REQUIRED)
+endif()
set(WEBSERVER_MAIN src/webserver_main.cpp)
# the webassets file has a non-ideal beahvior, where it loads binary data into a std::string
diff --git a/boost-dbus b/boost-dbus
index f95fe4c..e7dae9c 160000
--- a/boost-dbus
+++ b/boost-dbus
@@ -1 +1 @@
-Subproject commit f95fe4cc8caaa50c344594b96211655d5dba09a3
+Subproject commit e7dae9ce93226e6a7bf3d9101f457d29afac40c2