-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathopengl_tutorial.gpr
226 lines (147 loc) · 6.2 KB
/
opengl_tutorial.gpr
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
with "../OpenGLAda/opengl.gpr";
limited with "../OpenGLAda/opengl-glfw.gpr";
project OpenGL_Tutorial is
type Library_Kinds1 is
("static", "relocatable");
for Object_Dir use "obj";
type Glfw_Version_Type is
("2", "3");
Glfw_Version : Glfw_Version_Type := external ("GLFW_Version");
type Library_Kinds is
("static", "relocatable");
Library_Type : Library_Kinds := external ("Library_Type");
type Toggle_Type is
("enabled", "disabled");
Auto_Exceptions : Toggle_Type := external ("Auto_Exceptions");
type Mode_Type is
("debug", "release");
Mode : Mode_Type := external ("Mode");
-- Different operating systems need different linker
-- flags. Moreover, some features (such as WGL, GLX,
-- CGL) are only available on one specific platform.
-- Supported values:
-- * windows : Microsoft Windows
-- * x11 : X Window System
-- * quartz : Quartz Compositor (OS X)
type Windowing_System_Type is
("windows", "x11", "quartz");
Windowing_System : Windowing_System_Type := external ("Windowing_System");
LIBRARY_TYPE : Library_Kinds1 := external ("LIBRARY_TYPE");
case Glfw_Version is
when "2" =>
case LIBRARY_TYPE is
when "static" =>
case Auto_Exceptions is
when "enabled" =>
case Mode is
when "debug" =>
case Windowing_System is
when "windows" =>
case Library_Type is
when "static" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src/**");
when "relocatable" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "x11" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
when "quartz" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "release" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "disabled" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "relocatable" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "3" =>
case Library_Type is
when "static" =>
case Auto_Exceptions is
when "enabled" =>
case Mode is
when "debug" =>
case Windowing_System is
when "windows" =>
for Main use ("gl_1.adb", "gl_2.adb", "gl_3_1.adb", "gl_3_2.adb", "gl_3_3.adb", "gl_4_1.adb", "gl_4_2.adb");
for Source_Dirs use ("src/**");
for Exec_Dir use "bin";
when "x11" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
when "quartz" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "release" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "disabled" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
when "relocatable" =>
for Main use ("gl_1.adb");
for Source_Dirs use ("src");
end case;
end case;
package Compiler is
case Glfw_Version is
when "2" =>
when "3" =>
case Library_Type is
when "static" =>
case Auto_Exceptions is
when "enabled" =>
case Mode is
when "debug" =>
case Windowing_System is
when "windows" =>
for Switches ("ada") use ("-gnat12");
when "x11" =>
when "quartz" =>
end case;
when "release" =>
end case;
when "disabled" =>
end case;
when "relocatable" =>
end case;
end case;
end Compiler;
package Ide is
case Glfw_Version is
when "2" =>
when "3" =>
case Library_Type is
when "static" =>
case Auto_Exceptions is
when "enabled" =>
case Mode is
when "debug" =>
case Windowing_System is
when "windows" =>
for Vcs_Kind use "Git";
when "x11" =>
when "quartz" =>
end case;
when "release" =>
end case;
when "disabled" =>
end case;
when "relocatable" =>
end case;
end case;
end Ide;
end OpenGL_Tutorial;