comp.lang.ada
 help / color / mirror / Atom feed
* gcov with GNAT 3.11p on Win 95
@ 1999-07-04  0:00 Graeme English
  1999-07-08  0:00 ` Steve Doiel
  0 siblings, 1 reply; 2+ messages in thread
From: Graeme English @ 1999-07-04  0:00 UTC (permalink / raw)


I am trying to get gcov to work with a trivial Ada program (I am assuming
this is possible since it comes with the distribution) but when I compile
code with the -gprofile-arcs -ftest-coverage the linker complains with the
following :-

C:\gnat\lib\gcc-lib\pentium-mingw32msv\2.8.1\libgcc.a(_bb.o) : In function
`_bb_init_prg':
c:/gcc/build/../gcc-2.8.1/libgcc2.c(.text+0x10a7): undefined reference to
`bzero'

Also is there a version of gprof which can cope with Ada ?






^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: gcov with GNAT 3.11p on Win 95
  1999-07-04  0:00 gcov with GNAT 3.11p on Win 95 Graeme English
@ 1999-07-08  0:00 ` Steve Doiel
  0 siblings, 0 replies; 2+ messages in thread
From: Steve Doiel @ 1999-07-08  0:00 UTC (permalink / raw)



Graeme English wrote in message <7m30k3$5eu$1@neptunium.btinternet.com>...
>I am trying to get gcov to work with a trivial Ada program (I am assuming
>this is possible since it comes with the distribution) but when I compile
>code with the -gprofile-arcs -ftest-coverage the linker complains with the
>following :-
>
>C:\gnat\lib\gcc-lib\pentium-mingw32msv\2.8.1\libgcc.a(_bb.o) : In function
>`_bb_init_prg':
>c:/gcc/build/../gcc-2.8.1/libgcc2.c(.text+0x10a7): undefined reference to
>`bzero'
>
>Also is there a version of gprof which can cope with Ada ?
>
>
I was able to resolve the bzero problem by creating the function below in a
file
named bzero.c, compiling with gcc -c bzero.c and then linking with the
object
using the following gnatmake
switches: -f  -fprofile-arcs -cargs -ftest-coverage -largs bzero.o

void bzero( char *ptr, int len )
{
  int ii;
  for( ii = 0 ; ii < len ; ii++ )
  {
    *ptr = 0;
    ptr++;
  }
}


BTW: I'm working on NT 4.0 with GNAT 3.11p

SteveD






^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~1999-07-08  0:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-07-04  0:00 gcov with GNAT 3.11p on Win 95 Graeme English
1999-07-08  0:00 ` Steve Doiel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox