This is the mail archive of the libc-help@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: glibc build with gcov support


I wanna check Glibc test coverage to be able to find untested functions.

As far as I understand oprofile isn't suitable for it:
It'll give me information about running code only.

Tatiana

-----Original Message-----
From: Ondřej Bílka [mailto:neleai@seznam.cz] 
Sent: Tuesday, November 19, 2013 12:08 PM
To: Tatiana Udalova
Cc: libc-help@sourceware.org; 'Slava Garbuzov'; 'Evgeny Gavrin'
Subject: Re: glibc build with gcov support

On Tue, Nov 19, 2013 at 10:54:37AM +0400, Tatiana Udalova wrote:
> Hi!
> 
> Could you advise the right way to build Glibc2.17 with gcov coverage 
> testing support?
>
How do you plan to use gcov? Does oprofile not suffice?

 
> I couldn't find any working solution on how to do it.
> 
> I was trying to add extra CFLAGS="--coverage" (or 
> CFLAGS="-fprofile-arcs
> -ftest-coverage") for glibc configuration and build.
> The following configuration error occur:
> ./configure --prefix=/usr --host=arm-none-linux-gnueabi 
> --enable-add-ons=ports,nptl --without-fp ...
> checking whether to put _rtld_local into .sdata section... no checking 
> for .preinit_array/.init_array/.fini_array support... no
> configure: error: Need linker with .init_array/.fini_array support.
> 
> Hence I can successfully build Glibc without mentioned CFLAGS.
> 
> The second solution I've tried was configuring Glibc without extra 
> CFLAGS and adding these CFLAGS on make stage only.
> Make stage failed with the following error:
> 
> arm-none-linux-gnueabi-gcc   -nostdlib -nostartfiles -r -o
> /home/t.udalova/glibc-build/elf/librtld.map.o '-Wl,-('
> /home/t.udalova/glibc-build/elf/dl-allobjs.os
> /home/t.udalova/glibc-build/libc_pic.a -lgcc '-Wl,-)'
> -Wl,-Map,/home/t.udalova/glibc-build/elf/librtld.mapT
> /home/t.udalova/glibc-build/libc_pic.a(dl-addr.os): In function
> `_GLOBAL__sub_I_65535_0_dl_addr.c':
> /home/t.udalova/sources/glibc/libc/elf/dl-addr.c:155: multiple 
> definition of `_dl_addr_inside_object'
> /home/t.udalova/glibc-build/elf/dl-allobjs.os:/home/t.udalova/fox-p/vd
> 47_a15
> /toolchain/build/sources/glibc/libc/elf/dl-open.c:755: first defined 
> here
> /home/t.udalova/glibc-build/libc_pic.a(init-first.os):(.data+0x0): 
> multiple definition of `__libc_multiple_libcs'
> /home/t.udalova/glibc-build/elf/dl-allobjs.os:/home/t.udalova/fox-p/vd
> 47_a15
> /toolchain/build/sources/glibc/libc/elf/rtld.c:2160: first defined 
> here
> /home/t.udalova/glibc-build/libc_pic.a(_itoa.os): In function `_itoa':
> /home/t.udalova/sources/glibc/libc/stdio-common/_itoa.c:199: multiple 
> definition of `_itoa'
> /home/t.udalova/glibc-build/elf/dl-allobjs.os:/home/t.udalova/sources/
> glibc/
> libc/elf/dl-minimal.c:317: first defined here
> collect2: error: ld returned 1 exit status
> 
> There are no --enable-coverage or --enable-gcov options for Glibc 
> configuration.
> 
> Tatiana
> 
> 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]