3 ## live-build(7) - System Build Scripts
4 ## Copyright (C) 2006-2013 Daniel Baumann <mail@daniel-baumann.ch>
6 ## This program comes with ABSOLUTELY NO WARRANTY; for details see COPYING.
7 ## This is free software, and you are welcome to redistribute it
8 ## under certain conditions; see COPYING for details.
17 FILE
="/var/lock/${PROGRAM}.lock"
23 Echo_error
"${PROGRAM} locked"
34 FILE
="/var/lock/${PROGRAM}.lock"
37 DIRECTORY
="$(dirname ${FILE})"
39 # Creating lock directory
40 mkdir
-p "${DIRECTORY}"
43 trap 'ret=${?}; '"rm -f \"${FILE}\";"' exit ${ret}' EXIT HUP INT QUIT TERM