[oe-commits] [openembedded-core] 04/07: Revert "icecc.bbclass: Improve error reporting"

git at git.openembedded.org git at git.openembedded.org
Mon Apr 23 10:15:37 UTC 2018


This is an automated email from the git hooks/post-receive script.

rpurdie pushed a commit to branch sumo-next
in repository openembedded-core.

commit 802a2877a78a44c17f3e142f7d12017a08d09dad
Author: Joshua Watt <jpewhacker at gmail.com>
AuthorDate: Fri Apr 20 08:54:06 2018 -0500

    Revert "icecc.bbclass: Improve error reporting"
    
    This reverts commit b28114cf1e58643bd233bc0c83d6d8138952b7ac.
    
    The "-E" option for flock is not ubiquitously supported, so don't use
    it.
    
    Signed-off-by: Joshua Watt <JPEWhacker at gmail.com>
    Signed-off-by: Ross Burton <ross.burton at intel.com>
---
 meta/classes/icecc.bbclass | 20 +++++++-------------
 1 file changed, 7 insertions(+), 13 deletions(-)

diff --git a/meta/classes/icecc.bbclass b/meta/classes/icecc.bbclass
index 73eba7a..0ca8de8 100644
--- a/meta/classes/icecc.bbclass
+++ b/meta/classes/icecc.bbclass
@@ -366,20 +366,14 @@ set_icecc_env() {
 
         # the ICECC_VERSION generation step must be locked by a mutex
         # in order to prevent race conditions
-        exit_code=0
-        flock -n -E 10 "${ICECC_VERSION}.lock" \
-            ${ICECC_ENV_EXEC} ${ICECC_ENV_DEBUG} "${ICECC_CC}" "${ICECC_CXX}" "${ICECC_AS}" "${ICECC_VERSION}" || exit_code=$?
-        if [ "$exit_code" -eq 0 ]; then
-            touch "${ICECC_VERSION}.done"
-        elif [ "$exit_code" -eq "10" ]; then
-            if [ ! wait_for_file "${ICECC_VERSION}.done" 30 ]; then
-                # locking failed so wait for ${ICECC_VERSION}.done to appear
-                bbwarn "Timeout waiting for ${ICECC_VERSION}.done"
-                return
-            fi
-        else
-            bbwarn "Could not create icecc environment: $exit_code"
+        if flock -n "${ICECC_VERSION}.lock" \
+            ${ICECC_ENV_EXEC} ${ICECC_ENV_DEBUG} "${ICECC_CC}" "${ICECC_CXX}" "${ICECC_AS}" "${ICECC_VERSION}"
+        then
             touch "${ICECC_VERSION}.done"
+        elif [ ! wait_for_file "${ICECC_VERSION}.done" 30 ]
+        then
+            # locking failed so wait for ${ICECC_VERSION}.done to appear
+            bbwarn "Timeout waiting for ${ICECC_VERSION}.done"
             return
         fi
     fi

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Openembedded-commits mailing list