Commit | Line | Data |
---|---|---|
959f3c4c JH |
1 | ?RCS: $Id: archlib.U,v 3.0.1.5 1997/02/28 15:23:38 ram Exp $ |
2 | ?RCS: | |
3 | ?RCS: Copyright (c) 1991-1993, Raphael Manfredi | |
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: Original Author: Andy Dougherty <doughera@lafcol.lafayette.edu> | |
12 | ?RCS: | |
13 | ?RCS: $Log: archlib.U,v $ | |
14 | ?RCS: Revision 3.0.1.5 1997/02/28 15:23:38 ram | |
15 | ?RCS: patch61: skip existence checks for archlib | |
16 | ?RCS: | |
17 | ?RCS: Revision 3.0.1.4 1995/09/25 09:15:18 ram | |
18 | ?RCS: patch59: unit is now forced to the top of Configure, if possible | |
19 | ?RCS: | |
20 | ?RCS: Revision 3.0.1.3 1995/02/15 14:14:14 ram | |
21 | ?RCS: patch51: architecture name is now computed by a separate unit | |
22 | ?RCS: | |
23 | ?RCS: Revision 3.0.1.2 1995/01/30 14:32:22 ram | |
24 | ?RCS: patch49: archname is now systematically recomputed | |
25 | ?RCS: patch49: can now handle installation prefix changes (from WED) | |
26 | ?RCS: | |
27 | ?RCS: Revision 3.0.1.1 1994/10/29 16:02:36 ram | |
28 | ?RCS: patch36: created by ADO | |
29 | ?RCS: | |
30 | ?MAKE:d_archlib archlib archlibexp installarchlib: archname afs spackage \ | |
31 | cat Getfile Loc Oldconfig prefixexp privlib test Prefixit Prefixup | |
32 | ?MAKE: -pick add $@ %< | |
33 | ?Y:TOP | |
34 | ?S:d_archlib: | |
35 | ?S: This variable conditionally defines ARCHLIB to hold the pathname | |
36 | ?S: of architecture-dependent library files for $package. If | |
37 | ?S: $archlib is the same as $privlib, then this is set to undef. | |
38 | ?S:. | |
39 | ?S:archlib: | |
40 | ?S: This variable holds the name of the directory in which the user wants | |
41 | ?S: to put architecture-dependent public library files for $package. | |
42 | ?S: It is most often a local directory such as /usr/local/lib. | |
43 | ?S: Programs using this variable must be prepared to deal | |
44 | ?S: with filename expansion. | |
45 | ?S:. | |
46 | ?S:archlibexp: | |
47 | ?S: This variable is the same as the archlib variable, but is | |
48 | ?S: filename expanded at configuration time, for convenient use. | |
49 | ?S:. | |
50 | ?S:installarchlib: | |
51 | ?S: This variable is really the same as archlibexp but may differ on | |
52 | ?S: those systems using AFS. For extra portability, only this variable | |
53 | ?S: should be used in makefiles. | |
54 | ?S:. | |
55 | ?C:ARCHLIB: | |
56 | ?C: This variable, if defined, holds the name of the directory in | |
57 | ?C: which the user wants to put architecture-dependent public | |
58 | ?C: library files for $package. It is most often a local directory | |
59 | ?C: such as /usr/local/lib. Programs using this variable must be | |
60 | ?C: prepared to deal with filename expansion. If ARCHLIB is the | |
61 | ?C: same as PRIVLIB, it is not defined, since presumably the | |
62 | ?C: program already searches PRIVLIB. | |
63 | ?C:. | |
64 | ?C:ARCHLIB_EXP: | |
65 | ?C: This symbol contains the ~name expanded version of ARCHLIB, to be used | |
66 | ?C: in programs that are not prepared to deal with ~ expansion at run-time. | |
67 | ?C:. | |
68 | ?H:#$d_archlib ARCHLIB "$archlib" /**/ | |
69 | ?H:#$d_archlib ARCHLIB_EXP "$archlibexp" /**/ | |
70 | ?H:. | |
71 | : determine where public architecture dependent libraries go | |
72 | set archlib archlib | |
73 | eval $prefixit | |
74 | case "$archlib" in | |
75 | '') | |
76 | case "$privlib" in | |
77 | '') | |
78 | dflt=`./loc . "." $prefixexp/lib /usr/local/lib /usr/lib /lib` | |
79 | set dflt | |
80 | eval $prefixup | |
81 | ;; | |
82 | *) dflt="$privlib/$archname";; | |
83 | esac | |
84 | ;; | |
85 | *) dflt="$archlib";; | |
86 | esac | |
87 | cat <<EOM | |
88 | ||
89 | $spackage contains architecture-dependent library files. If you are | |
90 | sharing libraries in a heterogeneous environment, you might store | |
91 | these files in a separate location. Otherwise, you can just include | |
92 | them with the rest of the public library files. | |
93 | ||
94 | EOM | |
95 | fn=d+~ | |
96 | rp='Where do you want to put the public architecture-dependent libraries?' | |
97 | . ./getfile | |
98 | archlib="$ans" | |
99 | archlibexp="$ansexp" | |
100 | ||
101 | if $afs; then | |
102 | $cat <<EOM | |
103 | ||
104 | Since you are running AFS, I need to distinguish the directory in which | |
105 | private files reside from the directory in which they are installed (and from | |
106 | which they are presumably copied to the former directory by occult means). | |
107 | ||
108 | EOM | |
109 | case "$installarchlib" in | |
110 | '') dflt=`echo $archlibexp | sed 's#^/afs/#/afs/.#'`;; | |
111 | *) dflt="$installarchlib";; | |
112 | esac | |
113 | fn=de~ | |
114 | rp='Where will architecture-dependent library files be installed?' | |
115 | . ./getfile | |
116 | installarchlib="$ans" | |
117 | else | |
118 | installarchlib="$archlibexp" | |
119 | fi | |
120 | if $test X"$archlib" = X"$privlib"; then | |
121 | d_archlib="$undef" | |
122 | else | |
123 | d_archlib="$define" | |
124 | fi | |
125 |