1 ?RCS: $Id: errnolist.U,v 3.0.1.2 1997/02/28 15:48:01 ram Exp $
3 ?RCS: Copyright (c) 1991-1993, Raphael Manfredi
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.
11 ?RCS: $Log: errnolist.U,v $
12 ?RCS: Revision 3.0.1.2 1997/02/28 15:48:01 ram
13 ?RCS: patch61: replaced .a with $_a all over the place
14 ?RCS: patch61: likewise for .o replaced by $_o
16 ?RCS: Revision 3.0.1.1 1994/01/24 14:10:54 ram
17 ?RCS: patch16: created
19 ?MAKE:errnolist errnolist_SH errnolist_a errnolist_c errnolist_o: cat \
20 Compile +d_sysernlst _a _o
21 ?MAKE: -pick add $@ %<
23 ?S: This variable holds the base name of a file containing the
24 ?S: definition of the sys_errnolist array, if the C library
25 ?S: doesn't provide it already. Otherwise, its value is empty.
26 ?S: The following lines should be included in your Makefile.SH:
28 ?S: case "$errnolist" in
31 ?S: $spitshell >>Makefile <<!GROK!THIS!
32 ?S: $errnolist_c: $errnolist_SH $errnolist_a
33 ?S: sh ./$errnolist_SH
39 ?S: You may define the 'errnolist' variable in your Myinit.U if you
40 ?S: wish to override its default value "errnolist".
43 ?S: This is the name of a file which will generate errnolistc.
46 ?S: This is the name of the awk script called by errnolist_SH.
49 ?S: This is the name of a generated C file which provides the
50 ?S: definition of the sys_errnolist array.
53 ?S: This is the name of the object file which provides the
54 ?S: definition of the sys_errnolist array, if the C library
55 ?S: doesn't provide it already. Otherwise, its value is empty.
57 ?INIT:errnolist=errnolist
58 : check for sys_errnolist
59 @if d_sysernlst || HAS_SYS_ERRNOLIST
60 case "$d_sysernlst" in
70 echo "I'll make sure your Makefile provides sys_errnolist in $errnolist.c"
71 errnolist_SH=$errnolist.SH
72 errnolist_a=$errnolist$_a
73 errnolist_c=$errnolist.c
74 errnolist_o=$errnolist$_o
80 Checking to see if your C library provides us with sys_errnolist[]...
82 $cat >errnolist.c <<'EOCP'
83 extern char *sys_errnolist[];
85 char *p0 = sys_errnolist[0];
86 char *p1 = sys_errnolist[1];
88 return (p0 == p1); /* Make sure they're not optimized away */
92 if eval $compile; then
100 echo "I'll make sure your Makefile provides sys_errnolist in $errnolist.c"
101 errnolist_SH=$errnolist.SH
102 errnolist_a=$errnolist$_a
103 errnolist_c=$errnolist.c
104 errnolist_o=$errnolist$_o