12 if($ARGV[0] eq "-v") {
20 my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,
21 $atime,$mtime,$ctime,$blksize,$blocks)
28 my $dir = "$ROOT/apps/lang";
30 my @files = grep { /\.lang$/ } readdir(DIR
);
35 $output =~ s/(.*)\.lang/$1.lng/;
36 print "lang $_\n" if($verbose);
37 system ("$ROOT/tools/binlang $dir/english.lang $dir/$_ $outputlang/$output >/dev/null 2>&1");
42 my ($zip, $image, $notplayer)=@_;
47 mkdir ".rockbox", 0777;
48 mkdir ".rockbox/langs", 0777;
49 mkdir ".rockbox/rocks", 0777;
50 `find . -name "*.rock" ! -empty | xargs --replace=foo cp foo .rockbox/rocks/`;
52 open VIEWERS
, "$ROOT/apps/plugins/viewers.config" or
53 die "can't open viewers.config";
57 open VIEWERS
, ">.rockbox/viewers.config" or
58 die "can't create .rockbox/viewers.config";
59 mkdir ".rockbox/viewers", 0777;
62 if(-e
".rockbox/rocks/$1") {
63 `mv .rockbox/rocks/$1 .rockbox/viewers`;
71 `cp $ROOT/apps/plugins/sokoban.levels .rockbox/`; # sokoban levels
72 `cp $ROOT/apps/plugins/snake2.levels .rockbox/`; # snake2 levels
74 mkdir ".rockbox/fonts", 0777;
76 opendir(DIR
, "$ROOT/fonts") || die "can't open dir fonts";
77 my @fonts = grep { /\.bdf$/ && -f
"$ROOT/fonts/$_" } readdir(DIR
);
81 open(HEADER
, "<$ROOT/firmware/export/font.h");
83 if(/^\#define MAX_FONT_SIZE[ \t]*(\d+)/) {
88 die "no decent max font size" if ($maxfont < 2000);
93 print "FONT: $f\n" if($verbose);
96 my $cmd ="$ROOT/tools/convbdf -s 32 -l 255 -f -o \".rockbox/fonts/$o\" \"$ROOT/fonts/$f\" >/dev/null 2>&1";
97 print "CMD: $cmd\n" if($verbose);
100 # no need to add fonts we cannot load anyway
101 my $fontsize = filesize
(".rockbox/fonts/$o");
102 if($fontsize > $maxfont) {
103 unlink(".rockbox/fonts/$o");
110 # image is blank when this is a simulator
111 if( filesize
("rockbox.ucl") > 1000 ) {
112 `cp rockbox.ucl .rockbox/`; # UCL for flashing
114 if( filesize
("rombox.ucl") > 1000) {
115 `cp rombox.ucl .rockbox/`; # UCL for flashing
119 mkdir ".rockbox/docs", 0777;
126 `cp $ROOT/docs/$_ .rockbox/docs/$_.txt`;
129 # now copy the file made for reading on the unit:
131 # `cp $webroot/docs/Help-JBR.txt .rockbox/docs/`;
134 # `cp $webroot/docs/Help-Stu.txt .rockbox/docs/`;
137 buildlangs
(".rockbox/langs");
139 `find .rockbox | zip $zip -@ >/dev/null`;
145 # remove the .rockbox afterwards
149 my ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) =
155 $date=sprintf("%04d%02d%02d", $year,$mon, $mday);
156 $shortdate=sprintf("%02d%02d%02d", $year%100,$mon, $mday);
158 # made once for all targets
160 my ($type, $target)=@_;
162 # build a full install zip file
163 buildzip
("rockbox.zip", $target,
164 ($type eq "player")?
0:1);
167 my $target = $ARGV[0];
171 if($target !~ /sim/i) {
173 if($target =~ /(recorder|ondio)/i) {
181 if($target =~ /player/i) {
182 runone
("player", $exe);
185 runone
("recorder", $exe);