Giter VIP home page Giter VIP logo

Comments (11)

zaps166 avatar zaps166 commented on August 20, 2024

Looks like missing zlib linking for Linux (worked when I tested without this). Please apply:

diff --git a/src/modules/Modplug/CMakeLists.txt b/src/modules/Modplug/CMakeLists.txt
index e868ee2..2d3eb3e 100644
--- a/src/modules/Modplug/CMakeLists.txt
+++ b/src/modules/Modplug/CMakeLists.txt
@@ -61,10 +61,8 @@ add_library(${PROJECT_NAME} MODULE
     ${Modplug_SRC}
 )

-if(WIN32 OR CMAKE_SYSTEM_NAME STREQUAL "Darwin")
-    find_package(ZLIB REQUIRED)
-    target_link_libraries(${PROJECT_NAME} ${ZLIB_LIBRARY})
-endif()
+find_package(ZLIB REQUIRED)
+target_link_libraries(${PROJECT_NAME} ${ZLIB_LIBRARY})

 if(USE_QT5)
     qt5_use_modules(${PROJECT_NAME} Gui Widgets)

If it will help I'll push a patch :)

from qmplay2.

DAP-DarkneSS avatar DAP-DarkneSS commented on August 20, 2024

Thank you, the patch is fine but there is similar but another linking error now.
I suppose that issue depends on what libraries Qt was linked with.
cmake2.build.log.txt

from qmplay2.

zaps166 avatar zaps166 commented on August 20, 2024

The problem with OpenGL and ModPlug is in -Wl,--no-undefined which is used in your build. The best solution I think is to link to OpenGL libraries instead of removing the flag.

from qmplay2.

zaps166 avatar zaps166 commented on August 20, 2024

Or maybe it is better to force-remove -Wl,--no-undefined from CMake link flags?

As a workaround please apply:

XVideo:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3cd8de2..d49b97a 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -142,7 +142,7 @@ option(USE_PULSEAUDIO "Build with PulseAudio module" ${LIBPULSE_FOUND})
 add_feature_info(PulseAudio USE_PULSEAUDIO "Build with PulseAudio module")

 if(NOT DEFINED USE_XVIDEO)
-    pkg_check_modules(LIB_X11_XV x11 xv)
+    pkg_check_modules(LIB_X11_XV x11 xv xext)
 endif()
 option(USE_XVIDEO "Build with XVideo module" ${LIB_X11_XV_FOUND})
 add_feature_info(XVideo USE_XVIDEO "Build with XVideo module")
diff --git a/src/modules/XVideo/CMakeLists.txt b/src/modules/XVideo/CMakeLists.txt
index 92c6cd7..fb8383b 100644
--- a/src/modules/XVideo/CMakeLists.txt
+++ b/src/modules/XVideo/CMakeLists.txt
@@ -28,7 +28,7 @@ set(XVideo_RESOURCES
     icon.qrc
 )

-pkg_check_modules(LIB_X11_XV x11 xv REQUIRED)
+pkg_check_modules(LIB_X11_XV x11 xv xext REQUIRED)
 link_directories(${LIB_X11_XV_LIBRARY_DIRS})

 if(USE_QT5)

OpenGL2:

diff --git a/src/modules/OpenGL2/CMakeLists.txt b/src/modules/OpenGL2/CMakeLists.txt
index 8464ce2..0fe2b4a 100644
--- a/src/modules/OpenGL2/CMakeLists.txt
+++ b/src/modules/OpenGL2/CMakeLists.txt
@@ -97,11 +97,13 @@ target_link_libraries(${PROJECT_NAME}
 if(CMAKE_SYSTEM_NAME STREQUAL "Darwin")
     find_package(OpenGL REQUIRED)
     target_link_libraries(${PROJECT_NAME} ${OPENGL_LIBRARIES})
-elseif(WIN32)
+else()
     if(QT_USES_OPENGLES)
         target_link_libraries(${PROJECT_NAME} GLESv2)
-    else()
+    elseif(WIN32)
         target_link_libraries(${PROJECT_NAME} opengl32)
+    else()
+        target_link_libraries(${PROJECT_NAME} GL)
     endif()
 endif()

from qmplay2.

DAP-DarkneSS avatar DAP-DarkneSS commented on August 20, 2024

from qmplay2.

zaps166 avatar zaps166 commented on August 20, 2024

Ok and I'll force-remove this flag from CMake build.

from qmplay2.

DAP-DarkneSS avatar DAP-DarkneSS commented on August 20, 2024

from qmplay2.

zaps166 avatar zaps166 commented on August 20, 2024

The first patch is not necessary if you not use the -Wl,--no-undefined.

from qmplay2.

zaps166 avatar zaps166 commented on August 20, 2024

The patch: f274748 should fix it without doing any modifications, please test it instead of doing any other modification and patches (I want to know if it works and if it doesn't break anything else) :)

from qmplay2.

DAP-DarkneSS avatar DAP-DarkneSS commented on August 20, 2024
             | vanilla | f274748

just cmake | OK | OK

packaging macro | Fail | *

*: Shared objects files are put into /usr/usr/lib64 not /usr/lib64. Should
I file another report about it?

from qmplay2.

zaps166 avatar zaps166 commented on August 20, 2024

Also 65f826c is needed if there is no additional linker flags.

Should I file another report about it?

Hmm... Yes.

from qmplay2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.