#OpenPKG Add Environment
opa () {
root="$1"
if [ ! -d $root ]; then
  echo "opa:ERROR: OpenPKG root directory $root not found"
  return 1
fi
if [ ! -f "$root/etc/rc" ]; then
  echo "opa:ERROR: does not contain OpenPKG hierarchy"
  return 1
fi
eval `$root/etc/rc --eval all env`
}