33590f13b2
2001-08-07 Benjamin Kosnik <bkoz@redhat.com> Implement std::messages. Make config a fully-nested directory. * config/locale: New directory. * config/c_locale_generic.cc: Move into locale subdirectory. * config/c_locale_generic.h: Same. * config/c_locale_gnu.cc: Same. * config/c_locale_gnu.h: Same. * config/c_locale_ieee_1003.1-200x.cc: Same. * config/c_locale_ieee_1003.1-200x_.h: Same. * config/codecvt_specializations_generic.h: Same. * config/codecvt_specializations_ieee_1003.1-200x.h: Same. * config/messages_members_gnu.h: Same. * config/messaages_members_gnu.cc: Same. * config/messages_members_generic.h: Same. * config/messaages_members_generic.cc: Same. * config/messages_members_ieee_1003.1-200x.h: Same. * config/messaages_members_ieee_1003.1-200x.cc: Same. * config/io: New directory. * config/basic_file_libio.h: Move into io subdirectory. * config/basic_file_libio.cc: Same. * config/c_io_libio.h: Same. * config/c_io_libio_codecvt.c: Same. * config/basic_file_stdio.h: Same. * config/basic_file_stdio.cc: Same. * config/c_io_stdio.h: Same. * po: New directory. * po/POTFILES.in: New file. * po/Makefile.am: New file. * po/Makefile.in: New file. * po/libstdc++.pot: Generic translation file. * po/fr.po: Preliminary French translation. * po/de.po: Preliminary German translation. * intl: New directory. * intl/Makefile.am: New file. * intl/Makefile.in: New file. * intl/string_literals.cc: New file. * acinclude.m4 (GLIBCPP_CONFIGURE): Bump VERSION to 3.1.0. Add requisite setup for gettext. Re-arrange. * aclocal.m4: Regenerate. * configure.in: Don't call GLIBCPP_CHECK_COMPILER_VERSION. Output Makefile bits for po and intl. * configure: Regenerate. * Makefile.am (SUBDIRS): Add intl, po. Add rule for dist. * Makefile.in: Regenerate. * acconfig.h: Add ENABLE_NLS, HAVE_CATGETS, HAVE_GETTEXT, HAVE_STPCPY. * config.h.in: Regenerate. * acinclude.m4 (AC_REPLACE_STRINGFUNCS): Remove. * include/Makefile.am (install-data-local): Don't install Makefile. * include/Makefile.in: Regenerate. * include/bits/locale_facet.h (locale::facet::_S_clone_c_locale): Add member. * config/locale/c_locale_gnu.cc (_S_clone_c_locale): Add definition. * config/locale/c_locale_generic.cc: Same. * config/locale/c_locale_ieee_1003.1-200x.cc: Same. * include/bits/codecvt.h: Excise non-standard, non-required bits. This includes __enc_traits, and partial specializations of codecvt for __enc_traits. * src/codecvt.cc (__enc_traits::_S_max_size): Guard * config/codecvt_partials_ieee_1003.1-200x.h: New file. * config/codecvt_partials_generic.h: New file. * include/Makefile.am (allstamps): Add stamp-codecvt_model. (stamp-codecvt_model): Add. * include/Makefile.in: Regenerate. * acinclude.m4 (GLIBCPP_ENABLE_CLOCALE): Add in codecvt configury. * aclocal.m4: Regenerate. * configure: Regenerate. * testsuite/22_locale/codecvt_unicode_wchar_t.cc: Use macro guard. * testsuite/22_locale/codecvt_unicode_char.cc: Same. * testsuite/22_locale/ctor_copy_dtor.cc: And here. * include/bits/localefwd.h (class locale::facet): Add __enc_traits as a friend for _S_*_c_locale functions. * include/bits/codecvt.h (__enc_traits::__enc_traits): Add locale argument to default constructor so that CODESET information can be deduced. * include/bits/locale_facets.h (messages_byname): Re-implement. Remove specializations. * src/locale.cc (messages_byname<char>): Remove specialization. (messages_byname<wchar_t>): Same. * config/locale/c_locale_ieee_1003.1-200x.cc: New file. * config/locale/c_locale_ieee_1003.1-200x.h: New file. * config/locale/messages_members_ieee_1003.1-200x.cc: New file. * config/locale/messages_members_ieee_1003.1-200x.h: New file. * config/locale/messages_members_gnu.cc: New file. * config/locale/messages_members_gnu.h: New file. * config/locale/messages_members_generic.cc: New file. * config/locale/messages_members_generic.h: New file. * docs/html/configopts.html: Add documentation for new locale model, ieee_1003.1. Adjust other flags for current defaults. * docs/html/22_locale/locale.html: Update. * docs/html/22_locale/howto.html: Add link to messages.html. Organize. * docs/html/22_locale/messages.html: New. * src/Makefile.am (sources): Add messages_virtuals.cc. * src/Makefile.in: Regenerate. * include/Makefile.am (allstamps): Add stamp-messages_model. (stamp-messages_model): Add. * include/Makefile.in: Regenerate. * acinclude.m4 (GLIBCPP_ENABLE_CLOCALE): Add in messages configury. * aclocal.m4: Regenerate. * configure: Regenerate. * testsuite_flags.in (--cxxflags): Add LOCALEDIR. * testsuite/lib/libstdc++-v3-dg.exp: Remove broken LD_LIBRARY_PATH bits for Irix. * acinclude (GLIBCPP_ENABLE_CLOCALE): Set glibcpp_localedir to the build directories message catalog base directory, and export. Eventually this should probably be made to deal with build and install directories. For now, punt on this as the library itself doesn't use message catalogs (yet). * testsuite/22_locale/messages.cc: New file. * testsuite/22_locale/messages_char_members.cc: New file. * testsuite/22_locale/messages_byname.cc: New file. From-SVN: r44702
225 lines
9.4 KiB
HTML
225 lines
9.4 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
|
|
<HTML>
|
|
<HEAD>
|
|
<META NAME="AUTHOR" CONTENT="pme@sources.redhat.com (Phil Edwards)">
|
|
<META NAME="KEYWORDS" CONTENT="libstdc++, libstdc++-v3, GCC, g++">
|
|
<META NAME="DESCRIPTION" CONTENT="Configuration options for libstdc++-v3.">
|
|
<META NAME="GENERATOR" CONTENT="vi and eight fingers">
|
|
<TITLE>libstdc++-v3 configure options</TITLE>
|
|
<LINK REL=StyleSheet HREF="lib3styles.css">
|
|
<!-- $Id: configopts.html,v 1.12 2001/07/09 21:47:35 pme Exp $ -->
|
|
</HEAD>
|
|
<BODY>
|
|
|
|
<H1 CLASS="centered"><A NAME="top">Interesting <TT>configure</TT>
|
|
options</A></H1>
|
|
|
|
<P>The latest version of this document is always available at
|
|
<A HREF="http://gcc.gnu.org/onlinedocs/libstdc++/configopts.html">
|
|
http://gcc.gnu.org/onlinedocs/libstdc++/configopts.html</A>.
|
|
</P>
|
|
|
|
<P>To the <A HREF="http://gcc.gnu.org/libstdc++/">libstdc++-v3 homepage</A>.
|
|
|
|
|
|
<!-- ####################################################### -->
|
|
<HR>
|
|
<P>Here are some of the non-obvious options to libstdc++'s configure.
|
|
Keep in mind that
|
|
<!-- This SECnn should be the "Choosing Package Options" section. -->
|
|
<A HREF="http://sources.redhat.com/autoconf/autoconf.html#SEC74">they
|
|
all have opposite forms as well</A>
|
|
(enable/disable and with/without). The defaults are for current
|
|
development sources.
|
|
</P>
|
|
<P>The canonical way to find out the configure options that are
|
|
available for a given set of libstdc++ sources is to go to the
|
|
source directory and then type:<TT> ./configure --help</TT>
|
|
|
|
<DL>
|
|
<DT><TT>--enable-multilib </TT>[default]
|
|
<DD><P>This is part of the generic multilib support for building cross
|
|
compilers. As such, targets like "powerpc-elf" will have
|
|
libstdc++ built many different ways: "-msoft-float"
|
|
and not, etc. A different libstdc++ will be built for each of
|
|
the different multilib versions. This option is on by default.
|
|
</P>
|
|
|
|
<DT><TT>--enable-debug </TT>
|
|
<DD><P>The configure script will automatically detect the highest
|
|
level of optimization that the compiler in use can use
|
|
(certain versions of g++ will ICE if given the <TT>-O2</TT>
|
|
option, but this is fixed in later versions of the compiler).
|
|
This --enable flag will disable all optimizations and instruct
|
|
the compiler to emit as much extra debugging information as it
|
|
can, for use inside GDB. Note this make command, executed in
|
|
the build directory, will do much the same thing, without the
|
|
configuration difference:<TT>make CXXFLAGS='-g -O0' all</TT>
|
|
</P>
|
|
|
|
<DT><TT>--enable-cstdio </TT>
|
|
<DD><P>This is an abbreviated form of <TT>'--enable-cstdio=stdio'</TT>
|
|
(described next).
|
|
</P>
|
|
|
|
<DT><TT>--enable-cstdio=LIB </TT>
|
|
<DD><P>Select a target-specific I/O package. As of libstdc++-v3
|
|
snapshot 2.91, the choices are 'libio' to specify the GNU
|
|
I/O package (from
|
|
<A HREF="http://sources.redhat.com/glibc/">glibc</A>, the
|
|
GNU C library), or 'stdio' to use a generic "C"
|
|
abstraction. The default is 'stdio'. A longer explanation
|
|
is <A HREF="explanations.html#cstdio">here</A>.
|
|
</P>
|
|
|
|
<DT><TT>--enable-sjlj-exceptions </TT>
|
|
<DD><P>Forces old, set-jump/long-jump exception handling model. If
|
|
at all possible, the new, frame unwinding exception handling routines
|
|
should be used instead, as they significantly reduce both runtime
|
|
memory usage and executable size.
|
|
</P>
|
|
|
|
<DT><TT>--enable-clocale </TT>
|
|
<DD><P>This is an abbreviated form of <TT>'--enable-clocale=generic'</TT>
|
|
(described next).
|
|
</P>
|
|
|
|
<DT><TT>--enable-clocale=MODEL </TT>
|
|
<DD><P>Select a target-specific underlying locale package. The
|
|
choices are 'ieee_1003.1' to specify an X/Open, Standard Unix
|
|
(IEEE Std. 1003.1-200x) model based on langinfo/iconv/catgets,
|
|
'gnu' to specify a model based on functionality from the GNU C
|
|
library (langinfo/iconv/gettext) (from <A
|
|
HREF="http://sources.redhat.com/glibc/">glibc</A>, the GNU C
|
|
library), or 'generic' to use a generic "C"
|
|
abstraction which consists of "C" locale info. The
|
|
default is 'generic'.
|
|
</P>
|
|
|
|
<DT><TT>--enable-c99 </TT>
|
|
<DD><P>The "long long" type was introduced in C99, along
|
|
with many other functions for wide characters, and math
|
|
classification macros, etc. If enabled, all C99 functions not
|
|
specified by the C++ standard will be put into <TT>namespace
|
|
__gnu_cxx</TT>, and then all these names will
|
|
be injected into namespace std, so that C99 functions can be
|
|
used "as if" they were in the C++ standard (as they
|
|
will eventually be in some future revision of the standard,
|
|
without a doubt). By default, C99 support is on, assuming the
|
|
configure probes find all the necessary functions and bits
|
|
necessary.
|
|
</P>
|
|
|
|
<DT><TT>--enable-long-long </TT>
|
|
<DD><P>The "long long" type was introduced in C99. It is
|
|
provided as a GNU extension to C++98 in g++. This flag builds
|
|
support for "long long" into the library (specialized
|
|
templates and the like for iostreams). This option is on by default:
|
|
if enabled, users will have to either use the new-style "C"
|
|
headers by default (i.e., <cmath> not <math.h>)
|
|
or add appropriate compile-time flags to all compile lines to
|
|
allow "C" visibility of this feature (on GNU/Linux,
|
|
the flag is -D_ISOC99_SOURCE, which is added automatically via
|
|
CPLUSPLUS_CPP_SPEC's addition of _GNU_SOURCE).
|
|
</P>
|
|
|
|
<DT><TT>--enable-cheaders=OPTION </TT>
|
|
<DD><P>This allows the user to define what kind of C headers are
|
|
used. Options are: c, c_std, and c_shadow. These correspond
|
|
to the source directory's include/c, include/c_std, and
|
|
include/c_shadow directories. The default is c_std.
|
|
</P>
|
|
|
|
<DT><TT>--enable-threads </TT>
|
|
<DD><P>This is an abbreviated form of <TT>'--enable-threads=yes'</TT>
|
|
(described next).
|
|
</P>
|
|
|
|
<DT><TT>--enable-threads=LIB </TT>
|
|
<DD><P>Select a threading library. As of libstdc++-v3 snapshot 2.91,
|
|
the choices are:
|
|
'yes' for some kind of default (hmmmmm);
|
|
'decosf1', 'irix', 'mach', 'os2', 'posix'/'pthreads'
|
|
(same thing),
|
|
'solaris', 'win32', 'dce', or 'vxworks' to select the
|
|
corresponding interface;
|
|
and 'single', 'no', or 'none' for the null-case,
|
|
single-threaded library.
|
|
</P>
|
|
<P>All of this is currently undergoing a lot of changes. As of
|
|
2.91, 'single' and 'posix' are the only implemented
|
|
models. Default is single.
|
|
</P>
|
|
|
|
<DT><TT>--enable-version-specific-runtime-libs </TT>
|
|
<DD><P>Specify that run-time libraries should be installed in the
|
|
compiler-specific subdirectory (i.e.,
|
|
<TT>${libdir}/gcc-lib/${target_alias}/${gcc_version}</TT>)
|
|
instead of <TT>${libdir}</TT>. This option is useful if you
|
|
intend to use several versions of gcc in parallel. In addition,
|
|
libstdc++'s include files will be installed in
|
|
<TT>${libdir}/gcc-lib/${target_alias}/${gcc_version}/include/g++</TT>,
|
|
unless you also specify
|
|
<TT>--with-gxx-include-dir=<EM>dirname</EM></TT> during configuration.
|
|
</P>
|
|
|
|
<DT><TT>--with-gxx-include-dir=<include-files dir></TT>
|
|
<DD><P>Adds support for named libstdc++ include directory. For instance,
|
|
the following puts all the libstdc++ headers into a directory
|
|
called "2.97-20001008" instead of the usual
|
|
"g++-v3".
|
|
<PRE>
|
|
--with-gxx-include-dir=/foo/H-x86-gcc-3-c-gxx-inc/include/2.97-20001008</PRE>
|
|
</P>
|
|
|
|
<DT><TT>--enable-cxx-flags=FLAGS</TT>
|
|
<DD><P>With this option, you can pass a string of -f (functionality)
|
|
flags to the compiler to use when building libstdc++. FLAGS
|
|
is a quoted string of options, like
|
|
<PRE>
|
|
--enable-cxx-flags='-fvtable-gc -fomit-frame-pointer -ansi'</PRE>
|
|
Note that the flags don't necessarily have to all be -f flags,
|
|
as shown, but usually those are the ones that will make sense
|
|
for experimentation and configure-time overriding.
|
|
</P>
|
|
<P>The advantage of --enable-cxx-flags over setting CXXFLAGS in
|
|
the 'make' environment is that, if files are automatically
|
|
rebuilt, the same flags will be used when compiling those files
|
|
as well, so that everything matches.
|
|
</P>
|
|
<P>Fun flags to try might include combinations of
|
|
<PRE>
|
|
-fstrict-aliasing
|
|
-fno-exceptions
|
|
-ffunction-sections
|
|
-fvtable-gc</PRE>
|
|
and opposite forms (-fno-) of the same. Tell us (the mailing
|
|
list) if you discover more!
|
|
</P>
|
|
|
|
<DT><TT>--enable-c-mbchar </TT>[default]
|
|
<DD><P>Certain template specializations are required for wide
|
|
character conversion support. This is tricky and currently
|
|
changing rapidly, and can cause problems on new platforms.
|
|
Disabling wide character specializations is useful for initial
|
|
porting steps, but builds only a subset of what is required by
|
|
ISO. By default, this option is on.
|
|
</P>
|
|
</DL>
|
|
</P>
|
|
<P>Return <A HREF="#top">to the top of the page</A> or
|
|
<A HREF="http://gcc.gnu.org/libstdc++/">to the homepage</A>.
|
|
</P>
|
|
|
|
|
|
<!-- ####################################################### -->
|
|
|
|
<HR>
|
|
<P CLASS="fineprint"><EM>
|
|
$Id: configopts.html,v 1.12 2001/07/09 21:47:35 pme Exp $
|
|
</EM></P>
|
|
|
|
|
|
</BODY>
|
|
</HTML>
|