disabling libgcov.a?

Steffen Dettmer steffen.dettmer@googlemail.com
Fri Apr 29 13:36:00 GMT 2011


Hi,

I'm trying to build arm-elf-gcc --sysroot and my target does not have
a file system etc.
gcc building seems to enforce building of libgcov.a.

- Why is this enforced? I think libgcov is for converage
  analyzing with gcov and has high requirements (such as needing
  a file system).

- How can I disable building of libgcov.a?
  I used a hack in libgcc/Makefile.in, see at the end of the
  mail. How do I do this better?

diff -Nur gcc-4.6.0.dist/libgcc/Makefile.in gcc-4.6.0/libgcc/Makefile.in
--- gcc-4.6.0.dist/libgcc/Makefile.in   2011-01-26 05:19:58.000000000 +0100
+++ gcc-4.6.0/libgcc/Makefile.in        2011-04-28 14:25:28.000000000 +0200
@@ -765,7 +765,9 @@

        $(RANLIB) $@

-all: libgcc.a libgcov.a
+all: libgcc.a hack # libgcov.a
+hack:
+       test -e libgcov.a || ar cru libgcov.a ; true

 ifneq ($(LIBUNWIND),)
 all: libunwind.a



More information about the Gcc-help mailing list