Root and QT on MacOS

I wonder if anyone has successfully installed both QT and Root on MacOS 10.8? I have compiled QT from source (and also installed using Homebrew) which by default is compiled using “frameworks” option. This means that the QT libraries (libQtCore, libQtGui etc) are installed in directories such as /usr/local/qt/4.8.4/lib/QtCore.framework or /usr/local/qt/4.8.4/lib/QtGui.framework and so on.

The ROOT configure script (run with “–qt-enabled”) assumes that all the QT libraries are all in one directory, i.e. something like /usr/local/qt/4.8.4/lib. However this is not the case and I assume that to make my QT install work with the root configuration script, I will need to add code to the root configuration script OR recompile QT with the “–no-frameworks” option?

I wonder if anyone can assist or has dealt with this issue previously.

Regards, Nick.

Yes, I believe there is the RootForum thread on this issue. I’ll try to find it later.
What is your problem?

Did you read and try: … complement . It should work for MacOS too.

Yes I have read the attached link and I have performed the compilation. I have made a very simple Qt app and added a QWidget that I have promoted to TQtWidget. When I do this and compile my Qt example I get the following error:-

QWidget: Must construct a QApplication before a QPaintDevice

I do not have the same problem running the same Qt example compiled on Ubuntu Linux, but I simply cannot get the code to compile on MacOS. I have googled around for the above error, and it does seem to be a problem that is specific to Qt (not a Root problem) particularly on the MacOS platform… with a number of people alluding to a conflict between debug and release libraries.


[quote]but I simply cannot get the code to compile on MacOS. [/quote]The message you posted is the “run-time” message. It is not the compilation error. Can you show us compilation error?

[quote] compile my Qt example
[/quote] Well the first question is, "Did the Qt test suit work for you?"
The second question is, "Can you send me your “example” to reproduce ? (You can use the ‘Private message’ if you want.)