mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-22 06:05:38 +00:00
Fixed an annoying CMake issue that also broke the macOS build.
This commit is contained in:
parent
b8de48ae98
commit
cc93ca4630
|
@ -11,32 +11,34 @@
|
||||||
|
|
||||||
include(FindPkgMacros)
|
include(FindPkgMacros)
|
||||||
|
|
||||||
if (NOT WIN32)
|
if(NOT WIN32)
|
||||||
find_package(PkgConfig)
|
find_package(PkgConfig)
|
||||||
pkg_check_modules(PUGIXML REQUIRED pugixml>=1.09)
|
pkg_check_modules(PUGIXML REQUIRED pugixml>=1.09)
|
||||||
endif (NOT WIN32)
|
# Set the full path to the library instead of just 'pugixml'.
|
||||||
|
set(PUGIXML_LIBRARIES ${PUGIXML_LINK_LIBRARIES})
|
||||||
|
endif(NOT WIN32)
|
||||||
|
|
||||||
if (WIN32)
|
if(WIN32)
|
||||||
find_path(PUGIXML_INCLUDE_DIR pugixml.hpp)
|
find_path(PUGIXML_INCLUDE_DIR pugixml.hpp)
|
||||||
|
|
||||||
# Support the REQUIRED and QUIET arguments, and set PUGIXML_FOUND if found.
|
# Support the REQUIRED and QUIET arguments, and set PUGIXML_FOUND if found.
|
||||||
include (FindPackageHandleStandardArgs)
|
include(FindPackageHandleStandardArgs)
|
||||||
|
|
||||||
find_package_handle_standard_args(PUGIXML DEFAULT_MSG PUGIXML_INCLUDE_DIR)
|
find_package_handle_standard_args(PUGIXML DEFAULT_MSG PUGIXML_INCLUDE_DIR)
|
||||||
|
|
||||||
if (NOT PUGIXML_INCLUDE_DIR)
|
if(NOT PUGIXML_INCLUDE_DIR)
|
||||||
message(FATAL_ERROR "PUGIXML include files not found!")
|
message(FATAL_ERROR "PUGIXML include files not found!")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
endif (WIN32)
|
endif(WIN32)
|
||||||
|
|
||||||
find_library(PUGIXML_LIBRARY pugixml)
|
find_library(PUGIXML_LIBRARY pugixml)
|
||||||
|
|
||||||
if (NOT PUGIXML_LIBRARY)
|
if(NOT PUGIXML_LIBRARY)
|
||||||
message(FATAL_ERROR "libpugixml library not found!")
|
message(FATAL_ERROR "libpugixml library not found!")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
# Support the REQUIRED and QUIET arguments, and set PUGIXML_FOUND if found.
|
# Support the REQUIRED and QUIET arguments, and set PUGIXML_FOUND if found.
|
||||||
include (FindPackageHandleStandardArgs)
|
include(FindPackageHandleStandardArgs)
|
||||||
|
|
||||||
find_package_handle_standard_args(pugixml DEFAULT_MSG PUGIXML_LIBRARY)
|
find_package_handle_standard_args(Pugixml DEFAULT_MSG PUGIXML_LIBRARY)
|
||||||
|
|
|
@ -64,21 +64,12 @@ if(NOT WIN32)
|
||||||
find_package(CURL REQUIRED)
|
find_package(CURL REQUIRED)
|
||||||
find_package(FreeImage REQUIRED)
|
find_package(FreeImage REQUIRED)
|
||||||
find_package(Freetype REQUIRED)
|
find_package(Freetype REQUIRED)
|
||||||
|
find_package(Pugixml REQUIRED)
|
||||||
find_package(RapidJSON REQUIRED)
|
find_package(RapidJSON REQUIRED)
|
||||||
find_package(SDL2 REQUIRED)
|
find_package(SDL2 REQUIRED)
|
||||||
find_package(VLC REQUIRED)
|
find_package(VLC REQUIRED)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(APPLE)
|
|
||||||
# For some strange reason, macOS complains about an uppercase 'P' in Pugixml.
|
|
||||||
# FreeBSD, NetBSD and OpenBSD also complain about this, but applying the same rule to
|
|
||||||
# these OSs lead to linking issues for some reason, so we'll have to live with those
|
|
||||||
# warnings for now.
|
|
||||||
find_package(pugixml REQUIRED)
|
|
||||||
elseif(UNIX)
|
|
||||||
find_package(Pugixml REQUIRED)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# Add libCEC support.
|
# Add libCEC support.
|
||||||
if(CEC)
|
if(CEC)
|
||||||
find_package(libCEC REQUIRED)
|
find_package(libCEC REQUIRED)
|
||||||
|
|
Loading…
Reference in a new issue