0002-examples-fix-parallel-install.patch 7.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190
  1. From ceccffbee9d674044641dd6a1010715b86eda254 Mon Sep 17 00:00:00 2001
  2. From: Peter Seiderer <ps.report@gmx.net>
  3. Date: Tue, 26 May 2020 20:16:44 +0200
  4. Subject: [PATCH] examples: fix parallel install
  5. Installing qt5declarative examples on fast/multicore machines sometimes
  6. fails with a variation of the following error messages:
  7. - Cannot touch [...]/chapter5-listproperties/app.qml: No such file or directory
  8. - Error copying [...]/chapter2-methods/app.qml: Destination file exists
  9. Fix it by using OTHER_FILES instead of a seperate qml files install target.
  10. Signed-off-by: Peter Seiderer <ps.report@gmx.net>
  11. [Rebased for Qt5.15.0]
  12. Signed-off-by: Peter Seiderer <ps.report@gmx.net>
  13. ---
  14. .../extending-qml/chapter1-basics/chapter1-basics.pro | 8 +++-----
  15. .../extending-qml/chapter2-methods/chapter2-methods.pro | 8 +++-----
  16. .../extending-qml/chapter3-bindings/chapter3-bindings.pro | 8 +++-----
  17. .../chapter4-customPropertyTypes.pro | 8 +++-----
  18. .../chapter5-listproperties/chapter5-listproperties.pro | 8 +++-----
  19. examples/qmltest/qmltest/qmltest.pro | 7 ++++---
  20. examples/quick/imageprovider/imageprovider.pro | 7 ++++---
  21. .../quick/imageresponseprovider/imageresponseprovider.pro | 7 ++++---
  22. .../quick/scenegraph/simplematerial/simplematerial.pro | 6 +++---
  23. 9 files changed, 30 insertions(+), 37 deletions(-)
  24. diff --git a/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro b/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro
  25. index 1f777d2e..7c50dc31 100644
  26. --- a/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro
  27. +++ b/examples/qml/tutorials/extending-qml/chapter1-basics/chapter1-basics.pro
  28. @@ -12,10 +12,8 @@ SOURCES += piechart.cpp \
  29. RESOURCES += chapter1-basics.qrc
  30. -DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter1-basics
  31. -target.path = $$DESTPATH
  32. +target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter1-basics
  33. -qml.files = *.qml
  34. -qml.path = $$DESTPATH
  35. +OTHER_FILES += *.qml
  36. -INSTALLS += target qml
  37. +INSTALLS += target
  38. diff --git a/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro b/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro
  39. index 264f028f..8947b4e0 100644
  40. --- a/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro
  41. +++ b/examples/qml/tutorials/extending-qml/chapter2-methods/chapter2-methods.pro
  42. @@ -10,10 +10,8 @@ SOURCES += piechart.cpp \
  43. RESOURCES += chapter2-methods.qrc
  44. -DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter2-methods
  45. -target.path = $$DESTPATH
  46. +target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter2-methods
  47. -qml.files = *.qml
  48. -qml.path = $$DESTPATH
  49. +OTHER_FILES += *.qml
  50. -INSTALLS += target qml
  51. +INSTALLS += target
  52. diff --git a/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro b/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro
  53. index 152f17ce..ffe632ee 100644
  54. --- a/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro
  55. +++ b/examples/qml/tutorials/extending-qml/chapter3-bindings/chapter3-bindings.pro
  56. @@ -10,10 +10,8 @@ SOURCES += piechart.cpp \
  57. RESOURCES += chapter3-bindings.qrc
  58. -DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter3-bindings
  59. -target.path = $$DESTPATH
  60. +target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter3-bindings
  61. -qml.files = *.qml
  62. -qml.path = $$DESTPATH
  63. +OTHER_FILES += *.qml
  64. -INSTALLS += target qml
  65. +INSTALLS += target
  66. diff --git a/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro b/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro
  67. index e277f746..29911eae 100644
  68. --- a/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro
  69. +++ b/examples/qml/tutorials/extending-qml/chapter4-customPropertyTypes/chapter4-customPropertyTypes.pro
  70. @@ -12,10 +12,8 @@ SOURCES += piechart.cpp \
  71. RESOURCES += chapter4-customPropertyTypes.qrc
  72. -DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter4-customPropertyTypes
  73. -target.path = $$DESTPATH
  74. +target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter4-customPropertyTypes
  75. -qml.files = *.qml
  76. -qml.path = $$DESTPATH
  77. +OTHER_FILES += *.qml
  78. -INSTALLS += target qml
  79. +INSTALLS += target
  80. diff --git a/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro b/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro
  81. index edbd3c23..0db640a7 100644
  82. --- a/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro
  83. +++ b/examples/qml/tutorials/extending-qml/chapter5-listproperties/chapter5-listproperties.pro
  84. @@ -12,10 +12,8 @@ SOURCES += piechart.cpp \
  85. RESOURCES += chapter5-listproperties.qrc
  86. -DESTPATH = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter5-listproperties
  87. -target.path = $$DESTPATH
  88. +target.path = $$[QT_INSTALL_EXAMPLES]/qml/tutorials/extending-qml/chapter5-listproperties
  89. -qml.files = *.qml
  90. -qml.path = $$DESTPATH
  91. +OTHER_FILES += *.qml
  92. -INSTALLS += target qml
  93. +INSTALLS += target
  94. diff --git a/examples/qmltest/qmltest/qmltest.pro b/examples/qmltest/qmltest/qmltest.pro
  95. index b5893c5a..bade497d 100644
  96. --- a/examples/qmltest/qmltest/qmltest.pro
  97. +++ b/examples/qmltest/qmltest/qmltest.pro
  98. @@ -19,8 +19,9 @@ QT += qml qmltest
  99. macx: CONFIG -= app_bundle
  100. target.path = $$[QT_INSTALL_EXAMPLES]/qmltest/qmltest
  101. -qml.files = tst_basic.qml tst_item.qml
  102. -qml.path = $$[QT_INSTALL_EXAMPLES]/qmltest/qmltest
  103. -INSTALLS += target qml
  104. +
  105. +OTHER_FILES += tst_basic.qml tst_item.qml
  106. +
  107. +INSTALLS += target
  108. }
  109. diff --git a/examples/quick/imageprovider/imageprovider.pro b/examples/quick/imageprovider/imageprovider.pro
  110. index e54469b0..05938079 100644
  111. --- a/examples/quick/imageprovider/imageprovider.pro
  112. +++ b/examples/quick/imageprovider/imageprovider.pro
  113. @@ -10,8 +10,9 @@ SOURCES += imageprovider.cpp
  114. EXAMPLE_FILES = imageprovider-example.qml
  115. target.path = $$[QT_INSTALL_EXAMPLES]/quick/imageprovider/ImageProviderCore
  116. -qml.files = ImageProviderCore/qmldir
  117. -qml.path = $$[QT_INSTALL_EXAMPLES]/quick/imageprovider/ImageProviderCore
  118. -INSTALLS = target qml
  119. +
  120. +OTHER_FILES += ImageProviderCore/qmldir
  121. +
  122. +INSTALLS = target
  123. CONFIG += install_ok # Do not cargo-cult this!
  124. diff --git a/examples/quick/imageresponseprovider/imageresponseprovider.pro b/examples/quick/imageresponseprovider/imageresponseprovider.pro
  125. index 8be4dbb6..678a6756 100644
  126. --- a/examples/quick/imageresponseprovider/imageresponseprovider.pro
  127. +++ b/examples/quick/imageresponseprovider/imageresponseprovider.pro
  128. @@ -10,8 +10,9 @@ SOURCES += imageresponseprovider.cpp
  129. EXAMPLE_FILES = imageresponseprovider-example.qml
  130. target.path = $$[QT_INSTALL_EXAMPLES]/quick/imageresponseprovider/ImageResponseProviderCore
  131. -qml.files = ImageResponseProviderCore/qmldir
  132. -qml.path = $$[QT_INSTALL_EXAMPLES]/quick/imageresponseprovider/ImageResponseProviderCore
  133. -INSTALLS = target qml
  134. +
  135. +OTHER_FILES += ImageResponseProviderCore/qmldir
  136. +
  137. +INSTALLS = target
  138. CONFIG += install_ok # Do not cargo-cult this!
  139. diff --git a/examples/quick/scenegraph/simplematerial/simplematerial.pro b/examples/quick/scenegraph/simplematerial/simplematerial.pro
  140. index 131af459..76a21ab3 100644
  141. --- a/examples/quick/scenegraph/simplematerial/simplematerial.pro
  142. +++ b/examples/quick/scenegraph/simplematerial/simplematerial.pro
  143. @@ -11,10 +11,10 @@ SOURCES += \
  144. RESOURCES += simplematerial.qrc
  145. target.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/simplematerial
  146. -qml.files = main.qml
  147. -qml.path = $$[QT_INSTALL_EXAMPLES]/quick/scenegraph/simplematerial
  148. -INSTALLS += target qml
  149. +OTHER_FILES += main.qml
  150. +
  151. +INSTALLS += target
  152. HEADERS += \
  153. simplematerialitem.h
  154. --
  155. 2.26.2