Re: [Bug 882954] Re: gcc fails to compile legal code

2011-10-30 Thread Sandy Harris
On Sun, Oct 30, 2011 at 9:29 PM, Dave Gilbert wrote: > One difference from 10.04 is that the linker is more touchy about the > order of link options, so make sure the -lrt is after the .o which > requires it. Interesting, and it solves the problem. I have this code in a file named bug.c: >  I

[Bug 882954] Re: gcc fails to compile legal code

2011-10-30 Thread Dave Gilbert
The undefined reference is certainly link stage; can you show me a cut&paste from the terminal showing the exact compile line and sequence of errors. One difference from 10.04 is that the linker is more touchy about the order of link options, so make sure the -lrt is after the .o which requires it

[Bug 882954] Re: gcc fails to compile legal code

2011-10-29 Thread Sandy Harris
I am using -lrt. However, that does not seem to be the issue since it affects linking. My compiles are failing before the linking step is reached. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/882954

[Bug 882954] Re: gcc fails to compile legal code

2011-10-29 Thread Dave Gilbert
Hi Sandy, You need to add a -lrt to pick up clock_gettime which seems to live in librt these days. Dave ** Changed in: gcc-4.6 (Ubuntu) Status: New => Invalid -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.la

[Bug 882954] Re: gcc fails to compile legal code

2011-10-28 Thread Dmitry Shachnev
** Package changed: gcc-defaults (Ubuntu) => gcc-4.6 (Ubuntu) -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/882954 Title: gcc fails to compile legal code To manage notifications about this bug go t