From owner-svn-src-head@FreeBSD.ORG Fri Sep 6 09:46:46 2013 Return-Path: Delivered-To: svn-src-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 0E440D43; Fri, 6 Sep 2013 09:46:46 +0000 (UTC) (envelope-from theraven@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id D5C882D6F; Fri, 6 Sep 2013 09:46:45 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.7/8.14.7) with ESMTP id r869kjB4064462; Fri, 6 Sep 2013 09:46:45 GMT (envelope-from theraven@svn.freebsd.org) Received: (from theraven@localhost) by svn.freebsd.org (8.14.7/8.14.5/Submit) id r869kj8T064459; Fri, 6 Sep 2013 09:46:45 GMT (envelope-from theraven@svn.freebsd.org) Message-Id: <201309060946.r869kj8T064459@svn.freebsd.org> From: David Chisnall Date: Fri, 6 Sep 2013 09:46:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r255297 - in head: include lib/libc/iconv lib/libiconv_modules X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 06 Sep 2013 09:46:46 -0000 Author: theraven Date: Fri Sep 6 09:46:44 2013 New Revision: 255297 URL: http://svnweb.freebsd.org/changeset/base/255297 Log: Fix the namespace pollution caused by iconv.h including stdbool.h This broke any C89 ports that defined bool themselves, including things like gcc, gtk, and so on. Modified: head/include/iconv.h head/lib/libc/iconv/citrus_iconv_local.h head/lib/libiconv_modules/Makefile Modified: head/include/iconv.h ============================================================================== --- head/include/iconv.h Fri Sep 6 09:08:40 2013 (r255296) +++ head/include/iconv.h Fri Sep 6 09:46:44 2013 (r255297) @@ -35,7 +35,6 @@ #include #include -#include #include #include @@ -48,6 +47,13 @@ #define libiconv iconv #define libiconv_t iconv_t #endif +#ifdef __cplusplus +typedef bool __iconv_bool; +#elif __STDC_VERSION__ >= 199901L +typedef _Bool __iconv_bool; +#else +typedef int __iconv_bool; +#endif struct __tag_iconv_t; typedef struct __tag_iconv_t *iconv_t; @@ -61,7 +67,7 @@ int iconv_close(iconv_t); /* * non-portable interfaces for iconv */ -int __iconv_get_list(char ***, size_t *, bool); +int __iconv_get_list(char ***, size_t *, __iconv_bool); void __iconv_free_list(char **, size_t); size_t __iconv(iconv_t, const char **, size_t *, char **, size_t *, __uint32_t, size_t *); Modified: head/lib/libc/iconv/citrus_iconv_local.h ============================================================================== --- head/lib/libc/iconv/citrus_iconv_local.h Fri Sep 6 09:08:40 2013 (r255296) +++ head/lib/libc/iconv/citrus_iconv_local.h Fri Sep 6 09:46:44 2013 (r255297) @@ -31,6 +31,7 @@ #define _CITRUS_ICONV_LOCAL_H_ #include +#include #define _CITRUS_ICONV_GETOPS_FUNC_BASE(_n_) \ int _n_(struct _citrus_iconv_ops *) Modified: head/lib/libiconv_modules/Makefile ============================================================================== --- head/lib/libiconv_modules/Makefile Fri Sep 6 09:08:40 2013 (r255296) +++ head/lib/libiconv_modules/Makefile Fri Sep 6 09:46:44 2013 (r255297) @@ -2,6 +2,9 @@ .include +CFLAGS+= -Dbool=_Bool +.export CFLAGS + SUBDIR= BIG5 DECHanyu EUC EUCTW GBK2K HZ ISO2022 JOHAB MSKanji UES UTF1632 \ UTF7 UTF8 VIQR ZW iconv_none iconv_std mapper_646 mapper_none \ mapper_parallel mapper_serial mapper_std mapper_zone