public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug bootstrap/98412] New: libcody does not compile with older GCC versions
@ 2020-12-21 12:22 ebotcazou at gcc dot gnu.org
  2020-12-21 12:26 ` [Bug bootstrap/98412] " jakub at gcc dot gnu.org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2020-12-21 12:22 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

            Bug ID: 98412
           Summary: libcody does not compile with older GCC versions
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Severity: major
          Priority: P3
         Component: bootstrap
          Assignee: unassigned at gcc dot gnu.org
          Reporter: ebotcazou at gcc dot gnu.org
  Target Milestone: ---

This fails in libcody:

g++ -std=c++11 -g -O -fno-enforce-eh-specs -fno-stack-protector
-fno-threadsafe-statics -fno-exceptions -fno-rtti
-fdebug-prefix-map=/homes/botcazou/gcc-head/src/libcody/= -W -Wall -include
config.h -I/homes/botcazou/gcc-head/src/libcody \
  -MMD -MP -MF buffer.d -c -o buffer.o
/homes/botcazou/gcc-head/src/libcody/buffer.cc
/homes/botcazou/gcc-head/src/libcody/buffer.cc: In member function 'void
Cody::Detail::MessageBuffer::AppendInteger(unsigned int)':
/homes/botcazou/gcc-head/src/libcody/buffer.cc:149:18: error: 'to_string' is
not a member of 'std'
   std::string v (std::to_string (u));
                  ^
gmake[3]: *** [buffer.o] Error 1

It's with GCC 4.9.4 so not very old (< 5 years).

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
@ 2020-12-21 12:26 ` jakub at gcc dot gnu.org
  2020-12-21 13:42 ` nathan at gcc dot gnu.org
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: jakub at gcc dot gnu.org @ 2020-12-21 12:26 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org,
                   |                            |nathan at gcc dot gnu.org

--- Comment #1 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
We should support GCC 4.8 and later as the system compiler.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
  2020-12-21 12:26 ` [Bug bootstrap/98412] " jakub at gcc dot gnu.org
@ 2020-12-21 13:42 ` nathan at gcc dot gnu.org
  2020-12-21 16:04 ` ebotcazou at gcc dot gnu.org
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: nathan at gcc dot gnu.org @ 2020-12-21 13:42 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

Nathan Sidwell <nathan at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #2 from Nathan Sidwell <nathan at gcc dot gnu.org> ---
Fixed 119d7478d1a

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
  2020-12-21 12:26 ` [Bug bootstrap/98412] " jakub at gcc dot gnu.org
  2020-12-21 13:42 ` nathan at gcc dot gnu.org
@ 2020-12-21 16:04 ` ebotcazou at gcc dot gnu.org
  2020-12-21 16:06 ` ebotcazou at gcc dot gnu.org
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2020-12-21 16:04 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

--- Comment #3 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
Thanks.  The next errors are:

/homes/botcazou/gcc-head/src/libcody/client.cc: In function 'Cody::Packet
Cody::ConnectResponse(std::vector<std::basic_string<char> >&)':
/homes/botcazou/gcc-head/src/libcody/client.cc:217:64: error: 'strtoul' was not
declared in this scope
       unsigned long val = strtoul (words[1].c_str (), &eptr, 10);
                                                                ^
mv -f .deps/libz_a-trees.Tpo .deps/libz_a-trees.Po
/homes/botcazou/gcc-head/src/libcody/server.cc: In function 'unsigned int
Cody::ParseUnsigned(std::string&)':
/homes/botcazou/gcc-head/src/libcody/server.cc:164:55: error: 'strtoul' was not
declared in this scope
   unsigned long val = strtoul (str.c_str (), &eptr, 10);

and are fixed by adding

#include <cstdlib>

to both files.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
                   ` (2 preceding siblings ...)
  2020-12-21 16:04 ` ebotcazou at gcc dot gnu.org
@ 2020-12-21 16:06 ` ebotcazou at gcc dot gnu.org
  2020-12-21 16:43 ` nathan at gcc dot gnu.org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2020-12-21 16:06 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
   Last reconfirmed|                            |2020-12-21
         Resolution|FIXED                       |---
             Status|RESOLVED                    |REOPENED

--- Comment #4 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
Another one:

/homes/botcazou/gcc-head/src/gcc/cp/mapper-client.cc: In static member function
'static module_client* module_client::open_module_client(location_t, const
char*, void (*)(const char*), const char*)':
/homes/botcazou/gcc-head/src/gcc/cp/mapper-client.cc:176:35: error: 'stoul' is
not a member of 'std'
    fd_from = std::stoul (from, &pos, 10);
                                   ^
/homes/botcazou/gcc-head/src/gcc/cp/mapper-client.cc:193:33: error: 'stoul' is
not a member of 'std'
    fd_to = std::stoul (to, &pos, 10);
                                 ^
gmake[3]: *** [cp/mapper-client.o] Error 1

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
                   ` (3 preceding siblings ...)
  2020-12-21 16:06 ` ebotcazou at gcc dot gnu.org
@ 2020-12-21 16:43 ` nathan at gcc dot gnu.org
  2020-12-21 17:11 ` ebotcazou at gcc dot gnu.org
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: nathan at gcc dot gnu.org @ 2020-12-21 16:43 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

--- Comment #5 from Nathan Sidwell <nathan at gcc dot gnu.org> ---
Created attachment 49822
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=49822&action=edit
test patch

Can you try this?  I guess we're finding the limitations of 'requires C++11' :)

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
                   ` (4 preceding siblings ...)
  2020-12-21 16:43 ` nathan at gcc dot gnu.org
@ 2020-12-21 17:11 ` ebotcazou at gcc dot gnu.org
  2020-12-21 17:20 ` cvs-commit at gcc dot gnu.org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2020-12-21 17:11 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

--- Comment #6 from Eric Botcazou <ebotcazou at gcc dot gnu.org> ---
> Can you try this?  I guess we're finding the limitations of 'requires C++11'

Yes, this fixes all the compilation failures, thanks!

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
                   ` (5 preceding siblings ...)
  2020-12-21 17:11 ` ebotcazou at gcc dot gnu.org
@ 2020-12-21 17:20 ` cvs-commit at gcc dot gnu.org
  2020-12-21 17:42 ` nathan at gcc dot gnu.org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2020-12-21 17:20 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Nathan Sidwell <nathan@gcc.gnu.org>:

https://gcc.gnu.org/g:1467a5c5ab0dfbae3175b4a326467f939864dadb

commit r11-6289-g1467a5c5ab0dfbae3175b4a326467f939864dadb
Author: Nathan Sidwell <nathan@acm.org>
Date:   Mon Dec 21 09:16:48 2020 -0800

    bootstrap: std:stoul non-portable [PR 98412]

    Fix some more system-specific issues.  Not everyone's C++11 is the same :(

            PR bootstrap/98412
            libcody/
            * client.cc: Include cstdlib.
            * server.cc: Include cstdlib.
            gcc/cp/
            * mapper-client.cc: INCLUDE_STRING, INCLUDE_VECTOR.
            (module_client::open_module_client): Avoid std::stoul.
            * mapper-resolver.cc: INCLUDE_STRING, INCLUDE_VECTOR.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
                   ` (6 preceding siblings ...)
  2020-12-21 17:20 ` cvs-commit at gcc dot gnu.org
@ 2020-12-21 17:42 ` nathan at gcc dot gnu.org
  2020-12-22  6:58 ` nikhil.benesch at gmail dot com
  2020-12-22 12:45 ` nathan at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: nathan at gcc dot gnu.org @ 2020-12-21 17:42 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

Nathan Sidwell <nathan at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|REOPENED                    |RESOLVED

--- Comment #8 from Nathan Sidwell <nathan at gcc dot gnu.org> ---
1467a5c5ab0 2020-12-21 | bootstrap: std:stoul non-portable [PR 98412]

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
                   ` (7 preceding siblings ...)
  2020-12-21 17:42 ` nathan at gcc dot gnu.org
@ 2020-12-22  6:58 ` nikhil.benesch at gmail dot com
  2020-12-22 12:45 ` nathan at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: nikhil.benesch at gmail dot com @ 2020-12-22  6:58 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

Nikhil Benesch <nikhil.benesch at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |nikhil.benesch at gmail dot com

--- Comment #9 from Nikhil Benesch <nikhil.benesch at gmail dot com> ---
Looks like the same fix needs to be applied to cp/module.cc. See
https://gcc.gnu.org/pipermail/gcc-patches/2020-December/562404.html.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug bootstrap/98412] libcody does not compile with older GCC versions
  2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
                   ` (8 preceding siblings ...)
  2020-12-22  6:58 ` nikhil.benesch at gmail dot com
@ 2020-12-22 12:45 ` nathan at gcc dot gnu.org
  9 siblings, 0 replies; 11+ messages in thread
From: nathan at gcc dot gnu.org @ 2020-12-22 12:45 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=98412

--- Comment #10 from Nathan Sidwell <nathan at gcc dot gnu.org> ---
Gerald got their first:
* 7e63d383b89 2020-12-22 | c++: Fix build with clang

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2020-12-22 12:45 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-21 12:22 [Bug bootstrap/98412] New: libcody does not compile with older GCC versions ebotcazou at gcc dot gnu.org
2020-12-21 12:26 ` [Bug bootstrap/98412] " jakub at gcc dot gnu.org
2020-12-21 13:42 ` nathan at gcc dot gnu.org
2020-12-21 16:04 ` ebotcazou at gcc dot gnu.org
2020-12-21 16:06 ` ebotcazou at gcc dot gnu.org
2020-12-21 16:43 ` nathan at gcc dot gnu.org
2020-12-21 17:11 ` ebotcazou at gcc dot gnu.org
2020-12-21 17:20 ` cvs-commit at gcc dot gnu.org
2020-12-21 17:42 ` nathan at gcc dot gnu.org
2020-12-22  6:58 ` nikhil.benesch at gmail dot com
2020-12-22 12:45 ` nathan at gcc dot gnu.org

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).