#!/usr/local/bin/perl -w
=head1 NAME
build_vcp_executable.pl
=head1 SYNOPSIS
cd VCP
bin\build_vcp_executable.pl
=head1 DESCRIPTION
Builds vcp binaries using PAR's pp command. Make sure you have all the
VCP prereqs installed because pp silently won't include any not found.
=cut
use strict;
use lib "lib";
use VCP::Utils qw( scan_pm_files_in );
## VCP uses lazy loading extensively...
my @modules = (
scan_pm_files_in( "VCP" ),
scan_pm_files_in( "VCP::Source" ),
scan_pm_files_in( "VCP::Filter" ),
scan_pm_files_in( "VCP::Dest" ),
scan_pm_files_in( "VCP::Utils" ),
scan_pm_files_in( "VCP::UI" ),
);
warn map "$_\n", @modules;
system
"pp",
# "-p", "-o", "vcp.par",
"-o", "vcp.exe",
"-lib=lib",
map( "-add=$_", @modules ),
"bin/vcp"
and die $!;