use utf8;
use IO::Socket::INET;
use BerkeleyDB;
-use Chise_utils '$omegadb_path';
require 5.008001;
#my $kageaddr="home.fonts.jp:5100"; # Specify port number!
my $pfaedit="/usr/bin/env fontforge"; # point to 'fontforge' executable.
#die "Cannot execute $pfaedit. Abort.\n" unless -x $pfaedit;
+my $omegadb_path=""; # Check the path of omegadb, if needed.
+my $cleanup_script=""; # Check the path of pfaedit script, if needed.
+
+unless($omegadb_path){
+ if(-w '/usr/local/share/chise/omega'){
+ $omegadb_path='/usr/local/share/chise/omega';
+ }elsif(-w '/usr/share/chise/omega'){
+ $omegadb_path='/usr/share/chise/omega';
+ }elsif(-w '/sw/share/chise/omega'){
+ $omegadb_path='/sw/share/chise/omega';
+ }elsif(-w '/usr/local/lib/chise/omega'){
+ $omegadb_path='/usr/local/lib/chise/omega';
+ }else{
+ $omegadb_path=".";
+ }
+}
$omegadb_path=~s!/$!!;
-my $cleanup_script=""; # Check the path of pfaedit script, if needed.
+my $makefonts_dir;
+($makefonts_dir=$0)=~s!^(.*)/.*$!$1!;
unless($cleanup_script){
- if(-e "/usr/local/share/texmf/omega/ocp/chise_rqd/chise/svg2t1.pfe"){
+ if(-e "$makefonts_dir/svg2t1.pfe"){
+ $cleanup_script="$makefonts_dir/svg2t1.pfe";
+ }elsif(-e "/usr/local/share/texmf/omega/ocp/chise_rqd/chise/svg2t1.pfe"){
$cleanup_script="/usr/local/share/texmf/omega/ocp/chise_rqd/chise/svg2t1.pfe";
}elsif(-e "/usr/local/share/texmf/omega/ocp/local/chise/svg2t1.pfe"){
$cleanup_script="/usr/local/share/texmf/omega/ocp/local/chise/svg2t1.pfe";
- }elsif(-e "/usr/share/texmf/omega/ocp/local/chise/svg2t1.pfe"){
+ }elsif(-e "/usr/share/texmf/omega/ocp/chise_rqd/chise/svg2t1.pfe"){
$cleanup_script="/usr/share/texmf/omega/ocp/local/chise/svg2t1.pfe";
}elsif(-e "/sw/share/texmf/omega/ocp/local/chise/svg2t1.pfe"){
$cleanup_script="/sw/share/texmf/omega/ocp/local/chise/svg2t1.pfe";
}
}
+
unless($cleanup_script and -e $cleanup_script){
print STDERR "svg2t1.pfe not found!\n",
"please check \$cleanup_script in $0.\n";