Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/3] lsof: fix permission of extracted files
@ 2011-10-20 22:05 Damian Kaczmarek
  2011-10-21  6:55 ` Thomas Petazzoni
  2011-11-24 22:14 ` Peter Korsgaard
  0 siblings, 2 replies; 4+ messages in thread
From: Damian Kaczmarek @ 2011-10-20 22:05 UTC (permalink / raw)
  To: buildroot

Default tar permissiong make it impossible to apply patches to some of the files

Change extraction command to skip permissions by using "-O" tar option
and a pipe tar chain. Solution suggested by: Arnout Vandecappelle <arnout@mind.be>
---
 package/lsof/lsof.mk |   10 ++++------
 1 files changed, 4 insertions(+), 6 deletions(-)

diff --git a/package/lsof/lsof.mk b/package/lsof/lsof.mk
index bfdfee3..2de0034 100644
--- a/package/lsof/lsof.mk
+++ b/package/lsof/lsof.mk
@@ -33,13 +33,11 @@ endef
 endif
 
 # The .tar.bz2 contains another .tar, which contains the source code.
-define LSOF_EXTRACT_TAR
-	$(TAR) $(TAR_STRIP_COMPONENTS)=1 -xf $(@D)/lsof_$(LSOF_VERSION)_src.tar -C $(@D)
-	chmod +w -R $(@D)
-	rm -f $(@D)/lsof_$(LSOF_VERSION)_src.tar
-endef
+LSOF_EXTRACT_CMDS = \
+        $(INFLATE.bz2) $(DL_DIR)/$(LSOF_SOURCE) | \
+                $(TAR) -O $(TAR_OPTIONS) - lsof_$(LSOF_VERSION)/lsof_$(LSOF_VERSION)_src.tar | \
+        $(TAR) $(TAR_STRIP_COMPONENTS)=1 -C $(LSOF_DIR) $(TAR_OPTIONS) -
 
-LSOF_POST_EXTRACT_HOOKS += LSOF_EXTRACT_TAR
 
 define LSOF_CONFIGURE_CMDS
 	(cd $(@D) ; \
-- 
1.7.3.4

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

end of thread, other threads:[~2011-11-24 22:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-10-20 22:05 [Buildroot] [PATCH 1/3] lsof: fix permission of extracted files Damian Kaczmarek
2011-10-21  6:55 ` Thomas Petazzoni
2011-10-21 16:21   ` Yann E. MORIN
2011-11-24 22:14 ` Peter Korsgaard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox