[Bug ada/56588] New: gnatmake crash with incorrect SAL GPR
simon at pushface dot org
gcc-bugzilla@gcc.gnu.org
Sun Mar 10 16:02:00 GMT 2013
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56588
Bug #: 56588
Summary: gnatmake crash with incorrect SAL GPR
Classification: Unclassified
Product: gcc
Version: 4.8.0
Status: UNCONFIRMED
Severity: minor
Priority: P3
Component: ada
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: simon@pushface.org
Created attachment 29634
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=29634
Demonstrator
If a SAL GPR mistakenly includes the name of a separate body in the
Library_Interface, gnatmake crashes with a SEGV.
This problem is present in at least GNAT GPL 2012, GCC 4.7.0, and GCC 4.8.0
20130309 (experimental) [trunk revision 196573].
Using the attached demonstrator (source.tar.gz),
$ gnatmake -f -p -P source
gcc -c -fPIC -I- -gnatA /Users/simon/tmp/gnatmake-bug/source.adb
gnatbind -n -o b~source.adb -Lsource -a ...
gcc -c -gnatws b~source.adb -fPIC
building dynamic library for project source
gcc -dynamiclib -o /Users/simon/tmp/gnatmake-bug/lib//libsource.dylib ...
/Users/simon/tmp/gnatmake-bug/.build/b~source.o ...
Segmentation fault: 11
I've attached a patch, but you may not like the reporting style. With the
patch, the result is
$ gnatmake -f -p -P source
gcc -c -fPIC -I- -gnatA /Users/simon/tmp/gnatmake-bug/source.adb
gnatbind -n -o b~source.adb -Lsource -a ...
gcc -c -gnatws b~source.adb -fPIC
building dynamic library for project source
gcc -dynamiclib -o /Users/simon/tmp/gnatmake-bug/lib//libsource.dylib ...
/Users/simon/tmp/gnatmake-bug/.build/b~source.o ...
gnatmake: source-proc.ali not found (source may be subunit?)
More information about the Gcc-bugs
mailing list