summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta/classes/icecc.bbclass20
1 files changed, 7 insertions, 13 deletions
diff --git a/meta/classes/icecc.bbclass b/meta/classes/icecc.bbclass
index 73eba7a6a9..0ca8de86c2 100644
--- a/meta/classes/icecc.bbclass
+++ b/meta/classes/icecc.bbclass
@@ -366,20 +366,14 @@ set_icecc_env() {
366 366
367 # the ICECC_VERSION generation step must be locked by a mutex 367 # the ICECC_VERSION generation step must be locked by a mutex
368 # in order to prevent race conditions 368 # in order to prevent race conditions
369 exit_code=0 369 if flock -n "${ICECC_VERSION}.lock" \
370 flock -n -E 10 "${ICECC_VERSION}.lock" \ 370 ${ICECC_ENV_EXEC} ${ICECC_ENV_DEBUG} "${ICECC_CC}" "${ICECC_CXX}" "${ICECC_AS}" "${ICECC_VERSION}"
371 ${ICECC_ENV_EXEC} ${ICECC_ENV_DEBUG} "${ICECC_CC}" "${ICECC_CXX}" "${ICECC_AS}" "${ICECC_VERSION}" || exit_code=$? 371 then
372 if [ "$exit_code" -eq 0 ]; then
373 touch "${ICECC_VERSION}.done"
374 elif [ "$exit_code" -eq "10" ]; then
375 if [ ! wait_for_file "${ICECC_VERSION}.done" 30 ]; then
376 # locking failed so wait for ${ICECC_VERSION}.done to appear
377 bbwarn "Timeout waiting for ${ICECC_VERSION}.done"
378 return
379 fi
380 else
381 bbwarn "Could not create icecc environment: $exit_code"
382 touch "${ICECC_VERSION}.done" 372 touch "${ICECC_VERSION}.done"
373 elif [ ! wait_for_file "${ICECC_VERSION}.done" 30 ]
374 then
375 # locking failed so wait for ${ICECC_VERSION}.done to appear
376 bbwarn "Timeout waiting for ${ICECC_VERSION}.done"
383 return 377 return
384 fi 378 fi
385 fi 379 fi