Skip to content

Commit 22f46b1

Browse files
committed
PHPC-1188: Use --coverage option for code coverage builds
1 parent c78c03f commit 22f46b1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

config.m4

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -88,9 +88,10 @@ if test "$PHP_MONGODB" != "no"; then
8888
[no])
8989

9090
if test "$PHP_COVERAGE" = "yes"; then
91-
PHP_CHECK_GCC_ARG(-fprofile-arcs, COVERAGE_CFLAGS="$COVERAGE_CFLAGS -fprofile-arcs")
92-
PHP_CHECK_GCC_ARG(-ftest-coverage, COVERAGE_CFLAGS="$COVERAGE_CFLAGS -ftest-coverage")
93-
EXTRA_LDFLAGS="$COVERAGE_CFLAGS"
91+
COVERAGE_CFLAGS="--coverage -g"
92+
COVERAGE_LDFLAGS="--coverage"
93+
94+
MONGODB_SHARED_LIBADD="$MONGODB_SHARED_LIBADD $COVERAGE_LDFLAGS"
9495
fi
9596

9697
PHP_MONGODB_CFLAGS="$STD_CFLAGS $MAINTAINER_CFLAGS $COVERAGE_CFLAGS"

0 commit comments

Comments
 (0)