Improve file measure testcase
[platform/upstream/glib.git] / win32-fixup.pl
1 #!/usr/bin/perl
2
3 $major = 1;
4 $minor = 3;
5 $micro = 7;
6 $binary_age = 0;
7 $interface_age = 0;
8 $gettext_package = "glib20";
9 $current_minus_age = 0;
10
11 sub process_file
12 {
13         my $outfilename = shift;
14         my $infilename = $outfilename . ".in";
15         
16         open (INPUT, "< $infilename") || exit 1;
17         open (OUTPUT, "> $outfilename") || exit 1;
18         
19         while (<INPUT>) {
20             s/\@GLIB_MAJOR_VERSION\@/$major/g;
21             s/\@GLIB_MINOR_VERSION\@/$minor/g;
22             s/\@GLIB_MICRO_VERSION\@/$micro/g;
23             s/\@GLIB_INTERFACE_AGE\@/$interface_age/g;
24             s/\@GLIB_BINARY_AGE\@/$binary_age/g;
25             s/\@GETTEXT_PACKAGE\@/$gettext_package/g;
26             s/\@LT_CURRENT_MINUS_AGE@/$current_minus_age/g;
27             print OUTPUT;
28         }
29 }
30
31 process_file ("config.h.win32");
32 process_file ("glibconfig.h.win32");
33 process_file ("glib/makefile.msc");
34 process_file ("glib/glib.rc");
35 process_file ("gmodule/makefile.msc");
36 process_file ("gmodule/gmodule.rc");
37 process_file ("gobject/makefile.msc");
38 process_file ("gobject/gobject.rc");
39 process_file ("gthread/makefile.msc");
40 process_file ("gthread/gthread.rc");
41 process_file ("tests/makefile.msc");