-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathshowVersion.h
More file actions
38 lines (29 loc) · 737 Bytes
/
showVersion.h
File metadata and controls
38 lines (29 loc) · 737 Bytes
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
/* showVersion.h: _REVISION_ */
#ifndef _SHOWVERSION_H_
#define _SHOWVERSION_H_
#ifdef __cplusplus
extern "C" {
#endif
#ifdef CPM /* don't add overhead to CP/M builds */
#define CHK_SHOW_VERSION(argc, argv)
#else
#include <stdbool.h>
#include <stdio.h>
typedef char const verstr[];
#ifdef _MSC_VER
#ifndef strcasecmp
#define strcasecmp _stricmp
#endif
#endif
void showVersion(bool full);
#define CHK_SHOW_VERSION(argc, argv) \
if (argc == 2 && strcasecmp(argv[1], "-v") == 0) \
do { \
showVersion(argv[1][1] == 'V'); \
exit(0); \
} while (0)
#endif
#ifdef __cplusplus
}
#endif
#endif