/usr/share/gps/plug-ins/ada-support.xml is in gnat-gps-common 5.0-16.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 | <?xml version="1.0" ?>
<!-- This file provides support for Ada and GNAT:
The switches are no more defined here, but in ada_support.py. Only tools
names are defined so that they appear before other tools in the editor
(this module is loaded first).
This also includes predefined search patterns.
And finally a number of predefined text aliases are defined.
-->
<GPS>
<tool name="Gnatmake" package="Builder" index="ada">
<language>Ada</language>
<initial-cmd-line></initial-cmd-line>
<switches columns="2">
<title column="1" line="1" >Dependencies</title>
<title column="2" line="1" >Compilation</title>
<check label="Recompile if switches changed" switch="-s"
tip="Recompile if compiler switches have changed since last compilation" />
<check label="Minimal recompilation" switch="-m"
tip="Specifies that the minimum necessary amount of recompilation be performed. In this mode, gnatmake ignores time stamp differences when the only modification to a source file consist in adding or removing comments, empty lines, spaces or tabs" />
<spin label="Multiprocessing" switch="-j" min="0" max="100" default="1"
column="2"
tip="Use N processes to carry out the compilations. On a multiprocessor machine compilations will occur in parallel" />
<check label="Keep going" switch="-k" column="2"
tip="Continue as much as possible after a compilation error" />
<check label="Debug information" switch="-g" column="2"
tip="Add debugging information. This forces the corresponding switch for the compiler, binder and linker" />
<check label="Use mapping file" switch="-C" column="2"
tip="Use a mapping file. A mapping file is a way to communicate to the compiler two mappings: from unit name to file names, and from file names to path names. This will generally improve the compilation time" />
</switches>
</tool>
<tool name="Ada" package="Compiler" index="ada" override="true">
<language>Ada</language>
<initial-cmd-line>-g -gnatQ</initial-cmd-line>
<switches lines="3" columns="2"/>
</tool>
<tool name="Binder" package="Binder" index="ada">
<language>Ada</language>
<switches lines="1">
<check label="Store call stack in exceptions" switch="-E"
tip="Store tracebacks in exception occurrences when the target supports it" />
<check label="List possible restrictions" switch="-r" />
<check label="Shared GNAT run time" switch="-shared" />
</switches>
</tool>
<tool name="Ada Linker" package="Linker" index="ada">
<language>Ada</language>
<initial-cmd-line>-g</initial-cmd-line>
<switches lines="1">
<check label="Strip symbols" switch="-s" />
<check label="Debug information" switch="-g" />
<dependency master-page="Gnatmake" slave-page="Linker"
master-switch="-g" slave-switch="-g"
master-status="on" slave-status="on" />
<check label="Code coverage" switch="-fprofile-generate"
tip="Create data files for the gcov code-coverage utility" />
<dependency master-page="Ada" slave-page="Ada Linker"
master-switch="-ftest-coverage"
slave-switch="-fprofile-generate"
master-status="on" slave-status="on" />
<check label="Remove unused sections (GNU ld only)"
switch="-Wl,--gc-sections"
tip="Remove all unused sections from the link output. This is a GNU ld switch. See also -ffunction-sections and -fdata-sections compiler flags" />
</switches>
</tool>
<vsearch-pattern>
<name>Ada: type NAME is array (...)</name>
<regexp>\btype\s+(\w+)\s+is\s+array\s+\((.*?)\)\s+of\s+\w+\s*;</regexp>
</vsearch-pattern>
<vsearch-pattern>
<name>Ada: when CHOICE =></name>
<regexp>\bwhen\s+((\w+)\s+:\s+)?[\w\s|]+\s*=></regexp>
</vsearch-pattern>
<vsearch-pattern>
<name>Ada: (sub)type NAME is</name>
<regexp>\b((sub)?type\s+(\w+)|type\s+(\w+)\s+(\(.*?\))?)\s+is\b</regexp>
</vsearch-pattern>
<vsearch-pattern>
<name>Ada: type NAME (...) is</name>
<regexp>\btype\s+(\w+)\s+\((.*?)\)\s+is\b</regexp>
</vsearch-pattern>
<vsearch-pattern>
<name>Ada: for VAR in ... loop</name>
<regexp>\bfor\s+(\w+)\s+in\s+(reverse\s+)?(.+?)(\s+range\s+(.*?))?\s+loop\b</regexp>
</vsearch-pattern>
<vsearch-pattern>
<name>Ada: assignment</name>
<regexp>\b(\w+)\s*:=</regexp>
</vsearch-pattern>
<alias name="procedure is" >
<param name="name" />
<param name="params" />
<text>procedure %(name) (%(params)) is
begin
%_
end %(name);</text>
</alias>
<alias name="task body" >
<param name="name" />
<text>task body %(name) is
begin
%_
end %(name);</text>
</alias>
<alias name="select" >
<param name="entry2" />
<param name="entry" />
<text>select
accept %(entry) do
%_
end %(entry);
or
accept %(entry2) do
null;
end %(entry2);
end select;</text>
</alias>
<alias name="function is" >
<param name="name" />
<param name="params" />
<param name="return_type" />
<text>function %(name) (%(params)) return %(return_type) is
begin
return %_
end %(name);</text>
</alias>
<alias name="declare" >
<text>declare
%_
begin
null;
end;</text>
</alias>
<alias name="for" >
<param name="range" />
<param name="index" />
<text>for %(index) in %(range) loop
%_
end loop;</text>
</alias>
<alias name="procedure" >
<param name="name" />
<text>procedure %(name)%_;</text>
</alias>
<alias name="package body" >
<param name="name" />
<text>package body %(name) is
%_
end %(name);</text>
</alias>
<alias name="task" >
<param name="name" />
<text>task %(name) is
%_
end %(name);</text>
</alias>
<alias name="loop" >
<param name="exit_condition" />
<text>loop
%_
exit when %(exit_condition);
end loop;</text>
</alias>
<alias name="case" >
<param name="choice" />
<param name="expression" />
<text>case %(expression) is
when %(choice) =>
%_
end case;</text>
</alias>
<alias name="while" >
<param name="condition" />
<text>while %(condition) loop
%_
end loop;</text>
</alias>
<alias name="package" >
<param name="name" />
<text>package %(name) is
%_
end %(name);</text>
</alias>
<alias name="if" >
<param name="condition" />
<text>if %(condition) then
%_
end if;</text>
</alias>
<alias name="function" >
<param name="name" />
<param name="params" />
<text>function %(name) (%(params)) return %_;</text>
</alias>
<alias name="array" >
<param name="range" />
<text>array (%(range)) of %_;</text>
</alias>
<alias name="exception" >
<param name="error" />
<text>exception
when %(error) =>
%_</text>
</alias>
<alias name="begin" >
<text>begin
%_
end;</text>
</alias>
</GPS>
|