You've already forked libopenshot
mirror of
https://github.com/OpenShot/libopenshot.git
synced 2026-03-02 08:53:52 -08:00
* Search for libresvg.so in RESVGDIR also This means that RESVGDIR can be pointed to the `target/release` dir where resvg was built, and both `libresvg.so` and `include/resvg.h` will be found. * ReSVG: Fix up discovery module `find_package_handle_standard_args` is supposed to set the `_FOUND` variable automatically (as the comment right above it says), as well as handling things like REQUIRED, QUIETLY, etc. It should always be run at the end of a module, for this reason. This change removes the conditionals around the call, lets it handle what it's meant to handle, and defines a custom failure message for discovery that replaces the one in `src/CMakeList.txt`. In addition, the `REQRUIRED` is removed from `tests/CMakeLists.txt`, since it's _supposed_ to mark the module as required (which ReSVG is not), and was only working due to the aforementioned improper conditional wrapping of the module's cleanup. * FindRESVG.cmake does not set RESVG_DEFINITIONS Remove the comment that claims it does.
29 lines
1.1 KiB
CMake
29 lines
1.1 KiB
CMake
# - Try to find RESVG
|
|
# Once done this will define
|
|
# RESVG_FOUND - System has RESVG
|
|
# RESVG_INCLUDE_DIRS - The RESVG include directories
|
|
# RESVG_LIBRARIES - The libraries needed to use RESVG
|
|
find_path ( RESVG_INCLUDE_DIR ResvgQt.h
|
|
PATHS ${RESVGDIR}/include/resvg
|
|
$ENV{RESVGDIR}/include/resvg
|
|
$ENV{RESVGDIR}/include
|
|
/usr/include/resvg
|
|
/usr/include
|
|
/usr/local/include/resvg
|
|
/usr/local/include )
|
|
|
|
find_library ( RESVG_LIBRARY NAMES resvg
|
|
PATHS /usr/lib
|
|
/usr/local/lib
|
|
$ENV{RESVGDIR}
|
|
$ENV{RESVGDIR}/lib )
|
|
|
|
set ( RESVG_LIBRARIES ${RESVG_LIBRARY} )
|
|
set ( RESVG_INCLUDE_DIRS ${RESVG_INCLUDE_DIR} )
|
|
|
|
include ( FindPackageHandleStandardArgs )
|
|
# handle the QUIETLY and REQUIRED arguments and set RESVG_FOUND to TRUE
|
|
# if all listed variables are TRUE
|
|
find_package_handle_standard_args ( RESVG "Could NOT find RESVG, using Qt SVG parsing instead" RESVG_LIBRARY RESVG_INCLUDE_DIR )
|
|
mark_as_advanced( RESVG_LIBRARY RESVG_INCLUDE_DIR )
|