Auto merge of #37015 - ahmedcharles:sudo, r=alexcrichton

Prevent accidentally running 'make install' as sudo.

r? @alexcrichton

I missed this in the previous PR, but this seems to work. It should probably go in a rollup, but I don't know how to do those. :/
This commit is contained in:
bors 2016-10-08 02:23:47 -07:00 committed by GitHub
commit b5fcca5cd7
1 changed files with 4 additions and 0 deletions

View File

@ -52,7 +52,11 @@ check-cargotest:
dist:
$(Q)$(BOOTSTRAP) --step dist
install:
ifeq (root user, $(USER) $(patsubst %,user,$(SUDO_USER)))
$(Q)echo "'sudo make install' is not supported currently."
else
$(Q)$(BOOTSTRAP) --step install
endif
tidy:
$(Q)$(BOOTSTRAP) --step check-tidy --stage 0