in reply to Win32::GUI Installation Errors

dmake: Error code 129, while making '..\blib\arch\auto\Win32\GUI\Constants\Constants.dll'

Any message(s) before that which look like they might be hinting at the problem?

"Error code 129" alone doesn't say much, as it's just the return code from some previous failed command which dmake attempted to run...

Replies are listed 'Best First'.
Re^2: Win32::GUI Installation Errors
by Anonymous Monk on Dec 19, 2010 at 22:34 UTC
    The only lines before that that seem like errors are these:

    dll.exp: file not recognized: File format not recognized
    collect2: ld returned 1 exit status They are the two lines before the two error codes. All other commands seem to be positive, but I'll attach those below.

    Skip blib\lib\Win32/GUI/GridLayout.pm (unchanged)
    Skip blib\lib\Win32/GUI.pm (unchanged)
    Skip ..\blib\lib\Win32\GUI\BitmapInline.pm (unchanged)
    Skip ..\blib\lib\Win32\GUI/Constants/Tags.pm (unchanged)
    Skip ..\blib\lib\Win32\GUI/Constants.pm (unchanged)
    C:\strawberry\perl\bin\perl.exe "-I..\blib\arch"
    "-I..\blib\lib" Constants.PL constants.h
    C:\strawberry\perl\bin\perl.exe "-I..\blib\arch"
    "-I..\blib\lib" Constants.PL constants.src
    hash\perfect.exe < constants.src
    Read in 2031 keys
    found distinct (A,B) on attempt 143
    built perfect hash table of size 512
    Wrote phash.def
    Cleaned up
    C:\strawberry\perl\bin\perl.exe "-I..\blib\arch"
    "-I..\blib\lib" Constants.PL phash.inc
    C:\strawberry\perl\bin\perl.exe C:\strawberry\perl\lib\ExtUtils\xsubpp -typemap
    C:\strawberry\perl\lib\ExtUtils\typemap Constants.xs >
    Constants.xsc && C:\strawberry\perl\bin\perl.exe
    -MExtUtils::Command -e "mv" -- Constants.xsc Constants.c gcc -c -s -O2 -DWIN32 -DHAVE_DES_FCRYPT -DUSE_SITECUSTOMIZE -DPERL_IMPL ICIT_CONTEXT -DPERL_IMPLICIT_SYS -fno-strict-aliasing -DPERL_MSVCRT_READFIX -s -O2 -DVERSION=\"0.04\" -DXS_VERSION=\"0.04\" "-IC:\strawberry\perl\lib \CORE" Constants.c
    C:\strawberry\perl\bin\perl.exe "-I..\blib\arch" "-I..\blib\lib" ConstantsRC.PL Constants.rc
    windres -O coff -o Constants.res Constants.rc Running Mkbootstrap for Win32::GUI::Constants () C:\strawberry\perl\bin\perl.exe -MExtUtils::Command -e "chmod" -- 644 Constants.bs
    dlltool --def Constants.def --output-exp dll.exp g++ -o ..\blib\arch\auto\Win32\GUI\Constants\Constants.dll -Wl,--base-file -Wl,dll.base -mdll -s -L
    "C:\strawberry\perl\lib\CORE" -L"C:\strawberry\c\lib"
    Constants.o Constants.res -Wl,--image-base,0x370e0000
    C:\strawberry\perl\lib\CORE\libperl510.a
    -lmoldname -lkernel32 -luser32 -lgdi32 -lwinspool -lcomdlg32 -ladvapi32 -lshell32 -lole32 -loleaut32 -lnetapi32 -luuid -lws2_32 -lmpr -lwinmm -lversion -lodbc32 -lodbccp32 dll.exp
    dll.exp: file not recognized: File format not recognized
    collect2: ld returned 1 exit status
    dmake: Error code 129, while making '..\blib\arch\auto\Win32\GUI\Constants\Constants.dll'
    dmake: Error code 255, while making 'subdirs'


    I'm sorry for the mess, but copying messages from the command prompt is never pretty. I highlighted what I believe are the errors. It seems to be something to do with the .dll file.

    Thanks for taking the time.
      dll.exp: file not recognized: File format not recognized

      That's not right - first thing I'd try is re-installing Strawberry Perl.
      Win32-GUI-1.06 builds fine for me on both 5.10 and 5.12 editions of Strawberry Perl.

      Note that, if building Win32-GUI with Strawberry Perl, you miss out on Win32::GUI::AxWindow, Win32::GUI::Bitmap and Win32::GUI::Grid. (You'll see warnings about this during the 'perl Makefile.PL' stage.)
      If you want those features, then you should instead install Win32::GUI from the ActiveState ppm repository.

      Cheers,
      Rob
        Hi Rob,

        Thanks for looking at this for me.

        I tried re-installing Perl, I even tried the ActivePerl version and using "ppm" to install. Neither worked :(

        Like I said in a reply above just now, it might have to do with me not having a C compiler. I'm currently installing MinGW as an attempt to fix this.

        - Cbeppe

      dll.exp should be the list of symbols to export (binary format) that's being created right above with the command dlltool --def Constants.def --output-exp dll.exp.

      Other than that, I'm afraid I can't offer much wisdom :)  What does dll.exp contain? Maybe the file is empty because the dlltool command failed for some reason? Interestingly, my version of dlltool doesn't have an option --def, only --input-def or -d ...

      Update: a little googling suggests that --def is still understood for compatibility, so this shouldn't be an issue.

        No, the file is not empty, however I don't have a program that shows me the real contents. It's at about 730bytes though.

        Now, when you mention MinGW, I think my problem might lie there since I never installed anything like that. I'll download it and set it up and try again. Maybe that's why the file type is "unknown"?

        We'll see. Thanks for your help.

        - Cbeppe
Re^2: Win32::GUI Installation Errors
by Anonymous Monk on Dec 19, 2010 at 23:45 UTC
    Alright... I just installed MinGW to no avail :(

    Still getting the same errors...

    Dmake test produces the following:
    dlltool --def Constants.def --output-exp dll.exp g++ -o ..\blib\arch\auto\Win32\GUI\Constants\Constants.dll -Wl,--base- +file -Wl,dll.base -mdll -s -L"C:\strawberry\perl\lib\CORE" -L"C:\stra +wberry\c\li b" Constants.o Constants.res -Wl,--image-base,0x370e0000 C:\strawberr +y\perl\lib\CORE\libperl510.a -lmoldname -lkernel32 -luser32 -lgdi32 - +lwinspool - lcomdlg32 -ladvapi32 -lshell32 -lole32 -loleaut32 -lnetapi32 -luuid -l +ws2_32 -lmpr -lwinmm -lversion -lodbc32 -lodbccp32 dll.exp dll.exp: file not recognized: File format not recognized collect2: ld returned 1 exit status dmake: Error code 129, while making '..\blib\arch\auto\Win32\GUI\Cons +tants\Constants.dll' dmake: Error code 255, while making 'subdirs'


    Any more ideas? I'm honestly running out of stuff to try at the moment. Could always try to reinstall again, but...

    Thanks to everyone who's looking at this :)
      Alright... I just installed MinGW to no avail

      But you already had MinGW - it's in the Strawberry/c/ folder.
      Can you post the output of gcc -v ? With StrawberryPerl-5.10, mine looks like this:
      C:\>gcc -v Reading specs from C:/strawberry/c/bin/../lib/gcc/mingw32/3.4.5/specs Configured with: ../gcc-3.4.5-20060117-3/configure --with-gcc --with-g +nu-ld --with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw - +-enable-threads --disable-nls --enable-languages=c,c++,f77,ada,objc,j +ava --disable-win32-registry --disable-shared --enable-sjlj-exception +s --enable-libgcj --disable-java-awt --without-x --enable-java-gc=boe +hm --disable-libgcj-debug --enable-interpreter --enable-hash-synchron +ization --enable-libstdcxx-debug Thread model: win32 gcc version 3.4.5 (mingw-vista special r3)
      You should see something similar.
      Something is seriously broken ... probably, but not necessarily, MinGW.

      Cheers,
      Rob
        Here is the result:
        Reading specs from C:/strawberry/c/bin/../lib/gcc/mingw32/3.4.5/specs Configured with: ../gcc-3.4.5-20060117-3/configure --with-gcc --with-g +nu-ld --with-gnu-as --host=mingw32 --target=mingw32 --prefix=/mingw - +-enable-thr eads --disable-nls --enable-languages=c,c++,f77,ada,objc,java --disabl +e-win32-registry --disable-shared --enable-sjlj-exceptions --enable-l +ibgcj --dis able-java-awt --without-x --enable-java-gc=boehm --disable-libgcj-debu +g --enable-interpreter --enable-hash-synchronization --enable-libstdc +xx-debug Thread model: win32 gcc version 3.4.5 (mingw-vista special r3)
        Seriously broken.... hmm. That a good thing? :D
        - Cbeppe
      Ok, so I gave up on Win32::GUI, and installed ActivePerl from activestate. I also downloaded their Tcl and Tkx, which does very much the same as Win32::Gui.

      I'd just like to thank everyone who helped me out here. I see myself becoming a member of this forum as soon as I get an account.

      Thanks :)
      - Cbeppe
      I'm running Windows 7 64bit (Could that be a problem?) and Strawberry Perl 5.10.1.3.

      The result for the new MinGW compiler is this:
      Using built-in specs. COLLECT_GCC=gcc Target: mingw32 Configured with: ../gcc-4.5.0/configure --enable-languages=c,c++,ada,f +ortran,objc,obj-c++ --disable-sjlj-exceptions --with-dwarf2 --enable- +shared --en able-libgomp --disable-win32-registry --enable-libstdcxx-debug --enabl +e-version-specific-runtime-libs --disable-werror --build=mingw32 --pr +efix=/mingw Thread model: win32 gcc version 4.5.0 (GCC)
      As you can see, the new MinGW is a later version than the one shipped with Perl.
      I ran the commands you mentioned, but it still returns the same errors on dmake. Dmake realclean does not return an error, but doesn't seem to affect the install in any other way though.

      - Cbeppe
        I'm running Windows 7 64bit (Could that be a problem?) and Strawberry Perl 5.10.1.3

        I'm running Windows Vista 64 bit with both 32-bit and 64-bit builds of Strawberry Perl, and there's no problem.
        I guess there could be some Windows7-specific issue involved ... but I've not heard of any such thing.

        The compilers you're using are 32-bit compilers, which should be fine as long as your build of Strawberry Perl is also 32-bit. I don't think Strawberry Perl even provides a 64-bit build of perl 5.10.
        Anyway, just check that perl -V:archname reports MSWin32-x86-multi-thread, not MSWin32-x64-multi-thread

        Can't really think of anything else ...

        Cheers,
        Rob

        Avoid mixing Strawberry perl with your own mingw installation unless you exactly know what can happen. I recommend to remove all the other mingws from your PATH when building Win32::GUI in strawberry perl.

        Also assure that you do not have some other copy of dmake.exe in your PATH before strawberry's directories (IIRC Win32::GUI generate slightly strange Makefile which can be refused by the original dmake - e.g. https://rt.cpan.org/Public/Bug/Display.html?id=53721)

        Win32::GUI should build fine with Strawberry perl 5.10.1 with mingw toolchain included with strawberry perl.

        --
        kmx

      Here's one more idea if someone is willing to help:

      Could someone please upload an archive containing the directories that Win32::GUI installs itself into, so that I can do a very manual install? This is definitely a last resort, but it should work unless I need to modify the registry substantially.

      I'd really appreciate it if someone would be willing to help out on this.

      Thanks. - Cbeppe
        This is definitely a last resort, but it should work unless I need to modify the registry substantially

        Unfortunately it won't work - if 'dmake' hasn't been run successfully, then you don't have all of the files that are needed for a successful installation.

        Haven't grabbed the dll.exp file yet - apparently I need to register in order to be able to download anything ... which is a bit of a nuisance. Sounds like it's probably no good, anyway (given that it's so much smaller than the one my identical compiler produces).

        Cheers,
        Rob
      I just downloaded the 64bit version of Perl, which is still in Beta. I ran the installation process again, and got this error:
      In file included from Scintilla.xs:8: ../GUI.h:100: note: #pragma message: *** Using Preserved Perl context. In file included from Scintilla.xs:8: ../GUI.h:768: warning: 'ImageList_Duplicate' redeclared without dllimp +ort attribute: previous dllimport ignored Scintilla.xs: In function 'CallWndProc': Scintilla.xs:199: error: 'GWL_USERDATA' undeclared (first use in this +function) Scintilla.xs:199: error: (Each undeclared identifier is reported only +once Scintilla.xs:199: error: for each function it appears in.) dmake: Error code 129, while making 'Scintilla.o' dmake: Error code 255, while making 'subdirs'
      The error codes are the same, but the file that is causing the trouble is different. Any ideas?

      - Cbeppe

        Win32::GUI is known to have problems on 64bit Windows
        You can try my patched version from:

        http://strawberryperl.com/package/kmx/perl-modules-patched/Win32-GUI-1.06_patched2.tar.gz

        It builds fine on 64bit Strawberry Perl 5.12.

        --
        kmx