You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

112 lines
3.8 KiB

Index: cvs/install.pl
--- cvs/install.pl.orig 2009-02-03 22:33:00 +0100
+++ cvs/install.pl 2009-02-06 23:12:14 +0100
@@ -102,11 +102,11 @@
}
# prior installation may not have supported .makepp/*.mk files
--r "$datadir/FileInfo_makepp.pm" and
- (stat "$datadir/FileInfo_makepp.pm")[9] < 1102710870 || # check-in time
+-r "$ENV{DESTDIR}$datadir/FileInfo_makepp.pm" and
+ (stat "$ENV{DESTDIR}$datadir/FileInfo_makepp.pm")[9] < 1102710870 || # check-in time
do {
my $found;
- open F, "$datadir/FileInfo_makepp.pm";
+ open F, "$ENV{DESTDIR}$datadir/FileInfo_makepp.pm";
while( <F> ) {
$found = 1, last if /build_info_subdir.+\.mk/;
}
@@ -152,7 +152,7 @@
@sig_num{split ' ', $Config{sig_name}} = split ' ', $Config{sig_num};
$USR1 = $sig_num{USR1}; $USR1 = $USR1; # suppress used-only-once warning
-make_dir("$datadir/$_") for
+make_dir("$ENV{DESTDIR}$datadir/$_") for
qw(Mpp ActionParser BuildCheck CommandParser Scanner Signature);
our $useoldmodules = '';
@@ -180,10 +180,10 @@
}
}
-substitute_file( $_, $bindir, 0755, 1 ) for
+substitute_file( $_, "$ENV{DESTDIR}$bindir", 0755, 1 ) for
qw(makepp makeppbuiltin makeppclean makeppgraph makeppinfo makepplog makeppreplay makepp_build_cache_control);
-substitute_file( $_, $datadir, 0644 ) for
+substitute_file( $_, "$ENV{DESTDIR}$datadir", 0644 ) for
qw(recursive_makepp FileInfo_makepp.pm Mpp/BuildCacheControl.pm);
foreach $module (qw(Mpp/Frame
@@ -208,13 +208,13 @@
Signature Signature/c_compilation_md5 Signature/md5
Signature/shared_object Signature/verilog_simulation_md5
Signature/verilog_synthesis_md5)) {
- copy("$module.pm", "$datadir/$module.pm");
- chmod 0644, "$datadir/$module.pm";
+ copy("$module.pm", "$ENV{DESTDIR}$datadir/$module.pm");
+ chmod 0644, "$ENV{DESTDIR}$datadir/$module.pm";
}
foreach $include (qw(makepp_builtin_rules makepp_default_makefile)) {
- copy("$include.mk", "$datadir/$include.mk");
- chmod 0644, "$datadir/$include.mk";
+ copy("$include.mk", "$ENV{DESTDIR}$datadir/$include.mk");
+ chmod 0644, "$ENV{DESTDIR}$datadir/$include.mk";
}
#
@@ -228,16 +228,16 @@
# Install the man pages:
#
if ($mandir ne 'none') {
- make_dir("$mandir/man1");
+ make_dir("$ENV{DESTDIR}$mandir/man1");
foreach $file (@pods) {
my $manfile = $file;
$manfile =~ s/\.pod$/.1/; # Get the name of the man file.
$manfile =~ s@^pod/@@;
- system("pod2man $file > $mandir/man1/$manfile 2>/dev/null");
+ system("pod2man $file > $ENV{DESTDIR}$mandir/man1/$manfile 2>/dev/null");
# Ignore stderr because older versions of
# pod2man (e.g., perl 5.006) don't understand
# =head3.
- chmod 0644, "$mandir/man1/$manfile";
+ chmod 0644, "$ENV{DESTDIR}$mandir/man1/$manfile";
}
}
@@ -409,8 +409,8 @@
$nav .= join '<br />', map $link{$_}, @links;
}
$nav .= '</td></tr></table>';
- open my $outfile, ">$htmldir_val/$_" or die "can't create `$htmldir_val/$_'--$!";
- chmod 0644, "$htmldir_val/$_";
+ open my $outfile, ">$ENV{DESTDIR}$htmldir_val/$_" or die "can't create `$htmldir_val/$_'--$!";
+ chmod 0644, "$ENV{DESTDIR}$htmldir_val/$_";
s/\.html$//;
my $title = (s/^makepp(?:_|$)// ? 'Makepp ' : '') . $alias{$_ || 'makepp'};
my $index;
@@ -562,11 +562,11 @@
unlink $tmp;
for( qw'google.png makepp.gif makepp.css pre.png sflogo.png url.png' ) {
- copy $_, "$htmldir_val/$_";
- chmod 0644, "$htmldir_val/$_";
+ copy $_, "$ENV{DESTDIR}$htmldir_val/$_";
+ chmod 0644, "$ENV{DESTDIR}$htmldir_val/$_";
}
- symlink 'makepp.html', "$htmldir_val/index.html";
+ symlink 'makepp.html', "$ENV{DESTDIR}$htmldir_val/index.html";
}
#
@@ -672,6 +672,7 @@
}
sub read_with_prompt {
+ return undef;
local $| = 1; # Enable autoflush on STDOUT.
print @_; # Print the prompt.