summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/util
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/util')
-rw-r--r--src/lib/libcrypto/util/dirname.pl18
-rw-r--r--src/lib/libcrypto/util/pod2mantest7
2 files changed, 22 insertions, 3 deletions
diff --git a/src/lib/libcrypto/util/dirname.pl b/src/lib/libcrypto/util/dirname.pl
new file mode 100644
index 0000000000..d7a66d96ac
--- /dev/null
+++ b/src/lib/libcrypto/util/dirname.pl
@@ -0,0 +1,18 @@
1#!/usr/local/bin/perl
2
3if ($#ARGV < 0) {
4 die "dirname.pl: too few arguments\n";
5} elsif ($#ARGV > 0) {
6 die "dirname.pl: too many arguments\n";
7}
8
9my $d = $ARGV[0];
10
11if ($d =~ m|.*/.*|) {
12 $d =~ s|/[^/]*$||;
13} else {
14 $d = ".";
15}
16
17print $d,"\n";
18exit(0);
diff --git a/src/lib/libcrypto/util/pod2mantest b/src/lib/libcrypto/util/pod2mantest
index 79aefafac0..e01c6192a7 100644
--- a/src/lib/libcrypto/util/pod2mantest
+++ b/src/lib/libcrypto/util/pod2mantest
@@ -11,9 +11,10 @@
11 11
12 12
13IFS=: 13IFS=:
14try_without_dir=true 14if test "$OSTYPE" = "msdosdjgpp"; then IFS=";"; fi
15try_without_dir=false
15# First we try "pod2man", then "$dir/pod2man" for each item in $PATH. 16# First we try "pod2man", then "$dir/pod2man" for each item in $PATH.
16for dir in dummy:$PATH; do 17for dir in dummy${IFS}$PATH; do
17 if [ "$try_without_dir" = true ]; then 18 if [ "$try_without_dir" = true ]; then
18 # first iteration 19 # first iteration
19 pod2man=pod2man 20 pod2man=pod2man
@@ -47,7 +48,7 @@ done
47echo "No working pod2man found. Consider installing a new version." >&2 48echo "No working pod2man found. Consider installing a new version." >&2
48if [ "$1" = ignore ]; then 49if [ "$1" = ignore ]; then
49 echo "As a workaround, we'll use a bundled old copy of pod2man.pl." >&2 50 echo "As a workaround, we'll use a bundled old copy of pod2man.pl." >&2
50 echo "util/pod2man.pl" 51 echo "../../util/pod2man.pl"
51 exit 0 52 exit 0
52fi 53fi
53exit 1 54exit 1