summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-09-08 17:54:55 (EDT)
committer P. J. McDermott <pjm@nac.net>2012-09-08 17:54:55 (EDT)
commitdbb1d617f03dd47c4cb4235f937e7560c3a0fd86 (patch)
treea0fe62cff267f55e2f68f1a6a12bce43df8d1f24
parent3f4979bfb07389b33d7a1d71ed02dc4a8aadf24c (diff)
Make the load module use common module's stack MM.
-rw-r--r--lib/load.sh15
1 files changed, 8 insertions, 7 deletions
diff --git a/lib/load.sh b/lib/load.sh
index 03438c1..f22e128 100644
--- a/lib/load.sh
+++ b/lib/load.sh
@@ -20,25 +20,26 @@
[ -n "${_OB_LOAD_SM}" ] && return 0
_OB_LOAD_SM='true'
+# The "common" module is used by this and all other modules.
+# We have to manually load the "common" module so we can use it in ob_use.
+. '@@LIBOPKBUILD@@/common.sm'
+
ob_use()
{
- _obu_module=
+ _ob_local _obu_module
if [ "${#}" -eq 1 ]; then
_obu_module="${1}"
else
- unset _obu_module
- return 125
+ return $(_ob_return 125)
fi
_obu_module='@@LIBOPKBUILD@@'"/${_obu_module}.sm"
if [ -r "${_obu_module}" ]; then
. "${_obu_module}"
else
- unset _obu_module
- return 1
+ return $(_ob_return 1)
fi
- unset _obu_module
- return 0
+ return $(_ob_return 0)
}