[bin] update buildrc, add eit() wrapper

Also wrap eit around the rsync snapshot locks
This commit is contained in:
Fabio Erculiani 2012-09-08 17:32:36 +02:00
parent 0d5022345f
commit 2d8b8681be

View File

@ -1,6 +1,7 @@
#!/bin/bash
# Emerge wrapper, uses matter lock file support to avoid # Emerge wrapper, uses matter lock file support to avoid
# concurrent execution # concurrent execution
emerge() { _exec_locked() {
snapshot_lock_file="/var/tmp/.emerge.snapshot.lock" snapshot_lock_file="/var/tmp/.emerge.snapshot.lock"
matter_lock_file="/var/tmp/.matter_resource.lock" matter_lock_file="/var/tmp/.matter_resource.lock"
@ -29,9 +30,19 @@ emerge() {
} }
# eval $(portageq envvar -v FETCHCOMMAND RESUMECOMMAND PORTAGE_RSYNC_OPTS) # eval $(portageq envvar -v FETCHCOMMAND RESUMECOMMAND PORTAGE_RSYNC_OPTS)
# add bandwidth limit here # add bandwidth limit here
/usr/bin/emerge --quiet-build=n "$@" "${@}"
exit ${?} exit ${?}
) 9> "${snapshot_lock_file}" ) 9> "${snapshot_lock_file}"
return "${?}" return "${?}"
fi fi
} }
emerge() {
_exec_locked "/usr/bin/emerge" "${@}"
return ${?}
}
eit() {
_exec_locked "/usr/bin/eit" "${@}"
return ${?}
}