-
Notifications
You must be signed in to change notification settings - Fork 383
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
VS2017: Add Perl script and InfoZIP utility to automate making Window…
…s binary releases.
- Loading branch information
1 parent
3e3bc43
commit 41c7683
Showing
2 changed files
with
38 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#!/usr/bin/perl | ||
my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(); | ||
my $datestr = sprintf("%04u%02u%02u-%02u%02u%02u",$year+1900,$mon+1,$mday,$hour,$min,$sec); | ||
my $zipname = "dosbox-x-windows-$datestr.zip"; | ||
|
||
my $ziptool = "vs2015/tool/zip.exe"; | ||
|
||
exit 0 if -f $zipname; | ||
|
||
die unless -f $ziptool; | ||
|
||
mkdir "release" unless -d "release"; | ||
mkdir "release/windows" unless -d "release/windows"; | ||
|
||
die "bin directory not exist" unless -d "bin"; | ||
|
||
print "$zipname\n"; | ||
|
||
my @filelist = (); | ||
|
||
my @platforms = ('Win32', 'x64'); | ||
my @builds = ('Release', 'Release SDL2'); | ||
my @files = ('dosbox.reference.conf', 'dosbox-x.exe', 'FREECG98.bmp'); | ||
|
||
foreach $platform (@platforms) { | ||
foreach $build (@builds) { | ||
foreach $file (@files) { | ||
$addfile = "bin/$platform/$build/$file"; | ||
die "Missing file $addfile" unless -e $addfile; | ||
|
||
push(@filelist, $addfile); | ||
} | ||
} | ||
} | ||
|
||
# do it | ||
$r = system($ziptool, '-9', "release/windows/$zipname", @filelist); | ||
exit 1 unless $r == 0; |
Binary file not shown.