Issue Details (XML | Word | Printable)

Key: STDCXX-592
Type: Bug Bug
Status: Open Open
Priority: Minor Minor
Assignee: Unassigned
Reporter: Martin Sebor
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
C++ Standard Library

[EDG eccp/Linux] multiple definition of `__sti___xxx' objects in codecvt.cpp, collate.cpp, and ctype.cpp

Created: 12/Oct/07 09:58 PM   Updated: 02/Dec/08 03:05 AM
Return to search
Component/s: 22. Localization
Affects Version/s: 4.2.0
Fix Version/s: 4.2.2

Time Tracking:
Original Estimate: 8h
Original Estimate - 8h
Remaining Estimate: 8h
Remaining Estimate - 8h
Time Spent: Not Specified
Remaining Estimate - 8h

Environment: EDG eccp 3.10 with gcc 4.1.0 on SUSE Linux Enterprise Server 10 (x86_64)

Severity: Linker Error


 Description  « Hide
When compiled with EDG eccp 3.10 (and possibly prior versions of the same), a number of example programs fail to link with the error below:

generating dependencies for $(TOPDIR)/examples/manual/codecvt.cpp
eccp -M -I/amd/devco/sebor/stdcxx/include/ansi -D_RWSTDDEBUG -I/amd/devco/sebor/stdcxx/include -I/build/sebor/stdcxx-eccp-3.9-11s/include -I/amd/devco/sebor/stdcxx/examples/include -A -x --template_directory=/build/sebor/stdcxx-eccp-3.9-11s/lib -g --display_error_number --remarks --diag_suppress 193,236,340,401,2
61,479,487,678,679,815 /amd/devco/sebor/stdcxx/examples/manual/codecvt.cpp
eccp -c -I/amd/devco/sebor/stdcxx/include/ansi -D_RWSTDDEBUG -I/amd/devco/sebor/stdcxx/include -I/build/sebor/stdcxx-eccp-3.9-11s/include -I/amd/devco/sebor/stdcxx/examples/include -A -x --template_directory=/build/sebor/stdcxx-eccp-3.9-11s/lib -g --display_error_number --remarks --diag_suppress 193,236,340,401,2
61,479,487,678,679,815 /amd/devco/sebor/stdcxx/examples/manual/codecvt.cpp
eccp codecvt.o -o codecvt --template_directory=/build/sebor/stdcxx-eccp-3.9-11s/lib -L/build/sebor/stdcxx-eccp-3.9-11s/lib -lstd11s -lm
nm: t_exp.o: no symbols
nm: e_rem_pio2.o: no symbols
nm: k_cos.o: no symbols
nm: k_rem_pio2.o: no symbols
nm: k_sin.o: no symbols
nm: s_scalbln.o: no symbols
nm: e_rem_pio2f.o: no symbols
nm: k_rem_pio2f.o: no symbols
nm: s_scalblnf.o: no symbols
nm: e_rem_pio2l.o: no symbols
nm: k_rem_pio2l.o: no symbols
nm: s_nexttowardl.o: no symbols
nm: s_scalblnl.o: no symbols
nm: t_sincosl.o: no symbols
nm: k_sincosl.o: no symbols
nm: branred.o: no symbols
nm: doasin.o: no symbols
nm: dosincos.o: no symbols
nm: halfulp.o: no symbols
nm: mpa.o: no symbols
nm: mpatan2.o: no symbols
nm: mpatan.o: no symbols
nm: mpexp.o: no symbols
nm: mplog.o: no symbols
nm: mpsqrt.o: no symbols
nm: mptan.o: no symbols
nm: sincos32.o: no symbols
nm: slowexp.o: no symbols
nm: slowpow.o: no symbols
/build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(codecvt.o): In function `_sti__11_codecvt_cpp_845ea9dc':
/amd/devco/sebor/stdcxx/src/codecvt.cpp:273: multiple definition of `_sti__11_codecvt_cpp_845ea9dc'
codecvt.o:/amd/devco/sebor/stdcxx/include/loc/_locale.h:327: first defined here
/nfs/packages/mdx/sles/em64t/utils/binutils/2.16.91.0.5-23.4/bin/ld: Warning: size of symbol `_sti__11_codecvt_cpp_845ea9dc' changed from 48 in codecvt.o to 5 in /build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(codecvt.o)
collect2: ld returned 1 exit status
make: *** [codecvt] Error 1



 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Martin Sebor added a comment - 12/Oct/07 10:32 PM
As an aside, redirecting nm's stderr to /dev/null in $EDG_BASE/edg_eccp_config silences the nm noise.

Martin Sebor added a comment - 13/Oct/07 01:49 AM
Actually, only three example programs fail with this error: codecvt.cpp, collate.cpp, and ctype.cpp. The error appears to be caused by the fact that the names of the example source files are the same as the names of the library source files that define the corresponding facets. Seems like a compiler bug... Since the errors can be worked around by renaming the program .cpp files I'm lowering Priority to Minor and deferring the issue for 4.2.1.

Martin Sebor added a comment - 01/Nov/07 12:09 AM
Now that 4.2.0 is released, set Affects Version(s) accordingly.

Martin Sebor added a comment - 27/Mar/08 08:13 PM
In total, three examples are affected by this problem: codecvt.cpp, collate.cpp, and ctype.cpp:
$ nice make -C../examples -k
make: Entering directory `/build/sebor/stdcxx-eccp-3.9-11s/examples'
eccp codecvt.o -o codecvt --template_directory=/build/sebor/stdcxx-eccp-3.9-11s/lib    -L/build/sebor/stdcxx-eccp-3.9-11s/lib  -lstd11s  -lm 
/build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(codecvt.o): In function `__sti___11_codecvt_cpp_845ea9dc':
/amd/devco/sebor/stdcxx/src/codecvt.cpp:273: multiple definition of `__sti___11_codecvt_cpp_845ea9dc'
codecvt.o:/amd/devco/sebor/stdcxx/include/string:922: first defined here
/nfs/packages/mdx/sles/em64t/utils/binutils/2.16.91.0.5-23.4/bin/ld: Warning: size of symbol `__sti___11_codecvt_cpp_845ea9dc' changed from 48 in codecvt.o to 5 in /build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(codecvt.o)
collect2: ld returned 1 exit status
make: *** [codecvt] Error 1
eccp collate.o -o collate --template_directory=/build/sebor/stdcxx-eccp-3.9-11s/lib    -L/build/sebor/stdcxx-eccp-3.9-11s/lib  -lstd11s  -lm 
/build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(collate.o): In function `__sti___11_collate_cpp_845ea9dc':
/amd/devco/sebor/stdcxx/src/collate.cpp:301: multiple definition of `__sti___11_collate_cpp_845ea9dc'
collate.o:/amd/devco/sebor/stdcxx/include/string:922: first defined here
/nfs/packages/mdx/sles/em64t/utils/binutils/2.16.91.0.5-23.4/bin/ld: Warning: size of symbol `__sti___11_collate_cpp_845ea9dc' changed from 48 in collate.o to 5 in /build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(collate.o)
collect2: ld returned 1 exit status
make: *** [collate] Error 1
eccp ctype.o -o ctype --template_directory=/build/sebor/stdcxx-eccp-3.9-11s/lib    -L/build/sebor/stdcxx-eccp-3.9-11s/lib  -lstd11s  -lm 
/build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(ctype.o): In function `__sti___9_ctype_cpp_845ea9dc':
/amd/devco/sebor/stdcxx/src/ctype.cpp:651: multiple definition of `__sti___9_ctype_cpp_845ea9dc'
ctype.o:/amd/devco/sebor/stdcxx/include/loc/_locale.h:379: first defined here
/nfs/packages/mdx/sles/em64t/utils/binutils/2.16.91.0.5-23.4/bin/ld: Warning: size of symbol `__sti___9_ctype_cpp_845ea9dc' changed from 48 in ctype.o to 10475 in /build/sebor/stdcxx-eccp-3.9-11s/lib/libstd11s.a(ctype.o)
collect2: ld returned 1 exit status
make: *** [ctype] Error 1
make: Target `all' not remade because of errors.
make: Leaving directory `/build/sebor/stdcxx-eccp-3.9-11s/examples'

Martin Sebor added a comment - 23/Apr/08 12:34 AM
Deferred until 4.2.2.