Following up on semarie's bug report, only try to chown to the group obj
if this call is going to succeed. So that the bsd.prog.mk infrastructure
can be used by all users independently of they belong to wobj or not.

Index: share/mk/bsd.obj.mk
===================================================================
RCS file: /var/cvs/src/share/mk/bsd.obj.mk,v
retrieving revision 1.16
diff -u -p -r1.16 bsd.obj.mk
--- share/mk/bsd.obj.mk 19 Nov 2016 14:20:58 -0000      1.16
+++ share/mk/bsd.obj.mk 21 Jan 2017 03:42:57 -0000
@@ -27,7 +27,7 @@ obj! _SUBDIRUSE
                        }; \
                        MKDIRS=_mkdirs; \
                fi; \
-       elif [[ $$here == $$subdir ]]; then \
+       elif [[ `id` == *'('${WOBJGROUP}')'* && $$here == $$subdir ]]; then \
                SETOWNER="chown :${WOBJGROUP}"; \
        else \
                SETOWNER=:; \

Reply via email to