compiz-core fails to build on Archlinux, due to DSO linking problem

Bug #931005 reported by triplesqaurednine
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Compiz
Fix Released
Critical
Unassigned
Compiz Core
New
Undecided
Unassigned
Arch Linux
New
Undecided
Unassigned
CentOS
New
Undecided
Unassigned
Fedora
New
Undecided
Unassigned

Bug Description

As said compiz-core fails to build on (Archlinux 64) do to DSO linking problem;

Scanning dependencies of target compiz_privatescreen_test
[ 42%] Building CXX object src/privatescreen/tests/CMakeFiles/compiz_privatescreen_test.dir/test-privatescreen.cpp.o
Linking CXX executable compiz_privatescreen_test
/usr/bin/ld: CMakeFiles/compiz_privatescreen_test.dir/test-privatescreen.cpp.o: undefined reference to symbol 'XOpenDisplay'
/usr/bin/ld: note: 'XOpenDisplay' is defined in DSO /usr/lib/libX11.so.6 so try adding it to the linker command line
/usr/lib/libX11.so.6: could not read symbols: Invalid operation
collect2: ld returned 1 exit status
make[2]: *** [src/privatescreen/tests/compiz_privatescreen_test] Error 1
make[1]: *** [src/privatescreen/tests/CMakeFiles/compiz_privatescreen_test.dir/all] Error 2
make: *** [all] Error 2

I'm not quite familiar how to change this in the cmake files, but when just using 'make', usually i can just type 'export LDFLAGS="$LDFLAGS -lm" (as an example) before compiling, this doesn't seem to work with the cmake build system, though.

DSO linking is also discussed here (i think this applies anyway);

http://fedoraproject.org/wiki/UnderstandingDSOLinkChange

Maybe in Ubuntu/Debian, things aren't done this way, i don't know. But for many other distro's this might be an issue? From what i understand -libx11 should be defined in the cmakefiles, but seems to not be - i'm not positive as to where it should be.

cheerz

SideNote/off-topic: Could the Compiz team please post proper build instructions for compiz (On either the compiz home page or Smspillaz compiz blog), now that development has shifted to bzr-only. ~ this would be helpful for package maintainers on X,Y,Z distro, as well as those that wish to build compiz from sources on X.Y,Z distro.

thanx

Revision history for this message
triplesqaurednine (triplesquarednine) wrote :

I've now tested building compiz on several non-debian/ubuntu systems - in all cases compiz-core fails to build with DSO linking problems :\ this includes Archlinux, CentOS and Fedora ~ but if you like i can try to compile it on several other distros **if 3 failed builds on X,Y,Z distro isn't enough?**

I would assume other parts of compiz (in bzr) also have the same sort of (DSO) linking issues.... although, since compiz-core won't build, i haven't bothered to build any other part.

this is a *critical* bug, as compiz will *NOT* build outside of Ubuntu/debian, without manual intervention of the end-user. which IMO is almost as bad as when someone made a commit which broke compiz on ALL RPM distros;

http://bugs.opencompositing.org/show_bug.cgi?id=1352

please consider other distro's when coding, not everybody is using Ubuntu. thanks

Revision history for this message
triplesqaurednine (triplesquarednine) wrote :

I've now gotten Compiz 0.9.7-bzr to compile on ALL distro's mentioned. :)

Cmake does honour my LDFLAGS, but only if i execute it like so;

LDFLAGS='-lX11 -ldl -lXext' cmake .. -DCMAKE_INSTALL_PREFIX=/usr

... this also must be done *before* running cmake, otherwise cmake will not honour the flags... i would assume it uses whatever is cached instead. ~ this must have been my mistake the other day.

However, that being said. This is still a bug that should be fixed.

-lX11 -ldl -lXext should be defined (as LDFLAGS) somewhere in the sources (again not sure where), or compiz will continue to fail on non-debian based systems. (or atleast every distro that i have tested).

cheerz

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

I would like to get this fixed upstream too. Keep in mind though that compiz 0.9.7.0 has not even been released yet. The release in ubuntu/precise is an early preview so now might be premature trying to push it into other distros.

Regarding build instructions, this is mostly correct (if you ignore the "git" parts):
http://wiki.compiz.org/C%2B%2BCompiling
Though, we should probably move the relevant details to the INSTALL file instead.

Changed in compiz-core:
milestone: none → 0.9.7.2
Revision history for this message
triplesqaurednine (triplesquarednine) wrote :

Hey Daniel.

no worries, i realize Compiz 0.9.7.x isn't quite ready for primetime. (yet) ;)

however, In the last 24 hours a few ugly bugs have disappeared, though. (namely the white windows / fail to bind pixmap to texture). So at this point, compiz is relatively stable for me, although i have noticed some bugs / things not working as expected -> the main one being some of the 'bindings' aren't working (for scale anyway) AND this little issue on startup;

Initializing core options...done
/usr/lib/python2.7/site-packages/ccm/Window.py:92: Warning: g_object_set_qdata: assertion `G_IS_OBJECT (object)' failed
  self.LeftPane.pack_start(page.LeftWidget, True, True)
/usr/lib/python2.7/site-packages/ccm/Window.py:95: Warning: g_object_set_qdata: assertion `G_IS_OBJECT (object)' failed
  self.show_all()
/usr/lib/python2.7/site-packages/ccm/Widgets.py:1567: Warning: g_object_set_qdata: assertion `G_IS_OBJECT (object)' failed
  self._table.attach (button, col, col+1, row, row+1, 0, xpadding=TableX, ypadding=TableY)
Loading icons...
/usr/lib/python2.7/site-packages/ccm/Widgets.py:1572: Warning: g_object_set_qdata: assertion `G_IS_OBJECT (object)' failed
  self.show_all ()

Not sure what is causing this (?)

Other than that, this release is coming along nicely. I've even noticed a nice performance boost (i think it was the nvidia fix, maybe?) :)

anyway, tonight i am going to go through (all) of the bug reports, and see if anything i am seeing hasn't had a bug report yet and/or i will add myself to reports that apply to me.

cheerz

great work on Compiz ;)

Revision history for this message
Daniel van Vugt (vanvugt) wrote :

The bindings problem you mention is bug 931927

Changed in compiz-core:
milestone: 0.9.7.2 → 0.9.7.4
Changed in compiz-core:
milestone: 0.9.7.4 → none
Changed in compiz-core:
milestone: none → 0.9.7.6
Changed in compiz-core:
milestone: 0.9.7.6 → 0.9.7.8
Changed in compiz-core:
milestone: 0.9.7.8 → 0.9.8.0
Changed in compiz:
milestone: none → 0.9.8.0
Changed in compiz-core:
milestone: 0.9.8.0 → none
Changed in compiz:
milestone: 0.9.8.0 → 0.9.8.1
Changed in compiz:
milestone: 0.9.8.2 → 0.9.8.4
Changed in compiz:
milestone: 0.9.8.4 → 0.9.9.0
Changed in compiz:
milestone: 0.9.9.0 → 0.9.9.2
Changed in compiz:
milestone: 0.9.9.2 → 0.9.10.0
Revision history for this message
MC Return (mc-return) wrote :

@triplesqaurednine:

Do you still have these DSO linking problems when compiling Compiz on non-Ubuntu distros ?

Changed in compiz:
importance: Undecided → Critical
Revision history for this message
triplesqaurednine (triplesquarednine) wrote :

@MC return

I don't think it's a problem anymore - but i will have to check my compiz build script - when i get a chance (later tonight, not in front of that machine / at home, right now).

Revision history for this message
MC Return (mc-return) wrote :

@triplesqaurednine:

Thanks a lot for checking later. +1

MC Return (mc-return)
Changed in compiz:
status: New → Incomplete
Changed in compiz:
milestone: 0.9.10.0 → 0.9.10.2
MC Return (mc-return)
Changed in compiz:
milestone: 0.9.10.2 → 0.9.11.0
Revision history for this message
Stephen M. Webb (bregma) wrote :

CI build tools automatically detect this problem and report it as a failure. I'm fairly confident it has been fixed at some point.

Changed in compiz:
milestone: 0.9.11.0 → none
status: Incomplete → 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.