$plugin_purpose{'convert-flac'} =
  "Convert FLAC files to WAVE files using the flac command-line tool";
$plugin_options{'convert-flac'} = [
  ['opts=string', 'Extra flac command line options']];

$convert_plugin_hook = sub {
    my ($src, $dest) = map({quotemeta($_)} @_);
    my $flacopts = $plugin{'convert-flac'}{opts};
    system("flac -dsf --endian=little --channels=$channels --bps=16".
	   " --sample-rate=44100 --sign=signed $flacopts -o $dest $src");
    warn "error while executing flac" if $? != 0;
};

1
# vim:ft=perl
