File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -118,7 +118,6 @@ tools/*/*.i.tmp
118118
119119# === Rules for tools/perfetto ===
120120/tools /perfetto /trace_processor_shell
121- /tools /perfetto /.version
122121
123122# === Rules for test artifacts ===
124123/* .tap
Original file line number Diff line number Diff line change @@ -235,7 +235,7 @@ distclean: ## Remove all build and test artifacts.
235235 $(RM ) -r node_modules
236236 $(RM ) -r deps/icu
237237 $(RM ) -r deps/icu4c* .tgz deps/icu4c* .zip deps/icu-tmp
238- $(RM ) tools/perfetto/trace_processor_shell tools/perfetto/.version
238+ $(RM ) tools/perfetto/trace_processor_shell
239239 $(RM ) $(BINARYTAR ) .* $(TARBALL ) .*
240240
241241.PHONY : check
Original file line number Diff line number Diff line change 77tools_dir=$( CDPATH= cd -- " $( dirname -- " $0 " ) " && pwd)
88version=$( cat " $tools_dir /../../deps/perfetto/VERSION" )
99trace_processor=" $1 "
10- stamp=" $tools_dir /.version"
11-
12- if [ -x " $trace_processor " ] && [ " $( cat " $stamp " 2> /dev/null) " = " $version " ]; then
13- echo " trace_processor_shell v$version is already downloaded"
14- exit 0
15- fi
1610
1711# Perfetto names its release archives <os>-<arch>, which does not match uname.
1812case " $( uname -s) " in
3024url=" https://github.com/google/perfetto/releases/download/v$version /$os -$arch .zip"
3125archive=" $tools_dir /$os -$arch .zip"
3226
33- rm -f " $trace_processor " " $stamp "
27+ rm -f " $trace_processor "
3428echo " Downloading $url "
3529curl -sSfL -o " $archive " " $url "
3630unzip -q -j -o " $archive " ' */trace_processor_shell' -d " $tools_dir "
3731rm -f " $archive "
3832chmod +x " $trace_processor "
39- printf ' %s\n' " $version " > " $stamp "
33+ # The archive carries the release's own mtime. Make decides whether the tool is
34+ # current by comparing it against deps/perfetto/VERSION, so it has to come out
35+ # newer than the version file it was downloaded for.
36+ touch " $trace_processor "
You can’t perform that action at this time.
0 commit comments