From ce88f060c5f125b6835fd454f1e82d403e235e80 Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Fri, 28 Dec 2018 19:18:30 -0500 Subject: ob_reduce_deps(): Document --- (limited to 'lib') diff --git a/lib/deps.sh b/lib/deps.sh index 7a63a31..02bdf8c 100644 --- a/lib/deps.sh +++ b/lib/deps.sh @@ -184,6 +184,25 @@ ob_parse_dep() return 0 } +## @brief Reduce dependencies to a given architecture and platform +## @details \fBob_reduce_deps\fP reduces a list of dependencies to only those +## that apply to a given architecture and platform. A list is either a +## "normal" list or a "union" list. A normal list is an "AND" list +## composed of "OR" lists, which in turn are composed of simple +## dependencies. A union list is an AND list composed of only simple +## dependencies. That is, a normal list is of the form +## \fIdep\ |\ dep,\ dep\fP, and a union list is of the form +## \fIdep,\ dep\fP. The "Conflicts", "Provides", and "Replaces" +## package relationships are union lists. +## @option -a host_arch The architecture to which dependencies should be +## reduced. Required. +## @option -P host_plat The platform to which dependencies should be reduced. +## Required. +## @option -u - Treat \fIdeps\fP as a union list. +## @operand deps req The list of dependencies to reduce. +## @return Returns 0 on success or 125 on invalid option or missing \fIdeps\fP. +## @stdout Prints the reduced list of dependencies. +## @pure yes This function has no side effects. ob_reduce_deps() { local opt= -- cgit v0.9.1