Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 104330
Collapse All | Expand All

(-)configure.orig (-4 / +8 lines)
Lines 5-11 Link Here
5
# do a clean up if we get a CTRL-C
5
# do a clean up if we get a CTRL-C
6
$SIG{INT} = sub  { unlink "lesspipe.sh.tmp"; print "\n"; exit 1 };
6
$SIG{INT} = sub  { unlink "lesspipe.sh.tmp"; print "\n"; exit 1 };
7
7
8
use vars qw($opt_help $opt_prefix $opt_yes $opt_default $opt_ask $opt_nomake
8
use vars qw($opt_help $opt_prefix $opt_yes $opt_default $opt_ask $opt_syntax $opt_nomake
9
            $opt_shell $ifsyntax %have %rep $recursion);
9
            $opt_shell $ifsyntax %have %rep $recursion);
10
10
11
# the above line will use any perl that is in your PATH. You might want to
11
# the above line will use any perl that is in your PATH. You might want to
Lines 13-20 Link Here
13
13
14
use Getopt::Long;
14
use Getopt::Long;
15
Getopt::Long::Configure("prefix_pattern=--");
15
Getopt::Long::Configure("prefix_pattern=--");
16
my $result = GetOptions qw(help+ prefix=s shell=s yes+ default+ ask+ nomake+);
16
my $result = GetOptions qw(help+ prefix=s shell=s yes+ default+ ask+ syntax+ nomake+);
17
### still missing: check proper version of tar, cpio, gzip, bzip2
17
### still missing: check proper version of tar, cpio, gzip, bzip1
18
if ( $ARGV[0] or ! $result or $opt_help) {
18
if ( $ARGV[0] or ! $result or $opt_help) {
19
  print << 'EOF';
19
  print << 'EOF';
20
Usage: configure [options]
20
Usage: configure [options]
Lines 25-30 Link Here
25
  --default               do not ask questions, try to guess correct answer
25
  --default               do not ask questions, try to guess correct answer
26
  --yes                   like --default but assume ´yes´ to all questions
26
  --yes                   like --default but assume ´yes´ to all questions
27
  --shell=<filename>      specify full path to an alternative shell to use
27
  --shell=<filename>      specify full path to an alternative shell to use
28
  --syntax                enable syntax highlighting
28
  --nomake                do not generate a Makefile
29
  --nomake                do not generate a Makefile
29
Directory and file names:
30
Directory and file names:
30
  --prefix=PREFIX         install lesspipe.sh in PREFIX/bin (/usr/local)
31
  --prefix=PREFIX         install lesspipe.sh in PREFIX/bin (/usr/local)
Lines 84-89 Link Here
84
my $shell = check_shell_vers();
85
my $shell = check_shell_vers();
85
# ask if syntax highlighting should be included
86
# ask if syntax highlighting should be included
86
$ifsyntax = '';
87
$ifsyntax = '';
88
if ($opt_syntax) {
89
	$ifsyntax = 'y';
90
} else {
87
if ($opt_yes) {
91
if ($opt_yes) {
88
  $ifsyntax = 'y';
92
  $ifsyntax = 'y';
89
} elsif ($opt_default) {
93
} elsif ($opt_default) {
Lines 97-103 Link Here
97
    $ifsyntax ||= 'n';
101
    $ifsyntax ||= 'n';
98
  }
102
  }
99
}
103
}
100
104
}
101
while (<IN>) {
105
while (<IN>) {
102
  s/^/#/ if /^setopt / and $shell ne 'zsh';
106
  s/^/#/ if /^setopt / and $shell ne 'zsh';
103
  if (/set -A cmd / and $shell ne 'ksh') {
107
  if (/set -A cmd / and $shell ne 'ksh') {

Return to bug 104330