CMake: Remove gtk dep on macOS

We only need gio now
This commit is contained in:
TellowKrinkle 2021-10-22 21:02:31 -05:00 committed by tellowkrinkle
parent 0d40661b33
commit 2245315b60
2 changed files with 9 additions and 1 deletions

View File

@ -163,7 +163,9 @@ else()
find_package(X11 REQUIRED)
make_imported_target_if_missing(X11::X11 X11)
endif()
if(UNIX)
if(APPLE)
check_lib(GIO gio-2.0 gio/gio.h)
elseif(UNIX)
# Most plugins (if not all) and PCSX2 core need gtk2, so set the required flags
if (GTK2_API)
find_package(GTK2 REQUIRED gtk)

View File

@ -1468,6 +1468,12 @@ if(WIN32)
opengl32.lib
comsuppw.lib
)
elseif(APPLE)
target_link_libraries(PCSX2_FLAGS INTERFACE
PkgConfig::GIO
PCAP::PCAP
LibXml2::LibXml2
)
else()
target_link_libraries(PCSX2_FLAGS INTERFACE
GTK::gtk