在Windows XP上安装Text :: Aspell

时间:2012-12-26 15:53:20

标签: perl spell-checking aspell

我安装了Aspell-0-50-3-3-Setup.exe和字典Aspell-en- 来自http://aspell.net/win32/的0.50-2-3.exe我已将此文件夹包含在我的 环境变量PATH:C:\ Program Files \ Aspell \ bin但我仍然不能 安装Text :: Aspell。我的perl版本是ActivePerl 5.16.1 构建1601.这些是我得到的错误消息:

    Checking if your kit is complete...
    Looks good
    Note (probably harmless): No library found for -laspell
    Aspell.xs:4:20: aspell.h: No such file or directory
    Aspell.xs:9: error: syntax error before "AspellCanHaveError"
    Aspell.xs:9: warning: no semicolon at end of struct or union
    Aspell.xs:10: warning: data definition has no type or storage class
    Aspell.xs:11: error: syntax error before '*' token
    Aspell.xs:11: warning: data definition has no type or storage class
    Aspell.xs:14: error: syntax error before '}' token
    Aspell.xs:14: warning: data definition has no type or storage class
    Aspell.xs:17: error: syntax error before '*' token
    Aspell.xs: In function `_create_speller':

    Writing Makefile for Text::Aspell
    Writing MYMETA.yml and MYMETA.json
    cp Aspell.pm blib\lib\Text\Aspell.pm
    C:\Perl\bin\perl.exe C:\Perl\lib\ExtUtils\xsubpp -noprototypes -typemap
    C:\Perl\lib\ExtUtils\typemap -typemap typemap  Aspell.xs > Aspell.xsc && 
    C:\Perl\bin\perl.exe -MExtUtils::Command -e mv -- Aspell.xsc Aspell.c 
    C:\Perl\site\bin\gcc.exe -c -DNDEBUG -DWIN32 -D_CONSOLE -DNO_STRICT 
    DPERL_TEXTMODE_SCRIPTS -DUSE_SITECUSTOMIZE -DPERL_IMPLICIT_CONTEXT -
    DPERL_IMPLICIT_SYS -DUSE_PERLIO -D_USE_32BIT_TIME_T -DHASATTRIBUTE -fno-strict-
    aliasing -mms-bitfields -O2                        -DVERSION=\"0.09\"    -
    DXS_VERSION=\"0.09\"  "-IC:\Perl\lib\CORE"   Aspell.c
    [32m  HANK/Text-Aspell-0.09.tar.gz[0m
    [31m  C:\Perl\site\bin\dmake.exe -- NOT OK[0m
    [32mRunning make test 
    [32m  Can't test without successful make
    [32mRunning make install Make had returned bad status, install seems impossible
    [32mFailed during this command:
    HANK/Text-Aspell-0.09.tar.gz 
    : make NO
    [32m[0m

1 个答案:

答案 0 :(得分:2)

您的问题是Note (probably harmless): No library found for -laspell

来自http://cpansearch.perl.org/src/HANK/Text-Aspell-0.09/README的解决方案 是告诉Makefile.PL在哪里找到libaspell

perl Makefile.PL CCFLAGS=-I$HOME/local/include     LIBS="-L$HOME/local/lib -laspell"

您可以在CCFLAGS中阅读LIBS / ExtUtils::MakeMaker,也可能阅读一些教程:)