1#!/bin/sh
2#
3# This script is included in this distribution for the benefit
4# of those users who cannot use MakeMaker and make to install.
5# Run this script with
6# 
7#   perl install-nomake [-s <directory>]
8# 
9#   -s Install into this directory instead of the system site_lib
10#      (This directory must already exist)
11# 
12
13eval 'exec perl -x -S $0 ${1+"$@"}'
14  if $running_under_some_shell;
15
16#! -*- perl -*-
17
18use Config;
19use File::Spec;
20use Getopt::Long;
21use ExtUtils::Install qw(install);
22
23my $sitelib = $Config{'sitelibexp'};
24
25GetOptions(
26  'sitelib=s' => \$sitelib
27);
28
29die "$sitelib is not a directory: $!"
30  unless -d $sitelib;
31
32my $src = File::Spec->catdir(File::Spec->curdir, 'lib');
33
34die "This script must be run from the perl-ldap distribution directory: $!\n"
35  unless -f File::Spec->catfile($src, qw(Net LDAP.pm));
36
37install( { $src => $sitelib }, 1,0,0);
38