Skip to content

Commit

Permalink
osgeo4w: fix creatensis.pl
Browse files Browse the repository at this point in the history
  • Loading branch information
jef-n committed Oct 20, 2013
1 parent c40a698 commit be6d30f
Showing 1 changed file with 18 additions and 4 deletions.
22 changes: 18 additions & 4 deletions ms-windows/osgeo4w/creatensis.pl
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,10 @@ sub getDeps {
my @desc;
foreach my $p ( keys %pkgs ) {
my @f;
unless( exists $file{$p} ) {
print "No file for package $p found found.\n" if $verbose;
next;
}
push @f, "$root/$file{$p}";

if( exists $lic{$p} ) {
Expand Down Expand Up @@ -174,9 +178,19 @@ sub getDeps {
print O "INSTALLED.DB 2\n";

foreach my $pn ( keys %pkgs ) {
$p = $file{$pn};
my $p = $file{$pn};
unless( defined $p ) {
print "No package found for $pn\n" if $verbose;
next;
}

$p =~ s#^.*/#$packages/#;

unless( -r $p ) {
print "Package $p not found.\n" if $verbose;
next;
}

print O "$pn $p 0\n";

print "Unpacking $p...\n" if $verbose;
Expand Down Expand Up @@ -288,8 +302,8 @@ sub getDeps {
$version = "$major.$minor.$patch" unless defined $version;

unless( defined $binary ) {
if( -f "binary-$archpostfix$version" ) {
open P, "binary-$archpostfix$version";
if( -f "binary$archpostfix-$version" ) {
open P, "binary$archpostfix-$version";
$binary = <P>;
close P;
$binary++;
Expand Down Expand Up @@ -386,7 +400,7 @@ sub getDeps {
system $cmd;
die "running nsis failed" if $?;

open P, ">osgeo4w/binary-$archpostfix$version";
open P, ">osgeo4w/binary$archpostfix-$version";
print P $binary;
close P;

Expand Down

0 comments on commit be6d30f

Please sign in to comment.