/[pcsx2_0.9.7]/trunk/3rdparty/SDL-1.3.0-5387/test/testver.c
ViewVC logotype

Contents of /trunk/3rdparty/SDL-1.3.0-5387/test/testver.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 401 - (show annotations) (download)
Fri Feb 25 17:31:09 2011 UTC (9 years, 9 months ago) by william
File MIME type: text/plain
File size: 818 byte(s)
Auto Commited Import of: pcsx2-0.9.7-DEBUG (upstream: v0.9.7.4358 local: v0.9.7.313-latest) in ./trunk
1
2 /* Test program to compare the compile-time version of SDL with the linked
3 version of SDL
4 */
5
6 #include <stdio.h>
7 #include <stdlib.h>
8
9 #include "SDL.h"
10 #include "SDL_revision.h"
11
12 int
13 main(int argc, char *argv[])
14 {
15 SDL_version compiled;
16 SDL_version linked;
17
18 #if SDL_VERSION_ATLEAST(1, 3, 0)
19 printf("Compiled with SDL 1.3 or newer\n");
20 #else
21 printf("Compiled with SDL older than 1.3\n");
22 #endif
23 SDL_VERSION(&compiled);
24 printf("Compiled version: %d.%d.%d.%d (%s)\n",
25 compiled.major, compiled.minor, compiled.patch,
26 SDL_REVISION_NUMBER, SDL_REVISION);
27 SDL_GetVersion(&linked);
28 printf("Linked version: %d.%d.%d.%d (%s)\n",
29 linked.major, linked.minor, linked.patch,
30 SDL_GetRevisionNumber(), SDL_GetRevision());
31 SDL_Quit();
32 return (0);
33 }

  ViewVC Help
Powered by ViewVC 1.1.22