perf tools: Makefile: Remove various and sundry cruft
Commit-ID: a3d1ee10d1bf4520af3d44c1aa6cd46956ec4fd7 Gitweb: http://git.kernel.org/tip/a3d1ee10d1bf4520af3d44c1aa6cd46956ec4fd7 Author: Michael Witten <[email protected]> AuthorDate: Wed, 2 Feb 2011 14:22:08 -0600 Committer: Arnaldo Carvalho de Melo <[email protected]> CommitDate: Fri, 18 Feb 2011 07:43:06 -0200
perf tools: Makefile: Remove various and sundry cruft
This commit squashes several commits that remove:
unnecessary uname calls
`sh -c'
BUILT_INS and QUIET_BUILT_IN
They have no effect, and the fixup-builtins' and check-builtins.sh' scripts don't even exist.
RUNTIME_PREFIX
It's currently never anything but unset, and it's apparently only meaningful when Microsoft Windows is the operating system (according to the source for git).
TEST_PROGRAMS
EXTRA_PROGRAMS
unused SHELL_PATH_SQ portions
unused test for V=2
useless exports
Only when V' is undefined (that is, only when the value of V' is empty) is export V' performed, which just has the effect of placing the empty-valued variable V' in the environment.
The only other script to make use of V' is Documentation/Makefile', which only checks whether V' is undefined (that is, whether the value of V' is empty); hence, the `export V' has no effect whatsoever.
Similarly, export QUIET_GEN' is useless because it will only have a non-empty value when V' has an empty-value, and when V' has an empty-value, QUIET_GEN' is always explicitly set in every script in which it is used.
DESTDIR' is only ever defined by the user via the environment or the command line, both of which are automatically exported to sub-make processes. Furthermore, no non-make sub-scripts make use of DESTDIR' as an environment variable.
No other scripts use `perfexec_instdir'.
unused QUIET_SUBDIR{0,1}
TAR and RPMBUILD
PTHREAD_LIBS
Maintainer's dist rules and commands
distclean target
Test suite coverage testing
PRINT_DIR and NO_SUBDIR
`configure' target
NO_CURL
@@PERF_VERSION@@ substitution
Without the sed command, all of the rule's commands can be reduced to a single line that copies a file and sets the permissions properly in the process.
`make test' echo line
template_instdir
PERF-BUILD-OPTIONS
double-colon rules
The use of double-colon rules seems misguided or vestigial git.
Essentially hard-coded $(SCRIPTS) expansion
LKML-Reference: <new-submission>
--- tools/perf/.gitignore | 1 - tools/perf/Makefile | 213 ++----------------------------------------- tools/perf/util/exec_cmd.c | 19 ---- 3 files changed, 10 insertions(+), 223 deletions(-)
tools/perf/.gitignore +0 -1
@@ -1,4 +1,3 @@ -PERF-BUILD-OPTIONS PERF-CFLAGS PERF-GUI-VARS PERF-VERSION-FILE
tools/perf/Makefile +10 -203
357 lines not on this page · raw message
tools/perf/util/exec_cmd.c +0 -19
@@ -11,31 +11,12 @@ static const char *argv0_path;const char *system_path (const char *path) { -#ifdef RUNTIME_PREFIX -static const char *prefix; -#else static const char *prefix =PREFIX ; -#endif struct strbuf d =STRBUF_INIT ;if (is_absolute_path (path))return path; -#ifdef RUNTIME_PREFIX -assert (argv0_path); -assert (is_absolute_path (argv0_path)); - -if (!prefix && - !(prefix =strip_path_suffix (argv0_path,PERF_EXEC_PATH )) && - !(prefix =strip_path_suffix (argv0_path,BINDIR )) && - !(prefix =strip_path_suffix (argv0_path,"perf" ))) { - prefix =PREFIX ; -fprintf (stderr,"RUNTIME_PREFIX requested, " -"but prefix computation failed. " -"Using static fallback '%s'.\n" , prefix); - } -#endif -strbuf_addf (&d,"%s/%s" , prefix, path); path =strbuf_detach (&d,NULL );return path;