https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83027
Bug ID: 83027 Summary: Hang when attaching a SIGINT handler Product: gcc Version: 7.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: ada Assignee: unassigned at gcc dot gnu.org Reporter: porton at narod dot ru Target Milestone: --- Created attachment 42630 --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=42630&action=edit The source reprising the bug Extract attached bug.zip into an empty directory. Run make compile ./obj/simple_test The command simple_test hangs. The most wonderful thing is that if I do not compile it (as "make compile" does) as an .a library imported when linking simple_test, but put all source into a single directory and run "gnatmake simple_test", then the error does not happen (but Program_Error is raised as it should be accordingly the docs, because pragma Unreserve_All_Interrupts is not in effect in this example code). Another weird thing that it happens with SIGINT but not with SIGTERM nor with SIGCHLD. The bug also does not happen if I remove "with Ada.Text_IO;". GCC 7.2.0.