?RCS: $Id$ ?RCS: ?RCS: Copyright (c) 1991-1997, 2004-2006, Raphael Manfredi ?RCS: ?RCS: You may redistribute only under the terms of the Artistic Licence, ?RCS: as specified in the README file that comes with the distribution. ?RCS: You may reuse parts of this distribution only within the terms of ?RCS: that same Artistic Licence; a copy of which may be found at the root ?RCS: of the source tree for dist 4.0. ?RCS: ?RCS: $Log: errnolist.U,v $ ?RCS: Revision 3.0.1.2 1997/02/28 15:48:01 ram ?RCS: patch61: replaced .a with $_a all over the place ?RCS: patch61: likewise for .o replaced by $_o ?RCS: ?RCS: Revision 3.0.1.1 1994/01/24 14:10:54 ram ?RCS: patch16: created ?RCS: ?MAKE:errnolist errnolist_SH errnolist_a errnolist_c errnolist_o: cat +cc \ +ccflags +libs +d_sysernlst _a _o ?MAKE: -pick add $@ %< ?S:errnolist: ?S: This variable holds the base name of a file containing the ?S: definition of the sys_errnolist array, if the C library ?S: doesn't provide it already. Otherwise, its value is empty. ?S: The following lines should be included in your Makefile.SH: ?S: ?S: case "$errnolist" in ?S: '') ;; ?S: *) ?S: $spitshell >>Makefile <errnolist.c <<'EOCP' extern char *sys_errnolist[]; int main() { char *p0 = sys_errnolist[0]; char *p1 = sys_errnolist[1]; return (p0 == p1); /* Make sure they're not optimized away */ } EOCP if $cc $ccflags -o errnolist errnolist.c $libs >/dev/null 2>&1 ; then echo "It does." errnolist='' errnolist_SH='' errnolist_a='' errnolist_c='' errnolist_o='' else echo "I'll make sure your Makefile provides sys_errnolist in $errnolist.c" errnolist_SH=$errnolist.SH errnolist_a=$errnolist$_a errnolist_c=$errnolist.c errnolist_o=$errnolist$_o fi @end