소스 검색

build: Use --coverage instead of -fprofile-arcs and -ftest-coverage

Noticed while investigating the lack of branch coverage. It appears the
option is supported for a very long time, at least since gcc 4.1.x.
Guillem Jover 12 년 전
부모
커밋
3d42412b38
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      m4/dpkg-coverage.m4

+ 2 - 2
m4/dpkg-coverage.m4

@@ -32,8 +32,8 @@ if test "x$enable_coverage" = "xyes"; then
       AC_MSG_ERROR([missing genhtml, which is required for C coverage support])
    fi
 
-   CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
-   LDFLAGS="$LDFLAGS -fprofile-arcs -ftest-coverage"
+   CFLAGS="$CFLAGS --coverage"
+   LDFLAGS="$LDFLAGS --coverage"
 
    AC_MSG_CHECKING([for Devel::Cover perl module])
    if $($PERL -e "require Devel::Cover;" 2>/dev/null); then