diff --git a/src/gui/X11EmbedContainer.h b/include/X11EmbedContainer.h similarity index 100% rename from src/gui/X11EmbedContainer.h rename to include/X11EmbedContainer.h diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 154ff4f85..8523fc44b 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -132,7 +132,7 @@ IF(LMMS_BUILD_HAIKU) SET(EXTRA_LIBRARIES "-lnetwork") ENDIF() -SET(LMMS_REQUIRED_LIBS +SET(LMMS_REQUIRED_LIBS ${LMMS_REQUIRED_LIBS} ${CMAKE_THREAD_LIBS_INIT} ${QT_LIBRARIES} ${ASOUND_LIBRARY} diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt index 3373945ed..345679297 100644 --- a/src/gui/CMakeLists.txt +++ b/src/gui/CMakeLists.txt @@ -92,8 +92,10 @@ SET(LMMS_SRCS ) IF(QT5 AND LMMS_BUILD_LINUX) + INCLUDE_DIRECTORIES("${CMAKE_SOURCE_DIR}/include/") add_library(x11embedcontainer STATIC - X11EmbedContainer + "${CMAKE_SOURCE_DIR}/src/gui/X11EmbedContainer.cpp" + "${CMAKE_SOURCE_DIR}/include/X11EmbedContainer.h" ) FIND_PACKAGE(Qt5Core COMPONENTS Private) FIND_PACKAGE(Qt5Widgets COMPONENTS Private) @@ -102,10 +104,11 @@ IF(QT5 AND LMMS_BUILD_LINUX) include_directories(${Qt5Core_PRIVATE_INCLUDE_DIRS}) include_directories(${Qt5Widgets_PRIVATE_INCLUDE_DIRS}) - target_link_Libraries(x11embedcontainer - xcb xcb-util X11-xcb Qt5::X11Extras + xcb xcb-util X11-xcb Qt5::X11Extras X11 ) + + SET(LMMS_REQUIRED_LIBS ${LMMS_REQUIRED_LIBS} x11embedcontainer PARENT_SCOPE) ELSE() add_library(x11embedcontainer STATIC /dev/null) ENDIF()