Subject: | standard portability issues with Makefile.PL/test.pl |
Hi.
I strongly suggest you read `perldoc perlport'
and `perldoc ExtUtils::MakeMaker'.
Please use ExtUtils::MakeMaker's prompt function to prompt
because it respects PERL_MM_USE_DEFAULT.
You should prompt to run java_server_install.pl.
For testing purposes, you should simply prompt to run JavaServer.jar
from where it is currently (simplifies matters).
You should use File::Spec when dealing with filenames
(in your case, a few calls to File::Spec->canonpath are in order)
And finally, you shouldn't be using system calls to copy files.
The following is not nice
if ($OS =~ /windows/i)
{
system("copy JavaServer.jar $lib");
}
else
{
system("/bin/cp JavaServer.jar $lib");
}
just use File::Copy, and avoid any and all such portability issues.
BTW, for future reference, if you want to check $^O,
check out
http://perlmonks.com/index.pl?node_id=233481
or
http://alma.ch/perl/perloses.htm
for a comprehensive list.
$^O on windows is not 'windows'.