Skip to contentSkip to conversation

generate-cmdlist.sh should be either executable or run as parameter of "."

PATCH In review Mulyadi Santosa 3 participants 5 messages Sep 25, 2009 – Oct 1, 2009 perf events

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 generate-cmdlist.sh should be either executable or run as parameter of "."

I believe this is just a small glitch. generate-cmdlist.sh by default should be made as executable. But since one might forgot to do it, we could simply call it as an argument "." or "source" or even "sh -c". I pick "."

Tested in 2.6.31

tools/perf/Makefile renamed from tools/perf/Makefile.bak +1 -1
@@ -682,7 +682,7 @@
 common-cmds.h: util/generate-cmdlist.sh command-list.txt
 
 common-cmds.h: $(wildcard Documentation/perf-*.txt)
-	$(QUIET_GEN)util/generate-cmdlist.sh > $@+ && mv $@+ $@
+	$(QUIET_GEN). util/generate-cmdlist.sh > $@+ && mv $@+ $@
 
 $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh
 	$(QUIET_GEN)$(RM) $@ $@+ && \
#1 lore raw
Quoted 8 lines · Mulyadi Santosa

I believe this is just a small glitch. generate-cmdlist.sh by default should be made as executable. But since one might forgot to do it, we could simply call it as an argument "." or "source" or even "sh -c". I pick "."

Tested in 2.6.31

hm, generate-cmdlist.sh is executable in the upstream kernel repo. It apparently isnt executable on your box - why?

Ingo

#2 lore raw
Quoted 8 lines · Ingo Molnar
Quoted 5 lines · Mulyadi Santosa

I believe this is just a small glitch. generate-cmdlist.sh by default should be made as executable. But since one might forgot to do it, we could simply call it as an argument "." or "source" or even "sh -c". I pick "."

Quoted 6 lines
Quoted 3 lines

Tested in 2.6.31

hm, generate-cmdlist.sh is executable in the upstream kernel repo. It apparently isnt executable on your box - why?

Whatever - we should try to avoid relying on executable bit being set. umask can prevent this is tree is checkout as one user and build as another user.

Sam

#3 lore raw
Quoted 11 lines · Sam Ravnborg
Quoted 10 lines · Ingo Molnar
Quoted 7 lines · Mulyadi Santosa

I believe this is just a small glitch. generate-cmdlist.sh by default should be made as executable. But since one might forgot to do it, we could simply call it as an argument "." or "source" or even "sh -c". I pick "."

Tested in 2.6.31

Quoted 8 lines
Quoted 4 lines
Quoted 1 line

hm, generate-cmdlist.sh is executable in the upstream kernel repo. It apparently isnt executable on your box - why?

Whatever - we should try to avoid relying on executable bit being set. umask can prevent this is tree is checkout as one user and build as another user.

Fair enough - i'll queue the patch up.

Ingo

#4 lore raw

[tip:perf/urgent] perf tools: Run generate-cmdlist.sh properly

In reply to Mulyadi Santosa
Commit-ID:  1ad0560e8cdb6d5b381220dc2da187691b5ce124
Gitweb:     http://git.kernel.org/tip/1ad0560e8cdb6d5b381220dc2da187691b5ce124
Author:     Mulyadi Santosa <[email protected]>
AuthorDate: Sat, 26 Sep 2009 02:01:41 +0700
Committer:  Ingo Molnar <[email protected]>
CommitDate: Thu, 1 Oct 2009 10:12:03 +0200

perf tools: Run generate-cmdlist.sh properly

Right now generate-cmdlist.sh is not executable, so we should call it as an argument ".".

This fixes cases where due to different umask defaults the generate-cmdlist.sh script is not executable in a kernel tree checkout.

Cc Peter Zijlstra <[email protected]>
Cc Mike Galbraith <[email protected]>
Cc Paul Mackerras <[email protected]>
Cc Arnaldo Carvalho de Melo <[email protected]>
Cc Frederic Weisbecker <[email protected]>

LKML-Reference: <[email protected]>

---
 tools/perf/Makefile |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
tools/perf/Makefile +1 -1
index b5f1953..5881943 100644
@@ -728,7 +728,7 @@ $(BUILT_INS): perf$X
 common-cmds.h: util/generate-cmdlist.sh command-list.txt
 
 common-cmds.h: $(wildcard Documentation/perf-*.txt)
-	$(QUIET_GEN)util/generate-cmdlist.sh > $@+ && mv $@+ $@
+	$(QUIET_GEN). util/generate-cmdlist.sh > $@+ && mv $@+ $@
 
 $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh
 	$(QUIET_GEN)$(RM) $@ $@+ && \