Qt 4.7.0 Building Problem on Mac OS Snow Leopard
-
Yep I'm running into the same problem and don't see any obvious reason why.
-
Setting the PATH should have no effect on picking up libraries on a unix-based systems like Mac OSX.
So where does it get /tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0 from? Is that where you had some sources at some point? Is it where your project is located? Is there anything in your .pro-file that references this location (using an absolute or relative path)?
-
Nope. Brand new machine nothing on it but the latest xcode, qt sdk, and a small project in ~/projectname, using a simple .pro file
my best guess is this is some temp dir used by Qt Creator during the build process. It doesn't actually cause any problems per se, everything builds fine; its just that it gives those warnings.
-
If you're building your project from the command line then you
need to set the environmental variables in either the global profile
file (located in /etc/profile) or the user .profile file (located in the users
home directory that is usually hidden, type 'ls -la' to show hidden files).The PATH environmental variable only tells the terminal where to
find other binary executables and should include the path to the
QT binaries.To find the libraries, I use the gcc environmental variable
LIBRARY_PATH set to all the locations where I've installed
libraries but I've also seen used LD_LIBRARY_PATH and
DYLD_LIBRARY_PATH to find libraries.Hope this has helped.
ASGR
-
Hi,
I "installed" Qt 4.7 SDK.mpkg bundle on snow 10.6.4 mac/ g++ gcc version 4.2.1.
I can run executables in Qt creator from other libraries, but when I am trying to install a light
viewer built on Qt I get 2 linker warnings by qmake, i.e.ld: warning: directory '/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib' following -L not found
ld: warning: directory '/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib' following -F not found
With qmake -query everything seems to be right, but qt installation seems broken.
qmake is there, but the lin dir in
/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib
has been removed.This seems like a bug to me (installing a lib in /tmp -> in a directory that is cleaned every time I reboot the machine??) 'n I have already filed it. Let me know if you have any hints,
cheers
-
For workaround please have a look at "QTBUG-13462":http://bugreports.qt.nokia.com/browse/QTBUG-13462
-
Con was right. I had another Qt installed via MacPorts that I've now uninstalled.
But I left earlier versions of Qt that were installed via MacPorts as a dependency for another ports,
ex. boost, cgal (libs rather complicated to build by source), since I don't want to destroy the dependencies. Do you think that this might cause the linker warnings above? I installed a Qt 4.7 SDK.mpkg bundle again, I executed the scripts at the bottom of http://bugreports.qt.nokia.com/browse/QTBUG-13462 , but I get the same warnings..cheers
-
This looks like a bug in qmake. It is used to build the Makefile for the project (you can find the -L option in the Makefile produced).
Looking at the qmake binary with:
% strings /usr/bin/qmake | grep qt-everywhere
produces lots of strings that begin with:
/tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0
If you want you could hand-edit the Makefile to remove this option from the link command. Alternatively:
% sudo mkdir -p /tmp/qt-stuff-6474/source/qt-everywhere-opensource-src-4.7.0/lib
will create the directory and silence the warning.