From: Jonathan Wakely <jwakely.gcc@gmail.com>
To: "Casey St.Fleur" <kc1491@msn.com>
Cc: "gcc-help@gcc.gnu.org" <gcc-help@gcc.gnu.org>
Subject: Re: Cross Compile Gcc 10.2.0
Date: Tue, 18 Aug 2020 10:54:42 +0100 [thread overview]
Message-ID: <CAH6eHdS7Tv-RadFnJAgcT7ch1hPbpT=_Mo72+MLL4VfL726T8A@mail.gmail.com> (raw)
In-Reply-To: <MN2PR16MB3008807CBC261C3B2B301EA8C0400@MN2PR16MB3008.namprd16.prod.outlook.com>
On Fri, 14 Aug 2020 at 22:23, Casey St.Fleur via Gcc-help
<gcc-help@gcc.gnu.org> wrote:
>
> Hi all,
>
> I am trying to build GCC 10.2 using Ubuntu's Arm cross compiler.
>
> But I am getting the following error,
>
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc:92:5: error: ‘__constinit’ does not name a type
> 92 | __constinit constant_init<newdel_res_t> newdel_res{};
> | ^~~~~~~~~~~
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc:93:5: error: ‘__constinit’ does not name a type
> 93 | __constinit constant_init<null_res_t> null_res{};
> | ^~~~~~~~~~~
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc:146:5: error: ‘__constinit’ does not name a type
> 146 | __constinit constant_init<atomic_mem_res> default_res{&newdel_res.obj};
> | ^~~~~~~~~~~
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc: In function ‘std::pmr::memory_resource* std::pmr::new_delete_resource()’:
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc:154:13: error: ‘newdel_res’ was not declared in this scope
> 154 | { return &newdel_res.obj; }
> | ^~~~~~~~~~
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc: In function ‘std::pmr::memory_resource* std::pmr::null_memory_resource()’:
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc:158:13: error: ‘null_res’ was not declared in this scope
> 158 | { return &null_res.obj; }
> | ^~~~~~~~
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc: In function ‘std::pmr::memory_resource* std::pmr::set_default_resource(std::pmr::memory_resource*)’:
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc:165:12: error: ‘default_res’ was not declared in this scope; did you mean ‘default_delete’?
> 165 | return default_res.obj.exchange(r);
> | ^~~~~~~~~~~
> | default_delete
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc: In function ‘std::pmr::memory_resource* std::pmr::get_default_resource()’:
> ../../../../../gcc-10.2.0/libstdc++-v3/src/c++17/memory_resource.cc:170:12: error: ‘default_res’ was not declared in this scope; did you mean ‘default_delete’?
> 170 | { return default_res.obj.load(); }
> | ^~~~~~~~~~~
> | default_delete
>
> It looks like build is failing because it is trying to build a C++ 17 feature using a C++ 20 keyword. I am not sure what to do from here, any help is greatly appreciated .
__constinit is not a C++20 keyword, it's a GCC extension. The C++20
keyword is 'constinit'.
The GCC extension is supported since GCC 10.1, so the errors you are
getting mean that libstdc++ is not being built by the right compiler.
prev parent reply other threads:[~2020-08-18 9:54 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-14 21:21 Casey St.Fleur
2020-08-15 17:00 ` Christer Solskogen
2020-08-18 9:54 ` Jonathan Wakely [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAH6eHdS7Tv-RadFnJAgcT7ch1hPbpT=_Mo72+MLL4VfL726T8A@mail.gmail.com' \
--to=jwakely.gcc@gmail.com \
--cc=gcc-help@gcc.gnu.org \
--cc=kc1491@msn.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).