Author Topic: compilation problems  (Read 7996 times)

Offline gdhgdh

  • Jr. Member
  • **
  • Posts: 5
    • View Profile
    • Email
compilation problems
« on: November 21, 2008, 20:00:50 »
Hi :)

Am trying to compile qtvomp on Ubuntu hardy. I'm not exactly a Linux newbie, but wanted to run this by you in case there's an inherent flaw in the build system:

Code: [Select]
gdh@gdh-home:~/qtvomp$ qmake
gdh@gdh-home:~/qtvomp$ make
cd src/ && make -f Makefile
make[1]: Entering directory `/home/gdh/qtvomp/src'
g++ -c -pipe -g -D_REENTRANT -Wall -W -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -I. -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtNetwork -I/usr/include/qt4/QtGui -I/usr/include/qt4/QtGui -I/usr/include/qt4 -I/usr/include/phonon -I../build/src -I. -o ../build/src/qtvomp.o qtvomp.cpp
In file included from qtvomp.h:32,
                 from qtvomp.cpp:25:
widgetplayvideo.h:26:32: error: phonon/mediaobject.h: No such file or directory

Now, libphonon-dev is installed, and that header is here:

Code: [Select]
/usr/lib/kde4/include/phonon/mediaobject.h

and I've installed hundreds of megs of kdelibs5-dev with dependencies... so everything needed should be there :/

Do I just need to force a specific include directory? How can the build system detect this automatically?

Offline gdhgdh

  • Jr. Member
  • **
  • Posts: 5
    • View Profile
    • Email
Re: compilation problems
« Reply #1 on: November 21, 2008, 20:14:36 »
Ok got it compiled and the binary launched. (still need to upgrade the server to 0.3, tho') . For reference, I just needed amend the qtvomp/src/Makefile to

INCPATH       = -I /usr/lib/kde4/include/ ...etc. ....
and
LIBS          = $(SUBLIBS)  -L/usr/lib -L/usr/lib/kde4/lib -lphonon -lpthread -lQtGui -lQtNetwork -lQtCore

I would still like to hear how these paths could be automatically detected by the build system (a KDE/Qt equivalent for gtk-config)

Offline Chris

  • Administrator
  • Hero Member
  • *****
  • Posts: 537
    • View Profile
    • Email
Re: compilation problems
« Reply #2 on: November 24, 2008, 14:11:06 »
Just out of interest, do you mean you have got the binary running in a gnome environment? Albeit with all the KDE stuff installed?

Offline gdhgdh

  • Jr. Member
  • **
  • Posts: 5
    • View Profile
    • Email
Re: compilation problems
« Reply #3 on: November 24, 2008, 14:25:30 »
It compiles and runs cleanly... but trying to watch any video fails with the Phonon subsystem complaining that it's unable to launch the playback plugin (which does seem to be xine)

I looked around, found a few possible solutions, but none worked so I gave up...


Offline MarkC

  • Full Member
  • ***
  • Posts: 65
    • View Profile
Re: compilation problems
« Reply #4 on: November 24, 2008, 17:00:26 »
Just out of interest, do you mean you have got the binary running in a gnome environment? Albeit with all the KDE stuff installed?


Chris, IIRC you told me that the phonon stuff doesn't work if you're not running the full KDE. On Debian / Ubuntu, at least.

The bug below has just been fixed in Debian. Not sure if it's relevant, but people have commented in it about phonon not working if you've never started a KDE4 session.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=498573

Offline Chris

  • Administrator
  • Hero Member
  • *****
  • Posts: 537
    • View Profile
    • Email
Re: compilation problems
« Reply #5 on: November 24, 2008, 17:39:18 »
Well spotted... I started a KDE 4 session on my normal user account, went back into gnome and now qtvomp works!

Offline gdhgdh

  • Jr. Member
  • **
  • Posts: 5
    • View Profile
    • Email
Re: compilation problems
« Reply #6 on: November 24, 2008, 19:49:32 »
Ahh great :) Also just fired up a KDE session, and qtvomp now shows video in live + recordings when run in GNOME - am looking forward to seeing the code develop =)


Offline muellerph

  • Full Member
  • ***
  • Posts: 136
    • View Profile
    • Email
Re: compilation problems
« Reply #7 on: November 25, 2008, 07:23:38 »
Thanks for the hint. That's what the alpha is for, getting the glitches clarified.

For the Makefile issue:
To be honest, I have not much experience in doing the makefiles, so in case we have customized environment, I'm a bit lost what to do.

But so far, there should not be the need to adjust the Makefile, only the qmake ".pro" files need to be adjusted.
For Linux, the respective .pro settings are in the file "src/src.pro".

Maybe I will switch to cmake, but also there no experience on my side.

Offline Sir George

  • Jr. Member
  • **
  • Posts: 18
    • View Profile
    • Email
Re: compilation problems
« Reply #8 on: December 25, 2008, 11:58:48 »
Chris, IIRC you told me that the phonon stuff doesn't work if you're not running the full KDE. On Debian / Ubuntu, at least.

The bug below has just been fixed in Debian. Not sure if it's relevant, but people have commented in it about phonon not working if you've never started a KDE4 session.

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=498573
There's even the possibility to get it working without having to start kde4 (tested under ubuntu 8.10); I got the hint from the debian bugreport above.
Code: [Select]
export QT_PLUGIN_PATH=/usr/lib/kde4/plugins/
./qtvomp