From 9abbc5f06c1c8eb087cd2bb6ea4b6ccb006a1298 Mon Sep 17 00:00:00 2001 From: David Adam Date: Sat, 9 Jul 2016 11:02:50 +0800 Subject: [PATCH] Makefile: soft-fail on creating extra directories The extra {completions,functions,conf}.d directories may be placed outside the writeable prefix. Attempt to create them, but don't abort the installation if it is not possible. (There is an argument for not creating these folders at all, but that reduces their discoverability.) As discussed in https://github.com/Homebrew/homebrew-core/pull/2813 --- Makefile.in | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Makefile.in b/Makefile.in index 8b6aedef9..3c5a5d9cf 100644 --- a/Makefile.in +++ b/Makefile.in @@ -575,7 +575,8 @@ xcode-install: # # Actually do the installation. These 'true' lines are to prevent installs -# from failing for (e.g.) missing man pages. +# from failing for (e.g.) missing man pages or extra_dirs outside the +# writeable prefix. # install-force: all install-translations $(INSTALL) -m 755 -d $(DESTDIR)$(bindir) @@ -587,9 +588,9 @@ install-force: all install-translations $(INSTALL) -m 755 -d $(DESTDIR)$(sysconfdir)/fish/conf.d $(INSTALL) -m 755 -d $(DESTDIR)$(datadir)/fish $(INSTALL) -m 755 -d $(DESTDIR)$(datadir)/fish/completions - $(INSTALL) -m 755 -d $(DESTDIR)$(extra_completionsdir) - $(INSTALL) -m 755 -d $(DESTDIR)$(extra_functionsdir) - $(INSTALL) -m 755 -d $(DESTDIR)$(extra_confdir) + $(INSTALL) -m 755 -d $(DESTDIR)$(extra_completionsdir); true + $(INSTALL) -m 755 -d $(DESTDIR)$(extra_functionsdir); true + $(INSTALL) -m 755 -d $(DESTDIR)$(extra_confdir); true $(INSTALL) -m 755 -d $(DESTDIR)$(datadir)/fish/functions $(INSTALL) -m 755 -d $(DESTDIR)$(datadir)/fish/man/man1 $(INSTALL) -m 755 -d $(DESTDIR)$(datadir)/fish/tools