或者,如果您的操作系统支持,则可以将libtermkey作为真正的软件包安装-我将软件包保留在 http://packages.leonerd.org.uk/用于Debian测试/不稳定;它也可能适用于其他Debian衍生的发行版,例如Ubuntu.I have a problem while installing Term::TermKey with CPAN and I can't find information about how to solve it. Here is an output:cpan[9]> install Term::TermKeyRunning install for module 'Term::TermKey'Running Build for P/PE/PEVANS/Term-TermKey-0.10.tar.gz Checksum was ok '/usr/bin/perl Build.PL installdirs=site' returned status 256, won't makeRunning Build test Make had some problems, won't testRunning Build install Make had some problems, won't installMay someone help me?//editI installed libtermkey but I still have a problem:Building Term-TermKeycc -I/usr/lib/perl5/core_perl/CORE -DXS_VERSION="0.10" -DVERSION="0.10" -fPIC -I/usr/local/include -c -D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe -fstack-protector -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -march=x86-64 -mtune=generic -O2 -pipe -fstack-protector --param=ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -o lib/Term/TermKey.o lib/Term/TermKey.cExtUtils::Mkbootstrap::Mkbootstrap('blib/arch/auto/Term/TermKey/TermKey.bs')cc -shared -Wl,-O1,--sort-common,--as-needed,-z,relro,--hash-style=gnu -L/usr/local/lib -fstack-protector -o blib/arch/auto/Term/TermKey/TermKey.so lib/Term/TermKey.o -L/usr/local/lib -ltermkey PEVANS/Term-TermKey-0.10.tar.gz ./Build -- OK'YAML' not installed, will not store persistent stateRunning Build testt/00use.t ........... 1/1 # Failed test 'use Term::TermKey;'# at t/00use.t line 8.# Tried to use 'Term::TermKey'.# Error: Can't load '/root/.cpan/build/Term-TermKey-0.10-Y5j3Oz/blib/arch/auto/Term/TermKey/TermKey.so' for module Term::TermKey: libtermkey.so.1: nie można otworzyć pliku obiektu dzielonego: Nie ma takiego pliku ani katalogu at /usr/lib/perl5/core_perl/DynaLoader.pm line 190.It fails on every test. I don't know why. There is -L/usr/local/lib -ltermkey, so I've checked this directory:ciembor@peace lib]$ ls | grep libtermkeylibtermkey.alibtermkey.lalibtermkey.solibtermkey.so.1libtermkey.so.1.4.0And all files are on their place... 解决方案 Make sure that /usr/local/lib is also present in either $LD_LIBRARY_PATH or /etc/ld.so.conf. Without that, even if pkg-config can find the termkey.pc file which tells the compiler where the <termkey.h> files are, the (runtime) linker will not be able to link against the actual libtermkey.so file at runtime.Alternatively, you could install libtermkey as a real package if your OS supports such - I keep a package on http://packages.leonerd.org.uk/ for Debian testing/unstable; it may also be suitable for other Debian-derived distributions such as Ubuntu. 这篇关于安装Term :: TermKey返回错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 10-30 00:06