forked from openembedded/meta-openembedded
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sanlock: Replace cp -a with cp -R --no-dereference
helps to stop leaking builder's UID into sstate cache Fixes Exception: KeyError: 'getpwuid(): uid not found: 6000' Signed-off-by: Khem Raj <[email protected]>
- Loading branch information
Showing
2 changed files
with
54 additions
and
1 deletion.
There are no files selected for viewing
51 changes: 51 additions & 0 deletions
51
...-extended/sanlock/sanlock/0001-sanlock-Replace-cp-a-with-cp-R-no-dereference-preser.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
From 78a9cffb1c760466933bbbcbae7ecb9b30a3e6a5 Mon Sep 17 00:00:00 2001 | ||
From: Khem Raj <[email protected]> | ||
Date: Thu, 21 Nov 2019 13:47:42 -0800 | ||
Subject: [PATCH] sanlock: Replace "cp -a" with "cp -R --no-dereference | ||
--preserve=mode, links" | ||
|
||
Using "cp -a" leaks UID of user running the builds | ||
|
||
Upstream-Status: Pending | ||
|
||
Signed-off-by: Khem Raj <[email protected]> | ||
--- | ||
src/Makefile | 8 ++++---- | ||
wdmd/Makefile | 4 ++-- | ||
2 files changed, 6 insertions(+), 6 deletions(-) | ||
|
||
diff --git a/src/Makefile b/src/Makefile | ||
index 533dd79..2fc9ba5 100644 | ||
--- a/src/Makefile | ||
+++ b/src/Makefile | ||
@@ -127,9 +127,9 @@ install: all | ||
$(INSTALL) -c -m 755 $(LIBSO_CLIENT_TARGET) $(DESTDIR)/$(LIBDIR) | ||
$(INSTALL) -c -m 644 $(LIBPC_ENTIRE_TARGET) $(DESTDIR)/$(LIBDIR)/pkgconfig | ||
$(INSTALL) -c -m 644 $(LIBPC_CLIENT_TARGET) $(DESTDIR)/$(LIBDIR)/pkgconfig | ||
- cp -a $(LIB_ENTIRE_TARGET).so $(DESTDIR)/$(LIBDIR) | ||
- cp -a $(LIB_CLIENT_TARGET).so $(DESTDIR)/$(LIBDIR) | ||
- cp -a $(LIB_ENTIRE_TARGET).so.$(SOMAJOR) $(DESTDIR)/$(LIBDIR) | ||
- cp -a $(LIB_CLIENT_TARGET).so.$(SOMAJOR) $(DESTDIR)/$(LIBDIR) | ||
+ cp -R --no-dereference --preserve=mode,links $(LIB_ENTIRE_TARGET).so $(DESTDIR)/$(LIBDIR) | ||
+ cp -R --no-dereference --preserve=mode,links $(LIB_CLIENT_TARGET).so $(DESTDIR)/$(LIBDIR) | ||
+ cp -R --no-dereference --preserve=mode,links $(LIB_ENTIRE_TARGET).so.$(SOMAJOR) $(DESTDIR)/$(LIBDIR) | ||
+ cp -R --no-dereference --preserve=mode,links $(LIB_CLIENT_TARGET).so.$(SOMAJOR) $(DESTDIR)/$(LIBDIR) | ||
$(INSTALL) -c -m 644 $(HEADER_TARGET) $(DESTDIR)/$(HEADIR) | ||
$(INSTALL) -m 644 $(MAN_TARGET) $(DESTDIR)/$(MANDIR)/man8/ | ||
diff --git a/wdmd/Makefile b/wdmd/Makefile | ||
index 5849efc..4894517 100644 | ||
--- a/wdmd/Makefile | ||
+++ b/wdmd/Makefile | ||
@@ -68,7 +68,7 @@ install: all | ||
$(INSTALL) -d $(DESTDIR)/$(MANDIR)/man8 | ||
$(INSTALL) -c -m 755 $(CMD_TARGET) $(DESTDIR)/$(BINDIR) | ||
$(INSTALL) -c -m 755 $(SHLIB_TARGET) $(DESTDIR)/$(LIBDIR) | ||
- cp -a $(LIB_TARGET).so $(DESTDIR)/$(LIBDIR) | ||
- cp -a $(LIB_TARGET).so.$(SOMAJOR) $(DESTDIR)/$(LIBDIR) | ||
+ cp -R --no-dereference --preserve=mode,links $(LIB_TARGET).so $(DESTDIR)/$(LIBDIR) | ||
+ cp -R --no-dereference --preserve=mode,links $(LIB_TARGET).so.$(SOMAJOR) $(DESTDIR)/$(LIBDIR) | ||
$(INSTALL) -c -m 644 $(HEADER_TARGET) $(DESTDIR)/$(HEADIR) | ||
$(INSTALL) -m 644 $(MAN_TARGET) $(DESTDIR)/$(MANDIR)/man8 | ||
-- | ||
2.24.0 | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters