ChiTownBob has asked for the wisdom of the Perl Monks concerning the following question:

I'm pretty much a newbie; used Perl very casually over the years, but never got too deep. Right now I'm trying to convert my company's docs into the Wikipedia format (MediaWiki), and I found a package http://search.cpan.org/~diberri/HTML-WikiConverter-0.30/WikiConverter.pm that promises to do that for HTML. (btw, if someone has a better way to do this, regardless of whether it's perl or not, *please* speak up). Anyway, CPAN fails to install it, and I am clueless as to why. Here's the relevant part of the output:
======================================== ............... HTML-WikiConverter-0.30/README Removing previously used \.cpan\build\HTML-WikiConverter-0.30 CPAN.pm: Going to build D/DI/DIBERRI/HTML-WikiConverter-0.30.tar.gz Checking if your kit is complete... Looks good Writing Makefile for HTML::WikiConverter -- OK Running make test 'test' is not recognized as an internal or external command, operable program or batch file. test -- NOT OK Running make install make test had returned bad status, won't install without force =============================
I've tried going back in and saying "force install HTML::WikiConverter" but that just fails in the same way.
This is all on Windows XP. Help?
Bob

Edited by Chady -- code tags, minor formatting, and linked url.

Replies are listed 'Best First'.
Re: CPAN install failure
by runrig (Abbot) on Sep 27, 2005 at 23:35 UTC
    You are on windows and do not have a 'make' command. See A guide to installing modules for Win32 and A Guide to Installing Modules. If you are using ActiveState perl, you should use ppm whenever possible, but I don't see a ppd for that module, so you will probably need to acquire and use nmake.exe and not make to manually install the module (or just copy the pm files to the appropriate places). I don't know if there is a way to tell CPAN.pm to use nmake.

      I believe the error reported of "'test' is not recognized as an internal or external command, operable program or batch file" means that the unix-ish test() was used in the tests. This would probably mean that a package like cygwin is needed, which provides such a utility, to properly run the tests in this case.

      In general, as far as using CPAN.pm on Win32, if one acquires nmake and places it somewhere on the PATH, then the CPAN.pm configuration will register and use it when building modules.

      It's certainly true though that it's much easier on Win32 to use the ppm utility - I've just placed in our uwinnipeg repository a ppm package for HTML-WikiConverter. Also, for future reference, like crazyinsomniac, I'm also open to taking requests for making up Win32 ppm packages - you may want to first check our CPAN search utility to see if a ppm package already exists; the database used includes ppm packages in the ActiveState, crazyinsomniac, bribes, and uwinnipeg repositories.