Gentoo Archives: gentoo-dev

From: Sergei Trofimovich <slyfox@g.o>
To: gentoo-dev@l.g.o
Cc: vapier@g.o
Subject: Re: [gentoo-dev] Re: GCC upgrades, FUD and gentoo documentation
Date: Fri, 14 Oct 2011 16:29:05
Message-Id: 20111014192816.7e3dd1f2@sf.home
In Reply to: Re: [gentoo-dev] Re: GCC upgrades, FUD and gentoo documentation by Mike Frysinger
1 > i think cases can be made for the other internal gcc libraries:
2 ...
3 > - libmudflap.la: build/link with `gcc -fmudflap`, not `gcc -lmudflap`
4
5 I'm afraid -fmudflap won't work alone (might be easy to fix in gcc?):
6 // a.c:
7 int main() { return 0; }
8 $ gcc -fmudflap a.c -o a
9 /usr/lib/gcc/x86_64-pc-linux-gnu/4.4.6/../../../../lib64/crt1.o: In function `_start':
10 (.text+0x20): undefined reference to `__wrap_main'
11 /tmp/ccCbbGQy.o: In function `global constructors keyed to 00099_0_main':
12 a.c:(.text+0x10): undefined reference to `__mf_init'
13 collect2: ld returned 1 exit status
14 $gcc -fmudflap -lmudflap a.c -o a
15 # all ok
16
17 same is true for all -{f,l}mudflap{,th,ir}
18
19 --
20
21 Sergei

Attachments

File name MIME type
signature.asc application/pgp-signature