Bug 26293 - [ada] FAIL: gdb.ada/mi_prot.exp: compilation prot.adb (gcc 7.5.0)
Summary: [ada] FAIL: gdb.ada/mi_prot.exp: compilation prot.adb (gcc 7.5.0)
Status: RESOLVED FIXED
Alias: None
Product: gdb
Classification: Unclassified
Component: testsuite (show other bugs)
Version: HEAD
: P2 normal
Target Milestone: 10.1
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-07-23 12:58 UTC by Tom de Vries
Modified: 2020-07-24 12:12 UTC (History)
1 user (show)

See Also:
Host:
Target:
Build:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom de Vries 2020-07-23 12:58:32 UTC
With gcc 7.5.0, I run into:
...
gcc -c -I./ -gnata -I/home/vries/gdb_versions/devel/src/gdb/testsuite/gdb.ada/mi_prot -g -lm -I- /home/vries/gdb_versions/devel/binutils-gdb.git/gdb/testsuite/gdb.ada/mi_prot/prot.adb^M
prot.adb:21:04: info: "Obj_Type" is frozen here, aspects evaluated at this point^M
prot.adb:23:09: visibility of aspect for "Obj_Type" changes after freeze point^M
gnatmake: "/home/vries/gdb_versions/devel/binutils-gdb.git/gdb/testsuite/gdb.ada/mi_prot/prot.adb" compilation error^M
compiler exited with status 1
compilation failed: gcc -c -I./ -gnata -I/home/vries/gdb_versions/devel/src/gdb/testsuite/gdb.ada/mi_prot -g -lm -I- /home/vries/gdb_versions/devel/binutils-gdb.git/gdb/testsuite/gdb.ada/mi_prot/prot.adb
prot.adb:21:04: info: "Obj_Type" is frozen here, aspects evaluated at this point
prot.adb:23:09: visibility of aspect for "Obj_Type" changes after freeze point
gnatmake: "/home/vries/gdb_versions/devel/binutils-gdb.git/gdb/testsuite/gdb.ada/mi_prot/prot.adb" compilation error

FAIL: gdb.ada/mi_prot.exp: compilation prot.adb
...

Works fine with 8.4.0.
Comment 1 Tom de Vries 2020-07-23 13:10:01 UTC
Can probably be fixed using gnatmake_version_at_least 8.
Comment 2 Sourceware Commits 2020-07-24 12:10:54 UTC
The master branch has been updated by Tom de Vries <vries@sourceware.org>:

https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=6dcfb80a28a571999a8cf2346bfc4665d56912ae

commit 6dcfb80a28a571999a8cf2346bfc4665d56912ae
Author: Tom de Vries <tdevries@suse.de>
Date:   Fri Jul 24 14:10:50 2020 +0200

    [gdb/testsuite] Require gnatmake-8 for gdb.ada/mi_prot.exp
    
    With gcc-7, I run into:
    ...
    gcc -c -I./ -gnata -Isrc/gdb/testsuite/gdb.ada/mi_prot -g -lm -I- \
      src/gdb/testsuite/gdb.ada/mi_prot/prot.adb^M
    prot.adb:21:04: info: "Obj_Type" is frozen here, aspects evaluated at this \
      point^M
    prot.adb:23:09: visibility of aspect for "Obj_Type" changes after freeze \
      point^M
    gnatmake: "src/gdb/testsuite/gdb.ada/mi_prot/prot.adb" compilation error^M
    compiler exited with status 1
      ...
    FAIL: gdb.ada/mi_prot.exp: compilation prot.adb
    ...
    
    Fix this by requiring gnatmake-8 for this test-case.
    
    Tested on x86_64-linux, with gnatmake-7, gnatmake-8 and gnatmake-11.
    
    gdb/testsuite/ChangeLog:
    
    2020-07-24  Tom de Vries  <tdevries@suse.de>
    
            PR testsuite/26293
            * gdb.ada/mi_prot.exp: Require gnatmake-8.
Comment 3 Tom de Vries 2020-07-24 12:12:54 UTC
Patch fixing test-case committed, marking resolved-fixed.