From 4aa7a8a5c8257e026b34fde1cf50434de0b48fbf Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Sun, 30 Mar 2014 19:14:39 -0700 Subject: [PATCH 1/2] mk: Fix 'make dist' on Mac --- mk/dist.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mk/dist.mk b/mk/dist.mk index d0990dfd72073..93aedb2240d78 100644 --- a/mk/dist.mk +++ b/mk/dist.mk @@ -171,7 +171,7 @@ dist/$(PKG_NAME)-$(1).pkg: $(S)src/etc/pkg/Distribution.xml LICENSE.txt \ --resources tmp/dist/pkgres-$(1) dist/$(PKG_NAME)-$(1).pkg $(Q)rm -rf tmp rust.pkg -tmp/dist/pkgres-$(1)/LICENSE.txt: $(S)/LICENSE.txt +tmp/dist/pkgres-$(1)/LICENSE.txt: LICENSE.txt @$$(call E,pkg resource LICENSE.txt) $(Q)mkdir -p $$(@D) $(Q)cp $$< $$@ From cfb52a5d35d2a5f682ce08435b3787b26ca05987 Mon Sep 17 00:00:00 2001 From: Brian Anderson Date: Sun, 30 Mar 2014 20:14:32 -0700 Subject: [PATCH 2/2] mk: Don't touch config.tmp or tmp/dist as root. Closes #13190 When running `make install` we are touching these files that can't then be removed later. --- mk/install.mk | 4 ++-- src/etc/install.sh | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/mk/install.mk b/mk/install.mk index ca9497444f08d..bcc2a5fbaaac0 100644 --- a/mk/install.mk +++ b/mk/install.mk @@ -17,12 +17,12 @@ endif install: dist-install-dir-$(CFG_BUILD) $(Q)sh tmp/dist/$(PKG_NAME)-$(CFG_BUILD)/install.sh --prefix="$(DESTDIR)$(CFG_PREFIX)" --libdir="$(DESTDIR)$(CFG_LIBDIR)" --mandir="$(DESTDIR)$(CFG_MANDIR)" "$(MAYBE_DISABLE_VERIFY)" # Remove tmp files while we can because they may have been created under sudo - $(Q)rm -R tmp/dist/$(PKG_NAME)-$(CFG_BUILD) + $(Q)rm -R tmp/dist uninstall: dist-install-dir-$(CFG_BUILD) $(Q)sh tmp/dist/$(PKG_NAME)-$(CFG_BUILD)/install.sh --uninstall --prefix="$(DESTDIR)$(CFG_PREFIX)" --libdir="$(DESTDIR)$(CFG_LIBDIR)" --mandir="$(DESTDIR)$(CFG_MANDIR)" # Remove tmp files while we can because they may have been created under sudo - $(Q)rm -R tmp/dist/$(PKG_NAME)-$(CFG_BUILD) + $(Q)rm -R tmp/dist ###################################################################### diff --git a/src/etc/install.sh b/src/etc/install.sh index 5674b0a5045c9..dc09c7dfd00da 100644 --- a/src/etc/install.sh +++ b/src/etc/install.sh @@ -45,7 +45,6 @@ putvar() { else printf "install: %-20s := %s %s\n" $1 "$T" "$2" fi - printf "%-20s := %s\n" $1 "$T" >>config.tmp } valopt() {