File: makebinary.pl

package info (click to toggle)
therion 0.3.10-3
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 4,840 kB
  • ctags: 5,417
  • sloc: cpp: 46,983; tcl: 17,383; ansic: 9,055; perl: 1,680; makefile: 728; asm: 152; sh: 12
file content (38 lines) | stat: -rw-r--r-- 1,075 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
$platform = lc($ARGV[0]);

#($sec,$min,$hour,$mday,$mon,$year,$wday,$yday) = gmtime(time);
#$year += 1900;
#$mon += 1;
#$datestr = sprintf("%04d%02d%02d",$year,$mon,$mday);

if (open(VFL,"thversion.h")) {
  @verfl = <VFL>;
  $verfl[0] =~ /(\d+)\.(\d+)\.(\d+)/;
  ($v1,$v2,$v3) = ($1,$2,$3);
  close(VFL);
} else {
  $v1 = 0;
  $v2 = 2;
  $v3 = 1;
}

$dd = "therion-temp";
$d = "../$dd";
system("mkdir $d");
system("cp ./therion $d");
system("cp ./install $d");
system("cp ./therion.ini $d");
system("cp ./xtherion/xtherion $d");
system("cp ./xtherion/xtherion.ini $d");
system("cp ./thbook/thbook.pdf $d");
system("cp ./man/therion.1 $d");
system("cp ./man/xtherion.1 $d");
system("cp ./README $d");
system("cp ./COPYING $d");
if ($platform eq "win32") {
    system("zip -jr ../therion-$platform-$v1.$v2.$v3.zip $d");
} else {
    system("tar -cvf ../therion-linux.i386-$v1.$v2.$v3.tar -C $d install therion therion.ini xtherion xtherion.ini thbook.pdf therion.1 xtherion.1 README COPYING");
    system("gzip -f ../therion-linux.i386-$v1.$v2.$v3.tar");
}
system("rm -R $d");