mirror of
https://github.com/ZDoom/fluidsynth.git
synced 2024-12-11 13:21:03 +00:00
fixes and simplifications
* FluidSynthConfigVersion.cmake is created with ${VERSION} instead of ${LIB_VERSION_INFO} * FluidSynthConfig.cmake.in simplified: it doesn't need to include the version file. * Simplified BUILD_INTERFACE generator expression as suggested
This commit is contained in:
parent
cf5fbac9af
commit
64a7787e90
3 changed files with 8 additions and 7 deletions
|
@ -869,8 +869,8 @@ export(EXPORT FluidSynthTargets
|
|||
include(CMakePackageConfigHelpers)
|
||||
write_basic_package_version_file(
|
||||
FluidSynthConfigVersion.cmake
|
||||
VERSION ${LIB_VERSION_INFO}
|
||||
COMPATIBILITY SameMajorVersion
|
||||
VERSION ${VERSION}
|
||||
COMPATIBILITY SameMinorVersion
|
||||
)
|
||||
|
||||
configure_file(FluidSynthConfig.cmake.in FluidSynthConfig.cmake @ONLY)
|
||||
|
|
|
@ -6,6 +6,5 @@
|
|||
# define variables for configuration options:
|
||||
# set(network-enabled @enable-network@)
|
||||
|
||||
# finally, include the targets/version files
|
||||
# finally, include the targets file
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FluidSynthTargets.cmake")
|
||||
include("${CMAKE_CURRENT_LIST_DIR}/FluidSynthConfigVersion.cmake")
|
||||
|
|
|
@ -348,7 +348,7 @@ else ( MACOSX_FRAMEWORK )
|
|||
)
|
||||
endif ( MACOSX_FRAMEWORK )
|
||||
|
||||
target_link_libraries ( libfluidsynth
|
||||
target_link_libraries ( libfluidsynth PRIVATE
|
||||
${GLIB_LIBRARIES}
|
||||
${GMODULE_LIBRARIES}
|
||||
${LASH_LIBRARIES}
|
||||
|
@ -391,10 +391,12 @@ if ( FLUID_CPPFLAGS )
|
|||
PROPERTIES COMPILE_FLAGS ${FLUID_CPPFLAGS} )
|
||||
endif ( FLUID_CPPFLAGS )
|
||||
|
||||
target_link_libraries ( fluidsynth
|
||||
target_link_libraries ( fluidsynth PRIVATE
|
||||
libfluidsynth
|
||||
${SYSTEMD_LIBRARIES}
|
||||
${FLUID_LIBS}
|
||||
${GLIB_LIBRARIES} # because g_file_test()
|
||||
${SDL2_LIBRARIES} # because SDL_Init() etc.
|
||||
)
|
||||
|
||||
if ( MACOSX_FRAMEWORK )
|
||||
|
@ -420,7 +422,7 @@ endif ( MACOSX_FRAMEWORK )
|
|||
# build_interface: for the libfluidsynth target when imported from the build directory.
|
||||
# install_interface: for the target when imported from the installed directory.
|
||||
target_include_directories(libfluidsynth PUBLIC
|
||||
"$<BUILD_INTERFACE:${CMAKE_SOURCE_DIR}/include/;${CMAKE_SOURCE_DIR}/include/fluidsynth/;${CMAKE_BINARY_DIR}/include/;${CMAKE_BINARY_DIR}/include/fluidsynth/>"
|
||||
"$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/include/;${PROJECT_BINARY_DIR}/include/>"
|
||||
"$<INSTALL_INTERFACE:${INCLUDE_INSTALL_DIR}>"
|
||||
)
|
||||
|
||||
|
|
Loading…
Reference in a new issue