trinity-devel@lists.pearsoncomputing.net

Message: previous - next
Month: December 2011

Re: [trinity-devel] Autotools package builds

From: Laurent Dard <f.couperin@...>
Date: Fri, 16 Dec 2011 14:09:26 +0100
Le 15/12/2011 23:37, Baho Utot a écrit :
> Why would the build fail?

I'm trying to understand.

Even if your intallation of qt isn't common, it should work.
And I can't say for sure that installing it in /usr will solve your problem.

But installing Qt3 in /usr is known to work so it's better to do it this way,
I think.

> I have tried using /usr for everything (entire build from start to finish all 
> packages) and it still failed.
> 
> I have tried to stick to the How to docs on trinity, but I have read that 
> everything should be in /opt/trinity except for tqtinterface.
> 
> What do you suggest?
> 
> I can rebuild all of trinity quite easily, so if I need to change all the 
> prefix(s) I can.

The dependencies in /usr.
The KDE packages in /opt/trinity.

* in /usr:
  qt3
  tqtinterface
  arts
  (dbus bindings)

* in /opt/trinity
  kde*

The web page isn't clear. But it says: "Please note that you can
find spec/dsc/PKGBUILD/emerge files at our GIT repositories."

I would add the slackware instructions from Darrell Anderson:
  http://humanreadable.nfshost.com/sdeg/kde_35x.htm
and his build scripts:
  http://humanreadable.nfshost.com/files/kde-35-buildtree.tar.gz
(look at the *.SlackBuild files).

And the instructions from BLFS and CLFS to build KDE3 are
still useful for me.

>> Your trinity installation should be working at this stage. Does it?
> 
> Yes, I am posting from TDE using kmail (this email)
> 
>> Can you run qt programs (designer...)?
> 
> It opens but it is a mess



> Notice that I have qt-mt.pc  in /usr/lib/pkgconfig,  I moved it there to try 
> to solve this problem.

That's a known bug in qt3.

"For Qt, pkg-config will look for the file lib/pkgconfig/qt-mt.pc which must
be modified if relocating the package. This file is set up correctly by the
build process. "
http://www.linuxfromscratch.org/blfs/view/svn/x/qt.html

>> Can you compile a little program?
>>   cat << EOF | gcc --verbose -x c++ - -I/opt/trinity/include
>> -L/opt/trinity/lib #include <qapplication.h>
>> int main(int argc, char **argv) { QApplication app(argc, argv); return 0; }
>> EOF
>>
> 
> cat << EOF | gcc --verbose -x c++ - -I/opt/trinity/include
>  -L/opt/trinity/lib #include <qapplication.h>
>   int main(int argc, char **argv) { QApplication app(argc, argv); return 0; }
> EOF

It can't work: Kmail broke the first line.
(But this test seems no more important:
your Qt installation is working.)

Maybe this will work:

echo "#include <qapplication.h>
int main(int argc, char **argv)
{ QApplication app(argc, argv); return 0; }" |
gcc --verbose -x c++ - -I/opt/trinity/include \
  -L/opt/trinity/lib

This one will test pkg-config and it *must* work:

echo "#include <qapplication.h>
int main(int argc, char **argv)
{ QApplication app(argc, argv); return 0; }" |
gcc --verbose -x c++ - \
  `pkg-config --cflags --libs qt-mt`

> cat /etc/profile.d/qt3.sh
> 
> export QT_XFT=true
> QTDIR=/opt/trinity
> PATH=${QTDIR}/bin:${PATH:=}
> PATH=${PATH%:}
> LD_LIBRARY_PATH=${QTDIR}/lib:${LD_LIBRARY_PATH:=}
> LD_LIBRARY_PATH=${LD_LIBRARY_PATH%:}
> LD_LIBRARY_PATH=/lib:/usr/lib:${LD_LIBRARY_PATH}
> export QTDIR PATH LD_LIBRARY_PATH

I imagine you have this somewhere:

  export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/opt/trinity/lib/pkgconfig

>> That's a bit too short, maybe...
>>   --sysconfdir=/etc/trinity
>>   --disable-rpath
>>   --with-extra-libs=/opt/trinity/lib
>>   --with-xinerama
>>   --enable-closure
>>
> 
> Yes I know it was but I was just trying to get past the compile errors and 
> then I will go back and fix that up

I would try to add these flags:

  --with-qt-dir=${QTDIR} \
  --with-qt-includes=${QTDIR}/include \
  --with-qt-libraries=${QTDIR}/lib \
  --enable-closure \
  --disable-rpath

> Thank you very much for helping me with this problem.

Unfortunately, it is still a mistery...

-- 
Laurent Dard