This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: sh-*-* Fails to Compile on FreeBSD
- From: Oleg Endo <oleg dot endo at t-online dot de>
- To: Joel Sherrill <joel dot sherrill at oarcorp dot com>
- Cc: GCC Mailing List <gcc at gcc dot gnu dot org>, Chris Johns <chrisj at rtems dot org>, Amar Takhar <verm at darkbeer dot org>
- Date: Thu, 1 May 2014 22:29:05 +0200
- Subject: Re: sh-*-* Fails to Compile on FreeBSD
- Authentication-results: sourceware.org; auth=none
- References: <5362A9A9 dot 9020109 at oarcorp dot com>
On 01 May 2014, at 22:08, Joel Sherrill <joel.sherrill@oarcorp.com> wrote:
> Hi
>
> gcc-4.8.2 targeting sh-*-* fails to compile on
> FreeBSD 10 which is using clang. I am hoping someone
> has some ideas about these.
Yes, I've noticed and mentioned this already a while ago:
http://gcc.gnu.org/ml/gcc/2013-12/msg00036.html
> In file included from ../../gcc-4.8.2/gcc/config/sh/sh.c:63:
> In file included from /usr/include/c++/v1/sstream:174:
> In file included from /usr/include/c++/v1/ostream:131:
> In file included from /usr/include/c++/v1/ios:216:
> In file included from /usr/include/c++/v1/__locale:15:
> In file included from /usr/include/c++/v1/string:438:
> In file included from /usr/include/c++/v1/cwchar:107:
> In file included from /usr/include/c++/v1/cwctype:54:
> /usr/include/c++/v1/cctype:51:72: error: use of undeclared identifier
> 'do_not_use_isalnum_with_safe_ctype'
> inline _LIBCPP_INLINE_VISIBILITY int __libcpp_isalnum(int __c) {return
> isalnum(__c);}
>
> sh.c line 63 is this:
>
> #include <sstream>
> #include <vector>
> #include <algorithm>
>
> It is the only file in gcc/config/* to include sstream. Has some
> update sweep for C++ transition missed this file?
Could you please try moving the std includes above any other (gcc) includes and see if it fixes the issue? AFAIR it did it for me.
Cheers,
Oleg