summaryrefslogtreecommitdiffstats
path: root/configure
diff options
context:
space:
mode:
Diffstat (limited to 'configure')
-rwxr-xr-xconfigure45
1 files changed, 31 insertions, 14 deletions
diff --git a/configure b/configure
index a3542bbd2e..744d1e5bb1 100755
--- a/configure
+++ b/configure
@@ -2389,13 +2389,6 @@ fi
if [ "$OPT_SHADOW" = "yes" ]; then
echo "Preparing build tree..."
- if [ -z "$PERL" ]; then
- echo
- echo "You need perl in your PATH to make a shadow build."
- echo "Cannot proceed."
- exit 1
- fi
-
[ -d "$outpath/bin" ] || mkdir -p "$outpath/bin"
# save a pre-existing mkspecs/modules dir
@@ -3918,7 +3911,14 @@ fi
# -----------------------------------------------------------------------------
# symlink includes
-if [ -n "$PERL" ] && [ -x "$relpath/bin/syncqt.pl" ]; then
+if [ -e "$relpath/.git" ]; then
+ if [ -z "$PERL" ]; then
+ echo
+ echo "You need perl in your PATH to make a build from GIT."
+ echo "Cannot proceed."
+ exit 1
+ fi
+
"$relpath/bin/syncqt.pl" -minimal -module QtCore "$relpath" || exit 1
fi
@@ -4051,6 +4051,11 @@ if true; then ###[ '!' -f "$outpath/bin/qmake" ];
echo "BUILD_PATH = $adjoutpath" >> "$mkfile"
echo "SOURCE_PATH = $adjrelpath" >> "$mkfile"
+ if [ -e "$relpath/.git" ]; then
+ echo 'INC_PATH = $(BUILD_PATH)/include' >> "$mkfile"
+ else
+ echo 'INC_PATH = $(SOURCE_PATH)/include' >> "$mkfile"
+ fi
echo "QMAKESPEC = $adjqmakespec" >> "$mkfile"
echo "QT_VERSION = $QT_VERSION" >> "$mkfile"
echo "EXTRA_CFLAGS = $EXTRA_CFLAGS" >> "$mkfile"
@@ -6438,12 +6443,24 @@ echo "#define QT_QPA_DEFAULT_PLATFORM_NAME \"$QT_QPA_DEFAULT_PLATFORM\"" >>"$out
if cmp -s "$outpath/src/corelib/global/qconfig.h" "$outpath/src/corelib/global/qconfig.h.new"; then
rm -f "$outpath/src/corelib/global/qconfig.h.new"
else
- [ -f "$outpath/src/corelib/global/qconfig.h" ] && chmod +w "$outpath/src/corelib/global/qconfig.h"
- mv "$outpath/src/corelib/global/qconfig.h.new" "$outpath/src/corelib/global/qconfig.h"
- chmod -w "$outpath/src/corelib/global/qconfig.h"
- if [ ! -f "$outpath/include/QtCore/qconfig.h" ]; then
- ln -s "$outpath/src/corelib/global/qconfig.h" "$outpath/include/QtCore/qconfig.h"
- fi
+ mv -f "$outpath/src/corelib/global/qconfig.h.new" "$outpath/src/corelib/global/qconfig.h"
+fi
+
+# create a forwarding header
+mkdir -p "$outpath/include/QtCore" || exit
+echo '#include "../../src/corelib/global/qconfig.h"' > $outpath/include/QtCore/qconfig.h.new
+if cmp -s "$outpath/include/QtCore/qconfig.h.new" "$outpath/include/QtCore/qconfig.h"; then
+ rm -f "$outpath/include/QtCore/qconfig.h.new"
+else
+ mv "$outpath/include/QtCore/qconfig.h.new" "$outpath/include/QtCore/qconfig.h" || exit
+fi
+
+# create a camelcase forwarding header
+echo '#include "qconfig.h"' > $outpath/include/QtCore/QtConfig.new
+if cmp -s "$outpath/include/QtCore/QtConfig.new" "$outpath/include/QtCore/QtConfig"; then
+ rm -f "$outpath/include/QtCore/QtConfig.new"
+else
+ mv "$outpath/include/QtCore/QtConfig.new" "$outpath/include/QtCore/QtConfig" || exit
fi
#-------------------------------------------------------------------------------