• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

0x7f454c46 / criu / 810 / 1
63%
master: 66%

Build:
Build:
LAST BUILD BRANCH: wip/vdso-kdat
DEFAULT BRANCH: master
Ran 05 Apr 2017 11:29AM UTC
Files 217
Run time 10s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

04 Apr 2017 05:21PM UTC coverage: 63.344% (+0.007%) from 63.337%
TR_ARCH=local GCOV=1

push

travis-ci

0x7f454c46
zdtm: rely on -D_GNU_SOURCE passed from Makefiles

After the commit
  02c763939c10 ("test/zdtm: unify common code")

CFLAGS with -D_GNU_SOURCE defined in the top Makefile
are being passed to tests Makefiles.
As _GNU_SOURCE is also defined by tests, that resulted in
zdtm tests build failures:

  make[2]: Entering directory `/home/criu/test/zdtm/lib'
   CC        test.o
  test.c:1:0: error: "_GNU_SOURCE" redefined [-Werror]
   #define _GNU_SOURCE
   ^
  <command-line>:0:0: note: this is the location of the previous definition
  cc1: all warnings being treated as errors
  make[2]: *** [test.o] Error 1

However, we didn't catch this in time by Travis-CI, as zdtm.py doesn't
do `make zdtm`, rather it does `make -C test/zdtm/{lib,static,transition}`.
By calling middle makefile this way, it doesn't have _GNU_SOURCE in
CFLAGS from top-Makefile.

I think the right thing to do here - is following CRIU's way:
rely on definition of _GNU_SOURCE by Makefiles.

This patch is almost fully generated with
  find test/zdtm/ -name '*.c' -type f					\
     -exec sed -i '/define _GNU_SOURCE/{n;/^$/d;}' '{}' \;		\
     -exec sed -i '/define _GNU_SOURCE/d' '{}' \;

With an exception for adding -D_GNU_SOURCE in tests Makefiles for
keeping the same behaviour for zdtm.py.
Also changed utsname.c to use utsname::domainname, rather private
utsname::__domainname, as now it's uncovered (from sys/utsname.h):
> struct utsname
>  {
...
> # ifdef __USE_GNU
>     char domainname[_UTSNAME_DOMAIN_LENGTH];
> # else
>     char __domainname[_UTSNAME_DOMAIN_LENGTH];
> # endif

Reported-by: Adrian Reber <areber@redhat.com>
Cc: Kir Kolyshkin <kir@openvz.org>
Signed-off-by: Dmitry Safonov <dsafonov@virtuozzo.com>

18839 of 29741 relevant lines covered (63.34%)

54485.65 hits per line

Source Files on job 810.1 (TR_ARCH=local GCOV=1)
  • Tree
  • List 0
  • Changed 123
  • Source Changed 0
  • Coverage Changed 123
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 810
  • Travis Job 810.1
  • eb2ac7b2 on github
  • Prev Job for TR_ARCH=local GCOV=1 on zdtm-gnu-source (#809.1)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc