GitLab maintenance scheduled for Today, 2019-12-05, from 17:00 to 18:00 CT - Services will be unavailable during this time.

Commit fb6a91f1 authored by Philip Carns's avatar Philip Carns

add a little error checking to darshan-analyzer and add it to the default

compile and installation rules


git-svn-id: https://svn.mcs.anl.gov/repos/darshan/trunk@117 3b7491f3-a168-0410-bf4b-c445ed680a29
parent 608567ee
all: checkpath lib/libdarshan-posix.a lib/libdarshan-mpi-io.a darshan-parser darshan-diff test/gztest test/gz-bench
all: checkpath lib/libdarshan-posix.a lib/libdarshan-mpi-io.a darshan-parser darshan-diff darshan-analyzer test/gztest test/gz-bench
DESTDIR =
srcdir = @srcdir@
......@@ -36,6 +36,9 @@ mktestdir::
darshan-parser: darshan-parser.c darshan.h darshan-log-format.h
gcc $(CFLAGS) -lz $< -o $@
darshan-analyzer: darshan-analyzer.c darshan.h darshan-log-format.h
gcc $(CFLAGS) -lz $< -o $@
darshan-diff: darshan-diff.o darshan.h darshan-log-format.h darshan-logutils.o darshan-logutils.h
gcc $(CFLAGS) -lz $< darshan-logutils.o -o $@
darshan-diff.o: darshan-diff.c
......@@ -78,6 +81,7 @@ install:: all
install -d $(bindir)
install -m 755 darshan-parser $(bindir)
install -m 755 darshan-diff $(bindir)
install -m 755 darshan-analyzer $(bindir)
install -m 755 darshan-mk-log-dirs.pl $(bindir)
install -m 755 darshan-gen-cc.pl $(bindir)
install -m 755 compilers/mpicc-trace-bgp-V1R4 $(bindir)/mpicc
......@@ -98,4 +102,4 @@ install:: all
install -m 755 compilers/mpixlf95_r-trace-bgp-V1R4 $(bindir)/mpixlf95_r
clean::
rm -f *.o *.a lib/*.o lib/*.a darshan-parser darshan-diff
rm -f *.o *.a lib/*.o lib/*.a darshan-parser darshan-diff darshan-analyzer
......@@ -367,9 +367,22 @@ int tree_walk (const char *fpath, const struct stat *sb, int typeflag)
int main(int argc, char **argv)
{
int ret = 0;
if(argc != 2)
{
fprintf(stderr, "Error: bad arguments.\n");
return(-1);
}
base = argv[1];
ftw(base, tree_walk, 512);
ret = ftw(base, tree_walk, 512);
if(ret != 0)
{
fprintf(stderr, "Error: failed to walk path: %s\n", base);
return(-1);
}
printf (" log: %s\n", base);
printf (" total: %d\n", total_count);
......
......@@ -172,7 +172,7 @@ char *darshan_f_names[] = {
"CP_F_NUM_INDICES",
};
/* a rather crude API for accessing raw binary chutzpa files */
/* a rather crude API for accessing raw binary darshan files */
darshan_fd darshan_open(char *name)
{
return gzopen(name, "r");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment