--- cf.schmorp.de/server/utils/cfutil.in 2007/06/03 15:32:51 1.35 +++ cf.schmorp.de/server/utils/cfutil.in 2007/07/19 13:46:39 1.42 @@ -8,7 +8,7 @@ my $DATADIR = "@datadir@/@PACKAGE@"; my $CONVERT = "@CONVERT@"; -my $IDENTIFY = "@IDENTIFY@"; +#my $IDENTIFY = "@IDENTIFY@"; my $OPTIPNG = "@OPTIPNG@"; my $RSYNC = "@RSYNC@"; my $PNGNQ = "@PNGNQ@"; @@ -23,8 +23,11 @@ use Coro::AIO; use POSIX (); use Digest::MD5; +use Carp; use Coro::Storable; $Storable::canonical = 1; +$SIG{QUIT} = sub { Carp::cluck "QUIT" }; + sub usage { warn < $1, + copyright => $copyright, + data => $data, + chksum => Digest::MD5::md5 $data, + }; + } + } + sub find_files; sub find_files { my ($path) = @_; @@ -403,6 +435,8 @@ push @trs, [$path, $file]; } elsif ($file =~ /\.arc$/) { push @arc, [$path, $file]; + } elsif ($file =~ /\.(ogg|jpg|res)$/) { + push @res, [$path, $file]; } else { warn "ignoring $path/$file\n" if $VERBOSE >= 3; } @@ -413,6 +447,8 @@ sub inst_arch($) { my (undef, $path) = @_; + $PATH = $path; + print "\n", "Installing '$path' to '$DATADIR'\n", "\n", @@ -436,6 +472,7 @@ (async \&process_png), (async \&process_png), (async \&process_png), (async \&process_png), (async \&process_trs), (async \&process_trs), (async \&process_arc), (async \&process_arc), + (async \&process_res), (async \&process_res), ); { @@ -513,6 +550,7 @@ version => 2, faceinfo => \%FACEINFO, animinfo => \%ANIMINFO, + resource => \%RESOURCE, }; }