summaryrefslogtreecommitdiff
path: root/functions/packageslists.sh
diff options
context:
space:
mode:
authorDaniel Baumann <daniel@debian.org>2010-09-07 15:11:20 +0200
committerDaniel Baumann <daniel@debian.org>2011-03-09 19:17:21 +0100
commit83bc63f725263c571094e3af1c88c58992bf0ac6 (patch)
tree25be3b96127e122c9f1448f6155dea6b03293248 /functions/packageslists.sh
parent293765885126c0fe429718f403be2802a225cd68 (diff)
downloadlive-build-83bc63f725263c571094e3af1c88c58992bf0ac6.zip
live-build-83bc63f725263c571094e3af1c88c58992bf0ac6.tar.gz
Updating internal variables from lh to lb scheme, should be the last piece to finish the live-helper to live-build rename.
Diffstat (limited to 'functions/packageslists.sh')
-rwxr-xr-xfunctions/packageslists.sh62
1 files changed, 31 insertions, 31 deletions
diff --git a/functions/packageslists.sh b/functions/packageslists.sh
index 6510d27..6095f3f 100755
--- a/functions/packageslists.sh
+++ b/functions/packageslists.sh
@@ -10,89 +10,89 @@
Expand_packagelist ()
{
- _LH_EXPAND_QUEUE="$(basename "${1}")"
+ _LB_EXPAND_QUEUE="$(basename "${1}")"
shift
- while [ -n "${_LH_EXPAND_QUEUE}" ]
+ while [ -n "${_LB_EXPAND_QUEUE}" ]
do
- _LH_LIST_NAME="$(echo ${_LH_EXPAND_QUEUE} | cut -d" " -f1)"
- _LH_EXPAND_QUEUE="$(echo ${_LH_EXPAND_QUEUE} | cut -s -d" " -f2-)"
- _LH_LIST_LOCATION=""
- _LH_NESTED=0
- _LH_ENABLED=1
+ _LB_LIST_NAME="$(echo ${_LB_EXPAND_QUEUE} | cut -d" " -f1)"
+ _LB_EXPAND_QUEUE="$(echo ${_LB_EXPAND_QUEUE} | cut -s -d" " -f2-)"
+ _LB_LIST_LOCATION=""
+ _LB_NESTED=0
+ _LB_ENABLED=1
- for _LH_SEARCH_PATH in ${@} "${LH_BASE:-/usr/share/live/build}/lists"
+ for _LB_SEARCH_PATH in ${@} "${LB_BASE:-/usr/share/live/build}/lists"
do
- if [ -e "${_LH_SEARCH_PATH}/${_LH_LIST_NAME}" ]
+ if [ -e "${_LB_SEARCH_PATH}/${_LB_LIST_NAME}" ]
then
- _LH_LIST_LOCATION="${_LH_SEARCH_PATH}/${_LH_LIST_NAME}"
+ _LB_LIST_LOCATION="${_LB_SEARCH_PATH}/${_LB_LIST_NAME}"
break
fi
done
- if [ -z "${_LH_LIST_LOCATION}" ]
+ if [ -z "${_LB_LIST_LOCATION}" ]
then
- echo "W: Unknown package list '${_LH_LIST_NAME}'" >&2
+ echo "W: Unknown package list '${_LB_LIST_NAME}'" >&2
continue
fi
- while read _LH_LINE
+ while read _LB_LINE
do
- case "${_LH_LINE}" in
+ case "${_LB_LINE}" in
\#if\ *)
- if [ ${_LH_NESTED} -eq 1 ]
+ if [ ${_LB_NESTED} -eq 1 ]
then
echo "E: Nesting conditionals is not supported" >&2
exit 1
fi
- _LH_NESTED=1
+ _LB_NESTED=1
- _LH_NEEDLE="$(echo "${_LH_LINE}" | cut -d' ' -f3-)"
- _LH_HAYSTACK="$(eval "echo \$LH_$(echo "${_LH_LINE}" | cut -d' ' -f2)")"
+ _LB_NEEDLE="$(echo "${_LB_LINE}" | cut -d' ' -f3-)"
+ _LB_HAYSTACK="$(eval "echo \$LB_$(echo "${_LB_LINE}" | cut -d' ' -f2)")"
- _LH_ENABLED=0
- for _LH_NEEDLE_PART in ${_LH_NEEDLE}
+ _LB_ENABLED=0
+ for _LB_NEEDLE_PART in ${_LB_NEEDLE}
do
- for _LH_HAYSTACK_PART in ${_LH_HAYSTACK}
+ for _LB_HAYSTACK_PART in ${_LB_HAYSTACK}
do
- if [ "${_LH_NEEDLE_PART}" = "${_LH_HAYSTACK_PART}" ]
+ if [ "${_LB_NEEDLE_PART}" = "${_LB_HAYSTACK_PART}" ]
then
- _LH_ENABLED=1
+ _LB_ENABLED=1
fi
done
done
;;
\#endif*)
- _LH_NESTED=0
- _LH_ENABLED=1
+ _LB_NESTED=0
+ _LB_ENABLED=1
;;
\#*)
- if [ ${_LH_ENABLED} -ne 1 ]
+ if [ ${_LB_ENABLED} -ne 1 ]
then
continue
fi
# Find includes
- _LH_INCLUDES="$(echo "${_LH_LINE}" | sed -n \
+ _LB_INCLUDES="$(echo "${_LB_LINE}" | sed -n \
-e 's|^#<include> \([^ ]*\)|\1|gp' \
-e 's|^#include <\([^ ]*\)>|\1|gp')"
# Add to queue
- _LH_EXPAND_QUEUE="$(echo ${_LH_EXPAND_QUEUE} ${_LH_INCLUDES} |
+ _LB_EXPAND_QUEUE="$(echo ${_LB_EXPAND_QUEUE} ${_LB_INCLUDES} |
sed -e 's|[ ]*$||' -e 's|^[ ]*||')"
;;
*)
- if [ ${_LH_ENABLED} -eq 1 ]
+ if [ ${_LB_ENABLED} -eq 1 ]
then
- echo "${_LH_LINE}"
+ echo "${_LB_LINE}"
fi
;;
esac
- done < "${_LH_LIST_LOCATION}"
+ done < "${_LB_LIST_LOCATION}"
done
}