This is the mail archive of the
mailing list for the libstdc++ project.
Re: [patch] Default to --enable-libstdcxx-time=auto
- From: Jakub Jelinek <jakub at redhat dot com>
- To: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- Cc: Paolo Carlini <paolo dot carlini at oracle dot com>, libstdc++ <libstdc++ at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>, Rainer Orth <ro at cebitec dot uni-bielefeld dot de>
- Date: Wed, 22 May 2013 13:15:43 +0200
- Subject: Re: [patch] Default to --enable-libstdcxx-time=auto
- References: <CAH6eHdTgTspzbfHhD3uDwDVD3uXAapb_NMZ0jAZ-4-UjfD4H4g at mail dot gmail dot com> <519C942D dot 6050100 at oracle dot com> <CAH6eHdTjdi75WSwKYfdGBtOeQwbsSvMbzzxo24qofMexFSmETA at mail dot gmail dot com> <519C9AF5 dot 8090300 at oracle dot com> <519C9CBC dot 4050606 at oracle dot com> <519C9E3B dot 60609 at oracle dot com> <CAH6eHdRXAK1r0g7u+50RobAxTo=6DJsvRZzo75m7x+5ir3opKQ at mail dot gmail dot com> <CAH6eHdS5gqa2nfNJfC0zy9FJq4amgjJbtUuEASM_Qw0GZ8-9aA at mail dot gmail dot com>
- Reply-to: Jakub Jelinek <jakub at redhat dot com>
On Wed, May 22, 2013 at 11:42:45AM +0100, Jonathan Wakely wrote:
> On 22 May 2013 11:40, Jonathan Wakely wrote:
> > On 22 May 2013 11:30, Paolo Carlini wrote:
> >> .. put an abort or something in the dummy implementations, to make sure
> >> people don't try to run an executable built with headers which have the
> >> clock available linked at run time to a .so which doesn't, really.
> >> Suboptimal solution because ideally we would like to fail at build time, but
> >> this is the best I have got so far. Be very clear in the docs, anyway.
> > Based on feedback for <regex> users much prefer to have something
> > undefined than to have it defined but non-functional or causing an
> > abort.
> Could leave the steady_clock::now() symbol "undesignated", like the
> __once_call and __once_callable symbols that are only present when
> _GLIBCXX_HAVE_TLS is defined?
For now() I think it was a mistake not to export it (generally, exports
conditional on supposedly non-ABI changing configure options are bad IMHO),
can't it just return some perhaps less precise clock or something instead?
The problem with having libstdc++.so's without now()@@GLIBCXX_3.4.17
exported in the wild and now new default flag builds having those
is quite a big ABI problem, say rpm dependency tracking will not spot those,
it only looks at symbol version names, not at individual symbols, so
programs that will try to call that symbol might fail only at runtime.
If now() can be perhaps with worse precision emulated in configurations not
built against glibc 2.17, perhaps best solution would be to
add now()@@GLIBCXX_3.4.18 into 4.8.1 (and change all 3.4.18 symbols to
3.4.19) and have now()@GLIBCXX_3.4.17 (note, just one @) as compatibility
alias to that.