1 /* @(#)xconfig.h	1.13 13/07/23 Copyright 1995-2013 J. Schilling */
2 /*
3  *	This file either includes the dynamic or manual autoconf stuff.
4  *
5  *	Copyright (c) 1995-2013 J. Schilling
6  *
7  *	This file is included from <schily/mconfig.h> and usually
8  *	includes $(SRCROOT)/incs/$(OARCH)/xconfig.h via
9  *	-I$(SRCROOT)/incs/$(OARCH)/
10  *
11  *	Use only cpp instructions.
12  *
13  *	NOTE: SING: (Schily Is Not Gnu)
14  */
15 /*
16  * The contents of this file are subject to the terms of the
17  * Common Development and Distribution License, Version 1.0 only
18  * (the "License").  You may not use this file except in compliance
19  * with the License.
20  *
21  * See the file CDDL.Schily.txt in this distribution for details.
22  * A copy of the CDDL is also available via the Internet at
23  * http://www.opensource.org/licenses/cddl1.txt
24  *
25  * When distributing Covered Code, include this CDDL HEADER in each
26  * file and include the License file CDDL.Schily.txt from this distribution.
27  */
28 
29 #ifndef _SCHILY_XCONFIG_H
30 #define	_SCHILY_XCONFIG_H
31 
32 /*
33  * This hack that is needed as long as VMS has no POSIX shell.
34  * It will go away soon. VMS users: in future you need to specify:
35  * cc -DUSE_STATIC_CONF
36  */
37 #ifdef	VMS
38 #	define	USE_STATIC_CONF
39 #endif
40 
41 #ifdef	NO_STATIC_CONF
42 #undef	USE_STATIC_CONF
43 #endif
44 
45 #ifdef	USE_STATIC_CONF
46 #	include <schily/xmconfig.h>	/* The static autoconf stuff */
47 #else	/* USE_STATIC_CONF */
48 
49 
50 #ifdef	SCHILY_BUILD	/* #defined by Schily makefile system */
51 	/*
52 	 * Include $(SRCROOT)/incs/$(OARCH)/xconfig.h via
53 	 * -I$(SRCROOT)/incs/$(OARCH)/
54 	 */
55 #	include <xconfig.h>	/* The current dynamic autoconf stuff */
56 #else	/* !SCHILY_BUILD */
57 /*
58  * The stuff for static compilation. Include files from a previous
59  * dynamic autoconfiguration.
60  */
61 #ifdef	__SUNOS5_SPARC_CC32
62 #include <schily/sparc-sunos5-cc/xconfig.h>
63 #define	__JS_ARCH_CONF_INCL
64 #endif
65 #ifdef	__SUNOS5_SPARC_CC64
66 #include <schily/sparc-sunos5-cc64/xconfig.h>
67 #define	__JS_ARCH_CONF_INCL
68 #endif
69 #ifdef	__SUNOS5_SPARC_GCC32
70 #include <schily/sparc-sunos5-gcc/xconfig.h>
71 #define	__JS_ARCH_CONF_INCL
72 #endif
73 #ifdef	__SUNOS5_SPARC_GCC64
74 #include <schily/sparc-sunos5-gcc64/xconfig.h>
75 #define	__JS_ARCH_CONF_INCL
76 #endif
77 #ifdef	__SUNOS5_X86_CC32
78 #include <schily/i386-sunos5-cc/xconfig.h>
79 #define	__JS_ARCH_CONF_INCL
80 #endif
81 #ifdef	__SUNOS5_X86_CC64
82 #include <schily/i386-sunos5-cc64/xconfig.h>
83 #define	__JS_ARCH_CONF_INCL
84 #endif
85 #ifdef	__SUNOS5_X86_GCC32
86 #include <schily/i386-sunos5-gcc/xconfig.h>
87 #define	__JS_ARCH_CONF_INCL
88 #endif
89 #ifdef	__SUNOS5_X86_GCC64
90 #include <schily/i386-sunos5-gcc64/xconfig.h>
91 #define	__JS_ARCH_CONF_INCL
92 #endif
93 
94 #ifdef	__SUNOS4_MC68000_CC32
95 #ifdef	__mc68020
96 #include <schily/mc68020-sunos4-cc/xconfig.h>
97 #define	__JS_ARCH_CONF_INCL
98 #endif
99 #endif
100 #ifdef	__SUNOS4_MC68000_GCC32
101 #ifdef	__mc68020
102 #include <schily/mc68020-sunos4-gcc/xconfig.h>
103 #define	__JS_ARCH_CONF_INCL
104 #endif
105 #endif
106 
107 #ifdef	__HPUX_HPPA_CC32
108 #include <schily/hppa-hp-ux-cc/xconfig.h>
109 #define	__JS_ARCH_CONF_INCL
110 #endif
111 #ifdef	__HPUX_HPPA_CC64
112 #include <schily/hppa-hp-ux-cc64/xconfig.h>
113 #define	__JS_ARCH_CONF_INCL
114 #endif
115 #ifdef	__HPUX_HPPA_GCC32
116 #include <schily/hppa-hp-ux-gcc/xconfig.h>
117 #define	__JS_ARCH_CONF_INCL
118 #endif
119 #ifdef	__HPUX_HPPA_GCC64
120 #include <schily/hppa-hp-ux-gcc64/xconfig.h>
121 #define	__JS_ARCH_CONF_INCL
122 #endif
123 
124 #ifdef	__LINUX_ARMV6L_GCC32
125 #include <schily/armv6l-linux-gcc/xconfig.h>
126 #define	__JS_ARCH_CONF_INCL
127 #endif
128 #ifdef	__LINUX_ARMV5L_GCC32
129 #include <schily/armv6l-linux-gcc/xconfig.h>
130 #define	__JS_ARCH_CONF_INCL
131 #endif
132 #ifdef	__LINUX_ARMV5TEJL_GCC32
133 #include <schily/armv5tejl-linux-gcc/xconfig.h>
134 #define	__JS_ARCH_CONF_INCL
135 #endif
136 #ifdef	__LINUX_I386_GCC32
137 #include <schily/i686-linux-gcc/xconfig.h>
138 #define	__JS_ARCH_CONF_INCL
139 #endif
140 #ifdef	__LINUX_amd64_GCC64
141 #include <schily/x86_64-linux-gcc/xconfig.h>
142 #define	__JS_ARCH_CONF_INCL
143 #endif
144 
145 #ifdef	__MSWIN_X86_CL32
146 #include <schily/i686-cygwin32_nt-cl/xconfig.h>
147 #define	__JS_ARCH_CONF_INCL
148 #endif
149 
150 #ifdef	__CYGWIN_X86_GCC
151 #include <schily/i686-cygwin32_nt-gcc/xconfig.h>
152 #define	__JS_ARCH_CONF_INCL
153 #endif
154 
155 #ifndef	__JS_ARCH_CONF_INCL
156 /*
157  * #error will not work for all compilers (e.g. sunos4)
158  * The following line will abort compilation on all compilers
159  * if none of the above is defined. And that's  what we want.
160  */
161 Error unconfigured architecture
162 
163 #include <schily/err_arch.h>	/* Avoid "unknown directive" with K&R */
164 #endif
165 
166 #endif	/* SCHILY_BUILD */
167 
168 #endif	/* USE_STATIC_CONF */
169 
170 #ifdef	__cplusplus
171 extern "C" {
172 #endif
173 /*
174  * Fake in order to keep the silly hdrchk(1) quiet.
175  */
176 #ifdef	__cplusplus
177 }
178 #endif
179 
180 #endif /* _SCHILY_XCONFIG_H */
181