我已按照说明成功安装(即没有错误或警告):
https://metacpan.org/pod/distribution/Lab-VISA/lib/Lab/VISA/Installation.pod
但是当我尝试运行示例脚本时,我得到了:
Can't load 'C:/Dwimperl/perl/site/lib/auto/Lab/VISA/VISA.dll' for module
Lab::VISA: load_file:The specified module could not be found at
C:/Dwimperl/perl/lib/DynaLoader.pm line 190.
at C:/Dwimperl/perl/site/lib/Lab/VISA.pm line 11
Compilation failed in require at VISA Test.pl line 3.
BEGIN failed--compilation aborted at VISA Test.pl line 3.
使用谷歌搜索表明VISA.dll出问题了。这是在模块安装过程中生成的,所以我想这是我环境中的问题。但是我有限的知识意味着我不确定从哪里开始。而且我似乎找不到Lab :: VISA模块的帮助联系人或论坛。
答案 0 :(得分:1)
在metacpan中被提及:
On 64-bit windows one needs a 32-bit version of perl with GNU binutils version <= 2.24. Otherwise linking with the NI-VISA library will fail. The reason for this are the following bugs in the GNU binutils:
binutils bug 16598
binutils bug 17910
These are fixed in the most recent version of the binutils. Once this version (2.26) is included in Strawberry Perl, it should be possible to use a 64-bit version of perl.
It is not possible to use either 32-bit or 64-bit versions of Strawberry Perl 5.22 as this version uses binutils 2.25.
因此,如果您具有WIN 64,则需要安装binutils
binutils错误16598:https://sourceware.org/bugzilla/show_bug.cgi?id=16598
和binutils错误17910:https://sourceware.org/bugzilla/show_bug.cgi?id=17910
注意:不要忘记总是阅读文档