Issue Details (XML | Word | Printable)

Key: STDCXX-404
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Critical Critical
Assignee: Martin Sebor
Reporter: Martin Sebor
Votes: 0
Watchers: 0
Operations

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

[FreeBSD 6.2] error on <iconv.h> in locale utilities

Created: 08/May/07 02:03 AM   Updated: 24/Sep/07 11:56 PM
Return to search
Component/s: Utilities
Affects Version/s: None
Fix Version/s: 4.2.0

Time Tracking:
Not Specified

Environment:
gcc 3.4.6/FreeBSD/x86
gcc 4.2/Mac OS X 10.4.10 (Tiger)
Issue Links:
Incorporates
 
Reference
 

Severity: Compiler Error
Resolution Date: 24/Sep/07 11:56 PM


 Description  « Hide
The locale utilities locale and localedef fail to build on FreeBSD due to assumptions about the <iconv.h> header which apparently isn't provided on this platform:

gcc -c -I$(TOPDIR)/include/ansi -D_RWSTDDEBUG -I$(TOPDIR)/include -I$(BUILDDIR)/include -pedantic -nostdinc++ -g -W -Wall -Wcast-qual -Winline -Wshadow -Wwrite-strings -Wno-long-long -Wcast-align $(TOPDIR)/util/localedef.cpp
In file included from $(TOPDIR)/util/def.h:45,
from $(TOPDIR)/util/localedef.cpp:30:
$(TOPDIR)/util/charmap.h:39:21: iconv.h: No such file or directory
In file included from $(TOPDIR)/util/def.h:45,
from $(TOPDIR)/util/localedef.cpp:30:
$(TOPDIR)/util/charmap.h:165: error: `iconv_t' does not name a type
$(TOPDIR)/util/charmap.h:165: error: extra semicolon
$(TOPDIR)/util/charmap.h:228: error: `iconv_t' does not name a type
$(TOPDIR)/util/charmap.h:228: error: extra semicolon
$(TOPDIR)/util/charmap.h:231: error: `iconv_t' does not name a type
$(TOPDIR)/util/charmap.h:231: error: extra semicolon
$(TOPDIR)/util/localedef.cpp: In function `bool process_command_line(ProgramOptions*, int, char**)':
$(TOPDIR)/util/localedef.cpp:475: warning: unused variable 'errors'
gmake: *** [localedef.o] Error 1



 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Martin Sebor made changes - 22/May/07 01:44 AM
Field Original Value New Value
Link This issue is related to STDCXX-40 [ STDCXX-40 ]
Martin Sebor added a comment - 22/May/07 01:44 AM
Should look at STDCXX-40 when dealing with this.

Martin Sebor made changes - 29/May/07 11:42 PM
Link This issue is part of STDCXX-117 [ STDCXX-117 ]
Eric Lemings added a comment - 13/Jul/07 07:45 PM
The same error occurs when building STDCXX on Mac OS X 10.4.10 (Tiger) with GCC 4.2.

...
gcc runall.o cmdopt.o output.o util.o exec.o display.o -o exec -L/stdcxx/lib -lstd -lsupc++ -lgcc_eh -lm

gcc -c -I/stdcxx/include/ansi -D_RWSTDDEBUG -I/stdcxx/include -I/stdcxx/include -pedantic -nostdinc++ -g -W -Wall -Wcast-qual -Winline -Wshadow -Wwrite-strings -Wno-long-long -Wcast-align /stdcxx/util/localedef.cpp
In file included from
/stdcxx/util/def.h:45,
from
/stdcxx/util/localedef.cpp:30:
/stdcxx/util/charmap.h:167: error: 'iconv_t' does not name a type
/stdcxx/util/charmap.h:230: error: 'iconv_t' does not name a type
/stdcxx/util/charmap.h:233: error: 'iconv_t' does not name a type
/stdcxx/util/localedef.cpp: In function 'bool process_command_line(ProgramOptions*, int, char**)':
/stdcxx/util/localedef.cpp:475: warning:
unused variable 'errors'
make[2]: *** [localedef.o] Error 1
make[1]: *** [util] Error 2
make: *** [libstd] Error 2


Eric Lemings made changes - 13/Jul/07 07:46 PM
Environment gcc 3.4.6/FreeBSD/x86 gcc 3.4.6/FreeBSD/x86
gcc 4.2/Mac OS X 10.4.10 (Tiger)
Martin Sebor added a comment - 23/Aug/07 04:19 AM
4.2 hasn't been released yet, setting Affects Version(s) to "trunk."

Martin Sebor made changes - 23/Aug/07 04:19 AM
Affects Version/s trunk [ 12312676 ]
Affects Version/s 4.2 [ 12311945 ]
Martin Sebor made changes - 24/Sep/07 11:39 PM
Assignee Martin Sebor [ sebor ]
Repository Revision Date User Message
ASF #579018 Mon Sep 24 23:40:24 UTC 2007 sebor 2007-09-24 Martin Sebor <sebor@roguewave.com>

STDCXX-404
* charmap.h (<iconv.h>): Removed a redundant _MSC_VER guard.
(open_iconv_to_utf8, open_iconv_to_ext, ic_to_utf8_, ic_to_ext_):
Guarded declarations with _RWSTD_NO_ICONV instead of _MSC_VER.
* charmap.cpp (my_iconv_open): Guarded function definition with
_RWSTD_NO_ICONV instead of _MSC_VER.
(convert_to_utf8): Defined function unconditionally and guarded
implementation with _RWSTD_NO_ICONV (defaulting to returning 0
when the macro is #defined).
(ic_to_utf8_, ic_to_ext_): Guarded the assignment of variables
with _RWSTD_NO_ICONV.
Guarded MSVC-specific behavior with _MSC_VER.
Files Changed
MODIFY /incubator/stdcxx/trunk/util/charmap.h
MODIFY /incubator/stdcxx/trunk/util/charmap.cpp

Martin Sebor made changes - 24/Sep/07 11:56 PM
Severity Compiler Error
Martin Sebor added a comment - 24/Sep/07 11:56 PM
Resolved by http://svn.apache.org/viewvc?rev=579018&view=rev.

Will close once we've seen good results for a few builds on the affected platforms (BSD and MSVC, since the patch touches code for both).


Martin Sebor made changes - 24/Sep/07 11:56 PM
Resolution Fixed [ 1 ]
Status Open [ 1 ] Resolved [ 5 ]