trinity-devel@lists.pearsoncomputing.net

Message: previous - next
Month: January 2012

Re: [trinity-devel] Need help: cmake/pkgconfig breakage?

From: Baho Utot <baho-utot@...>
Date: Thu, 19 Jan 2012 17:16:17 -0500

On Thursday 19 January 2012 04:32:05 pm Darrell Anderson wrote:
> > > Well here is an interesting turn of events. I added
> >
> > the following to my
> >
> > > ugly script function hack:
> > >
> > > pkg-config --cflags-only-I tqt
> > >
> > > The command returns no results.
> > >
> > > When directly in a terminal the command returns the
> >
> > expected
> >
> > > -I/usr/lib/qt3/include -I/usr/include/tqt.
> > >
> > > So perhaps the problem is right there. For whatever
> >
> > reason pkg-config is
> >
> > > not running from within scripts. Or is dumping the
> >
> > results to the bit
> >
> > > bucket.
> >
> > <snip>
> >
> > Yes, that is the problem right there!
> >
> > I would dump the environemnt (via the 'env' command) in
> > your terminal and
> > from within in the build script to see what is
> > different.  Usually this
> > kind of problem is caused by an incorrectly set environment
> > variable.
>
> Beat you to the punch. :)
>
> I might not be a crack developer, but I can troubleshoot with some of the
> best. ;)
>
> You might not believe the cause of this entire problem. Are you ready for
> this?
>
> Setting the $CPLUS_INCLUDE_PATH in the build environment prevents
> pkg-config from running properly. The moment I commented out that export
> command in my master script, the TQT_INCLUDE_DIRS internal variable began
> populating automatically.
>
> Okay, for the record: Woo-hoo!
>
> Now, why does the $CPLUS_INCLUDE_PATH environment variable, or the contents
> thereof, affect how pkg-config runs?
>
> Second, should I be setting that environment variable?
>
> Here is my normal setting for that variable:
>
> CPLUS_INCLUDE_PATH: /usr/include/tqt:/usr/lib/qt3/include:/usr/include
>
> Those locations are legitimate.
>
> I set $CMAKE_INCLUDE_PATH to the same, but I did not start setting that
> variable until recently. That is, this TQT_INCLUDE_DIRS problem existed
> long before I started setting the $CMAKE_INCLUDE_PATH variable. The
> $CPLUS_INCLUDE_PATH is the cause.
>
> Ideas?
>
> Darrell
>

FYI

<warning a bit of a rant follows> 

(and you can tell me to piss off if you want)

I try to keep to FHS as much as possible so I don't incur this type of wrath 
from pkg-config and the gnu tool chain.  To say nothing of actually ruining 
the beast when you've finished getting it to build.

This why I put TDE into /usr so the build environment doesn't cause me gas and 
bloating... and I know it will run when I get the beast installed.

I put qt3 into /usr/local so I avoid problems with qt4. 

/usr and /usr/local are usally configured on most distributions linker paths 
and it's in the PATH so then I don't as the packager have to jump through 
hoops etc.

You folks can do what ever you wish but for me I am sticking to FHS and puting 
this thing into /usr/local.

I don't know where all this /opt and company came from but.....

When I finally get to rebuilding TDE I will put the whole thing 
into /usr/local.  It will not interfere with KDE4 and QT4 and as an added 
benifit I don't have to mess with PATH nor the linker path etc.  It just 
works. ;)  May I suggest you think about changing /opt or where ever you 
installed this beast and place your work into /usr/local as well.

/usr/local is clean and has nothing else installed there.  So I have the play 
ground to myself.

I think most distros don't put things there by default.

/<warning a bit of a rant follows>