make-rules/ips.mk
changeset 1238 fb93a6ad84e5
parent 1235 413599fe2d31
child 1416 a87a9e85090e
--- a/make-rules/ips.mk	Fri Mar 29 17:28:20 2013 +0000
+++ b/make-rules/ips.mk	Fri Mar 29 14:29:29 2013 -0700
@@ -245,17 +245,17 @@
 # These files should contain a list of packages that the component is known to
 # depend on.  Using resolve.deps is not required, but significantly speeds up
 # the "pkg resolve" step.
-EXTDEPFILES = $(wildcard $(addsuffix resolve.deps, $(subst build/, , $(dir $(DEPENDED)))))
+EXTDEPFILES = $(wildcard $(sort $(addsuffix ../resolve.deps, $(dir $(DEPENDED)))))
 
 # This is a target that should only be run by hand, and not something that
 # .resolved-$(MACH) should depend on.
 sample-resolve.deps:
-	echo "<transform depend type=require -> print %(fmri)>" > rd-trans
+	echo "<transform depend type=(require|require-any) -> print %(fmri)>" > rd-trans
 	for i in build/*.depend; do \
-		$(PKGMOGRIFY) -O /dev/null $$i rd-trans | sort -u > m1; \
-		$(PKGMOGRIFY) -O /dev/null $$i.res rd-trans | sort -u > m2; \
+		$(PKGMOGRIFY) -O /dev/null $$i rd-trans | tr " " "\n" | sort -u > m1; \
+		$(PKGMOGRIFY) -O /dev/null $$i.res rd-trans | tr " " "\n" | sort -u > m2; \
 		comm -13 m1 m2; \
-	done | sed -e 's/@.*//' -e 's,^pkg:/,,' | sort -u > resolve.deps
+	done | sed -e 's/@[^ ]*//g' -e 's,pkg:/,,g' | sort -u > resolve.deps
 	$(RM) rd-trans m1 m2
 	if [[ ! -s resolve.deps ]]; then \
 		echo "No computed dependencies found; removing empty resolve.deps."; \