Skip to main content

QTLIB variable in share/def_qt.mk in conflicts with enviroment variable

3 replies [Last post]
ansoncat
Offline
Joined: 2006-11-15
Points: 0

Hi, when I build PBP/PP on my pc,
building system recognize:

AWT_LIB_LIBS=-L/usr/lib/qt-3.3 -l/usr/lib/qt-3.3/lib ...

And as you know, it fails. The problem is that
enviroment variables QTLIB
is preset to point dir /usr/lib/qt-3.3/lib
on fedora core 6 with qt-3.3

So I need to override QTLIB to "qt-mt" or "qt"
to build PBP/PP.
I don't know whether it is a bug or not.
So I post this problem here.

QTLIB in defs_qt.mk may needs to change a name.

And perhaps the default value of QT_TARGET_DIR can
be set to $(QTDIR) since it is common used.

Sorry for my poor english.

regards,

Anson Chen

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
ansoncat
Offline
Joined: 2006-11-15
Points: 0

> I didn't realize that QTLIB was a common environment
> variable. For now, you can just rename it in
> build/share/defs_qt.mk. We'll eventually choose a
> better name.
>
> For QTDIR, there is support for it. If you look in
> build/share/defs_qt.mk, you will see:
>
> # Check in QTDIR if set
> ifneq ($(QTDIR),)
> ifneq ($(wildcard $(QTDIR)/lib),)
> QT_TARGET_LIB_DIR ?= $(QTDIR)/lib
> QT_TARGET_INCLUDE_DIR ?= $(QTDIR)/include
> MOC ?= $(QTDIR)/bin/moc
> endif
> endif
>
> If for some reason this is not working for you, let
> me know. I don't think this path has actually been
> tested in quite some time, and the logic above it
> (which has changed quite a bit recently) could
> possibly be causing it not to work.

Thanks, I've not found QTDIR in build/share/def_qt.mk last time. :) All works fine without setting any setting excepted needing to unset QTLIB.

I found different distribution has different police. Fedora Core6 will set envarinment variables QTDIR, QTLIB, QTINC for any user, but Ubuntu 6.06 will not set any thing.
It may needs to hide some internal variables and add prefix
to all building options (yeh, it already has some but not all).

regards

Anson Chen

cjplummer
Offline
Joined: 2006-10-16
Points: 0

I didn't realize that QTLIB was a common environment variable. For now, you can just rename it in build/share/defs_qt.mk. We'll eventually choose a better name.

For QTDIR, there is support for it. If you look in build/share/defs_qt.mk, you will see:

# Check in QTDIR if set
ifneq ($(QTDIR),)
ifneq ($(wildcard $(QTDIR)/lib),)
QT_TARGET_LIB_DIR ?= $(QTDIR)/lib
QT_TARGET_INCLUDE_DIR ?= $(QTDIR)/include
MOC ?= $(QTDIR)/bin/moc
endif
endif

If for some reason this is not working for you, let me know. I don't think this path has actually been tested in quite some time, and the logic above it (which has changed quite a bit recently) could possibly be causing it not to work.

cjplummer
Offline
Joined: 2006-10-16
Points: 0

One more thing regarding QTDIR. If you are doing a cross build, QTDIR is ignored because it could be for any target platform. The thinking is that QTDIR should only be set to the host's QT installation, not for some cross developerment target, and therefore not used for cross builds.