Aegisub/cmake/Findass.cmake

21 lines
475 B
CMake
Raw Normal View History

2019-09-10 06:15:40 +02:00
find_package(PkgConfig QUIET)
pkg_check_modules(PC_ass QUIET libass)
find_path(ass_INCLUDE_DIRS
NAMES ass/ass.h ass/ass_types.h
2019-09-10 06:15:40 +02:00
PATH_SUFFIXES libass
HINTS ${PC_ass_INCLUDE_DIRS}
)
find_library(ass_LIBRARIES
NAMES ass
2019-09-10 06:15:40 +02:00
HINTS ${PC_ass_LIBRARY_DIRS}
)
set(ass_VERSION ${PC_ass_VERSION})
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(ass
FOUND_VAR ass_FOUND
REQUIRED_VARS
ass_LIBRARIES
ass_INCLUDE_DIRS
VERSION_VAR ass_VERSION
2019-09-10 06:15:40 +02:00
)