summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-11-05 18:23:31 (EST)
committer P. J. McDermott <pjm@nac.net>2012-11-05 18:23:31 (EST)
commit6ac848d88f4b1ff0b0468fad041b86dcc8764363 (patch)
tree661fcebde7ae401667410481efb0297b91ed2a43 /lib
parent32a2c02e527b707e4279931bcc4beb1be4e35476 (diff)
Reduce platforms in ob_get_binary_packages().
Diffstat (limited to 'lib')
-rw-r--r--lib/package.sh13
1 files changed, 11 insertions, 2 deletions
diff --git a/lib/package.sh b/lib/package.sh
index 72ffd63..4b5ce6a 100644
--- a/lib/package.sh
+++ b/lib/package.sh
@@ -131,14 +131,18 @@ ob_parse_package_metadata()
ob_get_binary_packages()
{
- _ob_local _obgbpk_opt _obgbpk_host_arch _obgbpk_pkgs _obgbpk_pkg \
+ _ob_local _obgbpk_opt _obgbpk_host_arch _obgbpk_host_plat \
+ _obgbpk_pkgs _obgbpk_pkg \
_obgbpk_pkgs_clean _obgbpk_pkg_clean _obgbpk_orig_text_domain
- while getopts 'a:' _obgbpk_opt; do
+ while getopts 'a:P:' _obgbpk_opt; do
case "${_obgbpk_opt}" in
a)
_obgbpk_host_arch="${OPTARG}"
;;
+ P)
+ _obgbpk_host_plat="${OPTARG}"
+ ;;
?)
_ob_return 125
return ${?}
@@ -201,6 +205,11 @@ ob_get_binary_packages()
"${_obgbpk_pkg}" 'Architecture')"; then
continue
fi
+ if [ -n "${_obgbpk_host_plat}" ] && ! ob_plat_is_concerned \
+ "${_obgbpk_host_plat}" "$(ob_get_binary_parameter \
+ "${_obgbpk_pkg}" 'Platform')"; then
+ continue
+ fi
_obgbpk_pkgs="${_obgbpk_pkgs} ${_obgbpk_pkg}"
done