This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [www] 3.2 ABI Compatibility issues


Benjamin Kosnik <bkoz@redhat.com> writes:

> According to
> http://gcc.gnu.org/install/configure.html
>
> --enable-shared is on by default.
>
> Due to Jakub's patching this week,
>
> --enable-threads=posix
>
> is now on by default.
>
> Thus, it seems like the only really required flag in 3.2 will be:
>
> --enable-__cxa_atexit

Thanks for reminding me.  I've reworked the section to emphasize also
that the default flags should not be changed.  What do you think of
the appended patch?  I'll commit it later unless folks improve it ;-).

>> E.g., it should be possible to learn the state of --enable-threads and
>> --enable-__cxa_atexit .  That seems better than forcing users to guess
>> how to build a new compiler with the most compatible C++ ABI.
>
> I'm of the opinon that the default options for a platform should be
> the ones used. 
>
> This seems difficult to do with __cxa_atexit, thus your web page.
>
> I think the verbose output in 'g++ -v' that indicates thread model
> came about because nobody could figure out (easily) what was going on
> when end-users reported bugs with MT apps. Having that info readily
> available has made all of the FAQ-type questions much easier to deal
> with.
>
> I hope the same thing happens with ABI issues. Sure, you can scan
> auto-host.h for DEFAULT_USE_CXA_ATEXIT, but it would seem simpler to
> have ABI-breaking flags as easy for people figure out as possible.

gcc -v mentions already the full configure line:
Configured with: /cvs/gcc/configure --prefix=/opt/gcc/3.3-devel --disable-nls --enable-threads=posix --enable-clocale=gnu --enable-__cxa_atexit --enable-shared --enable-languages=c,c++,f77,java,objc,ada --disable-checking --with-system-zlib

This should help.  Do we really need to add the other flags explicitly?

Andreas

Index: c++-abi.html
===================================================================
RCS file: /cvs/cvs-mirror-rsync/gcc/wwwdocs/htdocs/gcc-3.2/c++-abi.html,v
retrieving revision 1.1
diff -u -p -r1.1 c++-abi.html
--- c++-abi.html	8 Aug 2002 06:34:51 -0000	1.1
+++ c++-abi.html	9 Aug 2002 06:14:37 -0000
@@ -23,11 +23,16 @@
 
    <h2>Configuring GCC</h2>
     
-    <p>Configure GCC with these options:</p>
+    <p>Configure GCC with this options:</p>
     <pre>
-      --enable-threads=posix -enable-shared --enable-__cxa_atexit
+      --enable-__cxa_atexit
     </pre>
     
+    <p>GCC is configured by default on GNU/Linux systems also with
+    these two flags, do not change them to any another value:</p>
+    <pre>
+      --enable-threads=posix -enable-shared 
+    </pre>
     <p>If you do not use these options, your files generated by GCC
     will not be fully ABI compatible.</p>
 
-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]