summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/bb/main.py
diff options
context:
space:
mode:
Diffstat (limited to 'bitbake/lib/bb/main.py')
-rwxr-xr-xbitbake/lib/bb/main.py9
1 files changed, 6 insertions, 3 deletions
diff --git a/bitbake/lib/bb/main.py b/bitbake/lib/bb/main.py
index 6294b85cfd..1e38d04bcf 100755
--- a/bitbake/lib/bb/main.py
+++ b/bitbake/lib/bb/main.py
@@ -422,7 +422,7 @@ def setup_bitbake(configParams, extrafeatures=None):
422 retries = 8 422 retries = 8
423 while retries: 423 while retries:
424 try: 424 try:
425 topdir, lock = lockBitbake() 425 topdir, lock, lockfile = lockBitbake()
426 sockname = topdir + "/bitbake.sock" 426 sockname = topdir + "/bitbake.sock"
427 if lock: 427 if lock:
428 if configParams.status_only or configParams.kill_server: 428 if configParams.status_only or configParams.kill_server:
@@ -439,12 +439,15 @@ def setup_bitbake(configParams, extrafeatures=None):
439 logger.info("Reconnecting to bitbake server...") 439 logger.info("Reconnecting to bitbake server...")
440 if not os.path.exists(sockname): 440 if not os.path.exists(sockname):
441 logger.info("Previous bitbake instance shutting down?, waiting to retry... (%s)" % timestamp()) 441 logger.info("Previous bitbake instance shutting down?, waiting to retry... (%s)" % timestamp())
442 procs = bb.server.process.get_lockfile_process_msg(lockfile)
443 if procs:
444 logger.info("Processes holding bitbake.lock:\n%s" % procs)
442 i = 0 445 i = 0
443 lock = None 446 lock = None
444 # Wait for 5s or until we can get the lock 447 # Wait for 5s or until we can get the lock
445 while not lock and i < 50: 448 while not lock and i < 50:
446 time.sleep(0.1) 449 time.sleep(0.1)
447 _, lock = lockBitbake() 450 _, lock, _ = lockBitbake()
448 i += 1 451 i += 1
449 if lock: 452 if lock:
450 bb.utils.unlockfile(lock) 453 bb.utils.unlockfile(lock)
@@ -494,5 +497,5 @@ def lockBitbake():
494 bb.error("Unable to find conf/bblayers.conf or conf/bitbake.conf. BBPATH is unset and/or not in a build directory?") 497 bb.error("Unable to find conf/bblayers.conf or conf/bitbake.conf. BBPATH is unset and/or not in a build directory?")
495 raise BBMainFatal 498 raise BBMainFatal
496 lockfile = topdir + "/bitbake.lock" 499 lockfile = topdir + "/bitbake.lock"
497 return topdir, bb.utils.lockfile(lockfile, False, False) 500 return topdir, bb.utils.lockfile(lockfile, False, False), lockfile
498 501