|
| 1 | +abstract project Switches |
| 2 | +is |
| 3 | + Compiler_Switches := |
| 4 | + ( |
| 5 | + "-gnatA" -- Avoid processing gnat.adc, if present file will be ignored |
| 6 | + |
| 7 | + -- ,"-gnatef" -- Full source path in brief error messages |
| 8 | + |
| 9 | + -- Disabled due to a bug in GNAT Community 2018 |
| 10 | + --,"-gnateV" -- Validity checks on subprogram parameters |
| 11 | + |
| 12 | + ,"-gnatf" -- Full errors. Verbose details, all undefined references |
| 13 | + ,"-gnatU" -- Enable unique tag for error messages |
| 14 | + |
| 15 | + -- Validity checks |
| 16 | + ,"-gnatVa" -- turn on all validity checking options |
| 17 | + |
| 18 | + -- Warnings |
| 19 | + ,"-gnatwa" -- turn on all info/warnings marked with + in gnatmake help |
| 20 | + ,"-gnatwe" -- treat all warnings (but not info) as errors |
| 21 | + ,"-gnatwd" -- turn on warnings for implicit dereference |
| 22 | + ,"-gnatwh" -- turn on warnings for hiding declarations |
| 23 | + ,"-gnatwk" -- turn on warnings for standard redefinition |
| 24 | + ,"-gnatwt" -- turn on warnings for tracking deleted code |
| 25 | + ,"-gnatwu" -- turn on warnings for unordered enumeration |
| 26 | + |
| 27 | + -- Style checks |
| 28 | + ,"-gnaty3" -- Check indentation (3 spaces) |
| 29 | + ,"-gnatya" -- check attribute casing |
| 30 | + ,"-gnatyA" -- check array attribute indexes |
| 31 | + ,"-gnatyb" -- check no blanks at end of lines |
| 32 | + ,"-gnatyc" -- check comment format (two spaces) |
| 33 | + ,"-gnatyd" -- check no DOS line terminators |
| 34 | + ,"-gnatye" -- check end/exit labels present |
| 35 | + ,"-gnatyf" -- check no form feeds/vertical tabs in source |
| 36 | + ,"-gnatyh" -- check no horizontal tabs in source |
| 37 | + ,"-gnatyi" -- check if-then layout |
| 38 | + ,"-gnatyI" -- check mode in |
| 39 | + ,"-gnatyk" -- check casing rules for keywords |
| 40 | + ,"-gnatyl" -- check reference manual layout |
| 41 | + ,"-gnatyL8" -- check max nest level < nn |
| 42 | + ,"-gnatyM120" -- check line length <= nn characters |
| 43 | + ,"-gnatyn" -- check casing of package Standard identifiers |
| 44 | + ,"-gnatyO" -- check overriding indicators |
| 45 | + ,"-gnatyp" -- check pragma casing |
| 46 | + ,"-gnatyr" -- check casing for identifier references |
| 47 | + ,"-gnatys" -- check separate subprogram specs present |
| 48 | + ,"-gnatyS" -- check separate lines after THEN or ELSE |
| 49 | + ,"-gnatyt" -- check token separation rules |
| 50 | + ,"-gnatyu" -- check no unnecessary blank lines |
| 51 | + ,"-gnatyx" -- check extra parentheses around conditionals |
| 52 | + |
| 53 | + ); |
| 54 | + |
| 55 | + Compiler_Debug_Switches := |
| 56 | + ( |
| 57 | + "-fstack-check" -- dynamic stack checking |
| 58 | + ,"-gnata" -- Enable pragma Assert/Debug |
| 59 | + ,"-gnato" -- Overflow checking |
| 60 | + ,"-g" -- Debug symbols |
| 61 | + ,"-O0" -- Debug symbols |
| 62 | + ); |
| 63 | + |
| 64 | +end Switches; |
0 commit comments