Commit | Line | Data |
---|---|---|
4d3416a4 FF |
1 | Only in .: install.pl |
2 | diff -u -r ../cowsay-3.03+dfsg1/install.sh ./install.sh | |
3 | --- ../cowsay-3.03+dfsg1/install.sh 1999-11-01 15:19:21.000000000 -0500 | |
4 | +++ ./install.sh 2016-04-14 21:14:44.715683710 -0400 | |
5 | @@ -14,55 +14,8 @@ | |
6 | ||
7 | filelist='cows' | |
8 | ||
9 | -cat <<DOG | |
10 | -=================== | |
11 | -cowsay Installation | |
12 | -=================== | |
13 | - | |
14 | -Searching for useful perl executables... | |
15 | -DOG | |
16 | - | |
17 | -backdoor=$1 | |
18 | - | |
19 | -pathdirs=`echo $PATH | tr : " "` | |
20 | -for p in $pathdirs; do | |
21 | - set $p/perl $p/perl5* | |
22 | - while [ ! -z "$1" ]; do | |
23 | - if [ -x "$1" ]; then | |
24 | - echo Found perl in $1 | |
25 | - perls="$perls $1" | |
26 | - fi | |
27 | - shift | |
28 | - done | |
29 | -done | |
30 | -for perl in $perls; do | |
31 | - if $perl -MText::Wrap -e0 >/dev/null 2>&1; then | |
32 | - echo Found a good perl in $perl | |
33 | - goodperls="$goodperls $perl" | |
34 | - fi | |
35 | -done | |
36 | -echo The following perl executables will run cowsay: | |
37 | -echo $goodperls | |
38 | -echo I recommend the latest stable perl you can find. | |
39 | -set $goodperls | |
40 | -if [ -z "$1" ]; then | |
41 | - echo Ack! You do not have Perl 5 installed correctly! | |
42 | - echo Get thee to CPAN! | |
43 | - exit 1 | |
44 | -fi | |
45 | -usethisperl=$1 | |
46 | -echo I will be using $1 because I know it will work. | |
47 | - | |
48 | -echo Now I need an installation prefix. I will use /usr/local unless | |
49 | -printf "you give me a better idea here: " | |
50 | -if [ -n "$backdoor" ]; then | |
51 | - prefix=$backdoor | |
52 | - printf "%s (specified on command line)\n" $prefix | |
53 | -else | |
54 | - read prefix | |
55 | -fi | |
56 | - | |
57 | -PREFIX=${prefix:-/usr/local} | |
58 | +usethisperl=/data/data/com.termux/files/usr/bin/perl | |
59 | +PREFIX=/data/data/com.termux/files/usr | |
60 | ||
61 | echo Okay, time to install this puppy. | |
62 | ||
63 | @@ -70,13 +23,13 @@ | |
64 | echo s,%PREFIX%,$PREFIX,\; >> install.pl | |
65 | set -x | |
66 | mkdir -p $PREFIX/bin || (mkdir $PREFIX; mkdir $PREFIX/bin) | |
67 | -$usethisperl -p install.pl cowsay > $PREFIX/bin/cowsay | |
68 | +perl -p install.pl cowsay > $PREFIX/bin/cowsay | |
69 | chmod a+x $PREFIX/bin/cowsay | |
70 | ln -s cowsay $PREFIX/bin/cowthink | |
71 | -mkdir -p $PREFIX/man/man1 || ($mkdir $PREFIX; mkdir $PREFIX/man; mkdir $PREFIX/man/man1) | |
72 | -$usethisperl -p install.pl cowsay.1 > $PREFIX/man/man1/cowsay.1 | |
73 | -chmod a+r $PREFIX/man/man1/cowsay.1 | |
74 | -ln -s cowsay.1 $PREFIX/man/man1/cowthink.1 | |
75 | +mkdir -p $PREFIX/share/man/man1 | |
76 | +perl -p install.pl cowsay.1 > $PREFIX/share/man/man1/cowsay.1 | |
77 | +chmod a+r $PREFIX/share/man/man1/cowsay.1 | |
78 | +(cd $PREFIX/share/man/man1; ln -f -s cowsay.1 cowthink.1 ) | |
79 | mkdir -p $PREFIX/share/cows || (mkdir $PREFIX; mkdir $PREFIX/share; mkdir $PREFIX/share/cows) | |
80 | tar -cf - $filelist | (cd $PREFIX/share && tar -xvf -) | |
81 | set +x |