CMake: Build lmms shared library instead of object library

Resolves some inexplicable linking errors on Windows. Saves us from
working around incomplete CMake support of object libraries.
This commit is contained in:
Lukas W
2020-05-22 17:20:08 +02:00
parent ac0081de10
commit 846ca178f5
19 changed files with 80 additions and 123 deletions

View File

@@ -108,7 +108,7 @@ chmod +x "${APPDIR}usr/bin/lmms"
unset LD_LIBRARY_PATH
# Ensure linuxdeployqt can find shared objects
export LD_LIBRARY_PATH="${APPDIR}"usr/lib/lmms/:"${APPDIR}"usr/lib/lmms/optional:"$LD_LIBRARY_PATH"
export LD_LIBRARY_PATH="${APPDIR}"usr/lib/:"${APPDIR}"usr/lib/lmms/:"${APPDIR}"usr/lib/lmms/optional:"$LD_LIBRARY_PATH"
# Move executables so linuxdeployqt can find them
ZYNLIB="${APPDIR}usr/lib/lmms/RemoteZynAddSubFx"

View File

@@ -60,7 +60,7 @@ FUNCTION(BUILD_PLUGIN PLUGIN_NAME)
ADD_LIBRARY(${PLUGIN_NAME} ${PLUGIN_LINK} ${PLUGIN_SOURCES} ${plugin_MOC_out} ${RCC_OUT})
TARGET_LINK_LIBRARIES(${PLUGIN_NAME} Qt5::Widgets Qt5::Xml lmms)
TARGET_LINK_LIBRARIES(${PLUGIN_NAME} Qt5::Widgets Qt5::Xml lmmslib)
INSTALL(TARGETS ${PLUGIN_NAME}
LIBRARY DESTINATION "${PLUGIN_DESTINATION}"