无法运行从 wxGlade 生成的 Perl 代码 [英] Unable to run Perl code generated from wxGlade

查看:29
本文介绍了无法运行从 wxGlade 生成的 Perl 代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试运行使用 wxGlade 生成的 Perl 代码,但我收到此错误

I am trying to run Perl code generated using wxGlade but I am receiving this error

.

正文

无法为模块 Wx 加载 'C:/Perl/site/lib/auto/Wx/Wx.dll': load_file:在 C:/Perl/lib/Dynaloader.pm 行找不到指定的模块191.

Can't load 'C:/Perl/site/lib/auto/Wx/Wx.dll' for module Wx: load_file:The specified module could not be found at C:/Perl/lib/Dynaloader.pm line 191.

最终,我想使用从 wxGlade 生成的代码重新排列小部件.我没有 *.wxg 文件,我只有 Perl 代码.

Ultimately, I want to rearrange widgets using the code generated from wxGlade. I don't have the *.wxg file, I only have the Perl code.

如果这不可能,我想在 Perl 代码运行时看到小部件,然后我将在 wxGlade 中重新创建小部件.

If this is not possible, I want to see the widgets when the Perl code runs then I will re-create the widgets in wxGlade.

我在 Windows 10 上使用 ActivePerl 5.16.3 Build 1604.我已经安装了 wxPerl 版本 0.9921.

I'm using ActivePerl 5.16.3 Build 1604 on Windows 10. I have installed wxPerl Version 0.9921.

这是where perl

C:\Windows\system32>where perl
C:\Perl\bin\perl.exe
C:\strawberry\perl\bin\perl.exe

下面是 cpan Wx 命令的结果.

Below is the result of the cpan Wx command.

C:\Windows\system32>cpan Wx
Set up gcc environment - 4.4.3
CPAN: Term::ANSIColor loaded ok (v4.02)
CPAN: Storable loaded ok (v2.45)
Reading 'C:\Perl\cpan\Metadata'
  Database was generated on Mon, 04 Dec 2017 06:54:07 GMT
Running install for module 'Wx'
Running make for M/MD/MDOOTSON/Wx-0.9932.tar.gz
CPAN: Digest::SHA loaded ok (v5.85)
CPAN: Compress::Zlib loaded ok (v2.063)
Checksum for C:\Perl\cpan\sources\authors\id\M\MD\MDOOTSON\Wx-0.9932.tar.gz ok
CPAN: Archive::Tar loaded ok (v1.96)
Wx-0.9932/
Wx-0.9932/build/
Wx-0.9932/build/Wx/
Wx-0.9932/build/Wx/build/
Wx-0.9932/build/Wx/build/MakeMaker/
Wx-0.9932/build/Wx/build/MakeMaker/Any_OS.pm
Wx-0.9932/build/Wx/build/MakeMaker/Any_wx_config.pm
Wx-0.9932/build/Wx/build/MakeMaker/Core.pm
Wx-0.9932/build/Wx/build/MakeMaker/Hacks.pm
Wx-0.9932/build/Wx/build/MakeMaker/MacOSX_GCC.pm

Wx-0.9932/XS/SVGFileDC.xsp
Wx-0.9932/XS/TaskBarIcon.xs
Wx-0.9932/XS/TextAttr.xsp
Wx-0.9932/XS/TextCtrl.xsp
Wx-0.9932/XS/TextCtrlIface.xsp
Wx-0.9932/XS/TextEntryDialog.xs
Wx-0.9932/XS/Timer.xs
Wx-0.9932/XS/ToggleButton.xs
Wx-0.9932/XS/ToolBar.xs
Wx-0.9932/XS/Toolbook.xsp
Wx-0.9932/XS/ToolTip.xs
Wx-0.9932/XS/TopLevelWindow.xsp
Wx-0.9932/XS/Treebook.xsp
Wx-0.9932/XS/TreeCtrl.xs
Wx-0.9932/XS/Utils.xs
Wx-0.9932/XS/Validators.xs
Wx-0.9932/XS/VarHScrollHelper.xsp
Wx-0.9932/XS/VarHVScrollHelper.xsp
Wx-0.9932/XS/Variant.xsp
Wx-0.9932/XS/VarScrollHelperBase.xsp
Wx-0.9932/XS/VarVScrollHelper.xsp
Wx-0.9932/XS/VListBox.xsp
Wx-0.9932/XS/VScrolledWindow.xsp
Wx-0.9932/XS/Wave.xs
Wx-0.9932/XS/Window.xsp
Wx-0.9932/XS/Wizard.xs
CPAN: File::Temp loaded ok (v0.2304)
CPAN: Parse::CPAN::Meta loaded ok (v1.4409)
CPAN: CPAN::Meta loaded ok (v2.132830)
---- Unsatisfied dependencies detected during ----
----         MDOOTSON/Wx-0.9932.tar.gz        ----
    Alien::wxWidgets [build_requires]
Running make test
  Make had some problems, won't test
  Delayed until after prerequisites
Running make install
  Make had some problems, won't install
  Delayed until after prerequisites
Running install for module 'Alien::wxWidgets'
Running make for M/MD/MDOOTSON/Alien-wxWidgets-0.69.tar.gz
Checksum for C:\Perl\cpan\sources\authors\id\M\MD\MDOOTSON\Alien-wxWidgets-0.69.tar.gz ok
Alien-wxWidgets-0.69
Alien-wxWidgets-0.69/Build.PL
Alien-wxWidgets-0.69/Changes
Alien-wxWidgets-0.69/MANIFEST
Alien-wxWidgets-0.69/META.json

Alien-wxWidgets-0.69/patches/wxMac-2.8.10-fontdlg.patch
Alien-wxWidgets-0.69/patches/wxMac-2.8.3-brokengcc.patch
Alien-wxWidgets-0.69/patches/wxMac-2.9.0-textctrl.patch
Alien-wxWidgets-0.69/patches/wxWidgets-2.8.0-magic.patch
Alien-wxWidgets-0.69/patches/wxWidgets-2.8.10-gsocket.patch
Alien-wxWidgets-0.69/patches/wxWidgets-2.9.0-magic.patch
Alien-wxWidgets-0.69/patches/wxWidgets-2.9.0-msgdlg.patch
Alien-wxWidgets-0.69/patches/wxWidgets-2.9.4-plugin.patch
Alien-wxWidgets-0.69/patches/wxWidgets-3.0.2-webkit.patch
Alien-wxWidgets-0.69/script
Alien-wxWidgets-0.69/script/make_ppm.pl
Alien-wxWidgets-0.69/t
Alien-wxWidgets-0.69/t/01_load.t
Alien-wxWidgets-0.69/t/zy_pod_coverage.t
Alien-wxWidgets-0.69/t/zz_pod.t
CPAN: Module::CoreList loaded ok (v3.03)
CPAN: Module::Build loaded ok (v0.4203)

  CPAN.pm: Building M/MD/MDOOTSON/Alien-wxWidgets-0.69.tar.gz
    gmake: *** [gcc_mswudll\coredll_gdiplus.o] Error 1
    system: gmake -f makefile.gcc all  UNICODE=1 MSLU=0 BUILD=release SHARED=1  DEBUG_INFO=default DEBUG_FLAG=1 LDFLAGS=" -m32" CPPFLAGS="-m32 -D_USE_32BIT_TIME_T": 512 at inc/My/Build/Win32.pm line 284.
    dmake.exe:  Error code 130, while making 'all'
      MDOOTSON/Alien-wxWidgets-0.69.tar.gz
      C:\STRAWB~1\c\bin\dmake.exe -- NOT OK
    CPAN: YAML::XS loaded ok (v0.41)
    Running make test
      Can't test without successful make
    Running make install
      Make had returned bad status, install seems impossible
    Running make for M/MD/MDOOTSON/Wx-0.9932.tar.gz
    Warning: Prerequisite 'Alien::wxWidgets => 0.25' for 'MDOOTSON/Wx-0.9932.tar.gz' failed when processing 'MDOOTSON/Alien-wxWidgets-0.69.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
    CPAN: Time::HiRes loaded ok (v1.9726)

      CPAN.pm: Building M/MD/MDOOTSON/Wx-0.9932.tar.gz

    Set up gcc environment - 4.4.3
    Checking if your kit is complete...
    Looks good
    Warning: prerequisite Alien::wxWidgets 0.25 not found.
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Socket
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DND
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::FS
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Grid
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Help
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Html
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::MDI
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Print
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::XRC
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::STC
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DocView
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Calendar
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DateTime
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Media
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::RichText
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::AUI
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DataView
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::PropertyGrid
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Ribbon
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::WebView
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::PerlTest
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::IPC
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl::SplashFast
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl::Carp
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl::TextValidator
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx
    Writing MYMETA.yml and MYMETA.json

    ======================================================================
    wxWidgets minimum supported version 2.007001 is missing.
    You will need to re-run Makefile.PL after it is installed.
    You must install wxWidgets using Alien::wxWidgets.
    ======================================================================

    ======================================================================
    For installation instructions and further help please see
    docs/INSTALL.pod

    For command line switches help use:
    perl Makefile.PL --help
    ======================================================================

    Warning: Prerequisite 'Alien::wxWidgets => 0.25' for 'MDOOTSON/Wx-0.9932.tar.gz' failed when processing 'MDOOTSON/Alien-wxWidgets-0.69.tar.gz' with 'make => NO'. Continuing, but chances to succeed are limited.
    Makefile out-of-date with respect to alien_wxwidgets_missing
    Cleaning current config before rebuilding Makefile...
    C:\STRAWB~1\c\bin\dmake.exe -f Makefile.old clean > NUL
    C:\Perl\bin\perl.exe Makefile.PL "INSTALLDIRS=site"
    Set up gcc environment - 4.4.3
    Checking if your kit is complete...
    Looks good
    Warning: prerequisite Alien::wxWidgets 0.25 not found.
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Socket
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DND
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::FS
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Grid
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Help
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Html
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::MDI
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Print
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::XRC
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::STC
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DocView
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Calendar
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DateTime
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Media
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::RichText
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::AUI
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::DataView
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::PropertyGrid
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Ribbon
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::WebView
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::PerlTest
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::IPC
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl::SplashFast
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl::Carp
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl::TextValidator
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx::Perl
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx
    Writing MYMETA.yml and MYMETA.json
    Generating a dmake-style Makefile
    Writing Makefile for Wx
    Writing MYMETA.yml and MYMETA.json

    ======================================================================
    wxWidgets minimum supported version 2.007001 is missing.
    You will need to re-run Makefile.PL after it is installed.
    You must install wxWidgets using Alien::wxWidgets.
    ======================================================================

    ======================================================================
    For installation instructions and further help please see
    docs/INSTALL.pod

    For command line switches help use:
    perl Makefile.PL --help
    ======================================================================

    ==> Your Makefile has been rebuilt. <==
    ==> Please rerun the C:\STRAWB~1\c\bin\dmake.exe command.  <==
    C:\Perl\bin\perl.exe  -e "exit 1" --
    dmake.exe:  Error code 129, while making 'Makefile'
      MDOOTSON/Wx-0.9932.tar.gz
      C:\STRAWB~1\c\bin\dmake.exe -- NOT OK
    Running make test
      Can't test without successful make
    Running make install
      Make had returned bad status, install seems impossible

我删除了 ActivePerl 并使用了 Strawberry Perl.我发出了 cpan Wx 然后我得到了下面的错误.

I removed ActivePerl and used Strawberry Perl. I issued cpan Wx then I got the error below.

在 .@INC 中找不到 Wx/Mini.pm(.@INC 包含:
C:\Program Files\ActiveState Komodo IDE 9\lib\support\dbgp\perllib
C:/strawberry/perl/site/lib/MSWin32-x86-multi-thread
C:/strawberry/perl/site/lib
C:/strawberry/perl/vendor/lib
C:/strawberry/perl/lib .)
在 C:/strawberry/perl/lib/Wx.pm 第 100 行.
BEGIN 失败——编译在 C:/strawberry/perl/lib/Wx.pm 第 100 行中止.

Can't locate Wx/Mini.pm in .@INC (.@INC contains:
C:\Program Files\ActiveState Komodo IDE 9\lib\support\dbgp\perllib
C:/strawberry/perl/site/lib/MSWin32-x86-multi-thread
C:/strawberry/perl/site/lib
C:/strawberry/perl/vendor/lib
C:/strawberry/perl/lib .)
at C:/strawberry/perl/lib/Wx.pm line 100.
BEGIN failed--compilation aborted at C:/strawberry/perl/lib/Wx.pm line 100.

mini.pm 可以在 C:\strawberry\cpan\build\Wx-0.9932-zlzpbD\lib\Wx 找到

mini.pm can be found in C:\strawberry\cpan\build\Wx-0.9932-zlzpbD\lib\Wx

推荐答案

您的日志显示

Make had returned bad status, install seems impossible

所以安装失败并且您没有Wx.您还将看到构建尝试同时使用 dmake (Strawberry Perl) 和 gmake (Active Perl),并且它引用了 both perl实例在这里

so the installation failed and you have no Wx. You will also see that the build is trying to use both dmake (Strawberry Perl) and gmake (Active Perl), and it references both perl instances here

C:\STRAWB~1\c\bin\dmake.exe -f Makefile.old clean > NUL
C:\Perl\bin\perl.exe Makefile.PL "INSTALLDIRS=site"

所以它变得非常混乱

您需要删除一个或另一个以确保安全,因为与 Linux 不同,Windows 的行为受文件关联和 PATH 环境变量的影响.

You need to remove one or the other to be safe, as Windows' behaviour is affected both by file associations and the PATH environment variable, unlike Linux.

你可以看看 berrybrew 但我不知道它是否适用于 ActivePerl.

You could take a look at berrybrew but I don't know whether it will work with ActivePerl.

我通常更喜欢用于 Windows 的 Strawberry Perl,因为它与专有系统的联系较少.

I generally prefer Strawberry Perl for Windows as it is less tied to proprietary systems.

这篇关于无法运行从 wxGlade 生成的 Perl 代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆