-
Notifications
You must be signed in to change notification settings - Fork 19
/
config.h.in
447 lines (337 loc) · 10.2 KB
/
config.h.in
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
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
#ifndef _OCP_CONFIG_H
#define _OCP_CONFIG_H 1
#define _GNU_SOURCE 1
#define _XOPEN_SOURCE_EXTENDED 1 // needed for ncurses wide
#define _FILE_OFFSET_BITS 64
#undef WORDS_BIGENDIAN
#if __STDC_VERSION__ < 199901L
# if __GNUC__ >= 2
# define __func__ __FUNCTION__
# else
# define __func__ "<unknown>"
# endif
#endif
#undef HAVE_CURSES
#undef HAVE_CURSES_ENHANCED
#undef HAVE_CURSES_COLOR
#undef HAVE_CURSES_OBSOLETE
#undef HAVE_NCURSESW
#undef HAVE_NCURSES
#undef HAVE_CURSES_H
#undef HAVE_NCURSESW_H
#undef HAVE_NCURSES_H
#undef HAVE_NCURSESW_CURSES_H
#undef HAVE_NCURSES_CURSES_H
#ifndef NO_CURSES /* some source files have symbols that crashes with ncurses macros etc. */
# if defined HAVE_NCURSESW_CURSES_H
# include <ncursesw/curses.h>
# elif defined HAVE_NCURSESW_H
# include <ncursesw.h>
# elif defined HAVE_NCURSES_CURSES_H
# include <ncurses/curses.h>
# elif defined HAVE_NCURSES_H
# include <ncurses.h>
# elif defined HAVE_CURSES_H
# include <curses.h>
# else
# include "no-curses.h"
# endif
#endif
#define MAXDLLLIST 150
#define KEY_TAB 9
#define KEY_CTRL_P 0x10
#define KEY_SHIFT_TAB KEY_BTAB /*353*/ /* 0x0f00 curses.h gives us that SHIFT_TAB is BTAB*/
#define _KEY_ENTER 13 /* 13 linux console and curses defines a KEY_ENTER that is something else */
#define KEY_ESC 27
#define KEY_CTRL_D 4 /* 4 linux console */
#define KEY_CTRL_H 8 /* 8 linux console, maps to KEY_BACKSPACE */
#define KEY_CTRL_J 10 /* 10 linux console */
#define KEY_CTRL_K 11 /* 11 linux console */
#define KEY_CTRL_L 12 /* 12 linux console */
#define KEY_CTRL_Q 17 /* 17 linux console */
#define KEY_CTRL_S 19 /* 19 linux console */
#define KEY_CTRL_Z 26 /* 26 linux console */
#define KEY_CTRL_BS 31 /* 0x007f linux console */
#if 0
#define KEY_DOWN 258 /* 0x5000 curses.h */
#define KEY_UP 259 /* 0x4800 curses.h */
#define KEY_LEFT 260 /* 0x4b00 curses.h */
#define KEY_RIGHT 261 /* 0x4d00 curses.h */
#endif
#define KEY_ALT_A 0x1e00 /* 0x1e00 */
#define KEY_ALT_B 0x3000 /* 0x3000 */
#define KEY_ALT_C 0x2e00 /* 0x2e00 */
/*#define KEY_ALT_D 0*/ /* TODO */
#define KEY_ALT_E 0x1200 /* 0x1200 */
/*#define KEY_ALT_F 0*/ /* TODO */
#define KEY_ALT_G 0x2200 /* 0x2200 */
/*#define KEY_ALT_H 0*/ /* TODO */
#define KEY_ALT_I 0x1700 /* 0x1700 */
/*#define KEY_ALT_J 0*/ /* TODO */
#define KEY_ALT_K 0x2500 /* 0x2500 */
#define KEY_ALT_L 0x2600 /* 0x2600 */
#define KEY_ALT_M 0x3200 /* 0x3200 */
/*#define KEY_ALT_N 0*/ /* TODO */
#define KEY_ALT_O 0x1800 /* 0x1800 */
#define KEY_ALT_P 0x1900 /* 0x1900 */
/*#define KEY_ALT_Q 0*/ /* TODO */
#define KEY_ALT_R 0x1300
#define KEY_ALT_S 0x1f00 /* 0x1f00 */
/*#define KEY_ALT_T 0*/ /* TODO */
/*#define KEY_ALT_U 0*/ /* TODO */
/*#define KEY_ALT_V 0*/ /* TODO */
/*#define KEY_ALT_W 0*/ /* 0x1100 TODO */
#define KEY_ALT_X 0x2d00 /* 0x2d00 */
/*#define KEY_ALT_Y 0*/ /* TODO */
#define KEY_ALT_Z 0x2c00 /* 0x2c00 */
/*#define KEY_F(2) 266*/ /* 0x3c00 curses.h */
/*#define KEY_F(3) 267*/ /* 0x3d00 curses.h */
/*#define KEY_F(4) 268*/ /* 0x3e00 curses.h */
/*#define KEY_F(5) 269*/ /* 0x3f00 curses.h */
/*#define KEY_F(6) 270*/ /* 0x4000 curses.h */
/*#define KEY_F(7) 271*/ /* 0x4100 curses.h */
/*#define KEY_F(8) 272*/ /* 0x4200 curses.h */
/*#define KEY_F(9) 273*/ /* 0x4300 curses.h */
/*#define KEY_F(10) 274*/ /* 0x4400 curses.h */
/*#define KEY_F(11) 275*/ /* 0x8500 curses.h */
/*#define KEY_F(12) 276*/ /* 0x8600 curses.h */
#if 0
#define KEY_END 360 /* 0x4f00 curses.h */
#define KEY_HOME 262 /* 0x4700 curses.h */
#endif
#define KEY_CTRL_UP 0x0237 /* 0x8d00 */
#define KEY_CTRL_DOWN 0x020e /* 0x9100 */
#define KEY_CTRL_LEFT 0x0222 /* 0x7300 */
#define KEY_CTRL_RIGHT 0x0231 /* 0x7400 */
#define KEY_CTRL_PGUP 0x8400 /* 0x8400 x11 only */
#define KEY_CTRL_PGDN 0x7600 /* 0x7600 x11 only */
#define KEY_CTRL_HOME 0x0218 /* 0x7700 x11 only */
#define KEY_CTRL_END 0x0213 /* 0x7500 x11 only */
#define KEY_CTRL_DELETE 0x0208 /* 0x9300 x11 only */
#define KEY_CTRL_INSERT 0x9200 /* 0x9200 x11 only */
#define KEY_DELETE KEY_DC/*330*/ /* 0x5300 curses.h delete-key is mapped to delete-character */
#define KEY_INSERT KEY_IC/*331*/ /* 0x5200 curses.h insert-key is mapped to insert-character */
#if 0
#define KEY_NPAGE 338 /* 0x5100 curses.h */
#define KEY_PPAGE 339 /* 0x4900 curses.h */
#endif
#define KEY_CTRL_ENTER 0xff00 /* SDL/SDL2/X11 only */
#define KEY_ALT_ENTER 0xff01 /* used to be 10, collides with ctrl+j */
#define VIRT_KEY_RESIZE 0xff02 /* dummy key */
#define KEY_SHIFT_F(n) KEY_F(n+12) /* ncurses-hack */
#define KEY_CTRL_F(n) KEY_F(n+24) /* ncurses-hack */
#define KEY_CTRL_SHIFT_F(n) KEY_F(n+36) /* ncurses-hack */
/* keys we can't do
KEY_CTRL_ENTER 10
KEY_ALT_F1 0x6800
KEY_ALT_F2 0x6900
KEY_ALT_F3 0x6a00
KEY_ALT_F4 0x6b00
KEY_ALT_F8 0x6f00
KEY_ALT_F9 0x7000
KEY_ALT_TAB 0xa500 pfilesel.c cpitrack.c cpigraph.c
keys we don't know
0x2000 cdapplay.c
*/
#define CONSOLE_MAX_X 1024
#undef HAVE_RESIZE_TERM
/* #define KICKSTART_DEBUG */
/* #define ADBMETA_DEBUG */
/* #define CDFS_DEBUG */
/* #define PLAYTIMIDITY_DEBUG */
/* #define ZIP_DEBUG */
/* #define ZIP_VERBOSE */
/* #define DIRDB_DEBUG */
/* #define BZIP2_DEBUG */
/* #define BZIP2_VERBOSE */
/* #define GZIP_DEBUG */
/* #define GZIP_VERBOSE */
/* #define Z_DEBUG */
/* #define Z_VERBOSE */
/* #define TAR_DEBUG */
/* #define TAR_VERBOSE */
/* #define PAK_DEBUG */
/* #define PAK_VERBOSE */
/* #define RPG_DEBUG */
/* #define RPG_VERBOSE */
/* #define FILEHANDLE_CACHE_DEBUG */
/* #define FILEHANDLE_CACHE_DISABLE */
/* #define INITCLOSE_DEBUG 1*/
/* #define LD_DEBUG 1 */
/* #define OSS_DEBUG 1 */
/* #define ALSA_DEBUG 1 */
/* #define OSS_LOCK_DEBUG 1 */
/* #define STM_LOAD_DEBUG 1 */
/* #define S3M_LOAD_DEBUG 1 */
/* #define MIXER_DEBUG 1 */
/* #define KEYBOARD_DEBUG 1 */
/* #define KEYBOARDTEXT_DEBUG 1 */
/* #define VCSA_DEBUG 1*/
/* #define DEBUG_FRAMEBUFFER 1 */
/* #define MDB_DEBUG 1 */
/* #define PLAYMP2_DEBUG 1 */
/* #define PSETTING_DEBUG 1 */
/* #define PLAYWAVE_DEBUG 1 */
/* #define XM_LOAD_DEBUG 1 */
/* #define IT_LOAD_DEBUG 1 */
/* #define OKT_LOAD_DEBUG 1 */
/* #define MCP_DEBUG 1 */
/* #define COREAUDIO_DEBUG 1 */
/* #define SDL_DEBUG 1 */
/* #define SDL2_DEBUG 1 */
/* #define CPIFACE_DEBUG 1 */
/* #define PNG_DEBUG 1 */
/* #define JPEG_DEBUG 1 */
/* #define PLAYAY_DEBUG 1 */
/* #define AMS_DEBUG 1 */
/* #define ANCIENT_DEBUG 1 */
#define VERBOSE_FRAMEBUFFER 1
#define VCSA_VERBOSE 1
/* #define CDROM_VERBOSE 1 */
#define FIX_BACKSPACE 1 /* lot of linux distroes has a broken backspace key in consoles. See stuff-vsca.c */
/* Multibyte support, don't think so.. VGA hardware is hardwired to one byte, so fuck the stupid new standards, since they SUCK */
#define VCSA_FONT "ISO-8859-1"
/*#define VCSA_FONT "LATIN1"*/
#define OCP_FONT "CP437"
#define VCSA_PATH "/dev/vcsa"
/* Stuff below here will be updated by ./configure */
#undef TIMIDITY_DEFAULT_PATH
#undef TIMIDITYPKGDATADIR
#undef HAVE_OV_PCM_SEEK_LAP
#undef HAVE_OV_PCM_SEEK
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
#undef HAVE_GETOPT
#undef HAVE_GETPWUID
#undef HAVE_MEMMEM
#undef HAVE_QSORT
#undef HAVE_STRUPR
#undef HAVE_POPEN
#undef HAVE_STRDUP
#undef HAVE_GETCWD
#undef HAVE_STRSTR
#undef HAVE_STRERROR
#undef HAVE_SNPRINTF
#undef HAVE_VSNPRINTF
#undef HAVE_STRNCASECMP
#undef HAVE_SLEEP
#undef HAVE_USLEEP
#undef HAVE_MKSTEMP
#undef HAVE_STRLCPY
#undef HAVE_STRLCAT
#undef HAVE_GETTIMEOFDAY
#undef HAVE_EFENCE
#undef HAVE_DUMA
#undef HAVE_X11
#undef HAVE_SDL
#undef HAVE_SDL2
#undef HAVE_MAD
#undef HAVE_ERRNO_H
#undef HAVE_LIMITS_H
#undef HAVE_SYS_CDEFS_H
#undef HAVE_SYS_STAT_H
#undef HAVE_SYS_TIME_H
/* Define to 1 if you can safely include both <sys/time.h> and <time.h>. */
#undef TIME_WITH_SYS_TIME
#undef HAVE_SYS_PARAM_H
#undef HAVE_SYS_TYPES_H
#undef HAVE_DIRENT_H
#undef HAVE_FCNTL_H
#undef HAVE_GRP_H
#undef HAVE_NDIR_H
#undef HAVE_SYS_NDIR_H
#undef HAVE_SYS_DIR_H
#undef HAVE_STDINT_H
#undef HAVE_INTTYPES_H
#undef HAVE_BYTESWAP_H
#undef HAVE_GETOPT_H
#undef HAVE_UNISTD_H
#undef HAVE_MACHINE_ENDIAN_H
#undef HAVE_PWD_H
#undef HAVE_SYS_SOUNDCARD_H
#undef HAVE_STRING_H
#undef NO_STRING_H
#undef HAVE_AVAILABILITY_H
#undef HAVE_AVAILABILITYMACROS_H
#undef HAVE_AVAILABILITYVERSIONS_H
#undef HAVE_GETPWNAM
#undef HAVE_FRAMEBUFFER
/* Using GNU libiconv */
#undef USE_LIBICONV_GNU
/* Using a native implementation of iconv in a separate library */
#undef USE_LIBICONV_NATIVE
#undef DLLVERSION
#undef PACKAGE_VERSION
#define VERSION PACKAGE_VERSION
#undef OCP_MAJOR_VERSION
#undef OCP_MINOR_VERSION
#undef OCP_PATCH_VERSION
#undef HAVE_LZW
#undef HAVE_LZH
#ifdef HAVE_EFENCE
#include <stdlib.h>
#include <efence.h>
#endif
#ifdef HAVE_DUMA
#include <stdlib.h>
#include <string.h>
#include <duma.h>
#endif
#if defined(HAVE_DUMA)|defined(HAVE_EFENCE)
#define NO_DLCLOSE
#endif
#ifndef _WIN32
#define PREFIX "/usr/local"
#define LIBDIR "/usr/lib"
#define LIBDIROCP "/usr/lib/ocp"
#define DATADIR "/usr/share"
#define DATADIROCP "/usr/share/ocp"
#endif
#undef UNIFONT_RELATIVE
#undef UNIFONT_TTF
#undef UNIFONT_CSUR_TTF
#undef UNIFONT_UPPER_TTF
#undef UNIFONT_OTF
#undef UNIFONT_CSUR_OTF
#undef UNIFONT_UPPER_OTF
#define LIB_SUFFIX ".so"
#ifndef HAVE_MEMMEM
#include <string.h>
# ifdef __cplusplus
extern "C" {
# endif
/* We experienced that some combination of Haiku + nCurses ends up with header
* files that defines memmem (as non-static), but no memmem implementation in
* the provided libc (libgnu might provide it) so redirect memmem to ocp_memmem
*/
#undef memmem
#define memmem ocp_memmem
static inline void *memmem(const void *_haystack, size_t haystacklen,
const void *needle, size_t needlelen)
{
const char *haystack = (const char *)_haystack;
while (haystacklen>=needlelen)
{
if (!memcmp(haystack, needle, needlelen))
return (void *)haystack;
haystack++;
haystacklen--;
}
return NULL;
}
# ifdef __cplusplus
}
# endif
#endif
#undef HAVE_FNMATCH
#undef HAVE_PATHMATCHSPECA
#include <limits.h>
/* A lot of structures etc. uses PATH_MAX, NAME_MAX and friends, so we
* still #include <limits.h> here
*/
#undef GCC_411_RUNTIMECHECK
#undef SUPPORT_STATIC_PLUGINS
#undef STATIC_CORE
#undef HAVE_SYSCONF
#undef HAVE_STRUCT_DIRENT_D_TYPE
#endif