fix broken support for Ubuntu-20.04LTS

This commit is contained in:
F. Duncanh
2024-11-22 01:39:43 -05:00
parent bc715a411e
commit 078d95bb79
2 changed files with 23 additions and 9 deletions

View File

@@ -82,22 +82,28 @@ else()
endif()
# libplist
pkg_search_module(PLIST REQUIRED libplist-2.0)
if ( PLIST_FOUND )
message( STATUS "found libplist-${PLIST_VERSION}" )
endif()
if( APPLE )
# use static linking
pkg_search_module(PLIST REQUIRED libplist-2.0)
find_library( LIBPLIST libplist-2.0.a REQUIRED )
message( STATUS "(Static linking) LIBPLIST " ${LIBPLIST} )
target_link_libraries ( airplay ${LIBPLIST} )
elseif( WIN32)
pkg_search_module(PLIST REQUIRED libplist-2.0)
find_library( LIBPLIST ${PLIST_LIBRARIES} PATH ${PLIST_LIBDIR} )
target_link_libraries ( airplay ${LIBPLIST} )
else ()
pkg_search_module(PLIST libplist>=2.0)
if(NOT PLIST_FOUND)
pkg_search_module(PLIST REQUIRED libplist-2.0)
endif()
find_library( LIBPLIST ${PLIST_LIBRARIES} PATH ${PLIST_LIBDIR} )
target_link_libraries ( airplay PUBLIC ${LIBPLIST} )
endif()
if ( PLIST_FOUND )
message( STATUS "found libplist-${PLIST_VERSION}" )
endif()
target_include_directories( airplay PRIVATE ${PLIST_INCLUDE_DIRS} )
#libcrypto