This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
/\=/ does not require \ even in older awk
[metaconfig.git] / U / installdirs / vendorlib.U
1 ?RCS: $Id: vendorlib.U,v 1.1 1999/07/08 18:32:57 doughera Exp doughera $
2 ?RCS:
3 ?RCS: Copyright (c) 1999, Andy Dougherty
4 ?RCS:
5 ?RCS: You may redistribute only under the terms of the Artistic License,
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 License; 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: vendorlib.U,v $
12 ?RCS: Revision 1.1  1999/07/08 18:32:57  doughera
13 ?RCS: Initial revision
14 ?RCS:
15 ?MAKE:d_vendorlib vendorlib vendorlibexp installvendorlib vendorlib_stem: \
16         Getfile Setprefixvar Oldconfig Prefixit package vendorprefix sed \
17         installstyle version
18 ?MAKE:  -pick add $@ %<
19 ?Y:TOP
20 ?S:vendorlib:
21 ?S:     This variable contains the eventual value of the VENDORLIB symbol,
22 ?S:     which is the name of the private library for this package.
23 ?S:     The standard distribution will put nothing in this directory.
24 ?S:     Vendors who distribute perl may wish to place their own
25 ?S:     modules in this directory with
26 ?S:             MakeMaker Makefile.PL INSTALLDIRS=vendor
27 ?S:     or equivalent.  See INSTALL for details.
28 ?S:.
29 ?S:vendorlibexp:
30 ?S:     This variable is the ~name expanded version of vendorlib, so that you
31 ?S:     may use it directly in Makefiles or shell scripts.
32 ?S:.
33 ?D:installvendorlib=''
34 ?S:installvendorlib:
35 ?S:     This variable is really the same as vendorlibexp but may differ on
36 ?S:     those systems using AFS. For extra portability, only this variable
37 ?S:     should be used in makefiles.
38 ?S:.
39 ?S:d_vendorlib:
40 ?S:     This variable conditionally defines PERL_VENDORLIB.
41 ?S:.
42 ?S:vendorlib_stem:
43 ?S:     This variable is $vendorlibexp with any trailing version-specific component
44 ?S:     removed.  The elements in inc_version_list (inc_version_list.U) can
45 ?S:     be tacked onto this variable to generate a list of directories to search.
46 ?S:.
47 ?C:PERL_VENDORLIB:
48 ?C:     If defined, this symbol contains the name of a private library.
49 ?C:     The library is private in the sense that it needn't be in anyone's
50 ?C:     execution path, but it should be accessible by the world.  The program
51 ?C:     should be prepared to do ~ expansion.
52 ?C:     The standard distribution will put nothing in this directory.
53 ?C:     Vendors who distribute perl may wish to place their own
54 ?C:     modules in this directory with
55 ?C:             MakeMaker Makefile.PL INSTALLDIRS=vendor
56 ?C:     or equivalent.  See INSTALL for details.
57 ?C:.
58 ?C:PERL_VENDORLIB_EXP:
59 ?C:     This symbol contains the ~name expanded version of VENDORLIB, to be used
60 ?C:     in programs that are not prepared to deal with ~ expansion at run-time.
61 ?C:.
62 ?C:PERL_VENDORLIB_STEM:
63 ?C:     This define is PERL_VENDORLIB_EXP with any trailing version-specific component
64 ?C:     removed.  The elements in inc_version_list (inc_version_list.U) can
65 ?C:     be tacked onto this variable to generate a list of directories to search.
66 ?C:.
67 ?H:#$d_vendorlib PERL_VENDORLIB "$vendorlib"            /**/
68 ?H:#$d_vendorlib PERL_VENDORLIB_EXP "$vendorlibexp"             /**/
69 ?H:#$d_vendorlib PERL_VENDORLIB_STEM "$vendorlib_stem"          /**/
70 ?H:.
71 ?T:prog
72 ?LINT:change prefixvar
73 ?LINT:set installvendorlib
74 : Set the vendorlib variables
75 case "$vendorprefix" in
76 '')     d_vendorlib="$undef"
77         vendorlib=''
78         vendorlibexp=''
79         ;;
80 *)      d_vendorlib="$define"
81         : determine where vendor-supplied modules go.
82         : Usual default is /usr/local/lib/perl5/vendor_perl/$version
83         case "$vendorlib" in
84         '')
85 ?X:             remove any trailing -3.0 or other version identification
86                 prog=`echo $package | $sed 's/-*[0-9.]*$//'`
87                 case "$installstyle" in
88                 *lib/perl5*) dflt=$vendorprefix/lib/$package/vendor_$prog/$version ;;
89                 *)           dflt=$vendorprefix/lib/vendor_$prog/$version ;;
90                 esac
91                 ;;
92         *)      dflt="$vendorlib"
93                 ;;
94         esac
95         fn=d~+
96         rp='Pathname for the vendor-supplied library files?'
97         . ./getfile
98         vendorlib="$ans"
99         vendorlibexp="$ansexp"
100         ;;
101 esac
102 vendorlib_stem=`echo "$vendorlibexp" | sed "s,/$version$,,"`
103 prefixvar=vendorlib
104 . ./installprefix
105