How to create a windows native binary check_logfiles.exe


1) Install Strawberry Perl (Portable Edition)
   from http://strawberryperl.com/
   It comes in a zip file, which you extract wherever you want.
   In my case the target is D:\tmp\strawberry-perl-5.32.1.1-64bit-portable

2) Enter the perl environment
   cd D:\tmp\strawberry-perl-5.32.1.1-64bit-portable
   .\portableshell.bat
   inside this portable shell you better start another powershell, otherwise a path length limit may be hit.

3) Install PAR::Packer 
   cpan install PAR
   cpan install PAR::Packer
   The installation will probably fail if your installation path is a long one.
   (You have a limit of 260 characters, which you can extend by setting Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\FileSystem\LongPathsEnabled to 1.)

4) Build the plugin
   cd check_logfiles-x.x.x.x or wherever you unpacked the check_logfiles tgz
   perl winconfig.pl

5) Compile the plugin
   cd plugins-scripts
   pp -M PerlIO -M Digest::MD5 -M Encode::Encoding -M Encode::Unicode -M Encode::Unicode::UTF7 -M Net::Domain -M Win32::NetResource -M Win32::Daemon -M Time::Piece -M Time::Local -M Win32::EventLog -M Win32::TieRegistry -M Win32::WinError -M Date::Manip -M Win32::OLE -o check_logfiles.exe check_logfiles
   (maybe you need to install Win32::NetResource and Win32::Daemon)
   (Win32::Service is useful, too)
   And when pp complains "Cannot find module Date/Manip.pm", then you install
   cpan install Date::Manip
   Ma moinad, do kannt oana vo selwa draafkema. Moinad ma. Douns owa ned.

6) Package the plugin
   C:\Programme\WinZip\WINZIP32.EXE -a check_logfiles.zip plugins-scripts\check_logfiles

If it does not work it's not my fault. It worked for me and my PC.
I read the documentation and played around until it worked.
If it does not work for you, read the documentation and play around.
At least for a week.
If it still does not work, forget check_logfiles.
Use check_hanswurscht instead. The source of check_hanswurscht is:

printf "hello hanswurscht\n";

Now try to create a windows binary with
pp -o check_hanswurscht.exe check_hanswurscht

Do not contact me if check_hanswurscht.exe doesn't work.
Please contact Strawberry and tell them:
"hi, i am a hanswurscht and i have a problem..."

