2014-07-20 23:48:40 +08:00
|
|
|
#
|
|
|
|
# Try to find Ogg/Vorbis libraries and include paths.
|
|
|
|
# Once done this will define
|
|
|
|
#
|
|
|
|
# VORBIS_FOUND
|
|
|
|
# VORBIS_INCLUDE_DIRS
|
|
|
|
# VORBIS_LIBRARIES
|
|
|
|
#
|
|
|
|
|
|
|
|
find_path(OGG_INCLUDE_DIR ogg/ogg.h)
|
|
|
|
find_path(VORBIS_INCLUDE_DIR vorbis/vorbisfile.h)
|
|
|
|
|
|
|
|
find_library(OGG_LIBRARY NAMES ogg)
|
|
|
|
find_library(VORBIS_LIBRARY NAMES vorbis)
|
2018-01-25 07:29:19 +08:00
|
|
|
if (NOT SFML_OS_IOS)
|
|
|
|
find_library(VORBISFILE_LIBRARY NAMES vorbisfile)
|
|
|
|
find_library(VORBISENC_LIBRARY NAMES vorbisenc)
|
|
|
|
set(VORBIS_LIBRARIES ${VORBISENC_LIBRARY} ${VORBISFILE_LIBRARY} ${VORBIS_LIBRARY} ${OGG_LIBRARY})
|
|
|
|
else()
|
|
|
|
set(VORBIS_LIBRARIES ${VORBIS_LIBRARY} ${OGG_LIBRARY})
|
|
|
|
endif()
|
2014-07-20 23:48:40 +08:00
|
|
|
|
|
|
|
include(FindPackageHandleStandardArgs)
|
2018-01-25 07:29:19 +08:00
|
|
|
|
|
|
|
find_package_handle_standard_args(VORBIS DEFAULT_MSG VORBIS_LIBRARIES VORBIS_INCLUDE_DIR OGG_INCLUDE_DIR)
|
2014-07-20 23:48:40 +08:00
|
|
|
|
|
|
|
set(VORBIS_INCLUDE_DIRS ${OGG_INCLUDE_DIR} ${VORBIS_INCLUDE_DIR})
|
2015-02-25 17:46:37 +08:00
|
|
|
|
|
|
|
mark_as_advanced(OGG_INCLUDE_DIR VORBIS_INCLUDE_DIR OGG_LIBRARY VORBIS_LIBRARY VORBISFILE_LIBRARY VORBISENC_LIBRARY)
|