From: imiyazaki Date: Thu, 23 Mar 2006 06:43:51 +0000 (+0000) Subject: update for CHISE DB 1.0. X-Git-Url: http://git.chise.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;ds=sidebyside;p=chise%2Fperl.git update for CHISE DB 1.0. --- diff --git a/Chise_utils/Chise_utils.pm b/Chise_utils/Chise_utils.pm index a044631..f69a885 100644 --- a/Chise_utils/Chise_utils.pm +++ b/Chise_utils/Chise_utils.pm @@ -44,7 +44,7 @@ our @EXPORT_OK = ( @{ $EXPORT_TAGS{'all'} } ); our @EXPORT = qw( ); -our $VERSION = '0.02'; +our $VERSION = '0.03'; # Preloaded methods go here. @@ -66,12 +66,12 @@ unless($omegadb_path){ my $DB_HOME=""; unless($DB_HOME){ - if(-e '/usr/local/share/chise/0.3/db'){ - $DB_HOME='/usr/local/share/chise/0.3/db'; - }elsif(-e '/usr/share/chise/0.3/db'){ - $DB_HOME='/usr/share/chise/0.3/db'; - }elsif(-e '/sw/share/chise/0.3/db'){ - $DB_HOME='/sw/share/chise/0.3/db'; + if(-e '/usr/local/share/chise/1.0/db'){ + $DB_HOME='/usr/local/share/chise/1.0/db'; + }elsif(-e '/usr/share/chise/1.0/db'){ + $DB_HOME='/usr/share/chise/1.0/db'; + }elsif(-e '/sw/share/chise/1.0/db'){ + $DB_HOME='/sw/share/chise/1.0/db'; }elsif(-e '/usr/local/lib/chise/chise-db'){ $DB_HOME='/usr/local/lib/chise/chise-db'; }elsif(-e '/usr/lib/chise/chise-db'){ @@ -132,10 +132,10 @@ if(-d "$DB_HOME/character"){ $atr=~s!$DB_HOME/character/feature/!!; $db{$atr}=$_; } - for (glob "$DB_HOME/character/by_feature/*"){ + for (glob "$DB_HOME/character/index/*"){ next if(/\.txt$/); $atr=$_; - $atr=~s!$DB_HOME/character/by_feature/!!; + $atr=~s!$DB_HOME/character/index/!!; $reverse_db{$atr}=$_; } }elsif(-d "$DB_HOME/system-char-id"){