From 6cedd688115d85e6f14a43f7653378749ef31624 Mon Sep 17 00:00:00 2001 From: Peter Kjellerstedt Date: Wed, 4 Apr 2018 16:04:59 +0200 Subject: [PATCH] btrfs-progs: build: Do not use cp -a to install library links 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 Reviewed-by: Anand Jain Signed-off-by: David Sterba --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index fbd6677a..5ba76d2e 100644 --- a/Makefile +++ b/Makefile @@ -642,7 +642,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)/btrfs $(INSTALL) -m644 $(libbtrfs_headers) $(DESTDIR)$(incdir)/btrfs $(INSTALL) -m644 libbtrfsutil/btrfsutil.h $(DESTDIR)$(incdir)