Commit | Line | Data |
---|---|---|
33a01fd2 | 1 | ?RCS: $Id$ |
d8875586 MBT |
2 | ?RCS: |
3 | ?RCS: Copyright (c) 1991-1997, 2004-2006, Raphael Manfredi | |
33a01fd2 MBT |
4 | ?RCS: |
5 | ?RCS: You may redistribute only under the terms of the Artistic License, | |
d8875586 MBT |
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 | |
33a01fd2 | 8 | ?RCS: that same Artistic License; a copy of which may be found at the root |
d8875586 MBT |
9 | ?RCS: of the source tree for dist 4.0. |
10 | ?RCS: | |
11 | ?RCS: $Log: d_csh.U,v $ | |
12 | ?RCS: Revision 3.0.1.1 1997/02/28 15:32:18 ram | |
13 | ?RCS: patch61: added full_csh to preserve the full path even when portable | |
14 | ?RCS: | |
15 | ?RCS: Revision 3.0 1993/08/18 12:05:53 ram | |
16 | ?RCS: Baseline for dist 3.0 netwide release. | |
17 | ?RCS: | |
18 | ?MAKE:d_csh full_csh: csh Setvar | |
19 | ?MAKE: -pick add $@ %< | |
20 | ?S:d_csh: | |
21 | ?S: This variable conditionally defines the CSH symbol, which | |
22 | ?S: indicates to the C program that the C-shell exists. | |
23 | ?S:. | |
24 | ?S:full_csh: | |
25 | ?S: This variable contains the full pathname to 'csh', whether or | |
26 | ?S: not the user has specified 'portability'. This is only used | |
27 | ?S: in the compiled C program, and we assume that all systems which | |
28 | ?S: can share this executable will have the same full pathname to | |
29 | ?S: 'csh.' | |
30 | ?S:. | |
31 | ?C:HAS_CSH: | |
32 | ?C: This symbol, if defined, indicates that the C-shell exists. | |
33 | ?C:. | |
34 | ?C:CSH: | |
35 | ?C: This symbol, if defined, contains the full pathname of csh. | |
36 | ?C:. | |
37 | ?X: Previously, I just did $d_csh CSH "$full_csh", but that caused | |
38 | ?X: problems on VMS where the config.sh extraction program changes | |
39 | ?X: $undef to a real cpp undef, and they then had #undef CSH "" | |
40 | ?X: which the compiler didn't like. It's easy to work around this, | |
41 | ?X: so I did. --AD 3/1998. | |
42 | ?X: And we don't want to define CSH if !HAS_CSH, but we don't want | |
43 | ?X: those lines in config.h if they don't need CSH, so protect with ?CSH | |
44 | ?X: and not ?%<. --RAM, 15/02/2004 | |
45 | ?H:?%<:#$d_csh HAS_CSH /**/ | |
46 | ?H:?CSH:#ifdef HAS_CSH | |
47 | ?H:?CSH:#define CSH "$full_csh" /**/ | |
48 | ?H:?CSH:#endif | |
49 | ?H:. | |
50 | ?LINT:set d_csh | |
51 | : get csh whereabouts | |
52 | case "$csh" in | |
53 | 'csh') val="$undef" ;; | |
54 | *) val="$define" ;; | |
55 | esac | |
56 | set d_csh | |
57 | eval $setvar | |
58 | : Respect a hint or command line value for full_csh. | |
59 | case "$full_csh" in | |
60 | '') full_csh=$csh ;; | |
61 | esac | |
62 |