From 0eea8359e77474a2aec1f551accd4c83e3d0980b Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Mon, 23 Apr 2018 10:00:06 +0200 Subject: [PATCH] Allow to give search directory on command line. --- tools/doxygen/xbt_log_extract_hierarchy.pl | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/doxygen/xbt_log_extract_hierarchy.pl b/tools/doxygen/xbt_log_extract_hierarchy.pl index 8370735d8b..3675ec9f6c 100755 --- a/tools/doxygen/xbt_log_extract_hierarchy.pl +++ b/tools/doxygen/xbt_log_extract_hierarchy.pl @@ -75,14 +75,14 @@ sub parse_file { print STDERR " $name -> $anc\n" if $debug; } } -# Retrieve all the file names, and add their content to $data -my $data; -open FILES, "find ../src/ ../tools/ ../include/ -name '*.c' -o -name '*.cpp' |" || die "Cannot search for the source file names: $!\n"; +# Retrieve all the file names +my $path = $ARGV[0] // ".."; +open FILES, "find $path/src/ $path/tools/ $path/include/ -name '*.c' -o -name '*.cpp' |" || die "Cannot search for the source file names: $!\n"; while (my $file=) { chomp $file; parse_file($file); } -parse_file("../include/xbt/sysdep.h"); +parse_file("$path/include/xbt/sysdep.h"); close FILES; # Display the tree, looking for disconnected elems -- 2.20.1