1 /* Copyright (C) 2001-2012 Artifex Software, Inc. 2 All Rights Reserved. 3 4 This software is provided AS-IS with no warranty, either express or 5 implied. 6 7 This software is distributed under license and may not be copied, 8 modified or distributed except as expressly authorized under the terms 9 of the license contained in the file LICENSE in this distribution. 10 11 Refer to licensing information at http://www.artifex.com or contact 12 Artifex Software, Inc., 7 Mt. Lassen Drive - Suite A-134, San Rafael, 13 CA 94903, U.S.A., +1(415)492-9861, for further information. 14 */ 15 16 /* Generic substitute for Unix errno.h */ 17 18 #ifndef errno__INCLUDED 19 # define errno__INCLUDED 20 21 /* We must include std.h before any file that includes sys/types.h. */ 22 #include "std.h" 23 24 /* All environments provide errno.h, but in some of them, errno.h */ 25 /* only defines the error numbers, and doesn't declare errno. */ 26 #include <errno.h> 27 #ifndef errno /* in case it was #defined (very implausible!) */ 28 extern int errno; 29 #endif 30 31 /* Some systems don't have EILSEQ, so (following GNU iconv) we use */ 32 /* ENOENT instead if necessary. */ 33 #ifndef EILSEQ 34 # define EILSEQ ENOENT 35 #endif 36 37 #endif /* errno__INCLUDED */ 38