Fix #33518: Jack sync doesn't work in 2.64, 2.64 or 2.65 stable versions

Added new build option WITH_JACK_DYNLOAD for CMake and
WITH_BF_JACK_DYNLOAD for SCons, which means there'll be
no build-time linking against libjack and getting symbols
from libjack will happen runtime using dlopen and dlsym
tricks.

Alternative would be to use weak linking, but it'll require
having wrapper for preloading libjack.

This new options are disabled by default and they only
intended to be used on linux. Other platforms shall not
be using this and there shall be no functional changes
on non-linux platforms at all.
This commit is contained in:
Sergey Sharybin
2013-03-27 07:19:54 +00:00
parent 91b2b970ad
commit 31eee77a45
19 changed files with 380 additions and 79 deletions

View File

@@ -228,7 +228,7 @@ macro(SETUP_LIBDIRS)
if(WITH_OPENAL)
link_directories(${OPENAL_LIBPATH})
endif()
if(WITH_JACK)
if(WITH_JACK AND NOT WITH_JACK_DYNLOAD)
link_directories(${JACK_LIBPATH})
endif()
if(WITH_CODEC_SNDFILE)
@@ -293,7 +293,7 @@ macro(setup_liblinks
if(WITH_FFTW3)
target_link_libraries(${target} ${FFTW3_LIBRARIES})
endif()
if(WITH_JACK)
if(WITH_JACK AND NOT WITH_JACK_DYNLOAD)
target_link_libraries(${target} ${JACK_LIBRARIES})
endif()
if(WITH_CODEC_SNDFILE)