diff mbox

btrfs-progs: Makefile.in: Simplify/correct install-static

Message ID 1453391972-25669-1-git-send-email-floppym@gentoo.org (mailing list archive)
State Accepted
Headers show

Commit Message

Mike Gilbert Jan. 21, 2016, 3:59 p.m. UTC
install -D does not create the last component, so this failed if
$(DESTDIR)$(bindir) did not already exist.

There's no need for a loop here since install accepts multiple source
arguments.

Signed-off-by: Mike Gilbert <floppym@gentoo.org>
---
 Makefile.in | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Comments

David Sterba Jan. 21, 2016, 6:35 p.m. UTC | #1
On Thu, Jan 21, 2016 at 10:59:32AM -0500, Mike Gilbert wrote:
> install -D does not create the last component, so this failed if
> $(DESTDIR)$(bindir) did not already exist.
> 
> There's no need for a loop here since install accepts multiple source
> arguments.
> 
> Signed-off-by: Mike Gilbert <floppym@gentoo.org>

Applied, thanks.
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox

Patch

diff --git a/Makefile.in b/Makefile.in
index 19697ff..82a3143 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -379,9 +379,8 @@  install: $(libs) $(progs_install) $(INSTALLDIRS)
 	$(INSTALL) -m644 $(headers) $(DESTDIR)$(incdir)
 
 install-static: $(progs_static) $(INSTALLDIRS)
-	for p in $(progs_static) ; do \
-		$(INSTALL) -D -m755 $$p $(DESTDIR)$(bindir)/ ; \
-	done
+	$(INSTALL) -m755 -d $(DESTDIR)$(bindir)
+	$(INSTALL) $(progs_static) $(DESTDIR)$(bindir)
 	# btrfsck is a link to btrfs in the src tree, make it so for installed file as well
 	$(LN_S) -f btrfs.static $(DESTDIR)$(bindir)/btrfsck.static