/[pcsx2_0.9.7]/branch/debug/0.X/0.9.X/0.9.7/r3113/fps2bios/romver.c
ViewVC logotype

Annotation of /branch/debug/0.X/0.9.X/0.9.7/r3113/fps2bios/romver.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 32 - (hide annotations) (download)
Tue Sep 7 03:29:01 2010 UTC (10 years, 8 months ago) by william
Original Path: branch/r3113_0.9.7_beta/fps2bios/romver.c
File MIME type: text/plain
File size: 709 byte(s)
branching from upstream revision (http://pcsx2.googlecode.com/svn/trunk
): r3113 to
https://svn.netsolutions.dnsalias.com/websvn/ps2/pcsx2/pcsx2_0.9.7/branch/r3113_0.9.7_beta
1 william 31 #include <stdio.h>
2     #include <string.h>
3     #include <stdlib.h>
4     #include <ctype.h>
5     #include <sys/types.h>
6     #include <sys/stat.h>
7     #include <time.h>
8    
9     int main(int argc, char *argv[]) {
10     char str[256];
11     FILE *f;
12     time_t t;
13     int version;
14     int build;
15    
16     printf("fps2bios romver generator\n");
17     if (argc < 3){
18     printf("usage: %s version build\n", argv[0]);
19     return 1;
20     }
21     f = fopen("ROMVER", "wb");
22     if (f == NULL) {
23     printf("failed to create ROMVER\n");
24     return 1;
25     }
26    
27     t = time(NULL);
28     strftime(str, 256, "%Y%m%d", localtime(&t));
29     version = strtol(argv[1], (char**)NULL, 0);
30     build = strtol(argv[2], (char**)NULL, 0);
31     fprintf(f, "%2.2d%2.2dPD%s\n", version, build, str);
32     fputc(0, f);
33    
34     fclose(f);
35    
36     return 0;
37     }

  ViewVC Help
Powered by ViewVC 1.1.22