This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


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

V3 static data in classes vs AIX


	The remaining V3 failures on AIX seem to be because of static
variables in classes that somehow are suppose to be commonly accessed in
shared libraries.  This is most prevalent in
V3/include/bits/locale_facets.h:

public:
	static locale::id id;
	static int _S_pword_ix;


The header file creates a common symbol reference in the application while
the library contains the definition.  When linked statically, the two are
merged (with a duplicate symbol warning).  When linked shared, the
application and the library each use their own definitions.

	If I manually remove the common symbol in the application and
allow it to use the library definition, everything works.

	I assume that this is another case where SVR4 uses weak symbols to
define a single, global instance -- a feature which AIX does not yet have.
Can locale::id be made global?

David


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