Hi Monks,

I'm trying to write a perl script in a Windows environment that will detect the color of the pixel the cursor is pointing at. After some cpan searching, Win32::Screenshot looks ideal, as it allows me to do a quick capture of a specified (small) rectangle on the screen. This would be much more efficient than doing a full screen or window capture, and then picking through the data to find my pixel.

However, I'm having a tough time getting Win32::Screenshot to install correctly. It has a prerequisite of installing Image-Magick. I installed the windows binary, and during the installation, it also installed the perl interface. I verified this in ppm with a query:

15. Image-Magick 6.2.3 ImageMagick PERL Extension

According to the Screenshot README, that's the only prerequisite. So I run "perl Makefile.PL" in the Screenshot directory, and I get the following output:

C:\apps\Perl\dev\Win32-Screenshot-1.20>perl Makefile.PL Note (probably harmless): No library found for comctl32.lib Note (probably harmless): No library found for oldnames.lib Note (probably harmless): No library found for kernel32.lib Note (probably harmless): No library found for user32.lib Note (probably harmless): No library found for gdi32.lib Note (probably harmless): No library found for winspool.lib Note (probably harmless): No library found for comdlg32.lib Note (probably harmless): No library found for advapi32.lib Note (probably harmless): No library found for shell32.lib Note (probably harmless): No library found for ole32.lib Note (probably harmless): No library found for oleaut32.lib Note (probably harmless): No library found for netapi32.lib Note (probably harmless): No library found for uuid.lib Note (probably harmless): No library found for ws2_32.lib Note (probably harmless): No library found for mpr.lib Note (probably harmless): No library found for winmm.lib Note (probably harmless): No library found for version.lib Note (probably harmless): No library found for odbc32.lib Note (probably harmless): No library found for odbccp32.lib Note (probably harmless): No library found for msvcrt.lib Writing Makefile for Win32::Screenshot
If the only prerequisite is Image Magick, why are all these libraries missing??

nmake install produces the following error:

C:\apps\Perl\dev\Win32-Screenshot-1.20>nmake install Microsoft (R) Program Maintenance Utility Version 1.50 Copyright (c) Microsoft Corp 1988-94. All rights reserved. cl -c -I. -nologo -Gf -W3 -MD -Zi -DNDEBUG -O1 -DWIN32 -D_CO +NSOLE -DNO _STRICT -DHAVE_DES_FCRYPT -DNO_HASH_SEED -DPERL_IMPLICIT_CONTEXT -DPER +L_IMPLICIT _SYS -DUSE_PERLIO -DPERL_MSVCRT_READFIX -MD -Zi -DNDEBUG -O1 -DVERS +ION=\"1.20 \" -DXS_VERSION=\"1.20\" "-IC:\apps\Perl\lib\CORE" Screenshot.c 'cl' is not recognized as an internal or external command, operable program or batch file. NMAKE : fatal error U1077: 'C:\WINDOWS\system32\cmd.exe' : return code + '0x1' Stop.
I assume "cl" is a c compiler, but I've never had to use a compiler to do a perl install, so what's going on here? Is there a way I can get this cl compiler, or can I specfiy a different compiler?

Any help with this is greatly appreciated.

In reply to Installing Win32::Screenshot by TROGDOR

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.