/usr/lib/x86_64-linux-gnu/perl5/5.26/Wx/build/MakeMaker/Win32.pm is in libwx-perl 1:0.9932-4.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | package Wx::build::MakeMaker::Win32;
use strict;
use base 'Wx::build::MakeMaker::Any_OS';
use Wx::build::Utils;
use Config;
sub is_mingw() { $Config{cc} =~ /gcc/ }
sub is_msvc() { $Config{cc} =~ /cl/ }
sub get_flags {
my $this = shift;
my %config = $this->SUPER::get_flags;
$config{CC} = Alien::wxWidgets->compiler;
$config{LD} = Alien::wxWidgets->linker;
# used to be CCFLAGS, but overrode CCFLAGS from MakeMaker
$config{CC} .= ' ' . Alien::wxWidgets->c_flags . ' ';
# $config{dynamic_lib}{OTHERLDFLAGS} = Alien::wxWidgets->link_flags;
$config{clean}{FILES} .= is_mingw ? ' dll.base dll.exp '
:' *.pdb *.pdb *_def.old ';
$config{DEFINE} .= Alien::wxWidgets->defines . ' ';
$config{INC} .= Alien::wxWidgets->include_path;
if( $this->_debug ) {
$config{OPTIMIZE} = ' ';
}
if( is_mingw() ) {
# add $MINGWDIR/lib to lib search path, to stop perl from complaining...
my $path = Wx::build::Utils::path_search( 'gcc.exe' )
or warn "Unable to find gcc";
$path =~ s{bin[\\/]gcc\.exe$}{}i;
$config{LIBS} = "-L${path}lib " . ( $config{LIBS} || '' );
} else {
$config{DEFINE} .= '-D_CRT_SECURE_NO_DEPRECATE ';
}
return %config;
}
sub configure_core {
my $this = shift;
my %config = $this->SUPER::configure_core( @_ );
my $res = $this->_res_file;
$config{depend} = { $res => 'Wx.rc ' };
$config{LDFROM} .= "\$(OBJECT) $res ";
$config{dynamic_lib}{INST_DYNAMIC_DEP} .= " $res";
$config{clean}{FILES} .= " $res Wx_def.old";
return %config;
}
sub postamble_core {
my $this = shift;
my $text = $this->SUPER::postamble_core( @_ );
return $text unless $Wx::build::MakeMaker::Core::has_alien;
my $wxdir = Alien::wxWidgets->wx_base_directory;
my $command = $this->_res_command;
my $res_file = $this->_res_file;
$command =~ s/%incdir/$wxdir\\include/;
$command =~ s/%src/Wx.rc/;
$command =~ s/%dest/$res_file/;
my $strip = $this->_strip_command;
$text .= sprintf <<'EOT', $res_file, $command, $strip, $^X;
%s : Wx.rc
%s
# for compatibility
ppmdist : ppm
ppm : pure_all
%s
%s script/make_ppm.pl
EOT
}
1;
# local variables:
# mode: cperl
# end:
|