forked from Lainports/freebsd-ports
- install the correct ChangeLog - add a patch so we have a better chance of working with 4.x Perl PR: 61058 Submitted by: maintainer
70 lines
1.3 KiB
Text
70 lines
1.3 KiB
Text
$FreeBSD$
|
|
|
|
--- gift-setup.in.orig Tue Dec 23 05:22:52 2003
|
|
+++ gift-setup.in Sun Jan 4 18:11:01 2004
|
|
@@ -338,31 +338,31 @@
|
|
my ($path_cfg_dir) = $path_cfg =~ m/^(.*)\/[^\/]+$/;
|
|
mkdir ($path_cfg_dir, 0755) unless (-d $path_cfg_dir);
|
|
|
|
- open (my $fcfg, ">$path_cfg") or
|
|
+ open (fcfg, ">$path_cfg") or
|
|
die "Cannot open $path_cfg: $!";
|
|
|
|
- open (my $ftpl, $path_tpl) or
|
|
+ open (ftpl, $path_tpl) or
|
|
die "Cannot open $path_tpl: $!";
|
|
|
|
my $cfg_hdr;
|
|
|
|
- while (<$ftpl>)
|
|
+ while (<ftpl>)
|
|
{
|
|
$cfg_hdr = $1 if m/^\[(\w+)\]$/;
|
|
|
|
if (m/^\#?(\w+) =\s?(.*)$/)
|
|
{
|
|
die unless defined $cfg_hdr;
|
|
- printf $fcfg ("%s = %s\n", $1, $cfg_tbl->{"/$cfg_hdr/$1"});
|
|
+ printf fcfg ("%s = %s\n", $1, $cfg_tbl->{"/$cfg_hdr/$1"});
|
|
}
|
|
else
|
|
{
|
|
- print $fcfg $_;
|
|
+ print fcfg $_;
|
|
}
|
|
}
|
|
|
|
- close $fcfg;
|
|
- close $ftpl;
|
|
+ close fcfg;
|
|
+ close ftpl;
|
|
|
|
printf ("Wrote %s.\n", $path_cfg);
|
|
}
|
|
@@ -376,7 +376,7 @@
|
|
my $cfg_ent = {};
|
|
my $cfg_hdr = undef;
|
|
|
|
- open (my $fhandle, $template) or
|
|
+ open (fhandle, $template) or
|
|
die "Cannot open $template: $!";
|
|
|
|
#
|
|
@@ -387,7 +387,7 @@
|
|
#
|
|
my $reading = 0;
|
|
|
|
- while (<$fhandle>)
|
|
+ while (<fhandle>)
|
|
{
|
|
$cfg_hdr = $1 if m/^\[(\w+)\]$/;
|
|
|
|
@@ -425,7 +425,7 @@
|
|
}
|
|
}
|
|
|
|
- close $fhandle;
|
|
+ close fhandle;
|
|
|
|
return \@cfg_tbl;
|
|
}
|