From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ciao.gmane.io (static.214.254.202.116.clients.your-server.de [116.202.254.214]) by sourceware.org (Postfix) with ESMTPS id 95B453857C4A for ; Sat, 15 Aug 2020 17:00:47 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.3.2 sourceware.org 95B453857C4A Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1k6zXx-0002vT-MY for gcc-help@gcc.gnu.org; Sat, 15 Aug 2020 19:00:45 +0200 X-Injected-Via-Gmane: http://gmane.org/ To: gcc-help@gcc.gnu.org From: Christer Solskogen Subject: Re: Cross Compile Gcc 10.2.0 Date: Sat, 15 Aug 2020 19:00:41 +0200 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 In-Reply-To: Content-Language: en-US X-Spam-Status: No, score=3.3 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, FORGED_GMAIL_RCVD, FORGED_MUA_MOZILLA, FREEMAIL_FORGED_FROMDOMAIN, FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS, KAM_DMARC_STATUS, KAM_NUMSUBJECT, NICE_REPLY_A, NML_ADSP_CUSTOM_MED, SPF_HELO_NONE, SPF_PASS, TXREP autolearn=no autolearn_force=no version=3.4.2 X-Spam-Level: *** X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on server2.sourceware.org X-BeenThere: gcc-help@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-help mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 15 Aug 2020 17:00:49 -0000 On 14.08.2020 23:21, Casey St.Fleur via Gcc-help 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{}; > | ^~~~~~~~~~~ > ../../../../../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{}; > | ^~~~~~~~~~~ > ../../../../../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 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 . > > Here are the configure parameters I used to set up the build: > > ../gcc-10.2.0/configure --prefix=/opt/gcc-10.2.0 --build=$MACHTYPE --host=arm-linux-gnueabihf --target=arm-linux-gnueabihf --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++ --with-gcc-major-version-only --program-suffix=-10.2 --program-prefix=arm-linux-gnueabihf- --enable-shared --without-included-gettext --enable-threads=posix --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-libitm --disable-libquadmath --disable-libquadmath-support --enable-plugin --with-system-zlib --with-target-system-zlib --enable-objc-gc=auto --enable-multiarch --disable-sjlj-exceptions --with-arch=armv6 --with-fpu=vfp --with-float=hard --disable-werror --enable-checking=release > Try with fewer options. For example --enable-bootstrap won't and can't work with this setup. -- chs