diff --git a/daemon/AtraceDriver.h b/daemon/AtraceDriver.h index 2f16d40e..16e8d466 100644 --- a/daemon/AtraceDriver.h +++ b/daemon/AtraceDriver.h @@ -4,7 +4,7 @@ #define ATRACEDRIVER_H #include "SimpleDriver.h" -#include "mxml/mxml.h" +#include class FtraceDriver; diff --git a/daemon/CMakeLists.txt b/daemon/CMakeLists.txt index fc7b41a0..132b948c 100644 --- a/daemon/CMakeLists.txt +++ b/daemon/CMakeLists.txt @@ -86,7 +86,16 @@ INCLUDE(${CMAKE_CURRENT_SOURCE_DIR}/cmake/compiler-flags.cmake) ADD_SUBDIRECTORY(ipc/proto) # Find the external dependencies -FIND_PACKAGE(mxml CONFIG REQUIRED) +IF (ENABLE_VCPKG) + FIND_PACKAGE(mxml CONFIG REQUIRED) + SET(MXML_TARGET mxml) +ELSE() + INCLUDE(FindPkgConfig) + pkg_search_module(PKG_MXML REQUIRED IMPORTED_TARGET "mxml>=3") + SET(MXML_TARGET PkgConfig::PKG_MXML) + INCLUDE_DIRECTORIES(SYSTEM ${PKG_MXML_INCLUDE_DIRS} ${PKG_MXML_INCLUDEDIR}) +ENDIF() + FIND_PACKAGE(Threads REQUIRED) SET(Boost_USE_MULTITHREADED ON) FIND_PACKAGE(Boost 1.75 REQUIRED COMPONENTS @@ -687,7 +696,7 @@ TARGET_LINK_LIBRARIES(gatord PRIVATE Threads::Threads PRIVATE atomic PRIVATE device - PRIVATE mxml + PRIVATE ${MXML_TARGET} PRIVATE Boost::boost PRIVATE Boost::filesystem PRIVATE Boost::regex @@ -750,7 +759,7 @@ ENDIF() IF(EXISTS ${CLANG_TIDY}) # ## CMAKE_xxx_CLANG_TIDY need to be before the ADD_EXECUTABLE - OPTION(ENABLE_CLANG_TIDY_DURING_BUILD "Compile and tidy at the same time" ON) + OPTION(ENABLE_CLANG_TIDY_DURING_BUILD "Compile and tidy at the same time" OFF) IF(ENABLE_CLANG_TIDY_DURING_BUILD) SET(CMAKE_C_CLANG_TIDY ) diff --git a/daemon/CapturedXML.cpp b/daemon/CapturedXML.cpp index ee4eca5d..299ab09f 100644 --- a/daemon/CapturedXML.cpp +++ b/daemon/CapturedXML.cpp @@ -21,7 +21,7 @@ #include #include -#include +#include /* Basic target OS detection */ #undef GATOR_TARGET_OS diff --git a/daemon/ConfigurationXMLParser.h b/daemon/ConfigurationXMLParser.h index 86b378ef..687dd3df 100644 --- a/daemon/ConfigurationXMLParser.h +++ b/daemon/ConfigurationXMLParser.h @@ -6,7 +6,7 @@ #include "Configuration.h" #include "Logging.h" #include "OlyUtility.h" -#include "mxml/mxml.h" +#include #include #include diff --git a/daemon/CounterXML.cpp b/daemon/CounterXML.cpp index d8021ff0..26ba99b7 100644 --- a/daemon/CounterXML.cpp +++ b/daemon/CounterXML.cpp @@ -9,7 +9,7 @@ #include "SessionData.h" #include "lib/String.h" #include "logging/global_log.h" -#include "mxml/mxml.h" +#include #include "xml/MxmlUtils.h" #include "xml/PmuXML.h" diff --git a/daemon/Driver.h b/daemon/Driver.h index 615e085c..50de6595 100644 --- a/daemon/Driver.h +++ b/daemon/Driver.h @@ -5,7 +5,7 @@ #include "CapturedSpe.h" #include "Constant.h" -#include "mxml/mxml.h" +#include #include #include diff --git a/daemon/SessionData.h b/daemon/SessionData.h index 5d94524a..11c8a9a6 100644 --- a/daemon/SessionData.h +++ b/daemon/SessionData.h @@ -11,7 +11,7 @@ #include "Time.h" #include "lib/SharedMemory.h" #include "linux/smmu_identifier.h" -#include "mxml/mxml.h" +#include #include #include diff --git a/daemon/SessionXML.h b/daemon/SessionXML.h index 4d95ce91..7df9f144 100644 --- a/daemon/SessionXML.h +++ b/daemon/SessionXML.h @@ -3,7 +3,7 @@ #ifndef SESSION_XML_H #define SESSION_XML_H -#include "mxml/mxml.h" +#include struct ImageLinkList; diff --git a/daemon/TtraceDriver.h b/daemon/TtraceDriver.h index 248c708e..f6d20f1d 100644 --- a/daemon/TtraceDriver.h +++ b/daemon/TtraceDriver.h @@ -4,7 +4,7 @@ #define TTRACEDRIVER_H #include "SimpleDriver.h" -#include "mxml/mxml.h" +#include class FtraceDriver; diff --git a/daemon/android/ThermalDriver.cpp b/daemon/android/ThermalDriver.cpp index a57ecd0c..b4787fa5 100644 --- a/daemon/android/ThermalDriver.cpp +++ b/daemon/android/ThermalDriver.cpp @@ -5,7 +5,7 @@ #include "IBlockCounterFrameBuilder.h" #include "Logging.h" #include "SessionData.h" -#include "mxml/mxml.h" +#include #include #include diff --git a/daemon/ipc/proto/CMakeLists.txt b/daemon/ipc/proto/CMakeLists.txt index 5f1c1586..83a60c36 100644 --- a/daemon/ipc/proto/CMakeLists.txt +++ b/daemon/ipc/proto/CMakeLists.txt @@ -1,6 +1,6 @@ # Copyright (C) 2022 by Arm Limited. All rights reserved. -find_package(Protobuf REQUIRED CONFIG) +find_package(Protobuf REQUIRED) set(GENERATED_DIR ${CMAKE_CURRENT_LIST_DIR}/generated) file(MAKE_DIRECTORY ${GENERATED_DIR}) diff --git a/daemon/mali_userspace/MaliGPUClockPolledDriver.h b/daemon/mali_userspace/MaliGPUClockPolledDriver.h index 7dca407b..7b3e88d0 100644 --- a/daemon/mali_userspace/MaliGPUClockPolledDriver.h +++ b/daemon/mali_userspace/MaliGPUClockPolledDriver.h @@ -7,7 +7,7 @@ #include "Logging.h" #include "MaliGPUClockPolledDriverCounter.h" #include "PolledDriver.h" -#include "mxml/mxml.h" +#include #include #include diff --git a/daemon/xml/EventsXML.h b/daemon/xml/EventsXML.h index 18739504..6704f06d 100644 --- a/daemon/xml/EventsXML.h +++ b/daemon/xml/EventsXML.h @@ -6,7 +6,7 @@ #include "EventCode.h" #include "lib/Span.h" #include "linux/perf/PerfEventGroupIdentifier.h" -#include "mxml/mxml.h" +#include #include #include diff --git a/daemon/xml/MxmlUtils.h b/daemon/xml/MxmlUtils.h index caf721b5..84c34056 100644 --- a/daemon/xml/MxmlUtils.h +++ b/daemon/xml/MxmlUtils.h @@ -3,7 +3,7 @@ #ifndef MXML_UTILS_H #define MXML_UTILS_H -#include "mxml/mxml.h" +#include #include #include diff --git a/daemon/xml/PmuXMLParser.cpp b/daemon/xml/PmuXMLParser.cpp index 436ad9cf..6f2f7687 100644 --- a/daemon/xml/PmuXMLParser.cpp +++ b/daemon/xml/PmuXMLParser.cpp @@ -9,7 +9,7 @@ #include "lib/FsEntry.h" #include "lib/String.h" #include "lib/Utils.h" -#include "mxml/mxml.h" +#include #include #include diff --git a/vcpkg_registry/ports/mxml/3.0.0/CMakeLists.txt b/vcpkg_registry/ports/mxml/3.0.0/CMakeLists.txt index 9ff5e6c1..fac742ba 100644 --- a/vcpkg_registry/ports/mxml/3.0.0/CMakeLists.txt +++ b/vcpkg_registry/ports/mxml/3.0.0/CMakeLists.txt @@ -41,7 +41,7 @@ set_target_properties(${PROJECT_NAME} PROPERTIES PUBLIC_HEADER ${CMAKE_SOURCE_DI install( TARGETS ${PROJECT_NAME} EXPORT ${PROJECT_NAME}Export - PUBLIC_HEADER DESTINATION include/${PROJECT_NAME} + PUBLIC_HEADER DESTINATION include ) # Generate and install package cmake file, so it can be found with