-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathincbinfs.c
364 lines (359 loc) · 16.3 KB
/
incbinfs.c
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
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
#include <stddef.h>
#include <stdio.h>
#define REF(visible_name, underscored_name) \
do { \
extern const void _binary_assets_ ## underscored_name ## _start; \
extern const void _binary_assets_ ## underscored_name ## _size; \
stdio_add_inode(visible_name, \
&_binary_assets_ ## underscored_name ## _start, \
(size_t)&_binary_assets_ ## underscored_name ## _size); \
} while (0)
void init_incbinfs(void)
{
/* Usually the name in the FS (the string) is just the symbol name
* (i.e. the name of the original file with underscores instead of
* non-\w characters) translated back to a normal filename.
* Exceptions are marked with exclamation mark comments. */
REF("/abort.png", abort_png);
REF("/army-none.png", army_none_png);
REF("/army-blue-1.png", army_blue_1_png);
REF("/army-blue-2.png", army_blue_2_png);
REF("/army-blue-3.png", army_blue_3_png);
REF("/army-blue-4.png", army_blue_4_png);
REF("/army-blue-5.png", army_blue_5_png);
REF("/army-blue-6.png", army_blue_6_png);
REF("/army-blue-7.png", army_blue_7_png);
REF("/army-blue-8.png", army_blue_8_png);
REF("/army-blue-9.png", army_blue_9_png);
REF("/army-blue-10.png", army_blue_10_png);
REF("/army-blue-11.png", army_blue_11_png);
REF("/army-blue-12.png", army_blue_12_png);
REF("/army-blue-13.png", army_blue_13_png);
REF("/army-blue-14.png", army_blue_14_png);
REF("/army-blue-15.png", army_blue_15_png);
REF("/army-blue-16.png", army_blue_16_png);
REF("/army-blue-17.png", army_blue_17_png);
REF("/army-blue-18.png", army_blue_18_png);
REF("/army-blue-19.png", army_blue_19_png);
REF("/army-blue-20.png", army_blue_20_png);
REF("/army-blue-21.png", army_blue_21_png);
REF("/army-blue-22.png", army_blue_22_png);
REF("/army-blue-23.png", army_blue_23_png);
REF("/army-blue-24.png", army_blue_24_png);
REF("/army-blue-25.png", army_blue_25_png);
REF("/army-blue-26.png", army_blue_26_png);
REF("/army-blue-27.png", army_blue_27_png);
REF("/army-blue-28.png", army_blue_28_png);
REF("/army-blue-29.png", army_blue_29_png);
REF("/army-blue-30.png", army_blue_30_png);
REF("/army-blue-31.png", army_blue_31_png);
REF("/army-blue-32.png", army_blue_32_png);
REF("/army-blue-33.png", army_blue_33_png);
REF("/army-blue-34.png", army_blue_34_png);
REF("/army-blue-35.png", army_blue_35_png);
REF("/army-blue-36.png", army_blue_36_png);
REF("/army-blue-37.png", army_blue_37_png);
REF("/army-blue-38.png", army_blue_38_png);
REF("/army-blue-39.png", army_blue_39_png);
REF("/army-blue-40.png", army_blue_40_png);
REF("/army-blue-41.png", army_blue_41_png);
REF("/army-blue-42.png", army_blue_42_png);
REF("/army-blue-43.png", army_blue_43_png);
REF("/army-blue-44.png", army_blue_44_png);
REF("/army-blue-45.png", army_blue_45_png);
REF("/army-blue-46.png", army_blue_46_png);
REF("/army-blue-47.png", army_blue_47_png);
REF("/army-blue-48.png", army_blue_48_png);
REF("/army-blue-49.png", army_blue_49_png);
REF("/army-blue-50.png", army_blue_50_png);
REF("/army-blue-51.png", army_blue_51_png);
REF("/army-blue-52.png", army_blue_52_png);
REF("/army-blue-53.png", army_blue_53_png);
REF("/army-blue-54.png", army_blue_54_png);
REF("/army-blue-55.png", army_blue_55_png);
REF("/army-blue-56.png", army_blue_56_png);
REF("/army-blue-57.png", army_blue_57_png);
REF("/army-blue-58.png", army_blue_58_png);
REF("/army-blue-59.png", army_blue_59_png);
REF("/army-blue-60.png", army_blue_60_png);
REF("/army-blue-61.png", army_blue_61_png);
REF("/army-blue-62.png", army_blue_62_png);
REF("/army-blue-63.png", army_blue_63_png);
REF("/army-blue-64.png", army_blue_64_png);
REF("/army-blue-65.png", army_blue_65_png);
REF("/army-blue-66.png", army_blue_66_png);
REF("/army-blue-67.png", army_blue_67_png);
REF("/army-blue-68.png", army_blue_68_png);
REF("/army-blue-69.png", army_blue_69_png);
REF("/army-blue-70.png", army_blue_70_png);
REF("/army-blue-71.png", army_blue_71_png);
REF("/army-blue-72.png", army_blue_72_png);
REF("/army-blue-73.png", army_blue_73_png);
REF("/army-blue-74.png", army_blue_74_png);
REF("/army-blue-75.png", army_blue_75_png);
REF("/army-blue-76.png", army_blue_76_png);
REF("/army-blue-77.png", army_blue_77_png);
REF("/army-blue-78.png", army_blue_78_png);
REF("/army-blue-79.png", army_blue_79_png);
REF("/army-blue-80.png", army_blue_80_png);
REF("/army-blue-81.png", army_blue_81_png);
REF("/army-blue-82.png", army_blue_82_png);
REF("/army-blue-83.png", army_blue_83_png);
REF("/army-blue-84.png", army_blue_84_png);
REF("/army-blue-85.png", army_blue_85_png);
REF("/army-blue-86.png", army_blue_86_png);
REF("/army-blue-87.png", army_blue_87_png);
REF("/army-blue-88.png", army_blue_88_png);
REF("/army-blue-89.png", army_blue_89_png);
REF("/army-blue-90.png", army_blue_90_png);
REF("/army-blue-91.png", army_blue_91_png);
REF("/army-blue-92.png", army_blue_92_png);
REF("/army-blue-93.png", army_blue_93_png);
REF("/army-blue-94.png", army_blue_94_png);
REF("/army-blue-95.png", army_blue_95_png);
REF("/army-blue-96.png", army_blue_96_png);
REF("/army-blue-97.png", army_blue_97_png);
REF("/army-blue-98.png", army_blue_98_png);
REF("/army-blue-99.png", army_blue_99_png);
REF("/army-gray-1.png", army_gray_1_png);
REF("/army-gray-2.png", army_gray_2_png);
REF("/army-gray-3.png", army_gray_3_png);
REF("/army-gray-4.png", army_gray_4_png);
REF("/army-gray-5.png", army_gray_5_png);
REF("/army-gray-6.png", army_gray_6_png);
REF("/army-gray-7.png", army_gray_7_png);
REF("/army-gray-8.png", army_gray_8_png);
REF("/army-gray-9.png", army_gray_9_png);
REF("/army-gray-10.png", army_gray_10_png);
REF("/army-gray-11.png", army_gray_11_png);
REF("/army-gray-12.png", army_gray_12_png);
REF("/army-gray-13.png", army_gray_13_png);
REF("/army-gray-14.png", army_gray_14_png);
REF("/army-gray-15.png", army_gray_15_png);
REF("/army-gray-16.png", army_gray_16_png);
REF("/army-gray-17.png", army_gray_17_png);
REF("/army-gray-18.png", army_gray_18_png);
REF("/army-gray-19.png", army_gray_19_png);
REF("/army-gray-20.png", army_gray_20_png);
REF("/army-gray-21.png", army_gray_21_png);
REF("/army-gray-22.png", army_gray_22_png);
REF("/army-gray-23.png", army_gray_23_png);
REF("/army-gray-24.png", army_gray_24_png);
REF("/army-gray-25.png", army_gray_25_png);
REF("/army-gray-26.png", army_gray_26_png);
REF("/army-gray-27.png", army_gray_27_png);
REF("/army-gray-28.png", army_gray_28_png);
REF("/army-gray-29.png", army_gray_29_png);
REF("/army-gray-30.png", army_gray_30_png);
REF("/army-gray-31.png", army_gray_31_png);
REF("/army-gray-32.png", army_gray_32_png);
REF("/army-gray-33.png", army_gray_33_png);
REF("/army-gray-34.png", army_gray_34_png);
REF("/army-gray-35.png", army_gray_35_png);
REF("/army-gray-36.png", army_gray_36_png);
REF("/army-gray-37.png", army_gray_37_png);
REF("/army-gray-38.png", army_gray_38_png);
REF("/army-gray-39.png", army_gray_39_png);
REF("/army-gray-40.png", army_gray_40_png);
REF("/army-gray-41.png", army_gray_41_png);
REF("/army-gray-42.png", army_gray_42_png);
REF("/army-gray-43.png", army_gray_43_png);
REF("/army-gray-44.png", army_gray_44_png);
REF("/army-gray-45.png", army_gray_45_png);
REF("/army-gray-46.png", army_gray_46_png);
REF("/army-gray-47.png", army_gray_47_png);
REF("/army-gray-48.png", army_gray_48_png);
REF("/army-gray-49.png", army_gray_49_png);
REF("/army-gray-50.png", army_gray_50_png);
REF("/army-gray-51.png", army_gray_51_png);
REF("/army-gray-52.png", army_gray_52_png);
REF("/army-gray-53.png", army_gray_53_png);
REF("/army-gray-54.png", army_gray_54_png);
REF("/army-gray-55.png", army_gray_55_png);
REF("/army-gray-56.png", army_gray_56_png);
REF("/army-gray-57.png", army_gray_57_png);
REF("/army-gray-58.png", army_gray_58_png);
REF("/army-gray-59.png", army_gray_59_png);
REF("/army-gray-60.png", army_gray_60_png);
REF("/army-gray-61.png", army_gray_61_png);
REF("/army-gray-62.png", army_gray_62_png);
REF("/army-gray-63.png", army_gray_63_png);
REF("/army-gray-64.png", army_gray_64_png);
REF("/army-gray-65.png", army_gray_65_png);
REF("/army-gray-66.png", army_gray_66_png);
REF("/army-gray-67.png", army_gray_67_png);
REF("/army-gray-68.png", army_gray_68_png);
REF("/army-gray-69.png", army_gray_69_png);
REF("/army-gray-70.png", army_gray_70_png);
REF("/army-gray-71.png", army_gray_71_png);
REF("/army-gray-72.png", army_gray_72_png);
REF("/army-gray-73.png", army_gray_73_png);
REF("/army-gray-74.png", army_gray_74_png);
REF("/army-gray-75.png", army_gray_75_png);
REF("/army-gray-76.png", army_gray_76_png);
REF("/army-gray-77.png", army_gray_77_png);
REF("/army-gray-78.png", army_gray_78_png);
REF("/army-gray-79.png", army_gray_79_png);
REF("/army-gray-80.png", army_gray_80_png);
REF("/army-gray-81.png", army_gray_81_png);
REF("/army-gray-82.png", army_gray_82_png);
REF("/army-gray-83.png", army_gray_83_png);
REF("/army-gray-84.png", army_gray_84_png);
REF("/army-gray-85.png", army_gray_85_png);
REF("/army-gray-86.png", army_gray_86_png);
REF("/army-gray-87.png", army_gray_87_png);
REF("/army-gray-88.png", army_gray_88_png);
REF("/army-gray-89.png", army_gray_89_png);
REF("/army-gray-90.png", army_gray_90_png);
REF("/army-gray-91.png", army_gray_91_png);
REF("/army-gray-92.png", army_gray_92_png);
REF("/army-gray-93.png", army_gray_93_png);
REF("/army-gray-94.png", army_gray_94_png);
REF("/army-gray-95.png", army_gray_95_png);
REF("/army-gray-96.png", army_gray_96_png);
REF("/army-gray-97.png", army_gray_97_png);
REF("/army-gray-98.png", army_gray_98_png);
REF("/army-gray-99.png", army_gray_99_png);
REF("/army-red-1.png", army_red_1_png);
REF("/army-red-2.png", army_red_2_png);
REF("/army-red-3.png", army_red_3_png);
REF("/army-red-4.png", army_red_4_png);
REF("/army-red-5.png", army_red_5_png);
REF("/army-red-6.png", army_red_6_png);
REF("/army-red-7.png", army_red_7_png);
REF("/army-red-8.png", army_red_8_png);
REF("/army-red-9.png", army_red_9_png);
REF("/army-red-10.png", army_red_10_png);
REF("/army-red-11.png", army_red_11_png);
REF("/army-red-12.png", army_red_12_png);
REF("/army-red-13.png", army_red_13_png);
REF("/army-red-14.png", army_red_14_png);
REF("/army-red-15.png", army_red_15_png);
REF("/army-red-16.png", army_red_16_png);
REF("/army-red-17.png", army_red_17_png);
REF("/army-red-18.png", army_red_18_png);
REF("/army-red-19.png", army_red_19_png);
REF("/army-red-20.png", army_red_20_png);
REF("/army-red-21.png", army_red_21_png);
REF("/army-red-22.png", army_red_22_png);
REF("/army-red-23.png", army_red_23_png);
REF("/army-red-24.png", army_red_24_png);
REF("/army-red-25.png", army_red_25_png);
REF("/army-red-26.png", army_red_26_png);
REF("/army-red-27.png", army_red_27_png);
REF("/army-red-28.png", army_red_28_png);
REF("/army-red-29.png", army_red_29_png);
REF("/army-red-30.png", army_red_30_png);
REF("/army-red-31.png", army_red_31_png);
REF("/army-red-32.png", army_red_32_png);
REF("/army-red-33.png", army_red_33_png);
REF("/army-red-34.png", army_red_34_png);
REF("/army-red-35.png", army_red_35_png);
REF("/army-red-36.png", army_red_36_png);
REF("/army-red-37.png", army_red_37_png);
REF("/army-red-38.png", army_red_38_png);
REF("/army-red-39.png", army_red_39_png);
REF("/army-red-40.png", army_red_40_png);
REF("/army-red-41.png", army_red_41_png);
REF("/army-red-42.png", army_red_42_png);
REF("/army-red-43.png", army_red_43_png);
REF("/army-red-44.png", army_red_44_png);
REF("/army-red-45.png", army_red_45_png);
REF("/army-red-46.png", army_red_46_png);
REF("/army-red-47.png", army_red_47_png);
REF("/army-red-48.png", army_red_48_png);
REF("/army-red-49.png", army_red_49_png);
REF("/army-red-50.png", army_red_50_png);
REF("/army-red-51.png", army_red_51_png);
REF("/army-red-52.png", army_red_52_png);
REF("/army-red-53.png", army_red_53_png);
REF("/army-red-54.png", army_red_54_png);
REF("/army-red-55.png", army_red_55_png);
REF("/army-red-56.png", army_red_56_png);
REF("/army-red-57.png", army_red_57_png);
REF("/army-red-58.png", army_red_58_png);
REF("/army-red-59.png", army_red_59_png);
REF("/army-red-60.png", army_red_60_png);
REF("/army-red-61.png", army_red_61_png);
REF("/army-red-62.png", army_red_62_png);
REF("/army-red-63.png", army_red_63_png);
REF("/army-red-64.png", army_red_64_png);
REF("/army-red-65.png", army_red_65_png);
REF("/army-red-66.png", army_red_66_png);
REF("/army-red-67.png", army_red_67_png);
REF("/army-red-68.png", army_red_68_png);
REF("/army-red-69.png", army_red_69_png);
REF("/army-red-70.png", army_red_70_png);
REF("/army-red-71.png", army_red_71_png);
REF("/army-red-72.png", army_red_72_png);
REF("/army-red-73.png", army_red_73_png);
REF("/army-red-74.png", army_red_74_png);
REF("/army-red-75.png", army_red_75_png);
REF("/army-red-76.png", army_red_76_png);
REF("/army-red-77.png", army_red_77_png);
REF("/army-red-78.png", army_red_78_png);
REF("/army-red-79.png", army_red_79_png);
REF("/army-red-80.png", army_red_80_png);
REF("/army-red-81.png", army_red_81_png);
REF("/army-red-82.png", army_red_82_png);
REF("/army-red-83.png", army_red_83_png);
REF("/army-red-84.png", army_red_84_png);
REF("/army-red-85.png", army_red_85_png);
REF("/army-red-86.png", army_red_86_png);
REF("/army-red-87.png", army_red_87_png);
REF("/army-red-88.png", army_red_88_png);
REF("/army-red-89.png", army_red_89_png);
REF("/army-red-90.png", army_red_90_png);
REF("/army-red-91.png", army_red_91_png);
REF("/army-red-92.png", army_red_92_png);
REF("/army-red-93.png", army_red_93_png);
REF("/army-red-94.png", army_red_94_png);
REF("/army-red-95.png", army_red_95_png);
REF("/army-red-96.png", army_red_96_png);
REF("/army-red-97.png", army_red_97_png);
REF("/army-red-98.png", army_red_98_png);
REF("/army-red-99.png", army_red_99_png);
REF("/attacked-region.png", attacked_region_png);
REF("/attacking-region.png", attacking_region_png);
REF("/battle.ogg", battle_ogg);
REF("/battle.png", battle_png);
REF("/beep1.ogg", beep1_ogg);
REF("/beep2.ogg", beep2_ogg);
REF("/bg.png", bg_png);
REF("/capture.ogg", capture_ogg);
REF("/card-bg.png", card_bg_png);
REF("/card-design-0.png", card_infantry_png); // !
REF("/card-design-1.png", card_cavalry_png); // !
REF("/card-design-2.png", card_artillery_png); // !
REF("/card-design-3.png", card_wildcard_png); // !
REF("/card-hover.png", card_hover_png);
REF("/card-selected.png", card_selected_png);
REF("/cursor.png", cursor_png);
REF("/defeat.png", defeat_png);
REF("/destination-region.png", destination_region_png);
REF("/die-1.png", die_1_png);
REF("/die-2.png", die_2_png);
REF("/die-3.png", die_3_png);
REF("/die-4.png", die_4_png);
REF("/die-5.png", die_5_png);
REF("/die-6.png", die_6_png);
REF("/error-icon.png", error_icon_png);
REF("/focus-region.png", focus_region_png);
REF("/font.npf", font_npf);
REF("/game-over.png", game_over_png);
REF("/loading.png", loading_png);
REF("/movement.ogg", movement_ogg);
REF("/movement.png", movement_png);
REF("/music.ogg", music_ogg);
REF("/notification.ogg", notification_ogg);
REF("/origin-region.png", origin_region_png);
REF("/preparation.png", preparation_png);
REF("/region-areas.png", region_areas_png);
REF("/reinforcements.ogg", reinforcements_ogg);
REF("/reinforcements.png", reinforcements_png);
REF("/trade-in.png", trade_in_png);
REF("/victory.ogg", victory_ogg);
REF("/victory.png", victory_png);
REF("/waiting-for-other.png", waiting_for_other_png);
REF("/waiting-for-other.png", waiting_for_other_png);
}