diff options
author | Gunnar Sletta <gunnar.sletta@nokia.com> | 2011-09-13 08:54:45 +0200 |
---|---|---|
committer | Gunnar Sletta <gunnar.sletta@nokia.com> | 2011-09-13 08:54:45 +0200 |
commit | b62bd0584a7872b6917917009b707785b3abd077 (patch) | |
tree | 9981f274712c098cabbff0c4667672a3934e5393 /bin | |
parent | 5e10745dca1d10025404a9f268f03ae697fb10cc (diff) | |
parent | 97baad65f65783d2b5ff938f6217aec9434f2e5f (diff) |
Merge branch 'refactor'
Conflicts:
mkspecs/qws/linux-lsb-g++/qmake.conf
src/gui/image/qpixmap_mac.cpp
src/gui/painting/qpaintengine_x11.cpp
src/gui/painting/qtessellator.cpp
src/gui/text/qfontengine_qws.cpp
src/gui/text/qfontengine_x11.cpp
src/gui/widgets/qlinecontrol.cpp
src/opengl/qgl.h
src/opengl/qgl_x11egl.cpp
src/plugins/plugins.pro
Change-Id: If52dcd55cd55f2983a756c2f843967702b60a310
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/fixqt4headers | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/bin/fixqt4headers b/bin/fixqt4headers new file mode 100755 index 0000000000..58b0fdf43d --- /dev/null +++ b/bin/fixqt4headers @@ -0,0 +1,23 @@ +#!/bin/bash + +modules=`ls $QTDIR/include` + +files=`find * -name '*.h' -or -name '*.cpp' -or -name '*.C' -or -name '*.cc' -or -name '*.CC'` + +echo $files + +for module in $modules; do +# once we change other things, change the line from == "QtWidgets" to != "Qt" to get everything fixed + if [ $module == "QtWidgets" ] || [ $module == "QtPrintSupport" ]; then + echo $module ":" + includes=`ls $QTDIR/include/$module` + for i in $includes; do +# echo " fixing " $i + perl -pi -e "s,^#include +<.+/$i>,#include <$module/$i>," $files; +# perl -pi -e 's,^#include +".+/$i",#include "$module/$i",' $files; + done; + fi; +done; + +perl -pi -e 's,<QtGui>,<QtWidgets>,' $files +perl -pi -e 's,<QtGui/QtGui>,<QtWidgets/QtWidgets>,' $files |