Building 5.2 (stable) with libc++ for c++11 support?
-
Hi,
It should be set in the macx-ios-clang mkspec
-
Thanks SGaist. I seem to have gotten it working by adding "c++11" to the "CONFIG +=" line in qtbase/mkspecs/macx-ios-clang/qmake.conf.
This should be the default, as libc++ is now the default for iOS and the provided libstdc++ is old and doesn't include c++11 support. Should this be a bug report?
-
Before that you should ask on the interest mailing list, you'll find Qt's developers/maintainers there (this forum is more user oriented). Don't forget to subscribe first.
-
So was the solution to recompile Qt for iOS with c++11 using the method that rosetter described (modifying the qtbase/mkspecs/macx-ios-clang/qmake.conf file)?
-
[quote author="kersson" date="1392188702"]So was the solution to recompile Qt for iOS with c++11 using the method that rosetter described (modifying the qtbase/mkspecs/macx-ios-clang/qmake.conf file)?[/quote]
yes, that's what works for me.
-
Hi rosetter,
I have changed the qmake.conf in the way you described. But after a configure the line which shows the C++11 support says no.
"see":http://qt-project.org/forums/viewthread/38373/#162619
Will it work yet?
-
kortus, even though the line says C++11...no, it is actually enabled. I confirmed that after making the change to the mkspec and compiling Qt for iOS, I was able to compile and deploy projects with CONFIG += c++11 for both simulator and device.
However, I'm still working on a solving a "semi-related issue.":http://qt-project.org/forums/viewthread/38541/
Let me know if you have any thoughts :)
-
kersson, you are right, it works.
-
Hi rosetter,
Could you please provide us the steps for doing the Qt compilation?
Thanks
-
Hi SGaist,
Is there any information about the compilation steps of the Qt provided at http://qt-project.org/downloads?
Thanks
-
Hi,
Do you mean the exact parameter they use ?
Personally I used the line provided "here":http://qt-project.org/doc/qt-5/building-from-source-ios.html
-
SGaist, thanks for replying.
Yes, I meant that (Sorry for my english).
What if I want to build all the Qt "products" included in the download page?
I want to build them in the same way (exact the same) as Qt does.My question is: what are the parameters (to the configure script) used by Qt for the products provided in the download page?
Is there any information about this?I have another doubt:
I checked the file:
5.3/ios/mkspecs/macx-ios-clang/qmake.confthat includes:
5.3/ios/mkspecs/common/clang-mac.confIn the last file, the following is specified:
QMAKE_CXXFLAGS_CXX11 += -stdlib=libc++
QMAKE_LFLAGS_CXX11 += -stdlib=libc++(This is the same for Qt5.2)
According to what I understand, Qt 5.2 and 5.3 (ios) are compiled to use LibC++.
I do not understand why it is not.Thanks!
Fernando. -
You have that "wiki entry":http://qt-project.org/wiki/Building-Qt-Package that explains how.
I don't understand your last question. Since 5.2, they do use libc++