2012-08-08 30 views
2

我使用Perl 5.14.2與Unicode::Collate::Locale在Cygwin的Unicode ::分頁::區域設置的Perl模塊的方法排序一些法國文本錯誤調用時,「新」在Cygwin

use Unicode::Collate::Locale; 
my $coll = Unicode::Collate::Locale->new(locale => "fr"); 
@french_text = $coll->sort(@french_text); 

,我的錯誤得到的是:

Unicode/Collate/Locale/fr.pl can't be found at ./program.pl line 16 

正在從以下文件生成此錯誤消息:

/usr/lib/perl5/5.14/i686-cygwin-threads-64int/Unicode/Collate/Locale.pm 

的下列文件存在:

/usr/lib/perl5/5.14/Unicode/Collate/Locale/fr.pl 

但經調查,我發現Locale.pm正在尋找:

/usr/lib/perl5/5.14/i686-cygwin-threads-64int/Unicode/Collate/Locale/fr.pl 

此文件不存在,因此我收到錯誤消息。其他人是否看到這個問題?這是一個錯誤?

回答

0

您應該檢查是否Unicode::Collate::Locale安裝法正確

使用命令instmodsh檢查安裝的模塊。

MPBAB:work macpro$ instmodsh 
Available commands are: 
    l   - List all installed modules 
    m <module> - Select a module 
    q   - Quit the program 
cmd? m Unicode::Collate::Locale 
Available commands are: 
    f [all|prog|doc] - List installed files of a given type 
    d [all|prog|doc] - List the directories used by a module 
    v     - Validate the .packlist - check for missing files 
    t <tarfile>  - Create a tar archive of the module 
    h     - Display module help 
    q     - Quit the module 
WWW::Mechanize cmd? f 
+0

U :: C :: Locale是v5.14的一部分。其實,我之前已經看到過這個問題,不止一次,但還沒有找到它。這不僅僅是一個Cygwin問題,因爲那不是我見過的。我似乎記得它是通過執行CPAN安裝/更新/刷新修復的。 – tchrist 2012-08-09 04:49:02

+0

我按照建議重新安裝了模塊,問題已解決。謝謝您的幫助。 – 2012-08-09 23:54:07