kumquat-buildroot/package/qt5/qt5declarative/0002-examples-fix-parallel-install.patch

191 lines
7.8 KiB
Diff
Raw Normal View History

From ceccffbee9d674044641dd6a1010715b86eda254 Mon Sep 17 00:00:00 2001
From: Peter Seiderer <ps.report@gmx.net>
Date: Tue, 26 May 2020 20:16:44 +0200
Subject: [PATCH] examples: fix parallel install
Installing qt5declarative examples on fast/multicore machines sometimes
fails with a variation of the following error messages:
- Cannot touch [...]/chapter5-listproperties/app.qml: No such file or directory
- Error copying [...]/chapter2-methods/app.qml: Destination file exists
Fix it by using OTHER_FILES instead of a seperate qml files install target.
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
[Rebased for Qt5.15.0]
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
---
.../extending-qml/chapter1-basics/chapter1-basics.pro | 8 +++-----
.../extending-qml/chapter2-methods/chapter2-methods.pro | 8 +++-----
.../extending-qml/chapter3-bindings/chapter3-bindings.pro | 8 +++-----
.../chapter4-customPropertyTypes.pro | 8 +++-----
.../chapter5-listproperties/chapter5-listproperties.pro | 8 +++-----
examples/qmltest/qmltest/qmltest.pro | 7 ++++---
examples/quick/imageprovider/imageprovider.pro | 7 ++++---
.../quick/imageresponseprovider/imageresponseprovider.pro | 7 ++++---
.../quick/scenegraph/simplematerial/simplematerial.pro | 6 +++---
9 files changed, 30 insertions(+), 37 deletions(-)
diff --git a/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro b/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro
index 1f777d2e..7c50dc31 100644
--- a/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro
+++ b/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro
@@ -12,10 +12,8 @@ SOURCES += piechart.cpp \
RESOURCES += chapter1-basics.qrc
-DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter1-basics
-target.path = $$DESTPATH
+target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter1-basics
-qml.files = *.qml
-qml.path = $$DESTPATH
+OTHER_FILES += *.qml
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro b/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro
index 264f028f..8947b4e0 100644
--- a/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro
+++ b/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro
@@ -10,10 +10,8 @@ SOURCES += piechart.cpp \
RESOURCES += chapter2-methods.qrc
-DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter2-methods
-target.path = $$DESTPATH
+target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter2-methods
-qml.files = *.qml
-qml.path = $$DESTPATH
+OTHER_FILES += *.qml
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro b/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro
index 152f17ce..ffe632ee 100644
--- a/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro
+++ b/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro
@@ -10,10 +10,8 @@ SOURCES += piechart.cpp \
RESOURCES += chapter3-bindings.qrc
-DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter3-bindings
-target.path = $$DESTPATH
+target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter3-bindings
-qml.files = *.qml
-qml.path = $$DESTPATH
+OTHER_FILES += *.qml
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro b/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro
index e277f746..29911eae 100644
--- a/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro
+++ b/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro
@@ -12,10 +12,8 @@ SOURCES += piechart.cpp \
RESOURCES += chapter4-customPropertyTypes.qrc
-DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter4-customPropertyTypes
-target.path = $$DESTPATH
+target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter4-customPropertyTypes
-qml.files = *.qml
-qml.path = $$DESTPATH
+OTHER_FILES += *.qml
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro b/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro
index edbd3c23..0db640a7 100644
--- a/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro
+++ b/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro
@@ -12,10 +12,8 @@ SOURCES += piechart.cpp \
RESOURCES += chapter5-listproperties.qrc
-DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter5-listproperties
-target.path = $$DESTPATH
+target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter5-listproperties
-qml.files = *.qml
-qml.path = $$DESTPATH
+OTHER_FILES += *.qml
-INSTALLS += target qml
+INSTALLS += target
diff --git a/examples/qmltest/qmltest/qmltest.pro b/examples/qmltest/qmltest/qmltest.pro
index b5893c5a..bade497d 100644
--- a/examples/qmltest/qmltest/qmltest.pro
+++ b/examples/qmltest/qmltest/qmltest.pro
@@ -19,8 +19,9 @@ QT += qml qmltest
macx: CONFIG -= app_bundle
target.path = $$[QT_INSTALL_EXAMPLES]/qmltest/qmltest
-qml.files = tst_basic.qml tst_item.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/qmltest/qmltest
-INSTALLS += target qml
+
+OTHER_FILES += tst_basic.qml tst_item.qml
+
+INSTALLS += target
}
diff --git a/examples/quick/imageprovider/imageprovider.pro b/examples/quick/imageprovider/imageprovider.pro
index e54469b0..05938079 100644
--- a/examples/quick/imageprovider/imageprovider.pro
+++ b/examples/quick/imageprovider/imageprovider.pro
@@ -10,8 +10,9 @@ SOURCES += imageprovider.cpp
EXAMPLE_FILES = imageprovider-example.qml
target.path = $$[QT_INSTALL_EXAMPLES]/quick/imageprovider/ImageProviderCore
-qml.files = ImageProviderCore/qmldir
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/imageprovider/ImageProviderCore
-INSTALLS = target qml
+
+OTHER_FILES += ImageProviderCore/qmldir
+
+INSTALLS = target
CONFIG += install_ok # Do not cargo-cult this!
diff --git a/examples/quick/imageresponseprovider/imageresponseprovider.pro b/examples/quick/imageresponseprovider/imageresponseprovider.pro
index 8be4dbb6..678a6756 100644
--- a/examples/quick/imageresponseprovider/imageresponseprovider.pro
+++ b/examples/quick/imageresponseprovider/imageresponseprovider.pro
@@ -10,8 +10,9 @@ SOURCES += imageresponseprovider.cpp
EXAMPLE_FILES = imageresponseprovider-example.qml
target.path = $$[QT_INSTALL_EXAMPLES]/quick/imageresponseprovider/ImageResponseProviderCore
-qml.files = ImageResponseProviderCore/qmldir
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/imageresponseprovider/ImageResponseProviderCore
-INSTALLS = target qml
+
+OTHER_FILES += ImageResponseProviderCore/qmldir
+
+INSTALLS = target
CONFIG += install_ok # Do not cargo-cult this!
diff --git a/examples/quick/scenegraph/simplematerial/simplematerial.pro b/examples/quick/scenegraph/simplematerial/simplematerial.pro
index 131af459..76a21ab3 100644
--- a/examples/quick/scenegraph/simplematerial/simplematerial.pro
+++ b/examples/quick/scenegraph/simplematerial/simplematerial.pro
@@ -11,10 +11,10 @@ SOURCES += \
RESOURCES += simplematerial.qrc
target.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/simplematerial
-qml.files = main.qml
-qml.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/simplematerial
-INSTALLS += target qml
+OTHER_FILES += main.qml
+
+INSTALLS += target
HEADERS += \
simplematerialitem.h
--
2.26.2