aboutsummaryrefslogtreecommitdiff
path: root/gprof/testsuite/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'gprof/testsuite/Makefile.am')
-rw-r--r--gprof/testsuite/Makefile.am14
1 files changed, 8 insertions, 6 deletions
diff --git a/gprof/testsuite/Makefile.am b/gprof/testsuite/Makefile.am
index c4d6c41..7ab1c2e 100644
--- a/gprof/testsuite/Makefile.am
+++ b/gprof/testsuite/Makefile.am
@@ -6,12 +6,12 @@ GPROF = ../gprof$(EXEEXT)
# NB: -O2 -fno-omit-frame-pointer is needed for expected call graph. See
# https://sourceware.org/bugzilla/show_bug.cgi?id=32768
-GPROF_FLAGS = -O2 -fno-omit-frame-pointer -pg
+# -g is needed for line number info checked by tst-gmon-gprof-l.sh. See
+# https://sourceware.org/bugzilla/show_bug.cgi?id=32779
+GPROF_FLAGS = -O2 -fno-omit-frame-pointer -pg -g
-COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
- $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) $(GPROF_FLAGS)
-LINK = $(CC) $(AM_CFLAGS) $(CFLAGS) $(OPT_NO_PLUGINS) $(GPROF_FLAGS) \
- $(AM_LDFLAGS) $(LDFLAGS) -o $@
+COMPILE = $(CC) $(AM_CFLAGS) $(GPROF_FLAGS)
+LINK = $(CC) $(AM_CFLAGS) $(GPROF_FLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
# We will add to these later, for each individual test. Note
# that we add each test under check_SCRIPTS;
@@ -37,7 +37,9 @@ tst-gmon-gprof.out: tst-gmon$(EXEEXT) $(GPROF)
check_SCRIPTS += tst-gmon-gprof-l.sh
check_DATA += tst-gmon-gprof-l.out
-tst-gmon-gprof-l.out: tst-gmon$(EXEEXT) $(GPROF)
+# Run tst-gmon-gprof-l.sh after tst-gmon-gprof.sh to avoid the race
+# condition since they both generate gmon.out.
+tst-gmon-gprof-l.out: tst-gmon$(EXEEXT) $(GPROF) tst-gmon-gprof.out
$(srcdir)/tst-gmon-gprof-l.sh $(GPROF) tst-gmon$(EXEEXT)
endif NATIVE