Alien-IUP
view release on metacpan or search on metacpan
$builder->notes('iup_sha1', 'DO_NOT_CHECK_SHA1');
$builder->notes('im_url', 'https://github.com/kmx/mirror-im/tarball/master');
$builder->notes('im_sha1', 'DO_NOT_CHECK_SHA1');
$builder->notes('cd_url', 'https://github.com/kmx/mirror-cd/tarball/master');
$builder->notes('cd_sha1', 'DO_NOT_CHECK_SHA1');
$builder->notes('build_debug_info', 1);
$builder->notes('is_devel_cvs_version', 1)
}
else {
if ($builder->check_installed_lib()) {
my $ans = $ENV{TRAVIS} ? 'y' : $builder->prompt("\nIUP detected, wanna use IUP already installed on your system (y/n)?", 'y');
$builder->notes('already_installed_lib', undef) if lc($ans) ne 'y';
}
# set what tarballs we are gonna use
#$builder->notes('iup_url', 'http://download.sf.net/iup/iup-3.19.1_Sources.tar.gz');
$builder->notes('iup_url', 'http://strawberryperl.com/package/kmx/iup/iup-3.19.1_Sources.tar.gz');
$builder->notes('iup_sha1', '3d94e148c8e93f80572667a74a2d5ecbf18a460c');
$builder->notes('iup_patches', [ qw!patches/iup-3.19.1-cygwin.diff patches/old-cygwin.diff patches/iup-plot-contextplus.diff! ] );
#$builder->notes('im_url', 'http://download.sf.net/imtoolkit/im-3.11_Sources.tar.gz');
0.0.22 2010-10-12
- fixed GNU make check exit code
0.0.21 2010-10-11
- GNU make check moved to Build.pl (now cpan testers should report "N/A)
- more messages on sha1 check failure
- small POD changes
0.0.20 2010-10-05
- more questions/prompts during build
- cleaning up + cosmetics
- OpenBSD - not building im_process (g++ internal error)
- OpenBSD - lesstif related fixes
- DragonFly patch for 'sizeof(FILE)'
- exit if GNU make not found
- DragonFly patch for libjasper/jasper/jas_types.h
- create_makefile_pl => 'small' (creating Makefile.PL to satisfy old CPAN clients)
0.0.19 2010-09-28
- iup patch - fixing newlines in the main Makefile (troubles on solaris)
inc/My/Builder.pm view on Meta::CPAN
if ( ! -e 'build_done' ) {
my $inst = $self->notes('already_installed_lib');
if (defined $inst) {
$self->config_data('config', { LIBS => $inst->{lflags},
INC => $inst->{cflags},
});
}
else {
# some questions before we start
my $dbg = !$ENV{TRAVIS} ? $self->prompt("\nDo you want to see debug info + all messages during 'make' (y/n)?", 'n') : 'n';
$self->notes('build_msgs', lc($dbg) eq 'y' ? 1 : 0);
$self->notes('build_debug_info', lc($dbg) eq 'y' ? 1 : 0);
#my $large_imglib = $ENV{TRAVIS} ? 'y' : lc($self->prompt("Do you wanna compile built-in images with large (48x48) size? ", "y"));
my $large_imglib = 'y'; #forcing large icons
$self->notes('build_large_imglib', lc($large_imglib) eq 'y' ? 1 : 0);
# important directories
my $download = 'download';
my $patches = 'patches';
my $build_src = 'build_src';
# we are deriving the subdir name from VERSION as we want to prevent
# troubles when user reinstalls the newer version of Alien package
my $share_subdir = $self->{properties}->{dist_version};
inc/My/Builder.pm view on Meta::CPAN
my $build_out = catfile('sharedir', $share_subdir);
$self->add_to_cleanup($build_out);
# store info into CofigData
$self->config_data('iup_url', $self->notes('iup_url'));
$self->config_data('im_url', $self->notes('im_url'));
$self->config_data('cd_url', $self->notes('cd_url'));
# prepare sources
my $unpack;
$unpack = (-d "$build_src/iup") && !$ENV{TRAVIS} ? $self->prompt("\nDir '$build_src/iup' exists, wanna replace with clean sources?", "n") : 'y';
if (lc($unpack) eq 'y') {
File::Path::rmtree("$build_src/iup") if -d "$build_src/iup";
$self->prepare_sources($self->notes('iup_url'), $self->notes('iup_sha1'), $download, $build_src);
if ($self->notes('iup_patches')) {
$self->apply_patch("$build_src/iup", $_) foreach (@{$self->notes('iup_patches')});
}
}
$unpack = (-d "$build_src/im") && !$ENV{TRAVIS} ? $self->prompt("\nDir '$build_src/im' exists, wanna replace with clean sources?", "n") : 'y';
if (lc($unpack) eq 'y') {
File::Path::rmtree("$build_src/im") if -d "$build_src/im";
$self->prepare_sources($self->notes('im_url'), $self->notes('im_sha1'), $download, $build_src);
if ($self->notes('im_patches')) {
$self->apply_patch("$build_src/im", $_) foreach (@{$self->notes('im_patches')});
}
}
$unpack = (-d "$build_src/cd") && !$ENV{TRAVIS} ? $self->prompt("\nDir '$build_src/cd' exists, wanna replace with clean sources?", "n") : 'y';
if (lc($unpack) eq 'y') {
File::Path::rmtree("$build_src/cd") if -d "$build_src/cd";
$self->prepare_sources($self->notes('cd_url'), $self->notes('cd_sha1'), $download, $build_src);
if ($self->notes('cd_patches')) {
$self->apply_patch("$build_src/cd", $_) foreach (@{$self->notes('cd_patches')});
}
}
$unpack = (-d "$build_src/zlib") && !$ENV{TRAVIS} ? $self->prompt("\nDir '$build_src/zlib' exists, wanna replace with clean sources?", "n") : 'y';
if ($self->notes('zlib_url') && !$self->config_data('syszlib_lflags') && lc($unpack) eq 'y') {
File::Path::rmtree("$build_src/zlib") if -d "$build_src/zlib";
$self->prepare_sources($self->notes('zlib_url'), $self->notes('zlib_sha1'), $download, $build_src);
if ($self->notes('zlib_patches')) {
$self->apply_patch("$build_src/zlib", $_) foreach (@{$self->notes('zlib_patches')});
}
}
$unpack = (-d "$build_src/freetype") && !$ENV{TRAVIS} ? $self->prompt("\nDir '$build_src/freetype' exists, wanna replace with clean sources?", "n") : 'y';
if ($self->notes('freetype_url') && !$self->config_data('sysfreetype_lflags') && lc($unpack) eq 'y') {
File::Path::rmtree("$build_src/freetype") if -d "$build_src/freetype";
$self->prepare_sources($self->notes('freetype_url'), $self->notes('freetype_sha1'), $download, $build_src);
if ($self->notes('freetype_patches')) {
$self->apply_patch("$build_src/freetype", $_) foreach (@{$self->notes('freetype_patches')});
}
}
$unpack = (-d "$build_src/ftgl") && !$ENV{TRAVIS} ? $self->prompt("\nDir '$build_src/ftgl' exists, wanna replace with clean sources?", "n") : 'y';
if ($self->notes('ftgl_url') && lc($unpack) eq 'y') {
File::Path::rmtree("$build_src/ftgl") if -d "$build_src/ftgl";
$self->prepare_sources($self->notes('ftgl_url'), $self->notes('ftgl_sha1'), $download, $build_src);
if ($self->notes('ftgl_patches')) {
$self->apply_patch("$build_src/ftgl", $_) foreach (@{$self->notes('ftgl_patches')});
}
}
### XXX hack for handling github tarballs
unless (-d "$build_src/cd" && -d "$build_src/im" && -d "$build_src/iup") {
inc/My/Builder/Unix.pm view on Meta::CPAN
warn "###WARN### skipping iup_mglplot on Solaris (fails to compile)";
@iuptargets = grep { $_ !~ /^iup_mglplot$/ } @iuptargets;
}
}
my $ftgl_target = 1;
unless ($has{l_GL} && $has{l_GLU} && $has{gl} && $has{glx} && $has{glu}) {
warn "###WARN### OpenGL libraries not found or not complete\n";
warn "- required headers: GL/gl.h GL/glx.h GL/glu.h\n";
warn "- required libraries: libGL libGLU\n";
my $skip = $ENV{TRAVIS} ? 'y' : $self->prompt("Skip OpenGL related IUP/CD components?", 'y');
if (lc($skip) eq 'y') {
@cdtargets = grep { $_ !~ /^(cd_ftgl|cdgl)$/ } @cdtargets;
@iuptargets = grep { $_ !~ /^(iup_mglplot|iup_plot|iupglcontrols|iupgl)$/ } @iuptargets;
$ftgl_target = 0;
}
}
@iuptargets = grep { $_ !~ /^(iupweb)$/ } @iuptargets unless $has{webkit};
#store debug info into ConfigData
$self->config_data('info_has', \%has);
inc/My/Builder/Unix.pm view on Meta::CPAN
push(@build_opts, 'X11/Motif') if ($has{Xlib} && $has{Xm});
if (scalar(@build_opts) == 1) {
$build_target = $build_opts[0];
}
elsif (scalar(@build_opts) > 1) {
my $n = 1;
my $msg = "\nYou have the following build options available:\n" .
join("\n", map ($n++ . ") $_", @build_opts)) .
"\nWhat do you wanna build?";
my $i = $ENV{TRAVIS} ? 1 : $self->prompt($msg, 1);
$build_target = $build_opts[$i-1];
die "###ERROR### Wrong selection!" unless $build_target;
}
else {
warn "###WARNING### No supported GUI subsystem detected!\n";
}
if ($self->notes('build_debug_info') || ( !$build_target && $ENV{AUTOMATED_TESTING} ) ) {
foreach (sort keys %has) {
my $msg = "has: $has{$_} - $_";
( run in 0.659 second using v1.01-cache-2.11-cpan-0b5f733616e )