This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Megalopatch for Configure: Andy's new installation schemes;
[metaconfig.git] / U / installdirs / sitescript.U
CommitLineData
0fdea05a
JH
1?RCS: $Id: sitescript.U,v $
2?RCS:
3?RCS: Copyright (c) 1999 Andy Dougherty
4?RCS:
5?RCS: You may redistribute only under the terms of the Artistic Licence,
6?RCS: as specified in the README file that comes with the distribution.
7?RCS: You may reuse parts of this distribution only within the terms of
8?RCS: that same Artistic Licence; a copy of which may be found at the root
9?RCS: of the source tree for dist 3.0.
10?RCS:
11?RCS: $Log: sitescript.U,v $
12?RCS:
13?MAKE:sitescript sitescriptexp installsitescript : Getfile Oldconfig test \
14 sitebin prefix siteprefix sed installprefix
15?MAKE: -pick add $@ %<
16?Y:TOP
17?S:sitescript:
18?S: This variable holds the name of the directory in which the user wants
19?S: to put add-on publicly executable files for the package in question. It
20?S: is most often a local directory such as /usr/local/bin. Programs using
21?S: this variable must be prepared to deal with ~name substitution.
22?S: The standard distribution will put nothing in this directory.
23?S: After perl has been installed, users may install their own local
24?S: scripts in this directory with
25?S: MakeMaker Makefile.PL
26?S: or equivalent. See INSTALL for details.
27?S:.
28?S:sitescriptexp:
29?S: This is the same as the sitescript variable, but is filename expanded at
30?S: configuration time, for use in your makefiles.
31?S:.
32?S:installsitescript:
33?S: This variable is usually the same as sitescriptexp, unless you are on
34?S: a system running AFS, in which case they may differ slightly. You
35?S: should always use this variable within your makefiles for portability.
36?S:.
37: determine where add-on public executable scripts go
38case "$sitescript" in
39'') dflt=$siteprefix/script
40 $test -d $dflt || dflt=$sitebin ;;
41*) dflt="$sitescript" ;;
42esac
43fn=d~+
44rp='Pathname where add-on public executable scripts should be installed?'
45. ./getfile
46sitescript="$ans"
47sitescriptexp="$ansexp"
48: Change installation prefix, if necessary.
49if $test X"$prefix" != X"$installprefix"; then
50 installsitescript=`echo $sitescriptexp | sed "s#^$prefix#$installprefix#"`
51else
52 installsitescript="$sitescriptexp"
53fi
54