Mercurial > mxe-octave
annotate src/physfs-test.c @ 7207:9ed6500e56d3 default tip @
maint: Merge release to default.
author | Markus Mützel <markus.muetzel@gmx.de> |
---|---|
date | Fri, 17 May 2024 20:16:41 +0200 |
parents | 99516e73b368 |
children |
rev | line source |
---|---|
2351
8a6c466753e2
Improve comment style of all test programs
Volker Grabsch <vog@notjusthosting.com>
parents:
2333
diff
changeset
|
1 /* |
8a6c466753e2
Improve comment style of all test programs
Volker Grabsch <vog@notjusthosting.com>
parents:
2333
diff
changeset
|
2 * This file is part of MXE. |
2353
99516e73b368
Move doc/index.html -> index.html
Volker Grabsch <vog@notjusthosting.com>
parents:
2351
diff
changeset
|
3 * See index.html for further information. |
2351
8a6c466753e2
Improve comment style of all test programs
Volker Grabsch <vog@notjusthosting.com>
parents:
2333
diff
changeset
|
4 * |
8a6c466753e2
Improve comment style of all test programs
Volker Grabsch <vog@notjusthosting.com>
parents:
2333
diff
changeset
|
5 * This is a slightly modified version of: |
8a6c466753e2
Improve comment style of all test programs
Volker Grabsch <vog@notjusthosting.com>
parents:
2333
diff
changeset
|
6 * test/physfs_test.c |
8a6c466753e2
Improve comment style of all test programs
Volker Grabsch <vog@notjusthosting.com>
parents:
2333
diff
changeset
|
7 */ |
1615 | 8 |
9 #include "physfs.h" | |
10 #include <stdio.h> | |
11 #include <stdlib.h> | |
12 | |
13 int main(int argc, char *argv[]) | |
14 { | |
15 (void)argc; | |
16 (void)argv; | |
17 | |
18 PHYSFS_Version compiled; | |
19 PHYSFS_VERSION(&compiled); | |
20 | |
21 printf("Compiled against PhysicsFS version %d.%d.%d\n\n", | |
22 (int) compiled.major, (int) compiled.minor, (int) compiled.patch); | |
23 | |
24 const PHYSFS_ArchiveInfo **rc; | |
25 const PHYSFS_ArchiveInfo **i; | |
26 | |
27 rc = PHYSFS_supportedArchiveTypes(); | |
28 printf("Supported archive types:\n"); | |
29 if (*rc == NULL) | |
30 printf(" * Apparently, NONE!\n"); | |
31 else | |
32 { | |
33 for (i = rc; *i != NULL; i++) | |
34 { | |
35 printf(" * %s: %s\n Written by %s.\n %s\n", | |
36 (*i)->extension, (*i)->description, | |
37 (*i)->author, (*i)->url); | |
38 } /* for */ | |
39 } /* else */ | |
40 | |
41 return 0; | |
42 } |