This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
Re: -frepo not working?
- To: Chad Gatesman <chadg at redrose dot net>
- Subject: Re: -frepo not working?
- From: Lee Iverson <leei at ai dot sri dot com>
- Date: Wed, 16 Dec 1998 11:07:25 -0800
- cc: Alexandre Oliva <oliva at dcc dot unicamp dot br>, egcs at cygnus dot com, egcs-bugs at cygnus dot com
In message <367801D4.F6C06EC3@redrose.net> you write:
>
> This can be reproduced very easily. I will show you an example using
> egcs-1.1.1:
>
> _________________________________
>
> // repo-fail.cc
> #include <vector>
>
> void main()
> {
> vector<int> v;
>
> v.push_back(1);
> }
>
> _________________________________
>
>
> chad:/tmp> g++ -c -frepo repo-fail.cc
> chad:/tmp> g++ -o repo-fail repo-fail.o
> repo-fail.o: In function `vector<int, __default_alloc_template<false, 0>
> >::push_back(int const &)':
> repo-fail.o(.vector<int, __default_alloc_template<0, 0>
> >::gnu.linkonce.t.push_back(int const &)+0x35): undefined reference to
> `vector<int, __default_alloc_template<false, 0> >::insert_aux(int *, int
> const &)'
> collect2: ld returned 1 exit status
>
Bzzzt... Close but... -frepo is a *linker* command. Try adding it
to the second line 'g++ -frepo -o repo-fail repo-fail.o'
-------------------------------------------------------------------------------
Lee Iverson SRI International
leei@ai.sri.com 333 Ravenswood Ave., Menlo Park CA 94025
http://www.ai.sri.com/~leei/ (650) 859-3307