mirror of
https://github.com/NaomiAmethyst/dots.git
synced 2025-04-13 09:30:06 +00:00
[answerback] handle different systems
This commit is contained in:
parent
b3e8467693
commit
0cbb34a92a
2 changed files with 11 additions and 6 deletions
|
@ -71,8 +71,9 @@ if command -v infocmp >/dev/null 2>&1 ; then
|
|||
TERM="xterm-256color"
|
||||
fi
|
||||
else
|
||||
if command -v answerback >/dev/null 2>&1 ; then
|
||||
ANSWERBACK=`answerback`
|
||||
answerback_cmd="answerback.`uname -s`"
|
||||
if command -v ${answerback_cmd} >/dev/null 2>&1 ; then
|
||||
ANSWERBACK=`${answerback_cmd} 2>/dev/null`
|
||||
export ANSWERBACK
|
||||
fi
|
||||
fi
|
||||
|
|
12
install.pl
12
install.pl
|
@ -84,8 +84,6 @@ my %links = (
|
|||
'git-info' => 'bin/git-info',
|
||||
'git-untrack-ignored' => 'bin/git-untracked-ignored',
|
||||
|
||||
answerback => 'bin/answerback',
|
||||
|
||||
gdbinit => '.gdbinit',
|
||||
);
|
||||
|
||||
|
@ -96,8 +94,14 @@ if ($contained) {
|
|||
($prefix) = $prefix =~ m{^\/? (.+) [^/]+ $}x;
|
||||
}
|
||||
|
||||
`make answerback`;
|
||||
warn "Could not compile answerback.\n" if ($? != 0);
|
||||
chomp(my $uname = `uname -s`);
|
||||
`cc answerback.c -o answerback.$uname`;
|
||||
if ($? != 0) {
|
||||
warn "Could not compile answerback.\n";
|
||||
} else {
|
||||
$links{"answerback.$uname"} = "bin/answerback.$uname";
|
||||
}
|
||||
|
||||
|
||||
my $i = 0; # Keep track of how many links we added
|
||||
for my $file (keys %links) {
|
||||
|
|
Loading…
Add table
Reference in a new issue