clementine FTBFS due to wrong linking glew in projectm

Bug #819025 reported by Artur Rona
20
This bug affects 1 person
Affects Status Importance Assigned to Milestone
projectm (Ubuntu)
Fix Released
Undecided
Matthias Klumpp

Bug Description

I am working on clementine in Debian due to get it synced to Ubuntu without remaining changes. However, start work is not possible due to FTBFS.

[100%] Built target clementine_lib
make -f src/CMakeFiles/clementine.dir/build.make src/CMakeFiles/clementine.dir/depend
make[4]: Entering directory `/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu'
cd /tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu && /usr/bin/cmake -E cmake_depends "Unix Makefiles" /tmp/buildd/clementine-0.7.1+dfsg /tmp/buildd/clementine-0.7.1+dfsg/src /tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu /tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu/src /tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu/src/CMakeFiles/clementine.dir/DependInfo.cmake --color=
Scanning dependencies of target clementine
make[4]: Leaving directory `/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu'
make -f src/CMakeFiles/clementine.dir/build.make src/CMakeFiles/clementine.dir/build
make[4]: Entering directory `/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu'
/usr/bin/cmake -E cmake_progress_report /tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu/CMakeFiles
[100%] Building CXX object src/CMakeFiles/clementine.dir/main.cpp.o
cd /tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu/src && /usr/bin/c++ -DQT_OPENGL_LIB -DQT_GUI_LIB -DQT_DBUS_LIB -DQT_XML_LIB -DQT_SQL_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_NO_CAST_TO_ASCII -g -O2 -Woverloaded-virtual -Wall -Wno-sign-compare -Werror -I/usr/include/qt4 -I/usr/include/qt4/QtOpenGL -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtDBus -I/usr/include/qt4/QtXml -I/usr/include/qt4/QtSql -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtCore -I/usr/include/taglib -I/usr/include/glib-2.0 -I/usr/lib/i386-linux-gnu/glib-2.0/include -I/usr/include/gstreamer-0.10 -I/usr/include/libxml2 -I/tmp/buildd/clementine-0.7.1+dfsg/3rdparty/universalchardet -I/tmp/buildd/clementine-0.7.1+dfsg -I/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu/src -I/tmp/buildd/clementine-0.7.1+dfsg/src -I/tmp/buildd/clementine-0.7.1+dfsg/src/../3rdparty/gmock/gtest/include -I/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu -I/tmp/buildd/clementine-0.7.1+dfsg/3rdparty/qtsingleapplication -I/tmp/buildd/clementine-0.7.1+dfsg/3rdparty/qtiocompressor -I/usr/include/qxt/QxtCore -I/usr/include/qxt/QxtGui -I/usr/include/gdk-pixbuf-2.0 -I/usr/include/libpng12 -I/usr/include/gpod-1.0 -o CMakeFiles/clementine.dir/main.cpp.o -c /tmp/buildd/clementine-0.7.1+dfsg/src/main.cpp
Linking CXX executable ../clementine
cd /tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu/src && /usr/bin/cmake -E cmake_link_script CMakeFiles/clementine.dir/link.txt --verbose=1
/usr/bin/c++ -g -O2 -Woverloaded-virtual -Wall -Wno-sign-compare -Werror -Wl,-Bsymbolic-functions CMakeFiles/clementine.dir/main.cpp.o -o ../clementine -rdynamic libclementine_lib.a ../3rdparty/universalchardet/libchardet.a -lechonest -ltag -lQtOpenGL -lQtGui -lQtDBus -lQtXml -lQtSql -lQtNetwork -lQtCore ../3rdparty/qtsingleapplication/libqtsingleapplication.a ../3rdparty/qtiocompressor/libqtiocompressor.a -lpthread -ldl -lz -lprojectM -llastfm -lgpod -lgdk_pixbuf-2.0 -lm -lgio-2.0 -lplist -lusbmuxd ../gstafcsrc/libgstafcsrc.a -lgobject-2.0 -lgthread-2.0 -lrt -lglib-2.0 -lgstbase-0.10 -lgstreamer-0.10 -lgmodule-2.0 -lxml2 -lgobject-2.0 -lgthread-2.0 -lrt -lglib-2.0 -lgstbase-0.10 -lgstreamer-0.10 -lgmodule-2.0 -lxml2 -limobiledevice -lmtp -lusb -lQxtGui -lX11 -ldl
/usr/lib/libprojectM.so: undefined reference to `__glewFramebufferTexture2DEXT'
/usr/lib/libprojectM.so: undefined reference to `FTPixmapFont::FTPixmapFont(char const*)'
/usr/lib/libprojectM.so: undefined reference to `__glewFramebufferRenderbufferEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewCheckFramebufferStatusEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewRenderbufferStorageEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewGenRenderbuffersEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewBindRenderbufferEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewDeleteFramebuffersEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewGenFramebuffersEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewDeleteRenderbuffersEXT'
/usr/lib/libprojectM.so: undefined reference to `__glewBindFramebufferEXT'
/usr/lib/libprojectM.so: undefined reference to `FTExtrudeFont::FTExtrudeFont(char const*)'
/usr/lib/libprojectM.so: undefined reference to `glewIsSupported'
/usr/lib/libprojectM.so: undefined reference to `glewInit'
collect2: ld returned 1 exit status
make[4]: *** [clementine] Error 1
make[4]: Leaving directory `/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu'
make[3]: *** [src/CMakeFiles/clementine.dir/all] Error 2
make[3]: Leaving directory `/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/tmp/buildd/clementine-0.7.1+dfsg/obj-i686-linux-gnu'
dh_auto_build: make -j1 returned exit code 2
make[1]: *** [override_dh_auto_build] Error 2
make[1]: Leaving directory `/tmp/buildd/clementine-0.7.1+dfsg'
make: *** [build] Error 2
dpkg-buildpackage: error: debian/rules build gave error exit status 2
E: Failed autobuilding of package

I've asked on #debian-devel and this is advice:
[Sunday 24 of July 2011] [12:37:06] <ari-tczew> anybody knows how to fix this ftbfs>? http://paste.debian.net/123980/
[Sunday 24 of July 2011] [12:37:35] <KiBi> -lglew?
[Sunday 24 of July 2011] [12:38:04] <ari-tczew> KiBi: where I need to add it?
[Sunday 24 of July 2011] [12:38:14] <pinotree> in libprojectM

In paste.debian mentioned above is buildlog. I've attached full buildlog from pbuilder-oneiric.

I'll be grateful for help.

Revision history for this message
Artur Rona (ari-tczew) wrote :
Artur Rona (ari-tczew)
tags: added: ftbfs oneiric universe
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package projectm - 2.0.1+dfsg-9build1

---------------
projectm (2.0.1+dfsg-9build1) oneiric; urgency=low

  * No change rebuild for libglew1.5 -> libglew1.6 transition (LP: #819025)
 -- Micah Gersten <email address hidden> Sun, 31 Jul 2011 22:54:05 -0500

Changed in projectm (Ubuntu):
status: New → Fix Released
Revision history for this message
Micah Gersten (micahg) wrote :

Actually not fixed...

Changed in projectm (Ubuntu):
status: Fix Released → New
Revision history for this message
Matthias Klumpp (ximion) wrote :

I'll take a look at it, but at time I'm not able to reproduce this bug...

Changed in projectm (Ubuntu):
assignee: nobody → Matthias Klumpp (ximion)
Revision history for this message
Julian Taylor (jtaylor) wrote :

it is an as-needed problem, cmake adds dependencies transitive, so it ends up with libprojectM.so ends up linking with libRenderer.a in the wrong order on the commend line.

This patch works around this issue fir libprojectM.so but the same problem exists for libprojectM-qt.so

check the libraries with ldd -r to ensure you fixed it correctly.

--- projectm-2.0.1+dfsg.orig/src/libprojectM/CMakeLists.txt
+++ projectm-2.0.1+dfsg/src/libprojectM/CMakeLists.txt
@@ -189,7 +189,7 @@ if(BUILD_PROJECTM_STATIC)
   TARGET_LINK_LIBRARIES(projectM ${GLEW_LINK_TARGETS} m ${FTGL_LINK_TARGETS} ${OPENGL_LIBRARIES} ${IMAGE_L
INK_TARGETS} ${CG_LINK_TARGETS} ${PRESET_FACTORY_LINK_TARGETS})
 else(BUILD_PROJECTM_STATIC)

-TARGET_LINK_LIBRARIES(projectM ${GLEW_LINK_TARGETS} m ${FTGL_LINK_TARGETS} ${OPENGL_LIBRARIES} ${IMAGE_LINK_TARGETS} $
{CG_LINK_TARGETS} ${PRESET_FACTORY_LINK_TARGETS})
+TARGET_LINK_LIBRARIES(projectM Renderer ${GLEW_LINK_TARGETS} m dl ${FTGL_LINK_TARGETS} ${OPENGL_LIBRARIES} ${IMAGE_LIN
K_TARGETS} ${CG_LINK_TARGETS} ${PRESET_FACTORY_LINK_TARGETS})

 endif(BUILD_PROJECTM_STATIC)

Revision history for this message
Julian Taylor (jtaylor) wrote :

there seems to be a cmake property to disable this behavior:
http://www.cmake.org/cmake/help/cmake-2-8-docs.html#prop_tgt:LINK_INTERFACE_LIBRARIES
but I fail to get it to work.

Revision history for this message
Julian Taylor (jtaylor) wrote :

above workaround-patch had a minor issue with the ordering. attached a proper one.

tags: added: patch
Matthias Klumpp (ximion)
Changed in projectm (Ubuntu):
status: New → In Progress
Revision history for this message
Artur Rona (ari-tczew) wrote :

I can confirm that projectm 2.0.1+dfsg-10 fixes issue. Sync bug #819763.
Clementine now builds fine on my PPA. https://launchpad.net/~ari-tczew/+archive/testing/+build/2662731

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package projectm - 2.0.1+dfsg-10

---------------
projectm (2.0.1+dfsg-10) unstable; urgency=low

  * Use DejaVu font instead of Bistream-Vera (Closes: #630557)
  * Update my email-address
  * Update projectM-Qt dev package dependencies
  * Fix projectM linking (LP: #819025)
  * Rebuild for libglew1.5 -> libglew1.6 transition
 -- Matthias Klumpp <email address hidden> Mon, 08 Aug 2011 23:55:39 +0000

Changed in projectm (Ubuntu):
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.