OSDN Git Service

Dont choke when chown fails. Try to be more portable...
authorEric Andersen <andersen@codepoet.org>
Fri, 8 Feb 2002 15:55:04 +0000 (15:55 -0000)
committerEric Andersen <andersen@codepoet.org>
Fri, 8 Feb 2002 15:55:04 +0000 (15:55 -0000)
Makefile

index 79ff995..1de1eab 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -197,7 +197,7 @@ install_dev:
        -@for i in `find  $(PREFIX)$(DEVEL_PREFIX) -type d` ; do \
            chmod -f 755 $$i; chmod -f 644 $$i/*.h; \
        done;
-       (NAME=`id -u`; GROUP=`id -g`; chown -R $$NAME.$$GROUP $(PREFIX)$(DEVEL_PREFIX))
+       -chown -R `id | sed 's/^uid=\([0-9]*\).*gid=\([0-9]*\).*$/\1.\2/'` $(PREFIX)$(DEVEL_PREFIX)
 ifeq ($(strip $(HAVE_SHARED)),true)
        find lib/ -type l -name '*.so' -exec cp -a {} $(PREFIX)$(DEVEL_PREFIX)/lib ';'
 endif