svn commit: r334647 - in head: . . . [this broke ci.freebsd.org's FreeBSD-head-amd64-gcc build but via an include/c++/v1/ problem]

Dimitry Andric dim at FreeBSD.org
Tue Jun 5 17:49:38 UTC 2018


On 5 Jun 2018, at 15:03, Mark Millard via freebsd-toolchain <freebsd-toolchain at freebsd.org> wrote:
> 
> https://ci.freebsd.org/job/FreeBSD-head-amd64-gcc/5974/consoleText shows:
> 
> --- all_subdir_usr.sbin/pmc ---
> In file included from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/ios:216:0,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/iostream:38,
>                 from /workspace/src/usr.sbin/pmc/cmd_pmc_filter.cc:71:
> /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/__locale: At global scope:
> /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/__locale:1237:40: error: redundant redeclaration of 'void std::__1::__throw_runtime_error(const char*)' in same scope [-Werror=redundant-decls]
> _LIBCPP_NORETURN _LIBCPP_FUNC_VIS void __throw_runtime_error(const char*);
>                                        ^~~~~~~~~~~~~~~~~~~~~
> In file included from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/memory:663:0,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/algorithm:643,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/__string:56,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/string_view:176,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/string:477,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/__locale:15,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/ios:216,
>                 from /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/iostream:38,
>                 from /workspace/src/usr.sbin/pmc/cmd_pmc_filter.cc:71:
> /workspace/obj/workspace/src/amd64.amd64/tmp/usr/include/c++/v1/stdexcept:186:40: note: previous declaration of 'void std::__1::__throw_runtime_error(const char*)'
> _LIBCPP_NORETURN _LIBCPP_FUNC_VIS void __throw_runtime_error(const char*);
>                                        ^~~~~~~~~~~~~~~~~~~~~
> 
> 
> It looks like the new #include of iostream brings in code that gcc rejected above:
> 
> --- head/usr.sbin/pmc/cmd_pmc_filter.c	Mon Jun  4 23:17:18 2018	(r334645, copy source)
> +++ head/usr.sbin/pmc/cmd_pmc_filter.cc	Tue Jun  5 04:26:40 2018	(r334647)
> @@ -68,11 +68,22 @@ __FBSDID("$FreeBSD$");
> #include <libpmcstat.h>
> #include "cmd_pmc.h"
> 
> +#include <iostream>
> . . .

I don't think anybody has yet tested building libc++ headers with the
combination of recent gcc, -Wsystem-headers, and -Werror. :)

For now, try disabling -Wredundant-decls.

-Dimitry

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 223 bytes
Desc: Message signed with OpenPGP
URL: <http://lists.freebsd.org/pipermail/svn-src-head/attachments/20180605/625a26de/attachment.sig>


More information about the svn-src-head mailing list