'This checks constraints on common dependencies against each other.'

def satisfies_dependencies(self, other, strict=False):

    other = self._autospec(other)
    if strict:
        if (other._dependencies and (not self._dependencies)):
            return False
        selfdeps = self.traverse(root=False)
        otherdeps = other.traverse(root=False)
        if (not all((any((d.satisfies(dep) for d in selfdeps)) for dep in otherdeps))):
            return False
    elif ((not self._dependencies) or (not other._dependencies)):
        return True
    for name in self.common_dependencies(other):
        if (not self[name].satisfies(other[name], deps=False)):
            return False
    self_index = ProviderIndex(self.traverse(), restrict=True)
    other_index = ProviderIndex(other.traverse(), restrict=True)
    if (not self_index.satisfies(other_index)):
        return False
    for spec in self.virtual_dependencies():
        if ((spec.name in other_index) and (not other_index.providers_for(spec))):
            return False
    for spec in other.virtual_dependencies():
        if ((spec.name in self_index) and (not self_index.providers_for(spec))):
            return False
    return True
