--- a/tools/userland-mangler Fri Oct 02 10:36:56 2015 -0700
+++ b/tools/userland-mangler Tue Oct 06 07:41:40 2015 -0700
@@ -290,6 +290,18 @@
for action in manifest.gen_actions_by_type("license"):
manifest.actions.remove(action)
+ # Check for pkg.obsolete and if found, remove any depend actions.
+ manifest_is_obsolete = False
+
+ for action in manifest.gen_actions_by_type("set"):
+ if (action.attrs["name"] == "pkg.obsolete" and
+ action.attrs["value"] == "true"):
+ manifest_is_obsolete = True
+
+ if manifest_is_obsolete:
+ for action in manifest.gen_actions_by_type("depend"):
+ manifest.actions.remove(action)
+
def load_manifest(manifest_file):
manifest = pkg.manifest.Manifest()
manifest.set_content(pathname=manifest_file)