All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] btrfs-progs: build: Do not use cp -a to install files
@ 2018-04-04 14:04 Peter Kjellerstedt
  2018-04-05  6:35 ` Anand Jain
  2018-04-06 12:55 ` David Sterba
  0 siblings, 2 replies; 3+ messages in thread
From: Peter Kjellerstedt @ 2018-04-04 14:04 UTC (permalink / raw)
  To: linux-btrfs; +Cc: pkj

Using cp -a to install files will preserve the ownership of the
original files (if possible), which is typically not wanted. E.g., if
the files were built by a normal user, but are being installed by
root, then the installed files would maintain the UIDs/GIDs of the
user that built the files rather than be owned by root.

Signed-off-by: Peter Kjellerstedt <peter.kjellerstedt@axis.com>
---
 Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Makefile b/Makefile
index 92cfe7b5..0e8bfd98 100644
--- a/Makefile
+++ b/Makefile
@@ -578,7 +578,7 @@ install: $(libs) $(progs_install) $(INSTALLDIRS)
 	$(LN_S) -f btrfs $(DESTDIR)$(bindir)/btrfsck
 	$(INSTALL) -m755 -d $(DESTDIR)$(libdir)
 	$(INSTALL) $(libs) $(DESTDIR)$(libdir)
-	cp -a $(lib_links) $(DESTDIR)$(libdir)
+	cp -d $(lib_links) $(DESTDIR)$(libdir)
 	$(INSTALL) -m755 -d $(DESTDIR)$(incdir)
 	$(INSTALL) -m644 $(headers) $(DESTDIR)$(incdir)
 ifneq ($(udevdir),)
-- 
2.12.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-04-06 12:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-04 14:04 [PATCH] btrfs-progs: build: Do not use cp -a to install files Peter Kjellerstedt
2018-04-05  6:35 ` Anand Jain
2018-04-06 12:55 ` David Sterba

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.