Skip to contentSkip to conversation

qmake4_base.bbclass: Add staging directory for native builds

PATCH In review Donald R. Poole, Jr. 2 participants 5 messages Apr 30, 2014 – May 1, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 qmake4_base.bbclass: Add staging directory for native builds

From: "Donald R. Poole, Jr" <donald (dot) poole (at) swri (dot) org>

When building a basic Qt5 native application, the build fails on the do_install task as a result of the variable being empty. This causes the copy command in the test block to fail because it is trying to copy files from/to itself.

---
 classes/qmake5_base.bbclass |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
classes/qmake5_base.bbclass +1 -1
index 2db0fa3..18fdb2a 100644
@@ -171,7 +171,7 @@ qmake5_base_do_install() {
     # but we cannot remove sysroot override, because that's useful for pkg-config etc
     # In some cases like QtQmlDevTools in qtdeclarative, the sed above does not work,
     # fix them manually
-    if [ -d ${D}${STAGING_DIR_TARGET} ] ; then
+    if [ -d ${D}${STAGING_DIR_TARGET} ] && [ -n "${STAGING_DIR_TARGET}" ] ; then
         echo "Some files are installed in wrong directory ${D}${STAGING_DIR_TARGET}"
         cp -ra ${D}${STAGING_DIR_TARGET}/* ${D}
         rm -rf ${D}${STAGING_DIR_TARGET}
Signature · 1 line
1.7.9.5
#1 lore raw
Quoted 1 line · Jr.

From: "Donald R. Poole, Jr" <donald (dot) poole (at) swri (dot) org>

Did you send with git send-email?

The shortlog and code does not agree. You cite qt4 and change qt5 ;)

Quoted 26 lines

When building a basic Qt5 native application, the build fails on the do_install task as a result of the variable being empty. This causes the copy command in the test block to fail because it is trying to copy files from/to itself.

---
 classes/qmake5_base.bbclass |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
classes/qmake5_base.bbclass +1 -2
index 2db0fa3..18fdb2a 100644
@@ -171,7 +171,7 @@ qmake5_base_do_install() {
     # but we cannot remove sysroot override, because that's useful for pkg-config etc
     # In some cases like QtQmlDevTools in qtdeclarative, the sed above does not work,
     # fix them manually
-    if [ -d ${D}${STAGING_DIR_TARGET} ] ; then
+    if [ -d ${D}${STAGING_DIR_TARGET} ] && [ -n "${STAGING_DIR_TARGET}" ] ; then
         echo "Some files are installed in wrong directory ${D}${STAGING_DIR_TARGET}"
         cp -ra ${D}${STAGING_DIR_TARGET}/* ${D}
         rm -rf ${D}${STAGING_DIR_TARGET}
--

1.7.9.5

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

Signature · 3 lines
Otavio Salvador                             O.S. Systems
http://www.ossystems.com.br        http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854            Mobile: +1 (347) 903-9750
#2 lore raw

Sorry, I meant to say Qt5 to match the code.

Quoted 54 lines · Otavio Salvador
Quoted 1 line · Jr.

From: "Donald R. Poole, Jr" <donald (dot) poole (at) swri (dot) org>

Did you send with git send-email?

The shortlog and code does not agree. You cite qt4 and change qt5 ;)

Quoted 1 line

When building a basic Qt5 native application, the build fails on the

do_install task as a result of the variable being empty. This causes the copy command in the test block to fail because it is trying to copy files from/to itself.

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 171

Quoted 10 lines
---
 classes/qmake5_base.bbclass |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
classes/qmake5_base.bbclass +0 -0
index 2db0fa3..18fdb2a 100644
@@ -171,7 +171,7 @@ qmake5_base_do_install() {
     # but we cannot remove sysroot override, because that's useful for

pkg-config etc

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 172

Quoted 1 line
classes/qmake5_base.bbclass +0 -0
     # In some cases like QtQmlDevTools in qtdeclarative, the sed above

does not work,

classes/qmake5_base.bbclass qmake5_base_do_install() {

Quoted 3 lines
classes/qmake5_base.bbclass +1 -1
     # fix them manually
-    if [ -d ${D}${STAGING_DIR_TARGET} ] ; then
+    if [ -d ${D}${STAGING_DIR_TARGET} ] && [ -n "${STAGING_DIR_TARGET}"

] ; then

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 175

Quoted 1 line
classes/qmake5_base.bbclass +0 -0
         echo "Some files are installed in wrong directory

${D}${STAGING_DIR_TARGET}"

Quoted 10 lines
classes/qmake5_base.bbclass +0 -1
         cp -ra ${D}${STAGING_DIR_TARGET}/* ${D}
         rm -rf ${D}${STAGING_DIR_TARGET}
--

1.7.9.5

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.br http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854 Mobile: +1 (347) 903-9750
--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#3 lore raw
In reply to Otavio Salvador

And yes, I did send this with git send-email.

Quoted 54 lines · Otavio Salvador
Quoted 1 line · Jr.

From: "Donald R. Poole, Jr" <donald (dot) poole (at) swri (dot) org>

Did you send with git send-email?

The shortlog and code does not agree. You cite qt4 and change qt5 ;)

Quoted 1 line

When building a basic Qt5 native application, the build fails on the

do_install task as a result of the variable being empty. This causes the copy command in the test block to fail because it is trying to copy files from/to itself.

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 171

Quoted 10 lines
---
 classes/qmake5_base.bbclass |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
classes/qmake5_base.bbclass +0 -0
index 2db0fa3..18fdb2a 100644
@@ -171,7 +171,7 @@ qmake5_base_do_install() {
     # but we cannot remove sysroot override, because that's useful for

pkg-config etc

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 172

Quoted 1 line
classes/qmake5_base.bbclass +0 -0
     # In some cases like QtQmlDevTools in qtdeclarative, the sed above

does not work,

classes/qmake5_base.bbclass qmake5_base_do_install() {

Quoted 3 lines
classes/qmake5_base.bbclass +1 -1
     # fix them manually
-    if [ -d ${D}${STAGING_DIR_TARGET} ] ; then
+    if [ -d ${D}${STAGING_DIR_TARGET} ] && [ -n "${STAGING_DIR_TARGET}"

] ; then

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 175

Quoted 1 line
classes/qmake5_base.bbclass +0 -0
         echo "Some files are installed in wrong directory

${D}${STAGING_DIR_TARGET}"

Quoted 10 lines
classes/qmake5_base.bbclass +0 -1
         cp -ra ${D}${STAGING_DIR_TARGET}/* ${D}
         rm -rf ${D}${STAGING_DIR_TARGET}
--

1.7.9.5

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.br http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854 Mobile: +1 (347) 903-9750
--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#4 lore raw
In reply to Otavio Salvador

Disregard this patch. I'm sending another patch that should cover the native build case more completely.

Quoted 54 lines · Otavio Salvador
Quoted 1 line · Jr.

From: "Donald R. Poole, Jr" <donald (dot) poole (at) swri (dot) org>

Did you send with git send-email?

The shortlog and code does not agree. You cite qt4 and change qt5 ;)

Quoted 1 line

When building a basic Qt5 native application, the build fails on the

do_install task as a result of the variable being empty. This causes the copy command in the test block to fail because it is trying to copy files from/to itself.

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 171

Quoted 10 lines
---
 classes/qmake5_base.bbclass |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
classes/qmake5_base.bbclass +0 -0
index 2db0fa3..18fdb2a 100644
@@ -171,7 +171,7 @@ qmake5_base_do_install() {
     # but we cannot remove sysroot override, because that's useful for

pkg-config etc

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 172

Quoted 1 line
classes/qmake5_base.bbclass +0 -0
     # In some cases like QtQmlDevTools in qtdeclarative, the sed above

does not work,

classes/qmake5_base.bbclass qmake5_base_do_install() {

Quoted 3 lines
classes/qmake5_base.bbclass +1 -1
     # fix them manually
-    if [ -d ${D}${STAGING_DIR_TARGET} ] ; then
+    if [ -d ${D}${STAGING_DIR_TARGET} ] && [ -n "${STAGING_DIR_TARGET}"

] ; then

classes/qmake5_base.bbclass qmake5_base_do_install() { · line 175

Quoted 1 line
classes/qmake5_base.bbclass +0 -0
         echo "Some files are installed in wrong directory

${D}${STAGING_DIR_TARGET}"

Quoted 10 lines
classes/qmake5_base.bbclass +0 -1
         cp -ra ${D}${STAGING_DIR_TARGET}/* ${D}
         rm -rf ${D}${STAGING_DIR_TARGET}
--

1.7.9.5

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

--
Otavio Salvador O.S. Systems
http://www.ossystems.com.br http://code.ossystems.com.br
Mobile: +55 (53) 9981-7854 Mobile: +1 (347) 903-9750
--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel