Compile error with gcc

Julio Merino jmmv at outlook.com
Sun Feb 16 12:46:23 UTC 2014


On Feb 16, 2014, at 7:11, Dimitry Andric <dim at FreeBSD.org> wrote:
> 
> I don't think this will always work correctly.  If MK_LIBCPLUSPLUS is
> defined in bsd.own.mk, it only means libc++ is being *built*, not that
> it is being used.
> 
> It is probably easier and more fool-proof to check if _LIBCPP_VERSION is
> defined (which is the case when you use libc++) in bconfig.h, like so:
> 
> Index: contrib/atf/bconfig.h
> ===================================================================
> --- contrib/atf/bconfig.h       (revision 261974)
> +++ contrib/atf/bconfig.h       (working copy)
> @@ -56,7 +56,9 @@
> #define HAVE_UNSETENV 1
> 
> /* Define to 1 if vsnprintf is in std */
> +#ifdef _LIBCPP_VERSION
> #define HAVE_VSNPRINTF_IN_STD 1
> +#endif

Let's not do that unless we can change configure.ac to generate these same contents.

Maybe we can just revert this to _not_ define HAVE_VSNPRINTF_IN_STD as it used to be the case before the new import?  Things were working just fine with both libstdc++ and libc++ even if that setting was not accurate for the latter...


More information about the freebsd-testing mailing list