8 my $sysconfdir = shift;
12 open(YIN
, "yasql.in") or die("Could not open yasql.in! $!");
13 # open yasql for writing
14 open(YOUT
, ">yasql") or die("Could not open yasql for writing! $!");
15 flock(YOUT
, 2) or die("Could not flock yasql! $!");
17 for(my $i = 0; <YIN
>; $i++) {
19 print YOUT
"#!" . $perlpath . "\n";
20 } elsif(/^\$sysconfdir = /) {
21 print YOUT
"\$sysconfdir = \"" . $sysconfdir . "\";\n";
22 } elsif(/^ \$VERSION = /) {
23 print YOUT
" \$VERSION = \"" . $version . "\";\n";
34 my $pod = Pod
::Man
->new(section
=>1);
35 $pod->parse_from_file ('yasql', 'yasql.1');
38 warn "Generating man page failed, install Pod::Man to fix this"
41 print "Configuration successful\n";