Add rendercheck 1.4 to x11-apps.
Robert Hooker
11 years ago
68 | 68 | - atobm, bitmap, and bmtoa, tools for manipulating bitmap images; |
69 | 69 | - ico, a demo program animating polyhedrons; |
70 | 70 | - oclock and xclock, graphical clocks; |
71 | - rendercheck, a program to test render extension implementations; | |
71 | 72 | - transset, a tool to set opacity property on a window; |
72 | 73 | - xbiff, a tool which tells you when you have new email; |
73 | 74 | - xcalc, a scientific calculator desktop accessory; |
141 | 141 | be used in advertising or otherwise to promote the sale, use or other deal- |
142 | 142 | ings in this Software without prior written authorization from the X Consor- |
143 | 143 | ium. |
144 | ||
145 | rendercheck: | |
146 | Copyright 2004 Eric Anholt | |
147 | ||
148 | Permission to use, copy, modify, distribute, and sell this software and its | |
149 | documentation for any purpose is hereby granted without fee, provided that | |
150 | the above copyright notice appear in all copies and that both that | |
151 | copyright notice and this permission notice appear in supporting | |
152 | documentation, and that the name of Eric Anholt not be used in | |
153 | advertising or publicity pertaining to distribution of the software without | |
154 | specific, written prior permission. Eric Anholt makes no | |
155 | representations about the suitability of this software for any purpose. It | |
156 | is provided "as is" without express or implied warranty. | |
157 | ||
158 | ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
159 | INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
160 | EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
161 | CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
162 | DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
163 | TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
164 | PERFORMANCE OF THIS SOFTWARE. | |
144 | 165 | |
145 | 166 | transset: |
146 | 167 | Copyright © 2003-2004 Matthew Hawn |
13 | 13 | |
14 | 14 | # This package contains multiple modules as shipped by upstream. Each module is # contained in a subdirectory in the root dir of the package. You must list each |
15 | 15 | # subdirectory explicitly so that the build system knows what to build |
16 | DEF_SUBDIRS=bitmap ico oclock transset x11perf xbiff xcalc xclipboard xclock xconsole xcursorgen xditview xedit xeyes xgc xload xlogo xmag xman xmore xwd xwud | |
16 | DEF_SUBDIRS=bitmap ico oclock rendercheck transset x11perf xbiff xcalc xclipboard xclock xconsole xcursorgen xditview xedit xeyes xgc xload xlogo xmag xman xmore xwd xwud | |
17 | 17 | SUBDIRS=$(DEF_SUBDIRS) |
18 | 18 | BUILD_STAMPS = $(addprefix $(STAMP_DIR)/build-,$(SUBDIRS)) |
19 | 19 |
0 | # Compulsory line, this is a version 3 file | |
1 | version=3 | |
2 | http://xorg.freedesktop.org/archive/individual/app/rendercheck-(.*)\.tar\.gz |
0 | Copyright 2004 Eric Anholt | |
1 | ||
2 | Permission to use, copy, modify, distribute, and sell this software and its | |
3 | documentation for any purpose is hereby granted without fee, provided that | |
4 | the above copyright notice appear in all copies and that both that | |
5 | copyright notice and this permission notice appear in supporting | |
6 | documentation, and that the name of Eric Anholt not be used in | |
7 | advertising or publicity pertaining to distribution of the software without | |
8 | specific, written prior permission. Eric Anholt makes no | |
9 | representations about the suitability of this software for any purpose. It | |
10 | is provided "as is" without express or implied warranty. | |
11 | ||
12 | ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
13 | INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
14 | EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
15 | CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
16 | DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
17 | TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
18 | PERFORMANCE OF THIS SOFTWARE. |
0 | commit 16d7e5c3052f8c4e9df77f889f935ed8b8f8b326 | |
1 | Author: Alan Coopersmith <alan.coopersmith@oracle.com> | |
2 | Date: Sun Nov 21 18:55:18 2010 -0800 | |
3 | ||
4 | rendercheck 1.4 | |
5 | ||
6 | Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> | |
7 | ||
8 | commit 03e284e42edbec2a184e0373b0d86bdfbc109b32 | |
9 | Author: Alan Coopersmith <alan.coopersmith@oracle.com> | |
10 | Date: Sat Oct 30 13:47:22 2010 -0700 | |
11 | ||
12 | config: Remove unnecessary calls from configure.ac | |
13 | ||
14 | AC_PROG_CC & AC_PROG_SED are provided by XORG_DEFAULT_OPTIONS now | |
15 | PKG_CONFIG_MODULES handles AC_SUBST of the CFLAGS & LIBS variables | |
16 | XORG_DEFAULT_OPTIONS includes XORG_STRICT_OPTION to set -Werror | |
17 | ||
18 | Assume systems have xrender.pc now - those building on older systems | |
19 | can set RC_LIBS="-lXrender -lXext -lX11" plus any -I/-L/-R flags they | |
20 | need in RC_CFLAGS & RC_LIBS. | |
21 | ||
22 | Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> | |
23 | ||
24 | commit db39192719bb4474264a6cc66d0a264468b56f05 | |
25 | Author: Alan Coopersmith <alan.coopersmith@oracle.com> | |
26 | Date: Sat Oct 30 13:43:30 2010 -0700 | |
27 | ||
28 | Sun's copyrights now belong to Oracle | |
29 | ||
30 | Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> | |
31 | ||
32 | commit 6e16e632cfd0528b0934aaadb6ef5f239e61aa9e | |
33 | Author: Gaetan Nadon <memsize@videotron.ca> | |
34 | Date: Sat Oct 30 13:41:51 2010 -0700 | |
35 | ||
36 | config: update AC_PREREQ statement to 2.60 | |
37 | ||
38 | Unrelated to the previous patches, the new value simply reflects | |
39 | the reality that the minimum level for autoconf to configure | |
40 | all x.org modules is 2.60 dated June 2006. | |
41 | ||
42 | ftp://ftp.gnu.org/gnu/autoconf/autoconf-2.60.tar.gz | |
43 | ||
44 | Signed-off-by: Gaetan Nadon <memsize@videotron.ca> | |
45 | Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> | |
46 | ||
47 | commit e581769b5152ff8e8fdf745b66eb81479a380c32 | |
48 | Author: Alan Coopersmith <alan.coopersmith@oracle.com> | |
49 | Date: Sat Oct 30 13:41:22 2010 -0700 | |
50 | ||
51 | config: upgrade to util-macros 1.8 for additional man page support | |
52 | ||
53 | Use MAN_SUBST now supplied in XORG_MANPAGE_SECTIONS | |
54 | The value of MAN_SUBST is the same for all X.Org packages. | |
55 | ||
56 | Use AC_PROG_SED now supplied by XORG_DEFAULT_OPTIONS | |
57 | Enables use of platform appropriate version of sed. | |
58 | ||
59 | Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> | |
60 | ||
61 | commit 539d89d70ddb16fc3b98968a63276519e737a270 | |
62 | Author: Jesse Adkins <jesserayadkins@gmail.com> | |
63 | Date: Tue Sep 28 13:29:49 2010 -0700 | |
64 | ||
65 | Purge cvs tags. | |
66 | ||
67 | Signed-off-by: Jesse Adkins <jesserayadkins@gmail.com> | |
68 | ||
69 | commit 0d88ba2ebc5d31e7bb03a0628fd4027f1937c39b | |
70 | Author: Gaetan Nadon <memsize@videotron.ca> | |
71 | Date: Sat Mar 27 10:33:54 2010 -0400 | |
72 | ||
73 | config: remove files unnecessarily listed in EXTRA_DIST | |
74 | ||
75 | Automake always distribute those files | |
76 | ||
77 | Signed-off-by: Gaetan Nadon <memsize@videotron.ca> | |
78 | ||
79 | commit a069b6acf4026b3bfd2927c8cc936a5fa65e160b | |
80 | Author: Gaetan Nadon <memsize@videotron.ca> | |
81 | Date: Fri Mar 26 17:22:22 2010 -0400 | |
82 | ||
83 | man: build man pages the standard way | |
84 | ||
85 | Source in git is .man, the suffix may vary by platform | |
86 | No need to make an exception in .gitignore for rendercheck | |
87 | Add __xorgversion__ to rendercheck.man | |
88 | ||
89 | Signed-off-by: Gaetan Nadon <memsize@videotron.ca> | |
90 | ||
91 | commit 83a772482d3bf85eeb3f47a7456a662b3b91c1d2 | |
92 | Author: Gaetan Nadon <memsize@videotron.ca> | |
93 | Date: Thu Feb 11 10:08:06 2010 -0500 | |
94 | ||
95 | config: move CWARNFLAGS from configure.ac to Makefile.am | |
96 | ||
97 | Compiler warning flags should be explicitly set in the makefile | |
98 | rather than being merged with other packages compiler flags. | |
99 | ||
100 | Signed-off-by: Gaetan Nadon <memsize@videotron.ca> | |
101 | ||
102 | commit c1cf222ea8dded9832863116b7f62991088135a0 | |
103 | Author: Gaetan Nadon <memsize@videotron.ca> | |
104 | Date: Thu Nov 26 09:19:52 2009 -0500 | |
105 | ||
106 | Makefile.am: add ChangeLog and INSTALL on MAINTAINERCLEANFILES | |
107 | ||
108 | Now that the INSTALL file is generated. | |
109 | Allows running make maintainer-clean. | |
110 | ||
111 | commit 999c99c4534a4f371076e5f85cd135483b66960d | |
112 | Author: Gaetan Nadon <memsize@videotron.ca> | |
113 | Date: Wed Oct 28 14:09:07 2009 -0400 | |
114 | ||
115 | INSTALL, NEWS, README or AUTHORS files are missing/incorrect #24206 | |
116 | ||
117 | Add missing INSTALL file. Use standard GNU file on building tarball | |
118 | README may have been updated | |
119 | Remove AUTHORS file as it is empty and no content available yet. | |
120 | Remove NEWS file as it is empty and no content available yet. | |
121 | ||
122 | commit a118619650d75cf92caca2896828a1d8ef0d3e03 | |
123 | Author: Gaetan Nadon <memsize@videotron.ca> | |
124 | Date: Tue Oct 27 15:07:24 2009 -0400 | |
125 | ||
126 | Deploy the new XORG_DEFAULT_OPTIONS #24242 | |
127 | ||
128 | This macro aggregate a number of existing macros that sets commmon | |
129 | X.Org components configuration options. It shields the configuration file from | |
130 | future changes. | |
131 | ||
132 | commit f76c6cb996769fe32a6dce496b5f70326feb84e8 | |
133 | Author: Gaetan Nadon <memsize@videotron.ca> | |
134 | Date: Mon Oct 26 22:08:38 2009 -0400 | |
135 | ||
136 | Makefile.am: ChangeLog not required: EXTRA_DIST or *CLEANFILES #24432 | |
137 | ||
138 | ChangeLog filename is known to Automake and requires no further | |
139 | coding in the makefile. | |
140 | ||
141 | commit a05c845fd67c85a775ed5d9abf75369cf5dae25b | |
142 | Author: Gaetan Nadon <memsize@videotron.ca> | |
143 | Date: Thu Oct 22 16:13:16 2009 -0400 | |
144 | ||
145 | Makefile.am: do not include autogen.sh in distribution #24183 | |
146 | ||
147 | This is a private build script that should not be distributed | |
148 | ||
149 | commit c80dce0c5beca48ee2758ca78fba59c20127215e | |
150 | Author: Gaetan Nadon <memsize@videotron.ca> | |
151 | Date: Thu Oct 22 12:34:14 2009 -0400 | |
152 | ||
153 | .gitignore: use common defaults with custom section # 24239 | |
154 | ||
155 | Using common defaults will reduce errors and maintenance. | |
156 | Only the very small or inexistent custom section need periodic maintenance | |
157 | when the structure of the component changes. Do not edit defaults. | |
158 | ||
159 | commit ed91c60970a41670d6dc58f59c24c60d0dbe21fd | |
160 | Author: Jeremy Huddleston <jeremyhu@freedesktop.org> | |
161 | Date: Wed Oct 21 12:47:19 2009 -0700 | |
162 | ||
163 | This is not a GNU project, so declare it foreign. | |
164 | ||
165 | On Wed, 2009-10-21 at 13:36 +1000, Peter Hutterer wrote: | |
166 | > On Tue, Oct 20, 2009 at 08:23:55PM -0700, Jeremy Huddleston wrote: | |
167 | > > I noticed an INSTALL file in xlsclients and libXvMC today, and it | |
168 | > > was quite annoying to work around since 'autoreconf -fvi' replaces | |
169 | > > it and git wants to commit it. Should these files even be in git? | |
170 | > > Can I nuke them for the betterment of humanity and since they get | |
171 | > > created by autoreconf anyways? | |
172 | > | |
173 | > See https://bugs.freedesktop.org/show_bug.cgi?id=24206 | |
174 | ||
175 | As an interim measure, replace AM_INIT_AUTOMAKE([dist-bzip2]) with | |
176 | AM_INIT_AUTOMAKE([foreign dist-bzip2]). This will prevent the generation | |
177 | of the INSTALL file. It is also part of the 24206 solution. | |
178 | ||
179 | Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org> | |
180 | ||
181 | commit 37eac61e71a313df9927ca2a41ef49bda92fd9c6 | |
182 | Author: Ian Romanick <ian.d.romanick@intel.com> | |
183 | Date: Tue Jan 20 12:04:46 2009 -0800 | |
184 | ||
185 | Make autogen.sh look like the autogen.sh in every other fd.o project | |
186 | ||
187 | Explicitly calling aclocal in autogen.sh circumvents the user's | |
188 | ACLOCAL environment setting and pretty much always does the wrong thing. | |
189 | ||
190 | commit 63814639cb070e34a1aa2205ff71d64e6cc884ce | |
191 | Author: Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br> | |
192 | Date: Mon Jan 19 15:20:50 2009 -0200 | |
193 | ||
194 | Ansification and compile warning fixes. | |
195 | ||
196 | This also uses XORG_CHANGELOG and XORG_CWARNFLAGS, corrects | |
197 | make distcheck, all gcc 4.3 and sparse warnings, and a configure | |
198 | configure warning about err.h. | |
199 | ||
200 | commit 2659ac63a1b17e489cb37a44d8c26350de8c7c82 | |
201 | Author: Aaron Plattner <aplattner@nvidia.com> | |
202 | Date: Wed Jan 7 18:40:50 2009 -0800 | |
203 | ||
204 | Fix build with -Wall -Werror -pedantic | |
205 | ||
206 | commit c006790eff135feb16c88e48afb12496d74930b4 | |
207 | Author: Aaron Plattner <aplattner@nvidia.com> | |
208 | Date: Wed Jan 7 18:24:08 2009 -0800 | |
209 | ||
210 | Add a --version option. | |
211 | ||
212 | Print the version unconditionally. Exit immediately if --version was specified | |
213 | and continue otherwise. | |
214 | ||
215 | While I'm at it, use Bool instead of int for is_sync. | |
216 | ||
217 | commit 0c6aaf012b592bae818d5ce75cd41f23bd4d2cd5 | |
218 | Author: Eric Anholt <eric@anholt.net> | |
219 | Date: Tue Apr 15 14:01:06 2008 -0700 | |
220 | ||
221 | Add a test for rendering to source-only pictures under gradients. | |
222 | ||
223 | commit 8288fd35540d148f7900d883525b530c4923eb71 | |
224 | Author: Keith Packard <keithp@keithp.com> | |
225 | Date: Tue Apr 15 13:27:35 2008 -0700 | |
226 | ||
227 | Remove bogus extra loop from gradient tests. | |
228 | ||
229 | Gradient tests use a single loop, not two. | |
230 | ||
231 | commit 74e2b0dffb65578360889ee7a0ef1e2a82347233 | |
232 | Author: Adam Jackson <ajax@redhat.com> | |
233 | Date: Fri Mar 7 16:48:08 2008 -0500 | |
234 | ||
235 | rendercheck 1.3 | |
236 | ||
237 | commit 365c2d85d4bc342a3a868f5bc5e43a342f384d07 | |
238 | Author: James Cloos <cloos@jhcloos.com> | |
239 | Date: Thu Dec 6 16:37:04 2007 -0500 | |
240 | ||
241 | Replace static ChangeLog with dist-hook to generate from git log | |
242 | ||
243 | commit bf5275efbf45672ef8364c773cfa98ccd46ab967 | |
244 | Merge: 3b5b26e 70d9421 | |
245 | Author: Eric Anholt <eric@anholt.net> | |
246 | Date: Fri Feb 9 14:10:24 2007 -0800 | |
247 | ||
248 | Merge branch 'origin' | |
249 | ||
250 | commit 70d94216cc7b6ecd15cc628646516aef10972035 | |
251 | Author: Eric Anholt <eric@anholt.net> | |
252 | Date: Fri Feb 2 17:04:10 2007 -0800 | |
253 | ||
254 | Add another transformed source coordinates test. | |
255 | ||
256 | This one takes a whole image and rotates it to the left when drawing it to | |
257 | the destination. Reveals an off-by-one error in i915 Render acceleration. | |
258 | ||
259 | commit 160d69f593f4054d1973b27a24bf24323774c346 | |
260 | Author: Eric Anholt <eric@anholt.net> | |
261 | Date: Fri Feb 2 15:55:07 2007 -0800 | |
262 | ||
263 | Unbreak the dstcoords test, and test it with PictOpOver, as well. | |
264 | ||
265 | Testing on dests[0] meant an a8 picture, which doesn't capture color very well. | |
266 | Use the window, instead. Also, make the code match the comment about it being | |
267 | a 3x3 picture (previously, we drew 1x1). | |
268 | ||
269 | commit 2ae83b5c2783dbce9523ce030a50596eb6804c2b | |
270 | Author: Eric Anholt <eric@anholt.net> | |
271 | Date: Thu Jan 11 16:36:48 2007 -0800 | |
272 | ||
273 | Bug #9485: Fix a sign-extension issue on 64-bit platforms in pixel fetching. | |
274 | ||
275 | The result was that 32bpp pictures with a field including the top bit would | |
276 | result in get_pixel returning a zero in that channel. | |
277 | ||
278 | While I'm here, also fix the fact that we weren't using XGetPixel to fetch the | |
279 | pixel, which would have likely caused problems on big-endian systems. | |
280 | ||
281 | commit f5395a5866c4947dbfc30b8845f9400a422990ce | |
282 | Author: Eric Anholt <eric@anholt.net> | |
283 | Date: Thu Jan 11 16:16:27 2007 -0800 | |
284 | ||
285 | Add more gcc warning flags, and clean up the added warnings. | |
286 | ||
287 | commit 3b5b26e88dfdfc2f97cd1a239eae1865b25bbe5a | |
288 | Author: Eric Anholt <eric@anholt.net> | |
289 | Date: Tue Nov 28 15:05:01 2006 -0800 | |
290 | ||
291 | Bump version to 1.2 and update docs. | |
292 | ||
293 | commit 72cb2695ae1f78adef263eff779cc88541a41c87 | |
294 | Author: Eric Anholt <eric@anholt.net> | |
295 | Date: Thu Oct 26 16:31:43 2006 -0700 | |
296 | ||
297 | Reduce the size of the rendering done in many tests. | |
298 | ||
299 | This significantly improves test performance (~60% in blend). | |
300 | ||
301 | commit ff63516c203c0593ee08b77cc9267afe2ca5b0e3 | |
302 | Author: Eric Anholt <eric@anholt.net> | |
303 | Date: Thu Oct 26 16:15:55 2006 -0700 | |
304 | ||
305 | Slight cleanup of create_formats_list(). | |
306 | ||
307 | commit cadf1d2fdfc4a35662a766864d323b4097d07767 | |
308 | Author: Eric Anholt <eric@anholt.net> | |
309 | Date: Thu Oct 26 16:14:29 2006 -0700 | |
310 | ||
311 | Reduce the number of colors to speed up test execution. | |
312 | ||
313 | The other colors were probably not important. | |
314 | ||
315 | commit 6e809f1ee673a430c58ed486346bf482f451493e | |
316 | Author: Eric Anholt <eric@anholt.net> | |
317 | Date: Thu Oct 26 16:13:45 2006 -0700 | |
318 | ||
319 | Run most tests with all formats, rather than a small subset. | |
320 | ||
321 | commit 501d5fb5b354951bf8eef893824b637003beea6e | |
322 | Author: Eric Anholt <eric@anholt.net> | |
323 | Date: Thu Oct 26 13:27:25 2006 -0700 | |
324 | ||
325 | Add a -f flag to whitelist formats. | |
326 | ||
327 | commit 003f341cf695f66b81d21f255bd816ae825f4ab3 | |
328 | Author: Tilman Sauerbeck <tilman@code-monkey.de> | |
329 | Date: Wed Sep 13 22:26:16 2006 +0200 | |
330 | ||
331 | Set the format field for the solid pictures, too. | |
332 | ||
333 | It's needed in case an error occurs at the tests where they are used, | |
334 | because then the picture format will be evaluated by describe_format(). | |
335 | ||
336 | commit 095d7346b2a58c48609c1c8d75e5e21e25230b73 | |
337 | Author: Tilman Sauerbeck <tilman@code-monkey.de> | |
338 | Date: Wed Sep 13 22:24:25 2006 +0200 | |
339 | ||
340 | Scale the alpha channel diff, too, before calculating the final error. | |
341 | ||
342 | This makes errors that only occur in the alpha channel have a chance to be | |
343 | recognized. If the alpha channel diff isn't scaled, it can never be > 3.0. | |
344 | ||
345 | commit 053d4f3d0f4e271e5c868067137264756a11dbff | |
346 | Author: Tilman Sauerbeck <tilman@code-monkey.de> | |
347 | Date: Tue Sep 5 20:58:22 2006 +0200 | |
348 | ||
349 | Added missing tests to usage output. | |
350 | ||
351 | commit de32ec8589b7d292dcf6e92c9f28a62b95aa2dbd | |
352 | Author: Tilman Sauerbeck <tilman@code-monkey.de> | |
353 | Date: Tue Aug 29 18:17:39 2006 +0200 | |
354 | ||
355 | Bug #8062: Set up XTransforms correctly. | |
356 | ||
357 | Don't store floats directly in the matrix, but pass them through | |
358 | XDoubleToFixed(). That the test still passes with xorg-server's software | |
359 | implementation. | |
360 | ||
361 | commit ad7e07b309216e2eef30cbc718edefb79d8febe5 | |
362 | Author: Tilman Sauerbeck <tilman@code-monkey.de> | |
363 | Date: Fri Aug 25 16:07:58 2006 -0700 | |
364 | ||
365 | Correct typo in usage. | |
366 | ||
367 | commit 2319fc448354c6b965132ada135d38cce8badb9d | |
368 | Author: Eric Anholt <anholt@FreeBSD.org> | |
369 | Date: Fri Jun 30 11:54:13 2006 +0200 | |
370 | ||
371 | Add a check for setting a filter on a source picture causing a crash. | |
372 | (cherry picked from f313b8c4f7bfc2910a55002ba6c8a731796e7d19 commit) | |
373 | ||
374 | commit 0b9af7ccf482fb1dafed256f21742eb2a9de56f9 | |
375 | Author: Eric Anholt <anholt@FreeBSD.org> | |
376 | Date: Fri Jun 30 11:57:35 2006 +0200 | |
377 | ||
378 | Actually add the tests for bug #7366, and add a couple more crash cases. | |
379 | ||
380 | commit a3c9527030127fe6dd06d1d75207b4e855b93db8 | |
381 | Author: Eric Anholt <anholt@FreeBSD.org> | |
382 | Date: Thu Jun 29 19:12:52 2006 +0200 | |
383 | ||
384 | Add a regression test for bug #7366 (crash on transform of source picture). | |
385 | ||
386 | commit 388f4492b3099546a2af89e59bc8807709508b53 | |
387 | Author: Eric Anholt <anholt@FreeBSD.org> | |
388 | Date: Mon Jun 19 17:58:45 2006 -0700 | |
389 | ||
390 | Add a -o flag to select a subset of the Render operators for testing. | |
391 | ||
392 | commit f678d50210e81941790f2db72c12563d411006d9 | |
393 | Author: Eric Anholt <anholt@FreeBSD.org> | |
394 | Date: Mon Jun 19 17:17:28 2006 -0700 | |
395 | ||
396 | Disable tests at low bitdepths that rendercheck isn't good enough to support. | |
397 | ||
398 | commit 29494c0526c0a1e66e947dec455de1338fad11dd | |
399 | Author: Eric Anholt <anholt@FreeBSD.org> | |
400 | Date: Mon Jun 19 16:49:41 2006 -0700 | |
401 | ||
402 | Note the source format in blend test error output. | |
403 | ||
404 | commit 63074a124a755ac6374d644ae7960dbd8cab6251 | |
405 | Author: Eric Anholt <anholt@FreeBSD.org> | |
406 | Date: Mon Jun 19 16:49:18 2006 -0700 | |
407 | ||
408 | Tell the ordering of the channel values in error output. | |
409 | ||
410 | commit 05fa6e38e8e934b74bcc3771781d05cfb3313b26 | |
411 | Author: Eric Anholt <anholt@FreeBSD.org> | |
412 | Date: Mon Jun 19 08:30:27 2006 -0700 | |
413 | ||
414 | Add support for checking more formats. | |
415 | ||
416 | commit 334d2203d35c27e0c0d73226ad8a58360c8b36bb | |
417 | Author: Eric Anholt <anholt@FreeBSD.org> | |
418 | Date: Fri Jun 16 09:49:06 2006 -0700 | |
419 | ||
420 | Add an option "--minimalrendering" which suppresses the copying of offscreen | |
421 | rendering results to the window, which reduces the runtime of the blend tests by | |
422 | 10.2% +/- 6.2% on my system. The copy remains on by default because I think it | |
423 | can be useful. | |
424 | ||
425 | commit b99c20783f3d77077eef2af18960db1a68d0dffd | |
426 | Author: Eric Anholt <anholt@FreeBSD.org> | |
427 | Date: Mon May 22 23:54:55 2006 -0700 | |
428 | ||
429 | Bump version to 1.1 and update docs. | |
430 | ||
431 | commit 47e2f49ffc5c9300097ffb217074b0cac13f1e42 | |
432 | Author: Eric Anholt <anholt@FreeBSD.org> | |
433 | Date: Mon May 22 23:51:39 2006 -0700 | |
434 | ||
435 | Replace autogen.sh with a more standard one from that does srcdir != builddir. | |
436 | ||
437 | commit 60d23bc0d6b8dbefa0c03949bb1637970450e58e | |
438 | Author: Alan Coopersmith <alanc@alf.(none)> | |
439 | Date: Thu May 4 21:46:39 2006 -0700 | |
440 | ||
441 | Add fallback version of errx for platforms without errx/err.h | |
442 | ||
443 | commit d51e519170bf912339afac89f25c1f7662a101a2 | |
444 | Author: Alan Coopersmith <alanc@alf.(none)> | |
445 | Date: Wed May 3 09:58:47 2006 -0700 | |
446 | ||
447 | Ignore emacs *~ backup files | |
448 | ||
449 | commit af99a26276212838da35d9fd07702e74dcbab5a1 | |
450 | Merge: 0410434 c1d2c66 | |
451 | Author: Eric Anholt <anholt@FreeBSD.org> | |
452 | Date: Wed May 3 01:32:57 2006 -0700 | |
453 | ||
454 | Merge branch 'security-implications' containing a new test for the triangles | |
455 | calls, which I used for tracking down the Bug #6642 (CVE-2006-1526) issue. It | |
456 | doesn't test much more of triangles than "we can render a couple of them". | |
457 | ||
458 | Conflicts: | |
459 | ||
460 | Makefile.am | |
461 | main.c | |
462 | rendercheck.1 | |
463 | rendercheck.h | |
464 | tests.c | |
465 | ||
466 | commit 0410434d5a10a52cb381d6713d347da759474edd | |
467 | Author: Eric Anholt <anholt@FreeBSD.org> | |
468 | Date: Mon May 1 22:15:14 2006 -0700 | |
469 | ||
470 | Include the format of the picture in the fill test failure output. | |
471 | ||
472 | commit 202329633d2ebc370e11b922337df7b412f8d01d | |
473 | Author: Eric Anholt <anholt@FreeBSD.org> | |
474 | Date: Mon May 1 22:14:24 2006 -0700 | |
475 | ||
476 | Fix describing of some more formats. | |
477 | ||
478 | commit e0aa3e6f0fe7d4f546079d3f994c4ee8aea14a19 | |
479 | Author: Eric Anholt <anholt@FreeBSD.org> | |
480 | Date: Mon May 1 20:35:47 2006 -0700 | |
481 | ||
482 | Correct the comment describing what fill_test does (test the filling of the | |
483 | ||
484 | pictures, not filling from the pictures). | |
485 | ||
486 | commit b7f09efcab3e85b183218438e6e87bd665541fb5 | |
487 | Merge: 6545649 f95ea74 | |
488 | Author: Alan Coopersmith <alanc@alf.(none)> | |
489 | Date: Mon May 1 09:49:34 2006 -0700 | |
490 | ||
491 | Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/app/rendercheck | |
492 | ||
493 | commit f95ea74cd31f28e33a0c888f9ab26a6408fb1d2e | |
494 | Author: Eric Anholt <anholt@FreeBSD.org> | |
495 | Date: Fri Apr 21 09:21:50 2006 -0700 | |
496 | ||
497 | Update TODO list. | |
498 | ||
499 | commit beeae5eb9b1d85d8e3b638e7927d94ad2f3c5f1d | |
500 | Author: Eric Anholt <anholt@FreeBSD.org> | |
501 | Date: Fri Apr 21 09:20:21 2006 -0700 | |
502 | ||
503 | Count the successes and failures of tests, printing results when finished, and | |
504 | returning a failure exit code if we failed any tests. | |
505 | ||
506 | commit 9d46f6e9528040416356602688d717a2bb0dd2a5 | |
507 | Merge: edb11cf 6cfab61 | |
508 | Author: Lars Knoll <lars@pramoda.localdomain> | |
509 | Date: Fri Apr 21 10:01:40 2006 +0200 | |
510 | ||
511 | Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/app/rendercheck | |
512 | ||
513 | commit 6cfab618fabcc5c4fc86aaeadcd8e6d9255cb6eb | |
514 | Author: Eric Anholt <anholt@FreeBSD.org> | |
515 | Date: Thu Apr 20 12:41:29 2006 -0700 | |
516 | ||
517 | Correct offsets for argb32* convenience colors, so the right colors are used in | |
518 | the repeat test. | |
519 | ||
520 | commit c862f6285b868435a2780b07a602f57e810e1f96 | |
521 | Author: Eric Anholt <anholt@FreeBSD.org> | |
522 | Date: Thu Apr 20 12:33:25 2006 -0700 | |
523 | ||
524 | Add a short doc on the things to do when adding a new test. Move TODO into the | |
525 | doc dir as well. Also, update README for the new tests. | |
526 | ||
527 | commit b26a0acd18aac615a2abc4df5adc888cb3e3714b | |
528 | Author: Eric Anholt <anholt@FreeBSD.org> | |
529 | Date: Thu Apr 20 12:27:17 2006 -0700 | |
530 | ||
531 | Add a test for various-sized repeating sources. Reveals issues with EXA Radeon | |
532 | render acceleration. Thanks to frederikh for the testcase that suggested the | |
533 | necessity here. | |
534 | ||
535 | commit e5e49a6b67e2e2919d5236583f01088fdecf347b | |
536 | Author: Eric Anholt <anholt@FreeBSD.org> | |
537 | Date: Thu Apr 20 11:53:51 2006 -0700 | |
538 | ||
539 | Correct a heinous memory leak in get_pixel(). | |
540 | ||
541 | commit edb11cfdda3d4d14fc1ba5f0c4bc9ce925bf970b | |
542 | Author: Lars Knoll <lars@trolltech.com> | |
543 | Date: Thu Apr 20 08:56:37 2006 +0200 | |
544 | ||
545 | add license header | |
546 | ||
547 | commit 65456490e4511a961cdd1ce85e2b31ec791def4d | |
548 | Author: Alan Coopersmith <alanc@alf.(none)> | |
549 | Date: Wed Apr 19 18:55:10 2006 -0700 | |
550 | ||
551 | Only add -Wall flag when using gcc, not other compilers | |
552 | ||
553 | commit ccf3c74e703aacb6a3677842e14668fce0e315cc | |
554 | Author: Eric Anholt <anholt@FreeBSD.org> | |
555 | Date: Wed Apr 19 09:27:01 2006 -0700 | |
556 | ||
557 | Respect --iter in a couple more tests. | |
558 | ||
559 | commit d08fdf4794584f6fc0d78f27ec331a90d1ebd279 | |
560 | Author: Eric Anholt <anholt@FreeBSD.org> | |
561 | Date: Wed Apr 19 09:26:07 2006 -0700 | |
562 | ||
563 | Improve the wording of the -d argument, which was copied from xcompmgr.1 iirc. | |
564 | ||
565 | commit 02d1383ddae76597323655435ff0892b8d48d7f2 | |
566 | Author: Eric Anholt <anholt@FreeBSD.org> | |
567 | Date: Wed Apr 19 09:20:12 2006 -0700 | |
568 | ||
569 | Add gradients to the list of tests supported. | |
570 | ||
571 | commit 032ae6c6cd84503c30427857107b3b312506726c | |
572 | Author: Eric Anholt <anholt@FreeBSD.org> | |
573 | Date: Wed Apr 19 09:18:23 2006 -0700 | |
574 | ||
575 | Remove useless $Id$ markers. | |
576 | ||
577 | commit c1d2c663c385a4c0e2ac6ba03664cf252dff62b0 | |
578 | Author: Eric Anholt <anholt@FreeBSD.org> | |
579 | Date: Wed Apr 19 09:13:55 2006 -0700 | |
580 | ||
581 | Add a trivial test for Triangles, TriStrip, and TriFan, which exposed a security | |
582 | flaw in the server | |
583 | ||
584 | commit d5949bcc33e115f12762127093f1d5b3158c1c01 | |
585 | Author: Eric Anholt <anholt@FreeBSD.org> | |
586 | Date: Tue Apr 18 16:34:52 2006 -0700 | |
587 | ||
588 | Move .cvsignore to .gitignore. | |
589 | ||
590 | commit 00f788fc2785db30ee294281c027f82d09256be6 | |
591 | Author: Lars Knoll <lars@trolltech.com> | |
592 | Date: Wed Mar 8 06:13:42 2006 +0000 | |
593 | ||
594 | add testing for linear gradients. | |
595 | ||
596 | commit 4fd03c7cf419c84b8bdfcf25745627659e794300 | |
597 | Author: Lars Knoll <lars@trolltech.com> | |
598 | Date: Mon Mar 6 21:22:15 2006 +0000 | |
599 | ||
600 | test composition operations using solid source pictures | |
601 | (Created with XRenderCreateSolidFill). | |
602 | ||
603 | At least the XServer doesn't crash anymore on me | |
604 | trying to use them (though he might with EXA), | |
605 | but the i810 driver fails handling them correctly. | |
606 | I'm sure other drivers might have problems as well. | |
607 | ||
608 | commit 2e734bdc5e1fa6433c953e05f3608566ad75aa1d | |
609 | Author: Eric Anholt <anholt@freebsd.org> | |
610 | Date: Tue Sep 27 02:19:15 2005 +0000 | |
611 | ||
612 | Add a description of the -i flag, and alphabetize. | |
613 | ||
614 | commit 14c1dbe8d030fb5dbd63e0bbc63f256f7fc78bde | |
615 | Author: Eric Anholt <anholt@freebsd.org> | |
616 | Date: Tue Sep 27 02:08:04 2005 +0000 | |
617 | ||
618 | Add a --sync flag to set XSynchronize() (for debugging a scripting issue) and | |
619 | add long argument equivalents for current options. | |
620 | ||
621 | commit 7445bc2d1ccaa0f4f276b0cef159d3db4a41dd84 | |
622 | Author: Eric Anholt <anholt@freebsd.org> | |
623 | Date: Thu Sep 15 22:15:22 2005 +0000 | |
624 | ||
625 | Remove the apparently-unnecessary AC_CONFIG_AUX_DIR setting that made new | |
626 | automake cry. | |
627 | ||
628 | commit 227b75ebf0e468c094bcba95bd9599a5e6d687be | |
629 | Author: Eric Anholt <anholt@freebsd.org> | |
630 | Date: Thu Jan 27 03:47:37 2005 +0000 | |
631 | ||
632 | Make autogen.sh actually do its job, and add some missing files to the dist. | |
633 | ||
634 | commit 2427ac0046a8f53bea8b709c2d6e90eacb355631 | |
635 | Author: Eric Anholt <anholt@freebsd.org> | |
636 | Date: Thu Jan 27 03:12:08 2005 +0000 | |
637 | ||
638 | Allow users to specify the set of tests to be run. | |
639 | ||
640 | commit 7419df337982418ba11432c9f11a7b4056b70658 | |
641 | Author: Eric Anholt <anholt@freebsd.org> | |
642 | Date: Thu Jan 27 02:42:14 2005 +0000 | |
643 | ||
644 | - Split the tests out into separate files. | |
645 | - Split some of the test picture generation out into those files, too. | |
646 | - Add a helper function for filling things with a color. | |
647 | - Add -Wall to CFLAGS and clean up the ensuing carnage. | |
648 | ||
649 | commit 85a6ac04cca072a64aa13d1829ae9aa1a6a3f7e3 | |
650 | Author: Eric Anholt <anholt@freebsd.org> | |
651 | Date: Thu Jan 27 02:39:30 2005 +0000 | |
652 | ||
653 | Add an appropriate .cvsignore. | |
654 | ||
655 | commit f02f7e4cd2d2a628d59def61835ed9fa06de4c4f | |
656 | Author: Eric Anholt <anholt@freebsd.org> | |
657 | Date: Thu Jan 27 01:24:41 2005 +0000 | |
658 | ||
659 | Add a simple manpage, and add commandline options for verbosity and display. | |
660 | ||
661 | commit 56890198e02cb2d63e6ca64264a4f2252c272978 | |
662 | Author: Eric Anholt <anholt@freebsd.org> | |
663 | Date: Thu Jan 27 00:39:56 2005 +0000 | |
664 | ||
665 | Set the main window OverrideRedirect. metacity gets less confused, and things | |
666 | are a bit more deterministic. | |
667 | ||
668 | commit a5962dda126e7e48f51c276f907a1fbb76b8ed4d | |
669 | Author: Eric Anholt <anholt@freebsd.org> | |
670 | Date: Sun Oct 24 21:03:56 2004 +0000 | |
671 | ||
672 | Allow building without xrender.pc, by using AC_PATH_XTRA. Bump to 1.0.3. | |
673 | ||
674 | commit df85d34dd3a85a3629caa2732729ae26f268d5d0 | |
675 | Author: Eric Anholt <anholt@freebsd.org> | |
676 | Date: Mon Sep 27 01:51:42 2004 +0000 | |
677 | ||
678 | Sigh. Some day somebody will write a makefile system that isn't based on | |
679 | hatred for its users. Until then, shut automake up about the "lack" of a | |
680 | ChangeLog file. Also avoid accidentally spamming in the copy of the GPL it | |
681 | decided my COPYING file should be replaced with. | |
682 | ||
683 | commit 1550c69e3528653a0690f116a454a77f63bf1294 | |
684 | Author: Eric Anholt <anholt@freebsd.org> | |
685 | Date: Mon Sep 20 02:42:53 2004 +0000 | |
686 | ||
687 | Back out previous changes to the transformed coordinates test. It looks like the | |
688 | intention really was for pixels to be centered on (x + .5, y + .5), and this | |
689 | does seem more sensible. Bump the version to 1.0.2 and update docs. | |
690 | ||
691 | commit e342db6763ad3f829d1bfc14663247509677f20b | |
692 | Author: Eric Anholt <anholt@freebsd.org> | |
693 | Date: Mon Aug 30 22:07:16 2004 +0000 | |
694 | ||
695 | Correct the previous commit: | |
696 | Render does specify the rounding on transformed coordinates, which is "Nearest" | |
697 | by default. Fix the test appropriately. Note that this exposes a bug in the fb | |
698 | implementation. | |
699 | ||
700 | commit 2a0b03dc10470c85ab31628aad360736b1f6739a | |
701 | Author: Eric Anholt <anholt@freebsd.org> | |
702 | Date: Mon Aug 30 17:24:04 2004 +0000 | |
703 | ||
704 | Add a simple test of transformed source/mask coordinates. | |
705 | Add more tasks to TODO. | |
706 | ||
707 | commit 1594aadab7bc3636adbea9a990fb42547840770c | |
708 | Author: Eric Anholt <anholt@freebsd.org> | |
709 | Date: Mon Aug 30 16:54:49 2004 +0000 | |
710 | ||
711 | Kill the ChangeLog. Updating them is annoying. If you want the ChangeLog, use | |
712 | cvs2cl. | |
713 | ||
714 | commit 783ba8d4314ca1412e3f806cd07bfd52fb8dfc5b | |
715 | Author: Eric Anholt <anholt@freebsd.org> | |
716 | Date: Sun Jun 13 19:52:06 2004 +0000 | |
717 | ||
718 | Exercise XAA's Composite acceleration by also rendering | |
719 | directly to the destination window instead of only pixmaps. | |
720 | ||
721 | commit 3ee9ea7cda8fe71abc77151e1a94b4dfc06767b8 | |
722 | Author: Eric Anholt <anholt@freebsd.org> | |
723 | Date: Mon May 17 05:31:21 2004 +0000 | |
724 | ||
725 | - get_pixel was not at fault, and get destcoords_test working. | |
726 | - Change fill_test from being a duplication of the blend tests | |
727 | to a test of whether the XRenderFillRectangle()s produced the | |
728 | expected results. | |
729 | - Update TODO list. | |
730 | - Bump version to 1.0.1. | |
731 | ||
732 | commit 70b1be1b819b7ebacf268dfb498a3adab133916e | |
733 | Author: Eric Anholt <anholt@freebsd.org> | |
734 | Date: Mon May 10 07:21:19 2004 +0000 | |
735 | ||
736 | Initial import of rendercheck (attempt 2). | |
737 | ||
738 | commit 258f238ae94782fa1c0e1d8b6280d8d61c9c0c40 | |
739 | Author: Eric Anholt <anholt@freebsd.org> | |
740 | Date: Mon May 10 07:21:19 2004 +0000 | |
741 | ||
742 | Initial revision |
0 | Installation Instructions | |
1 | ************************* | |
2 | ||
3 | Copyright (C) 1994, 1995, 1996, 1999, 2000, 2001, 2002, 2004, 2005, | |
4 | 2006, 2007, 2008 Free Software Foundation, Inc. | |
5 | ||
6 | This file is free documentation; the Free Software Foundation gives | |
7 | unlimited permission to copy, distribute and modify it. | |
8 | ||
9 | Basic Installation | |
10 | ================== | |
11 | ||
12 | Briefly, the shell commands `./configure; make; make install' should | |
13 | configure, build, and install this package. The following | |
14 | more-detailed instructions are generic; see the `README' file for | |
15 | instructions specific to this package. | |
16 | ||
17 | The `configure' shell script attempts to guess correct values for | |
18 | various system-dependent variables used during compilation. It uses | |
19 | those values to create a `Makefile' in each directory of the package. | |
20 | It may also create one or more `.h' files containing system-dependent | |
21 | definitions. Finally, it creates a shell script `config.status' that | |
22 | you can run in the future to recreate the current configuration, and a | |
23 | file `config.log' containing compiler output (useful mainly for | |
24 | debugging `configure'). | |
25 | ||
26 | It can also use an optional file (typically called `config.cache' | |
27 | and enabled with `--cache-file=config.cache' or simply `-C') that saves | |
28 | the results of its tests to speed up reconfiguring. Caching is | |
29 | disabled by default to prevent problems with accidental use of stale | |
30 | cache files. | |
31 | ||
32 | If you need to do unusual things to compile the package, please try | |
33 | to figure out how `configure' could check whether to do them, and mail | |
34 | diffs or instructions to the address given in the `README' so they can | |
35 | be considered for the next release. If you are using the cache, and at | |
36 | some point `config.cache' contains results you don't want to keep, you | |
37 | may remove or edit it. | |
38 | ||
39 | The file `configure.ac' (or `configure.in') is used to create | |
40 | `configure' by a program called `autoconf'. You need `configure.ac' if | |
41 | you want to change it or regenerate `configure' using a newer version | |
42 | of `autoconf'. | |
43 | ||
44 | The simplest way to compile this package is: | |
45 | ||
46 | 1. `cd' to the directory containing the package's source code and type | |
47 | `./configure' to configure the package for your system. | |
48 | ||
49 | Running `configure' might take a while. While running, it prints | |
50 | some messages telling which features it is checking for. | |
51 | ||
52 | 2. Type `make' to compile the package. | |
53 | ||
54 | 3. Optionally, type `make check' to run any self-tests that come with | |
55 | the package. | |
56 | ||
57 | 4. Type `make install' to install the programs and any data files and | |
58 | documentation. | |
59 | ||
60 | 5. You can remove the program binaries and object files from the | |
61 | source code directory by typing `make clean'. To also remove the | |
62 | files that `configure' created (so you can compile the package for | |
63 | a different kind of computer), type `make distclean'. There is | |
64 | also a `make maintainer-clean' target, but that is intended mainly | |
65 | for the package's developers. If you use it, you may have to get | |
66 | all sorts of other programs in order to regenerate files that came | |
67 | with the distribution. | |
68 | ||
69 | 6. Often, you can also type `make uninstall' to remove the installed | |
70 | files again. | |
71 | ||
72 | Compilers and Options | |
73 | ===================== | |
74 | ||
75 | Some systems require unusual options for compilation or linking that | |
76 | the `configure' script does not know about. Run `./configure --help' | |
77 | for details on some of the pertinent environment variables. | |
78 | ||
79 | You can give `configure' initial values for configuration parameters | |
80 | by setting variables in the command line or in the environment. Here | |
81 | is an example: | |
82 | ||
83 | ./configure CC=c99 CFLAGS=-g LIBS=-lposix | |
84 | ||
85 | *Note Defining Variables::, for more details. | |
86 | ||
87 | Compiling For Multiple Architectures | |
88 | ==================================== | |
89 | ||
90 | You can compile the package for more than one kind of computer at the | |
91 | same time, by placing the object files for each architecture in their | |
92 | own directory. To do this, you can use GNU `make'. `cd' to the | |
93 | directory where you want the object files and executables to go and run | |
94 | the `configure' script. `configure' automatically checks for the | |
95 | source code in the directory that `configure' is in and in `..'. | |
96 | ||
97 | With a non-GNU `make', it is safer to compile the package for one | |
98 | architecture at a time in the source code directory. After you have | |
99 | installed the package for one architecture, use `make distclean' before | |
100 | reconfiguring for another architecture. | |
101 | ||
102 | On MacOS X 10.5 and later systems, you can create libraries and | |
103 | executables that work on multiple system types--known as "fat" or | |
104 | "universal" binaries--by specifying multiple `-arch' options to the | |
105 | compiler but only a single `-arch' option to the preprocessor. Like | |
106 | this: | |
107 | ||
108 | ./configure CC="gcc -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ | |
109 | CXX="g++ -arch i386 -arch x86_64 -arch ppc -arch ppc64" \ | |
110 | CPP="gcc -E" CXXCPP="g++ -E" | |
111 | ||
112 | This is not guaranteed to produce working output in all cases, you | |
113 | may have to build one architecture at a time and combine the results | |
114 | using the `lipo' tool if you have problems. | |
115 | ||
116 | Installation Names | |
117 | ================== | |
118 | ||
119 | By default, `make install' installs the package's commands under | |
120 | `/usr/local/bin', include files under `/usr/local/include', etc. You | |
121 | can specify an installation prefix other than `/usr/local' by giving | |
122 | `configure' the option `--prefix=PREFIX'. | |
123 | ||
124 | You can specify separate installation prefixes for | |
125 | architecture-specific files and architecture-independent files. If you | |
126 | pass the option `--exec-prefix=PREFIX' to `configure', the package uses | |
127 | PREFIX as the prefix for installing programs and libraries. | |
128 | Documentation and other data files still use the regular prefix. | |
129 | ||
130 | In addition, if you use an unusual directory layout you can give | |
131 | options like `--bindir=DIR' to specify different values for particular | |
132 | kinds of files. Run `configure --help' for a list of the directories | |
133 | you can set and what kinds of files go in them. | |
134 | ||
135 | If the package supports it, you can cause programs to be installed | |
136 | with an extra prefix or suffix on their names by giving `configure' the | |
137 | option `--program-prefix=PREFIX' or `--program-suffix=SUFFIX'. | |
138 | ||
139 | Optional Features | |
140 | ================= | |
141 | ||
142 | Some packages pay attention to `--enable-FEATURE' options to | |
143 | `configure', where FEATURE indicates an optional part of the package. | |
144 | They may also pay attention to `--with-PACKAGE' options, where PACKAGE | |
145 | is something like `gnu-as' or `x' (for the X Window System). The | |
146 | `README' should mention any `--enable-' and `--with-' options that the | |
147 | package recognizes. | |
148 | ||
149 | For packages that use the X Window System, `configure' can usually | |
150 | find the X include and library files automatically, but if it doesn't, | |
151 | you can use the `configure' options `--x-includes=DIR' and | |
152 | `--x-libraries=DIR' to specify their locations. | |
153 | ||
154 | Particular systems | |
155 | ================== | |
156 | ||
157 | On HP-UX, the default C compiler is not ANSI C compatible. If GNU | |
158 | CC is not installed, it is recommended to use the following options in | |
159 | order to use an ANSI C compiler: | |
160 | ||
161 | ./configure CC="cc -Ae" | |
162 | ||
163 | and if that doesn't work, install pre-built binaries of GCC for HP-UX. | |
164 | ||
165 | On OSF/1 a.k.a. Tru64, some versions of the default C compiler cannot | |
166 | parse its `<wchar.h>' header file. The option `-nodtk' can be used as | |
167 | a workaround. If GNU CC is not installed, it is therefore recommended | |
168 | to try | |
169 | ||
170 | ./configure CC="cc" | |
171 | ||
172 | and if that doesn't work, try | |
173 | ||
174 | ./configure CC="cc -nodtk" | |
175 | ||
176 | Specifying the System Type | |
177 | ========================== | |
178 | ||
179 | There may be some features `configure' cannot figure out | |
180 | automatically, but needs to determine by the type of machine the package | |
181 | will run on. Usually, assuming the package is built to be run on the | |
182 | _same_ architectures, `configure' can figure that out, but if it prints | |
183 | a message saying it cannot guess the machine type, give it the | |
184 | `--build=TYPE' option. TYPE can either be a short name for the system | |
185 | type, such as `sun4', or a canonical name which has the form: | |
186 | ||
187 | CPU-COMPANY-SYSTEM | |
188 | ||
189 | where SYSTEM can have one of these forms: | |
190 | ||
191 | OS KERNEL-OS | |
192 | ||
193 | See the file `config.sub' for the possible values of each field. If | |
194 | `config.sub' isn't included in this package, then this package doesn't | |
195 | need to know the machine type. | |
196 | ||
197 | If you are _building_ compiler tools for cross-compiling, you should | |
198 | use the option `--target=TYPE' to select the type of system they will | |
199 | produce code for. | |
200 | ||
201 | If you want to _use_ a cross compiler, that generates code for a | |
202 | platform different from the build platform, you should specify the | |
203 | "host" platform (i.e., that on which the generated programs will | |
204 | eventually be run) with `--host=TYPE'. | |
205 | ||
206 | Sharing Defaults | |
207 | ================ | |
208 | ||
209 | If you want to set default values for `configure' scripts to share, | |
210 | you can create a site shell script called `config.site' that gives | |
211 | default values for variables like `CC', `cache_file', and `prefix'. | |
212 | `configure' looks for `PREFIX/share/config.site' if it exists, then | |
213 | `PREFIX/etc/config.site' if it exists. Or, you can set the | |
214 | `CONFIG_SITE' environment variable to the location of the site script. | |
215 | A warning: not all `configure' scripts look for a site script. | |
216 | ||
217 | Defining Variables | |
218 | ================== | |
219 | ||
220 | Variables not defined in a site shell script can be set in the | |
221 | environment passed to `configure'. However, some packages may run | |
222 | configure again during the build, and the customized values of these | |
223 | variables may be lost. In order to avoid this problem, you should set | |
224 | them in the `configure' command line, using `VAR=value'. For example: | |
225 | ||
226 | ./configure CC=/usr/local2/bin/gcc | |
227 | ||
228 | causes the specified `gcc' to be used as the C compiler (unless it is | |
229 | overridden in the site shell script). | |
230 | ||
231 | Unfortunately, this technique does not work for `CONFIG_SHELL' due to | |
232 | an Autoconf bug. Until the bug is fixed you can use this workaround: | |
233 | ||
234 | CONFIG_SHELL=/bin/bash /bin/bash ./configure CONFIG_SHELL=/bin/bash | |
235 | ||
236 | `configure' Invocation | |
237 | ====================== | |
238 | ||
239 | `configure' recognizes the following options to control how it | |
240 | operates. | |
241 | ||
242 | `--help' | |
243 | `-h' | |
244 | Print a summary of all of the options to `configure', and exit. | |
245 | ||
246 | `--help=short' | |
247 | `--help=recursive' | |
248 | Print a summary of the options unique to this package's | |
249 | `configure', and exit. The `short' variant lists options used | |
250 | only in the top level, while the `recursive' variant lists options | |
251 | also present in any nested packages. | |
252 | ||
253 | `--version' | |
254 | `-V' | |
255 | Print the version of Autoconf used to generate the `configure' | |
256 | script, and exit. | |
257 | ||
258 | `--cache-file=FILE' | |
259 | Enable the cache: use and save the results of the tests in FILE, | |
260 | traditionally `config.cache'. FILE defaults to `/dev/null' to | |
261 | disable caching. | |
262 | ||
263 | `--config-cache' | |
264 | `-C' | |
265 | Alias for `--cache-file=config.cache'. | |
266 | ||
267 | `--quiet' | |
268 | `--silent' | |
269 | `-q' | |
270 | Do not print messages saying which checks are being made. To | |
271 | suppress all normal output, redirect it to `/dev/null' (any error | |
272 | messages will still be shown). | |
273 | ||
274 | `--srcdir=DIR' | |
275 | Look for the package's source code in directory DIR. Usually | |
276 | `configure' can determine that directory automatically. | |
277 | ||
278 | `--prefix=DIR' | |
279 | Use DIR as the installation prefix. *Note Installation Names:: | |
280 | for more details, including other options available for fine-tuning | |
281 | the installation locations. | |
282 | ||
283 | `--no-create' | |
284 | `-n' | |
285 | Run the configure checks, but stop before creating any output | |
286 | files. | |
287 | ||
288 | `configure' also accepts some other, not widely useful, options. Run | |
289 | `configure --help' for more details. | |
290 |
0 | SUBDIRS = man | |
1 | ||
2 | bin_PROGRAMS = rendercheck | |
3 | ||
4 | rendercheck_SOURCES = \ | |
5 | main.c \ | |
6 | ops.c \ | |
7 | rendercheck.h \ | |
8 | tests.c \ | |
9 | t_blend.c \ | |
10 | t_bug7366.c \ | |
11 | t_composite.c \ | |
12 | t_dstcoords.c \ | |
13 | t_fill.c \ | |
14 | t_gradient.c \ | |
15 | t_repeat.c \ | |
16 | t_srccoords.c \ | |
17 | t_tsrccoords.c \ | |
18 | t_tsrccoords2.c \ | |
19 | t_triangles.c | |
20 | ||
21 | AM_CFLAGS = $(RC_CFLAGS) $(CWARNFLAGS) | |
22 | rendercheck_LDADD = $(RC_LIBS) | |
23 | ||
24 | MAINTAINERCLEANFILES = ChangeLog INSTALL | |
25 | EXTRA_DIST = \ | |
26 | doc/AddingNewTests \ | |
27 | doc/TODO \ | |
28 | autogen.sh | |
29 | ||
30 | .PHONY: ChangeLog INSTALL | |
31 | ||
32 | INSTALL: | |
33 | $(INSTALL_CMD) | |
34 | ||
35 | ChangeLog: | |
36 | $(CHANGELOG_CMD) | |
37 | ||
38 | dist-hook: ChangeLog INSTALL |
0 | # Makefile.in generated by automake 1.11.1 from Makefile.am. | |
1 | # @configure_input@ | |
2 | ||
3 | # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, | |
4 | # 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, | |
5 | # Inc. | |
6 | # This Makefile.in is free software; the Free Software Foundation | |
7 | # gives unlimited permission to copy and/or distribute it, | |
8 | # with or without modifications, as long as this notice is preserved. | |
9 | ||
10 | # This program is distributed in the hope that it will be useful, | |
11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without | |
12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A | |
13 | # PARTICULAR PURPOSE. | |
14 | ||
15 | @SET_MAKE@ | |
16 | ||
17 | VPATH = @srcdir@ | |
18 | pkgdatadir = $(datadir)/@PACKAGE@ | |
19 | pkgincludedir = $(includedir)/@PACKAGE@ | |
20 | pkglibdir = $(libdir)/@PACKAGE@ | |
21 | pkglibexecdir = $(libexecdir)/@PACKAGE@ | |
22 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd | |
23 | install_sh_DATA = $(install_sh) -c -m 644 | |
24 | install_sh_PROGRAM = $(install_sh) -c | |
25 | install_sh_SCRIPT = $(install_sh) -c | |
26 | INSTALL_HEADER = $(INSTALL_DATA) | |
27 | transform = $(program_transform_name) | |
28 | NORMAL_INSTALL = : | |
29 | PRE_INSTALL = : | |
30 | POST_INSTALL = : | |
31 | NORMAL_UNINSTALL = : | |
32 | PRE_UNINSTALL = : | |
33 | POST_UNINSTALL = : | |
34 | build_triplet = @build@ | |
35 | host_triplet = @host@ | |
36 | bin_PROGRAMS = rendercheck$(EXEEXT) | |
37 | subdir = . | |
38 | DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \ | |
39 | $(srcdir)/Makefile.in $(top_srcdir)/configure AUTHORS COPYING \ | |
40 | ChangeLog INSTALL NEWS config.guess config.sub depcomp \ | |
41 | install-sh missing | |
42 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 | |
43 | am__aclocal_m4_deps = $(top_srcdir)/configure.ac | |
44 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ | |
45 | $(ACLOCAL_M4) | |
46 | am__CONFIG_DISTCLEAN_FILES = config.status config.cache config.log \ | |
47 | configure.lineno config.status.lineno | |
48 | mkinstalldirs = $(install_sh) -d | |
49 | CONFIG_CLEAN_FILES = | |
50 | CONFIG_CLEAN_VPATH_FILES = | |
51 | am__installdirs = "$(DESTDIR)$(bindir)" | |
52 | PROGRAMS = $(bin_PROGRAMS) | |
53 | am_rendercheck_OBJECTS = main.$(OBJEXT) ops.$(OBJEXT) tests.$(OBJEXT) \ | |
54 | t_blend.$(OBJEXT) t_bug7366.$(OBJEXT) t_composite.$(OBJEXT) \ | |
55 | t_dstcoords.$(OBJEXT) t_fill.$(OBJEXT) t_gradient.$(OBJEXT) \ | |
56 | t_repeat.$(OBJEXT) t_srccoords.$(OBJEXT) \ | |
57 | t_tsrccoords.$(OBJEXT) t_tsrccoords2.$(OBJEXT) \ | |
58 | t_triangles.$(OBJEXT) | |
59 | rendercheck_OBJECTS = $(am_rendercheck_OBJECTS) | |
60 | am__DEPENDENCIES_1 = | |
61 | rendercheck_DEPENDENCIES = $(am__DEPENDENCIES_1) | |
62 | DEFAULT_INCLUDES = -I.@am__isrc@ | |
63 | depcomp = $(SHELL) $(top_srcdir)/depcomp | |
64 | am__depfiles_maybe = depfiles | |
65 | am__mv = mv -f | |
66 | COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \ | |
67 | $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) | |
68 | AM_V_CC = $(am__v_CC_$(V)) | |
69 | am__v_CC_ = $(am__v_CC_$(AM_DEFAULT_VERBOSITY)) | |
70 | am__v_CC_0 = @echo " CC " $@; | |
71 | AM_V_at = $(am__v_at_$(V)) | |
72 | am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY)) | |
73 | am__v_at_0 = @ | |
74 | CCLD = $(CC) | |
75 | LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ | |
76 | AM_V_CCLD = $(am__v_CCLD_$(V)) | |
77 | am__v_CCLD_ = $(am__v_CCLD_$(AM_DEFAULT_VERBOSITY)) | |
78 | am__v_CCLD_0 = @echo " CCLD " $@; | |
79 | AM_V_GEN = $(am__v_GEN_$(V)) | |
80 | am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) | |
81 | am__v_GEN_0 = @echo " GEN " $@; | |
82 | SOURCES = $(rendercheck_SOURCES) | |
83 | DIST_SOURCES = $(rendercheck_SOURCES) | |
84 | RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \ | |
85 | html-recursive info-recursive install-data-recursive \ | |
86 | install-dvi-recursive install-exec-recursive \ | |
87 | install-html-recursive install-info-recursive \ | |
88 | install-pdf-recursive install-ps-recursive install-recursive \ | |
89 | installcheck-recursive installdirs-recursive pdf-recursive \ | |
90 | ps-recursive uninstall-recursive | |
91 | RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive \ | |
92 | distclean-recursive maintainer-clean-recursive | |
93 | AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \ | |
94 | $(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \ | |
95 | distdir dist dist-all distcheck | |
96 | ETAGS = etags | |
97 | CTAGS = ctags | |
98 | DIST_SUBDIRS = $(SUBDIRS) | |
99 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) | |
100 | distdir = $(PACKAGE)-$(VERSION) | |
101 | top_distdir = $(distdir) | |
102 | am__remove_distdir = \ | |
103 | { test ! -d "$(distdir)" \ | |
104 | || { find "$(distdir)" -type d ! -perm -200 -exec chmod u+w {} ';' \ | |
105 | && rm -fr "$(distdir)"; }; } | |
106 | am__relativize = \ | |
107 | dir0=`pwd`; \ | |
108 | sed_first='s,^\([^/]*\)/.*$$,\1,'; \ | |
109 | sed_rest='s,^[^/]*/*,,'; \ | |
110 | sed_last='s,^.*/\([^/]*\)$$,\1,'; \ | |
111 | sed_butlast='s,/*[^/]*$$,,'; \ | |
112 | while test -n "$$dir1"; do \ | |
113 | first=`echo "$$dir1" | sed -e "$$sed_first"`; \ | |
114 | if test "$$first" != "."; then \ | |
115 | if test "$$first" = ".."; then \ | |
116 | dir2=`echo "$$dir0" | sed -e "$$sed_last"`/"$$dir2"; \ | |
117 | dir0=`echo "$$dir0" | sed -e "$$sed_butlast"`; \ | |
118 | else \ | |
119 | first2=`echo "$$dir2" | sed -e "$$sed_first"`; \ | |
120 | if test "$$first2" = "$$first"; then \ | |
121 | dir2=`echo "$$dir2" | sed -e "$$sed_rest"`; \ | |
122 | else \ | |
123 | dir2="../$$dir2"; \ | |
124 | fi; \ | |
125 | dir0="$$dir0"/"$$first"; \ | |
126 | fi; \ | |
127 | fi; \ | |
128 | dir1=`echo "$$dir1" | sed -e "$$sed_rest"`; \ | |
129 | done; \ | |
130 | reldir="$$dir2" | |
131 | DIST_ARCHIVES = $(distdir).tar.gz $(distdir).tar.bz2 | |
132 | GZIP_ENV = --best | |
133 | distuninstallcheck_listfiles = find . -type f -print | |
134 | distcleancheck_listfiles = find . -type f -print | |
135 | ACLOCAL = @ACLOCAL@ | |
136 | ADMIN_MAN_DIR = @ADMIN_MAN_DIR@ | |
137 | ADMIN_MAN_SUFFIX = @ADMIN_MAN_SUFFIX@ | |
138 | AMTAR = @AMTAR@ | |
139 | AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ | |
140 | APP_MAN_DIR = @APP_MAN_DIR@ | |
141 | APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ | |
142 | AUTOCONF = @AUTOCONF@ | |
143 | AUTOHEADER = @AUTOHEADER@ | |
144 | AUTOMAKE = @AUTOMAKE@ | |
145 | AWK = @AWK@ | |
146 | CC = @CC@ | |
147 | CCDEPMODE = @CCDEPMODE@ | |
148 | CFLAGS = @CFLAGS@ | |
149 | CHANGELOG_CMD = @CHANGELOG_CMD@ | |
150 | CPP = @CPP@ | |
151 | CPPFLAGS = @CPPFLAGS@ | |
152 | CWARNFLAGS = @CWARNFLAGS@ | |
153 | CYGPATH_W = @CYGPATH_W@ | |
154 | DEFS = @DEFS@ | |
155 | DEPDIR = @DEPDIR@ | |
156 | DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ | |
157 | DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ | |
158 | ECHO_C = @ECHO_C@ | |
159 | ECHO_N = @ECHO_N@ | |
160 | ECHO_T = @ECHO_T@ | |
161 | EGREP = @EGREP@ | |
162 | EXEEXT = @EXEEXT@ | |
163 | FILE_MAN_DIR = @FILE_MAN_DIR@ | |
164 | FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ | |
165 | GREP = @GREP@ | |
166 | INSTALL = @INSTALL@ | |
167 | INSTALL_CMD = @INSTALL_CMD@ | |
168 | INSTALL_DATA = @INSTALL_DATA@ | |
169 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ | |
170 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ | |
171 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ | |
172 | LDFLAGS = @LDFLAGS@ | |
173 | LIBOBJS = @LIBOBJS@ | |
174 | LIBS = @LIBS@ | |
175 | LIB_MAN_DIR = @LIB_MAN_DIR@ | |
176 | LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ | |
177 | LTLIBOBJS = @LTLIBOBJS@ | |
178 | MAINT = @MAINT@ | |
179 | MAKEINFO = @MAKEINFO@ | |
180 | MAN_SUBSTS = @MAN_SUBSTS@ | |
181 | MISC_MAN_DIR = @MISC_MAN_DIR@ | |
182 | MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ | |
183 | MKDIR_P = @MKDIR_P@ | |
184 | OBJEXT = @OBJEXT@ | |
185 | PACKAGE = @PACKAGE@ | |
186 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ | |
187 | PACKAGE_NAME = @PACKAGE_NAME@ | |
188 | PACKAGE_STRING = @PACKAGE_STRING@ | |
189 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ | |
190 | PACKAGE_URL = @PACKAGE_URL@ | |
191 | PACKAGE_VERSION = @PACKAGE_VERSION@ | |
192 | PATH_SEPARATOR = @PATH_SEPARATOR@ | |
193 | PKG_CONFIG = @PKG_CONFIG@ | |
194 | RC_CFLAGS = @RC_CFLAGS@ | |
195 | RC_LIBS = @RC_LIBS@ | |
196 | SED = @SED@ | |
197 | SET_MAKE = @SET_MAKE@ | |
198 | SHELL = @SHELL@ | |
199 | STRIP = @STRIP@ | |
200 | VERSION = @VERSION@ | |
201 | XORG_MAN_PAGE = @XORG_MAN_PAGE@ | |
202 | abs_builddir = @abs_builddir@ | |
203 | abs_srcdir = @abs_srcdir@ | |
204 | abs_top_builddir = @abs_top_builddir@ | |
205 | abs_top_srcdir = @abs_top_srcdir@ | |
206 | ac_ct_CC = @ac_ct_CC@ | |
207 | am__include = @am__include@ | |
208 | am__leading_dot = @am__leading_dot@ | |
209 | am__quote = @am__quote@ | |
210 | am__tar = @am__tar@ | |
211 | am__untar = @am__untar@ | |
212 | bindir = @bindir@ | |
213 | build = @build@ | |
214 | build_alias = @build_alias@ | |
215 | build_cpu = @build_cpu@ | |
216 | build_os = @build_os@ | |
217 | build_vendor = @build_vendor@ | |
218 | builddir = @builddir@ | |
219 | datadir = @datadir@ | |
220 | datarootdir = @datarootdir@ | |
221 | docdir = @docdir@ | |
222 | dvidir = @dvidir@ | |
223 | exec_prefix = @exec_prefix@ | |
224 | host = @host@ | |
225 | host_alias = @host_alias@ | |
226 | host_cpu = @host_cpu@ | |
227 | host_os = @host_os@ | |
228 | host_vendor = @host_vendor@ | |
229 | htmldir = @htmldir@ | |
230 | includedir = @includedir@ | |
231 | infodir = @infodir@ | |
232 | install_sh = @install_sh@ | |
233 | libdir = @libdir@ | |
234 | libexecdir = @libexecdir@ | |
235 | localedir = @localedir@ | |
236 | localstatedir = @localstatedir@ | |
237 | mandir = @mandir@ | |
238 | mkdir_p = @mkdir_p@ | |
239 | oldincludedir = @oldincludedir@ | |
240 | pdfdir = @pdfdir@ | |
241 | prefix = @prefix@ | |
242 | program_transform_name = @program_transform_name@ | |
243 | psdir = @psdir@ | |
244 | sbindir = @sbindir@ | |
245 | sharedstatedir = @sharedstatedir@ | |
246 | srcdir = @srcdir@ | |
247 | sysconfdir = @sysconfdir@ | |
248 | target_alias = @target_alias@ | |
249 | top_build_prefix = @top_build_prefix@ | |
250 | top_builddir = @top_builddir@ | |
251 | top_srcdir = @top_srcdir@ | |
252 | SUBDIRS = man | |
253 | rendercheck_SOURCES = \ | |
254 | main.c \ | |
255 | ops.c \ | |
256 | rendercheck.h \ | |
257 | tests.c \ | |
258 | t_blend.c \ | |
259 | t_bug7366.c \ | |
260 | t_composite.c \ | |
261 | t_dstcoords.c \ | |
262 | t_fill.c \ | |
263 | t_gradient.c \ | |
264 | t_repeat.c \ | |
265 | t_srccoords.c \ | |
266 | t_tsrccoords.c \ | |
267 | t_tsrccoords2.c \ | |
268 | t_triangles.c | |
269 | ||
270 | AM_CFLAGS = $(RC_CFLAGS) $(CWARNFLAGS) | |
271 | rendercheck_LDADD = $(RC_LIBS) | |
272 | MAINTAINERCLEANFILES = ChangeLog INSTALL | |
273 | EXTRA_DIST = \ | |
274 | doc/AddingNewTests \ | |
275 | doc/TODO \ | |
276 | autogen.sh | |
277 | ||
278 | all: all-recursive | |
279 | ||
280 | .SUFFIXES: | |
281 | .SUFFIXES: .c .o .obj | |
282 | am--refresh: | |
283 | @: | |
284 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) | |
285 | @for dep in $?; do \ | |
286 | case '$(am__configure_deps)' in \ | |
287 | *$$dep*) \ | |
288 | echo ' cd $(srcdir) && $(AUTOMAKE) --foreign'; \ | |
289 | $(am__cd) $(srcdir) && $(AUTOMAKE) --foreign \ | |
290 | && exit 0; \ | |
291 | exit 1;; \ | |
292 | esac; \ | |
293 | done; \ | |
294 | echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign Makefile'; \ | |
295 | $(am__cd) $(top_srcdir) && \ | |
296 | $(AUTOMAKE) --foreign Makefile | |
297 | .PRECIOUS: Makefile | |
298 | Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status | |
299 | @case '$?' in \ | |
300 | *config.status*) \ | |
301 | echo ' $(SHELL) ./config.status'; \ | |
302 | $(SHELL) ./config.status;; \ | |
303 | *) \ | |
304 | echo ' cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe)'; \ | |
305 | cd $(top_builddir) && $(SHELL) ./config.status $@ $(am__depfiles_maybe);; \ | |
306 | esac; | |
307 | ||
308 | $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) | |
309 | $(SHELL) ./config.status --recheck | |
310 | ||
311 | $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) | |
312 | $(am__cd) $(srcdir) && $(AUTOCONF) | |
313 | $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) | |
314 | $(am__cd) $(srcdir) && $(ACLOCAL) $(ACLOCAL_AMFLAGS) | |
315 | $(am__aclocal_m4_deps): | |
316 | install-binPROGRAMS: $(bin_PROGRAMS) | |
317 | @$(NORMAL_INSTALL) | |
318 | test -z "$(bindir)" || $(MKDIR_P) "$(DESTDIR)$(bindir)" | |
319 | @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ | |
320 | for p in $$list; do echo "$$p $$p"; done | \ | |
321 | sed 's/$(EXEEXT)$$//' | \ | |
322 | while read p p1; do if test -f $$p; \ | |
323 | then echo "$$p"; echo "$$p"; else :; fi; \ | |
324 | done | \ | |
325 | sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \ | |
326 | -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \ | |
327 | sed 'N;N;N;s,\n, ,g' | \ | |
328 | $(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \ | |
329 | { d=$$3; if (dirs[d] != 1) { print "d", d; dirs[d] = 1 } \ | |
330 | if ($$2 == $$4) files[d] = files[d] " " $$1; \ | |
331 | else { print "f", $$3 "/" $$4, $$1; } } \ | |
332 | END { for (d in files) print "f", d, files[d] }' | \ | |
333 | while read type dir files; do \ | |
334 | if test "$$dir" = .; then dir=; else dir=/$$dir; fi; \ | |
335 | test -z "$$files" || { \ | |
336 | echo " $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files '$(DESTDIR)$(bindir)$$dir'"; \ | |
337 | $(INSTALL_PROGRAM_ENV) $(INSTALL_PROGRAM) $$files "$(DESTDIR)$(bindir)$$dir" || exit $$?; \ | |
338 | } \ | |
339 | ; done | |
340 | ||
341 | uninstall-binPROGRAMS: | |
342 | @$(NORMAL_UNINSTALL) | |
343 | @list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \ | |
344 | files=`for p in $$list; do echo "$$p"; done | \ | |
345 | sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \ | |
346 | -e 's/$$/$(EXEEXT)/' `; \ | |
347 | test -n "$$list" || exit 0; \ | |
348 | echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \ | |
349 | cd "$(DESTDIR)$(bindir)" && rm -f $$files | |
350 | ||
351 | clean-binPROGRAMS: | |
352 | -test -z "$(bin_PROGRAMS)" || rm -f $(bin_PROGRAMS) | |
353 | rendercheck$(EXEEXT): $(rendercheck_OBJECTS) $(rendercheck_DEPENDENCIES) | |
354 | @rm -f rendercheck$(EXEEXT) | |
355 | $(AM_V_CCLD)$(LINK) $(rendercheck_OBJECTS) $(rendercheck_LDADD) $(LIBS) | |
356 | ||
357 | mostlyclean-compile: | |
358 | -rm -f *.$(OBJEXT) | |
359 | ||
360 | distclean-compile: | |
361 | -rm -f *.tab.c | |
362 | ||
363 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/main.Po@am__quote@ | |
364 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ops.Po@am__quote@ | |
365 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_blend.Po@am__quote@ | |
366 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_bug7366.Po@am__quote@ | |
367 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_composite.Po@am__quote@ | |
368 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_dstcoords.Po@am__quote@ | |
369 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_fill.Po@am__quote@ | |
370 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_gradient.Po@am__quote@ | |
371 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_repeat.Po@am__quote@ | |
372 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_srccoords.Po@am__quote@ | |
373 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_triangles.Po@am__quote@ | |
374 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_tsrccoords.Po@am__quote@ | |
375 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/t_tsrccoords2.Po@am__quote@ | |
376 | @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/tests.Po@am__quote@ | |
377 | ||
378 | .c.o: | |
379 | @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $< | |
380 | @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po | |
381 | @am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@ | |
382 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ | |
383 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ | |
384 | @am__fastdepCC_FALSE@ $(COMPILE) -c $< | |
385 | ||
386 | .c.obj: | |
387 | @am__fastdepCC_TRUE@ $(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'` | |
388 | @am__fastdepCC_TRUE@ $(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po | |
389 | @am__fastdepCC_FALSE@ $(AM_V_CC) @AM_BACKSLASH@ | |
390 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ source='$<' object='$@' libtool=no @AMDEPBACKSLASH@ | |
391 | @AMDEP_TRUE@@am__fastdepCC_FALSE@ DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@ | |
392 | @am__fastdepCC_FALSE@ $(COMPILE) -c `$(CYGPATH_W) '$<'` | |
393 | ||
394 | # This directory's subdirectories are mostly independent; you can cd | |
395 | # into them and run `make' without going through this Makefile. | |
396 | # To change the values of `make' variables: instead of editing Makefiles, | |
397 | # (1) if the variable is set in `config.status', edit `config.status' | |
398 | # (which will cause the Makefiles to be regenerated when you run `make'); | |
399 | # (2) otherwise, pass the desired values on the `make' command line. | |
400 | $(RECURSIVE_TARGETS): | |
401 | @fail= failcom='exit 1'; \ | |
402 | for f in x $$MAKEFLAGS; do \ | |
403 | case $$f in \ | |
404 | *=* | --[!k]*);; \ | |
405 | *k*) failcom='fail=yes';; \ | |
406 | esac; \ | |
407 | done; \ | |
408 | dot_seen=no; \ | |
409 | target=`echo $@ | sed s/-recursive//`; \ | |
410 | list='$(SUBDIRS)'; for subdir in $$list; do \ | |
411 | echo "Making $$target in $$subdir"; \ | |
412 | if test "$$subdir" = "."; then \ | |
413 | dot_seen=yes; \ | |
414 | local_target="$$target-am"; \ | |
415 | else \ | |
416 | local_target="$$target"; \ | |
417 | fi; \ | |
418 | ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ | |
419 | || eval $$failcom; \ | |
420 | done; \ | |
421 | if test "$$dot_seen" = "no"; then \ | |
422 | $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \ | |
423 | fi; test -z "$$fail" | |
424 | ||
425 | $(RECURSIVE_CLEAN_TARGETS): | |
426 | @fail= failcom='exit 1'; \ | |
427 | for f in x $$MAKEFLAGS; do \ | |
428 | case $$f in \ | |
429 | *=* | --[!k]*);; \ | |
430 | *k*) failcom='fail=yes';; \ | |
431 | esac; \ | |
432 | done; \ | |
433 | dot_seen=no; \ | |
434 | case "$@" in \ | |
435 | distclean-* | maintainer-clean-*) list='$(DIST_SUBDIRS)' ;; \ | |
436 | *) list='$(SUBDIRS)' ;; \ | |
437 | esac; \ | |
438 | rev=''; for subdir in $$list; do \ | |
439 | if test "$$subdir" = "."; then :; else \ | |
440 | rev="$$subdir $$rev"; \ | |
441 | fi; \ | |
442 | done; \ | |
443 | rev="$$rev ."; \ | |
444 | target=`echo $@ | sed s/-recursive//`; \ | |
445 | for subdir in $$rev; do \ | |
446 | echo "Making $$target in $$subdir"; \ | |
447 | if test "$$subdir" = "."; then \ | |
448 | local_target="$$target-am"; \ | |
449 | else \ | |
450 | local_target="$$target"; \ | |
451 | fi; \ | |
452 | ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$local_target) \ | |
453 | || eval $$failcom; \ | |
454 | done && test -z "$$fail" | |
455 | tags-recursive: | |
456 | list='$(SUBDIRS)'; for subdir in $$list; do \ | |
457 | test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \ | |
458 | done | |
459 | ctags-recursive: | |
460 | list='$(SUBDIRS)'; for subdir in $$list; do \ | |
461 | test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \ | |
462 | done | |
463 | ||
464 | ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES) | |
465 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ | |
466 | unique=`for i in $$list; do \ | |
467 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ | |
468 | done | \ | |
469 | $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ | |
470 | END { if (nonempty) { for (i in files) print i; }; }'`; \ | |
471 | mkid -fID $$unique | |
472 | tags: TAGS | |
473 | ||
474 | TAGS: tags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ | |
475 | $(TAGS_FILES) $(LISP) | |
476 | set x; \ | |
477 | here=`pwd`; \ | |
478 | if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \ | |
479 | include_option=--etags-include; \ | |
480 | empty_fix=.; \ | |
481 | else \ | |
482 | include_option=--include; \ | |
483 | empty_fix=; \ | |
484 | fi; \ | |
485 | list='$(SUBDIRS)'; for subdir in $$list; do \ | |
486 | if test "$$subdir" = .; then :; else \ | |
487 | test ! -f $$subdir/TAGS || \ | |
488 | set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \ | |
489 | fi; \ | |
490 | done; \ | |
491 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ | |
492 | unique=`for i in $$list; do \ | |
493 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ | |
494 | done | \ | |
495 | $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ | |
496 | END { if (nonempty) { for (i in files) print i; }; }'`; \ | |
497 | shift; \ | |
498 | if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \ | |
499 | test -n "$$unique" || unique=$$empty_fix; \ | |
500 | if test $$# -gt 0; then \ | |
501 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ | |
502 | "$$@" $$unique; \ | |
503 | else \ | |
504 | $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \ | |
505 | $$unique; \ | |
506 | fi; \ | |
507 | fi | |
508 | ctags: CTAGS | |
509 | CTAGS: ctags-recursive $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \ | |
510 | $(TAGS_FILES) $(LISP) | |
511 | list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \ | |
512 | unique=`for i in $$list; do \ | |
513 | if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \ | |
514 | done | \ | |
515 | $(AWK) '{ files[$$0] = 1; nonempty = 1; } \ | |
516 | END { if (nonempty) { for (i in files) print i; }; }'`; \ | |
517 | test -z "$(CTAGS_ARGS)$$unique" \ | |
518 | || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \ | |
519 | $$unique | |
520 | ||
521 | GTAGS: | |
522 | here=`$(am__cd) $(top_builddir) && pwd` \ | |
523 | && $(am__cd) $(top_srcdir) \ | |
524 | && gtags -i $(GTAGS_ARGS) "$$here" | |
525 | ||
526 | distclean-tags: | |
527 | -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags | |
528 | ||
529 | distdir: $(DISTFILES) | |
530 | $(am__remove_distdir) | |
531 | test -d "$(distdir)" || mkdir "$(distdir)" | |
532 | @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ | |
533 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ | |
534 | list='$(DISTFILES)'; \ | |
535 | dist_files=`for file in $$list; do echo $$file; done | \ | |
536 | sed -e "s|^$$srcdirstrip/||;t" \ | |
537 | -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ | |
538 | case $$dist_files in \ | |
539 | */*) $(MKDIR_P) `echo "$$dist_files" | \ | |
540 | sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ | |
541 | sort -u` ;; \ | |
542 | esac; \ | |
543 | for file in $$dist_files; do \ | |
544 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ | |
545 | if test -d $$d/$$file; then \ | |
546 | dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ | |
547 | if test -d "$(distdir)/$$file"; then \ | |
548 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ | |
549 | fi; \ | |
550 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ | |
551 | cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ | |
552 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ | |
553 | fi; \ | |
554 | cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ | |
555 | else \ | |
556 | test -f "$(distdir)/$$file" \ | |
557 | || cp -p $$d/$$file "$(distdir)/$$file" \ | |
558 | || exit 1; \ | |
559 | fi; \ | |
560 | done | |
561 | @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ | |
562 | if test "$$subdir" = .; then :; else \ | |
563 | test -d "$(distdir)/$$subdir" \ | |
564 | || $(MKDIR_P) "$(distdir)/$$subdir" \ | |
565 | || exit 1; \ | |
566 | fi; \ | |
567 | done | |
568 | @list='$(DIST_SUBDIRS)'; for subdir in $$list; do \ | |
569 | if test "$$subdir" = .; then :; else \ | |
570 | dir1=$$subdir; dir2="$(distdir)/$$subdir"; \ | |
571 | $(am__relativize); \ | |
572 | new_distdir=$$reldir; \ | |
573 | dir1=$$subdir; dir2="$(top_distdir)"; \ | |
574 | $(am__relativize); \ | |
575 | new_top_distdir=$$reldir; \ | |
576 | echo " (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) top_distdir="$$new_top_distdir" distdir="$$new_distdir" \\"; \ | |
577 | echo " am__remove_distdir=: am__skip_length_check=: am__skip_mode_fix=: distdir)"; \ | |
578 | ($(am__cd) $$subdir && \ | |
579 | $(MAKE) $(AM_MAKEFLAGS) \ | |
580 | top_distdir="$$new_top_distdir" \ | |
581 | distdir="$$new_distdir" \ | |
582 | am__remove_distdir=: \ | |
583 | am__skip_length_check=: \ | |
584 | am__skip_mode_fix=: \ | |
585 | distdir) \ | |
586 | || exit 1; \ | |
587 | fi; \ | |
588 | done | |
589 | $(MAKE) $(AM_MAKEFLAGS) \ | |
590 | top_distdir="$(top_distdir)" distdir="$(distdir)" \ | |
591 | dist-hook | |
592 | -test -n "$(am__skip_mode_fix)" \ | |
593 | || find "$(distdir)" -type d ! -perm -755 \ | |
594 | -exec chmod u+rwx,go+rx {} \; -o \ | |
595 | ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \ | |
596 | ! -type d ! -perm -400 -exec chmod a+r {} \; -o \ | |
597 | ! -type d ! -perm -444 -exec $(install_sh) -c -m a+r {} {} \; \ | |
598 | || chmod -R a+r "$(distdir)" | |
599 | dist-gzip: distdir | |
600 | tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz | |
601 | $(am__remove_distdir) | |
602 | dist-bzip2: distdir | |
603 | tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 | |
604 | $(am__remove_distdir) | |
605 | ||
606 | dist-lzma: distdir | |
607 | tardir=$(distdir) && $(am__tar) | lzma -9 -c >$(distdir).tar.lzma | |
608 | $(am__remove_distdir) | |
609 | ||
610 | dist-xz: distdir | |
611 | tardir=$(distdir) && $(am__tar) | xz -c >$(distdir).tar.xz | |
612 | $(am__remove_distdir) | |
613 | ||
614 | dist-tarZ: distdir | |
615 | tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z | |
616 | $(am__remove_distdir) | |
617 | ||
618 | dist-shar: distdir | |
619 | shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz | |
620 | $(am__remove_distdir) | |
621 | ||
622 | dist-zip: distdir | |
623 | -rm -f $(distdir).zip | |
624 | zip -rq $(distdir).zip $(distdir) | |
625 | $(am__remove_distdir) | |
626 | ||
627 | dist dist-all: distdir | |
628 | tardir=$(distdir) && $(am__tar) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).tar.gz | |
629 | tardir=$(distdir) && $(am__tar) | bzip2 -9 -c >$(distdir).tar.bz2 | |
630 | $(am__remove_distdir) | |
631 | ||
632 | # This target untars the dist file and tries a VPATH configuration. Then | |
633 | # it guarantees that the distribution is self-contained by making another | |
634 | # tarfile. | |
635 | distcheck: dist | |
636 | case '$(DIST_ARCHIVES)' in \ | |
637 | *.tar.gz*) \ | |
638 | GZIP=$(GZIP_ENV) gzip -dc $(distdir).tar.gz | $(am__untar) ;;\ | |
639 | *.tar.bz2*) \ | |
640 | bzip2 -dc $(distdir).tar.bz2 | $(am__untar) ;;\ | |
641 | *.tar.lzma*) \ | |
642 | lzma -dc $(distdir).tar.lzma | $(am__untar) ;;\ | |
643 | *.tar.xz*) \ | |
644 | xz -dc $(distdir).tar.xz | $(am__untar) ;;\ | |
645 | *.tar.Z*) \ | |
646 | uncompress -c $(distdir).tar.Z | $(am__untar) ;;\ | |
647 | *.shar.gz*) \ | |
648 | GZIP=$(GZIP_ENV) gzip -dc $(distdir).shar.gz | unshar ;;\ | |
649 | *.zip*) \ | |
650 | unzip $(distdir).zip ;;\ | |
651 | esac | |
652 | chmod -R a-w $(distdir); chmod a+w $(distdir) | |
653 | mkdir $(distdir)/_build | |
654 | mkdir $(distdir)/_inst | |
655 | chmod a-w $(distdir) | |
656 | test -d $(distdir)/_build || exit 0; \ | |
657 | dc_install_base=`$(am__cd) $(distdir)/_inst && pwd | sed -e 's,^[^:\\/]:[\\/],/,'` \ | |
658 | && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \ | |
659 | && am__cwd=`pwd` \ | |
660 | && $(am__cd) $(distdir)/_build \ | |
661 | && ../configure --srcdir=.. --prefix="$$dc_install_base" \ | |
662 | $(DISTCHECK_CONFIGURE_FLAGS) \ | |
663 | && $(MAKE) $(AM_MAKEFLAGS) \ | |
664 | && $(MAKE) $(AM_MAKEFLAGS) dvi \ | |
665 | && $(MAKE) $(AM_MAKEFLAGS) check \ | |
666 | && $(MAKE) $(AM_MAKEFLAGS) install \ | |
667 | && $(MAKE) $(AM_MAKEFLAGS) installcheck \ | |
668 | && $(MAKE) $(AM_MAKEFLAGS) uninstall \ | |
669 | && $(MAKE) $(AM_MAKEFLAGS) distuninstallcheck_dir="$$dc_install_base" \ | |
670 | distuninstallcheck \ | |
671 | && chmod -R a-w "$$dc_install_base" \ | |
672 | && ({ \ | |
673 | (cd ../.. && umask 077 && mkdir "$$dc_destdir") \ | |
674 | && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" install \ | |
675 | && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" uninstall \ | |
676 | && $(MAKE) $(AM_MAKEFLAGS) DESTDIR="$$dc_destdir" \ | |
677 | distuninstallcheck_dir="$$dc_destdir" distuninstallcheck; \ | |
678 | } || { rm -rf "$$dc_destdir"; exit 1; }) \ | |
679 | && rm -rf "$$dc_destdir" \ | |
680 | && $(MAKE) $(AM_MAKEFLAGS) dist \ | |
681 | && rm -rf $(DIST_ARCHIVES) \ | |
682 | && $(MAKE) $(AM_MAKEFLAGS) distcleancheck \ | |
683 | && cd "$$am__cwd" \ | |
684 | || exit 1 | |
685 | $(am__remove_distdir) | |
686 | @(echo "$(distdir) archives ready for distribution: "; \ | |
687 | list='$(DIST_ARCHIVES)'; for i in $$list; do echo $$i; done) | \ | |
688 | sed -e 1h -e 1s/./=/g -e 1p -e 1x -e '$$p' -e '$$x' | |
689 | distuninstallcheck: | |
690 | @$(am__cd) '$(distuninstallcheck_dir)' \ | |
691 | && test `$(distuninstallcheck_listfiles) | wc -l` -le 1 \ | |
692 | || { echo "ERROR: files left after uninstall:" ; \ | |
693 | if test -n "$(DESTDIR)"; then \ | |
694 | echo " (check DESTDIR support)"; \ | |
695 | fi ; \ | |
696 | $(distuninstallcheck_listfiles) ; \ | |
697 | exit 1; } >&2 | |
698 | distcleancheck: distclean | |
699 | @if test '$(srcdir)' = . ; then \ | |
700 | echo "ERROR: distcleancheck can only run from a VPATH build" ; \ | |
701 | exit 1 ; \ | |
702 | fi | |
703 | @test `$(distcleancheck_listfiles) | wc -l` -eq 0 \ | |
704 | || { echo "ERROR: files left in build directory after distclean:" ; \ | |
705 | $(distcleancheck_listfiles) ; \ | |
706 | exit 1; } >&2 | |
707 | check-am: all-am | |
708 | check: check-recursive | |
709 | all-am: Makefile $(PROGRAMS) | |
710 | installdirs: installdirs-recursive | |
711 | installdirs-am: | |
712 | for dir in "$(DESTDIR)$(bindir)"; do \ | |
713 | test -z "$$dir" || $(MKDIR_P) "$$dir"; \ | |
714 | done | |
715 | install: install-recursive | |
716 | install-exec: install-exec-recursive | |
717 | install-data: install-data-recursive | |
718 | uninstall: uninstall-recursive | |
719 | ||
720 | install-am: all-am | |
721 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am | |
722 | ||
723 | installcheck: installcheck-recursive | |
724 | install-strip: | |
725 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ | |
726 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ | |
727 | `test -z '$(STRIP)' || \ | |
728 | echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install | |
729 | mostlyclean-generic: | |
730 | ||
731 | clean-generic: | |
732 | ||
733 | distclean-generic: | |
734 | -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) | |
735 | -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) | |
736 | ||
737 | maintainer-clean-generic: | |
738 | @echo "This command is intended for maintainers to use" | |
739 | @echo "it deletes files that may require special tools to rebuild." | |
740 | -test -z "$(MAINTAINERCLEANFILES)" || rm -f $(MAINTAINERCLEANFILES) | |
741 | clean: clean-recursive | |
742 | ||
743 | clean-am: clean-binPROGRAMS clean-generic mostlyclean-am | |
744 | ||
745 | distclean: distclean-recursive | |
746 | -rm -f $(am__CONFIG_DISTCLEAN_FILES) | |
747 | -rm -rf ./$(DEPDIR) | |
748 | -rm -f Makefile | |
749 | distclean-am: clean-am distclean-compile distclean-generic \ | |
750 | distclean-tags | |
751 | ||
752 | dvi: dvi-recursive | |
753 | ||
754 | dvi-am: | |
755 | ||
756 | html: html-recursive | |
757 | ||
758 | html-am: | |
759 | ||
760 | info: info-recursive | |
761 | ||
762 | info-am: | |
763 | ||
764 | install-data-am: | |
765 | ||
766 | install-dvi: install-dvi-recursive | |
767 | ||
768 | install-dvi-am: | |
769 | ||
770 | install-exec-am: install-binPROGRAMS | |
771 | ||
772 | install-html: install-html-recursive | |
773 | ||
774 | install-html-am: | |
775 | ||
776 | install-info: install-info-recursive | |
777 | ||
778 | install-info-am: | |
779 | ||
780 | install-man: | |
781 | ||
782 | install-pdf: install-pdf-recursive | |
783 | ||
784 | install-pdf-am: | |
785 | ||
786 | install-ps: install-ps-recursive | |
787 | ||
788 | install-ps-am: | |
789 | ||
790 | installcheck-am: | |
791 | ||
792 | maintainer-clean: maintainer-clean-recursive | |
793 | -rm -f $(am__CONFIG_DISTCLEAN_FILES) | |
794 | -rm -rf $(top_srcdir)/autom4te.cache | |
795 | -rm -rf ./$(DEPDIR) | |
796 | -rm -f Makefile | |
797 | maintainer-clean-am: distclean-am maintainer-clean-generic | |
798 | ||
799 | mostlyclean: mostlyclean-recursive | |
800 | ||
801 | mostlyclean-am: mostlyclean-compile mostlyclean-generic | |
802 | ||
803 | pdf: pdf-recursive | |
804 | ||
805 | pdf-am: | |
806 | ||
807 | ps: ps-recursive | |
808 | ||
809 | ps-am: | |
810 | ||
811 | uninstall-am: uninstall-binPROGRAMS | |
812 | ||
813 | .MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) ctags-recursive \ | |
814 | install-am install-strip tags-recursive | |
815 | ||
816 | .PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \ | |
817 | all all-am am--refresh check check-am clean clean-binPROGRAMS \ | |
818 | clean-generic ctags ctags-recursive dist dist-all dist-bzip2 \ | |
819 | dist-gzip dist-hook dist-lzma dist-shar dist-tarZ dist-xz \ | |
820 | dist-zip distcheck distclean distclean-compile \ | |
821 | distclean-generic distclean-tags distcleancheck distdir \ | |
822 | distuninstallcheck dvi dvi-am html html-am info info-am \ | |
823 | install install-am install-binPROGRAMS install-data \ | |
824 | install-data-am install-dvi install-dvi-am install-exec \ | |
825 | install-exec-am install-html install-html-am install-info \ | |
826 | install-info-am install-man install-pdf install-pdf-am \ | |
827 | install-ps install-ps-am install-strip installcheck \ | |
828 | installcheck-am installdirs installdirs-am maintainer-clean \ | |
829 | maintainer-clean-generic mostlyclean mostlyclean-compile \ | |
830 | mostlyclean-generic pdf pdf-am ps ps-am tags tags-recursive \ | |
831 | uninstall uninstall-am uninstall-binPROGRAMS | |
832 | ||
833 | ||
834 | .PHONY: ChangeLog INSTALL | |
835 | ||
836 | INSTALL: | |
837 | $(INSTALL_CMD) | |
838 | ||
839 | ChangeLog: | |
840 | $(CHANGELOG_CMD) | |
841 | ||
842 | dist-hook: ChangeLog INSTALL | |
843 | ||
844 | # Tell versions [3.59,3.63) of GNU make to not export all variables. | |
845 | # Otherwise a system limit (for SysV at least) may be exceeded. | |
846 | .NOEXPORT: |
0 | 2006-11-27: | |
1 | Version 1.2 released | |
2 | Adds test for bug #7366 | |
3 | Tests against more picture formats. | |
4 | Allows testing against a subset of the operators and formats. | |
5 | ||
6 | 2006-05-22: | |
7 | Version 1.1 released. | |
8 | Adds tests for triangles, gradients, and repeating sources. | |
9 | Fixes a major memory leak. | |
10 | Allow run-time selection of the set of tests to be run. | |
11 | Add a manpage. | |
12 | ||
13 | 2004-10-24: | |
14 | Version 1.0.3 released. | |
15 | Allows building on systems without xrender.pc. | |
16 | ||
17 | 2004-09-19: | |
18 | Version 1.0.2 released. | |
19 | Adds a transformed coordinates test. | |
20 | ||
21 | 2004-05-17: | |
22 | Version 1.0.1 released. | |
23 | Makes the fill test useful and adds a destination coordinates test. | |
24 | ||
25 | 2004-05-10: | |
26 | Initial version 1.0 imported. |
0 | rendercheck is a program to test a Render extension implementation against | |
1 | separate calculations of expected output. | |
2 | ||
3 | Tests currently include: | |
4 | - Destination coordinates correctness | |
5 | - Source coordinates correctness | |
6 | - Transformed (FilterNearest) source coordinates correctness. | |
7 | - Composite with and without mask (with/without component alpha), with 1x1 | |
8 | repeating Pictures and 10x10 Pictures. | |
9 | - Linear gradients | |
10 | - Repeating sources/masks at POT and non-POT sizes | |
11 | - Some regression tests for bugs from freedesktop.org bugzilla. |
0 | # generated automatically by aclocal 1.11.1 -*- Autoconf -*- | |
1 | ||
2 | # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, | |
3 | # 2005, 2006, 2007, 2008, 2009 Free Software Foundation, Inc. | |
4 | # This file is free software; the Free Software Foundation | |
5 | # gives unlimited permission to copy and/or distribute it, | |
6 | # with or without modifications, as long as this notice is preserved. | |
7 | ||
8 | # This program is distributed in the hope that it will be useful, | |
9 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without | |
10 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A | |
11 | # PARTICULAR PURPOSE. | |
12 | ||
13 | m4_ifndef([AC_AUTOCONF_VERSION], | |
14 | [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl | |
15 | m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.68],, | |
16 | [m4_warning([this file was generated for autoconf 2.68. | |
17 | You have another version of autoconf. It may work, but is not guaranteed to. | |
18 | If you have problems, you may need to regenerate the build system entirely. | |
19 | To do so, use the procedure documented by the package, typically `autoreconf'.])]) | |
20 | ||
21 | # Copyright (C) 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. | |
22 | # | |
23 | # This file is free software; the Free Software Foundation | |
24 | # gives unlimited permission to copy and/or distribute it, | |
25 | # with or without modifications, as long as this notice is preserved. | |
26 | ||
27 | # AM_AUTOMAKE_VERSION(VERSION) | |
28 | # ---------------------------- | |
29 | # Automake X.Y traces this macro to ensure aclocal.m4 has been | |
30 | # generated from the m4 files accompanying Automake X.Y. | |
31 | # (This private macro should not be called outside this file.) | |
32 | AC_DEFUN([AM_AUTOMAKE_VERSION], | |
33 | [am__api_version='1.11' | |
34 | dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to | |
35 | dnl require some minimum version. Point them to the right macro. | |
36 | m4_if([$1], [1.11.1], [], | |
37 | [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl | |
38 | ]) | |
39 | ||
40 | # _AM_AUTOCONF_VERSION(VERSION) | |
41 | # ----------------------------- | |
42 | # aclocal traces this macro to find the Autoconf version. | |
43 | # This is a private macro too. Using m4_define simplifies | |
44 | # the logic in aclocal, which can simply ignore this definition. | |
45 | m4_define([_AM_AUTOCONF_VERSION], []) | |
46 | ||
47 | # AM_SET_CURRENT_AUTOMAKE_VERSION | |
48 | # ------------------------------- | |
49 | # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced. | |
50 | # This function is AC_REQUIREd by AM_INIT_AUTOMAKE. | |
51 | AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION], | |
52 | [AM_AUTOMAKE_VERSION([1.11.1])dnl | |
53 | m4_ifndef([AC_AUTOCONF_VERSION], | |
54 | [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl | |
55 | _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))]) | |
56 | ||
57 | # AM_AUX_DIR_EXPAND -*- Autoconf -*- | |
58 | ||
59 | # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. | |
60 | # | |
61 | # This file is free software; the Free Software Foundation | |
62 | # gives unlimited permission to copy and/or distribute it, | |
63 | # with or without modifications, as long as this notice is preserved. | |
64 | ||
65 | # For projects using AC_CONFIG_AUX_DIR([foo]), Autoconf sets | |
66 | # $ac_aux_dir to `$srcdir/foo'. In other projects, it is set to | |
67 | # `$srcdir', `$srcdir/..', or `$srcdir/../..'. | |
68 | # | |
69 | # Of course, Automake must honor this variable whenever it calls a | |
70 | # tool from the auxiliary directory. The problem is that $srcdir (and | |
71 | # therefore $ac_aux_dir as well) can be either absolute or relative, | |
72 | # depending on how configure is run. This is pretty annoying, since | |
73 | # it makes $ac_aux_dir quite unusable in subdirectories: in the top | |
74 | # source directory, any form will work fine, but in subdirectories a | |
75 | # relative path needs to be adjusted first. | |
76 | # | |
77 | # $ac_aux_dir/missing | |
78 | # fails when called from a subdirectory if $ac_aux_dir is relative | |
79 | # $top_srcdir/$ac_aux_dir/missing | |
80 | # fails if $ac_aux_dir is absolute, | |
81 | # fails when called from a subdirectory in a VPATH build with | |
82 | # a relative $ac_aux_dir | |
83 | # | |
84 | # The reason of the latter failure is that $top_srcdir and $ac_aux_dir | |
85 | # are both prefixed by $srcdir. In an in-source build this is usually | |
86 | # harmless because $srcdir is `.', but things will broke when you | |
87 | # start a VPATH build or use an absolute $srcdir. | |
88 | # | |
89 | # So we could use something similar to $top_srcdir/$ac_aux_dir/missing, | |
90 | # iff we strip the leading $srcdir from $ac_aux_dir. That would be: | |
91 | # am_aux_dir='\$(top_srcdir)/'`expr "$ac_aux_dir" : "$srcdir//*\(.*\)"` | |
92 | # and then we would define $MISSING as | |
93 | # MISSING="\${SHELL} $am_aux_dir/missing" | |
94 | # This will work as long as MISSING is not called from configure, because | |
95 | # unfortunately $(top_srcdir) has no meaning in configure. | |
96 | # However there are other variables, like CC, which are often used in | |
97 | # configure, and could therefore not use this "fixed" $ac_aux_dir. | |
98 | # | |
99 | # Another solution, used here, is to always expand $ac_aux_dir to an | |
100 | # absolute PATH. The drawback is that using absolute paths prevent a | |
101 | # configured tree to be moved without reconfiguration. | |
102 | ||
103 | AC_DEFUN([AM_AUX_DIR_EXPAND], | |
104 | [dnl Rely on autoconf to set up CDPATH properly. | |
105 | AC_PREREQ([2.50])dnl | |
106 | # expand $ac_aux_dir to an absolute path | |
107 | am_aux_dir=`cd $ac_aux_dir && pwd` | |
108 | ]) | |
109 | ||
110 | # AM_CONDITIONAL -*- Autoconf -*- | |
111 | ||
112 | # Copyright (C) 1997, 2000, 2001, 2003, 2004, 2005, 2006, 2008 | |
113 | # Free Software Foundation, Inc. | |
114 | # | |
115 | # This file is free software; the Free Software Foundation | |
116 | # gives unlimited permission to copy and/or distribute it, | |
117 | # with or without modifications, as long as this notice is preserved. | |
118 | ||
119 | # serial 9 | |
120 | ||
121 | # AM_CONDITIONAL(NAME, SHELL-CONDITION) | |
122 | # ------------------------------------- | |
123 | # Define a conditional. | |
124 | AC_DEFUN([AM_CONDITIONAL], | |
125 | [AC_PREREQ(2.52)dnl | |
126 | ifelse([$1], [TRUE], [AC_FATAL([$0: invalid condition: $1])], | |
127 | [$1], [FALSE], [AC_FATAL([$0: invalid condition: $1])])dnl | |
128 | AC_SUBST([$1_TRUE])dnl | |
129 | AC_SUBST([$1_FALSE])dnl | |
130 | _AM_SUBST_NOTMAKE([$1_TRUE])dnl | |
131 | _AM_SUBST_NOTMAKE([$1_FALSE])dnl | |
132 | m4_define([_AM_COND_VALUE_$1], [$2])dnl | |
133 | if $2; then | |
134 | $1_TRUE= | |
135 | $1_FALSE='#' | |
136 | else | |
137 | $1_TRUE='#' | |
138 | $1_FALSE= | |
139 | fi | |
140 | AC_CONFIG_COMMANDS_PRE( | |
141 | [if test -z "${$1_TRUE}" && test -z "${$1_FALSE}"; then | |
142 | AC_MSG_ERROR([[conditional "$1" was never defined. | |
143 | Usually this means the macro was only invoked conditionally.]]) | |
144 | fi])]) | |
145 | ||
146 | # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2009 | |
147 | # Free Software Foundation, Inc. | |
148 | # | |
149 | # This file is free software; the Free Software Foundation | |
150 | # gives unlimited permission to copy and/or distribute it, | |
151 | # with or without modifications, as long as this notice is preserved. | |
152 | ||
153 | # serial 10 | |
154 | ||
155 | # There are a few dirty hacks below to avoid letting `AC_PROG_CC' be | |
156 | # written in clear, in which case automake, when reading aclocal.m4, | |
157 | # will think it sees a *use*, and therefore will trigger all it's | |
158 | # C support machinery. Also note that it means that autoscan, seeing | |
159 | # CC etc. in the Makefile, will ask for an AC_PROG_CC use... | |
160 | ||
161 | ||
162 | # _AM_DEPENDENCIES(NAME) | |
163 | # ---------------------- | |
164 | # See how the compiler implements dependency checking. | |
165 | # NAME is "CC", "CXX", "GCJ", or "OBJC". | |
166 | # We try a few techniques and use that to set a single cache variable. | |
167 | # | |
168 | # We don't AC_REQUIRE the corresponding AC_PROG_CC since the latter was | |
169 | # modified to invoke _AM_DEPENDENCIES(CC); we would have a circular | |
170 | # dependency, and given that the user is not expected to run this macro, | |
171 | # just rely on AC_PROG_CC. | |
172 | AC_DEFUN([_AM_DEPENDENCIES], | |
173 | [AC_REQUIRE([AM_SET_DEPDIR])dnl | |
174 | AC_REQUIRE([AM_OUTPUT_DEPENDENCY_COMMANDS])dnl | |
175 | AC_REQUIRE([AM_MAKE_INCLUDE])dnl | |
176 | AC_REQUIRE([AM_DEP_TRACK])dnl | |
177 | ||
178 | ifelse([$1], CC, [depcc="$CC" am_compiler_list=], | |
179 | [$1], CXX, [depcc="$CXX" am_compiler_list=], | |
180 | [$1], OBJC, [depcc="$OBJC" am_compiler_list='gcc3 gcc'], | |
181 | [$1], UPC, [depcc="$UPC" am_compiler_list=], | |
182 | [$1], GCJ, [depcc="$GCJ" am_compiler_list='gcc3 gcc'], | |
183 | [depcc="$$1" am_compiler_list=]) | |
184 | ||
185 | AC_CACHE_CHECK([dependency style of $depcc], | |
186 | [am_cv_$1_dependencies_compiler_type], | |
187 | [if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then | |
188 | # We make a subdir and do the tests there. Otherwise we can end up | |
189 | # making bogus files that we don't know about and never remove. For | |
190 | # instance it was reported that on HP-UX the gcc test will end up | |
191 | # making a dummy file named `D' -- because `-MD' means `put the output | |
192 | # in D'. | |
193 | mkdir conftest.dir | |
194 | # Copy depcomp to subdir because otherwise we won't find it if we're | |
195 | # using a relative directory. | |
196 | cp "$am_depcomp" conftest.dir | |
197 | cd conftest.dir | |
198 | # We will build objects and dependencies in a subdirectory because | |
199 | # it helps to detect inapplicable dependency modes. For instance | |
200 | # both Tru64's cc and ICC support -MD to output dependencies as a | |
201 | # side effect of compilation, but ICC will put the dependencies in | |
202 | # the current directory while Tru64 will put them in the object | |
203 | # directory. | |
204 | mkdir sub | |
205 | ||
206 | am_cv_$1_dependencies_compiler_type=none | |
207 | if test "$am_compiler_list" = ""; then | |
208 | am_compiler_list=`sed -n ['s/^#*\([a-zA-Z0-9]*\))$/\1/p'] < ./depcomp` | |
209 | fi | |
210 | am__universal=false | |
211 | m4_case([$1], [CC], | |
212 | [case " $depcc " in #( | |
213 | *\ -arch\ *\ -arch\ *) am__universal=true ;; | |
214 | esac], | |
215 | [CXX], | |
216 | [case " $depcc " in #( | |
217 | *\ -arch\ *\ -arch\ *) am__universal=true ;; | |
218 | esac]) | |
219 | ||
220 | for depmode in $am_compiler_list; do | |
221 | # Setup a source with many dependencies, because some compilers | |
222 | # like to wrap large dependency lists on column 80 (with \), and | |
223 | # we should not choose a depcomp mode which is confused by this. | |
224 | # | |
225 | # We need to recreate these files for each test, as the compiler may | |
226 | # overwrite some of them when testing with obscure command lines. | |
227 | # This happens at least with the AIX C compiler. | |
228 | : > sub/conftest.c | |
229 | for i in 1 2 3 4 5 6; do | |
230 | echo '#include "conftst'$i'.h"' >> sub/conftest.c | |
231 | # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with | |
232 | # Solaris 8's {/usr,}/bin/sh. | |
233 | touch sub/conftst$i.h | |
234 | done | |
235 | echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf | |
236 | ||
237 | # We check with `-c' and `-o' for the sake of the "dashmstdout" | |
238 | # mode. It turns out that the SunPro C++ compiler does not properly | |
239 | # handle `-M -o', and we need to detect this. Also, some Intel | |
240 | # versions had trouble with output in subdirs | |
241 | am__obj=sub/conftest.${OBJEXT-o} | |
242 | am__minus_obj="-o $am__obj" | |
243 | case $depmode in | |
244 | gcc) | |
245 | # This depmode causes a compiler race in universal mode. | |
246 | test "$am__universal" = false || continue | |
247 | ;; | |
248 | nosideeffect) | |
249 | # after this tag, mechanisms are not by side-effect, so they'll | |
250 | # only be used when explicitly requested | |
251 | if test "x$enable_dependency_tracking" = xyes; then | |
252 | continue | |
253 | else | |
254 | break | |
255 | fi | |
256 | ;; | |
257 | msvisualcpp | msvcmsys) | |
258 | # This compiler won't grok `-c -o', but also, the minuso test has | |
259 | # not run yet. These depmodes are late enough in the game, and | |
260 | # so weak that their functioning should not be impacted. | |
261 | am__obj=conftest.${OBJEXT-o} | |
262 | am__minus_obj= | |
263 | ;; | |
264 | none) break ;; | |
265 | esac | |
266 | if depmode=$depmode \ | |
267 | source=sub/conftest.c object=$am__obj \ | |
268 | depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ | |
269 | $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ | |
270 | >/dev/null 2>conftest.err && | |
271 | grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && | |
272 | grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && | |
273 | grep $am__obj sub/conftest.Po > /dev/null 2>&1 && | |
274 | ${MAKE-make} -s -f confmf > /dev/null 2>&1; then | |
275 | # icc doesn't choke on unknown options, it will just issue warnings | |
276 | # or remarks (even with -Werror). So we grep stderr for any message | |
277 | # that says an option was ignored or not supported. | |
278 | # When given -MP, icc 7.0 and 7.1 complain thusly: | |
279 | # icc: Command line warning: ignoring option '-M'; no argument required | |
280 | # The diagnosis changed in icc 8.0: | |
281 | # icc: Command line remark: option '-MP' not supported | |
282 | if (grep 'ignoring option' conftest.err || | |
283 | grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else | |
284 | am_cv_$1_dependencies_compiler_type=$depmode | |
285 | break | |
286 | fi | |
287 | fi | |
288 | done | |
289 | ||
290 | cd .. | |
291 | rm -rf conftest.dir | |
292 | else | |
293 | am_cv_$1_dependencies_compiler_type=none | |
294 | fi | |
295 | ]) | |
296 | AC_SUBST([$1DEPMODE], [depmode=$am_cv_$1_dependencies_compiler_type]) | |
297 | AM_CONDITIONAL([am__fastdep$1], [ | |
298 | test "x$enable_dependency_tracking" != xno \ | |
299 | && test "$am_cv_$1_dependencies_compiler_type" = gcc3]) | |
300 | ]) | |
301 | ||
302 | ||
303 | # AM_SET_DEPDIR | |
304 | # ------------- | |
305 | # Choose a directory name for dependency files. | |
306 | # This macro is AC_REQUIREd in _AM_DEPENDENCIES | |
307 | AC_DEFUN([AM_SET_DEPDIR], | |
308 | [AC_REQUIRE([AM_SET_LEADING_DOT])dnl | |
309 | AC_SUBST([DEPDIR], ["${am__leading_dot}deps"])dnl | |
310 | ]) | |
311 | ||
312 | ||
313 | # AM_DEP_TRACK | |
314 | # ------------ | |
315 | AC_DEFUN([AM_DEP_TRACK], | |
316 | [AC_ARG_ENABLE(dependency-tracking, | |
317 | [ --disable-dependency-tracking speeds up one-time build | |
318 | --enable-dependency-tracking do not reject slow dependency extractors]) | |
319 | if test "x$enable_dependency_tracking" != xno; then | |
320 | am_depcomp="$ac_aux_dir/depcomp" | |
321 | AMDEPBACKSLASH='\' | |
322 | fi | |
323 | AM_CONDITIONAL([AMDEP], [test "x$enable_dependency_tracking" != xno]) | |
324 | AC_SUBST([AMDEPBACKSLASH])dnl | |
325 | _AM_SUBST_NOTMAKE([AMDEPBACKSLASH])dnl | |
326 | ]) | |
327 | ||
328 | # Generate code to set up dependency tracking. -*- Autoconf -*- | |
329 | ||
330 | # Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2008 | |
331 | # Free Software Foundation, Inc. | |
332 | # | |
333 | # This file is free software; the Free Software Foundation | |
334 | # gives unlimited permission to copy and/or distribute it, | |
335 | # with or without modifications, as long as this notice is preserved. | |
336 | ||
337 | #serial 5 | |
338 | ||
339 | # _AM_OUTPUT_DEPENDENCY_COMMANDS | |
340 | # ------------------------------ | |
341 | AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS], | |
342 | [{ | |
343 | # Autoconf 2.62 quotes --file arguments for eval, but not when files | |
344 | # are listed without --file. Let's play safe and only enable the eval | |
345 | # if we detect the quoting. | |
346 | case $CONFIG_FILES in | |
347 | *\'*) eval set x "$CONFIG_FILES" ;; | |
348 | *) set x $CONFIG_FILES ;; | |
349 | esac | |
350 | shift | |
351 | for mf | |
352 | do | |
353 | # Strip MF so we end up with the name of the file. | |
354 | mf=`echo "$mf" | sed -e 's/:.*$//'` | |
355 | # Check whether this is an Automake generated Makefile or not. | |
356 | # We used to match only the files named `Makefile.in', but | |
357 | # some people rename them; so instead we look at the file content. | |
358 | # Grep'ing the first line is not enough: some people post-process | |
359 | # each Makefile.in and add a new line on top of each file to say so. | |
360 | # Grep'ing the whole file is not good either: AIX grep has a line | |
361 | # limit of 2048, but all sed's we know have understand at least 4000. | |
362 | if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then | |
363 | dirpart=`AS_DIRNAME("$mf")` | |
364 | else | |
365 | continue | |
366 | fi | |
367 | # Extract the definition of DEPDIR, am__include, and am__quote | |
368 | # from the Makefile without running `make'. | |
369 | DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` | |
370 | test -z "$DEPDIR" && continue | |
371 | am__include=`sed -n 's/^am__include = //p' < "$mf"` | |
372 | test -z "am__include" && continue | |
373 | am__quote=`sed -n 's/^am__quote = //p' < "$mf"` | |
374 | # When using ansi2knr, U may be empty or an underscore; expand it | |
375 | U=`sed -n 's/^U = //p' < "$mf"` | |
376 | # Find all dependency output files, they are included files with | |
377 | # $(DEPDIR) in their names. We invoke sed twice because it is the | |
378 | # simplest approach to changing $(DEPDIR) to its actual value in the | |
379 | # expansion. | |
380 | for file in `sed -n " | |
381 | s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ | |
382 | sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do | |
383 | # Make sure the directory exists. | |
384 | test -f "$dirpart/$file" && continue | |
385 | fdir=`AS_DIRNAME(["$file"])` | |
386 | AS_MKDIR_P([$dirpart/$fdir]) | |
387 | # echo "creating $dirpart/$file" | |
388 | echo '# dummy' > "$dirpart/$file" | |
389 | done | |
390 | done | |
391 | } | |
392 | ])# _AM_OUTPUT_DEPENDENCY_COMMANDS | |
393 | ||
394 | ||
395 | # AM_OUTPUT_DEPENDENCY_COMMANDS | |
396 | # ----------------------------- | |
397 | # This macro should only be invoked once -- use via AC_REQUIRE. | |
398 | # | |
399 | # This code is only required when automatic dependency tracking | |
400 | # is enabled. FIXME. This creates each `.P' file that we will | |
401 | # need in order to bootstrap the dependency handling code. | |
402 | AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS], | |
403 | [AC_CONFIG_COMMANDS([depfiles], | |
404 | [test x"$AMDEP_TRUE" != x"" || _AM_OUTPUT_DEPENDENCY_COMMANDS], | |
405 | [AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"]) | |
406 | ]) | |
407 | ||
408 | # Do all the work for Automake. -*- Autoconf -*- | |
409 | ||
410 | # Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, | |
411 | # 2005, 2006, 2008, 2009 Free Software Foundation, Inc. | |
412 | # | |
413 | # This file is free software; the Free Software Foundation | |
414 | # gives unlimited permission to copy and/or distribute it, | |
415 | # with or without modifications, as long as this notice is preserved. | |
416 | ||
417 | # serial 16 | |
418 | ||
419 | # This macro actually does too much. Some checks are only needed if | |
420 | # your package does certain things. But this isn't really a big deal. | |
421 | ||
422 | # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE]) | |
423 | # AM_INIT_AUTOMAKE([OPTIONS]) | |
424 | # ----------------------------------------------- | |
425 | # The call with PACKAGE and VERSION arguments is the old style | |
426 | # call (pre autoconf-2.50), which is being phased out. PACKAGE | |
427 | # and VERSION should now be passed to AC_INIT and removed from | |
428 | # the call to AM_INIT_AUTOMAKE. | |
429 | # We support both call styles for the transition. After | |
430 | # the next Automake release, Autoconf can make the AC_INIT | |
431 | # arguments mandatory, and then we can depend on a new Autoconf | |
432 | # release and drop the old call support. | |
433 | AC_DEFUN([AM_INIT_AUTOMAKE], | |
434 | [AC_PREREQ([2.62])dnl | |
435 | dnl Autoconf wants to disallow AM_ names. We explicitly allow | |
436 | dnl the ones we care about. | |
437 | m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl | |
438 | AC_REQUIRE([AM_SET_CURRENT_AUTOMAKE_VERSION])dnl | |
439 | AC_REQUIRE([AC_PROG_INSTALL])dnl | |
440 | if test "`cd $srcdir && pwd`" != "`pwd`"; then | |
441 | # Use -I$(srcdir) only when $(srcdir) != ., so that make's output | |
442 | # is not polluted with repeated "-I." | |
443 | AC_SUBST([am__isrc], [' -I$(srcdir)'])_AM_SUBST_NOTMAKE([am__isrc])dnl | |
444 | # test to see if srcdir already configured | |
445 | if test -f $srcdir/config.status; then | |
446 | AC_MSG_ERROR([source directory already configured; run "make distclean" there first]) | |
447 | fi | |
448 | fi | |
449 | ||
450 | # test whether we have cygpath | |
451 | if test -z "$CYGPATH_W"; then | |
452 | if (cygpath --version) >/dev/null 2>/dev/null; then | |
453 | CYGPATH_W='cygpath -w' | |
454 | else | |
455 | CYGPATH_W=echo | |
456 | fi | |
457 | fi | |
458 | AC_SUBST([CYGPATH_W]) | |
459 | ||
460 | # Define the identity of the package. | |
461 | dnl Distinguish between old-style and new-style calls. | |
462 | m4_ifval([$2], | |
463 | [m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl | |
464 | AC_SUBST([PACKAGE], [$1])dnl | |
465 | AC_SUBST([VERSION], [$2])], | |
466 | [_AM_SET_OPTIONS([$1])dnl | |
467 | dnl Diagnose old-style AC_INIT with new-style AM_AUTOMAKE_INIT. | |
468 | m4_if(m4_ifdef([AC_PACKAGE_NAME], 1)m4_ifdef([AC_PACKAGE_VERSION], 1), 11,, | |
469 | [m4_fatal([AC_INIT should be called with package and version arguments])])dnl | |
470 | AC_SUBST([PACKAGE], ['AC_PACKAGE_TARNAME'])dnl | |
471 | AC_SUBST([VERSION], ['AC_PACKAGE_VERSION'])])dnl | |
472 | ||
473 | _AM_IF_OPTION([no-define],, | |
474 | [AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of package]) | |
475 | AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version number of package])])dnl | |
476 | ||
477 | # Some tools Automake needs. | |
478 | AC_REQUIRE([AM_SANITY_CHECK])dnl | |
479 | AC_REQUIRE([AC_ARG_PROGRAM])dnl | |
480 | AM_MISSING_PROG(ACLOCAL, aclocal-${am__api_version}) | |
481 | AM_MISSING_PROG(AUTOCONF, autoconf) | |
482 | AM_MISSING_PROG(AUTOMAKE, automake-${am__api_version}) | |
483 | AM_MISSING_PROG(AUTOHEADER, autoheader) | |
484 | AM_MISSING_PROG(MAKEINFO, makeinfo) | |
485 | AC_REQUIRE([AM_PROG_INSTALL_SH])dnl | |
486 | AC_REQUIRE([AM_PROG_INSTALL_STRIP])dnl | |
487 | AC_REQUIRE([AM_PROG_MKDIR_P])dnl | |
488 | # We need awk for the "check" target. The system "awk" is bad on | |
489 | # some platforms. | |
490 | AC_REQUIRE([AC_PROG_AWK])dnl | |
491 | AC_REQUIRE([AC_PROG_MAKE_SET])dnl | |
492 | AC_REQUIRE([AM_SET_LEADING_DOT])dnl | |
493 | _AM_IF_OPTION([tar-ustar], [_AM_PROG_TAR([ustar])], | |
494 | [_AM_IF_OPTION([tar-pax], [_AM_PROG_TAR([pax])], | |
495 | [_AM_PROG_TAR([v7])])]) | |
496 | _AM_IF_OPTION([no-dependencies],, | |
497 | [AC_PROVIDE_IFELSE([AC_PROG_CC], | |
498 | [_AM_DEPENDENCIES(CC)], | |
499 | [define([AC_PROG_CC], | |
500 | defn([AC_PROG_CC])[_AM_DEPENDENCIES(CC)])])dnl | |
501 | AC_PROVIDE_IFELSE([AC_PROG_CXX], | |
502 | [_AM_DEPENDENCIES(CXX)], | |
503 | [define([AC_PROG_CXX], | |
504 | defn([AC_PROG_CXX])[_AM_DEPENDENCIES(CXX)])])dnl | |
505 | AC_PROVIDE_IFELSE([AC_PROG_OBJC], | |
506 | [_AM_DEPENDENCIES(OBJC)], | |
507 | [define([AC_PROG_OBJC], | |
508 | defn([AC_PROG_OBJC])[_AM_DEPENDENCIES(OBJC)])])dnl | |
509 | ]) | |
510 | _AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl | |
511 | dnl The `parallel-tests' driver may need to know about EXEEXT, so add the | |
512 | dnl `am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen. This macro | |
513 | dnl is hooked onto _AC_COMPILER_EXEEXT early, see below. | |
514 | AC_CONFIG_COMMANDS_PRE(dnl | |
515 | [m4_provide_if([_AM_COMPILER_EXEEXT], | |
516 | [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl | |
517 | ]) | |
518 | ||
519 | dnl Hook into `_AC_COMPILER_EXEEXT' early to learn its expansion. Do not | |
520 | dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further | |
521 | dnl mangled by Autoconf and run in a shell conditional statement. | |
522 | m4_define([_AC_COMPILER_EXEEXT], | |
523 | m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])]) | |
524 | ||
525 | ||
526 | # When config.status generates a header, we must update the stamp-h file. | |
527 | # This file resides in the same directory as the config header | |
528 | # that is generated. The stamp files are numbered to have different names. | |
529 | ||
530 | # Autoconf calls _AC_AM_CONFIG_HEADER_HOOK (when defined) in the | |
531 | # loop where config.status creates the headers, so we can generate | |
532 | # our stamp files there. | |
533 | AC_DEFUN([_AC_AM_CONFIG_HEADER_HOOK], | |
534 | [# Compute $1's index in $config_headers. | |
535 | _am_arg=$1 | |
536 | _am_stamp_count=1 | |
537 | for _am_header in $config_headers :; do | |
538 | case $_am_header in | |
539 | $_am_arg | $_am_arg:* ) | |
540 | break ;; | |
541 | * ) | |
542 | _am_stamp_count=`expr $_am_stamp_count + 1` ;; | |
543 | esac | |
544 | done | |
545 | echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count]) | |
546 | ||
547 | # Copyright (C) 2001, 2003, 2005, 2008 Free Software Foundation, Inc. | |
548 | # | |
549 | # This file is free software; the Free Software Foundation | |
550 | # gives unlimited permission to copy and/or distribute it, | |
551 | # with or without modifications, as long as this notice is preserved. | |
552 | ||
553 | # AM_PROG_INSTALL_SH | |
554 | # ------------------ | |
555 | # Define $install_sh. | |
556 | AC_DEFUN([AM_PROG_INSTALL_SH], | |
557 | [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl | |
558 | if test x"${install_sh}" != xset; then | |
559 | case $am_aux_dir in | |
560 | *\ * | *\ *) | |
561 | install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; | |
562 | *) | |
563 | install_sh="\${SHELL} $am_aux_dir/install-sh" | |
564 | esac | |
565 | fi | |
566 | AC_SUBST(install_sh)]) | |
567 | ||
568 | # Copyright (C) 2003, 2005 Free Software Foundation, Inc. | |
569 | # | |
570 | # This file is free software; the Free Software Foundation | |
571 | # gives unlimited permission to copy and/or distribute it, | |
572 | # with or without modifications, as long as this notice is preserved. | |
573 | ||
574 | # serial 2 | |
575 | ||
576 | # Check whether the underlying file-system supports filenames | |
577 | # with a leading dot. For instance MS-DOS doesn't. | |
578 | AC_DEFUN([AM_SET_LEADING_DOT], | |
579 | [rm -rf .tst 2>/dev/null | |
580 | mkdir .tst 2>/dev/null | |
581 | if test -d .tst; then | |
582 | am__leading_dot=. | |
583 | else | |
584 | am__leading_dot=_ | |
585 | fi | |
586 | rmdir .tst 2>/dev/null | |
587 | AC_SUBST([am__leading_dot])]) | |
588 | ||
589 | # Add --enable-maintainer-mode option to configure. -*- Autoconf -*- | |
590 | # From Jim Meyering | |
591 | ||
592 | # Copyright (C) 1996, 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2008 | |
593 | # Free Software Foundation, Inc. | |
594 | # | |
595 | # This file is free software; the Free Software Foundation | |
596 | # gives unlimited permission to copy and/or distribute it, | |
597 | # with or without modifications, as long as this notice is preserved. | |
598 | ||
599 | # serial 5 | |
600 | ||
601 | # AM_MAINTAINER_MODE([DEFAULT-MODE]) | |
602 | # ---------------------------------- | |
603 | # Control maintainer-specific portions of Makefiles. | |
604 | # Default is to disable them, unless `enable' is passed literally. | |
605 | # For symmetry, `disable' may be passed as well. Anyway, the user | |
606 | # can override the default with the --enable/--disable switch. | |
607 | AC_DEFUN([AM_MAINTAINER_MODE], | |
608 | [m4_case(m4_default([$1], [disable]), | |
609 | [enable], [m4_define([am_maintainer_other], [disable])], | |
610 | [disable], [m4_define([am_maintainer_other], [enable])], | |
611 | [m4_define([am_maintainer_other], [enable]) | |
612 | m4_warn([syntax], [unexpected argument to AM@&t@_MAINTAINER_MODE: $1])]) | |
613 | AC_MSG_CHECKING([whether to am_maintainer_other maintainer-specific portions of Makefiles]) | |
614 | dnl maintainer-mode's default is 'disable' unless 'enable' is passed | |
615 | AC_ARG_ENABLE([maintainer-mode], | |
616 | [ --][am_maintainer_other][-maintainer-mode am_maintainer_other make rules and dependencies not useful | |
617 | (and sometimes confusing) to the casual installer], | |
618 | [USE_MAINTAINER_MODE=$enableval], | |
619 | [USE_MAINTAINER_MODE=]m4_if(am_maintainer_other, [enable], [no], [yes])) | |
620 | AC_MSG_RESULT([$USE_MAINTAINER_MODE]) | |
621 | AM_CONDITIONAL([MAINTAINER_MODE], [test $USE_MAINTAINER_MODE = yes]) | |
622 | MAINT=$MAINTAINER_MODE_TRUE | |
623 | AC_SUBST([MAINT])dnl | |
624 | ] | |
625 | ) | |
626 | ||
627 | AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE]) | |
628 | ||
629 | # Check to see how 'make' treats includes. -*- Autoconf -*- | |
630 | ||
631 | # Copyright (C) 2001, 2002, 2003, 2005, 2009 Free Software Foundation, Inc. | |
632 | # | |
633 | # This file is free software; the Free Software Foundation | |
634 | # gives unlimited permission to copy and/or distribute it, | |
635 | # with or without modifications, as long as this notice is preserved. | |
636 | ||
637 | # serial 4 | |
638 | ||
639 | # AM_MAKE_INCLUDE() | |
640 | # ----------------- | |
641 | # Check to see how make treats includes. | |
642 | AC_DEFUN([AM_MAKE_INCLUDE], | |
643 | [am_make=${MAKE-make} | |
644 | cat > confinc << 'END' | |
645 | am__doit: | |
646 | @echo this is the am__doit target | |
647 | .PHONY: am__doit | |
648 | END | |
649 | # If we don't find an include directive, just comment out the code. | |
650 | AC_MSG_CHECKING([for style of include used by $am_make]) | |
651 | am__include="#" | |
652 | am__quote= | |
653 | _am_result=none | |
654 | # First try GNU make style include. | |
655 | echo "include confinc" > confmf | |
656 | # Ignore all kinds of additional output from `make'. | |
657 | case `$am_make -s -f confmf 2> /dev/null` in #( | |
658 | *the\ am__doit\ target*) | |
659 | am__include=include | |
660 | am__quote= | |
661 | _am_result=GNU | |
662 | ;; | |
663 | esac | |
664 | # Now try BSD make style include. | |
665 | if test "$am__include" = "#"; then | |
666 | echo '.include "confinc"' > confmf | |
667 | case `$am_make -s -f confmf 2> /dev/null` in #( | |
668 | *the\ am__doit\ target*) | |
669 | am__include=.include | |
670 | am__quote="\"" | |
671 | _am_result=BSD | |
672 | ;; | |
673 | esac | |
674 | fi | |
675 | AC_SUBST([am__include]) | |
676 | AC_SUBST([am__quote]) | |
677 | AC_MSG_RESULT([$_am_result]) | |
678 | rm -f confinc confmf | |
679 | ]) | |
680 | ||
681 | # Fake the existence of programs that GNU maintainers use. -*- Autoconf -*- | |
682 | ||
683 | # Copyright (C) 1997, 1999, 2000, 2001, 2003, 2004, 2005, 2008 | |
684 | # Free Software Foundation, Inc. | |
685 | # | |
686 | # This file is free software; the Free Software Foundation | |
687 | # gives unlimited permission to copy and/or distribute it, | |
688 | # with or without modifications, as long as this notice is preserved. | |
689 | ||
690 | # serial 6 | |
691 | ||
692 | # AM_MISSING_PROG(NAME, PROGRAM) | |
693 | # ------------------------------ | |
694 | AC_DEFUN([AM_MISSING_PROG], | |
695 | [AC_REQUIRE([AM_MISSING_HAS_RUN]) | |
696 | $1=${$1-"${am_missing_run}$2"} | |
697 | AC_SUBST($1)]) | |
698 | ||
699 | ||
700 | # AM_MISSING_HAS_RUN | |
701 | # ------------------ | |
702 | # Define MISSING if not defined so far and test if it supports --run. | |
703 | # If it does, set am_missing_run to use it, otherwise, to nothing. | |
704 | AC_DEFUN([AM_MISSING_HAS_RUN], | |
705 | [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl | |
706 | AC_REQUIRE_AUX_FILE([missing])dnl | |
707 | if test x"${MISSING+set}" != xset; then | |
708 | case $am_aux_dir in | |
709 | *\ * | *\ *) | |
710 | MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; | |
711 | *) | |
712 | MISSING="\${SHELL} $am_aux_dir/missing" ;; | |
713 | esac | |
714 | fi | |
715 | # Use eval to expand $SHELL | |
716 | if eval "$MISSING --run true"; then | |
717 | am_missing_run="$MISSING --run " | |
718 | else | |
719 | am_missing_run= | |
720 | AC_MSG_WARN([`missing' script is too old or missing]) | |
721 | fi | |
722 | ]) | |
723 | ||
724 | # Copyright (C) 2003, 2004, 2005, 2006 Free Software Foundation, Inc. | |
725 | # | |
726 | # This file is free software; the Free Software Foundation | |
727 | # gives unlimited permission to copy and/or distribute it, | |
728 | # with or without modifications, as long as this notice is preserved. | |
729 | ||
730 | # AM_PROG_MKDIR_P | |
731 | # --------------- | |
732 | # Check for `mkdir -p'. | |
733 | AC_DEFUN([AM_PROG_MKDIR_P], | |
734 | [AC_PREREQ([2.60])dnl | |
735 | AC_REQUIRE([AC_PROG_MKDIR_P])dnl | |
736 | dnl Automake 1.8 to 1.9.6 used to define mkdir_p. We now use MKDIR_P, | |
737 | dnl while keeping a definition of mkdir_p for backward compatibility. | |
738 | dnl @MKDIR_P@ is magic: AC_OUTPUT adjusts its value for each Makefile. | |
739 | dnl However we cannot define mkdir_p as $(MKDIR_P) for the sake of | |
740 | dnl Makefile.ins that do not define MKDIR_P, so we do our own | |
741 | dnl adjustment using top_builddir (which is defined more often than | |
742 | dnl MKDIR_P). | |
743 | AC_SUBST([mkdir_p], ["$MKDIR_P"])dnl | |
744 | case $mkdir_p in | |
745 | [[\\/$]]* | ?:[[\\/]]*) ;; | |
746 | */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; | |
747 | esac | |
748 | ]) | |
749 | ||
750 | # Helper functions for option handling. -*- Autoconf -*- | |
751 | ||
752 | # Copyright (C) 2001, 2002, 2003, 2005, 2008 Free Software Foundation, Inc. | |
753 | # | |
754 | # This file is free software; the Free Software Foundation | |
755 | # gives unlimited permission to copy and/or distribute it, | |
756 | # with or without modifications, as long as this notice is preserved. | |
757 | ||
758 | # serial 4 | |
759 | ||
760 | # _AM_MANGLE_OPTION(NAME) | |
761 | # ----------------------- | |
762 | AC_DEFUN([_AM_MANGLE_OPTION], | |
763 | [[_AM_OPTION_]m4_bpatsubst($1, [[^a-zA-Z0-9_]], [_])]) | |
764 | ||
765 | # _AM_SET_OPTION(NAME) | |
766 | # ------------------------------ | |
767 | # Set option NAME. Presently that only means defining a flag for this option. | |
768 | AC_DEFUN([_AM_SET_OPTION], | |
769 | [m4_define(_AM_MANGLE_OPTION([$1]), 1)]) | |
770 | ||
771 | # _AM_SET_OPTIONS(OPTIONS) | |
772 | # ---------------------------------- | |
773 | # OPTIONS is a space-separated list of Automake options. | |
774 | AC_DEFUN([_AM_SET_OPTIONS], | |
775 | [m4_foreach_w([_AM_Option], [$1], [_AM_SET_OPTION(_AM_Option)])]) | |
776 | ||
777 | # _AM_IF_OPTION(OPTION, IF-SET, [IF-NOT-SET]) | |
778 | # ------------------------------------------- | |
779 | # Execute IF-SET if OPTION is set, IF-NOT-SET otherwise. | |
780 | AC_DEFUN([_AM_IF_OPTION], | |
781 | [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])]) | |
782 | ||
783 | # Check to make sure that the build environment is sane. -*- Autoconf -*- | |
784 | ||
785 | # Copyright (C) 1996, 1997, 2000, 2001, 2003, 2005, 2008 | |
786 | # Free Software Foundation, Inc. | |
787 | # | |
788 | # This file is free software; the Free Software Foundation | |
789 | # gives unlimited permission to copy and/or distribute it, | |
790 | # with or without modifications, as long as this notice is preserved. | |
791 | ||
792 | # serial 5 | |
793 | ||
794 | # AM_SANITY_CHECK | |
795 | # --------------- | |
796 | AC_DEFUN([AM_SANITY_CHECK], | |
797 | [AC_MSG_CHECKING([whether build environment is sane]) | |
798 | # Just in case | |
799 | sleep 1 | |
800 | echo timestamp > conftest.file | |
801 | # Reject unsafe characters in $srcdir or the absolute working directory | |
802 | # name. Accept space and tab only in the latter. | |
803 | am_lf=' | |
804 | ' | |
805 | case `pwd` in | |
806 | *[[\\\"\#\$\&\'\`$am_lf]]*) | |
807 | AC_MSG_ERROR([unsafe absolute working directory name]);; | |
808 | esac | |
809 | case $srcdir in | |
810 | *[[\\\"\#\$\&\'\`$am_lf\ \ ]]*) | |
811 | AC_MSG_ERROR([unsafe srcdir value: `$srcdir']);; | |
812 | esac | |
813 | ||
814 | # Do `set' in a subshell so we don't clobber the current shell's | |
815 | # arguments. Must try -L first in case configure is actually a | |
816 | # symlink; some systems play weird games with the mod time of symlinks | |
817 | # (eg FreeBSD returns the mod time of the symlink's containing | |
818 | # directory). | |
819 | if ( | |
820 | set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` | |
821 | if test "$[*]" = "X"; then | |
822 | # -L didn't work. | |
823 | set X `ls -t "$srcdir/configure" conftest.file` | |
824 | fi | |
825 | rm -f conftest.file | |
826 | if test "$[*]" != "X $srcdir/configure conftest.file" \ | |
827 | && test "$[*]" != "X conftest.file $srcdir/configure"; then | |
828 | ||
829 | # If neither matched, then we have a broken ls. This can happen | |
830 | # if, for instance, CONFIG_SHELL is bash and it inherits a | |
831 | # broken ls alias from the environment. This has actually | |
832 | # happened. Such a system could not be considered "sane". | |
833 | AC_MSG_ERROR([ls -t appears to fail. Make sure there is not a broken | |
834 | alias in your environment]) | |
835 | fi | |
836 | ||
837 | test "$[2]" = conftest.file | |
838 | ) | |
839 | then | |
840 | # Ok. | |
841 | : | |
842 | else | |
843 | AC_MSG_ERROR([newly created file is older than distributed files! | |
844 | Check your system clock]) | |
845 | fi | |
846 | AC_MSG_RESULT(yes)]) | |
847 | ||
848 | # Copyright (C) 2009 Free Software Foundation, Inc. | |
849 | # | |
850 | # This file is free software; the Free Software Foundation | |
851 | # gives unlimited permission to copy and/or distribute it, | |
852 | # with or without modifications, as long as this notice is preserved. | |
853 | ||
854 | # serial 1 | |
855 | ||
856 | # AM_SILENT_RULES([DEFAULT]) | |
857 | # -------------------------- | |
858 | # Enable less verbose build rules; with the default set to DEFAULT | |
859 | # (`yes' being less verbose, `no' or empty being verbose). | |
860 | AC_DEFUN([AM_SILENT_RULES], | |
861 | [AC_ARG_ENABLE([silent-rules], | |
862 | [ --enable-silent-rules less verbose build output (undo: `make V=1') | |
863 | --disable-silent-rules verbose build output (undo: `make V=0')]) | |
864 | case $enable_silent_rules in | |
865 | yes) AM_DEFAULT_VERBOSITY=0;; | |
866 | no) AM_DEFAULT_VERBOSITY=1;; | |
867 | *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);; | |
868 | esac | |
869 | AC_SUBST([AM_DEFAULT_VERBOSITY])dnl | |
870 | AM_BACKSLASH='\' | |
871 | AC_SUBST([AM_BACKSLASH])dnl | |
872 | _AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl | |
873 | ]) | |
874 | ||
875 | # Copyright (C) 2001, 2003, 2005 Free Software Foundation, Inc. | |
876 | # | |
877 | # This file is free software; the Free Software Foundation | |
878 | # gives unlimited permission to copy and/or distribute it, | |
879 | # with or without modifications, as long as this notice is preserved. | |
880 | ||
881 | # AM_PROG_INSTALL_STRIP | |
882 | # --------------------- | |
883 | # One issue with vendor `install' (even GNU) is that you can't | |
884 | # specify the program used to strip binaries. This is especially | |
885 | # annoying in cross-compiling environments, where the build's strip | |
886 | # is unlikely to handle the host's binaries. | |
887 | # Fortunately install-sh will honor a STRIPPROG variable, so we | |
888 | # always use install-sh in `make install-strip', and initialize | |
889 | # STRIPPROG with the value of the STRIP variable (set by the user). | |
890 | AC_DEFUN([AM_PROG_INSTALL_STRIP], | |
891 | [AC_REQUIRE([AM_PROG_INSTALL_SH])dnl | |
892 | # Installed binaries are usually stripped using `strip' when the user | |
893 | # run `make install-strip'. However `strip' might not be the right | |
894 | # tool to use in cross-compilation environments, therefore Automake | |
895 | # will honor the `STRIP' environment variable to overrule this program. | |
896 | dnl Don't test for $cross_compiling = yes, because it might be `maybe'. | |
897 | if test "$cross_compiling" != no; then | |
898 | AC_CHECK_TOOL([STRIP], [strip], :) | |
899 | fi | |
900 | INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" | |
901 | AC_SUBST([INSTALL_STRIP_PROGRAM])]) | |
902 | ||
903 | # Copyright (C) 2006, 2008 Free Software Foundation, Inc. | |
904 | # | |
905 | # This file is free software; the Free Software Foundation | |
906 | # gives unlimited permission to copy and/or distribute it, | |
907 | # with or without modifications, as long as this notice is preserved. | |
908 | ||
909 | # serial 2 | |
910 | ||
911 | # _AM_SUBST_NOTMAKE(VARIABLE) | |
912 | # --------------------------- | |
913 | # Prevent Automake from outputting VARIABLE = @VARIABLE@ in Makefile.in. | |
914 | # This macro is traced by Automake. | |
915 | AC_DEFUN([_AM_SUBST_NOTMAKE]) | |
916 | ||
917 | # AM_SUBST_NOTMAKE(VARIABLE) | |
918 | # --------------------------- | |
919 | # Public sister of _AM_SUBST_NOTMAKE. | |
920 | AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)]) | |
921 | ||
922 | # Check how to create a tarball. -*- Autoconf -*- | |
923 | ||
924 | # Copyright (C) 2004, 2005 Free Software Foundation, Inc. | |
925 | # | |
926 | # This file is free software; the Free Software Foundation | |
927 | # gives unlimited permission to copy and/or distribute it, | |
928 | # with or without modifications, as long as this notice is preserved. | |
929 | ||
930 | # serial 2 | |
931 | ||
932 | # _AM_PROG_TAR(FORMAT) | |
933 | # -------------------- | |
934 | # Check how to create a tarball in format FORMAT. | |
935 | # FORMAT should be one of `v7', `ustar', or `pax'. | |
936 | # | |
937 | # Substitute a variable $(am__tar) that is a command | |
938 | # writing to stdout a FORMAT-tarball containing the directory | |
939 | # $tardir. | |
940 | # tardir=directory && $(am__tar) > result.tar | |
941 | # | |
942 | # Substitute a variable $(am__untar) that extract such | |
943 | # a tarball read from stdin. | |
944 | # $(am__untar) < result.tar | |
945 | AC_DEFUN([_AM_PROG_TAR], | |
946 | [# Always define AMTAR for backward compatibility. | |
947 | AM_MISSING_PROG([AMTAR], [tar]) | |
948 | m4_if([$1], [v7], | |
949 | [am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'], | |
950 | [m4_case([$1], [ustar],, [pax],, | |
951 | [m4_fatal([Unknown tar format])]) | |
952 | AC_MSG_CHECKING([how to create a $1 tar archive]) | |
953 | # Loop over all known methods to create a tar archive until one works. | |
954 | _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none' | |
955 | _am_tools=${am_cv_prog_tar_$1-$_am_tools} | |
956 | # Do not fold the above two line into one, because Tru64 sh and | |
957 | # Solaris sh will not grok spaces in the rhs of `-'. | |
958 | for _am_tool in $_am_tools | |
959 | do | |
960 | case $_am_tool in | |
961 | gnutar) | |
962 | for _am_tar in tar gnutar gtar; | |
963 | do | |
964 | AM_RUN_LOG([$_am_tar --version]) && break | |
965 | done | |
966 | am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"' | |
967 | am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"' | |
968 | am__untar="$_am_tar -xf -" | |
969 | ;; | |
970 | plaintar) | |
971 | # Must skip GNU tar: if it does not support --format= it doesn't create | |
972 | # ustar tarball either. | |
973 | (tar --version) >/dev/null 2>&1 && continue | |
974 | am__tar='tar chf - "$$tardir"' | |
975 | am__tar_='tar chf - "$tardir"' | |
976 | am__untar='tar xf -' | |
977 | ;; | |
978 | pax) | |
979 | am__tar='pax -L -x $1 -w "$$tardir"' | |
980 | am__tar_='pax -L -x $1 -w "$tardir"' | |
981 | am__untar='pax -r' | |
982 | ;; | |
983 | cpio) | |
984 | am__tar='find "$$tardir" -print | cpio -o -H $1 -L' | |
985 | am__tar_='find "$tardir" -print | cpio -o -H $1 -L' | |
986 | am__untar='cpio -i -H $1 -d' | |
987 | ;; | |
988 | none) | |
989 | am__tar=false | |
990 | am__tar_=false | |
991 | am__untar=false | |
992 | ;; | |
993 | esac | |
994 | ||
995 | # If the value was cached, stop now. We just wanted to have am__tar | |
996 | # and am__untar set. | |
997 | test -n "${am_cv_prog_tar_$1}" && break | |
998 | ||
999 | # tar/untar a dummy directory, and stop if the command works | |
1000 | rm -rf conftest.dir | |
1001 | mkdir conftest.dir | |
1002 | echo GrepMe > conftest.dir/file | |
1003 | AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar]) | |
1004 | rm -rf conftest.dir | |
1005 | if test -s conftest.tar; then | |
1006 | AM_RUN_LOG([$am__untar <conftest.tar]) | |
1007 | grep GrepMe conftest.dir/file >/dev/null 2>&1 && break | |
1008 | fi | |
1009 | done | |
1010 | rm -rf conftest.dir | |
1011 | ||
1012 | AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool]) | |
1013 | AC_MSG_RESULT([$am_cv_prog_tar_$1])]) | |
1014 | AC_SUBST([am__tar]) | |
1015 | AC_SUBST([am__untar]) | |
1016 | ]) # _AM_PROG_TAR | |
1017 | ||
1018 | dnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure. | |
1019 | dnl | |
1020 | dnl Copyright (c) 2005, 2006, Oracle and/or its affiliates. All rights reserved. | |
1021 | dnl | |
1022 | dnl Permission is hereby granted, free of charge, to any person obtaining a | |
1023 | dnl copy of this software and associated documentation files (the "Software"), | |
1024 | dnl to deal in the Software without restriction, including without limitation | |
1025 | dnl the rights to use, copy, modify, merge, publish, distribute, sublicense, | |
1026 | dnl and/or sell copies of the Software, and to permit persons to whom the | |
1027 | dnl Software is furnished to do so, subject to the following conditions: | |
1028 | dnl | |
1029 | dnl The above copyright notice and this permission notice (including the next | |
1030 | dnl paragraph) shall be included in all copies or substantial portions of the | |
1031 | dnl Software. | |
1032 | dnl | |
1033 | dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
1034 | dnl IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
1035 | dnl FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL | |
1036 | dnl THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
1037 | dnl LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | |
1038 | dnl FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | |
1039 | dnl DEALINGS IN THE SOFTWARE. | |
1040 | ||
1041 | # XORG_MACROS_VERSION(required-version) | |
1042 | # ------------------------------------- | |
1043 | # Minimum version: 1.1.0 | |
1044 | # | |
1045 | # If you're using a macro added in Version 1.1 or newer, include this in | |
1046 | # your configure.ac with the minimum required version, such as: | |
1047 | # XORG_MACROS_VERSION(1.1) | |
1048 | # | |
1049 | # To ensure that this macro is defined, also add: | |
1050 | # m4_ifndef([XORG_MACROS_VERSION], | |
1051 | # [m4_fatal([must install xorg-macros 1.1 or later before running autoconf/autogen])]) | |
1052 | # | |
1053 | # | |
1054 | # See the "minimum version" comment for each macro you use to see what | |
1055 | # version you require. | |
1056 | m4_defun([XORG_MACROS_VERSION],[ | |
1057 | m4_define([vers_have], [1.11.0]) | |
1058 | m4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.]))) | |
1059 | m4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.]))) | |
1060 | m4_if(m4_cmp(maj_have, maj_needed), 0,, | |
1061 | [m4_fatal([xorg-macros major version ]maj_needed[ is required but ]vers_have[ found])]) | |
1062 | m4_if(m4_version_compare(vers_have, [$1]), -1, | |
1063 | [m4_fatal([xorg-macros version $1 or higher is required but ]vers_have[ found])]) | |
1064 | m4_undefine([vers_have]) | |
1065 | m4_undefine([maj_have]) | |
1066 | m4_undefine([maj_needed]) | |
1067 | ]) # XORG_MACROS_VERSION | |
1068 | ||
1069 | # XORG_PROG_RAWCPP() | |
1070 | # ------------------ | |
1071 | # Minimum version: 1.0.0 | |
1072 | # | |
1073 | # Find cpp program and necessary flags for use in pre-processing text files | |
1074 | # such as man pages and config files | |
1075 | AC_DEFUN([XORG_PROG_RAWCPP],[ | |
1076 | AC_REQUIRE([AC_PROG_CPP]) | |
1077 | AC_PATH_PROGS(RAWCPP, [cpp], [${CPP}], | |
1078 | [$PATH:/bin:/usr/bin:/usr/lib:/usr/libexec:/usr/ccs/lib:/usr/ccs/lbin:/lib]) | |
1079 | ||
1080 | # Check for flag to avoid builtin definitions - assumes unix is predefined, | |
1081 | # which is not the best choice for supporting other OS'es, but covers most | |
1082 | # of the ones we need for now. | |
1083 | AC_MSG_CHECKING([if $RAWCPP requires -undef]) | |
1084 | AC_LANG_CONFTEST([Does cpp redefine unix ?]) | |
1085 | if test `${RAWCPP} < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then | |
1086 | AC_MSG_RESULT([no]) | |
1087 | else | |
1088 | if test `${RAWCPP} -undef < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then | |
1089 | RAWCPPFLAGS=-undef | |
1090 | AC_MSG_RESULT([yes]) | |
1091 | # under Cygwin unix is still defined even with -undef | |
1092 | elif test `${RAWCPP} -undef -ansi < conftest.$ac_ext | grep -c 'unix'` -eq 1 ; then | |
1093 | RAWCPPFLAGS="-undef -ansi" | |
1094 | AC_MSG_RESULT([yes, with -ansi]) | |
1095 | else | |
1096 | AC_MSG_ERROR([${RAWCPP} defines unix with or without -undef. I don't know what to do.]) | |
1097 | fi | |
1098 | fi | |
1099 | rm -f conftest.$ac_ext | |
1100 | ||
1101 | AC_MSG_CHECKING([if $RAWCPP requires -traditional]) | |
1102 | AC_LANG_CONFTEST([Does cpp preserve "whitespace"?]) | |
1103 | if test `${RAWCPP} < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then | |
1104 | AC_MSG_RESULT([no]) | |
1105 | else | |
1106 | if test `${RAWCPP} -traditional < conftest.$ac_ext | grep -c 'preserve \"'` -eq 1 ; then | |
1107 | RAWCPPFLAGS="${RAWCPPFLAGS} -traditional" | |
1108 | AC_MSG_RESULT([yes]) | |
1109 | else | |
1110 | AC_MSG_ERROR([${RAWCPP} does not preserve whitespace with or without -traditional. I don't know what to do.]) | |
1111 | fi | |
1112 | fi | |
1113 | rm -f conftest.$ac_ext | |
1114 | AC_SUBST(RAWCPPFLAGS) | |
1115 | ]) # XORG_PROG_RAWCPP | |
1116 | ||
1117 | # XORG_MANPAGE_SECTIONS() | |
1118 | # ----------------------- | |
1119 | # Minimum version: 1.0.0 | |
1120 | # | |
1121 | # Determine which sections man pages go in for the different man page types | |
1122 | # on this OS - replaces *ManSuffix settings in old Imake *.cf per-os files. | |
1123 | # Not sure if there's any better way than just hardcoding by OS name. | |
1124 | # Override default settings by setting environment variables | |
1125 | # Added MAN_SUBSTS in version 1.8 | |
1126 | # Added AC_PROG_SED in version 1.8 | |
1127 | ||
1128 | AC_DEFUN([XORG_MANPAGE_SECTIONS],[ | |
1129 | AC_REQUIRE([AC_CANONICAL_HOST]) | |
1130 | AC_REQUIRE([AC_PROG_SED]) | |
1131 | ||
1132 | if test x$APP_MAN_SUFFIX = x ; then | |
1133 | APP_MAN_SUFFIX=1 | |
1134 | fi | |
1135 | if test x$APP_MAN_DIR = x ; then | |
1136 | APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' | |
1137 | fi | |
1138 | ||
1139 | if test x$LIB_MAN_SUFFIX = x ; then | |
1140 | LIB_MAN_SUFFIX=3 | |
1141 | fi | |
1142 | if test x$LIB_MAN_DIR = x ; then | |
1143 | LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' | |
1144 | fi | |
1145 | ||
1146 | if test x$FILE_MAN_SUFFIX = x ; then | |
1147 | case $host_os in | |
1148 | solaris*) FILE_MAN_SUFFIX=4 ;; | |
1149 | *) FILE_MAN_SUFFIX=5 ;; | |
1150 | esac | |
1151 | fi | |
1152 | if test x$FILE_MAN_DIR = x ; then | |
1153 | FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' | |
1154 | fi | |
1155 | ||
1156 | if test x$MISC_MAN_SUFFIX = x ; then | |
1157 | case $host_os in | |
1158 | solaris*) MISC_MAN_SUFFIX=5 ;; | |
1159 | *) MISC_MAN_SUFFIX=7 ;; | |
1160 | esac | |
1161 | fi | |
1162 | if test x$MISC_MAN_DIR = x ; then | |
1163 | MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' | |
1164 | fi | |
1165 | ||
1166 | if test x$DRIVER_MAN_SUFFIX = x ; then | |
1167 | case $host_os in | |
1168 | solaris*) DRIVER_MAN_SUFFIX=7 ;; | |
1169 | *) DRIVER_MAN_SUFFIX=4 ;; | |
1170 | esac | |
1171 | fi | |
1172 | if test x$DRIVER_MAN_DIR = x ; then | |
1173 | DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' | |
1174 | fi | |
1175 | ||
1176 | if test x$ADMIN_MAN_SUFFIX = x ; then | |
1177 | case $host_os in | |
1178 | solaris*) ADMIN_MAN_SUFFIX=1m ;; | |
1179 | *) ADMIN_MAN_SUFFIX=8 ;; | |
1180 | esac | |
1181 | fi | |
1182 | if test x$ADMIN_MAN_DIR = x ; then | |
1183 | ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' | |
1184 | fi | |
1185 | ||
1186 | ||
1187 | AC_SUBST([APP_MAN_SUFFIX]) | |
1188 | AC_SUBST([LIB_MAN_SUFFIX]) | |
1189 | AC_SUBST([FILE_MAN_SUFFIX]) | |
1190 | AC_SUBST([MISC_MAN_SUFFIX]) | |
1191 | AC_SUBST([DRIVER_MAN_SUFFIX]) | |
1192 | AC_SUBST([ADMIN_MAN_SUFFIX]) | |
1193 | AC_SUBST([APP_MAN_DIR]) | |
1194 | AC_SUBST([LIB_MAN_DIR]) | |
1195 | AC_SUBST([FILE_MAN_DIR]) | |
1196 | AC_SUBST([MISC_MAN_DIR]) | |
1197 | AC_SUBST([DRIVER_MAN_DIR]) | |
1198 | AC_SUBST([ADMIN_MAN_DIR]) | |
1199 | ||
1200 | XORG_MAN_PAGE="X Version 11" | |
1201 | AC_SUBST([XORG_MAN_PAGE]) | |
1202 | MAN_SUBSTS="\ | |
1203 | -e 's|__vendorversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ | |
1204 | -e 's|__xorgversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ | |
1205 | -e 's|__xservername__|Xorg|g' \ | |
1206 | -e 's|__xconfigfile__|xorg.conf|g' \ | |
1207 | -e 's|__projectroot__|\$(prefix)|g' \ | |
1208 | -e 's|__apploaddir__|\$(appdefaultdir)|g' \ | |
1209 | -e 's|__appmansuffix__|\$(APP_MAN_SUFFIX)|g' \ | |
1210 | -e 's|__drivermansuffix__|\$(DRIVER_MAN_SUFFIX)|g' \ | |
1211 | -e 's|__adminmansuffix__|\$(ADMIN_MAN_SUFFIX)|g' \ | |
1212 | -e 's|__libmansuffix__|\$(LIB_MAN_SUFFIX)|g' \ | |
1213 | -e 's|__miscmansuffix__|\$(MISC_MAN_SUFFIX)|g' \ | |
1214 | -e 's|__filemansuffix__|\$(FILE_MAN_SUFFIX)|g'" | |
1215 | AC_SUBST([MAN_SUBSTS]) | |
1216 | ||
1217 | ]) # XORG_MANPAGE_SECTIONS | |
1218 | ||
1219 | # XORG_CHECK_SGML_DOCTOOLS([MIN-VERSION]) | |
1220 | # ------------------------ | |
1221 | # Minimum version: 1.7.0 | |
1222 | # | |
1223 | # Defines the variable XORG_SGML_PATH containing the location of X11/defs.ent | |
1224 | # provided by xorg-sgml-doctools, if installed. | |
1225 | AC_DEFUN([XORG_CHECK_SGML_DOCTOOLS],[ | |
1226 | AC_MSG_CHECKING([for X.Org SGML entities m4_ifval([$1],[>= $1])]) | |
1227 | XORG_SGML_PATH= | |
1228 | PKG_CHECK_EXISTS([xorg-sgml-doctools m4_ifval([$1],[>= $1])], | |
1229 | [XORG_SGML_PATH=`$PKG_CONFIG --variable=sgmlrootdir xorg-sgml-doctools`], | |
1230 | [m4_ifval([$1],[:], | |
1231 | [if test x"$cross_compiling" != x"yes" ; then | |
1232 | AC_CHECK_FILE([$prefix/share/sgml/X11/defs.ent], | |
1233 | [XORG_SGML_PATH=$prefix/share/sgml]) | |
1234 | fi]) | |
1235 | ]) | |
1236 | ||
1237 | # Define variables STYLESHEET_SRCDIR and XSL_STYLESHEET containing | |
1238 | # the path and the name of the doc stylesheet | |
1239 | if test "x$XORG_SGML_PATH" != "x" ; then | |
1240 | AC_MSG_RESULT([$XORG_SGML_PATH]) | |
1241 | STYLESHEET_SRCDIR=$XORG_SGML_PATH/X11 | |
1242 | XSL_STYLESHEET=$STYLESHEET_SRCDIR/xorg.xsl | |
1243 | else | |
1244 | AC_MSG_RESULT([no]) | |
1245 | fi | |
1246 | ||
1247 | AC_SUBST(XORG_SGML_PATH) | |
1248 | AC_SUBST(STYLESHEET_SRCDIR) | |
1249 | AC_SUBST(XSL_STYLESHEET) | |
1250 | AM_CONDITIONAL([HAVE_STYLESHEETS], [test "x$XSL_STYLESHEET" != "x"]) | |
1251 | ]) # XORG_CHECK_SGML_DOCTOOLS | |
1252 | ||
1253 | # XORG_CHECK_LINUXDOC | |
1254 | # ------------------- | |
1255 | # Minimum version: 1.0.0 | |
1256 | # | |
1257 | # Defines the variable MAKE_TEXT if the necessary tools and | |
1258 | # files are found. $(MAKE_TEXT) blah.sgml will then produce blah.txt. | |
1259 | # Whether or not the necessary tools and files are found can be checked | |
1260 | # with the AM_CONDITIONAL "BUILD_LINUXDOC" | |
1261 | AC_DEFUN([XORG_CHECK_LINUXDOC],[ | |
1262 | AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) | |
1263 | AC_REQUIRE([XORG_WITH_PS2PDF]) | |
1264 | ||
1265 | AC_PATH_PROG(LINUXDOC, linuxdoc) | |
1266 | ||
1267 | AC_MSG_CHECKING([whether to build documentation]) | |
1268 | ||
1269 | if test x$XORG_SGML_PATH != x && test x$LINUXDOC != x ; then | |
1270 | BUILDDOC=yes | |
1271 | else | |
1272 | BUILDDOC=no | |
1273 | fi | |
1274 | ||
1275 | AM_CONDITIONAL(BUILD_LINUXDOC, [test x$BUILDDOC = xyes]) | |
1276 | ||
1277 | AC_MSG_RESULT([$BUILDDOC]) | |
1278 | ||
1279 | AC_MSG_CHECKING([whether to build pdf documentation]) | |
1280 | ||
1281 | if test x$have_ps2pdf != xno && test x$BUILD_PDFDOC != xno; then | |
1282 | BUILDPDFDOC=yes | |
1283 | else | |
1284 | BUILDPDFDOC=no | |
1285 | fi | |
1286 | ||
1287 | AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) | |
1288 | ||
1289 | AC_MSG_RESULT([$BUILDPDFDOC]) | |
1290 | ||
1291 | MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH GROFF_NO_SGR=y $LINUXDOC -B txt -f" | |
1292 | MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B latex --papersize=letter --output=ps" | |
1293 | MAKE_PDF="$PS2PDF" | |
1294 | MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $LINUXDOC -B html --split=0" | |
1295 | ||
1296 | AC_SUBST(MAKE_TEXT) | |
1297 | AC_SUBST(MAKE_PS) | |
1298 | AC_SUBST(MAKE_PDF) | |
1299 | AC_SUBST(MAKE_HTML) | |
1300 | ]) # XORG_CHECK_LINUXDOC | |
1301 | ||
1302 | # XORG_CHECK_DOCBOOK | |
1303 | # ------------------- | |
1304 | # Minimum version: 1.0.0 | |
1305 | # | |
1306 | # Checks for the ability to build output formats from SGML DocBook source. | |
1307 | # For XXX in {TXT, PDF, PS, HTML}, the AM_CONDITIONAL "BUILD_XXXDOC" | |
1308 | # indicates whether the necessary tools and files are found and, if set, | |
1309 | # $(MAKE_XXX) blah.sgml will produce blah.xxx. | |
1310 | AC_DEFUN([XORG_CHECK_DOCBOOK],[ | |
1311 | AC_REQUIRE([XORG_CHECK_SGML_DOCTOOLS]) | |
1312 | ||
1313 | BUILDTXTDOC=no | |
1314 | BUILDPDFDOC=no | |
1315 | BUILDPSDOC=no | |
1316 | BUILDHTMLDOC=no | |
1317 | ||
1318 | AC_PATH_PROG(DOCBOOKPS, docbook2ps) | |
1319 | AC_PATH_PROG(DOCBOOKPDF, docbook2pdf) | |
1320 | AC_PATH_PROG(DOCBOOKHTML, docbook2html) | |
1321 | AC_PATH_PROG(DOCBOOKTXT, docbook2txt) | |
1322 | ||
1323 | AC_MSG_CHECKING([whether to build text documentation]) | |
1324 | if test x$XORG_SGML_PATH != x && test x$DOCBOOKTXT != x && | |
1325 | test x$BUILD_TXTDOC != xno; then | |
1326 | BUILDTXTDOC=yes | |
1327 | fi | |
1328 | AM_CONDITIONAL(BUILD_TXTDOC, [test x$BUILDTXTDOC = xyes]) | |
1329 | AC_MSG_RESULT([$BUILDTXTDOC]) | |
1330 | ||
1331 | AC_MSG_CHECKING([whether to build PDF documentation]) | |
1332 | if test x$XORG_SGML_PATH != x && test x$DOCBOOKPDF != x && | |
1333 | test x$BUILD_PDFDOC != xno; then | |
1334 | BUILDPDFDOC=yes | |
1335 | fi | |
1336 | AM_CONDITIONAL(BUILD_PDFDOC, [test x$BUILDPDFDOC = xyes]) | |
1337 | AC_MSG_RESULT([$BUILDPDFDOC]) | |
1338 | ||
1339 | AC_MSG_CHECKING([whether to build PostScript documentation]) | |
1340 | if test x$XORG_SGML_PATH != x && test x$DOCBOOKPS != x && | |
1341 | test x$BUILD_PSDOC != xno; then | |
1342 | BUILDPSDOC=yes | |
1343 | fi | |
1344 | AM_CONDITIONAL(BUILD_PSDOC, [test x$BUILDPSDOC = xyes]) | |
1345 | AC_MSG_RESULT([$BUILDPSDOC]) | |
1346 | ||
1347 | AC_MSG_CHECKING([whether to build HTML documentation]) | |
1348 | if test x$XORG_SGML_PATH != x && test x$DOCBOOKHTML != x && | |
1349 | test x$BUILD_HTMLDOC != xno; then | |
1350 | BUILDHTMLDOC=yes | |
1351 | fi | |
1352 | AM_CONDITIONAL(BUILD_HTMLDOC, [test x$BUILDHTMLDOC = xyes]) | |
1353 | AC_MSG_RESULT([$BUILDHTMLDOC]) | |
1354 | ||
1355 | MAKE_TEXT="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKTXT" | |
1356 | MAKE_PS="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPS" | |
1357 | MAKE_PDF="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKPDF" | |
1358 | MAKE_HTML="SGML_SEARCH_PATH=$XORG_SGML_PATH $DOCBOOKHTML" | |
1359 | ||
1360 | AC_SUBST(MAKE_TEXT) | |
1361 | AC_SUBST(MAKE_PS) | |
1362 | AC_SUBST(MAKE_PDF) | |
1363 | AC_SUBST(MAKE_HTML) | |
1364 | ]) # XORG_CHECK_DOCBOOK | |
1365 | ||
1366 | # XORG_WITH_XMLTO([MIN-VERSION], [DEFAULT]) | |
1367 | # ---------------- | |
1368 | # Minimum version: 1.5.0 | |
1369 | # Minimum version for optional DEFAULT argument: 1.11.0 | |
1370 | # | |
1371 | # Documentation tools are not always available on all platforms and sometimes | |
1372 | # not at the appropriate level. This macro enables a module to test for the | |
1373 | # presence of the tool and obtain it's path in separate variables. Coupled with | |
1374 | # the --with-xmlto option, it allows maximum flexibilty in making decisions | |
1375 | # as whether or not to use the xmlto package. When DEFAULT is not specified, | |
1376 | # --with-xmlto assumes 'auto'. | |
1377 | # | |
1378 | # Interface to module: | |
1379 | # HAVE_XMLTO: used in makefiles to conditionally generate documentation | |
1380 | # XMLTO: returns the path of the xmlto program found | |
1381 | # returns the path set by the user in the environment | |
1382 | # --with-xmlto: 'yes' user instructs the module to use xmlto | |
1383 | # 'no' user instructs the module not to use xmlto | |
1384 | # | |
1385 | # Added in version 1.10.0 | |
1386 | # HAVE_XMLTO_TEXT: used in makefiles to conditionally generate text documentation | |
1387 | # xmlto for text output requires either lynx, links, or w3m browsers | |
1388 | # | |
1389 | # If the user sets the value of XMLTO, AC_PATH_PROG skips testing the path. | |
1390 | # | |
1391 | AC_DEFUN([XORG_WITH_XMLTO],[ | |
1392 | AC_ARG_VAR([XMLTO], [Path to xmlto command]) | |
1393 | m4_define([_defopt], m4_default([$2], [auto])) | |
1394 | AC_ARG_WITH(xmlto, | |
1395 | AS_HELP_STRING([--with-xmlto], | |
1396 | [Use xmlto to regenerate documentation (default: ]_defopt[)]), | |
1397 | [use_xmlto=$withval], [use_xmlto=]_defopt) | |
1398 | m4_undefine([_defopt]) | |
1399 | ||
1400 | if test "x$use_xmlto" = x"auto"; then | |
1401 | AC_PATH_PROG([XMLTO], [xmlto]) | |
1402 | if test "x$XMLTO" = "x"; then | |
1403 | AC_MSG_WARN([xmlto not found - documentation targets will be skipped]) | |
1404 | have_xmlto=no | |
1405 | else | |
1406 | have_xmlto=yes | |
1407 | fi | |
1408 | elif test "x$use_xmlto" = x"yes" ; then | |
1409 | AC_PATH_PROG([XMLTO], [xmlto]) | |
1410 | if test "x$XMLTO" = "x"; then | |
1411 | AC_MSG_ERROR([--with-xmlto=yes specified but xmlto not found in PATH]) | |
1412 | fi | |
1413 | have_xmlto=yes | |
1414 | elif test "x$use_xmlto" = x"no" ; then | |
1415 | if test "x$XMLTO" != "x"; then | |
1416 | AC_MSG_WARN([ignoring XMLTO environment variable since --with-xmlto=no was specified]) | |
1417 | fi | |
1418 | have_xmlto=no | |
1419 | else | |
1420 | AC_MSG_ERROR([--with-xmlto expects 'yes' or 'no']) | |
1421 | fi | |
1422 | ||
1423 | # Test for a minimum version of xmlto, if provided. | |
1424 | m4_ifval([$1], | |
1425 | [if test "$have_xmlto" = yes; then | |
1426 | # scrape the xmlto version | |
1427 | AC_MSG_CHECKING([the xmlto version]) | |
1428 | xmlto_version=`$XMLTO --version 2>/dev/null | cut -d' ' -f3` | |
1429 | AC_MSG_RESULT([$xmlto_version]) | |
1430 | AS_VERSION_COMPARE([$xmlto_version], [$1], | |
1431 | [if test "x$use_xmlto" = xauto; then | |
1432 | AC_MSG_WARN([xmlto version $xmlto_version found, but $1 needed]) | |
1433 | have_xmlto=no | |
1434 | else | |
1435 | AC_MSG_ERROR([xmlto version $xmlto_version found, but $1 needed]) | |
1436 | fi]) | |
1437 | fi]) | |
1438 | ||
1439 | # Test for the ability of xmlto to generate a text target | |
1440 | have_xmlto_text=no | |
1441 | cat > conftest.xml << "EOF" | |
1442 | EOF | |
1443 | AS_IF([test "$have_xmlto" = yes], | |
1444 | [AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1], | |
1445 | [have_xmlto_text=yes], | |
1446 | [AC_MSG_WARN([xmlto cannot generate text format, this format skipped])])]) | |
1447 | rm -f conftest.xml | |
1448 | AM_CONDITIONAL([HAVE_XMLTO_TEXT], [test $have_xmlto_text = yes]) | |
1449 | AM_CONDITIONAL([HAVE_XMLTO], [test "$have_xmlto" = yes]) | |
1450 | ]) # XORG_WITH_XMLTO | |
1451 | ||
1452 | # XORG_WITH_ASCIIDOC([MIN-VERSION], [DEFAULT]) | |
1453 | # ---------------- | |
1454 | # Minimum version: 1.5.0 | |
1455 | # Minimum version for optional DEFAULT argument: 1.11.0 | |
1456 | # | |
1457 | # Documentation tools are not always available on all platforms and sometimes | |
1458 | # not at the appropriate level. This macro enables a module to test for the | |
1459 | # presence of the tool and obtain it's path in separate variables. Coupled with | |
1460 | # the --with-asciidoc option, it allows maximum flexibilty in making decisions | |
1461 | # as whether or not to use the asciidoc package. When DEFAULT is not specified, | |
1462 | # --with-asciidoc assumes 'auto'. | |
1463 | # | |
1464 | # Interface to module: | |
1465 | # HAVE_ASCIIDOC: used in makefiles to conditionally generate documentation | |
1466 | # ASCIIDOC: returns the path of the asciidoc program found | |
1467 | # returns the path set by the user in the environment | |
1468 | # --with-asciidoc: 'yes' user instructs the module to use asciidoc | |
1469 | # 'no' user instructs the module not to use asciidoc | |
1470 | # | |
1471 | # If the user sets the value of ASCIIDOC, AC_PATH_PROG skips testing the path. | |
1472 | # | |
1473 | AC_DEFUN([XORG_WITH_ASCIIDOC],[ | |
1474 | AC_ARG_VAR([ASCIIDOC], [Path to asciidoc command]) | |
1475 | m4_define([_defopt], m4_default([$2], [auto])) | |
1476 | AC_ARG_WITH(asciidoc, | |
1477 | AS_HELP_STRING([--with-asciidoc], | |
1478 | [Use asciidoc to regenerate documentation (default: ]_defopt[)]), | |
1479 | [use_asciidoc=$withval], [use_asciidoc=]_defopt) | |
1480 | m4_undefine([_defopt]) | |
1481 | ||
1482 | if test "x$use_asciidoc" = x"auto"; then | |
1483 | AC_PATH_PROG([ASCIIDOC], [asciidoc]) | |
1484 | if test "x$ASCIIDOC" = "x"; then | |
1485 | AC_MSG_WARN([asciidoc not found - documentation targets will be skipped]) | |
1486 | have_asciidoc=no | |
1487 | else | |
1488 | have_asciidoc=yes | |
1489 | fi | |
1490 | elif test "x$use_asciidoc" = x"yes" ; then | |
1491 | AC_PATH_PROG([ASCIIDOC], [asciidoc]) | |
1492 | if test "x$ASCIIDOC" = "x"; then | |
1493 | AC_MSG_ERROR([--with-asciidoc=yes specified but asciidoc not found in PATH]) | |
1494 | fi | |
1495 | have_asciidoc=yes | |
1496 | elif test "x$use_asciidoc" = x"no" ; then | |
1497 | if test "x$ASCIIDOC" != "x"; then | |
1498 | AC_MSG_WARN([ignoring ASCIIDOC environment variable since --with-asciidoc=no was specified]) | |
1499 | fi | |
1500 | have_asciidoc=no | |
1501 | else | |
1502 | AC_MSG_ERROR([--with-asciidoc expects 'yes' or 'no']) | |
1503 | fi | |
1504 | m4_ifval([$1], | |
1505 | [if test "$have_asciidoc" = yes; then | |
1506 | # scrape the asciidoc version | |
1507 | AC_MSG_CHECKING([the asciidoc version]) | |
1508 | asciidoc_version=`$ASCIIDOC --version 2>/dev/null | cut -d' ' -f2` | |
1509 | AC_MSG_RESULT([$asciidoc_version]) | |
1510 | AS_VERSION_COMPARE([$asciidoc_version], [$1], | |
1511 | [if test "x$use_asciidoc" = xauto; then | |
1512 | AC_MSG_WARN([asciidoc version $asciidoc_version found, but $1 needed]) | |
1513 | have_asciidoc=no | |
1514 | else | |
1515 | AC_MSG_ERROR([asciidoc version $asciidoc_version found, but $1 needed]) | |
1516 | fi]) | |
1517 | fi]) | |
1518 | AM_CONDITIONAL([HAVE_ASCIIDOC], [test "$have_asciidoc" = yes]) | |
1519 | ]) # XORG_WITH_ASCIIDOC | |
1520 | ||
1521 | # XORG_WITH_DOXYGEN([MIN-VERSION], [DEFAULT]) | |
1522 | # -------------------------------- | |
1523 | # Minimum version: 1.5.0 | |
1524 | # Minimum version for optional DEFAULT argument: 1.11.0 | |
1525 | # | |
1526 | # Documentation tools are not always available on all platforms and sometimes | |
1527 | # not at the appropriate level. This macro enables a module to test for the | |
1528 | # presence of the tool and obtain it's path in separate variables. Coupled with | |
1529 | # the --with-doxygen option, it allows maximum flexibilty in making decisions | |
1530 | # as whether or not to use the doxygen package. When DEFAULT is not specified, | |
1531 | # --with-doxygen assumes 'auto'. | |
1532 | # | |
1533 | # Interface to module: | |
1534 | # HAVE_DOXYGEN: used in makefiles to conditionally generate documentation | |
1535 | # DOXYGEN: returns the path of the doxygen program found | |
1536 | # returns the path set by the user in the environment | |
1537 | # --with-doxygen: 'yes' user instructs the module to use doxygen | |
1538 | # 'no' user instructs the module not to use doxygen | |
1539 | # | |
1540 | # If the user sets the value of DOXYGEN, AC_PATH_PROG skips testing the path. | |
1541 | # | |
1542 | AC_DEFUN([XORG_WITH_DOXYGEN],[ | |
1543 | AC_ARG_VAR([DOXYGEN], [Path to doxygen command]) | |
1544 | m4_define([_defopt], m4_default([$2], [auto])) | |
1545 | AC_ARG_WITH(doxygen, | |
1546 | AS_HELP_STRING([--with-doxygen], | |
1547 | [Use doxygen to regenerate documentation (default: ]_defopt[)]), | |
1548 | [use_doxygen=$withval], [use_doxygen=]_defopt) | |
1549 | m4_undefine([_defopt]) | |
1550 | ||
1551 | if test "x$use_doxygen" = x"auto"; then | |
1552 | AC_PATH_PROG([DOXYGEN], [doxygen]) | |
1553 | if test "x$DOXYGEN" = "x"; then | |
1554 | AC_MSG_WARN([doxygen not found - documentation targets will be skipped]) | |
1555 | have_doxygen=no | |
1556 | else | |
1557 | have_doxygen=yes | |
1558 | fi | |
1559 | elif test "x$use_doxygen" = x"yes" ; then | |
1560 | AC_PATH_PROG([DOXYGEN], [doxygen]) | |
1561 | if test "x$DOXYGEN" = "x"; then | |
1562 | AC_MSG_ERROR([--with-doxygen=yes specified but doxygen not found in PATH]) | |
1563 | fi | |
1564 | have_doxygen=yes | |
1565 | elif test "x$use_doxygen" = x"no" ; then | |
1566 | if test "x$DOXYGEN" != "x"; then | |
1567 | AC_MSG_WARN([ignoring DOXYGEN environment variable since --with-doxygen=no was specified]) | |
1568 | fi | |
1569 | have_doxygen=no | |
1570 | else | |
1571 | AC_MSG_ERROR([--with-doxygen expects 'yes' or 'no']) | |
1572 | fi | |
1573 | m4_ifval([$1], | |
1574 | [if test "$have_doxygen" = yes; then | |
1575 | # scrape the doxygen version | |
1576 | AC_MSG_CHECKING([the doxygen version]) | |
1577 | doxygen_version=`$DOXYGEN --version 2>/dev/null` | |
1578 | AC_MSG_RESULT([$doxygen_version]) | |
1579 | AS_VERSION_COMPARE([$doxygen_version], [$1], | |
1580 | [if test "x$use_doxygen" = xauto; then | |
1581 | AC_MSG_WARN([doxygen version $doxygen_version found, but $1 needed]) | |
1582 | have_doxygen=no | |
1583 | else | |
1584 | AC_MSG_ERROR([doxygen version $doxygen_version found, but $1 needed]) | |
1585 | fi]) | |
1586 | fi]) | |
1587 | AM_CONDITIONAL([HAVE_DOXYGEN], [test "$have_doxygen" = yes]) | |
1588 | ]) # XORG_WITH_DOXYGEN | |
1589 | ||
1590 | # XORG_WITH_GROFF([DEFAULT]) | |
1591 | # ---------------- | |
1592 | # Minimum version: 1.6.0 | |
1593 | # Minimum version for optional DEFAULT argument: 1.11.0 | |
1594 | # | |
1595 | # Documentation tools are not always available on all platforms and sometimes | |
1596 | # not at the appropriate level. This macro enables a module to test for the | |
1597 | # presence of the tool and obtain it's path in separate variables. Coupled with | |
1598 | # the --with-groff option, it allows maximum flexibilty in making decisions | |
1599 | # as whether or not to use the groff package. When DEFAULT is not specified, | |
1600 | # --with-groff assumes 'auto'. | |
1601 | # | |
1602 | # Interface to module: | |
1603 | # HAVE_GROFF: used in makefiles to conditionally generate documentation | |
1604 | # HAVE_GROFF_MM: the memorandum macros (-mm) package | |
1605 | # HAVE_GROFF_MS: the -ms macros package | |
1606 | # GROFF: returns the path of the groff program found | |
1607 | # returns the path set by the user in the environment | |
1608 | # --with-groff: 'yes' user instructs the module to use groff | |
1609 | # 'no' user instructs the module not to use groff | |
1610 | # | |
1611 | # Added in version 1.9.0: | |
1612 | # HAVE_GROFF_HTML: groff has dependencies to output HTML format: | |
1613 | # pnmcut pnmcrop pnmtopng pnmtops from the netpbm package. | |
1614 | # psselect from the psutils package. | |
1615 | # the ghostcript package. Refer to the grohtml man pages | |
1616 | # | |
1617 | # If the user sets the value of GROFF, AC_PATH_PROG skips testing the path. | |
1618 | # | |
1619 | # OS and distros often splits groff in a basic and full package, the former | |
1620 | # having the groff program and the later having devices, fonts and macros | |
1621 | # Checking for the groff executable is not enough. | |
1622 | # | |
1623 | # If macros are missing, we cannot assume that groff is useless, so we don't | |
1624 | # unset HAVE_GROFF or GROFF env variables. | |
1625 | # HAVE_GROFF_?? can never be true while HAVE_GROFF is false. | |
1626 | # | |
1627 | AC_DEFUN([XORG_WITH_GROFF],[ | |
1628 | AC_ARG_VAR([GROFF], [Path to groff command]) | |
1629 | m4_define([_defopt], m4_default([$1], [auto])) | |
1630 | AC_ARG_WITH(groff, | |
1631 | AS_HELP_STRING([--with-groff], | |
1632 | [Use groff to regenerate documentation (default: ]_defopt[)]), | |
1633 | [use_groff=$withval], [use_groff=]_defopt) | |
1634 | m4_undefine([_defopt]) | |
1635 | ||
1636 | if test "x$use_groff" = x"auto"; then | |
1637 | AC_PATH_PROG([GROFF], [groff]) | |
1638 | if test "x$GROFF" = "x"; then | |
1639 | AC_MSG_WARN([groff not found - documentation targets will be skipped]) | |
1640 | have_groff=no | |
1641 | else | |
1642 | have_groff=yes | |
1643 | fi | |
1644 | elif test "x$use_groff" = x"yes" ; then | |
1645 | AC_PATH_PROG([GROFF], [groff]) | |
1646 | if test "x$GROFF" = "x"; then | |
1647 | AC_MSG_ERROR([--with-groff=yes specified but groff not found in PATH]) | |
1648 | fi | |
1649 | have_groff=yes | |
1650 | elif test "x$use_groff" = x"no" ; then | |
1651 | if test "x$GROFF" != "x"; then | |
1652 | AC_MSG_WARN([ignoring GROFF environment variable since --with-groff=no was specified]) | |
1653 | fi | |
1654 | have_groff=no | |
1655 | else | |
1656 | AC_MSG_ERROR([--with-groff expects 'yes' or 'no']) | |
1657 | fi | |
1658 | ||
1659 | # We have groff, test for the presence of the macro packages | |
1660 | if test "x$have_groff" = x"yes"; then | |
1661 | AC_MSG_CHECKING([for ${GROFF} -ms macros]) | |
1662 | if ${GROFF} -ms -I. /dev/null >/dev/null 2>&1 ; then | |
1663 | groff_ms_works=yes | |
1664 | else | |
1665 | groff_ms_works=no | |
1666 | fi | |
1667 | AC_MSG_RESULT([$groff_ms_works]) | |
1668 | AC_MSG_CHECKING([for ${GROFF} -mm macros]) | |
1669 | if ${GROFF} -mm -I. /dev/null >/dev/null 2>&1 ; then | |
1670 | groff_mm_works=yes | |
1671 | else | |
1672 | groff_mm_works=no | |
1673 | fi | |
1674 | AC_MSG_RESULT([$groff_mm_works]) | |
1675 | fi | |
1676 | ||
1677 | # We have groff, test for HTML dependencies, one command per package | |
1678 | if test "x$have_groff" = x"yes"; then | |
1679 | AC_PATH_PROGS(GS_PATH, [gs gswin32c]) | |
1680 | AC_PATH_PROG(PNMTOPNG_PATH, [pnmtopng]) | |
1681 | AC_PATH_PROG(PSSELECT_PATH, [psselect]) | |
1682 | if test "x$GS_PATH" != "x" -a "x$PNMTOPNG_PATH" != "x" -a "x$PSSELECT_PATH" != "x"; then | |
1683 | have_groff_html=yes | |
1684 | else | |
1685 | have_groff_html=no | |
1686 | AC_MSG_WARN([grohtml dependencies not found - HTML Documentation skipped. Refer to grohtml man pages]) | |
1687 | fi | |
1688 | fi | |
1689 | ||
1690 | # Set Automake conditionals for Makefiles | |
1691 | AM_CONDITIONAL([HAVE_GROFF], [test "$have_groff" = yes]) | |
1692 | AM_CONDITIONAL([HAVE_GROFF_MS], [test "$groff_ms_works" = yes]) | |
1693 | AM_CONDITIONAL([HAVE_GROFF_MM], [test "$groff_mm_works" = yes]) | |
1694 | AM_CONDITIONAL([HAVE_GROFF_HTML], [test "$have_groff_html" = yes]) | |
1695 | ]) # XORG_WITH_GROFF | |
1696 | ||
1697 | # XORG_WITH_FOP([DEFAULT]) | |
1698 | # ---------------- | |
1699 | # Minimum version: 1.6.0 | |
1700 | # Minimum version for optional DEFAULT argument: 1.11.0 | |
1701 | # | |
1702 | # Documentation tools are not always available on all platforms and sometimes | |
1703 | # not at the appropriate level. This macro enables a module to test for the | |
1704 | # presence of the tool and obtain it's path in separate variables. Coupled with | |
1705 | # the --with-fop option, it allows maximum flexibilty in making decisions | |
1706 | # as whether or not to use the fop package. When DEFAULT is not specified, | |
1707 | # --with-fop assumes 'auto'. | |
1708 | # | |
1709 | # Interface to module: | |
1710 | # HAVE_FOP: used in makefiles to conditionally generate documentation | |
1711 | # FOP: returns the path of the fop program found | |
1712 | # returns the path set by the user in the environment | |
1713 | # --with-fop: 'yes' user instructs the module to use fop | |
1714 | # 'no' user instructs the module not to use fop | |
1715 | # | |
1716 | # If the user sets the value of FOP, AC_PATH_PROG skips testing the path. | |
1717 | # | |
1718 | AC_DEFUN([XORG_WITH_FOP],[ | |
1719 | AC_ARG_VAR([FOP], [Path to fop command]) | |
1720 | m4_define([_defopt], m4_default([$1], [auto])) | |
1721 | AC_ARG_WITH(fop, | |
1722 | AS_HELP_STRING([--with-fop], | |
1723 | [Use fop to regenerate documentation (default: ]_defopt[)]), | |
1724 | [use_fop=$withval], [use_fop=]_defopt) | |
1725 | m4_undefine([_defopt]) | |
1726 | ||
1727 | if test "x$use_fop" = x"auto"; then | |
1728 | AC_PATH_PROG([FOP], [fop]) | |
1729 | if test "x$FOP" = "x"; then | |
1730 | AC_MSG_WARN([fop not found - documentation targets will be skipped]) | |
1731 | have_fop=no | |
1732 | else | |
1733 | have_fop=yes | |
1734 | fi | |
1735 | elif test "x$use_fop" = x"yes" ; then | |
1736 | AC_PATH_PROG([FOP], [fop]) | |
1737 | if test "x$FOP" = "x"; then | |
1738 | AC_MSG_ERROR([--with-fop=yes specified but fop not found in PATH]) | |
1739 | fi | |
1740 | have_fop=yes | |
1741 | elif test "x$use_fop" = x"no" ; then | |
1742 | if test "x$FOP" != "x"; then | |
1743 | AC_MSG_WARN([ignoring FOP environment variable since --with-fop=no was specified]) | |
1744 | fi | |
1745 | have_fop=no | |
1746 | else | |
1747 | AC_MSG_ERROR([--with-fop expects 'yes' or 'no']) | |
1748 | fi | |
1749 | AM_CONDITIONAL([HAVE_FOP], [test "$have_fop" = yes]) | |
1750 | ]) # XORG_WITH_FOP | |
1751 | ||
1752 | # XORG_WITH_PS2PDF([DEFAULT]) | |
1753 | # ---------------- | |
1754 | # Minimum version: 1.6.0 | |
1755 | # Minimum version for optional DEFAULT argument: 1.11.0 | |
1756 | # | |
1757 | # Documentation tools are not always available on all platforms and sometimes | |
1758 | # not at the appropriate level. This macro enables a module to test for the | |
1759 | # presence of the tool and obtain it's path in separate variables. Coupled with | |
1760 | # the --with-ps2pdf option, it allows maximum flexibilty in making decisions | |
1761 | # as whether or not to use the ps2pdf package. When DEFAULT is not specified, | |
1762 | # --with-ps2pdf assumes 'auto'. | |
1763 | # | |
1764 | # Interface to module: | |
1765 | # HAVE_PS2PDF: used in makefiles to conditionally generate documentation | |
1766 | # PS2PDF: returns the path of the ps2pdf program found | |
1767 | # returns the path set by the user in the environment | |
1768 | # --with-ps2pdf: 'yes' user instructs the module to use ps2pdf | |
1769 | # 'no' user instructs the module not to use ps2pdf | |
1770 | # | |
1771 | # If the user sets the value of PS2PDF, AC_PATH_PROG skips testing the path. | |
1772 | # | |
1773 | AC_DEFUN([XORG_WITH_PS2PDF],[ | |
1774 | AC_ARG_VAR([PS2PDF], [Path to ps2pdf command]) | |
1775 | m4_define([_defopt], m4_default([$1], [auto])) | |
1776 | AC_ARG_WITH(ps2pdf, | |
1777 | AS_HELP_STRING([--with-ps2pdf], | |
1778 | [Use ps2pdf to regenerate documentation (default: ]_defopt[)]), | |
1779 | [use_ps2pdf=$withval], [use_ps2pdf=]_defopt) | |
1780 | m4_undefine([_defopt]) | |
1781 | ||
1782 | if test "x$use_ps2pdf" = x"auto"; then | |
1783 | AC_PATH_PROG([PS2PDF], [ps2pdf]) | |
1784 | if test "x$PS2PDF" = "x"; then | |
1785 | AC_MSG_WARN([ps2pdf not found - documentation targets will be skipped]) | |
1786 | have_ps2pdf=no | |
1787 | else | |
1788 | have_ps2pdf=yes | |
1789 | fi | |
1790 | elif test "x$use_ps2pdf" = x"yes" ; then | |
1791 | AC_PATH_PROG([PS2PDF], [ps2pdf]) | |
1792 | if test "x$PS2PDF" = "x"; then | |
1793 | AC_MSG_ERROR([--with-ps2pdf=yes specified but ps2pdf not found in PATH]) | |
1794 | fi | |
1795 | have_ps2pdf=yes | |
1796 | elif test "x$use_ps2pdf" = x"no" ; then | |
1797 | if test "x$PS2PDF" != "x"; then | |
1798 | AC_MSG_WARN([ignoring PS2PDF environment variable since --with-ps2pdf=no was specified]) | |
1799 | fi | |
1800 | have_ps2pdf=no | |
1801 | else | |
1802 | AC_MSG_ERROR([--with-ps2pdf expects 'yes' or 'no']) | |
1803 | fi | |
1804 | AM_CONDITIONAL([HAVE_PS2PDF], [test "$have_ps2pdf" = yes]) | |
1805 | ]) # XORG_WITH_PS2PDF | |
1806 | ||
1807 | # XORG_ENABLE_DOCS (enable_docs=yes) | |
1808 | # ---------------- | |
1809 | # Minimum version: 1.6.0 | |
1810 | # | |
1811 | # Documentation tools are not always available on all platforms and sometimes | |
1812 | # not at the appropriate level. This macro enables a builder to skip all | |
1813 | # documentation targets except traditional man pages. | |
1814 | # Combined with the specific tool checking macros XORG_WITH_*, it provides | |
1815 | # maximum flexibilty in controlling documentation building. | |
1816 | # Refer to: | |
1817 | # XORG_WITH_XMLTO --with-xmlto | |
1818 | # XORG_WITH_ASCIIDOC --with-asciidoc | |
1819 | # XORG_WITH_DOXYGEN --with-doxygen | |
1820 | # XORG_WITH_FOP --with-fop | |
1821 | # XORG_WITH_GROFF --with-groff | |
1822 | # XORG_WITH_PS2PDF --with-ps2pdf | |
1823 | # | |
1824 | # Interface to module: | |
1825 | # ENABLE_DOCS: used in makefiles to conditionally generate documentation | |
1826 | # --enable-docs: 'yes' user instructs the module to generate docs | |
1827 | # 'no' user instructs the module not to generate docs | |
1828 | # parm1: specify the default value, yes or no. | |
1829 | # | |
1830 | AC_DEFUN([XORG_ENABLE_DOCS],[ | |
1831 | m4_define([docs_default], m4_default([$1], [yes])) | |
1832 | AC_ARG_ENABLE(docs, | |
1833 | AS_HELP_STRING([--enable-docs], | |
1834 | [Enable building the documentation (default: ]docs_default[)]), | |
1835 | [build_docs=$enableval], [build_docs=]docs_default) | |
1836 | m4_undefine([docs_default]) | |
1837 | AM_CONDITIONAL(ENABLE_DOCS, [test x$build_docs = xyes]) | |
1838 | AC_MSG_CHECKING([whether to build documentation]) | |
1839 | AC_MSG_RESULT([$build_docs]) | |
1840 | ]) # XORG_ENABLE_DOCS | |
1841 | ||
1842 | # XORG_ENABLE_DEVEL_DOCS (enable_devel_docs=yes) | |
1843 | # ---------------- | |
1844 | # Minimum version: 1.6.0 | |
1845 | # | |
1846 | # This macro enables a builder to skip all developer documentation. | |
1847 | # Combined with the specific tool checking macros XORG_WITH_*, it provides | |
1848 | # maximum flexibilty in controlling documentation building. | |
1849 | # Refer to: | |
1850 | # XORG_WITH_XMLTO --with-xmlto | |
1851 | # XORG_WITH_ASCIIDOC --with-asciidoc | |
1852 | # XORG_WITH_DOXYGEN --with-doxygen | |
1853 | # XORG_WITH_FOP --with-fop | |
1854 | # XORG_WITH_GROFF --with-groff | |
1855 | # XORG_WITH_PS2PDF --with-ps2pdf | |
1856 | # | |
1857 | # Interface to module: | |
1858 | # ENABLE_DEVEL_DOCS: used in makefiles to conditionally generate developer docs | |
1859 | # --enable-devel-docs: 'yes' user instructs the module to generate developer docs | |
1860 | # 'no' user instructs the module not to generate developer docs | |
1861 | # parm1: specify the default value, yes or no. | |
1862 | # | |
1863 | AC_DEFUN([XORG_ENABLE_DEVEL_DOCS],[ | |
1864 | m4_define([devel_default], m4_default([$1], [yes])) | |
1865 | AC_ARG_ENABLE(devel-docs, | |
1866 | AS_HELP_STRING([--enable-devel-docs], | |
1867 | [Enable building the developer documentation (default: ]devel_default[)]), | |
1868 | [build_devel_docs=$enableval], [build_devel_docs=]devel_default) | |
1869 | m4_undefine([devel_default]) | |
1870 | AM_CONDITIONAL(ENABLE_DEVEL_DOCS, [test x$build_devel_docs = xyes]) | |
1871 | AC_MSG_CHECKING([whether to build developer documentation]) | |
1872 | AC_MSG_RESULT([$build_devel_docs]) | |
1873 | ]) # XORG_ENABLE_DEVEL_DOCS | |
1874 | ||
1875 | # XORG_ENABLE_SPECS (enable_specs=yes) | |
1876 | # ---------------- | |
1877 | # Minimum version: 1.6.0 | |
1878 | # | |
1879 | # This macro enables a builder to skip all functional specification targets. | |
1880 | # Combined with the specific tool checking macros XORG_WITH_*, it provides | |
1881 | # maximum flexibilty in controlling documentation building. | |
1882 | # Refer to: | |
1883 | # XORG_WITH_XMLTO --with-xmlto | |
1884 | # XORG_WITH_ASCIIDOC --with-asciidoc | |
1885 | # XORG_WITH_DOXYGEN --with-doxygen | |
1886 | # XORG_WITH_FOP --with-fop | |
1887 | # XORG_WITH_GROFF --with-groff | |
1888 | # XORG_WITH_PS2PDF --with-ps2pdf | |
1889 | # | |
1890 | # Interface to module: | |
1891 | # ENABLE_SPECS: used in makefiles to conditionally generate specs | |
1892 | # --enable-specs: 'yes' user instructs the module to generate specs | |
1893 | # 'no' user instructs the module not to generate specs | |
1894 | # parm1: specify the default value, yes or no. | |
1895 | # | |
1896 | AC_DEFUN([XORG_ENABLE_SPECS],[ | |
1897 | m4_define([spec_default], m4_default([$1], [yes])) | |
1898 | AC_ARG_ENABLE(specs, | |
1899 | AS_HELP_STRING([--enable-specs], | |
1900 | [Enable building the specs (default: ]spec_default[)]), | |
1901 | [build_specs=$enableval], [build_specs=]spec_default) | |
1902 | m4_undefine([spec_default]) | |
1903 | AM_CONDITIONAL(ENABLE_SPECS, [test x$build_specs = xyes]) | |
1904 | AC_MSG_CHECKING([whether to build functional specifications]) | |
1905 | AC_MSG_RESULT([$build_specs]) | |
1906 | ]) # XORG_ENABLE_SPECS | |
1907 | ||
1908 | # XORG_CHECK_MALLOC_ZERO | |
1909 | # ---------------------- | |
1910 | # Minimum version: 1.0.0 | |
1911 | # | |
1912 | # Defines {MALLOC,XMALLOC,XTMALLOC}_ZERO_CFLAGS appropriately if | |
1913 | # malloc(0) returns NULL. Packages should add one of these cflags to | |
1914 | # their AM_CFLAGS (or other appropriate *_CFLAGS) to use them. | |
1915 | AC_DEFUN([XORG_CHECK_MALLOC_ZERO],[ | |
1916 | AC_ARG_ENABLE(malloc0returnsnull, | |
1917 | AS_HELP_STRING([--enable-malloc0returnsnull], | |
1918 | [malloc(0) returns NULL (default: auto)]), | |
1919 | [MALLOC_ZERO_RETURNS_NULL=$enableval], | |
1920 | [MALLOC_ZERO_RETURNS_NULL=auto]) | |
1921 | ||
1922 | AC_MSG_CHECKING([whether malloc(0) returns NULL]) | |
1923 | if test "x$MALLOC_ZERO_RETURNS_NULL" = xauto; then | |
1924 | AC_RUN_IFELSE([ | |
1925 | char *malloc(); | |
1926 | char *realloc(); | |
1927 | char *calloc(); | |
1928 | main() { | |
1929 | char *m0, *r0, *c0, *p; | |
1930 | m0 = malloc(0); | |
1931 | p = malloc(10); | |
1932 | r0 = realloc(p,0); | |
1933 | c0 = calloc(0); | |
1934 | exit(m0 == 0 || r0 == 0 || c0 == 0 ? 0 : 1); | |
1935 | }], | |
1936 | [MALLOC_ZERO_RETURNS_NULL=yes], | |
1937 | [MALLOC_ZERO_RETURNS_NULL=no], | |
1938 | [MALLOC_ZERO_RETURNS_NULL=yes]) | |
1939 | fi | |
1940 | AC_MSG_RESULT([$MALLOC_ZERO_RETURNS_NULL]) | |
1941 | ||
1942 | if test "x$MALLOC_ZERO_RETURNS_NULL" = xyes; then | |
1943 | MALLOC_ZERO_CFLAGS="-DMALLOC_0_RETURNS_NULL" | |
1944 | XMALLOC_ZERO_CFLAGS=$MALLOC_ZERO_CFLAGS | |
1945 | XTMALLOC_ZERO_CFLAGS="$MALLOC_ZERO_CFLAGS -DXTMALLOC_BC" | |
1946 | else | |
1947 | MALLOC_ZERO_CFLAGS="" | |
1948 | XMALLOC_ZERO_CFLAGS="" | |
1949 | XTMALLOC_ZERO_CFLAGS="" | |
1950 | fi | |
1951 | ||
1952 | AC_SUBST([MALLOC_ZERO_CFLAGS]) | |
1953 | AC_SUBST([XMALLOC_ZERO_CFLAGS]) | |
1954 | AC_SUBST([XTMALLOC_ZERO_CFLAGS]) | |
1955 | ]) # XORG_CHECK_MALLOC_ZERO | |
1956 | ||
1957 | # XORG_WITH_LINT() | |
1958 | # ---------------- | |
1959 | # Minimum version: 1.1.0 | |
1960 | # | |
1961 | # This macro enables the use of a tool that flags some suspicious and | |
1962 | # non-portable constructs (likely to be bugs) in C language source code. | |
1963 | # It will attempt to locate the tool and use appropriate options. | |
1964 | # There are various lint type tools on different platforms. | |
1965 | # | |
1966 | # Interface to module: | |
1967 | # LINT: returns the path to the tool found on the platform | |
1968 | # or the value set to LINT on the configure cmd line | |
1969 | # also an Automake conditional | |
1970 | # LINT_FLAGS: an Automake variable with appropriate flags | |
1971 | # | |
1972 | # --with-lint: 'yes' user instructs the module to use lint | |
1973 | # 'no' user instructs the module not to use lint (default) | |
1974 | # | |
1975 | # If the user sets the value of LINT, AC_PATH_PROG skips testing the path. | |
1976 | # If the user sets the value of LINT_FLAGS, they are used verbatim. | |
1977 | # | |
1978 | AC_DEFUN([XORG_WITH_LINT],[ | |
1979 | ||
1980 | AC_ARG_VAR([LINT], [Path to a lint-style command]) | |
1981 | AC_ARG_VAR([LINT_FLAGS], [Flags for the lint-style command]) | |
1982 | AC_ARG_WITH(lint, [AS_HELP_STRING([--with-lint], | |
1983 | [Use a lint-style source code checker (default: disabled)])], | |
1984 | [use_lint=$withval], [use_lint=no]) | |
1985 | ||
1986 | # Obtain platform specific info like program name and options | |
1987 | # The lint program on FreeBSD and NetBSD is different from the one on Solaris | |
1988 | case $host_os in | |
1989 | *linux* | *openbsd* | kfreebsd*-gnu | darwin* | cygwin*) | |
1990 | lint_name=splint | |
1991 | lint_options="-badflag" | |
1992 | ;; | |
1993 | *freebsd* | *netbsd*) | |
1994 | lint_name=lint | |
1995 | lint_options="-u -b" | |
1996 | ;; | |
1997 | *solaris*) | |
1998 | lint_name=lint | |
1999 | lint_options="-u -b -h -erroff=E_INDISTING_FROM_TRUNC2" | |
2000 | ;; | |
2001 | esac | |
2002 | ||
2003 | # Test for the presence of the program (either guessed by the code or spelled out by the user) | |
2004 | if test "x$use_lint" = x"yes" ; then | |
2005 | AC_PATH_PROG([LINT], [$lint_name]) | |
2006 | if test "x$LINT" = "x"; then | |
2007 | AC_MSG_ERROR([--with-lint=yes specified but lint-style tool not found in PATH]) | |
2008 | fi | |
2009 | elif test "x$use_lint" = x"no" ; then | |
2010 | if test "x$LINT" != "x"; then | |
2011 | AC_MSG_WARN([ignoring LINT environment variable since --with-lint=no was specified]) | |
2012 | fi | |
2013 | else | |
2014 | AC_MSG_ERROR([--with-lint expects 'yes' or 'no'. Use LINT variable to specify path.]) | |
2015 | fi | |
2016 | ||
2017 | # User supplied flags override default flags | |
2018 | if test "x$LINT_FLAGS" != "x"; then | |
2019 | lint_options=$LINT_FLAGS | |
2020 | fi | |
2021 | ||
2022 | AC_SUBST([LINT_FLAGS],[$lint_options]) | |
2023 | AM_CONDITIONAL(LINT, [test "x$LINT" != x]) | |
2024 | ||
2025 | ]) # XORG_WITH_LINT | |
2026 | ||
2027 | # XORG_LINT_LIBRARY(LIBNAME) | |
2028 | # -------------------------- | |
2029 | # Minimum version: 1.1.0 | |
2030 | # | |
2031 | # Sets up flags for building lint libraries for checking programs that call | |
2032 | # functions in the library. | |
2033 | # | |
2034 | # Interface to module: | |
2035 | # LINTLIB - Automake variable with the name of lint library file to make | |
2036 | # MAKE_LINT_LIB - Automake conditional | |
2037 | # | |
2038 | # --enable-lint-library: - 'yes' user instructs the module to created a lint library | |
2039 | # - 'no' user instructs the module not to create a lint library (default) | |
2040 | ||
2041 | AC_DEFUN([XORG_LINT_LIBRARY],[ | |
2042 | AC_REQUIRE([XORG_WITH_LINT]) | |
2043 | AC_ARG_ENABLE(lint-library, [AS_HELP_STRING([--enable-lint-library], | |
2044 | [Create lint library (default: disabled)])], | |
2045 | [make_lint_lib=$enableval], [make_lint_lib=no]) | |
2046 | ||
2047 | if test "x$make_lint_lib" = x"yes" ; then | |
2048 | LINTLIB=llib-l$1.ln | |
2049 | if test "x$LINT" = "x"; then | |
2050 | AC_MSG_ERROR([Cannot make lint library without --with-lint]) | |
2051 | fi | |
2052 | elif test "x$make_lint_lib" != x"no" ; then | |
2053 | AC_MSG_ERROR([--enable-lint-library expects 'yes' or 'no'.]) | |
2054 | fi | |
2055 | ||
2056 | AC_SUBST(LINTLIB) | |
2057 | AM_CONDITIONAL(MAKE_LINT_LIB, [test x$make_lint_lib != xno]) | |
2058 | ||
2059 | ]) # XORG_LINT_LIBRARY | |
2060 | ||
2061 | # XORG_CWARNFLAGS | |
2062 | # --------------- | |
2063 | # Minimum version: 1.2.0 | |
2064 | # | |
2065 | # Defines CWARNFLAGS to enable C compiler warnings. | |
2066 | # | |
2067 | AC_DEFUN([XORG_CWARNFLAGS], [ | |
2068 | AC_REQUIRE([AC_PROG_CC_C99]) | |
2069 | if test "x$GCC" = xyes ; then | |
2070 | CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ | |
2071 | -Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ | |
2072 | -Wbad-function-cast -Wformat=2" | |
2073 | case `$CC -dumpversion` in | |
2074 | 3.4.* | 4.*) | |
2075 | CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" | |
2076 | ;; | |
2077 | esac | |
2078 | else | |
2079 | AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) | |
2080 | if test "x$SUNCC" = "xyes"; then | |
2081 | CWARNFLAGS="-v" | |
2082 | fi | |
2083 | fi | |
2084 | AC_SUBST(CWARNFLAGS) | |
2085 | ]) # XORG_CWARNFLAGS | |
2086 | ||
2087 | # XORG_STRICT_OPTION | |
2088 | # ----------------------- | |
2089 | # Minimum version: 1.3.0 | |
2090 | # | |
2091 | # Add configure option to enable strict compilation | |
2092 | AC_DEFUN([XORG_STRICT_OPTION], [ | |
2093 | # If the module's configure.ac calls AC_PROG_CC later on, CC gets set to C89 | |
2094 | AC_REQUIRE([AC_PROG_CC_C99]) | |
2095 | AC_REQUIRE([XORG_CWARNFLAGS]) | |
2096 | ||
2097 | AC_ARG_ENABLE(strict-compilation, | |
2098 | AS_HELP_STRING([--enable-strict-compilation], | |
2099 | [Enable all warnings from compiler and make them errors (default: disabled)]), | |
2100 | [STRICT_COMPILE=$enableval], [STRICT_COMPILE=no]) | |
2101 | if test "x$STRICT_COMPILE" = "xyes"; then | |
2102 | AC_CHECK_DECL([__SUNPRO_C], [SUNCC="yes"], [SUNCC="no"]) | |
2103 | AC_CHECK_DECL([__INTEL_COMPILER], [INTELCC="yes"], [INTELCC="no"]) | |
2104 | if test "x$GCC" = xyes ; then | |
2105 | STRICT_CFLAGS="-pedantic -Werror" | |
2106 | elif test "x$SUNCC" = "xyes"; then | |
2107 | STRICT_CFLAGS="-errwarn" | |
2108 | elif test "x$INTELCC" = "xyes"; then | |
2109 | STRICT_CFLAGS="-Werror" | |
2110 | fi | |
2111 | fi | |
2112 | CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS" | |
2113 | AC_SUBST([CWARNFLAGS]) | |
2114 | ]) # XORG_STRICT_OPTION | |
2115 | ||
2116 | # XORG_DEFAULT_OPTIONS | |
2117 | # -------------------- | |
2118 | # Minimum version: 1.3.0 | |
2119 | # | |
2120 | # Defines default options for X.Org modules. | |
2121 | # | |
2122 | AC_DEFUN([XORG_DEFAULT_OPTIONS], [ | |
2123 | AC_REQUIRE([AC_PROG_INSTALL]) | |
2124 | XORG_CWARNFLAGS | |
2125 | XORG_STRICT_OPTION | |
2126 | XORG_RELEASE_VERSION | |
2127 | XORG_CHANGELOG | |
2128 | XORG_INSTALL | |
2129 | XORG_MANPAGE_SECTIONS | |
2130 | m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])], | |
2131 | [AC_SUBST([AM_DEFAULT_VERBOSITY], [1])]) | |
2132 | ]) # XORG_DEFAULT_OPTIONS | |
2133 | ||
2134 | # XORG_INSTALL() | |
2135 | # ---------------- | |
2136 | # Minimum version: 1.4.0 | |
2137 | # | |
2138 | # Defines the variable INSTALL_CMD as the command to copy | |
2139 | # INSTALL from $prefix/share/util-macros. | |
2140 | # | |
2141 | AC_DEFUN([XORG_INSTALL], [ | |
2142 | AC_REQUIRE([PKG_PROG_PKG_CONFIG]) | |
2143 | macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros` | |
2144 | INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \ | |
2145 | mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \ | |
2146 | || (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \ | |
2147 | echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)" | |
2148 | AC_SUBST([INSTALL_CMD]) | |
2149 | ]) # XORG_INSTALL | |
2150 | dnl Copyright 2005 Red Hat, Inc | |
2151 | dnl | |
2152 | dnl Permission to use, copy, modify, distribute, and sell this software and its | |
2153 | dnl documentation for any purpose is hereby granted without fee, provided that | |
2154 | dnl the above copyright notice appear in all copies and that both that | |
2155 | dnl copyright notice and this permission notice appear in supporting | |
2156 | dnl documentation. | |
2157 | dnl | |
2158 | dnl The above copyright notice and this permission notice shall be included | |
2159 | dnl in all copies or substantial portions of the Software. | |
2160 | dnl | |
2161 | dnl THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS | |
2162 | dnl OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | |
2163 | dnl MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. | |
2164 | dnl IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR | |
2165 | dnl OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, | |
2166 | dnl ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR | |
2167 | dnl OTHER DEALINGS IN THE SOFTWARE. | |
2168 | dnl | |
2169 | dnl Except as contained in this notice, the name of the copyright holders shall | |
2170 | dnl not be used in advertising or otherwise to promote the sale, use or | |
2171 | dnl other dealings in this Software without prior written authorization | |
2172 | dnl from the copyright holders. | |
2173 | dnl | |
2174 | ||
2175 | # XORG_RELEASE_VERSION | |
2176 | # -------------------- | |
2177 | # Defines PACKAGE_VERSION_{MAJOR,MINOR,PATCHLEVEL} for modules to use. | |
2178 | ||
2179 | AC_DEFUN([XORG_RELEASE_VERSION],[ | |
2180 | AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MAJOR], | |
2181 | [`echo $PACKAGE_VERSION | cut -d . -f 1`], | |
2182 | [Major version of this package]) | |
2183 | PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` | |
2184 | if test "x$PVM" = "x"; then | |
2185 | PVM="0" | |
2186 | fi | |
2187 | AC_DEFINE_UNQUOTED([PACKAGE_VERSION_MINOR], | |
2188 | [$PVM], | |
2189 | [Minor version of this package]) | |
2190 | PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` | |
2191 | if test "x$PVP" = "x"; then | |
2192 | PVP="0" | |
2193 | fi | |
2194 | AC_DEFINE_UNQUOTED([PACKAGE_VERSION_PATCHLEVEL], | |
2195 | [$PVP], | |
2196 | [Patch version of this package]) | |
2197 | ]) | |
2198 | ||
2199 | # XORG_CHANGELOG() | |
2200 | # ---------------- | |
2201 | # Minimum version: 1.2.0 | |
2202 | # | |
2203 | # Defines the variable CHANGELOG_CMD as the command to generate | |
2204 | # ChangeLog from git. | |
2205 | # | |
2206 | # | |
2207 | AC_DEFUN([XORG_CHANGELOG], [ | |
2208 | CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \ | |
2209 | mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \ | |
2210 | || (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \ | |
2211 | echo 'git directory not found: installing possibly empty changelog.' >&2)" | |
2212 | AC_SUBST([CHANGELOG_CMD]) | |
2213 | ]) # XORG_CHANGELOG | |
2214 | ||
2215 | # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- | |
2216 | # | |
2217 | # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. | |
2218 | # | |
2219 | # This program is free software; you can redistribute it and/or modify | |
2220 | # it under the terms of the GNU General Public License as published by | |
2221 | # the Free Software Foundation; either version 2 of the License, or | |
2222 | # (at your option) any later version. | |
2223 | # | |
2224 | # This program is distributed in the hope that it will be useful, but | |
2225 | # WITHOUT ANY WARRANTY; without even the implied warranty of | |
2226 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
2227 | # General Public License for more details. | |
2228 | # | |
2229 | # You should have received a copy of the GNU General Public License | |
2230 | # along with this program; if not, write to the Free Software | |
2231 | # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | |
2232 | # | |
2233 | # As a special exception to the GNU General Public License, if you | |
2234 | # distribute this file as part of a program that contains a | |
2235 | # configuration script generated by Autoconf, you may include it under | |
2236 | # the same distribution terms that you use for the rest of that program. | |
2237 | ||
2238 | # PKG_PROG_PKG_CONFIG([MIN-VERSION]) | |
2239 | # ---------------------------------- | |
2240 | AC_DEFUN([PKG_PROG_PKG_CONFIG], | |
2241 | [m4_pattern_forbid([^_?PKG_[A-Z_]+$]) | |
2242 | m4_pattern_allow([^PKG_CONFIG(_PATH)?$]) | |
2243 | AC_ARG_VAR([PKG_CONFIG], [path to pkg-config utility])dnl | |
2244 | if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then | |
2245 | AC_PATH_TOOL([PKG_CONFIG], [pkg-config]) | |
2246 | fi | |
2247 | if test -n "$PKG_CONFIG"; then | |
2248 | _pkg_min_version=m4_default([$1], [0.9.0]) | |
2249 | AC_MSG_CHECKING([pkg-config is at least version $_pkg_min_version]) | |
2250 | if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then | |
2251 | AC_MSG_RESULT([yes]) | |
2252 | else | |
2253 | AC_MSG_RESULT([no]) | |
2254 | PKG_CONFIG="" | |
2255 | fi | |
2256 | ||
2257 | fi[]dnl | |
2258 | ])# PKG_PROG_PKG_CONFIG | |
2259 | ||
2260 | # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) | |
2261 | # | |
2262 | # Check to see whether a particular set of modules exists. Similar | |
2263 | # to PKG_CHECK_MODULES(), but does not set variables or print errors. | |
2264 | # | |
2265 | # | |
2266 | # Similar to PKG_CHECK_MODULES, make sure that the first instance of | |
2267 | # this or PKG_CHECK_MODULES is called, or make sure to call | |
2268 | # PKG_CHECK_EXISTS manually | |
2269 | # -------------------------------------------------------------- | |
2270 | AC_DEFUN([PKG_CHECK_EXISTS], | |
2271 | [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl | |
2272 | if test -n "$PKG_CONFIG" && \ | |
2273 | AC_RUN_LOG([$PKG_CONFIG --exists --print-errors "$1"]); then | |
2274 | m4_ifval([$2], [$2], [:]) | |
2275 | m4_ifvaln([$3], [else | |
2276 | $3])dnl | |
2277 | fi]) | |
2278 | ||
2279 | ||
2280 | # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) | |
2281 | # --------------------------------------------- | |
2282 | m4_define([_PKG_CONFIG], | |
2283 | [if test -n "$$1"; then | |
2284 | pkg_cv_[]$1="$$1" | |
2285 | elif test -n "$PKG_CONFIG"; then | |
2286 | PKG_CHECK_EXISTS([$3], | |
2287 | [pkg_cv_[]$1=`$PKG_CONFIG --[]$2 "$3" 2>/dev/null`], | |
2288 | [pkg_failed=yes]) | |
2289 | else | |
2290 | pkg_failed=untried | |
2291 | fi[]dnl | |
2292 | ])# _PKG_CONFIG | |
2293 | ||
2294 | # _PKG_SHORT_ERRORS_SUPPORTED | |
2295 | # ----------------------------- | |
2296 | AC_DEFUN([_PKG_SHORT_ERRORS_SUPPORTED], | |
2297 | [AC_REQUIRE([PKG_PROG_PKG_CONFIG]) | |
2298 | if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then | |
2299 | _pkg_short_errors_supported=yes | |
2300 | else | |
2301 | _pkg_short_errors_supported=no | |
2302 | fi[]dnl | |
2303 | ])# _PKG_SHORT_ERRORS_SUPPORTED | |
2304 | ||
2305 | ||
2306 | # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], | |
2307 | # [ACTION-IF-NOT-FOUND]) | |
2308 | # | |
2309 | # | |
2310 | # Note that if there is a possibility the first call to | |
2311 | # PKG_CHECK_MODULES might not happen, you should be sure to include an | |
2312 | # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac | |
2313 | # | |
2314 | # | |
2315 | # -------------------------------------------------------------- | |
2316 | AC_DEFUN([PKG_CHECK_MODULES], | |
2317 | [AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl | |
2318 | AC_ARG_VAR([$1][_CFLAGS], [C compiler flags for $1, overriding pkg-config])dnl | |
2319 | AC_ARG_VAR([$1][_LIBS], [linker flags for $1, overriding pkg-config])dnl | |
2320 | ||
2321 | pkg_failed=no | |
2322 | AC_MSG_CHECKING([for $1]) | |
2323 | ||
2324 | _PKG_CONFIG([$1][_CFLAGS], [cflags], [$2]) | |
2325 | _PKG_CONFIG([$1][_LIBS], [libs], [$2]) | |
2326 | ||
2327 | m4_define([_PKG_TEXT], [Alternatively, you may set the environment variables $1[]_CFLAGS | |
2328 | and $1[]_LIBS to avoid the need to call pkg-config. | |
2329 | See the pkg-config man page for more details.]) | |
2330 | ||
2331 | if test $pkg_failed = yes; then | |
2332 | _PKG_SHORT_ERRORS_SUPPORTED | |
2333 | if test $_pkg_short_errors_supported = yes; then | |
2334 | $1[]_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "$2" 2>&1` | |
2335 | else | |
2336 | $1[]_PKG_ERRORS=`$PKG_CONFIG --print-errors "$2" 2>&1` | |
2337 | fi | |
2338 | # Put the nasty error message in config.log where it belongs | |
2339 | echo "$$1[]_PKG_ERRORS" >&AS_MESSAGE_LOG_FD | |
2340 | ||
2341 | ifelse([$4], , [AC_MSG_ERROR(dnl | |
2342 | [Package requirements ($2) were not met: | |
2343 | ||
2344 | $$1_PKG_ERRORS | |
2345 | ||
2346 | Consider adjusting the PKG_CONFIG_PATH environment variable if you | |
2347 | installed software in a non-standard prefix. | |
2348 | ||
2349 | _PKG_TEXT | |
2350 | ])], | |
2351 | [AC_MSG_RESULT([no]) | |
2352 | $4]) | |
2353 | elif test $pkg_failed = untried; then | |
2354 | ifelse([$4], , [AC_MSG_FAILURE(dnl | |
2355 | [The pkg-config script could not be found or is too old. Make sure it | |
2356 | is in your PATH or set the PKG_CONFIG environment variable to the full | |
2357 | path to pkg-config. | |
2358 | ||
2359 | _PKG_TEXT | |
2360 | ||
2361 | To get pkg-config, see <http://pkg-config.freedesktop.org/>.])], | |
2362 | [$4]) | |
2363 | else | |
2364 | $1[]_CFLAGS=$pkg_cv_[]$1[]_CFLAGS | |
2365 | $1[]_LIBS=$pkg_cv_[]$1[]_LIBS | |
2366 | AC_MSG_RESULT([yes]) | |
2367 | ifelse([$3], , :, [$3]) | |
2368 | fi[]dnl | |
2369 | ])# PKG_CHECK_MODULES | |
2370 |
0 | #! /bin/sh | |
1 | ||
2 | srcdir=`dirname $0` | |
3 | test -z "$srcdir" && srcdir=. | |
4 | ||
5 | ORIGDIR=`pwd` | |
6 | cd $srcdir | |
7 | ||
8 | autoreconf -v --install || exit 1 | |
9 | ||
10 | cd $ORIGDIR || exit $? | |
11 | ||
12 | $srcdir/configure --enable-maintainer-mode "$@" |
0 | #! /bin/sh | |
1 | # Attempt to guess a canonical system name. | |
2 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, | |
3 | # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 | |
4 | # Free Software Foundation, Inc. | |
5 | ||
6 | timestamp='2010-08-21' | |
7 | ||
8 | # This file is free software; you can redistribute it and/or modify it | |
9 | # under the terms of the GNU General Public License as published by | |
10 | # the Free Software Foundation; either version 2 of the License, or | |
11 | # (at your option) any later version. | |
12 | # | |
13 | # This program is distributed in the hope that it will be useful, but | |
14 | # WITHOUT ANY WARRANTY; without even the implied warranty of | |
15 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
16 | # General Public License for more details. | |
17 | # | |
18 | # You should have received a copy of the GNU General Public License | |
19 | # along with this program; if not, write to the Free Software | |
20 | # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA | |
21 | # 02110-1301, USA. | |
22 | # | |
23 | # As a special exception to the GNU General Public License, if you | |
24 | # distribute this file as part of a program that contains a | |
25 | # configuration script generated by Autoconf, you may include it under | |
26 | # the same distribution terms that you use for the rest of that program. | |
27 | ||
28 | ||
29 | # Originally written by Per Bothner. Please send patches (context | |
30 | # diff format) to <config-patches@gnu.org> and include a ChangeLog | |
31 | # entry. | |
32 | # | |
33 | # This script attempts to guess a canonical system name similar to | |
34 | # config.sub. If it succeeds, it prints the system name on stdout, and | |
35 | # exits with 0. Otherwise, it exits with 1. | |
36 | # | |
37 | # You can get the latest version of this script from: | |
38 | # http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD | |
39 | ||
40 | me=`echo "$0" | sed -e 's,.*/,,'` | |
41 | ||
42 | usage="\ | |
43 | Usage: $0 [OPTION] | |
44 | ||
45 | Output the configuration name of the system \`$me' is run on. | |
46 | ||
47 | Operation modes: | |
48 | -h, --help print this help, then exit | |
49 | -t, --time-stamp print date of last modification, then exit | |
50 | -v, --version print version number, then exit | |
51 | ||
52 | Report bugs and patches to <config-patches@gnu.org>." | |
53 | ||
54 | version="\ | |
55 | GNU config.guess ($timestamp) | |
56 | ||
57 | Originally written by Per Bothner. | |
58 | Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, | |
59 | 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free | |
60 | Software Foundation, Inc. | |
61 | ||
62 | This is free software; see the source for copying conditions. There is NO | |
63 | warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." | |
64 | ||
65 | help=" | |
66 | Try \`$me --help' for more information." | |
67 | ||
68 | # Parse command line | |
69 | while test $# -gt 0 ; do | |
70 | case $1 in | |
71 | --time-stamp | --time* | -t ) | |
72 | echo "$timestamp" ; exit ;; | |
73 | --version | -v ) | |
74 | echo "$version" ; exit ;; | |
75 | --help | --h* | -h ) | |
76 | echo "$usage"; exit ;; | |
77 | -- ) # Stop option processing | |
78 | shift; break ;; | |
79 | - ) # Use stdin as input. | |
80 | break ;; | |
81 | -* ) | |
82 | echo "$me: invalid option $1$help" >&2 | |
83 | exit 1 ;; | |
84 | * ) | |
85 | break ;; | |
86 | esac | |
87 | done | |
88 | ||
89 | if test $# != 0; then | |
90 | echo "$me: too many arguments$help" >&2 | |
91 | exit 1 | |
92 | fi | |
93 | ||
94 | trap 'exit 1' HUP INT TERM | |
95 | ||
96 | # CC_FOR_BUILD -- compiler used by this script. Note that the use of a | |
97 | # compiler to aid in system detection is discouraged as it requires | |
98 | # temporary files to be created and, as you can see below, it is a | |
99 | # headache to deal with in a portable fashion. | |
100 | ||
101 | # Historically, `CC_FOR_BUILD' used to be named `HOST_CC'. We still | |
102 | # use `HOST_CC' if defined, but it is deprecated. | |
103 | ||
104 | # Portable tmp directory creation inspired by the Autoconf team. | |
105 | ||
106 | set_cc_for_build=' | |
107 | trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ; | |
108 | trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" HUP INT PIPE TERM ; | |
109 | : ${TMPDIR=/tmp} ; | |
110 | { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } || | |
111 | { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } || | |
112 | { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } || | |
113 | { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ; | |
114 | dummy=$tmp/dummy ; | |
115 | tmpfiles="$dummy.c $dummy.o $dummy.rel $dummy" ; | |
116 | case $CC_FOR_BUILD,$HOST_CC,$CC in | |
117 | ,,) echo "int x;" > $dummy.c ; | |
118 | for c in cc gcc c89 c99 ; do | |
119 | if ($c -c -o $dummy.o $dummy.c) >/dev/null 2>&1 ; then | |
120 | CC_FOR_BUILD="$c"; break ; | |
121 | fi ; | |
122 | done ; | |
123 | if test x"$CC_FOR_BUILD" = x ; then | |
124 | CC_FOR_BUILD=no_compiler_found ; | |
125 | fi | |
126 | ;; | |
127 | ,,*) CC_FOR_BUILD=$CC ;; | |
128 | ,*,*) CC_FOR_BUILD=$HOST_CC ;; | |
129 | esac ; set_cc_for_build= ;' | |
130 | ||
131 | # This is needed to find uname on a Pyramid OSx when run in the BSD universe. | |
132 | # (ghazi@noc.rutgers.edu 1994-08-24) | |
133 | if (test -f /.attbin/uname) >/dev/null 2>&1 ; then | |
134 | PATH=$PATH:/.attbin ; export PATH | |
135 | fi | |
136 | ||
137 | UNAME_MACHINE=`(uname -m) 2>/dev/null` || UNAME_MACHINE=unknown | |
138 | UNAME_RELEASE=`(uname -r) 2>/dev/null` || UNAME_RELEASE=unknown | |
139 | UNAME_SYSTEM=`(uname -s) 2>/dev/null` || UNAME_SYSTEM=unknown | |
140 | UNAME_VERSION=`(uname -v) 2>/dev/null` || UNAME_VERSION=unknown | |
141 | ||
142 | # Note: order is significant - the case branches are not exclusive. | |
143 | ||
144 | case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in | |
145 | *:NetBSD:*:*) | |
146 | # NetBSD (nbsd) targets should (where applicable) match one or | |
147 | # more of the tupples: *-*-netbsdelf*, *-*-netbsdaout*, | |
148 | # *-*-netbsdecoff* and *-*-netbsd*. For targets that recently | |
149 | # switched to ELF, *-*-netbsd* would select the old | |
150 | # object file format. This provides both forward | |
151 | # compatibility and a consistent mechanism for selecting the | |
152 | # object file format. | |
153 | # | |
154 | # Note: NetBSD doesn't particularly care about the vendor | |
155 | # portion of the name. We always set it to "unknown". | |
156 | sysctl="sysctl -n hw.machine_arch" | |
157 | UNAME_MACHINE_ARCH=`(/sbin/$sysctl 2>/dev/null || \ | |
158 | /usr/sbin/$sysctl 2>/dev/null || echo unknown)` | |
159 | case "${UNAME_MACHINE_ARCH}" in | |
160 | armeb) machine=armeb-unknown ;; | |
161 | arm*) machine=arm-unknown ;; | |
162 | sh3el) machine=shl-unknown ;; | |
163 | sh3eb) machine=sh-unknown ;; | |
164 | sh5el) machine=sh5le-unknown ;; | |
165 | *) machine=${UNAME_MACHINE_ARCH}-unknown ;; | |
166 | esac | |
167 | # The Operating System including object format, if it has switched | |
168 | # to ELF recently, or will in the future. | |
169 | case "${UNAME_MACHINE_ARCH}" in | |
170 | arm*|i386|m68k|ns32k|sh3*|sparc|vax) | |
171 | eval $set_cc_for_build | |
172 | if echo __ELF__ | $CC_FOR_BUILD -E - 2>/dev/null \ | |
173 | | grep -q __ELF__ | |
174 | then | |
175 | # Once all utilities can be ECOFF (netbsdecoff) or a.out (netbsdaout). | |
176 | # Return netbsd for either. FIX? | |
177 | os=netbsd | |
178 | else | |
179 | os=netbsdelf | |
180 | fi | |
181 | ;; | |
182 | *) | |
183 | os=netbsd | |
184 | ;; | |
185 | esac | |
186 | # The OS release | |
187 | # Debian GNU/NetBSD machines have a different userland, and | |
188 | # thus, need a distinct triplet. However, they do not need | |
189 | # kernel version information, so it can be replaced with a | |
190 | # suitable tag, in the style of linux-gnu. | |
191 | case "${UNAME_VERSION}" in | |
192 | Debian*) | |
193 | release='-gnu' | |
194 | ;; | |
195 | *) | |
196 | release=`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'` | |
197 | ;; | |
198 | esac | |
199 | # Since CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM: | |
200 | # contains redundant information, the shorter form: | |
201 | # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM is used. | |
202 | echo "${machine}-${os}${release}" | |
203 | exit ;; | |
204 | *:OpenBSD:*:*) | |
205 | UNAME_MACHINE_ARCH=`arch | sed 's/OpenBSD.//'` | |
206 | echo ${UNAME_MACHINE_ARCH}-unknown-openbsd${UNAME_RELEASE} | |
207 | exit ;; | |
208 | *:ekkoBSD:*:*) | |
209 | echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE} | |
210 | exit ;; | |
211 | *:SolidBSD:*:*) | |
212 | echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE} | |
213 | exit ;; | |
214 | macppc:MirBSD:*:*) | |
215 | echo powerpc-unknown-mirbsd${UNAME_RELEASE} | |
216 | exit ;; | |
217 | *:MirBSD:*:*) | |
218 | echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE} | |
219 | exit ;; | |
220 | alpha:OSF1:*:*) | |
221 | case $UNAME_RELEASE in | |
222 | *4.0) | |
223 | UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $3}'` | |
224 | ;; | |
225 | *5.*) | |
226 | UNAME_RELEASE=`/usr/sbin/sizer -v | awk '{print $4}'` | |
227 | ;; | |
228 | esac | |
229 | # According to Compaq, /usr/sbin/psrinfo has been available on | |
230 | # OSF/1 and Tru64 systems produced since 1995. I hope that | |
231 | # covers most systems running today. This code pipes the CPU | |
232 | # types through head -n 1, so we only detect the type of CPU 0. | |
233 | ALPHA_CPU_TYPE=`/usr/sbin/psrinfo -v | sed -n -e 's/^ The alpha \(.*\) processor.*$/\1/p' | head -n 1` | |
234 | case "$ALPHA_CPU_TYPE" in | |
235 | "EV4 (21064)") | |
236 | UNAME_MACHINE="alpha" ;; | |
237 | "EV4.5 (21064)") | |
238 | UNAME_MACHINE="alpha" ;; | |
239 | "LCA4 (21066/21068)") | |
240 | UNAME_MACHINE="alpha" ;; | |
241 | "EV5 (21164)") | |
242 | UNAME_MACHINE="alphaev5" ;; | |
243 | "EV5.6 (21164A)") | |
244 | UNAME_MACHINE="alphaev56" ;; | |
245 | "EV5.6 (21164PC)") | |
246 | UNAME_MACHINE="alphapca56" ;; | |
247 | "EV5.7 (21164PC)") | |
248 | UNAME_MACHINE="alphapca57" ;; | |
249 | "EV6 (21264)") | |
250 | UNAME_MACHINE="alphaev6" ;; | |
251 | "EV6.7 (21264A)") | |
252 | UNAME_MACHINE="alphaev67" ;; | |
253 | "EV6.8CB (21264C)") | |
254 | UNAME_MACHINE="alphaev68" ;; | |
255 | "EV6.8AL (21264B)") | |
256 | UNAME_MACHINE="alphaev68" ;; | |
257 | "EV6.8CX (21264D)") | |
258 | UNAME_MACHINE="alphaev68" ;; | |
259 | "EV6.9A (21264/EV69A)") | |
260 | UNAME_MACHINE="alphaev69" ;; | |
261 | "EV7 (21364)") | |
262 | UNAME_MACHINE="alphaev7" ;; | |
263 | "EV7.9 (21364A)") | |
264 | UNAME_MACHINE="alphaev79" ;; | |
265 | esac | |
266 | # A Pn.n version is a patched version. | |
267 | # A Vn.n version is a released version. | |
268 | # A Tn.n version is a released field test version. | |
269 | # A Xn.n version is an unreleased experimental baselevel. | |
270 | # 1.2 uses "1.2" for uname -r. | |
271 | echo ${UNAME_MACHINE}-dec-osf`echo ${UNAME_RELEASE} | sed -e 's/^[PVTX]//' | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` | |
272 | exit ;; | |
273 | Alpha\ *:Windows_NT*:*) | |
274 | # How do we know it's Interix rather than the generic POSIX subsystem? | |
275 | # Should we change UNAME_MACHINE based on the output of uname instead | |
276 | # of the specific Alpha model? | |
277 | echo alpha-pc-interix | |
278 | exit ;; | |
279 | 21064:Windows_NT:50:3) | |
280 | echo alpha-dec-winnt3.5 | |
281 | exit ;; | |
282 | Amiga*:UNIX_System_V:4.0:*) | |
283 | echo m68k-unknown-sysv4 | |
284 | exit ;; | |
285 | *:[Aa]miga[Oo][Ss]:*:*) | |
286 | echo ${UNAME_MACHINE}-unknown-amigaos | |
287 | exit ;; | |
288 | *:[Mm]orph[Oo][Ss]:*:*) | |
289 | echo ${UNAME_MACHINE}-unknown-morphos | |
290 | exit ;; | |
291 | *:OS/390:*:*) | |
292 | echo i370-ibm-openedition | |
293 | exit ;; | |
294 | *:z/VM:*:*) | |
295 | echo s390-ibm-zvmoe | |
296 | exit ;; | |
297 | *:OS400:*:*) | |
298 | echo powerpc-ibm-os400 | |
299 | exit ;; | |
300 | arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*) | |
301 | echo arm-acorn-riscix${UNAME_RELEASE} | |
302 | exit ;; | |
303 | arm:riscos:*:*|arm:RISCOS:*:*) | |
304 | echo arm-unknown-riscos | |
305 | exit ;; | |
306 | SR2?01:HI-UX/MPP:*:* | SR8000:HI-UX/MPP:*:*) | |
307 | echo hppa1.1-hitachi-hiuxmpp | |
308 | exit ;; | |
309 | Pyramid*:OSx*:*:* | MIS*:OSx*:*:* | MIS*:SMP_DC-OSx*:*:*) | |
310 | # akee@wpdis03.wpafb.af.mil (Earle F. Ake) contributed MIS and NILE. | |
311 | if test "`(/bin/universe) 2>/dev/null`" = att ; then | |
312 | echo pyramid-pyramid-sysv3 | |
313 | else | |
314 | echo pyramid-pyramid-bsd | |
315 | fi | |
316 | exit ;; | |
317 | NILE*:*:*:dcosx) | |
318 | echo pyramid-pyramid-svr4 | |
319 | exit ;; | |
320 | DRS?6000:unix:4.0:6*) | |
321 | echo sparc-icl-nx6 | |
322 | exit ;; | |
323 | DRS?6000:UNIX_SV:4.2*:7* | DRS?6000:isis:4.2*:7*) | |
324 | case `/usr/bin/uname -p` in | |
325 | sparc) echo sparc-icl-nx7; exit ;; | |
326 | esac ;; | |
327 | s390x:SunOS:*:*) | |
328 | echo ${UNAME_MACHINE}-ibm-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` | |
329 | exit ;; | |
330 | sun4H:SunOS:5.*:*) | |
331 | echo sparc-hal-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` | |
332 | exit ;; | |
333 | sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) | |
334 | echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` | |
335 | exit ;; | |
336 | i86pc:AuroraUX:5.*:* | i86xen:AuroraUX:5.*:*) | |
337 | echo i386-pc-auroraux${UNAME_RELEASE} | |
338 | exit ;; | |
339 | i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) | |
340 | eval $set_cc_for_build | |
341 | SUN_ARCH="i386" | |
342 | # If there is a compiler, see if it is configured for 64-bit objects. | |
343 | # Note that the Sun cc does not turn __LP64__ into 1 like gcc does. | |
344 | # This test works for both compilers. | |
345 | if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then | |
346 | if (echo '#ifdef __amd64'; echo IS_64BIT_ARCH; echo '#endif') | \ | |
347 | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ | |
348 | grep IS_64BIT_ARCH >/dev/null | |
349 | then | |
350 | SUN_ARCH="x86_64" | |
351 | fi | |
352 | fi | |
353 | echo ${SUN_ARCH}-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` | |
354 | exit ;; | |
355 | sun4*:SunOS:6*:*) | |
356 | # According to config.sub, this is the proper way to canonicalize | |
357 | # SunOS6. Hard to guess exactly what SunOS6 will be like, but | |
358 | # it's likely to be more like Solaris than SunOS4. | |
359 | echo sparc-sun-solaris3`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` | |
360 | exit ;; | |
361 | sun4*:SunOS:*:*) | |
362 | case "`/usr/bin/arch -k`" in | |
363 | Series*|S4*) | |
364 | UNAME_RELEASE=`uname -v` | |
365 | ;; | |
366 | esac | |
367 | # Japanese Language versions have a version number like `4.1.3-JL'. | |
368 | echo sparc-sun-sunos`echo ${UNAME_RELEASE}|sed -e 's/-/_/'` | |
369 | exit ;; | |
370 | sun3*:SunOS:*:*) | |
371 | echo m68k-sun-sunos${UNAME_RELEASE} | |
372 | exit ;; | |
373 | sun*:*:4.2BSD:*) | |
374 | UNAME_RELEASE=`(sed 1q /etc/motd | awk '{print substr($5,1,3)}') 2>/dev/null` | |
375 | test "x${UNAME_RELEASE}" = "x" && UNAME_RELEASE=3 | |
376 | case "`/bin/arch`" in | |
377 | sun3) | |
378 | echo m68k-sun-sunos${UNAME_RELEASE} | |
379 | ;; | |
380 | sun4) | |
381 | echo sparc-sun-sunos${UNAME_RELEASE} | |
382 | ;; | |
383 | esac | |
384 | exit ;; | |
385 | aushp:SunOS:*:*) | |
386 | echo sparc-auspex-sunos${UNAME_RELEASE} | |
387 | exit ;; | |
388 | # The situation for MiNT is a little confusing. The machine name | |
389 | # can be virtually everything (everything which is not | |
390 | # "atarist" or "atariste" at least should have a processor | |
391 | # > m68000). The system name ranges from "MiNT" over "FreeMiNT" | |
392 | # to the lowercase version "mint" (or "freemint"). Finally | |
393 | # the system name "TOS" denotes a system which is actually not | |
394 | # MiNT. But MiNT is downward compatible to TOS, so this should | |
395 | # be no problem. | |
396 | atarist[e]:*MiNT:*:* | atarist[e]:*mint:*:* | atarist[e]:*TOS:*:*) | |
397 | echo m68k-atari-mint${UNAME_RELEASE} | |
398 | exit ;; | |
399 | atari*:*MiNT:*:* | atari*:*mint:*:* | atarist[e]:*TOS:*:*) | |
400 | echo m68k-atari-mint${UNAME_RELEASE} | |
401 | exit ;; | |
402 | *falcon*:*MiNT:*:* | *falcon*:*mint:*:* | *falcon*:*TOS:*:*) | |
403 | echo m68k-atari-mint${UNAME_RELEASE} | |
404 | exit ;; | |
405 | milan*:*MiNT:*:* | milan*:*mint:*:* | *milan*:*TOS:*:*) | |
406 | echo m68k-milan-mint${UNAME_RELEASE} | |
407 | exit ;; | |
408 | hades*:*MiNT:*:* | hades*:*mint:*:* | *hades*:*TOS:*:*) | |
409 | echo m68k-hades-mint${UNAME_RELEASE} | |
410 | exit ;; | |
411 | *:*MiNT:*:* | *:*mint:*:* | *:*TOS:*:*) | |
412 | echo m68k-unknown-mint${UNAME_RELEASE} | |
413 | exit ;; | |
414 | m68k:machten:*:*) | |
415 | echo m68k-apple-machten${UNAME_RELEASE} | |
416 | exit ;; | |
417 | powerpc:machten:*:*) | |
418 | echo powerpc-apple-machten${UNAME_RELEASE} | |
419 | exit ;; | |
420 | RISC*:Mach:*:*) | |
421 | echo mips-dec-mach_bsd4.3 | |
422 | exit ;; | |
423 | RISC*:ULTRIX:*:*) | |
424 | echo mips-dec-ultrix${UNAME_RELEASE} | |
425 | exit ;; | |
426 | VAX*:ULTRIX*:*:*) | |
427 | echo vax-dec-ultrix${UNAME_RELEASE} | |
428 | exit ;; | |
429 | 2020:CLIX:*:* | 2430:CLIX:*:*) | |
430 | echo clipper-intergraph-clix${UNAME_RELEASE} | |
431 | exit ;; | |
432 | mips:*:*:UMIPS | mips:*:*:RISCos) | |
433 | eval $set_cc_for_build | |
434 | sed 's/^ //' << EOF >$dummy.c | |
435 | #ifdef __cplusplus | |
436 | #include <stdio.h> /* for printf() prototype */ | |
437 | int main (int argc, char *argv[]) { | |
438 | #else | |
439 | int main (argc, argv) int argc; char *argv[]; { | |
440 | #endif | |
441 | #if defined (host_mips) && defined (MIPSEB) | |
442 | #if defined (SYSTYPE_SYSV) | |
443 | printf ("mips-mips-riscos%ssysv\n", argv[1]); exit (0); | |
444 | #endif | |
445 | #if defined (SYSTYPE_SVR4) | |
446 | printf ("mips-mips-riscos%ssvr4\n", argv[1]); exit (0); | |
447 | #endif | |
448 | #if defined (SYSTYPE_BSD43) || defined(SYSTYPE_BSD) | |
449 | printf ("mips-mips-riscos%sbsd\n", argv[1]); exit (0); | |
450 | #endif | |
451 | #endif | |
452 | exit (-1); | |
453 | } | |
454 | EOF | |
455 | $CC_FOR_BUILD -o $dummy $dummy.c && | |
456 | dummyarg=`echo "${UNAME_RELEASE}" | sed -n 's/\([0-9]*\).*/\1/p'` && | |
457 | SYSTEM_NAME=`$dummy $dummyarg` && | |
458 | { echo "$SYSTEM_NAME"; exit; } | |
459 | echo mips-mips-riscos${UNAME_RELEASE} | |
460 | exit ;; | |
461 | Motorola:PowerMAX_OS:*:*) | |
462 | echo powerpc-motorola-powermax | |
463 | exit ;; | |
464 | Motorola:*:4.3:PL8-*) | |
465 | echo powerpc-harris-powermax | |
466 | exit ;; | |
467 | Night_Hawk:*:*:PowerMAX_OS | Synergy:PowerMAX_OS:*:*) | |
468 | echo powerpc-harris-powermax | |
469 | exit ;; | |
470 | Night_Hawk:Power_UNIX:*:*) | |
471 | echo powerpc-harris-powerunix | |
472 | exit ;; | |
473 | m88k:CX/UX:7*:*) | |
474 | echo m88k-harris-cxux7 | |
475 | exit ;; | |
476 | m88k:*:4*:R4*) | |
477 | echo m88k-motorola-sysv4 | |
478 | exit ;; | |
479 | m88k:*:3*:R3*) | |
480 | echo m88k-motorola-sysv3 | |
481 | exit ;; | |
482 | AViiON:dgux:*:*) | |
483 | # DG/UX returns AViiON for all architectures | |
484 | UNAME_PROCESSOR=`/usr/bin/uname -p` | |
485 | if [ $UNAME_PROCESSOR = mc88100 ] || [ $UNAME_PROCESSOR = mc88110 ] | |
486 | then | |
487 | if [ ${TARGET_BINARY_INTERFACE}x = m88kdguxelfx ] || \ | |
488 | [ ${TARGET_BINARY_INTERFACE}x = x ] | |
489 | then | |
490 | echo m88k-dg-dgux${UNAME_RELEASE} | |
491 | else | |
492 | echo m88k-dg-dguxbcs${UNAME_RELEASE} | |
493 | fi | |
494 | else | |
495 | echo i586-dg-dgux${UNAME_RELEASE} | |
496 | fi | |
497 | exit ;; | |
498 | M88*:DolphinOS:*:*) # DolphinOS (SVR3) | |
499 | echo m88k-dolphin-sysv3 | |
500 | exit ;; | |
501 | M88*:*:R3*:*) | |
502 | # Delta 88k system running SVR3 | |
503 | echo m88k-motorola-sysv3 | |
504 | exit ;; | |
505 | XD88*:*:*:*) # Tektronix XD88 system running UTekV (SVR3) | |
506 | echo m88k-tektronix-sysv3 | |
507 | exit ;; | |
508 | Tek43[0-9][0-9]:UTek:*:*) # Tektronix 4300 system running UTek (BSD) | |
509 | echo m68k-tektronix-bsd | |
510 | exit ;; | |
511 | *:IRIX*:*:*) | |
512 | echo mips-sgi-irix`echo ${UNAME_RELEASE}|sed -e 's/-/_/g'` | |
513 | exit ;; | |
514 | ????????:AIX?:[12].1:2) # AIX 2.2.1 or AIX 2.1.1 is RT/PC AIX. | |
515 | echo romp-ibm-aix # uname -m gives an 8 hex-code CPU id | |
516 | exit ;; # Note that: echo "'`uname -s`'" gives 'AIX ' | |
517 | i*86:AIX:*:*) | |
518 | echo i386-ibm-aix | |
519 | exit ;; | |
520 | ia64:AIX:*:*) | |
521 | if [ -x /usr/bin/oslevel ] ; then | |
522 | IBM_REV=`/usr/bin/oslevel` | |
523 | else | |
524 | IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} | |
525 | fi | |
526 | echo ${UNAME_MACHINE}-ibm-aix${IBM_REV} | |
527 | exit ;; | |
528 | *:AIX:2:3) | |
529 | if grep bos325 /usr/include/stdio.h >/dev/null 2>&1; then | |
530 | eval $set_cc_for_build | |
531 | sed 's/^ //' << EOF >$dummy.c | |
532 | #include <sys/systemcfg.h> | |
533 | ||
534 | main() | |
535 | { | |
536 | if (!__power_pc()) | |
537 | exit(1); | |
538 | puts("powerpc-ibm-aix3.2.5"); | |
539 | exit(0); | |
540 | } | |
541 | EOF | |
542 | if $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` | |
543 | then | |
544 | echo "$SYSTEM_NAME" | |
545 | else | |
546 | echo rs6000-ibm-aix3.2.5 | |
547 | fi | |
548 | elif grep bos324 /usr/include/stdio.h >/dev/null 2>&1; then | |
549 | echo rs6000-ibm-aix3.2.4 | |
550 | else | |
551 | echo rs6000-ibm-aix3.2 | |
552 | fi | |
553 | exit ;; | |
554 | *:AIX:*:[4567]) | |
555 | IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` | |
556 | if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then | |
557 | IBM_ARCH=rs6000 | |
558 | else | |
559 | IBM_ARCH=powerpc | |
560 | fi | |
561 | if [ -x /usr/bin/oslevel ] ; then | |
562 | IBM_REV=`/usr/bin/oslevel` | |
563 | else | |
564 | IBM_REV=${UNAME_VERSION}.${UNAME_RELEASE} | |
565 | fi | |
566 | echo ${IBM_ARCH}-ibm-aix${IBM_REV} | |
567 | exit ;; | |
568 | *:AIX:*:*) | |
569 | echo rs6000-ibm-aix | |
570 | exit ;; | |
571 | ibmrt:4.4BSD:*|romp-ibm:BSD:*) | |
572 | echo romp-ibm-bsd4.4 | |
573 | exit ;; | |
574 | ibmrt:*BSD:*|romp-ibm:BSD:*) # covers RT/PC BSD and | |
575 | echo romp-ibm-bsd${UNAME_RELEASE} # 4.3 with uname added to | |
576 | exit ;; # report: romp-ibm BSD 4.3 | |
577 | *:BOSX:*:*) | |
578 | echo rs6000-bull-bosx | |
579 | exit ;; | |
580 | DPX/2?00:B.O.S.:*:*) | |
581 | echo m68k-bull-sysv3 | |
582 | exit ;; | |
583 | 9000/[34]??:4.3bsd:1.*:*) | |
584 | echo m68k-hp-bsd | |
585 | exit ;; | |
586 | hp300:4.4BSD:*:* | 9000/[34]??:4.3bsd:2.*:*) | |
587 | echo m68k-hp-bsd4.4 | |
588 | exit ;; | |
589 | 9000/[34678]??:HP-UX:*:*) | |
590 | HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` | |
591 | case "${UNAME_MACHINE}" in | |
592 | 9000/31? ) HP_ARCH=m68000 ;; | |
593 | 9000/[34]?? ) HP_ARCH=m68k ;; | |
594 | 9000/[678][0-9][0-9]) | |
595 | if [ -x /usr/bin/getconf ]; then | |
596 | sc_cpu_version=`/usr/bin/getconf SC_CPU_VERSION 2>/dev/null` | |
597 | sc_kernel_bits=`/usr/bin/getconf SC_KERNEL_BITS 2>/dev/null` | |
598 | case "${sc_cpu_version}" in | |
599 | 523) HP_ARCH="hppa1.0" ;; # CPU_PA_RISC1_0 | |
600 | 528) HP_ARCH="hppa1.1" ;; # CPU_PA_RISC1_1 | |
601 | 532) # CPU_PA_RISC2_0 | |
602 | case "${sc_kernel_bits}" in | |
603 | 32) HP_ARCH="hppa2.0n" ;; | |
604 | 64) HP_ARCH="hppa2.0w" ;; | |
605 | '') HP_ARCH="hppa2.0" ;; # HP-UX 10.20 | |
606 | esac ;; | |
607 | esac | |
608 | fi | |
609 | if [ "${HP_ARCH}" = "" ]; then | |
610 | eval $set_cc_for_build | |
611 | sed 's/^ //' << EOF >$dummy.c | |
612 | ||
613 | #define _HPUX_SOURCE | |
614 | #include <stdlib.h> | |
615 | #include <unistd.h> | |
616 | ||
617 | int main () | |
618 | { | |
619 | #if defined(_SC_KERNEL_BITS) | |
620 | long bits = sysconf(_SC_KERNEL_BITS); | |
621 | #endif | |
622 | long cpu = sysconf (_SC_CPU_VERSION); | |
623 | ||
624 | switch (cpu) | |
625 | { | |
626 | case CPU_PA_RISC1_0: puts ("hppa1.0"); break; | |
627 | case CPU_PA_RISC1_1: puts ("hppa1.1"); break; | |
628 | case CPU_PA_RISC2_0: | |
629 | #if defined(_SC_KERNEL_BITS) | |
630 | switch (bits) | |
631 | { | |
632 | case 64: puts ("hppa2.0w"); break; | |
633 | case 32: puts ("hppa2.0n"); break; | |
634 | default: puts ("hppa2.0"); break; | |
635 | } break; | |
636 | #else /* !defined(_SC_KERNEL_BITS) */ | |
637 | puts ("hppa2.0"); break; | |
638 | #endif | |
639 | default: puts ("hppa1.0"); break; | |
640 | } | |
641 | exit (0); | |
642 | } | |
643 | EOF | |
644 | (CCOPTS= $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null) && HP_ARCH=`$dummy` | |
645 | test -z "$HP_ARCH" && HP_ARCH=hppa | |
646 | fi ;; | |
647 | esac | |
648 | if [ ${HP_ARCH} = "hppa2.0w" ] | |
649 | then | |
650 | eval $set_cc_for_build | |
651 | ||
652 | # hppa2.0w-hp-hpux* has a 64-bit kernel and a compiler generating | |
653 | # 32-bit code. hppa64-hp-hpux* has the same kernel and a compiler | |
654 | # generating 64-bit code. GNU and HP use different nomenclature: | |
655 | # | |
656 | # $ CC_FOR_BUILD=cc ./config.guess | |
657 | # => hppa2.0w-hp-hpux11.23 | |
658 | # $ CC_FOR_BUILD="cc +DA2.0w" ./config.guess | |
659 | # => hppa64-hp-hpux11.23 | |
660 | ||
661 | if echo __LP64__ | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | | |
662 | grep -q __LP64__ | |
663 | then | |
664 | HP_ARCH="hppa2.0w" | |
665 | else | |
666 | HP_ARCH="hppa64" | |
667 | fi | |
668 | fi | |
669 | echo ${HP_ARCH}-hp-hpux${HPUX_REV} | |
670 | exit ;; | |
671 | ia64:HP-UX:*:*) | |
672 | HPUX_REV=`echo ${UNAME_RELEASE}|sed -e 's/[^.]*.[0B]*//'` | |
673 | echo ia64-hp-hpux${HPUX_REV} | |
674 | exit ;; | |
675 | 3050*:HI-UX:*:*) | |
676 | eval $set_cc_for_build | |
677 | sed 's/^ //' << EOF >$dummy.c | |
678 | #include <unistd.h> | |
679 | int | |
680 | main () | |
681 | { | |
682 | long cpu = sysconf (_SC_CPU_VERSION); | |
683 | /* The order matters, because CPU_IS_HP_MC68K erroneously returns | |
684 | true for CPU_PA_RISC1_0. CPU_IS_PA_RISC returns correct | |
685 | results, however. */ | |
686 | if (CPU_IS_PA_RISC (cpu)) | |
687 | { | |
688 | switch (cpu) | |
689 | { | |
690 | case CPU_PA_RISC1_0: puts ("hppa1.0-hitachi-hiuxwe2"); break; | |
691 | case CPU_PA_RISC1_1: puts ("hppa1.1-hitachi-hiuxwe2"); break; | |
692 | case CPU_PA_RISC2_0: puts ("hppa2.0-hitachi-hiuxwe2"); break; | |
693 | default: puts ("hppa-hitachi-hiuxwe2"); break; | |
694 | } | |
695 | } | |
696 | else if (CPU_IS_HP_MC68K (cpu)) | |
697 | puts ("m68k-hitachi-hiuxwe2"); | |
698 | else puts ("unknown-hitachi-hiuxwe2"); | |
699 | exit (0); | |
700 | } | |
701 | EOF | |
702 | $CC_FOR_BUILD -o $dummy $dummy.c && SYSTEM_NAME=`$dummy` && | |
703 | { echo "$SYSTEM_NAME"; exit; } | |
704 | echo unknown-hitachi-hiuxwe2 | |
705 | exit ;; | |
706 | 9000/7??:4.3bsd:*:* | 9000/8?[79]:4.3bsd:*:* ) | |
707 | echo hppa1.1-hp-bsd | |
708 | exit ;; | |
709 | 9000/8??:4.3bsd:*:*) | |
710 | echo hppa1.0-hp-bsd | |
711 | exit ;; | |
712 | *9??*:MPE/iX:*:* | *3000*:MPE/iX:*:*) | |
713 | echo hppa1.0-hp-mpeix | |
714 | exit ;; | |
715 | hp7??:OSF1:*:* | hp8?[79]:OSF1:*:* ) | |
716 | echo hppa1.1-hp-osf | |
717 | exit ;; | |
718 | hp8??:OSF1:*:*) | |
719 | echo hppa1.0-hp-osf | |
720 | exit ;; | |
721 | i*86:OSF1:*:*) | |
722 | if [ -x /usr/sbin/sysversion ] ; then | |
723 | echo ${UNAME_MACHINE}-unknown-osf1mk | |
724 | else | |
725 | echo ${UNAME_MACHINE}-unknown-osf1 | |
726 | fi | |
727 | exit ;; | |
728 | parisc*:Lites*:*:*) | |
729 | echo hppa1.1-hp-lites | |
730 | exit ;; | |
731 | C1*:ConvexOS:*:* | convex:ConvexOS:C1*:*) | |
732 | echo c1-convex-bsd | |
733 | exit ;; | |
734 | C2*:ConvexOS:*:* | convex:ConvexOS:C2*:*) | |
735 | if getsysinfo -f scalar_acc | |
736 | then echo c32-convex-bsd | |
737 | else echo c2-convex-bsd | |
738 | fi | |
739 | exit ;; | |
740 | C34*:ConvexOS:*:* | convex:ConvexOS:C34*:*) | |
741 | echo c34-convex-bsd | |
742 | exit ;; | |
743 | C38*:ConvexOS:*:* | convex:ConvexOS:C38*:*) | |
744 | echo c38-convex-bsd | |
745 | exit ;; | |
746 | C4*:ConvexOS:*:* | convex:ConvexOS:C4*:*) | |
747 | echo c4-convex-bsd | |
748 | exit ;; | |
749 | CRAY*Y-MP:*:*:*) | |
750 | echo ymp-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' | |
751 | exit ;; | |
752 | CRAY*[A-Z]90:*:*:*) | |
753 | echo ${UNAME_MACHINE}-cray-unicos${UNAME_RELEASE} \ | |
754 | | sed -e 's/CRAY.*\([A-Z]90\)/\1/' \ | |
755 | -e y/ABCDEFGHIJKLMNOPQRSTUVWXYZ/abcdefghijklmnopqrstuvwxyz/ \ | |
756 | -e 's/\.[^.]*$/.X/' | |
757 | exit ;; | |
758 | CRAY*TS:*:*:*) | |
759 | echo t90-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' | |
760 | exit ;; | |
761 | CRAY*T3E:*:*:*) | |
762 | echo alphaev5-cray-unicosmk${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' | |
763 | exit ;; | |
764 | CRAY*SV1:*:*:*) | |
765 | echo sv1-cray-unicos${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' | |
766 | exit ;; | |
767 | *:UNICOS/mp:*:*) | |
768 | echo craynv-cray-unicosmp${UNAME_RELEASE} | sed -e 's/\.[^.]*$/.X/' | |
769 | exit ;; | |
770 | F30[01]:UNIX_System_V:*:* | F700:UNIX_System_V:*:*) | |
771 | FUJITSU_PROC=`uname -m | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` | |
772 | FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` | |
773 | FUJITSU_REL=`echo ${UNAME_RELEASE} | sed -e 's/ /_/'` | |
774 | echo "${FUJITSU_PROC}-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" | |
775 | exit ;; | |
776 | 5000:UNIX_System_V:4.*:*) | |
777 | FUJITSU_SYS=`uname -p | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/\///'` | |
778 | FUJITSU_REL=`echo ${UNAME_RELEASE} | tr 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz' | sed -e 's/ /_/'` | |
779 | echo "sparc-fujitsu-${FUJITSU_SYS}${FUJITSU_REL}" | |
780 | exit ;; | |
781 | i*86:BSD/386:*:* | i*86:BSD/OS:*:* | *:Ascend\ Embedded/OS:*:*) | |
782 | echo ${UNAME_MACHINE}-pc-bsdi${UNAME_RELEASE} | |
783 | exit ;; | |
784 | sparc*:BSD/OS:*:*) | |
785 | echo sparc-unknown-bsdi${UNAME_RELEASE} | |
786 | exit ;; | |
787 | *:BSD/OS:*:*) | |
788 | echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE} | |
789 | exit ;; | |
790 | *:FreeBSD:*:*) | |
791 | case ${UNAME_MACHINE} in | |
792 | pc98) | |
793 | echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; | |
794 | amd64) | |
795 | echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; | |
796 | *) | |
797 | echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;; | |
798 | esac | |
799 | exit ;; | |
800 | i*:CYGWIN*:*) | |
801 | echo ${UNAME_MACHINE}-pc-cygwin | |
802 | exit ;; | |
803 | *:MINGW*:*) | |
804 | echo ${UNAME_MACHINE}-pc-mingw32 | |
805 | exit ;; | |
806 | i*:windows32*:*) | |
807 | # uname -m includes "-pc" on this system. | |
808 | echo ${UNAME_MACHINE}-mingw32 | |
809 | exit ;; | |
810 | i*:PW*:*) | |
811 | echo ${UNAME_MACHINE}-pc-pw32 | |
812 | exit ;; | |
813 | *:Interix*:*) | |
814 | case ${UNAME_MACHINE} in | |
815 | x86) | |
816 | echo i586-pc-interix${UNAME_RELEASE} | |
817 | exit ;; | |
818 | authenticamd | genuineintel | EM64T) | |
819 | echo x86_64-unknown-interix${UNAME_RELEASE} | |
820 | exit ;; | |
821 | IA64) | |
822 | echo ia64-unknown-interix${UNAME_RELEASE} | |
823 | exit ;; | |
824 | esac ;; | |
825 | [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) | |
826 | echo i${UNAME_MACHINE}-pc-mks | |
827 | exit ;; | |
828 | 8664:Windows_NT:*) | |
829 | echo x86_64-pc-mks | |
830 | exit ;; | |
831 | i*:Windows_NT*:* | Pentium*:Windows_NT*:*) | |
832 | # How do we know it's Interix rather than the generic POSIX subsystem? | |
833 | # It also conflicts with pre-2.0 versions of AT&T UWIN. Should we | |
834 | # UNAME_MACHINE based on the output of uname instead of i386? | |
835 | echo i586-pc-interix | |
836 | exit ;; | |
837 | i*:UWIN*:*) | |
838 | echo ${UNAME_MACHINE}-pc-uwin | |
839 | exit ;; | |
840 | amd64:CYGWIN*:*:* | x86_64:CYGWIN*:*:*) | |
841 | echo x86_64-unknown-cygwin | |
842 | exit ;; | |
843 | p*:CYGWIN*:*) | |
844 | echo powerpcle-unknown-cygwin | |
845 | exit ;; | |
846 | prep*:SunOS:5.*:*) | |
847 | echo powerpcle-unknown-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` | |
848 | exit ;; | |
849 | *:GNU:*:*) | |
850 | # the GNU system | |
851 | echo `echo ${UNAME_MACHINE}|sed -e 's,[-/].*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'` | |
852 | exit ;; | |
853 | *:GNU/*:*:*) | |
854 | # other systems with GNU libc and userland | |
855 | echo ${UNAME_MACHINE}-unknown-`echo ${UNAME_SYSTEM} | sed 's,^[^/]*/,,' | tr '[A-Z]' '[a-z]'``echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`-gnu | |
856 | exit ;; | |
857 | i*86:Minix:*:*) | |
858 | echo ${UNAME_MACHINE}-pc-minix | |
859 | exit ;; | |
860 | alpha:Linux:*:*) | |
861 | case `sed -n '/^cpu model/s/^.*: \(.*\)/\1/p' < /proc/cpuinfo` in | |
862 | EV5) UNAME_MACHINE=alphaev5 ;; | |
863 | EV56) UNAME_MACHINE=alphaev56 ;; | |
864 | PCA56) UNAME_MACHINE=alphapca56 ;; | |
865 | PCA57) UNAME_MACHINE=alphapca56 ;; | |
866 | EV6) UNAME_MACHINE=alphaev6 ;; | |
867 | EV67) UNAME_MACHINE=alphaev67 ;; | |
868 | EV68*) UNAME_MACHINE=alphaev68 ;; | |
869 | esac | |
870 | objdump --private-headers /bin/sh | grep -q ld.so.1 | |
871 | if test "$?" = 0 ; then LIBC="libc1" ; else LIBC="" ; fi | |
872 | echo ${UNAME_MACHINE}-unknown-linux-gnu${LIBC} | |
873 | exit ;; | |
874 | arm*:Linux:*:*) | |
875 | eval $set_cc_for_build | |
876 | if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ | |
877 | | grep -q __ARM_EABI__ | |
878 | then | |
879 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
880 | else | |
881 | echo ${UNAME_MACHINE}-unknown-linux-gnueabi | |
882 | fi | |
883 | exit ;; | |
884 | avr32*:Linux:*:*) | |
885 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
886 | exit ;; | |
887 | cris:Linux:*:*) | |
888 | echo cris-axis-linux-gnu | |
889 | exit ;; | |
890 | crisv32:Linux:*:*) | |
891 | echo crisv32-axis-linux-gnu | |
892 | exit ;; | |
893 | frv:Linux:*:*) | |
894 | echo frv-unknown-linux-gnu | |
895 | exit ;; | |
896 | i*86:Linux:*:*) | |
897 | LIBC=gnu | |
898 | eval $set_cc_for_build | |
899 | sed 's/^ //' << EOF >$dummy.c | |
900 | #ifdef __dietlibc__ | |
901 | LIBC=dietlibc | |
902 | #endif | |
903 | EOF | |
904 | eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^LIBC'` | |
905 | echo "${UNAME_MACHINE}-pc-linux-${LIBC}" | |
906 | exit ;; | |
907 | ia64:Linux:*:*) | |
908 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
909 | exit ;; | |
910 | m32r*:Linux:*:*) | |
911 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
912 | exit ;; | |
913 | m68*:Linux:*:*) | |
914 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
915 | exit ;; | |
916 | mips:Linux:*:* | mips64:Linux:*:*) | |
917 | eval $set_cc_for_build | |
918 | sed 's/^ //' << EOF >$dummy.c | |
919 | #undef CPU | |
920 | #undef ${UNAME_MACHINE} | |
921 | #undef ${UNAME_MACHINE}el | |
922 | #if defined(__MIPSEL__) || defined(__MIPSEL) || defined(_MIPSEL) || defined(MIPSEL) | |
923 | CPU=${UNAME_MACHINE}el | |
924 | #else | |
925 | #if defined(__MIPSEB__) || defined(__MIPSEB) || defined(_MIPSEB) || defined(MIPSEB) | |
926 | CPU=${UNAME_MACHINE} | |
927 | #else | |
928 | CPU= | |
929 | #endif | |
930 | #endif | |
931 | EOF | |
932 | eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep '^CPU'` | |
933 | test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; } | |
934 | ;; | |
935 | or32:Linux:*:*) | |
936 | echo or32-unknown-linux-gnu | |
937 | exit ;; | |
938 | padre:Linux:*:*) | |
939 | echo sparc-unknown-linux-gnu | |
940 | exit ;; | |
941 | parisc64:Linux:*:* | hppa64:Linux:*:*) | |
942 | echo hppa64-unknown-linux-gnu | |
943 | exit ;; | |
944 | parisc:Linux:*:* | hppa:Linux:*:*) | |
945 | # Look for CPU level | |
946 | case `grep '^cpu[^a-z]*:' /proc/cpuinfo 2>/dev/null | cut -d' ' -f2` in | |
947 | PA7*) echo hppa1.1-unknown-linux-gnu ;; | |
948 | PA8*) echo hppa2.0-unknown-linux-gnu ;; | |
949 | *) echo hppa-unknown-linux-gnu ;; | |
950 | esac | |
951 | exit ;; | |
952 | ppc64:Linux:*:*) | |
953 | echo powerpc64-unknown-linux-gnu | |
954 | exit ;; | |
955 | ppc:Linux:*:*) | |
956 | echo powerpc-unknown-linux-gnu | |
957 | exit ;; | |
958 | s390:Linux:*:* | s390x:Linux:*:*) | |
959 | echo ${UNAME_MACHINE}-ibm-linux | |
960 | exit ;; | |
961 | sh64*:Linux:*:*) | |
962 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
963 | exit ;; | |
964 | sh*:Linux:*:*) | |
965 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
966 | exit ;; | |
967 | sparc:Linux:*:* | sparc64:Linux:*:*) | |
968 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
969 | exit ;; | |
970 | tile*:Linux:*:*) | |
971 | echo ${UNAME_MACHINE}-tilera-linux-gnu | |
972 | exit ;; | |
973 | vax:Linux:*:*) | |
974 | echo ${UNAME_MACHINE}-dec-linux-gnu | |
975 | exit ;; | |
976 | x86_64:Linux:*:*) | |
977 | echo x86_64-unknown-linux-gnu | |
978 | exit ;; | |
979 | xtensa*:Linux:*:*) | |
980 | echo ${UNAME_MACHINE}-unknown-linux-gnu | |
981 | exit ;; | |
982 | i*86:DYNIX/ptx:4*:*) | |
983 | # ptx 4.0 does uname -s correctly, with DYNIX/ptx in there. | |
984 | # earlier versions are messed up and put the nodename in both | |
985 | # sysname and nodename. | |
986 | echo i386-sequent-sysv4 | |
987 | exit ;; | |
988 | i*86:UNIX_SV:4.2MP:2.*) | |
989 | # Unixware is an offshoot of SVR4, but it has its own version | |
990 | # number series starting with 2... | |
991 | # I am not positive that other SVR4 systems won't match this, | |
992 | # I just have to hope. -- rms. | |
993 | # Use sysv4.2uw... so that sysv4* matches it. | |
994 | echo ${UNAME_MACHINE}-pc-sysv4.2uw${UNAME_VERSION} | |
995 | exit ;; | |
996 | i*86:OS/2:*:*) | |
997 | # If we were able to find `uname', then EMX Unix compatibility | |
998 | # is probably installed. | |
999 | echo ${UNAME_MACHINE}-pc-os2-emx | |
1000 | exit ;; | |
1001 | i*86:XTS-300:*:STOP) | |
1002 | echo ${UNAME_MACHINE}-unknown-stop | |
1003 | exit ;; | |
1004 | i*86:atheos:*:*) | |
1005 | echo ${UNAME_MACHINE}-unknown-atheos | |
1006 | exit ;; | |
1007 | i*86:syllable:*:*) | |
1008 | echo ${UNAME_MACHINE}-pc-syllable | |
1009 | exit ;; | |
1010 | i*86:LynxOS:2.*:* | i*86:LynxOS:3.[01]*:* | i*86:LynxOS:4.[02]*:*) | |
1011 | echo i386-unknown-lynxos${UNAME_RELEASE} | |
1012 | exit ;; | |
1013 | i*86:*DOS:*:*) | |
1014 | echo ${UNAME_MACHINE}-pc-msdosdjgpp | |
1015 | exit ;; | |
1016 | i*86:*:4.*:* | i*86:SYSTEM_V:4.*:*) | |
1017 | UNAME_REL=`echo ${UNAME_RELEASE} | sed 's/\/MP$//'` | |
1018 | if grep Novell /usr/include/link.h >/dev/null 2>/dev/null; then | |
1019 | echo ${UNAME_MACHINE}-univel-sysv${UNAME_REL} | |
1020 | else | |
1021 | echo ${UNAME_MACHINE}-pc-sysv${UNAME_REL} | |
1022 | fi | |
1023 | exit ;; | |
1024 | i*86:*:5:[678]*) | |
1025 | # UnixWare 7.x, OpenUNIX and OpenServer 6. | |
1026 | case `/bin/uname -X | grep "^Machine"` in | |
1027 | *486*) UNAME_MACHINE=i486 ;; | |
1028 | *Pentium) UNAME_MACHINE=i586 ;; | |
1029 | *Pent*|*Celeron) UNAME_MACHINE=i686 ;; | |
1030 | esac | |
1031 | echo ${UNAME_MACHINE}-unknown-sysv${UNAME_RELEASE}${UNAME_SYSTEM}${UNAME_VERSION} | |
1032 | exit ;; | |
1033 | i*86:*:3.2:*) | |
1034 | if test -f /usr/options/cb.name; then | |
1035 | UNAME_REL=`sed -n 's/.*Version //p' </usr/options/cb.name` | |
1036 | echo ${UNAME_MACHINE}-pc-isc$UNAME_REL | |
1037 | elif /bin/uname -X 2>/dev/null >/dev/null ; then | |
1038 | UNAME_REL=`(/bin/uname -X|grep Release|sed -e 's/.*= //')` | |
1039 | (/bin/uname -X|grep i80486 >/dev/null) && UNAME_MACHINE=i486 | |
1040 | (/bin/uname -X|grep '^Machine.*Pentium' >/dev/null) \ | |
1041 | && UNAME_MACHINE=i586 | |
1042 | (/bin/uname -X|grep '^Machine.*Pent *II' >/dev/null) \ | |
1043 | && UNAME_MACHINE=i686 | |
1044 | (/bin/uname -X|grep '^Machine.*Pentium Pro' >/dev/null) \ | |
1045 | && UNAME_MACHINE=i686 | |
1046 | echo ${UNAME_MACHINE}-pc-sco$UNAME_REL | |
1047 | else | |
1048 | echo ${UNAME_MACHINE}-pc-sysv32 | |
1049 | fi | |
1050 | exit ;; | |
1051 | pc:*:*:*) | |
1052 | # Left here for compatibility: | |
1053 | # uname -m prints for DJGPP always 'pc', but it prints nothing about | |
1054 | # the processor, so we play safe by assuming i586. | |
1055 | # Note: whatever this is, it MUST be the same as what config.sub | |
1056 | # prints for the "djgpp" host, or else GDB configury will decide that | |
1057 | # this is a cross-build. | |
1058 | echo i586-pc-msdosdjgpp | |
1059 | exit ;; | |
1060 | Intel:Mach:3*:*) | |
1061 | echo i386-pc-mach3 | |
1062 | exit ;; | |
1063 | paragon:*:*:*) | |
1064 | echo i860-intel-osf1 | |
1065 | exit ;; | |
1066 | i860:*:4.*:*) # i860-SVR4 | |
1067 | if grep Stardent /usr/include/sys/uadmin.h >/dev/null 2>&1 ; then | |
1068 | echo i860-stardent-sysv${UNAME_RELEASE} # Stardent Vistra i860-SVR4 | |
1069 | else # Add other i860-SVR4 vendors below as they are discovered. | |
1070 | echo i860-unknown-sysv${UNAME_RELEASE} # Unknown i860-SVR4 | |
1071 | fi | |
1072 | exit ;; | |
1073 | mini*:CTIX:SYS*5:*) | |
1074 | # "miniframe" | |
1075 | echo m68010-convergent-sysv | |
1076 | exit ;; | |
1077 | mc68k:UNIX:SYSTEM5:3.51m) | |
1078 | echo m68k-convergent-sysv | |
1079 | exit ;; | |
1080 | M680?0:D-NIX:5.3:*) | |
1081 | echo m68k-diab-dnix | |
1082 | exit ;; | |
1083 | M68*:*:R3V[5678]*:*) | |
1084 | test -r /sysV68 && { echo 'm68k-motorola-sysv'; exit; } ;; | |
1085 | 3[345]??:*:4.0:3.0 | 3[34]??A:*:4.0:3.0 | 3[34]??,*:*:4.0:3.0 | 3[34]??/*:*:4.0:3.0 | 4400:*:4.0:3.0 | 4850:*:4.0:3.0 | SKA40:*:4.0:3.0 | SDS2:*:4.0:3.0 | SHG2:*:4.0:3.0 | S7501*:*:4.0:3.0) | |
1086 | OS_REL='' | |
1087 | test -r /etc/.relid \ | |
1088 | && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` | |
1089 | /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ | |
1090 | && { echo i486-ncr-sysv4.3${OS_REL}; exit; } | |
1091 | /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ | |
1092 | && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; | |
1093 | 3[34]??:*:4.0:* | 3[34]??,*:*:4.0:*) | |
1094 | /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ | |
1095 | && { echo i486-ncr-sysv4; exit; } ;; | |
1096 | NCR*:*:4.2:* | MPRAS*:*:4.2:*) | |
1097 | OS_REL='.3' | |
1098 | test -r /etc/.relid \ | |
1099 | && OS_REL=.`sed -n 's/[^ ]* [^ ]* \([0-9][0-9]\).*/\1/p' < /etc/.relid` | |
1100 | /bin/uname -p 2>/dev/null | grep 86 >/dev/null \ | |
1101 | && { echo i486-ncr-sysv4.3${OS_REL}; exit; } | |
1102 | /bin/uname -p 2>/dev/null | /bin/grep entium >/dev/null \ | |
1103 | && { echo i586-ncr-sysv4.3${OS_REL}; exit; } | |
1104 | /bin/uname -p 2>/dev/null | /bin/grep pteron >/dev/null \ | |
1105 | && { echo i586-ncr-sysv4.3${OS_REL}; exit; } ;; | |
1106 | m68*:LynxOS:2.*:* | m68*:LynxOS:3.0*:*) | |
1107 | echo m68k-unknown-lynxos${UNAME_RELEASE} | |
1108 | exit ;; | |
1109 | mc68030:UNIX_System_V:4.*:*) | |
1110 | echo m68k-atari-sysv4 | |
1111 | exit ;; | |
1112 | TSUNAMI:LynxOS:2.*:*) | |
1113 | echo sparc-unknown-lynxos${UNAME_RELEASE} | |
1114 | exit ;; | |
1115 | rs6000:LynxOS:2.*:*) | |
1116 | echo rs6000-unknown-lynxos${UNAME_RELEASE} | |
1117 | exit ;; | |
1118 | PowerPC:LynxOS:2.*:* | PowerPC:LynxOS:3.[01]*:* | PowerPC:LynxOS:4.[02]*:*) | |
1119 | echo powerpc-unknown-lynxos${UNAME_RELEASE} | |
1120 | exit ;; | |
1121 | SM[BE]S:UNIX_SV:*:*) | |
1122 | echo mips-dde-sysv${UNAME_RELEASE} | |
1123 | exit ;; | |
1124 | RM*:ReliantUNIX-*:*:*) | |
1125 | echo mips-sni-sysv4 | |
1126 | exit ;; | |
1127 | RM*:SINIX-*:*:*) | |
1128 | echo mips-sni-sysv4 | |
1129 | exit ;; | |
1130 | *:SINIX-*:*:*) | |
1131 | if uname -p 2>/dev/null >/dev/null ; then | |
1132 | UNAME_MACHINE=`(uname -p) 2>/dev/null` | |
1133 | echo ${UNAME_MACHINE}-sni-sysv4 | |
1134 | else | |
1135 | echo ns32k-sni-sysv | |
1136 | fi | |
1137 | exit ;; | |
1138 | PENTIUM:*:4.0*:*) # Unisys `ClearPath HMP IX 4000' SVR4/MP effort | |
1139 | # says <Richard.M.Bartel@ccMail.Census.GOV> | |
1140 | echo i586-unisys-sysv4 | |
1141 | exit ;; | |
1142 | *:UNIX_System_V:4*:FTX*) | |
1143 | # From Gerald Hewes <hewes@openmarket.com>. | |
1144 | # How about differentiating between stratus architectures? -djm | |
1145 | echo hppa1.1-stratus-sysv4 | |
1146 | exit ;; | |
1147 | *:*:*:FTX*) | |
1148 | # From seanf@swdc.stratus.com. | |
1149 | echo i860-stratus-sysv4 | |
1150 | exit ;; | |
1151 | i*86:VOS:*:*) | |
1152 | # From Paul.Green@stratus.com. | |
1153 | echo ${UNAME_MACHINE}-stratus-vos | |
1154 | exit ;; | |
1155 | *:VOS:*:*) | |
1156 | # From Paul.Green@stratus.com. | |
1157 | echo hppa1.1-stratus-vos | |
1158 | exit ;; | |
1159 | mc68*:A/UX:*:*) | |
1160 | echo m68k-apple-aux${UNAME_RELEASE} | |
1161 | exit ;; | |
1162 | news*:NEWS-OS:6*:*) | |
1163 | echo mips-sony-newsos6 | |
1164 | exit ;; | |
1165 | R[34]000:*System_V*:*:* | R4000:UNIX_SYSV:*:* | R*000:UNIX_SV:*:*) | |
1166 | if [ -d /usr/nec ]; then | |
1167 | echo mips-nec-sysv${UNAME_RELEASE} | |
1168 | else | |
1169 | echo mips-unknown-sysv${UNAME_RELEASE} | |
1170 | fi | |
1171 | exit ;; | |
1172 | BeBox:BeOS:*:*) # BeOS running on hardware made by Be, PPC only. | |
1173 | echo powerpc-be-beos | |
1174 | exit ;; | |
1175 | BeMac:BeOS:*:*) # BeOS running on Mac or Mac clone, PPC only. | |
1176 | echo powerpc-apple-beos | |
1177 | exit ;; | |
1178 | BePC:BeOS:*:*) # BeOS running on Intel PC compatible. | |
1179 | echo i586-pc-beos | |
1180 | exit ;; | |
1181 | BePC:Haiku:*:*) # Haiku running on Intel PC compatible. | |
1182 | echo i586-pc-haiku | |
1183 | exit ;; | |
1184 | SX-4:SUPER-UX:*:*) | |
1185 | echo sx4-nec-superux${UNAME_RELEASE} | |
1186 | exit ;; | |
1187 | SX-5:SUPER-UX:*:*) | |
1188 | echo sx5-nec-superux${UNAME_RELEASE} | |
1189 | exit ;; | |
1190 | SX-6:SUPER-UX:*:*) | |
1191 | echo sx6-nec-superux${UNAME_RELEASE} | |
1192 | exit ;; | |
1193 | SX-7:SUPER-UX:*:*) | |
1194 | echo sx7-nec-superux${UNAME_RELEASE} | |
1195 | exit ;; | |
1196 | SX-8:SUPER-UX:*:*) | |
1197 | echo sx8-nec-superux${UNAME_RELEASE} | |
1198 | exit ;; | |
1199 | SX-8R:SUPER-UX:*:*) | |
1200 | echo sx8r-nec-superux${UNAME_RELEASE} | |
1201 | exit ;; | |
1202 | Power*:Rhapsody:*:*) | |
1203 | echo powerpc-apple-rhapsody${UNAME_RELEASE} | |
1204 | exit ;; | |
1205 | *:Rhapsody:*:*) | |
1206 | echo ${UNAME_MACHINE}-apple-rhapsody${UNAME_RELEASE} | |
1207 | exit ;; | |
1208 | *:Darwin:*:*) | |
1209 | UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown | |
1210 | case $UNAME_PROCESSOR in | |
1211 | i386) | |
1212 | eval $set_cc_for_build | |
1213 | if [ "$CC_FOR_BUILD" != 'no_compiler_found' ]; then | |
1214 | if (echo '#ifdef __LP64__'; echo IS_64BIT_ARCH; echo '#endif') | \ | |
1215 | (CCOPTS= $CC_FOR_BUILD -E - 2>/dev/null) | \ | |
1216 | grep IS_64BIT_ARCH >/dev/null | |
1217 | then | |
1218 | UNAME_PROCESSOR="x86_64" | |
1219 | fi | |
1220 | fi ;; | |
1221 | unknown) UNAME_PROCESSOR=powerpc ;; | |
1222 | esac | |
1223 | echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE} | |
1224 | exit ;; | |
1225 | *:procnto*:*:* | *:QNX:[0123456789]*:*) | |
1226 | UNAME_PROCESSOR=`uname -p` | |
1227 | if test "$UNAME_PROCESSOR" = "x86"; then | |
1228 | UNAME_PROCESSOR=i386 | |
1229 | UNAME_MACHINE=pc | |
1230 | fi | |
1231 | echo ${UNAME_PROCESSOR}-${UNAME_MACHINE}-nto-qnx${UNAME_RELEASE} | |
1232 | exit ;; | |
1233 | *:QNX:*:4*) | |
1234 | echo i386-pc-qnx | |
1235 | exit ;; | |
1236 | NSE-?:NONSTOP_KERNEL:*:*) | |
1237 | echo nse-tandem-nsk${UNAME_RELEASE} | |
1238 | exit ;; | |
1239 | NSR-?:NONSTOP_KERNEL:*:*) | |
1240 | echo nsr-tandem-nsk${UNAME_RELEASE} | |
1241 | exit ;; | |
1242 | *:NonStop-UX:*:*) | |
1243 | echo mips-compaq-nonstopux | |
1244 | exit ;; | |
1245 | BS2000:POSIX*:*:*) | |
1246 | echo bs2000-siemens-sysv | |
1247 | exit ;; | |
1248 | DS/*:UNIX_System_V:*:*) | |
1249 | echo ${UNAME_MACHINE}-${UNAME_SYSTEM}-${UNAME_RELEASE} | |
1250 | exit ;; | |
1251 | *:Plan9:*:*) | |
1252 | # "uname -m" is not consistent, so use $cputype instead. 386 | |
1253 | # is converted to i386 for consistency with other x86 | |
1254 | # operating systems. | |
1255 | if test "$cputype" = "386"; then | |
1256 | UNAME_MACHINE=i386 | |
1257 | else | |
1258 | UNAME_MACHINE="$cputype" | |
1259 | fi | |
1260 | echo ${UNAME_MACHINE}-unknown-plan9 | |
1261 | exit ;; | |
1262 | *:TOPS-10:*:*) | |
1263 | echo pdp10-unknown-tops10 | |
1264 | exit ;; | |
1265 | *:TENEX:*:*) | |
1266 | echo pdp10-unknown-tenex | |
1267 | exit ;; | |
1268 | KS10:TOPS-20:*:* | KL10:TOPS-20:*:* | TYPE4:TOPS-20:*:*) | |
1269 | echo pdp10-dec-tops20 | |
1270 | exit ;; | |
1271 | XKL-1:TOPS-20:*:* | TYPE5:TOPS-20:*:*) | |
1272 | echo pdp10-xkl-tops20 | |
1273 | exit ;; | |
1274 | *:TOPS-20:*:*) | |
1275 | echo pdp10-unknown-tops20 | |
1276 | exit ;; | |
1277 | *:ITS:*:*) | |
1278 | echo pdp10-unknown-its | |
1279 | exit ;; | |
1280 | SEI:*:*:SEIUX) | |
1281 | echo mips-sei-seiux${UNAME_RELEASE} | |
1282 | exit ;; | |
1283 | *:DragonFly:*:*) | |
1284 | echo ${UNAME_MACHINE}-unknown-dragonfly`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` | |
1285 | exit ;; | |
1286 | *:*VMS:*:*) | |
1287 | UNAME_MACHINE=`(uname -p) 2>/dev/null` | |
1288 | case "${UNAME_MACHINE}" in | |
1289 | A*) echo alpha-dec-vms ; exit ;; | |
1290 | I*) echo ia64-dec-vms ; exit ;; | |
1291 | V*) echo vax-dec-vms ; exit ;; | |
1292 | esac ;; | |
1293 | *:XENIX:*:SysV) | |
1294 | echo i386-pc-xenix | |
1295 | exit ;; | |
1296 | i*86:skyos:*:*) | |
1297 | echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//' | |
1298 | exit ;; | |
1299 | i*86:rdos:*:*) | |
1300 | echo ${UNAME_MACHINE}-pc-rdos | |
1301 | exit ;; | |
1302 | i*86:AROS:*:*) | |
1303 | echo ${UNAME_MACHINE}-pc-aros | |
1304 | exit ;; | |
1305 | esac | |
1306 | ||
1307 | #echo '(No uname command or uname output not recognized.)' 1>&2 | |
1308 | #echo "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" 1>&2 | |
1309 | ||
1310 | eval $set_cc_for_build | |
1311 | cat >$dummy.c <<EOF | |
1312 | #ifdef _SEQUENT_ | |
1313 | # include <sys/types.h> | |
1314 | # include <sys/utsname.h> | |
1315 | #endif | |
1316 | main () | |
1317 | { | |
1318 | #if defined (sony) | |
1319 | #if defined (MIPSEB) | |
1320 | /* BFD wants "bsd" instead of "newsos". Perhaps BFD should be changed, | |
1321 | I don't know.... */ | |
1322 | printf ("mips-sony-bsd\n"); exit (0); | |
1323 | #else | |
1324 | #include <sys/param.h> | |
1325 | printf ("m68k-sony-newsos%s\n", | |
1326 | #ifdef NEWSOS4 | |
1327 | "4" | |
1328 | #else | |
1329 | "" | |
1330 | #endif | |
1331 | ); exit (0); | |
1332 | #endif | |
1333 | #endif | |
1334 | ||
1335 | #if defined (__arm) && defined (__acorn) && defined (__unix) | |
1336 | printf ("arm-acorn-riscix\n"); exit (0); | |
1337 | #endif | |
1338 | ||
1339 | #if defined (hp300) && !defined (hpux) | |
1340 | printf ("m68k-hp-bsd\n"); exit (0); | |
1341 | #endif | |
1342 | ||
1343 | #if defined (NeXT) | |
1344 | #if !defined (__ARCHITECTURE__) | |
1345 | #define __ARCHITECTURE__ "m68k" | |
1346 | #endif | |
1347 | int version; | |
1348 | version=`(hostinfo | sed -n 's/.*NeXT Mach \([0-9]*\).*/\1/p') 2>/dev/null`; | |
1349 | if (version < 4) | |
1350 | printf ("%s-next-nextstep%d\n", __ARCHITECTURE__, version); | |
1351 | else | |
1352 | printf ("%s-next-openstep%d\n", __ARCHITECTURE__, version); | |
1353 | exit (0); | |
1354 | #endif | |
1355 | ||
1356 | #if defined (MULTIMAX) || defined (n16) | |
1357 | #if defined (UMAXV) | |
1358 | printf ("ns32k-encore-sysv\n"); exit (0); | |
1359 | #else | |
1360 | #if defined (CMU) | |
1361 | printf ("ns32k-encore-mach\n"); exit (0); | |
1362 | #else | |
1363 | printf ("ns32k-encore-bsd\n"); exit (0); | |
1364 | #endif | |
1365 | #endif | |
1366 | #endif | |
1367 | ||
1368 | #if defined (__386BSD__) | |
1369 | printf ("i386-pc-bsd\n"); exit (0); | |
1370 | #endif | |
1371 | ||
1372 | #if defined (sequent) | |
1373 | #if defined (i386) | |
1374 | printf ("i386-sequent-dynix\n"); exit (0); | |
1375 | #endif | |
1376 | #if defined (ns32000) | |
1377 | printf ("ns32k-sequent-dynix\n"); exit (0); | |
1378 | #endif | |
1379 | #endif | |
1380 | ||
1381 | #if defined (_SEQUENT_) | |
1382 | struct utsname un; | |
1383 | ||
1384 | uname(&un); | |
1385 | ||
1386 | if (strncmp(un.version, "V2", 2) == 0) { | |
1387 | printf ("i386-sequent-ptx2\n"); exit (0); | |
1388 | } | |
1389 | if (strncmp(un.version, "V1", 2) == 0) { /* XXX is V1 correct? */ | |
1390 | printf ("i386-sequent-ptx1\n"); exit (0); | |
1391 | } | |
1392 | printf ("i386-sequent-ptx\n"); exit (0); | |
1393 | ||
1394 | #endif | |
1395 | ||
1396 | #if defined (vax) | |
1397 | # if !defined (ultrix) | |
1398 | # include <sys/param.h> | |
1399 | # if defined (BSD) | |
1400 | # if BSD == 43 | |
1401 | printf ("vax-dec-bsd4.3\n"); exit (0); | |
1402 | # else | |
1403 | # if BSD == 199006 | |
1404 | printf ("vax-dec-bsd4.3reno\n"); exit (0); | |
1405 | # else | |
1406 | printf ("vax-dec-bsd\n"); exit (0); | |
1407 | # endif | |
1408 | # endif | |
1409 | # else | |
1410 | printf ("vax-dec-bsd\n"); exit (0); | |
1411 | # endif | |
1412 | # else | |
1413 | printf ("vax-dec-ultrix\n"); exit (0); | |
1414 | # endif | |
1415 | #endif | |
1416 | ||
1417 | #if defined (alliant) && defined (i860) | |
1418 | printf ("i860-alliant-bsd\n"); exit (0); | |
1419 | #endif | |
1420 | ||
1421 | exit (1); | |
1422 | } | |
1423 | EOF | |
1424 | ||
1425 | $CC_FOR_BUILD -o $dummy $dummy.c 2>/dev/null && SYSTEM_NAME=`$dummy` && | |
1426 | { echo "$SYSTEM_NAME"; exit; } | |
1427 | ||
1428 | # Apollos put the system type in the environment. | |
1429 | ||
1430 | test -d /usr/apollo && { echo ${ISP}-apollo-${SYSTYPE}; exit; } | |
1431 | ||
1432 | # Convex versions that predate uname can use getsysinfo(1) | |
1433 | ||
1434 | if [ -x /usr/convex/getsysinfo ] | |
1435 | then | |
1436 | case `getsysinfo -f cpu_type` in | |
1437 | c1*) | |
1438 | echo c1-convex-bsd | |
1439 | exit ;; | |
1440 | c2*) | |
1441 | if getsysinfo -f scalar_acc | |
1442 | then echo c32-convex-bsd | |
1443 | else echo c2-convex-bsd | |
1444 | fi | |
1445 | exit ;; | |
1446 | c34*) | |
1447 | echo c34-convex-bsd | |
1448 | exit ;; | |
1449 | c38*) | |
1450 | echo c38-convex-bsd | |
1451 | exit ;; | |
1452 | c4*) | |
1453 | echo c4-convex-bsd | |
1454 | exit ;; | |
1455 | esac | |
1456 | fi | |
1457 | ||
1458 | cat >&2 <<EOF | |
1459 | $0: unable to guess system type | |
1460 | ||
1461 | This script, last modified $timestamp, has failed to recognize | |
1462 | the operating system you are using. It is advised that you | |
1463 | download the most up to date version of the config scripts from | |
1464 | ||
1465 | http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD | |
1466 | and | |
1467 | http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD | |
1468 | ||
1469 | If the version you run ($0) is already up to date, please | |
1470 | send the following data and any information you think might be | |
1471 | pertinent to <config-patches@gnu.org> in order to provide the needed | |
1472 | information to handle your system. | |
1473 | ||
1474 | config.guess timestamp = $timestamp | |
1475 | ||
1476 | uname -m = `(uname -m) 2>/dev/null || echo unknown` | |
1477 | uname -r = `(uname -r) 2>/dev/null || echo unknown` | |
1478 | uname -s = `(uname -s) 2>/dev/null || echo unknown` | |
1479 | uname -v = `(uname -v) 2>/dev/null || echo unknown` | |
1480 | ||
1481 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null` | |
1482 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null` | |
1483 | ||
1484 | hostinfo = `(hostinfo) 2>/dev/null` | |
1485 | /bin/universe = `(/bin/universe) 2>/dev/null` | |
1486 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null` | |
1487 | /bin/arch = `(/bin/arch) 2>/dev/null` | |
1488 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null` | |
1489 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null` | |
1490 | ||
1491 | UNAME_MACHINE = ${UNAME_MACHINE} | |
1492 | UNAME_RELEASE = ${UNAME_RELEASE} | |
1493 | UNAME_SYSTEM = ${UNAME_SYSTEM} | |
1494 | UNAME_VERSION = ${UNAME_VERSION} | |
1495 | EOF | |
1496 | ||
1497 | exit 1 | |
1498 | ||
1499 | # Local variables: | |
1500 | # eval: (add-hook 'write-file-hooks 'time-stamp) | |
1501 | # time-stamp-start: "timestamp='" | |
1502 | # time-stamp-format: "%:y-%02m-%02d" | |
1503 | # time-stamp-end: "'" | |
1504 | # End: |
0 | #! /bin/sh | |
1 | # Configuration validation subroutine script. | |
2 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, | |
3 | # 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 | |
4 | # Free Software Foundation, Inc. | |
5 | ||
6 | timestamp='2010-09-11' | |
7 | ||
8 | # This file is (in principle) common to ALL GNU software. | |
9 | # The presence of a machine in this file suggests that SOME GNU software | |
10 | # can handle that machine. It does not imply ALL GNU software can. | |
11 | # | |
12 | # This file is free software; you can redistribute it and/or modify | |
13 | # it under the terms of the GNU General Public License as published by | |
14 | # the Free Software Foundation; either version 2 of the License, or | |
15 | # (at your option) any later version. | |
16 | # | |
17 | # This program is distributed in the hope that it will be useful, | |
18 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
19 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
20 | # GNU General Public License for more details. | |
21 | # | |
22 | # You should have received a copy of the GNU General Public License | |
23 | # along with this program; if not, write to the Free Software | |
24 | # Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA | |
25 | # 02110-1301, USA. | |
26 | # | |
27 | # As a special exception to the GNU General Public License, if you | |
28 | # distribute this file as part of a program that contains a | |
29 | # configuration script generated by Autoconf, you may include it under | |
30 | # the same distribution terms that you use for the rest of that program. | |
31 | ||
32 | ||
33 | # Please send patches to <config-patches@gnu.org>. Submit a context | |
34 | # diff and a properly formatted GNU ChangeLog entry. | |
35 | # | |
36 | # Configuration subroutine to validate and canonicalize a configuration type. | |
37 | # Supply the specified configuration type as an argument. | |
38 | # If it is invalid, we print an error message on stderr and exit with code 1. | |
39 | # Otherwise, we print the canonical config type on stdout and succeed. | |
40 | ||
41 | # You can get the latest version of this script from: | |
42 | # http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD | |
43 | ||
44 | # This file is supposed to be the same for all GNU packages | |
45 | # and recognize all the CPU types, system types and aliases | |
46 | # that are meaningful with *any* GNU software. | |
47 | # Each package is responsible for reporting which valid configurations | |
48 | # it does not support. The user should be able to distinguish | |
49 | # a failure to support a valid configuration from a meaningless | |
50 | # configuration. | |
51 | ||
52 | # The goal of this file is to map all the various variations of a given | |
53 | # machine specification into a single specification in the form: | |
54 | # CPU_TYPE-MANUFACTURER-OPERATING_SYSTEM | |
55 | # or in some cases, the newer four-part form: | |
56 | # CPU_TYPE-MANUFACTURER-KERNEL-OPERATING_SYSTEM | |
57 | # It is wrong to echo any other type of specification. | |
58 | ||
59 | me=`echo "$0" | sed -e 's,.*/,,'` | |
60 | ||
61 | usage="\ | |
62 | Usage: $0 [OPTION] CPU-MFR-OPSYS | |
63 | $0 [OPTION] ALIAS | |
64 | ||
65 | Canonicalize a configuration name. | |
66 | ||
67 | Operation modes: | |
68 | -h, --help print this help, then exit | |
69 | -t, --time-stamp print date of last modification, then exit | |
70 | -v, --version print version number, then exit | |
71 | ||
72 | Report bugs and patches to <config-patches@gnu.org>." | |
73 | ||
74 | version="\ | |
75 | GNU config.sub ($timestamp) | |
76 | ||
77 | Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, | |
78 | 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free | |
79 | Software Foundation, Inc. | |
80 | ||
81 | This is free software; see the source for copying conditions. There is NO | |
82 | warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." | |
83 | ||
84 | help=" | |
85 | Try \`$me --help' for more information." | |
86 | ||
87 | # Parse command line | |
88 | while test $# -gt 0 ; do | |
89 | case $1 in | |
90 | --time-stamp | --time* | -t ) | |
91 | echo "$timestamp" ; exit ;; | |
92 | --version | -v ) | |
93 | echo "$version" ; exit ;; | |
94 | --help | --h* | -h ) | |
95 | echo "$usage"; exit ;; | |
96 | -- ) # Stop option processing | |
97 | shift; break ;; | |
98 | - ) # Use stdin as input. | |
99 | break ;; | |
100 | -* ) | |
101 | echo "$me: invalid option $1$help" | |
102 | exit 1 ;; | |
103 | ||
104 | *local*) | |
105 | # First pass through any local machine types. | |
106 | echo $1 | |
107 | exit ;; | |
108 | ||
109 | * ) | |
110 | break ;; | |
111 | esac | |
112 | done | |
113 | ||
114 | case $# in | |
115 | 0) echo "$me: missing argument$help" >&2 | |
116 | exit 1;; | |
117 | 1) ;; | |
118 | *) echo "$me: too many arguments$help" >&2 | |
119 | exit 1;; | |
120 | esac | |
121 | ||
122 | # Separate what the user gave into CPU-COMPANY and OS or KERNEL-OS (if any). | |
123 | # Here we must recognize all the valid KERNEL-OS combinations. | |
124 | maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'` | |
125 | case $maybe_os in | |
126 | nto-qnx* | linux-gnu* | linux-android* | linux-dietlibc | linux-newlib* | \ | |
127 | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | \ | |
128 | knetbsd*-gnu* | netbsd*-gnu* | \ | |
129 | kopensolaris*-gnu* | \ | |
130 | storm-chaos* | os2-emx* | rtmk-nova*) | |
131 | os=-$maybe_os | |
132 | basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'` | |
133 | ;; | |
134 | *) | |
135 | basic_machine=`echo $1 | sed 's/-[^-]*$//'` | |
136 | if [ $basic_machine != $1 ] | |
137 | then os=`echo $1 | sed 's/.*-/-/'` | |
138 | else os=; fi | |
139 | ;; | |
140 | esac | |
141 | ||
142 | ### Let's recognize common machines as not being operating systems so | |
143 | ### that things like config.sub decstation-3100 work. We also | |
144 | ### recognize some manufacturers as not being operating systems, so we | |
145 | ### can provide default operating systems below. | |
146 | case $os in | |
147 | -sun*os*) | |
148 | # Prevent following clause from handling this invalid input. | |
149 | ;; | |
150 | -dec* | -mips* | -sequent* | -encore* | -pc532* | -sgi* | -sony* | \ | |
151 | -att* | -7300* | -3300* | -delta* | -motorola* | -sun[234]* | \ | |
152 | -unicom* | -ibm* | -next | -hp | -isi* | -apollo | -altos* | \ | |
153 | -convergent* | -ncr* | -news | -32* | -3600* | -3100* | -hitachi* |\ | |
154 | -c[123]* | -convex* | -sun | -crds | -omron* | -dg | -ultra | -tti* | \ | |
155 | -harris | -dolphin | -highlevel | -gould | -cbm | -ns | -masscomp | \ | |
156 | -apple | -axis | -knuth | -cray | -microblaze) | |
157 | os= | |
158 | basic_machine=$1 | |
159 | ;; | |
160 | -bluegene*) | |
161 | os=-cnk | |
162 | ;; | |
163 | -sim | -cisco | -oki | -wec | -winbond) | |
164 | os= | |
165 | basic_machine=$1 | |
166 | ;; | |
167 | -scout) | |
168 | ;; | |
169 | -wrs) | |
170 | os=-vxworks | |
171 | basic_machine=$1 | |
172 | ;; | |
173 | -chorusos*) | |
174 | os=-chorusos | |
175 | basic_machine=$1 | |
176 | ;; | |
177 | -chorusrdb) | |
178 | os=-chorusrdb | |
179 | basic_machine=$1 | |
180 | ;; | |
181 | -hiux*) | |
182 | os=-hiuxwe2 | |
183 | ;; | |
184 | -sco6) | |
185 | os=-sco5v6 | |
186 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
187 | ;; | |
188 | -sco5) | |
189 | os=-sco3.2v5 | |
190 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
191 | ;; | |
192 | -sco4) | |
193 | os=-sco3.2v4 | |
194 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
195 | ;; | |
196 | -sco3.2.[4-9]*) | |
197 | os=`echo $os | sed -e 's/sco3.2./sco3.2v/'` | |
198 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
199 | ;; | |
200 | -sco3.2v[4-9]*) | |
201 | # Don't forget version if it is 3.2v4 or newer. | |
202 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
203 | ;; | |
204 | -sco5v6*) | |
205 | # Don't forget version if it is 3.2v4 or newer. | |
206 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
207 | ;; | |
208 | -sco*) | |
209 | os=-sco3.2v2 | |
210 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
211 | ;; | |
212 | -udk*) | |
213 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
214 | ;; | |
215 | -isc) | |
216 | os=-isc2.2 | |
217 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
218 | ;; | |
219 | -clix*) | |
220 | basic_machine=clipper-intergraph | |
221 | ;; | |
222 | -isc*) | |
223 | basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'` | |
224 | ;; | |
225 | -lynx*) | |
226 | os=-lynxos | |
227 | ;; | |
228 | -ptx*) | |
229 | basic_machine=`echo $1 | sed -e 's/86-.*/86-sequent/'` | |
230 | ;; | |
231 | -windowsnt*) | |
232 | os=`echo $os | sed -e 's/windowsnt/winnt/'` | |
233 | ;; | |
234 | -psos*) | |
235 | os=-psos | |
236 | ;; | |
237 | -mint | -mint[0-9]*) | |
238 | basic_machine=m68k-atari | |
239 | os=-mint | |
240 | ;; | |
241 | esac | |
242 | ||
243 | # Decode aliases for certain CPU-COMPANY combinations. | |
244 | case $basic_machine in | |
245 | # Recognize the basic CPU types without company name. | |
246 | # Some are omitted here because they have special meanings below. | |
247 | 1750a | 580 \ | |
248 | | a29k \ | |
249 | | alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \ | |
250 | | alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \ | |
251 | | am33_2.0 \ | |
252 | | arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \ | |
253 | | bfin \ | |
254 | | c4x | clipper \ | |
255 | | d10v | d30v | dlx | dsp16xx \ | |
256 | | fido | fr30 | frv \ | |
257 | | h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \ | |
258 | | i370 | i860 | i960 | ia64 \ | |
259 | | ip2k | iq2000 \ | |
260 | | lm32 \ | |
261 | | m32c | m32r | m32rle | m68000 | m68k | m88k \ | |
262 | | maxq | mb | microblaze | mcore | mep | metag \ | |
263 | | mips | mipsbe | mipseb | mipsel | mipsle \ | |
264 | | mips16 \ | |
265 | | mips64 | mips64el \ | |
266 | | mips64octeon | mips64octeonel \ | |
267 | | mips64orion | mips64orionel \ | |
268 | | mips64r5900 | mips64r5900el \ | |
269 | | mips64vr | mips64vrel \ | |
270 | | mips64vr4100 | mips64vr4100el \ | |
271 | | mips64vr4300 | mips64vr4300el \ | |
272 | | mips64vr5000 | mips64vr5000el \ | |
273 | | mips64vr5900 | mips64vr5900el \ | |
274 | | mipsisa32 | mipsisa32el \ | |
275 | | mipsisa32r2 | mipsisa32r2el \ | |
276 | | mipsisa64 | mipsisa64el \ | |
277 | | mipsisa64r2 | mipsisa64r2el \ | |
278 | | mipsisa64sb1 | mipsisa64sb1el \ | |
279 | | mipsisa64sr71k | mipsisa64sr71kel \ | |
280 | | mipstx39 | mipstx39el \ | |
281 | | mn10200 | mn10300 \ | |
282 | | moxie \ | |
283 | | mt \ | |
284 | | msp430 \ | |
285 | | nds32 | nds32le | nds32be \ | |
286 | | nios | nios2 \ | |
287 | | ns16k | ns32k \ | |
288 | | or32 \ | |
289 | | pdp10 | pdp11 | pj | pjl \ | |
290 | | powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \ | |
291 | | pyramid \ | |
292 | | rx \ | |
293 | | score \ | |
294 | | sh | sh[1234] | sh[24]a | sh[24]aeb | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \ | |
295 | | sh64 | sh64le \ | |
296 | | sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \ | |
297 | | sparcv8 | sparcv9 | sparcv9b | sparcv9v \ | |
298 | | spu | strongarm \ | |
299 | | tahoe | thumb | tic4x | tic54x | tic55x | tic6x | tic80 | tron \ | |
300 | | ubicom32 \ | |
301 | | v850 | v850e \ | |
302 | | we32k \ | |
303 | | x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \ | |
304 | | z8k | z80) | |
305 | basic_machine=$basic_machine-unknown | |
306 | ;; | |
307 | c54x) | |
308 | basic_machine=tic54x-unknown | |
309 | ;; | |
310 | c55x) | |
311 | basic_machine=tic55x-unknown | |
312 | ;; | |
313 | c6x) | |
314 | basic_machine=tic6x-unknown | |
315 | ;; | |
316 | m6811 | m68hc11 | m6812 | m68hc12 | picochip) | |
317 | # Motorola 68HC11/12. | |
318 | basic_machine=$basic_machine-unknown | |
319 | os=-none | |
320 | ;; | |
321 | m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k) | |
322 | ;; | |
323 | ms1) | |
324 | basic_machine=mt-unknown | |
325 | ;; | |
326 | ||
327 | # We use `pc' rather than `unknown' | |
328 | # because (1) that's what they normally are, and | |
329 | # (2) the word "unknown" tends to confuse beginning users. | |
330 | i*86 | x86_64) | |
331 | basic_machine=$basic_machine-pc | |
332 | ;; | |
333 | # Object if more than one company name word. | |
334 | *-*-*) | |
335 | echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 | |
336 | exit 1 | |
337 | ;; | |
338 | # Recognize the basic CPU types with company name. | |
339 | 580-* \ | |
340 | | a29k-* \ | |
341 | | alpha-* | alphaev[4-8]-* | alphaev56-* | alphaev6[78]-* \ | |
342 | | alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \ | |
343 | | alphapca5[67]-* | alpha64pca5[67]-* | arc-* \ | |
344 | | arm-* | armbe-* | armle-* | armeb-* | armv*-* \ | |
345 | | avr-* | avr32-* \ | |
346 | | bfin-* | bs2000-* \ | |
347 | | c[123]* | c30-* | [cjt]90-* | c4x-* \ | |
348 | | clipper-* | craynv-* | cydra-* \ | |
349 | | d10v-* | d30v-* | dlx-* \ | |
350 | | elxsi-* \ | |
351 | | f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \ | |
352 | | h8300-* | h8500-* \ | |
353 | | hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \ | |
354 | | i*86-* | i860-* | i960-* | ia64-* \ | |
355 | | ip2k-* | iq2000-* \ | |
356 | | lm32-* \ | |
357 | | m32c-* | m32r-* | m32rle-* \ | |
358 | | m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \ | |
359 | | m88110-* | m88k-* | maxq-* | mcore-* | metag-* | microblaze-* \ | |
360 | | mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \ | |
361 | | mips16-* \ | |
362 | | mips64-* | mips64el-* \ | |
363 | | mips64octeon-* | mips64octeonel-* \ | |
364 | | mips64orion-* | mips64orionel-* \ | |
365 | | mips64r5900-* | mips64r5900el-* \ | |
366 | | mips64vr-* | mips64vrel-* \ | |
367 | | mips64vr4100-* | mips64vr4100el-* \ | |
368 | | mips64vr4300-* | mips64vr4300el-* \ | |
369 | | mips64vr5000-* | mips64vr5000el-* \ | |
370 | | mips64vr5900-* | mips64vr5900el-* \ | |
371 | | mipsisa32-* | mipsisa32el-* \ | |
372 | | mipsisa32r2-* | mipsisa32r2el-* \ | |
373 | | mipsisa64-* | mipsisa64el-* \ | |
374 | | mipsisa64r2-* | mipsisa64r2el-* \ | |
375 | | mipsisa64sb1-* | mipsisa64sb1el-* \ | |
376 | | mipsisa64sr71k-* | mipsisa64sr71kel-* \ | |
377 | | mipstx39-* | mipstx39el-* \ | |
378 | | mmix-* \ | |
379 | | mt-* \ | |
380 | | msp430-* \ | |
381 | | nds32-* | nds32le-* | nds32be-* \ | |
382 | | nios-* | nios2-* \ | |
383 | | none-* | np1-* | ns16k-* | ns32k-* \ | |
384 | | orion-* \ | |
385 | | pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \ | |
386 | | powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \ | |
387 | | pyramid-* \ | |
388 | | romp-* | rs6000-* | rx-* \ | |
389 | | sh-* | sh[1234]-* | sh[24]a-* | sh[24]aeb-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \ | |
390 | | shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \ | |
391 | | sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \ | |
392 | | sparclite-* \ | |
393 | | sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \ | |
394 | | tahoe-* | thumb-* \ | |
395 | | tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \ | |
396 | | tile-* | tilegx-* \ | |
397 | | tron-* \ | |
398 | | ubicom32-* \ | |
399 | | v850-* | v850e-* | vax-* \ | |
400 | | we32k-* \ | |
401 | | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ | |
402 | | xstormy16-* | xtensa*-* \ | |
403 | | ymp-* \ | |
404 | | z8k-* | z80-*) | |
405 | ;; | |
406 | # Recognize the basic CPU types without company name, with glob match. | |
407 | xtensa*) | |
408 | basic_machine=$basic_machine-unknown | |
409 | ;; | |
410 | # Recognize the various machine names and aliases which stand | |
411 | # for a CPU type and a company and sometimes even an OS. | |
412 | 386bsd) | |
413 | basic_machine=i386-unknown | |
414 | os=-bsd | |
415 | ;; | |
416 | 3b1 | 7300 | 7300-att | att-7300 | pc7300 | safari | unixpc) | |
417 | basic_machine=m68000-att | |
418 | ;; | |
419 | 3b*) | |
420 | basic_machine=we32k-att | |
421 | ;; | |
422 | a29khif) | |
423 | basic_machine=a29k-amd | |
424 | os=-udi | |
425 | ;; | |
426 | abacus) | |
427 | basic_machine=abacus-unknown | |
428 | ;; | |
429 | adobe68k) | |
430 | basic_machine=m68010-adobe | |
431 | os=-scout | |
432 | ;; | |
433 | alliant | fx80) | |
434 | basic_machine=fx80-alliant | |
435 | ;; | |
436 | altos | altos3068) | |
437 | basic_machine=m68k-altos | |
438 | ;; | |
439 | am29k) | |
440 | basic_machine=a29k-none | |
441 | os=-bsd | |
442 | ;; | |
443 | amd64) | |
444 | basic_machine=x86_64-pc | |
445 | ;; | |
446 | amd64-*) | |
447 | basic_machine=x86_64-`echo $basic_machine | sed 's/^[^-]*-//'` | |
448 | ;; | |
449 | amdahl) | |
450 | basic_machine=580-amdahl | |
451 | os=-sysv | |
452 | ;; | |
453 | amiga | amiga-*) | |
454 | basic_machine=m68k-unknown | |
455 | ;; | |
456 | amigaos | amigados) | |
457 | basic_machine=m68k-unknown | |
458 | os=-amigaos | |
459 | ;; | |
460 | amigaunix | amix) | |
461 | basic_machine=m68k-unknown | |
462 | os=-sysv4 | |
463 | ;; | |
464 | apollo68) | |
465 | basic_machine=m68k-apollo | |
466 | os=-sysv | |
467 | ;; | |
468 | apollo68bsd) | |
469 | basic_machine=m68k-apollo | |
470 | os=-bsd | |
471 | ;; | |
472 | aros) | |
473 | basic_machine=i386-pc | |
474 | os=-aros | |
475 | ;; | |
476 | aux) | |
477 | basic_machine=m68k-apple | |
478 | os=-aux | |
479 | ;; | |
480 | balance) | |
481 | basic_machine=ns32k-sequent | |
482 | os=-dynix | |
483 | ;; | |
484 | blackfin) | |
485 | basic_machine=bfin-unknown | |
486 | os=-linux | |
487 | ;; | |
488 | blackfin-*) | |
489 | basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` | |
490 | os=-linux | |
491 | ;; | |
492 | bluegene*) | |
493 | basic_machine=powerpc-ibm | |
494 | os=-cnk | |
495 | ;; | |
496 | c54x-*) | |
497 | basic_machine=tic54x-`echo $basic_machine | sed 's/^[^-]*-//'` | |
498 | ;; | |
499 | c55x-*) | |
500 | basic_machine=tic55x-`echo $basic_machine | sed 's/^[^-]*-//'` | |
501 | ;; | |
502 | c6x-*) | |
503 | basic_machine=tic6x-`echo $basic_machine | sed 's/^[^-]*-//'` | |
504 | ;; | |
505 | c90) | |
506 | basic_machine=c90-cray | |
507 | os=-unicos | |
508 | ;; | |
509 | cegcc) | |
510 | basic_machine=arm-unknown | |
511 | os=-cegcc | |
512 | ;; | |
513 | convex-c1) | |
514 | basic_machine=c1-convex | |
515 | os=-bsd | |
516 | ;; | |
517 | convex-c2) | |
518 | basic_machine=c2-convex | |
519 | os=-bsd | |
520 | ;; | |
521 | convex-c32) | |
522 | basic_machine=c32-convex | |
523 | os=-bsd | |
524 | ;; | |
525 | convex-c34) | |
526 | basic_machine=c34-convex | |
527 | os=-bsd | |
528 | ;; | |
529 | convex-c38) | |
530 | basic_machine=c38-convex | |
531 | os=-bsd | |
532 | ;; | |
533 | cray | j90) | |
534 | basic_machine=j90-cray | |
535 | os=-unicos | |
536 | ;; | |
537 | craynv) | |
538 | basic_machine=craynv-cray | |
539 | os=-unicosmp | |
540 | ;; | |
541 | cr16) | |
542 | basic_machine=cr16-unknown | |
543 | os=-elf | |
544 | ;; | |
545 | crds | unos) | |
546 | basic_machine=m68k-crds | |
547 | ;; | |
548 | crisv32 | crisv32-* | etraxfs*) | |
549 | basic_machine=crisv32-axis | |
550 | ;; | |
551 | cris | cris-* | etrax*) | |
552 | basic_machine=cris-axis | |
553 | ;; | |
554 | crx) | |
555 | basic_machine=crx-unknown | |
556 | os=-elf | |
557 | ;; | |
558 | da30 | da30-*) | |
559 | basic_machine=m68k-da30 | |
560 | ;; | |
561 | decstation | decstation-3100 | pmax | pmax-* | pmin | dec3100 | decstatn) | |
562 | basic_machine=mips-dec | |
563 | ;; | |
564 | decsystem10* | dec10*) | |
565 | basic_machine=pdp10-dec | |
566 | os=-tops10 | |
567 | ;; | |
568 | decsystem20* | dec20*) | |
569 | basic_machine=pdp10-dec | |
570 | os=-tops20 | |
571 | ;; | |
572 | delta | 3300 | motorola-3300 | motorola-delta \ | |
573 | | 3300-motorola | delta-motorola) | |
574 | basic_machine=m68k-motorola | |
575 | ;; | |
576 | delta88) | |
577 | basic_machine=m88k-motorola | |
578 | os=-sysv3 | |
579 | ;; | |
580 | dicos) | |
581 | basic_machine=i686-pc | |
582 | os=-dicos | |
583 | ;; | |
584 | djgpp) | |
585 | basic_machine=i586-pc | |
586 | os=-msdosdjgpp | |
587 | ;; | |
588 | dpx20 | dpx20-*) | |
589 | basic_machine=rs6000-bull | |
590 | os=-bosx | |
591 | ;; | |
592 | dpx2* | dpx2*-bull) | |
593 | basic_machine=m68k-bull | |
594 | os=-sysv3 | |
595 | ;; | |
596 | ebmon29k) | |
597 | basic_machine=a29k-amd | |
598 | os=-ebmon | |
599 | ;; | |
600 | elxsi) | |
601 | basic_machine=elxsi-elxsi | |
602 | os=-bsd | |
603 | ;; | |
604 | encore | umax | mmax) | |
605 | basic_machine=ns32k-encore | |
606 | ;; | |
607 | es1800 | OSE68k | ose68k | ose | OSE) | |
608 | basic_machine=m68k-ericsson | |
609 | os=-ose | |
610 | ;; | |
611 | fx2800) | |
612 | basic_machine=i860-alliant | |
613 | ;; | |
614 | genix) | |
615 | basic_machine=ns32k-ns | |
616 | ;; | |
617 | gmicro) | |
618 | basic_machine=tron-gmicro | |
619 | os=-sysv | |
620 | ;; | |
621 | go32) | |
622 | basic_machine=i386-pc | |
623 | os=-go32 | |
624 | ;; | |
625 | h3050r* | hiux*) | |
626 | basic_machine=hppa1.1-hitachi | |
627 | os=-hiuxwe2 | |
628 | ;; | |
629 | h8300hms) | |
630 | basic_machine=h8300-hitachi | |
631 | os=-hms | |
632 | ;; | |
633 | h8300xray) | |
634 | basic_machine=h8300-hitachi | |
635 | os=-xray | |
636 | ;; | |
637 | h8500hms) | |
638 | basic_machine=h8500-hitachi | |
639 | os=-hms | |
640 | ;; | |
641 | harris) | |
642 | basic_machine=m88k-harris | |
643 | os=-sysv3 | |
644 | ;; | |
645 | hp300-*) | |
646 | basic_machine=m68k-hp | |
647 | ;; | |
648 | hp300bsd) | |
649 | basic_machine=m68k-hp | |
650 | os=-bsd | |
651 | ;; | |
652 | hp300hpux) | |
653 | basic_machine=m68k-hp | |
654 | os=-hpux | |
655 | ;; | |
656 | hp3k9[0-9][0-9] | hp9[0-9][0-9]) | |
657 | basic_machine=hppa1.0-hp | |
658 | ;; | |
659 | hp9k2[0-9][0-9] | hp9k31[0-9]) | |
660 | basic_machine=m68000-hp | |
661 | ;; | |
662 | hp9k3[2-9][0-9]) | |
663 | basic_machine=m68k-hp | |
664 | ;; | |
665 | hp9k6[0-9][0-9] | hp6[0-9][0-9]) | |
666 | basic_machine=hppa1.0-hp | |
667 | ;; | |
668 | hp9k7[0-79][0-9] | hp7[0-79][0-9]) | |
669 | basic_machine=hppa1.1-hp | |
670 | ;; | |
671 | hp9k78[0-9] | hp78[0-9]) | |
672 | # FIXME: really hppa2.0-hp | |
673 | basic_machine=hppa1.1-hp | |
674 | ;; | |
675 | hp9k8[67]1 | hp8[67]1 | hp9k80[24] | hp80[24] | hp9k8[78]9 | hp8[78]9 | hp9k893 | hp893) | |
676 | # FIXME: really hppa2.0-hp | |
677 | basic_machine=hppa1.1-hp | |
678 | ;; | |
679 | hp9k8[0-9][13679] | hp8[0-9][13679]) | |
680 | basic_machine=hppa1.1-hp | |
681 | ;; | |
682 | hp9k8[0-9][0-9] | hp8[0-9][0-9]) | |
683 | basic_machine=hppa1.0-hp | |
684 | ;; | |
685 | hppa-next) | |
686 | os=-nextstep3 | |
687 | ;; | |
688 | hppaosf) | |
689 | basic_machine=hppa1.1-hp | |
690 | os=-osf | |
691 | ;; | |
692 | hppro) | |
693 | basic_machine=hppa1.1-hp | |
694 | os=-proelf | |
695 | ;; | |
696 | i370-ibm* | ibm*) | |
697 | basic_machine=i370-ibm | |
698 | ;; | |
699 | # I'm not sure what "Sysv32" means. Should this be sysv3.2? | |
700 | i*86v32) | |
701 | basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` | |
702 | os=-sysv32 | |
703 | ;; | |
704 | i*86v4*) | |
705 | basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` | |
706 | os=-sysv4 | |
707 | ;; | |
708 | i*86v) | |
709 | basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` | |
710 | os=-sysv | |
711 | ;; | |
712 | i*86sol2) | |
713 | basic_machine=`echo $1 | sed -e 's/86.*/86-pc/'` | |
714 | os=-solaris2 | |
715 | ;; | |
716 | i386mach) | |
717 | basic_machine=i386-mach | |
718 | os=-mach | |
719 | ;; | |
720 | i386-vsta | vsta) | |
721 | basic_machine=i386-unknown | |
722 | os=-vsta | |
723 | ;; | |
724 | iris | iris4d) | |
725 | basic_machine=mips-sgi | |
726 | case $os in | |
727 | -irix*) | |
728 | ;; | |
729 | *) | |
730 | os=-irix4 | |
731 | ;; | |
732 | esac | |
733 | ;; | |
734 | isi68 | isi) | |
735 | basic_machine=m68k-isi | |
736 | os=-sysv | |
737 | ;; | |
738 | m68knommu) | |
739 | basic_machine=m68k-unknown | |
740 | os=-linux | |
741 | ;; | |
742 | m68knommu-*) | |
743 | basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` | |
744 | os=-linux | |
745 | ;; | |
746 | m88k-omron*) | |
747 | basic_machine=m88k-omron | |
748 | ;; | |
749 | magnum | m3230) | |
750 | basic_machine=mips-mips | |
751 | os=-sysv | |
752 | ;; | |
753 | merlin) | |
754 | basic_machine=ns32k-utek | |
755 | os=-sysv | |
756 | ;; | |
757 | microblaze) | |
758 | basic_machine=microblaze-xilinx | |
759 | ;; | |
760 | mingw32) | |
761 | basic_machine=i386-pc | |
762 | os=-mingw32 | |
763 | ;; | |
764 | mingw32ce) | |
765 | basic_machine=arm-unknown | |
766 | os=-mingw32ce | |
767 | ;; | |
768 | miniframe) | |
769 | basic_machine=m68000-convergent | |
770 | ;; | |
771 | *mint | -mint[0-9]* | *MiNT | *MiNT[0-9]*) | |
772 | basic_machine=m68k-atari | |
773 | os=-mint | |
774 | ;; | |
775 | mips3*-*) | |
776 | basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'` | |
777 | ;; | |
778 | mips3*) | |
779 | basic_machine=`echo $basic_machine | sed -e 's/mips3/mips64/'`-unknown | |
780 | ;; | |
781 | monitor) | |
782 | basic_machine=m68k-rom68k | |
783 | os=-coff | |
784 | ;; | |
785 | morphos) | |
786 | basic_machine=powerpc-unknown | |
787 | os=-morphos | |
788 | ;; | |
789 | msdos) | |
790 | basic_machine=i386-pc | |
791 | os=-msdos | |
792 | ;; | |
793 | ms1-*) | |
794 | basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'` | |
795 | ;; | |
796 | mvs) | |
797 | basic_machine=i370-ibm | |
798 | os=-mvs | |
799 | ;; | |
800 | ncr3000) | |
801 | basic_machine=i486-ncr | |
802 | os=-sysv4 | |
803 | ;; | |
804 | netbsd386) | |
805 | basic_machine=i386-unknown | |
806 | os=-netbsd | |
807 | ;; | |
808 | netwinder) | |
809 | basic_machine=armv4l-rebel | |
810 | os=-linux | |
811 | ;; | |
812 | news | news700 | news800 | news900) | |
813 | basic_machine=m68k-sony | |
814 | os=-newsos | |
815 | ;; | |
816 | news1000) | |
817 | basic_machine=m68030-sony | |
818 | os=-newsos | |
819 | ;; | |
820 | news-3600 | risc-news) | |
821 | basic_machine=mips-sony | |
822 | os=-newsos | |
823 | ;; | |
824 | necv70) | |
825 | basic_machine=v70-nec | |
826 | os=-sysv | |
827 | ;; | |
828 | next | m*-next ) | |
829 | basic_machine=m68k-next | |
830 | case $os in | |
831 | -nextstep* ) | |
832 | ;; | |
833 | -ns2*) | |
834 | os=-nextstep2 | |
835 | ;; | |
836 | *) | |
837 | os=-nextstep3 | |
838 | ;; | |
839 | esac | |
840 | ;; | |
841 | nh3000) | |
842 | basic_machine=m68k-harris | |
843 | os=-cxux | |
844 | ;; | |
845 | nh[45]000) | |
846 | basic_machine=m88k-harris | |
847 | os=-cxux | |
848 | ;; | |
849 | nindy960) | |
850 | basic_machine=i960-intel | |
851 | os=-nindy | |
852 | ;; | |
853 | mon960) | |
854 | basic_machine=i960-intel | |
855 | os=-mon960 | |
856 | ;; | |
857 | nonstopux) | |
858 | basic_machine=mips-compaq | |
859 | os=-nonstopux | |
860 | ;; | |
861 | np1) | |
862 | basic_machine=np1-gould | |
863 | ;; | |
864 | neo-tandem) | |
865 | basic_machine=neo-tandem | |
866 | ;; | |
867 | nse-tandem) | |
868 | basic_machine=nse-tandem | |
869 | ;; | |
870 | nsr-tandem) | |
871 | basic_machine=nsr-tandem | |
872 | ;; | |
873 | op50n-* | op60c-*) | |
874 | basic_machine=hppa1.1-oki | |
875 | os=-proelf | |
876 | ;; | |
877 | openrisc | openrisc-*) | |
878 | basic_machine=or32-unknown | |
879 | ;; | |
880 | os400) | |
881 | basic_machine=powerpc-ibm | |
882 | os=-os400 | |
883 | ;; | |
884 | OSE68000 | ose68000) | |
885 | basic_machine=m68000-ericsson | |
886 | os=-ose | |
887 | ;; | |
888 | os68k) | |
889 | basic_machine=m68k-none | |
890 | os=-os68k | |
891 | ;; | |
892 | pa-hitachi) | |
893 | basic_machine=hppa1.1-hitachi | |
894 | os=-hiuxwe2 | |
895 | ;; | |
896 | paragon) | |
897 | basic_machine=i860-intel | |
898 | os=-osf | |
899 | ;; | |
900 | parisc) | |
901 | basic_machine=hppa-unknown | |
902 | os=-linux | |
903 | ;; | |
904 | parisc-*) | |
905 | basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` | |
906 | os=-linux | |
907 | ;; | |
908 | pbd) | |
909 | basic_machine=sparc-tti | |
910 | ;; | |
911 | pbb) | |
912 | basic_machine=m68k-tti | |
913 | ;; | |
914 | pc532 | pc532-*) | |
915 | basic_machine=ns32k-pc532 | |
916 | ;; | |
917 | pc98) | |
918 | basic_machine=i386-pc | |
919 | ;; | |
920 | pc98-*) | |
921 | basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'` | |
922 | ;; | |
923 | pentium | p5 | k5 | k6 | nexgen | viac3) | |
924 | basic_machine=i586-pc | |
925 | ;; | |
926 | pentiumpro | p6 | 6x86 | athlon | athlon_*) | |
927 | basic_machine=i686-pc | |
928 | ;; | |
929 | pentiumii | pentium2 | pentiumiii | pentium3) | |
930 | basic_machine=i686-pc | |
931 | ;; | |
932 | pentium4) | |
933 | basic_machine=i786-pc | |
934 | ;; | |
935 | pentium-* | p5-* | k5-* | k6-* | nexgen-* | viac3-*) | |
936 | basic_machine=i586-`echo $basic_machine | sed 's/^[^-]*-//'` | |
937 | ;; | |
938 | pentiumpro-* | p6-* | 6x86-* | athlon-*) | |
939 | basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` | |
940 | ;; | |
941 | pentiumii-* | pentium2-* | pentiumiii-* | pentium3-*) | |
942 | basic_machine=i686-`echo $basic_machine | sed 's/^[^-]*-//'` | |
943 | ;; | |
944 | pentium4-*) | |
945 | basic_machine=i786-`echo $basic_machine | sed 's/^[^-]*-//'` | |
946 | ;; | |
947 | pn) | |
948 | basic_machine=pn-gould | |
949 | ;; | |
950 | power) basic_machine=power-ibm | |
951 | ;; | |
952 | ppc) basic_machine=powerpc-unknown | |
953 | ;; | |
954 | ppc-*) basic_machine=powerpc-`echo $basic_machine | sed 's/^[^-]*-//'` | |
955 | ;; | |
956 | ppcle | powerpclittle | ppc-le | powerpc-little) | |
957 | basic_machine=powerpcle-unknown | |
958 | ;; | |
959 | ppcle-* | powerpclittle-*) | |
960 | basic_machine=powerpcle-`echo $basic_machine | sed 's/^[^-]*-//'` | |
961 | ;; | |
962 | ppc64) basic_machine=powerpc64-unknown | |
963 | ;; | |
964 | ppc64-*) basic_machine=powerpc64-`echo $basic_machine | sed 's/^[^-]*-//'` | |
965 | ;; | |
966 | ppc64le | powerpc64little | ppc64-le | powerpc64-little) | |
967 | basic_machine=powerpc64le-unknown | |
968 | ;; | |
969 | ppc64le-* | powerpc64little-*) | |
970 | basic_machine=powerpc64le-`echo $basic_machine | sed 's/^[^-]*-//'` | |
971 | ;; | |
972 | ps2) | |
973 | basic_machine=i386-ibm | |
974 | ;; | |
975 | pw32) | |
976 | basic_machine=i586-unknown | |
977 | os=-pw32 | |
978 | ;; | |
979 | rdos) | |
980 | basic_machine=i386-pc | |
981 | os=-rdos | |
982 | ;; | |
983 | rom68k) | |
984 | basic_machine=m68k-rom68k | |
985 | os=-coff | |
986 | ;; | |
987 | rm[46]00) | |
988 | basic_machine=mips-siemens | |
989 | ;; | |
990 | rtpc | rtpc-*) | |
991 | basic_machine=romp-ibm | |
992 | ;; | |
993 | s390 | s390-*) | |
994 | basic_machine=s390-ibm | |
995 | ;; | |
996 | s390x | s390x-*) | |
997 | basic_machine=s390x-ibm | |
998 | ;; | |
999 | sa29200) | |
1000 | basic_machine=a29k-amd | |
1001 | os=-udi | |
1002 | ;; | |
1003 | sb1) | |
1004 | basic_machine=mipsisa64sb1-unknown | |
1005 | ;; | |
1006 | sb1el) | |
1007 | basic_machine=mipsisa64sb1el-unknown | |
1008 | ;; | |
1009 | sde) | |
1010 | basic_machine=mipsisa32-sde | |
1011 | os=-elf | |
1012 | ;; | |
1013 | sei) | |
1014 | basic_machine=mips-sei | |
1015 | os=-seiux | |
1016 | ;; | |
1017 | sequent) | |
1018 | basic_machine=i386-sequent | |
1019 | ;; | |
1020 | sh) | |
1021 | basic_machine=sh-hitachi | |
1022 | os=-hms | |
1023 | ;; | |
1024 | sh5el) | |
1025 | basic_machine=sh5le-unknown | |
1026 | ;; | |
1027 | sh64) | |
1028 | basic_machine=sh64-unknown | |
1029 | ;; | |
1030 | sparclite-wrs | simso-wrs) | |
1031 | basic_machine=sparclite-wrs | |
1032 | os=-vxworks | |
1033 | ;; | |
1034 | sps7) | |
1035 | basic_machine=m68k-bull | |
1036 | os=-sysv2 | |
1037 | ;; | |
1038 | spur) | |
1039 | basic_machine=spur-unknown | |
1040 | ;; | |
1041 | st2000) | |
1042 | basic_machine=m68k-tandem | |
1043 | ;; | |
1044 | stratus) | |
1045 | basic_machine=i860-stratus | |
1046 | os=-sysv4 | |
1047 | ;; | |
1048 | sun2) | |
1049 | basic_machine=m68000-sun | |
1050 | ;; | |
1051 | sun2os3) | |
1052 | basic_machine=m68000-sun | |
1053 | os=-sunos3 | |
1054 | ;; | |
1055 | sun2os4) | |
1056 | basic_machine=m68000-sun | |
1057 | os=-sunos4 | |
1058 | ;; | |
1059 | sun3os3) | |
1060 | basic_machine=m68k-sun | |
1061 | os=-sunos3 | |
1062 | ;; | |
1063 | sun3os4) | |
1064 | basic_machine=m68k-sun | |
1065 | os=-sunos4 | |
1066 | ;; | |
1067 | sun4os3) | |
1068 | basic_machine=sparc-sun | |
1069 | os=-sunos3 | |
1070 | ;; | |
1071 | sun4os4) | |
1072 | basic_machine=sparc-sun | |
1073 | os=-sunos4 | |
1074 | ;; | |
1075 | sun4sol2) | |
1076 | basic_machine=sparc-sun | |
1077 | os=-solaris2 | |
1078 | ;; | |
1079 | sun3 | sun3-*) | |
1080 | basic_machine=m68k-sun | |
1081 | ;; | |
1082 | sun4) | |
1083 | basic_machine=sparc-sun | |
1084 | ;; | |
1085 | sun386 | sun386i | roadrunner) | |
1086 | basic_machine=i386-sun | |
1087 | ;; | |
1088 | sv1) | |
1089 | basic_machine=sv1-cray | |
1090 | os=-unicos | |
1091 | ;; | |
1092 | symmetry) | |
1093 | basic_machine=i386-sequent | |
1094 | os=-dynix | |
1095 | ;; | |
1096 | t3e) | |
1097 | basic_machine=alphaev5-cray | |
1098 | os=-unicos | |
1099 | ;; | |
1100 | t90) | |
1101 | basic_machine=t90-cray | |
1102 | os=-unicos | |
1103 | ;; | |
1104 | # This must be matched before tile*. | |
1105 | tilegx*) | |
1106 | basic_machine=tilegx-unknown | |
1107 | os=-linux-gnu | |
1108 | ;; | |
1109 | tile*) | |
1110 | basic_machine=tile-unknown | |
1111 | os=-linux-gnu | |
1112 | ;; | |
1113 | tx39) | |
1114 | basic_machine=mipstx39-unknown | |
1115 | ;; | |
1116 | tx39el) | |
1117 | basic_machine=mipstx39el-unknown | |
1118 | ;; | |
1119 | toad1) | |
1120 | basic_machine=pdp10-xkl | |
1121 | os=-tops20 | |
1122 | ;; | |
1123 | tower | tower-32) | |
1124 | basic_machine=m68k-ncr | |
1125 | ;; | |
1126 | tpf) | |
1127 | basic_machine=s390x-ibm | |
1128 | os=-tpf | |
1129 | ;; | |
1130 | udi29k) | |
1131 | basic_machine=a29k-amd | |
1132 | os=-udi | |
1133 | ;; | |
1134 | ultra3) | |
1135 | basic_machine=a29k-nyu | |
1136 | os=-sym1 | |
1137 | ;; | |
1138 | v810 | necv810) | |
1139 | basic_machine=v810-nec | |
1140 | os=-none | |
1141 | ;; | |
1142 | vaxv) | |
1143 | basic_machine=vax-dec | |
1144 | os=-sysv | |
1145 | ;; | |
1146 | vms) | |
1147 | basic_machine=vax-dec | |
1148 | os=-vms | |
1149 | ;; | |
1150 | vpp*|vx|vx-*) | |
1151 | basic_machine=f301-fujitsu | |
1152 | ;; | |
1153 | vxworks960) | |
1154 | basic_machine=i960-wrs | |
1155 | os=-vxworks | |
1156 | ;; | |
1157 | vxworks68) | |
1158 | basic_machine=m68k-wrs | |
1159 | os=-vxworks | |
1160 | ;; | |
1161 | vxworks29k) | |
1162 | basic_machine=a29k-wrs | |
1163 | os=-vxworks | |
1164 | ;; | |
1165 | w65*) | |
1166 | basic_machine=w65-wdc | |
1167 | os=-none | |
1168 | ;; | |
1169 | w89k-*) | |
1170 | basic_machine=hppa1.1-winbond | |
1171 | os=-proelf | |
1172 | ;; | |
1173 | xbox) | |
1174 | basic_machine=i686-pc | |
1175 | os=-mingw32 | |
1176 | ;; | |
1177 | xps | xps100) | |
1178 | basic_machine=xps100-honeywell | |
1179 | ;; | |
1180 | ymp) | |
1181 | basic_machine=ymp-cray | |
1182 | os=-unicos | |
1183 | ;; | |
1184 | z8k-*-coff) | |
1185 | basic_machine=z8k-unknown | |
1186 | os=-sim | |
1187 | ;; | |
1188 | z80-*-coff) | |
1189 | basic_machine=z80-unknown | |
1190 | os=-sim | |
1191 | ;; | |
1192 | none) | |
1193 | basic_machine=none-none | |
1194 | os=-none | |
1195 | ;; | |
1196 | ||
1197 | # Here we handle the default manufacturer of certain CPU types. It is in | |
1198 | # some cases the only manufacturer, in others, it is the most popular. | |
1199 | w89k) | |
1200 | basic_machine=hppa1.1-winbond | |
1201 | ;; | |
1202 | op50n) | |
1203 | basic_machine=hppa1.1-oki | |
1204 | ;; | |
1205 | op60c) | |
1206 | basic_machine=hppa1.1-oki | |
1207 | ;; | |
1208 | romp) | |
1209 | basic_machine=romp-ibm | |
1210 | ;; | |
1211 | mmix) | |
1212 | basic_machine=mmix-knuth | |
1213 | ;; | |
1214 | rs6000) | |
1215 | basic_machine=rs6000-ibm | |
1216 | ;; | |
1217 | vax) | |
1218 | basic_machine=vax-dec | |
1219 | ;; | |
1220 | pdp10) | |
1221 | # there are many clones, so DEC is not a safe bet | |
1222 | basic_machine=pdp10-unknown | |
1223 | ;; | |
1224 | pdp11) | |
1225 | basic_machine=pdp11-dec | |
1226 | ;; | |
1227 | we32k) | |
1228 | basic_machine=we32k-att | |
1229 | ;; | |
1230 | sh[1234] | sh[24]a | sh[24]aeb | sh[34]eb | sh[1234]le | sh[23]ele) | |
1231 | basic_machine=sh-unknown | |
1232 | ;; | |
1233 | sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v) | |
1234 | basic_machine=sparc-sun | |
1235 | ;; | |
1236 | cydra) | |
1237 | basic_machine=cydra-cydrome | |
1238 | ;; | |
1239 | orion) | |
1240 | basic_machine=orion-highlevel | |
1241 | ;; | |
1242 | orion105) | |
1243 | basic_machine=clipper-highlevel | |
1244 | ;; | |
1245 | mac | mpw | mac-mpw) | |
1246 | basic_machine=m68k-apple | |
1247 | ;; | |
1248 | pmac | pmac-mpw) | |
1249 | basic_machine=powerpc-apple | |
1250 | ;; | |
1251 | *-unknown) | |
1252 | # Make sure to match an already-canonicalized machine name. | |
1253 | ;; | |
1254 | *) | |
1255 | echo Invalid configuration \`$1\': machine \`$basic_machine\' not recognized 1>&2 | |
1256 | exit 1 | |
1257 | ;; | |
1258 | esac | |
1259 | ||
1260 | # Here we canonicalize certain aliases for manufacturers. | |
1261 | case $basic_machine in | |
1262 | *-digital*) | |
1263 | basic_machine=`echo $basic_machine | sed 's/digital.*/dec/'` | |
1264 | ;; | |
1265 | *-commodore*) | |
1266 | basic_machine=`echo $basic_machine | sed 's/commodore.*/cbm/'` | |
1267 | ;; | |
1268 | *) | |
1269 | ;; | |
1270 | esac | |
1271 | ||
1272 | # Decode manufacturer-specific aliases for certain operating systems. | |
1273 | ||
1274 | if [ x"$os" != x"" ] | |
1275 | then | |
1276 | case $os in | |
1277 | # First match some system type aliases | |
1278 | # that might get confused with valid system types. | |
1279 | # -solaris* is a basic system type, with this one exception. | |
1280 | -auroraux) | |
1281 | os=-auroraux | |
1282 | ;; | |
1283 | -solaris1 | -solaris1.*) | |
1284 | os=`echo $os | sed -e 's|solaris1|sunos4|'` | |
1285 | ;; | |
1286 | -solaris) | |
1287 | os=-solaris2 | |
1288 | ;; | |
1289 | -svr4*) | |
1290 | os=-sysv4 | |
1291 | ;; | |
1292 | -unixware*) | |
1293 | os=-sysv4.2uw | |
1294 | ;; | |
1295 | -gnu/linux*) | |
1296 | os=`echo $os | sed -e 's|gnu/linux|linux-gnu|'` | |
1297 | ;; | |
1298 | # First accept the basic system types. | |
1299 | # The portable systems comes first. | |
1300 | # Each alternative MUST END IN A *, to match a version number. | |
1301 | # -sysv* is not here because it comes later, after sysvr4. | |
1302 | -gnu* | -bsd* | -mach* | -minix* | -genix* | -ultrix* | -irix* \ | |
1303 | | -*vms* | -sco* | -esix* | -isc* | -aix* | -cnk* | -sunos | -sunos[34]*\ | |
1304 | | -hpux* | -unos* | -osf* | -luna* | -dgux* | -auroraux* | -solaris* \ | |
1305 | | -sym* | -kopensolaris* \ | |
1306 | | -amigaos* | -amigados* | -msdos* | -newsos* | -unicos* | -aof* \ | |
1307 | | -aos* | -aros* \ | |
1308 | | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \ | |
1309 | | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \ | |
1310 | | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \ | |
1311 | | -openbsd* | -solidbsd* \ | |
1312 | | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \ | |
1313 | | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \ | |
1314 | | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \ | |
1315 | | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \ | |
1316 | | -chorusos* | -chorusrdb* | -cegcc* \ | |
1317 | | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \ | |
1318 | | -mingw32* | -linux-gnu* | -linux-android* \ | |
1319 | | -linux-newlib* | -linux-uclibc* \ | |
1320 | | -uxpv* | -beos* | -mpeix* | -udk* \ | |
1321 | | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \ | |
1322 | | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \ | |
1323 | | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \ | |
1324 | | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \ | |
1325 | | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \ | |
1326 | | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \ | |
1327 | | -skyos* | -haiku* | -rdos* | -toppers* | -drops* | -es*) | |
1328 | # Remember, each alternative MUST END IN *, to match a version number. | |
1329 | ;; | |
1330 | -qnx*) | |
1331 | case $basic_machine in | |
1332 | x86-* | i*86-*) | |
1333 | ;; | |
1334 | *) | |
1335 | os=-nto$os | |
1336 | ;; | |
1337 | esac | |
1338 | ;; | |
1339 | -nto-qnx*) | |
1340 | ;; | |
1341 | -nto*) | |
1342 | os=`echo $os | sed -e 's|nto|nto-qnx|'` | |
1343 | ;; | |
1344 | -sim | -es1800* | -hms* | -xray | -os68k* | -none* | -v88r* \ | |
1345 | | -windows* | -osx | -abug | -netware* | -os9* | -beos* | -haiku* \ | |
1346 | | -macos* | -mpw* | -magic* | -mmixware* | -mon960* | -lnews*) | |
1347 | ;; | |
1348 | -mac*) | |
1349 | os=`echo $os | sed -e 's|mac|macos|'` | |
1350 | ;; | |
1351 | -linux-dietlibc) | |
1352 | os=-linux-dietlibc | |
1353 | ;; | |
1354 | -linux*) | |
1355 | os=`echo $os | sed -e 's|linux|linux-gnu|'` | |
1356 | ;; | |
1357 | -sunos5*) | |
1358 | os=`echo $os | sed -e 's|sunos5|solaris2|'` | |
1359 | ;; | |
1360 | -sunos6*) | |
1361 | os=`echo $os | sed -e 's|sunos6|solaris3|'` | |
1362 | ;; | |
1363 | -opened*) | |
1364 | os=-openedition | |
1365 | ;; | |
1366 | -os400*) | |
1367 | os=-os400 | |
1368 | ;; | |
1369 | -wince*) | |
1370 | os=-wince | |
1371 | ;; | |
1372 | -osfrose*) | |
1373 | os=-osfrose | |
1374 | ;; | |
1375 | -osf*) | |
1376 | os=-osf | |
1377 | ;; | |
1378 | -utek*) | |
1379 | os=-bsd | |
1380 | ;; | |
1381 | -dynix*) | |
1382 | os=-bsd | |
1383 | ;; | |
1384 | -acis*) | |
1385 | os=-aos | |
1386 | ;; | |
1387 | -atheos*) | |
1388 | os=-atheos | |
1389 | ;; | |
1390 | -syllable*) | |
1391 | os=-syllable | |
1392 | ;; | |
1393 | -386bsd) | |
1394 | os=-bsd | |
1395 | ;; | |
1396 | -ctix* | -uts*) | |
1397 | os=-sysv | |
1398 | ;; | |
1399 | -nova*) | |
1400 | os=-rtmk-nova | |
1401 | ;; | |
1402 | -ns2 ) | |
1403 | os=-nextstep2 | |
1404 | ;; | |
1405 | -nsk*) | |
1406 | os=-nsk | |
1407 | ;; | |
1408 | # Preserve the version number of sinix5. | |
1409 | -sinix5.*) | |
1410 | os=`echo $os | sed -e 's|sinix|sysv|'` | |
1411 | ;; | |
1412 | -sinix*) | |
1413 | os=-sysv4 | |
1414 | ;; | |
1415 | -tpf*) | |
1416 | os=-tpf | |
1417 | ;; | |
1418 | -triton*) | |
1419 | os=-sysv3 | |
1420 | ;; | |
1421 | -oss*) | |
1422 | os=-sysv3 | |
1423 | ;; | |
1424 | -svr4) | |
1425 | os=-sysv4 | |
1426 | ;; | |
1427 | -svr3) | |
1428 | os=-sysv3 | |
1429 | ;; | |
1430 | -sysvr4) | |
1431 | os=-sysv4 | |
1432 | ;; | |
1433 | # This must come after -sysvr4. | |
1434 | -sysv*) | |
1435 | ;; | |
1436 | -ose*) | |
1437 | os=-ose | |
1438 | ;; | |
1439 | -es1800*) | |
1440 | os=-ose | |
1441 | ;; | |
1442 | -xenix) | |
1443 | os=-xenix | |
1444 | ;; | |
1445 | -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) | |
1446 | os=-mint | |
1447 | ;; | |
1448 | -aros*) | |
1449 | os=-aros | |
1450 | ;; | |
1451 | -kaos*) | |
1452 | os=-kaos | |
1453 | ;; | |
1454 | -zvmoe) | |
1455 | os=-zvmoe | |
1456 | ;; | |
1457 | -dicos*) | |
1458 | os=-dicos | |
1459 | ;; | |
1460 | -nacl*) | |
1461 | ;; | |
1462 | -none) | |
1463 | ;; | |
1464 | *) | |
1465 | # Get rid of the `-' at the beginning of $os. | |
1466 | os=`echo $os | sed 's/[^-]*-//'` | |
1467 | echo Invalid configuration \`$1\': system \`$os\' not recognized 1>&2 | |
1468 | exit 1 | |
1469 | ;; | |
1470 | esac | |
1471 | else | |
1472 | ||
1473 | # Here we handle the default operating systems that come with various machines. | |
1474 | # The value should be what the vendor currently ships out the door with their | |
1475 | # machine or put another way, the most popular os provided with the machine. | |
1476 | ||
1477 | # Note that if you're going to try to match "-MANUFACTURER" here (say, | |
1478 | # "-sun"), then you have to tell the case statement up towards the top | |
1479 | # that MANUFACTURER isn't an operating system. Otherwise, code above | |
1480 | # will signal an error saying that MANUFACTURER isn't an operating | |
1481 | # system, and we'll never get to this point. | |
1482 | ||
1483 | case $basic_machine in | |
1484 | score-*) | |
1485 | os=-elf | |
1486 | ;; | |
1487 | spu-*) | |
1488 | os=-elf | |
1489 | ;; | |
1490 | *-acorn) | |
1491 | os=-riscix1.2 | |
1492 | ;; | |
1493 | arm*-rebel) | |
1494 | os=-linux | |
1495 | ;; | |
1496 | arm*-semi) | |
1497 | os=-aout | |
1498 | ;; | |
1499 | c4x-* | tic4x-*) | |
1500 | os=-coff | |
1501 | ;; | |
1502 | tic54x-*) | |
1503 | os=-coff | |
1504 | ;; | |
1505 | tic55x-*) | |
1506 | os=-coff | |
1507 | ;; | |
1508 | tic6x-*) | |
1509 | os=-coff | |
1510 | ;; | |
1511 | # This must come before the *-dec entry. | |
1512 | pdp10-*) | |
1513 | os=-tops20 | |
1514 | ;; | |
1515 | pdp11-*) | |
1516 | os=-none | |
1517 | ;; | |
1518 | *-dec | vax-*) | |
1519 | os=-ultrix4.2 | |
1520 | ;; | |
1521 | m68*-apollo) | |
1522 | os=-domain | |
1523 | ;; | |
1524 | i386-sun) | |
1525 | os=-sunos4.0.2 | |
1526 | ;; | |
1527 | m68000-sun) | |
1528 | os=-sunos3 | |
1529 | # This also exists in the configure program, but was not the | |
1530 | # default. | |
1531 | # os=-sunos4 | |
1532 | ;; | |
1533 | m68*-cisco) | |
1534 | os=-aout | |
1535 | ;; | |
1536 | mep-*) | |
1537 | os=-elf | |
1538 | ;; | |
1539 | mips*-cisco) | |
1540 | os=-elf | |
1541 | ;; | |
1542 | mips*-*) | |
1543 | os=-elf | |
1544 | ;; | |
1545 | or32-*) | |
1546 | os=-coff | |
1547 | ;; | |
1548 | *-tti) # must be before sparc entry or we get the wrong os. | |
1549 | os=-sysv3 | |
1550 | ;; | |
1551 | sparc-* | *-sun) | |
1552 | os=-sunos4.1.1 | |
1553 | ;; | |
1554 | *-be) | |
1555 | os=-beos | |
1556 | ;; | |
1557 | *-haiku) | |
1558 | os=-haiku | |
1559 | ;; | |
1560 | *-ibm) | |
1561 | os=-aix | |
1562 | ;; | |
1563 | *-knuth) | |
1564 | os=-mmixware | |
1565 | ;; | |
1566 | *-wec) | |
1567 | os=-proelf | |
1568 | ;; | |
1569 | *-winbond) | |
1570 | os=-proelf | |
1571 | ;; | |
1572 | *-oki) | |
1573 | os=-proelf | |
1574 | ;; | |
1575 | *-hp) | |
1576 | os=-hpux | |
1577 | ;; | |
1578 | *-hitachi) | |
1579 | os=-hiux | |
1580 | ;; | |
1581 | i860-* | *-att | *-ncr | *-altos | *-motorola | *-convergent) | |
1582 | os=-sysv | |
1583 | ;; | |
1584 | *-cbm) | |
1585 | os=-amigaos | |
1586 | ;; | |
1587 | *-dg) | |
1588 | os=-dgux | |
1589 | ;; | |
1590 | *-dolphin) | |
1591 | os=-sysv3 | |
1592 | ;; | |
1593 | m68k-ccur) | |
1594 | os=-rtu | |
1595 | ;; | |
1596 | m88k-omron*) | |
1597 | os=-luna | |
1598 | ;; | |
1599 | *-next ) | |
1600 | os=-nextstep | |
1601 | ;; | |
1602 | *-sequent) | |
1603 | os=-ptx | |
1604 | ;; | |
1605 | *-crds) | |
1606 | os=-unos | |
1607 | ;; | |
1608 | *-ns) | |
1609 | os=-genix | |
1610 | ;; | |
1611 | i370-*) | |
1612 | os=-mvs | |
1613 | ;; | |
1614 | *-next) | |
1615 | os=-nextstep3 | |
1616 | ;; | |
1617 | *-gould) | |
1618 | os=-sysv | |
1619 | ;; | |
1620 | *-highlevel) | |
1621 | os=-bsd | |
1622 | ;; | |
1623 | *-encore) | |
1624 | os=-bsd | |
1625 | ;; | |
1626 | *-sgi) | |
1627 | os=-irix | |
1628 | ;; | |
1629 | *-siemens) | |
1630 | os=-sysv4 | |
1631 | ;; | |
1632 | *-masscomp) | |
1633 | os=-rtu | |
1634 | ;; | |
1635 | f30[01]-fujitsu | f700-fujitsu) | |
1636 | os=-uxpv | |
1637 | ;; | |
1638 | *-rom68k) | |
1639 | os=-coff | |
1640 | ;; | |
1641 | *-*bug) | |
1642 | os=-coff | |
1643 | ;; | |
1644 | *-apple) | |
1645 | os=-macos | |
1646 | ;; | |
1647 | *-atari*) | |
1648 | os=-mint | |
1649 | ;; | |
1650 | *) | |
1651 | os=-none | |
1652 | ;; | |
1653 | esac | |
1654 | fi | |
1655 | ||
1656 | # Here we handle the case where we know the os, and the CPU type, but not the | |
1657 | # manufacturer. We pick the logical manufacturer. | |
1658 | vendor=unknown | |
1659 | case $basic_machine in | |
1660 | *-unknown) | |
1661 | case $os in | |
1662 | -riscix*) | |
1663 | vendor=acorn | |
1664 | ;; | |
1665 | -sunos*) | |
1666 | vendor=sun | |
1667 | ;; | |
1668 | -cnk*|-aix*) | |
1669 | vendor=ibm | |
1670 | ;; | |
1671 | -beos*) | |
1672 | vendor=be | |
1673 | ;; | |
1674 | -hpux*) | |
1675 | vendor=hp | |
1676 | ;; | |
1677 | -mpeix*) | |
1678 | vendor=hp | |
1679 | ;; | |
1680 | -hiux*) | |
1681 | vendor=hitachi | |
1682 | ;; | |
1683 | -unos*) | |
1684 | vendor=crds | |
1685 | ;; | |
1686 | -dgux*) | |
1687 | vendor=dg | |
1688 | ;; | |
1689 | -luna*) | |
1690 | vendor=omron | |
1691 | ;; | |
1692 | -genix*) | |
1693 | vendor=ns | |
1694 | ;; | |
1695 | -mvs* | -opened*) | |
1696 | vendor=ibm | |
1697 | ;; | |
1698 | -os400*) | |
1699 | vendor=ibm | |
1700 | ;; | |
1701 | -ptx*) | |
1702 | vendor=sequent | |
1703 | ;; | |
1704 | -tpf*) | |
1705 | vendor=ibm | |
1706 | ;; | |
1707 | -vxsim* | -vxworks* | -windiss*) | |
1708 | vendor=wrs | |
1709 | ;; | |
1710 | -aux*) | |
1711 | vendor=apple | |
1712 | ;; | |
1713 | -hms*) | |
1714 | vendor=hitachi | |
1715 | ;; | |
1716 | -mpw* | -macos*) | |
1717 | vendor=apple | |
1718 | ;; | |
1719 | -*mint | -mint[0-9]* | -*MiNT | -MiNT[0-9]*) | |
1720 | vendor=atari | |
1721 | ;; | |
1722 | -vos*) | |
1723 | vendor=stratus | |
1724 | ;; | |
1725 | esac | |
1726 | basic_machine=`echo $basic_machine | sed "s/unknown/$vendor/"` | |
1727 | ;; | |
1728 | esac | |
1729 | ||
1730 | echo $basic_machine$os | |
1731 | exit | |
1732 | ||
1733 | # Local variables: | |
1734 | # eval: (add-hook 'write-file-hooks 'time-stamp) | |
1735 | # time-stamp-start: "timestamp='" | |
1736 | # time-stamp-format: "%:y-%02m-%02d" | |
1737 | # time-stamp-end: "'" | |
1738 | # End: |
0 | #! /bin/sh | |
1 | # Guess values for system-dependent variables and create Makefiles. | |
2 | # Generated by GNU Autoconf 2.68 for rendercheck 1.4. | |
3 | # | |
4 | # Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>. | |
5 | # | |
6 | # | |
7 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, | |
8 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software | |
9 | # Foundation, Inc. | |
10 | # | |
11 | # | |
12 | # This configure script is free software; the Free Software Foundation | |
13 | # gives unlimited permission to copy, distribute and modify it. | |
14 | ## -------------------- ## | |
15 | ## M4sh Initialization. ## | |
16 | ## -------------------- ## | |
17 | ||
18 | # Be more Bourne compatible | |
19 | DUALCASE=1; export DUALCASE # for MKS sh | |
20 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : | |
21 | emulate sh | |
22 | NULLCMD=: | |
23 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which | |
24 | # is contrary to our usage. Disable this feature. | |
25 | alias -g '${1+"$@"}'='"$@"' | |
26 | setopt NO_GLOB_SUBST | |
27 | else | |
28 | case `(set -o) 2>/dev/null` in #( | |
29 | *posix*) : | |
30 | set -o posix ;; #( | |
31 | *) : | |
32 | ;; | |
33 | esac | |
34 | fi | |
35 | ||
36 | ||
37 | as_nl=' | |
38 | ' | |
39 | export as_nl | |
40 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
41 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
42 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
43 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
44 | # Prefer a ksh shell builtin over an external printf program on Solaris, | |
45 | # but without wasting forks for bash or zsh. | |
46 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
47 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
48 | as_echo='print -r --' | |
49 | as_echo_n='print -rn --' | |
50 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
51 | as_echo='printf %s\n' | |
52 | as_echo_n='printf %s' | |
53 | else | |
54 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
55 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
56 | as_echo_n='/usr/ucb/echo -n' | |
57 | else | |
58 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
59 | as_echo_n_body='eval | |
60 | arg=$1; | |
61 | case $arg in #( | |
62 | *"$as_nl"*) | |
63 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
64 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
65 | esac; | |
66 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
67 | ' | |
68 | export as_echo_n_body | |
69 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
70 | fi | |
71 | export as_echo_body | |
72 | as_echo='sh -c $as_echo_body as_echo' | |
73 | fi | |
74 | ||
75 | # The user is always right. | |
76 | if test "${PATH_SEPARATOR+set}" != set; then | |
77 | PATH_SEPARATOR=: | |
78 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
79 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
80 | PATH_SEPARATOR=';' | |
81 | } | |
82 | fi | |
83 | ||
84 | ||
85 | # IFS | |
86 | # We need space, tab and new line, in precisely that order. Quoting is | |
87 | # there to prevent editors from complaining about space-tab. | |
88 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
89 | # splitting by setting IFS to empty value.) | |
90 | IFS=" "" $as_nl" | |
91 | ||
92 | # Find who we are. Look in the path if we contain no directory separator. | |
93 | as_myself= | |
94 | case $0 in #(( | |
95 | *[\\/]* ) as_myself=$0 ;; | |
96 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
97 | for as_dir in $PATH | |
98 | do | |
99 | IFS=$as_save_IFS | |
100 | test -z "$as_dir" && as_dir=. | |
101 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
102 | done | |
103 | IFS=$as_save_IFS | |
104 | ||
105 | ;; | |
106 | esac | |
107 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
108 | # in which case we are not to be found in the path. | |
109 | if test "x$as_myself" = x; then | |
110 | as_myself=$0 | |
111 | fi | |
112 | if test ! -f "$as_myself"; then | |
113 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
114 | exit 1 | |
115 | fi | |
116 | ||
117 | # Unset variables that we do not need and which cause bugs (e.g. in | |
118 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
119 | # suppresses any "Segmentation fault" message there. '((' could | |
120 | # trigger a bug in pdksh 5.2.14. | |
121 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
122 | do eval test x\${$as_var+set} = xset \ | |
123 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
124 | done | |
125 | PS1='$ ' | |
126 | PS2='> ' | |
127 | PS4='+ ' | |
128 | ||
129 | # NLS nuisances. | |
130 | LC_ALL=C | |
131 | export LC_ALL | |
132 | LANGUAGE=C | |
133 | export LANGUAGE | |
134 | ||
135 | # CDPATH. | |
136 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
137 | ||
138 | if test "x$CONFIG_SHELL" = x; then | |
139 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : | |
140 | emulate sh | |
141 | NULLCMD=: | |
142 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which | |
143 | # is contrary to our usage. Disable this feature. | |
144 | alias -g '\${1+\"\$@\"}'='\"\$@\"' | |
145 | setopt NO_GLOB_SUBST | |
146 | else | |
147 | case \`(set -o) 2>/dev/null\` in #( | |
148 | *posix*) : | |
149 | set -o posix ;; #( | |
150 | *) : | |
151 | ;; | |
152 | esac | |
153 | fi | |
154 | " | |
155 | as_required="as_fn_return () { (exit \$1); } | |
156 | as_fn_success () { as_fn_return 0; } | |
157 | as_fn_failure () { as_fn_return 1; } | |
158 | as_fn_ret_success () { return 0; } | |
159 | as_fn_ret_failure () { return 1; } | |
160 | ||
161 | exitcode=0 | |
162 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } | |
163 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } | |
164 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } | |
165 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } | |
166 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : | |
167 | ||
168 | else | |
169 | exitcode=1; echo positional parameters were not saved. | |
170 | fi | |
171 | test x\$exitcode = x0 || exit 1" | |
172 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO | |
173 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO | |
174 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && | |
175 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 | |
176 | test \$(( 1 + 1 )) = 2 || exit 1" | |
177 | if (eval "$as_required") 2>/dev/null; then : | |
178 | as_have_required=yes | |
179 | else | |
180 | as_have_required=no | |
181 | fi | |
182 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : | |
183 | ||
184 | else | |
185 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
186 | as_found=false | |
187 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH | |
188 | do | |
189 | IFS=$as_save_IFS | |
190 | test -z "$as_dir" && as_dir=. | |
191 | as_found=: | |
192 | case $as_dir in #( | |
193 | /*) | |
194 | for as_base in sh bash ksh sh5; do | |
195 | # Try only shells that exist, to save several forks. | |
196 | as_shell=$as_dir/$as_base | |
197 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && | |
198 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
199 | CONFIG_SHELL=$as_shell as_have_required=yes | |
200 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
201 | break 2 | |
202 | fi | |
203 | fi | |
204 | done;; | |
205 | esac | |
206 | as_found=false | |
207 | done | |
208 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && | |
209 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : | |
210 | CONFIG_SHELL=$SHELL as_have_required=yes | |
211 | fi; } | |
212 | IFS=$as_save_IFS | |
213 | ||
214 | ||
215 | if test "x$CONFIG_SHELL" != x; then : | |
216 | # We cannot yet assume a decent shell, so we have to provide a | |
217 | # neutralization value for shells without unset; and this also | |
218 | # works around shells that cannot unset nonexistent variables. | |
219 | # Preserve -v and -x to the replacement shell. | |
220 | BASH_ENV=/dev/null | |
221 | ENV=/dev/null | |
222 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
223 | export CONFIG_SHELL | |
224 | case $- in # (((( | |
225 | *v*x* | *x*v* ) as_opts=-vx ;; | |
226 | *v* ) as_opts=-v ;; | |
227 | *x* ) as_opts=-x ;; | |
228 | * ) as_opts= ;; | |
229 | esac | |
230 | exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} | |
231 | fi | |
232 | ||
233 | if test x$as_have_required = xno; then : | |
234 | $as_echo "$0: This script requires a shell more modern than all" | |
235 | $as_echo "$0: the shells that I found on your system." | |
236 | if test x${ZSH_VERSION+set} = xset ; then | |
237 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" | |
238 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." | |
239 | else | |
240 | $as_echo "$0: Please tell bug-autoconf@gnu.org and | |
241 | $0: https://bugs.freedesktop.org/enter_bug.cgi?product=xorg | |
242 | $0: about your system, including any error possibly output | |
243 | $0: before this message. Then install a modern shell, or | |
244 | $0: manually run the script under such a shell if you do | |
245 | $0: have one." | |
246 | fi | |
247 | exit 1 | |
248 | fi | |
249 | fi | |
250 | fi | |
251 | SHELL=${CONFIG_SHELL-/bin/sh} | |
252 | export SHELL | |
253 | # Unset more variables known to interfere with behavior of common tools. | |
254 | CLICOLOR_FORCE= GREP_OPTIONS= | |
255 | unset CLICOLOR_FORCE GREP_OPTIONS | |
256 | ||
257 | ## --------------------- ## | |
258 | ## M4sh Shell Functions. ## | |
259 | ## --------------------- ## | |
260 | # as_fn_unset VAR | |
261 | # --------------- | |
262 | # Portably unset VAR. | |
263 | as_fn_unset () | |
264 | { | |
265 | { eval $1=; unset $1;} | |
266 | } | |
267 | as_unset=as_fn_unset | |
268 | ||
269 | # as_fn_set_status STATUS | |
270 | # ----------------------- | |
271 | # Set $? to STATUS, without forking. | |
272 | as_fn_set_status () | |
273 | { | |
274 | return $1 | |
275 | } # as_fn_set_status | |
276 | ||
277 | # as_fn_exit STATUS | |
278 | # ----------------- | |
279 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
280 | as_fn_exit () | |
281 | { | |
282 | set +e | |
283 | as_fn_set_status $1 | |
284 | exit $1 | |
285 | } # as_fn_exit | |
286 | ||
287 | # as_fn_mkdir_p | |
288 | # ------------- | |
289 | # Create "$as_dir" as a directory, including parents if necessary. | |
290 | as_fn_mkdir_p () | |
291 | { | |
292 | ||
293 | case $as_dir in #( | |
294 | -*) as_dir=./$as_dir;; | |
295 | esac | |
296 | test -d "$as_dir" || eval $as_mkdir_p || { | |
297 | as_dirs= | |
298 | while :; do | |
299 | case $as_dir in #( | |
300 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
301 | *) as_qdir=$as_dir;; | |
302 | esac | |
303 | as_dirs="'$as_qdir' $as_dirs" | |
304 | as_dir=`$as_dirname -- "$as_dir" || | |
305 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
306 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
307 | X"$as_dir" : 'X\(//\)$' \| \ | |
308 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
309 | $as_echo X"$as_dir" | | |
310 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
311 | s//\1/ | |
312 | q | |
313 | } | |
314 | /^X\(\/\/\)[^/].*/{ | |
315 | s//\1/ | |
316 | q | |
317 | } | |
318 | /^X\(\/\/\)$/{ | |
319 | s//\1/ | |
320 | q | |
321 | } | |
322 | /^X\(\/\).*/{ | |
323 | s//\1/ | |
324 | q | |
325 | } | |
326 | s/.*/./; q'` | |
327 | test -d "$as_dir" && break | |
328 | done | |
329 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
330 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" | |
331 | ||
332 | ||
333 | } # as_fn_mkdir_p | |
334 | # as_fn_append VAR VALUE | |
335 | # ---------------------- | |
336 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
337 | # advantage of any shell optimizations that allow amortized linear growth over | |
338 | # repeated appends, instead of the typical quadratic growth present in naive | |
339 | # implementations. | |
340 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
341 | eval 'as_fn_append () | |
342 | { | |
343 | eval $1+=\$2 | |
344 | }' | |
345 | else | |
346 | as_fn_append () | |
347 | { | |
348 | eval $1=\$$1\$2 | |
349 | } | |
350 | fi # as_fn_append | |
351 | ||
352 | # as_fn_arith ARG... | |
353 | # ------------------ | |
354 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
355 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
356 | # must be portable across $(()) and expr. | |
357 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
358 | eval 'as_fn_arith () | |
359 | { | |
360 | as_val=$(( $* )) | |
361 | }' | |
362 | else | |
363 | as_fn_arith () | |
364 | { | |
365 | as_val=`expr "$@" || test $? -eq 1` | |
366 | } | |
367 | fi # as_fn_arith | |
368 | ||
369 | ||
370 | # as_fn_error STATUS ERROR [LINENO LOG_FD] | |
371 | # ---------------------------------------- | |
372 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
373 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
374 | # script with STATUS, using 1 if that was 0. | |
375 | as_fn_error () | |
376 | { | |
377 | as_status=$1; test $as_status -eq 0 && as_status=1 | |
378 | if test "$4"; then | |
379 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
380 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
381 | fi | |
382 | $as_echo "$as_me: error: $2" >&2 | |
383 | as_fn_exit $as_status | |
384 | } # as_fn_error | |
385 | ||
386 | if expr a : '\(a\)' >/dev/null 2>&1 && | |
387 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
388 | as_expr=expr | |
389 | else | |
390 | as_expr=false | |
391 | fi | |
392 | ||
393 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then | |
394 | as_basename=basename | |
395 | else | |
396 | as_basename=false | |
397 | fi | |
398 | ||
399 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then | |
400 | as_dirname=dirname | |
401 | else | |
402 | as_dirname=false | |
403 | fi | |
404 | ||
405 | as_me=`$as_basename -- "$0" || | |
406 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ | |
407 | X"$0" : 'X\(//\)$' \| \ | |
408 | X"$0" : 'X\(/\)' \| . 2>/dev/null || | |
409 | $as_echo X/"$0" | | |
410 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
411 | s//\1/ | |
412 | q | |
413 | } | |
414 | /^X\/\(\/\/\)$/{ | |
415 | s//\1/ | |
416 | q | |
417 | } | |
418 | /^X\/\(\/\).*/{ | |
419 | s//\1/ | |
420 | q | |
421 | } | |
422 | s/.*/./; q'` | |
423 | ||
424 | # Avoid depending upon Character Ranges. | |
425 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
426 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
427 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
428 | as_cr_digits='0123456789' | |
429 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
430 | ||
431 | ||
432 | as_lineno_1=$LINENO as_lineno_1a=$LINENO | |
433 | as_lineno_2=$LINENO as_lineno_2a=$LINENO | |
434 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && | |
435 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { | |
436 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) | |
437 | sed -n ' | |
438 | p | |
439 | /[$]LINENO/= | |
440 | ' <$as_myself | | |
441 | sed ' | |
442 | s/[$]LINENO.*/&-/ | |
443 | t lineno | |
444 | b | |
445 | :lineno | |
446 | N | |
447 | :loop | |
448 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ | |
449 | t loop | |
450 | s/-\n.*// | |
451 | ' >$as_me.lineno && | |
452 | chmod +x "$as_me.lineno" || | |
453 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } | |
454 | ||
455 | # Don't try to exec as it changes $[0], causing all sort of problems | |
456 | # (the dirname of $[0] is not the place where we might find the | |
457 | # original and so on. Autoconf is especially sensitive to this). | |
458 | . "./$as_me.lineno" | |
459 | # Exit status is that of the last command. | |
460 | exit | |
461 | } | |
462 | ||
463 | ECHO_C= ECHO_N= ECHO_T= | |
464 | case `echo -n x` in #((((( | |
465 | -n*) | |
466 | case `echo 'xy\c'` in | |
467 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
468 | xy) ECHO_C='\c';; | |
469 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
470 | ECHO_T=' ';; | |
471 | esac;; | |
472 | *) | |
473 | ECHO_N='-n';; | |
474 | esac | |
475 | ||
476 | rm -f conf$$ conf$$.exe conf$$.file | |
477 | if test -d conf$$.dir; then | |
478 | rm -f conf$$.dir/conf$$.file | |
479 | else | |
480 | rm -f conf$$.dir | |
481 | mkdir conf$$.dir 2>/dev/null | |
482 | fi | |
483 | if (echo >conf$$.file) 2>/dev/null; then | |
484 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
485 | as_ln_s='ln -s' | |
486 | # ... but there are two gotchas: | |
487 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
488 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
489 | # In both cases, we have to default to `cp -p'. | |
490 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
491 | as_ln_s='cp -p' | |
492 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
493 | as_ln_s=ln | |
494 | else | |
495 | as_ln_s='cp -p' | |
496 | fi | |
497 | else | |
498 | as_ln_s='cp -p' | |
499 | fi | |
500 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file | |
501 | rmdir conf$$.dir 2>/dev/null | |
502 | ||
503 | if mkdir -p . 2>/dev/null; then | |
504 | as_mkdir_p='mkdir -p "$as_dir"' | |
505 | else | |
506 | test -d ./-p && rmdir ./-p | |
507 | as_mkdir_p=false | |
508 | fi | |
509 | ||
510 | if test -x / >/dev/null 2>&1; then | |
511 | as_test_x='test -x' | |
512 | else | |
513 | if ls -dL / >/dev/null 2>&1; then | |
514 | as_ls_L_option=L | |
515 | else | |
516 | as_ls_L_option= | |
517 | fi | |
518 | as_test_x=' | |
519 | eval sh -c '\'' | |
520 | if test -d "$1"; then | |
521 | test -d "$1/."; | |
522 | else | |
523 | case $1 in #( | |
524 | -*)set "./$1";; | |
525 | esac; | |
526 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( | |
527 | ???[sx]*):;;*)false;;esac;fi | |
528 | '\'' sh | |
529 | ' | |
530 | fi | |
531 | as_executable_p=$as_test_x | |
532 | ||
533 | # Sed expression to map a string onto a valid CPP name. | |
534 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" | |
535 | ||
536 | # Sed expression to map a string onto a valid variable name. | |
537 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" | |
538 | ||
539 | ||
540 | test -n "$DJDIR" || exec 7<&0 </dev/null | |
541 | exec 6>&1 | |
542 | ||
543 | # Name of the host. | |
544 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, | |
545 | # so uname gets run too. | |
546 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` | |
547 | ||
548 | # | |
549 | # Initializations. | |
550 | # | |
551 | ac_default_prefix=/usr/local | |
552 | ac_clean_files= | |
553 | ac_config_libobj_dir=. | |
554 | LIBOBJS= | |
555 | cross_compiling=no | |
556 | subdirs= | |
557 | MFLAGS= | |
558 | MAKEFLAGS= | |
559 | ||
560 | # Identity of this package. | |
561 | PACKAGE_NAME='rendercheck' | |
562 | PACKAGE_TARNAME='rendercheck' | |
563 | PACKAGE_VERSION='1.4' | |
564 | PACKAGE_STRING='rendercheck 1.4' | |
565 | PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg' | |
566 | PACKAGE_URL='' | |
567 | ||
568 | ac_unique_file="Makefile.am" | |
569 | # Factoring default headers for most tests. | |
570 | ac_includes_default="\ | |
571 | #include <stdio.h> | |
572 | #ifdef HAVE_SYS_TYPES_H | |
573 | # include <sys/types.h> | |
574 | #endif | |
575 | #ifdef HAVE_SYS_STAT_H | |
576 | # include <sys/stat.h> | |
577 | #endif | |
578 | #ifdef STDC_HEADERS | |
579 | # include <stdlib.h> | |
580 | # include <stddef.h> | |
581 | #else | |
582 | # ifdef HAVE_STDLIB_H | |
583 | # include <stdlib.h> | |
584 | # endif | |
585 | #endif | |
586 | #ifdef HAVE_STRING_H | |
587 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | |
588 | # include <memory.h> | |
589 | # endif | |
590 | # include <string.h> | |
591 | #endif | |
592 | #ifdef HAVE_STRINGS_H | |
593 | # include <strings.h> | |
594 | #endif | |
595 | #ifdef HAVE_INTTYPES_H | |
596 | # include <inttypes.h> | |
597 | #endif | |
598 | #ifdef HAVE_STDINT_H | |
599 | # include <stdint.h> | |
600 | #endif | |
601 | #ifdef HAVE_UNISTD_H | |
602 | # include <unistd.h> | |
603 | #endif" | |
604 | ||
605 | ac_subst_vars='am__EXEEXT_FALSE | |
606 | am__EXEEXT_TRUE | |
607 | LTLIBOBJS | |
608 | LIBOBJS | |
609 | RC_LIBS | |
610 | RC_CFLAGS | |
611 | AM_BACKSLASH | |
612 | AM_DEFAULT_VERBOSITY | |
613 | MAN_SUBSTS | |
614 | XORG_MAN_PAGE | |
615 | ADMIN_MAN_DIR | |
616 | DRIVER_MAN_DIR | |
617 | MISC_MAN_DIR | |
618 | FILE_MAN_DIR | |
619 | LIB_MAN_DIR | |
620 | APP_MAN_DIR | |
621 | ADMIN_MAN_SUFFIX | |
622 | DRIVER_MAN_SUFFIX | |
623 | MISC_MAN_SUFFIX | |
624 | FILE_MAN_SUFFIX | |
625 | LIB_MAN_SUFFIX | |
626 | APP_MAN_SUFFIX | |
627 | SED | |
628 | host_os | |
629 | host_vendor | |
630 | host_cpu | |
631 | host | |
632 | build_os | |
633 | build_vendor | |
634 | build_cpu | |
635 | build | |
636 | INSTALL_CMD | |
637 | PKG_CONFIG | |
638 | CHANGELOG_CMD | |
639 | CWARNFLAGS | |
640 | EGREP | |
641 | GREP | |
642 | CPP | |
643 | am__fastdepCC_FALSE | |
644 | am__fastdepCC_TRUE | |
645 | CCDEPMODE | |
646 | AMDEPBACKSLASH | |
647 | AMDEP_FALSE | |
648 | AMDEP_TRUE | |
649 | am__quote | |
650 | am__include | |
651 | DEPDIR | |
652 | OBJEXT | |
653 | EXEEXT | |
654 | ac_ct_CC | |
655 | CPPFLAGS | |
656 | LDFLAGS | |
657 | CFLAGS | |
658 | CC | |
659 | MAINT | |
660 | MAINTAINER_MODE_FALSE | |
661 | MAINTAINER_MODE_TRUE | |
662 | am__untar | |
663 | am__tar | |
664 | AMTAR | |
665 | am__leading_dot | |
666 | SET_MAKE | |
667 | AWK | |
668 | mkdir_p | |
669 | MKDIR_P | |
670 | INSTALL_STRIP_PROGRAM | |
671 | STRIP | |
672 | install_sh | |
673 | MAKEINFO | |
674 | AUTOHEADER | |
675 | AUTOMAKE | |
676 | AUTOCONF | |
677 | ACLOCAL | |
678 | VERSION | |
679 | PACKAGE | |
680 | CYGPATH_W | |
681 | am__isrc | |
682 | INSTALL_DATA | |
683 | INSTALL_SCRIPT | |
684 | INSTALL_PROGRAM | |
685 | target_alias | |
686 | host_alias | |
687 | build_alias | |
688 | LIBS | |
689 | ECHO_T | |
690 | ECHO_N | |
691 | ECHO_C | |
692 | DEFS | |
693 | mandir | |
694 | localedir | |
695 | libdir | |
696 | psdir | |
697 | pdfdir | |
698 | dvidir | |
699 | htmldir | |
700 | infodir | |
701 | docdir | |
702 | oldincludedir | |
703 | includedir | |
704 | localstatedir | |
705 | sharedstatedir | |
706 | sysconfdir | |
707 | datadir | |
708 | datarootdir | |
709 | libexecdir | |
710 | sbindir | |
711 | bindir | |
712 | program_transform_name | |
713 | prefix | |
714 | exec_prefix | |
715 | PACKAGE_URL | |
716 | PACKAGE_BUGREPORT | |
717 | PACKAGE_STRING | |
718 | PACKAGE_VERSION | |
719 | PACKAGE_TARNAME | |
720 | PACKAGE_NAME | |
721 | PATH_SEPARATOR | |
722 | SHELL' | |
723 | ac_subst_files='' | |
724 | ac_user_opts=' | |
725 | enable_option_checking | |
726 | enable_maintainer_mode | |
727 | enable_dependency_tracking | |
728 | enable_strict_compilation | |
729 | enable_silent_rules | |
730 | ' | |
731 | ac_precious_vars='build_alias | |
732 | host_alias | |
733 | target_alias | |
734 | CC | |
735 | CFLAGS | |
736 | LDFLAGS | |
737 | LIBS | |
738 | CPPFLAGS | |
739 | CPP | |
740 | PKG_CONFIG | |
741 | RC_CFLAGS | |
742 | RC_LIBS' | |
743 | ||
744 | ||
745 | # Initialize some variables set by options. | |
746 | ac_init_help= | |
747 | ac_init_version=false | |
748 | ac_unrecognized_opts= | |
749 | ac_unrecognized_sep= | |
750 | # The variables have the same names as the options, with | |
751 | # dashes changed to underlines. | |
752 | cache_file=/dev/null | |
753 | exec_prefix=NONE | |
754 | no_create= | |
755 | no_recursion= | |
756 | prefix=NONE | |
757 | program_prefix=NONE | |
758 | program_suffix=NONE | |
759 | program_transform_name=s,x,x, | |
760 | silent= | |
761 | site= | |
762 | srcdir= | |
763 | verbose= | |
764 | x_includes=NONE | |
765 | x_libraries=NONE | |
766 | ||
767 | # Installation directory options. | |
768 | # These are left unexpanded so users can "make install exec_prefix=/foo" | |
769 | # and all the variables that are supposed to be based on exec_prefix | |
770 | # by default will actually change. | |
771 | # Use braces instead of parens because sh, perl, etc. also accept them. | |
772 | # (The list follows the same order as the GNU Coding Standards.) | |
773 | bindir='${exec_prefix}/bin' | |
774 | sbindir='${exec_prefix}/sbin' | |
775 | libexecdir='${exec_prefix}/libexec' | |
776 | datarootdir='${prefix}/share' | |
777 | datadir='${datarootdir}' | |
778 | sysconfdir='${prefix}/etc' | |
779 | sharedstatedir='${prefix}/com' | |
780 | localstatedir='${prefix}/var' | |
781 | includedir='${prefix}/include' | |
782 | oldincludedir='/usr/include' | |
783 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' | |
784 | infodir='${datarootdir}/info' | |
785 | htmldir='${docdir}' | |
786 | dvidir='${docdir}' | |
787 | pdfdir='${docdir}' | |
788 | psdir='${docdir}' | |
789 | libdir='${exec_prefix}/lib' | |
790 | localedir='${datarootdir}/locale' | |
791 | mandir='${datarootdir}/man' | |
792 | ||
793 | ac_prev= | |
794 | ac_dashdash= | |
795 | for ac_option | |
796 | do | |
797 | # If the previous option needs an argument, assign it. | |
798 | if test -n "$ac_prev"; then | |
799 | eval $ac_prev=\$ac_option | |
800 | ac_prev= | |
801 | continue | |
802 | fi | |
803 | ||
804 | case $ac_option in | |
805 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; | |
806 | *=) ac_optarg= ;; | |
807 | *) ac_optarg=yes ;; | |
808 | esac | |
809 | ||
810 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
811 | ||
812 | case $ac_dashdash$ac_option in | |
813 | --) | |
814 | ac_dashdash=yes ;; | |
815 | ||
816 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
817 | ac_prev=bindir ;; | |
818 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
819 | bindir=$ac_optarg ;; | |
820 | ||
821 | -build | --build | --buil | --bui | --bu) | |
822 | ac_prev=build_alias ;; | |
823 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) | |
824 | build_alias=$ac_optarg ;; | |
825 | ||
826 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
827 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
828 | ac_prev=cache_file ;; | |
829 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
830 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
831 | cache_file=$ac_optarg ;; | |
832 | ||
833 | --config-cache | -C) | |
834 | cache_file=config.cache ;; | |
835 | ||
836 | -datadir | --datadir | --datadi | --datad) | |
837 | ac_prev=datadir ;; | |
838 | -datadir=* | --datadir=* | --datadi=* | --datad=*) | |
839 | datadir=$ac_optarg ;; | |
840 | ||
841 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ | |
842 | | --dataroo | --dataro | --datar) | |
843 | ac_prev=datarootdir ;; | |
844 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | |
845 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) | |
846 | datarootdir=$ac_optarg ;; | |
847 | ||
848 | -disable-* | --disable-*) | |
849 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` | |
850 | # Reject names that are not valid shell variable names. | |
851 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
852 | as_fn_error $? "invalid feature name: $ac_useropt" | |
853 | ac_useropt_orig=$ac_useropt | |
854 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
855 | case $ac_user_opts in | |
856 | *" | |
857 | "enable_$ac_useropt" | |
858 | "*) ;; | |
859 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" | |
860 | ac_unrecognized_sep=', ';; | |
861 | esac | |
862 | eval enable_$ac_useropt=no ;; | |
863 | ||
864 | -docdir | --docdir | --docdi | --doc | --do) | |
865 | ac_prev=docdir ;; | |
866 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) | |
867 | docdir=$ac_optarg ;; | |
868 | ||
869 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) | |
870 | ac_prev=dvidir ;; | |
871 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) | |
872 | dvidir=$ac_optarg ;; | |
873 | ||
874 | -enable-* | --enable-*) | |
875 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` | |
876 | # Reject names that are not valid shell variable names. | |
877 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
878 | as_fn_error $? "invalid feature name: $ac_useropt" | |
879 | ac_useropt_orig=$ac_useropt | |
880 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
881 | case $ac_user_opts in | |
882 | *" | |
883 | "enable_$ac_useropt" | |
884 | "*) ;; | |
885 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" | |
886 | ac_unrecognized_sep=', ';; | |
887 | esac | |
888 | eval enable_$ac_useropt=\$ac_optarg ;; | |
889 | ||
890 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
891 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
892 | | --exec | --exe | --ex) | |
893 | ac_prev=exec_prefix ;; | |
894 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
895 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
896 | | --exec=* | --exe=* | --ex=*) | |
897 | exec_prefix=$ac_optarg ;; | |
898 | ||
899 | -gas | --gas | --ga | --g) | |
900 | # Obsolete; use --with-gas. | |
901 | with_gas=yes ;; | |
902 | ||
903 | -help | --help | --hel | --he | -h) | |
904 | ac_init_help=long ;; | |
905 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) | |
906 | ac_init_help=recursive ;; | |
907 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) | |
908 | ac_init_help=short ;; | |
909 | ||
910 | -host | --host | --hos | --ho) | |
911 | ac_prev=host_alias ;; | |
912 | -host=* | --host=* | --hos=* | --ho=*) | |
913 | host_alias=$ac_optarg ;; | |
914 | ||
915 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) | |
916 | ac_prev=htmldir ;; | |
917 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | |
918 | | --ht=*) | |
919 | htmldir=$ac_optarg ;; | |
920 | ||
921 | -includedir | --includedir | --includedi | --included | --include \ | |
922 | | --includ | --inclu | --incl | --inc) | |
923 | ac_prev=includedir ;; | |
924 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
925 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
926 | includedir=$ac_optarg ;; | |
927 | ||
928 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
929 | ac_prev=infodir ;; | |
930 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
931 | infodir=$ac_optarg ;; | |
932 | ||
933 | -libdir | --libdir | --libdi | --libd) | |
934 | ac_prev=libdir ;; | |
935 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
936 | libdir=$ac_optarg ;; | |
937 | ||
938 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
939 | | --libexe | --libex | --libe) | |
940 | ac_prev=libexecdir ;; | |
941 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
942 | | --libexe=* | --libex=* | --libe=*) | |
943 | libexecdir=$ac_optarg ;; | |
944 | ||
945 | -localedir | --localedir | --localedi | --localed | --locale) | |
946 | ac_prev=localedir ;; | |
947 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) | |
948 | localedir=$ac_optarg ;; | |
949 | ||
950 | -localstatedir | --localstatedir | --localstatedi | --localstated \ | |
951 | | --localstate | --localstat | --localsta | --localst | --locals) | |
952 | ac_prev=localstatedir ;; | |
953 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
954 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) | |
955 | localstatedir=$ac_optarg ;; | |
956 | ||
957 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
958 | ac_prev=mandir ;; | |
959 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
960 | mandir=$ac_optarg ;; | |
961 | ||
962 | -nfp | --nfp | --nf) | |
963 | # Obsolete; use --without-fp. | |
964 | with_fp=no ;; | |
965 | ||
966 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
967 | | --no-cr | --no-c | -n) | |
968 | no_create=yes ;; | |
969 | ||
970 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
971 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
972 | no_recursion=yes ;; | |
973 | ||
974 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
975 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
976 | | --oldin | --oldi | --old | --ol | --o) | |
977 | ac_prev=oldincludedir ;; | |
978 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
979 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
980 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
981 | oldincludedir=$ac_optarg ;; | |
982 | ||
983 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
984 | ac_prev=prefix ;; | |
985 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
986 | prefix=$ac_optarg ;; | |
987 | ||
988 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
989 | | --program-pre | --program-pr | --program-p) | |
990 | ac_prev=program_prefix ;; | |
991 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
992 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
993 | program_prefix=$ac_optarg ;; | |
994 | ||
995 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
996 | | --program-suf | --program-su | --program-s) | |
997 | ac_prev=program_suffix ;; | |
998 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
999 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
1000 | program_suffix=$ac_optarg ;; | |
1001 | ||
1002 | -program-transform-name | --program-transform-name \ | |
1003 | | --program-transform-nam | --program-transform-na \ | |
1004 | | --program-transform-n | --program-transform- \ | |
1005 | | --program-transform | --program-transfor \ | |
1006 | | --program-transfo | --program-transf \ | |
1007 | | --program-trans | --program-tran \ | |
1008 | | --progr-tra | --program-tr | --program-t) | |
1009 | ac_prev=program_transform_name ;; | |
1010 | -program-transform-name=* | --program-transform-name=* \ | |
1011 | | --program-transform-nam=* | --program-transform-na=* \ | |
1012 | | --program-transform-n=* | --program-transform-=* \ | |
1013 | | --program-transform=* | --program-transfor=* \ | |
1014 | | --program-transfo=* | --program-transf=* \ | |
1015 | | --program-trans=* | --program-tran=* \ | |
1016 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
1017 | program_transform_name=$ac_optarg ;; | |
1018 | ||
1019 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) | |
1020 | ac_prev=pdfdir ;; | |
1021 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) | |
1022 | pdfdir=$ac_optarg ;; | |
1023 | ||
1024 | -psdir | --psdir | --psdi | --psd | --ps) | |
1025 | ac_prev=psdir ;; | |
1026 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) | |
1027 | psdir=$ac_optarg ;; | |
1028 | ||
1029 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
1030 | | -silent | --silent | --silen | --sile | --sil) | |
1031 | silent=yes ;; | |
1032 | ||
1033 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
1034 | ac_prev=sbindir ;; | |
1035 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
1036 | | --sbi=* | --sb=*) | |
1037 | sbindir=$ac_optarg ;; | |
1038 | ||
1039 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
1040 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
1041 | | --sharedst | --shareds | --shared | --share | --shar \ | |
1042 | | --sha | --sh) | |
1043 | ac_prev=sharedstatedir ;; | |
1044 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
1045 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
1046 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
1047 | | --sha=* | --sh=*) | |
1048 | sharedstatedir=$ac_optarg ;; | |
1049 | ||
1050 | -site | --site | --sit) | |
1051 | ac_prev=site ;; | |
1052 | -site=* | --site=* | --sit=*) | |
1053 | site=$ac_optarg ;; | |
1054 | ||
1055 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
1056 | ac_prev=srcdir ;; | |
1057 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
1058 | srcdir=$ac_optarg ;; | |
1059 | ||
1060 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
1061 | | --syscon | --sysco | --sysc | --sys | --sy) | |
1062 | ac_prev=sysconfdir ;; | |
1063 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
1064 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
1065 | sysconfdir=$ac_optarg ;; | |
1066 | ||
1067 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
1068 | ac_prev=target_alias ;; | |
1069 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) | |
1070 | target_alias=$ac_optarg ;; | |
1071 | ||
1072 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
1073 | verbose=yes ;; | |
1074 | ||
1075 | -version | --version | --versio | --versi | --vers | -V) | |
1076 | ac_init_version=: ;; | |
1077 | ||
1078 | -with-* | --with-*) | |
1079 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` | |
1080 | # Reject names that are not valid shell variable names. | |
1081 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
1082 | as_fn_error $? "invalid package name: $ac_useropt" | |
1083 | ac_useropt_orig=$ac_useropt | |
1084 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1085 | case $ac_user_opts in | |
1086 | *" | |
1087 | "with_$ac_useropt" | |
1088 | "*) ;; | |
1089 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" | |
1090 | ac_unrecognized_sep=', ';; | |
1091 | esac | |
1092 | eval with_$ac_useropt=\$ac_optarg ;; | |
1093 | ||
1094 | -without-* | --without-*) | |
1095 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` | |
1096 | # Reject names that are not valid shell variable names. | |
1097 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && | |
1098 | as_fn_error $? "invalid package name: $ac_useropt" | |
1099 | ac_useropt_orig=$ac_useropt | |
1100 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1101 | case $ac_user_opts in | |
1102 | *" | |
1103 | "with_$ac_useropt" | |
1104 | "*) ;; | |
1105 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" | |
1106 | ac_unrecognized_sep=', ';; | |
1107 | esac | |
1108 | eval with_$ac_useropt=no ;; | |
1109 | ||
1110 | --x) | |
1111 | # Obsolete; use --with-x. | |
1112 | with_x=yes ;; | |
1113 | ||
1114 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
1115 | | --x-incl | --x-inc | --x-in | --x-i) | |
1116 | ac_prev=x_includes ;; | |
1117 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
1118 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
1119 | x_includes=$ac_optarg ;; | |
1120 | ||
1121 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
1122 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
1123 | ac_prev=x_libraries ;; | |
1124 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
1125 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
1126 | x_libraries=$ac_optarg ;; | |
1127 | ||
1128 | -*) as_fn_error $? "unrecognized option: \`$ac_option' | |
1129 | Try \`$0 --help' for more information" | |
1130 | ;; | |
1131 | ||
1132 | *=*) | |
1133 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` | |
1134 | # Reject names that are not valid shell variable names. | |
1135 | case $ac_envvar in #( | |
1136 | '' | [0-9]* | *[!_$as_cr_alnum]* ) | |
1137 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; | |
1138 | esac | |
1139 | eval $ac_envvar=\$ac_optarg | |
1140 | export $ac_envvar ;; | |
1141 | ||
1142 | *) | |
1143 | # FIXME: should be removed in autoconf 3.0. | |
1144 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 | |
1145 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && | |
1146 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 | |
1147 | : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" | |
1148 | ;; | |
1149 | ||
1150 | esac | |
1151 | done | |
1152 | ||
1153 | if test -n "$ac_prev"; then | |
1154 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` | |
1155 | as_fn_error $? "missing argument to $ac_option" | |
1156 | fi | |
1157 | ||
1158 | if test -n "$ac_unrecognized_opts"; then | |
1159 | case $enable_option_checking in | |
1160 | no) ;; | |
1161 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; | |
1162 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; | |
1163 | esac | |
1164 | fi | |
1165 | ||
1166 | # Check all directory arguments for consistency. | |
1167 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ | |
1168 | datadir sysconfdir sharedstatedir localstatedir includedir \ | |
1169 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ | |
1170 | libdir localedir mandir | |
1171 | do | |
1172 | eval ac_val=\$$ac_var | |
1173 | # Remove trailing slashes. | |
1174 | case $ac_val in | |
1175 | */ ) | |
1176 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` | |
1177 | eval $ac_var=\$ac_val;; | |
1178 | esac | |
1179 | # Be sure to have absolute directory names. | |
1180 | case $ac_val in | |
1181 | [\\/$]* | ?:[\\/]* ) continue;; | |
1182 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; | |
1183 | esac | |
1184 | as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" | |
1185 | done | |
1186 | ||
1187 | # There might be people who depend on the old broken behavior: `$host' | |
1188 | # used to hold the argument of --host etc. | |
1189 | # FIXME: To remove some day. | |
1190 | build=$build_alias | |
1191 | host=$host_alias | |
1192 | target=$target_alias | |
1193 | ||
1194 | # FIXME: To remove some day. | |
1195 | if test "x$host_alias" != x; then | |
1196 | if test "x$build_alias" = x; then | |
1197 | cross_compiling=maybe | |
1198 | $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. | |
1199 | If a cross compiler is detected then cross compile mode will be used" >&2 | |
1200 | elif test "x$build_alias" != "x$host_alias"; then | |
1201 | cross_compiling=yes | |
1202 | fi | |
1203 | fi | |
1204 | ||
1205 | ac_tool_prefix= | |
1206 | test -n "$host_alias" && ac_tool_prefix=$host_alias- | |
1207 | ||
1208 | test "$silent" = yes && exec 6>/dev/null | |
1209 | ||
1210 | ||
1211 | ac_pwd=`pwd` && test -n "$ac_pwd" && | |
1212 | ac_ls_di=`ls -di .` && | |
1213 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || | |
1214 | as_fn_error $? "working directory cannot be determined" | |
1215 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || | |
1216 | as_fn_error $? "pwd does not report name of working directory" | |
1217 | ||
1218 | ||
1219 | # Find the source files, if location was not specified. | |
1220 | if test -z "$srcdir"; then | |
1221 | ac_srcdir_defaulted=yes | |
1222 | # Try the directory containing this script, then the parent directory. | |
1223 | ac_confdir=`$as_dirname -- "$as_myself" || | |
1224 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
1225 | X"$as_myself" : 'X\(//\)[^/]' \| \ | |
1226 | X"$as_myself" : 'X\(//\)$' \| \ | |
1227 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || | |
1228 | $as_echo X"$as_myself" | | |
1229 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
1230 | s//\1/ | |
1231 | q | |
1232 | } | |
1233 | /^X\(\/\/\)[^/].*/{ | |
1234 | s//\1/ | |
1235 | q | |
1236 | } | |
1237 | /^X\(\/\/\)$/{ | |
1238 | s//\1/ | |
1239 | q | |
1240 | } | |
1241 | /^X\(\/\).*/{ | |
1242 | s//\1/ | |
1243 | q | |
1244 | } | |
1245 | s/.*/./; q'` | |
1246 | srcdir=$ac_confdir | |
1247 | if test ! -r "$srcdir/$ac_unique_file"; then | |
1248 | srcdir=.. | |
1249 | fi | |
1250 | else | |
1251 | ac_srcdir_defaulted=no | |
1252 | fi | |
1253 | if test ! -r "$srcdir/$ac_unique_file"; then | |
1254 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." | |
1255 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" | |
1256 | fi | |
1257 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" | |
1258 | ac_abs_confdir=`( | |
1259 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" | |
1260 | pwd)` | |
1261 | # When building in place, set srcdir=. | |
1262 | if test "$ac_abs_confdir" = "$ac_pwd"; then | |
1263 | srcdir=. | |
1264 | fi | |
1265 | # Remove unnecessary trailing slashes from srcdir. | |
1266 | # Double slashes in file names in object file debugging info | |
1267 | # mess up M-x gdb in Emacs. | |
1268 | case $srcdir in | |
1269 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; | |
1270 | esac | |
1271 | for ac_var in $ac_precious_vars; do | |
1272 | eval ac_env_${ac_var}_set=\${${ac_var}+set} | |
1273 | eval ac_env_${ac_var}_value=\$${ac_var} | |
1274 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} | |
1275 | eval ac_cv_env_${ac_var}_value=\$${ac_var} | |
1276 | done | |
1277 | ||
1278 | # | |
1279 | # Report the --help message. | |
1280 | # | |
1281 | if test "$ac_init_help" = "long"; then | |
1282 | # Omit some internal or obsolete options to make the list less imposing. | |
1283 | # This message is too long to be a string in the A/UX 3.1 sh. | |
1284 | cat <<_ACEOF | |
1285 | \`configure' configures rendercheck 1.4 to adapt to many kinds of systems. | |
1286 | ||
1287 | Usage: $0 [OPTION]... [VAR=VALUE]... | |
1288 | ||
1289 | To assign environment variables (e.g., CC, CFLAGS...), specify them as | |
1290 | VAR=VALUE. See below for descriptions of some of the useful variables. | |
1291 | ||
1292 | Defaults for the options are specified in brackets. | |
1293 | ||
1294 | Configuration: | |
1295 | -h, --help display this help and exit | |
1296 | --help=short display options specific to this package | |
1297 | --help=recursive display the short help of all the included packages | |
1298 | -V, --version display version information and exit | |
1299 | -q, --quiet, --silent do not print \`checking ...' messages | |
1300 | --cache-file=FILE cache test results in FILE [disabled] | |
1301 | -C, --config-cache alias for \`--cache-file=config.cache' | |
1302 | -n, --no-create do not create output files | |
1303 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] | |
1304 | ||
1305 | Installation directories: | |
1306 | --prefix=PREFIX install architecture-independent files in PREFIX | |
1307 | [$ac_default_prefix] | |
1308 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX | |
1309 | [PREFIX] | |
1310 | ||
1311 | By default, \`make install' will install all the files in | |
1312 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify | |
1313 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', | |
1314 | for instance \`--prefix=\$HOME'. | |
1315 | ||
1316 | For better control, use the options below. | |
1317 | ||
1318 | Fine tuning of the installation directories: | |
1319 | --bindir=DIR user executables [EPREFIX/bin] | |
1320 | --sbindir=DIR system admin executables [EPREFIX/sbin] | |
1321 | --libexecdir=DIR program executables [EPREFIX/libexec] | |
1322 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] | |
1323 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] | |
1324 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] | |
1325 | --libdir=DIR object code libraries [EPREFIX/lib] | |
1326 | --includedir=DIR C header files [PREFIX/include] | |
1327 | --oldincludedir=DIR C header files for non-gcc [/usr/include] | |
1328 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] | |
1329 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] | |
1330 | --infodir=DIR info documentation [DATAROOTDIR/info] | |
1331 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] | |
1332 | --mandir=DIR man documentation [DATAROOTDIR/man] | |
1333 | --docdir=DIR documentation root [DATAROOTDIR/doc/rendercheck] | |
1334 | --htmldir=DIR html documentation [DOCDIR] | |
1335 | --dvidir=DIR dvi documentation [DOCDIR] | |
1336 | --pdfdir=DIR pdf documentation [DOCDIR] | |
1337 | --psdir=DIR ps documentation [DOCDIR] | |
1338 | _ACEOF | |
1339 | ||
1340 | cat <<\_ACEOF | |
1341 | ||
1342 | Program names: | |
1343 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
1344 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
1345 | --program-transform-name=PROGRAM run sed PROGRAM on installed program names | |
1346 | ||
1347 | System types: | |
1348 | --build=BUILD configure for building on BUILD [guessed] | |
1349 | --host=HOST cross-compile to build programs to run on HOST [BUILD] | |
1350 | _ACEOF | |
1351 | fi | |
1352 | ||
1353 | if test -n "$ac_init_help"; then | |
1354 | case $ac_init_help in | |
1355 | short | recursive ) echo "Configuration of rendercheck 1.4:";; | |
1356 | esac | |
1357 | cat <<\_ACEOF | |
1358 | ||
1359 | Optional Features: | |
1360 | --disable-option-checking ignore unrecognized --enable/--with options | |
1361 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) | |
1362 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
1363 | --enable-maintainer-mode enable make rules and dependencies not useful | |
1364 | (and sometimes confusing) to the casual installer | |
1365 | --disable-dependency-tracking speeds up one-time build | |
1366 | --enable-dependency-tracking do not reject slow dependency extractors | |
1367 | --enable-strict-compilation | |
1368 | Enable all warnings from compiler and make them | |
1369 | errors (default: disabled) | |
1370 | --enable-silent-rules less verbose build output (undo: `make V=1') | |
1371 | --disable-silent-rules verbose build output (undo: `make V=0') | |
1372 | ||
1373 | Some influential environment variables: | |
1374 | CC C compiler command | |
1375 | CFLAGS C compiler flags | |
1376 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a | |
1377 | nonstandard directory <lib dir> | |
1378 | LIBS libraries to pass to the linker, e.g. -l<library> | |
1379 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if | |
1380 | you have headers in a nonstandard directory <include dir> | |
1381 | CPP C preprocessor | |
1382 | PKG_CONFIG path to pkg-config utility | |
1383 | RC_CFLAGS C compiler flags for RC, overriding pkg-config | |
1384 | RC_LIBS linker flags for RC, overriding pkg-config | |
1385 | ||
1386 | Use these variables to override the choices made by `configure' or to help | |
1387 | it to find libraries and programs with nonstandard names/locations. | |
1388 | ||
1389 | Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>. | |
1390 | _ACEOF | |
1391 | ac_status=$? | |
1392 | fi | |
1393 | ||
1394 | if test "$ac_init_help" = "recursive"; then | |
1395 | # If there are subdirs, report their specific --help. | |
1396 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue | |
1397 | test -d "$ac_dir" || | |
1398 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || | |
1399 | continue | |
1400 | ac_builddir=. | |
1401 | ||
1402 | case "$ac_dir" in | |
1403 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1404 | *) | |
1405 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
1406 | # A ".." for each directory in $ac_dir_suffix. | |
1407 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
1408 | case $ac_top_builddir_sub in | |
1409 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1410 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
1411 | esac ;; | |
1412 | esac | |
1413 | ac_abs_top_builddir=$ac_pwd | |
1414 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
1415 | # for backward compatibility: | |
1416 | ac_top_builddir=$ac_top_build_prefix | |
1417 | ||
1418 | case $srcdir in | |
1419 | .) # We are building in place. | |
1420 | ac_srcdir=. | |
1421 | ac_top_srcdir=$ac_top_builddir_sub | |
1422 | ac_abs_top_srcdir=$ac_pwd ;; | |
1423 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
1424 | ac_srcdir=$srcdir$ac_dir_suffix; | |
1425 | ac_top_srcdir=$srcdir | |
1426 | ac_abs_top_srcdir=$srcdir ;; | |
1427 | *) # Relative name. | |
1428 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
1429 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
1430 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
1431 | esac | |
1432 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix | |
1433 | ||
1434 | cd "$ac_dir" || { ac_status=$?; continue; } | |
1435 | # Check for guested configure. | |
1436 | if test -f "$ac_srcdir/configure.gnu"; then | |
1437 | echo && | |
1438 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive | |
1439 | elif test -f "$ac_srcdir/configure"; then | |
1440 | echo && | |
1441 | $SHELL "$ac_srcdir/configure" --help=recursive | |
1442 | else | |
1443 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 | |
1444 | fi || ac_status=$? | |
1445 | cd "$ac_pwd" || { ac_status=$?; break; } | |
1446 | done | |
1447 | fi | |
1448 | ||
1449 | test -n "$ac_init_help" && exit $ac_status | |
1450 | if $ac_init_version; then | |
1451 | cat <<\_ACEOF | |
1452 | rendercheck configure 1.4 | |
1453 | generated by GNU Autoconf 2.68 | |
1454 | ||
1455 | Copyright (C) 2010 Free Software Foundation, Inc. | |
1456 | This configure script is free software; the Free Software Foundation | |
1457 | gives unlimited permission to copy, distribute and modify it. | |
1458 | _ACEOF | |
1459 | exit | |
1460 | fi | |
1461 | ||
1462 | ## ------------------------ ## | |
1463 | ## Autoconf initialization. ## | |
1464 | ## ------------------------ ## | |
1465 | ||
1466 | # ac_fn_c_try_compile LINENO | |
1467 | # -------------------------- | |
1468 | # Try to compile conftest.$ac_ext, and return whether this succeeded. | |
1469 | ac_fn_c_try_compile () | |
1470 | { | |
1471 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1472 | rm -f conftest.$ac_objext | |
1473 | if { { ac_try="$ac_compile" | |
1474 | case "(($ac_try" in | |
1475 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1476 | *) ac_try_echo=$ac_try;; | |
1477 | esac | |
1478 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1479 | $as_echo "$ac_try_echo"; } >&5 | |
1480 | (eval "$ac_compile") 2>conftest.err | |
1481 | ac_status=$? | |
1482 | if test -s conftest.err; then | |
1483 | grep -v '^ *+' conftest.err >conftest.er1 | |
1484 | cat conftest.er1 >&5 | |
1485 | mv -f conftest.er1 conftest.err | |
1486 | fi | |
1487 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1488 | test $ac_status = 0; } && { | |
1489 | test -z "$ac_c_werror_flag" || | |
1490 | test ! -s conftest.err | |
1491 | } && test -s conftest.$ac_objext; then : | |
1492 | ac_retval=0 | |
1493 | else | |
1494 | $as_echo "$as_me: failed program was:" >&5 | |
1495 | sed 's/^/| /' conftest.$ac_ext >&5 | |
1496 | ||
1497 | ac_retval=1 | |
1498 | fi | |
1499 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1500 | as_fn_set_status $ac_retval | |
1501 | ||
1502 | } # ac_fn_c_try_compile | |
1503 | ||
1504 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES | |
1505 | # --------------------------------------------- | |
1506 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR | |
1507 | # accordingly. | |
1508 | ac_fn_c_check_decl () | |
1509 | { | |
1510 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1511 | as_decl_name=`echo $2|sed 's/ *(.*//'` | |
1512 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` | |
1513 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 | |
1514 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } | |
1515 | if eval \${$3+:} false; then : | |
1516 | $as_echo_n "(cached) " >&6 | |
1517 | else | |
1518 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1519 | /* end confdefs.h. */ | |
1520 | $4 | |
1521 | int | |
1522 | main () | |
1523 | { | |
1524 | #ifndef $as_decl_name | |
1525 | #ifdef __cplusplus | |
1526 | (void) $as_decl_use; | |
1527 | #else | |
1528 | (void) $as_decl_name; | |
1529 | #endif | |
1530 | #endif | |
1531 | ||
1532 | ; | |
1533 | return 0; | |
1534 | } | |
1535 | _ACEOF | |
1536 | if ac_fn_c_try_compile "$LINENO"; then : | |
1537 | eval "$3=yes" | |
1538 | else | |
1539 | eval "$3=no" | |
1540 | fi | |
1541 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1542 | fi | |
1543 | eval ac_res=\$$3 | |
1544 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1545 | $as_echo "$ac_res" >&6; } | |
1546 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1547 | ||
1548 | } # ac_fn_c_check_decl | |
1549 | ||
1550 | # ac_fn_c_try_cpp LINENO | |
1551 | # ---------------------- | |
1552 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. | |
1553 | ac_fn_c_try_cpp () | |
1554 | { | |
1555 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1556 | if { { ac_try="$ac_cpp conftest.$ac_ext" | |
1557 | case "(($ac_try" in | |
1558 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1559 | *) ac_try_echo=$ac_try;; | |
1560 | esac | |
1561 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1562 | $as_echo "$ac_try_echo"; } >&5 | |
1563 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err | |
1564 | ac_status=$? | |
1565 | if test -s conftest.err; then | |
1566 | grep -v '^ *+' conftest.err >conftest.er1 | |
1567 | cat conftest.er1 >&5 | |
1568 | mv -f conftest.er1 conftest.err | |
1569 | fi | |
1570 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1571 | test $ac_status = 0; } > conftest.i && { | |
1572 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || | |
1573 | test ! -s conftest.err | |
1574 | }; then : | |
1575 | ac_retval=0 | |
1576 | else | |
1577 | $as_echo "$as_me: failed program was:" >&5 | |
1578 | sed 's/^/| /' conftest.$ac_ext >&5 | |
1579 | ||
1580 | ac_retval=1 | |
1581 | fi | |
1582 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1583 | as_fn_set_status $ac_retval | |
1584 | ||
1585 | } # ac_fn_c_try_cpp | |
1586 | ||
1587 | # ac_fn_c_try_run LINENO | |
1588 | # ---------------------- | |
1589 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes | |
1590 | # that executables *can* be run. | |
1591 | ac_fn_c_try_run () | |
1592 | { | |
1593 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1594 | if { { ac_try="$ac_link" | |
1595 | case "(($ac_try" in | |
1596 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1597 | *) ac_try_echo=$ac_try;; | |
1598 | esac | |
1599 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1600 | $as_echo "$ac_try_echo"; } >&5 | |
1601 | (eval "$ac_link") 2>&5 | |
1602 | ac_status=$? | |
1603 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1604 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' | |
1605 | { { case "(($ac_try" in | |
1606 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1607 | *) ac_try_echo=$ac_try;; | |
1608 | esac | |
1609 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1610 | $as_echo "$ac_try_echo"; } >&5 | |
1611 | (eval "$ac_try") 2>&5 | |
1612 | ac_status=$? | |
1613 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1614 | test $ac_status = 0; }; }; then : | |
1615 | ac_retval=0 | |
1616 | else | |
1617 | $as_echo "$as_me: program exited with status $ac_status" >&5 | |
1618 | $as_echo "$as_me: failed program was:" >&5 | |
1619 | sed 's/^/| /' conftest.$ac_ext >&5 | |
1620 | ||
1621 | ac_retval=$ac_status | |
1622 | fi | |
1623 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
1624 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1625 | as_fn_set_status $ac_retval | |
1626 | ||
1627 | } # ac_fn_c_try_run | |
1628 | ||
1629 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES | |
1630 | # ------------------------------------------------------- | |
1631 | # Tests whether HEADER exists and can be compiled using the include files in | |
1632 | # INCLUDES, setting the cache variable VAR accordingly. | |
1633 | ac_fn_c_check_header_compile () | |
1634 | { | |
1635 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1636 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1637 | $as_echo_n "checking for $2... " >&6; } | |
1638 | if eval \${$3+:} false; then : | |
1639 | $as_echo_n "(cached) " >&6 | |
1640 | else | |
1641 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1642 | /* end confdefs.h. */ | |
1643 | $4 | |
1644 | #include <$2> | |
1645 | _ACEOF | |
1646 | if ac_fn_c_try_compile "$LINENO"; then : | |
1647 | eval "$3=yes" | |
1648 | else | |
1649 | eval "$3=no" | |
1650 | fi | |
1651 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1652 | fi | |
1653 | eval ac_res=\$$3 | |
1654 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1655 | $as_echo "$ac_res" >&6; } | |
1656 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1657 | ||
1658 | } # ac_fn_c_check_header_compile | |
1659 | ||
1660 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES | |
1661 | # ------------------------------------------------------- | |
1662 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using | |
1663 | # the include files in INCLUDES and setting the cache variable VAR | |
1664 | # accordingly. | |
1665 | ac_fn_c_check_header_mongrel () | |
1666 | { | |
1667 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1668 | if eval \${$3+:} false; then : | |
1669 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1670 | $as_echo_n "checking for $2... " >&6; } | |
1671 | if eval \${$3+:} false; then : | |
1672 | $as_echo_n "(cached) " >&6 | |
1673 | fi | |
1674 | eval ac_res=\$$3 | |
1675 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1676 | $as_echo "$ac_res" >&6; } | |
1677 | else | |
1678 | # Is the header compilable? | |
1679 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 | |
1680 | $as_echo_n "checking $2 usability... " >&6; } | |
1681 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1682 | /* end confdefs.h. */ | |
1683 | $4 | |
1684 | #include <$2> | |
1685 | _ACEOF | |
1686 | if ac_fn_c_try_compile "$LINENO"; then : | |
1687 | ac_header_compiler=yes | |
1688 | else | |
1689 | ac_header_compiler=no | |
1690 | fi | |
1691 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1692 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 | |
1693 | $as_echo "$ac_header_compiler" >&6; } | |
1694 | ||
1695 | # Is the header present? | |
1696 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 | |
1697 | $as_echo_n "checking $2 presence... " >&6; } | |
1698 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1699 | /* end confdefs.h. */ | |
1700 | #include <$2> | |
1701 | _ACEOF | |
1702 | if ac_fn_c_try_cpp "$LINENO"; then : | |
1703 | ac_header_preproc=yes | |
1704 | else | |
1705 | ac_header_preproc=no | |
1706 | fi | |
1707 | rm -f conftest.err conftest.i conftest.$ac_ext | |
1708 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 | |
1709 | $as_echo "$ac_header_preproc" >&6; } | |
1710 | ||
1711 | # So? What about this header? | |
1712 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( | |
1713 | yes:no: ) | |
1714 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 | |
1715 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} | |
1716 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1717 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1718 | ;; | |
1719 | no:yes:* ) | |
1720 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 | |
1721 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} | |
1722 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 | |
1723 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} | |
1724 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 | |
1725 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} | |
1726 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 | |
1727 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} | |
1728 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1729 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1730 | ( $as_echo "## ---------------------------------------------------------------------- ## | |
1731 | ## Report this to https://bugs.freedesktop.org/enter_bug.cgi?product=xorg ## | |
1732 | ## ---------------------------------------------------------------------- ##" | |
1733 | ) | sed "s/^/$as_me: WARNING: /" >&2 | |
1734 | ;; | |
1735 | esac | |
1736 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1737 | $as_echo_n "checking for $2... " >&6; } | |
1738 | if eval \${$3+:} false; then : | |
1739 | $as_echo_n "(cached) " >&6 | |
1740 | else | |
1741 | eval "$3=\$ac_header_compiler" | |
1742 | fi | |
1743 | eval ac_res=\$$3 | |
1744 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1745 | $as_echo "$ac_res" >&6; } | |
1746 | fi | |
1747 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1748 | ||
1749 | } # ac_fn_c_check_header_mongrel | |
1750 | cat >config.log <<_ACEOF | |
1751 | This file contains any messages produced by compilers while | |
1752 | running configure, to aid debugging if configure makes a mistake. | |
1753 | ||
1754 | It was created by rendercheck $as_me 1.4, which was | |
1755 | generated by GNU Autoconf 2.68. Invocation command line was | |
1756 | ||
1757 | $ $0 $@ | |
1758 | ||
1759 | _ACEOF | |
1760 | exec 5>>config.log | |
1761 | { | |
1762 | cat <<_ASUNAME | |
1763 | ## --------- ## | |
1764 | ## Platform. ## | |
1765 | ## --------- ## | |
1766 | ||
1767 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` | |
1768 | uname -m = `(uname -m) 2>/dev/null || echo unknown` | |
1769 | uname -r = `(uname -r) 2>/dev/null || echo unknown` | |
1770 | uname -s = `(uname -s) 2>/dev/null || echo unknown` | |
1771 | uname -v = `(uname -v) 2>/dev/null || echo unknown` | |
1772 | ||
1773 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` | |
1774 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` | |
1775 | ||
1776 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` | |
1777 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` | |
1778 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` | |
1779 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` | |
1780 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` | |
1781 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` | |
1782 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` | |
1783 | ||
1784 | _ASUNAME | |
1785 | ||
1786 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
1787 | for as_dir in $PATH | |
1788 | do | |
1789 | IFS=$as_save_IFS | |
1790 | test -z "$as_dir" && as_dir=. | |
1791 | $as_echo "PATH: $as_dir" | |
1792 | done | |
1793 | IFS=$as_save_IFS | |
1794 | ||
1795 | } >&5 | |
1796 | ||
1797 | cat >&5 <<_ACEOF | |
1798 | ||
1799 | ||
1800 | ## ----------- ## | |
1801 | ## Core tests. ## | |
1802 | ## ----------- ## | |
1803 | ||
1804 | _ACEOF | |
1805 | ||
1806 | ||
1807 | # Keep a trace of the command line. | |
1808 | # Strip out --no-create and --no-recursion so they do not pile up. | |
1809 | # Strip out --silent because we don't want to record it for future runs. | |
1810 | # Also quote any args containing shell meta-characters. | |
1811 | # Make two passes to allow for proper duplicate-argument suppression. | |
1812 | ac_configure_args= | |
1813 | ac_configure_args0= | |
1814 | ac_configure_args1= | |
1815 | ac_must_keep_next=false | |
1816 | for ac_pass in 1 2 | |
1817 | do | |
1818 | for ac_arg | |
1819 | do | |
1820 | case $ac_arg in | |
1821 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; | |
1822 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
1823 | | -silent | --silent | --silen | --sile | --sil) | |
1824 | continue ;; | |
1825 | *\'*) | |
1826 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
1827 | esac | |
1828 | case $ac_pass in | |
1829 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; | |
1830 | 2) | |
1831 | as_fn_append ac_configure_args1 " '$ac_arg'" | |
1832 | if test $ac_must_keep_next = true; then | |
1833 | ac_must_keep_next=false # Got value, back to normal. | |
1834 | else | |
1835 | case $ac_arg in | |
1836 | *=* | --config-cache | -C | -disable-* | --disable-* \ | |
1837 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | |
1838 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | |
1839 | | -with-* | --with-* | -without-* | --without-* | --x) | |
1840 | case "$ac_configure_args0 " in | |
1841 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; | |
1842 | esac | |
1843 | ;; | |
1844 | -* ) ac_must_keep_next=true ;; | |
1845 | esac | |
1846 | fi | |
1847 | as_fn_append ac_configure_args " '$ac_arg'" | |
1848 | ;; | |
1849 | esac | |
1850 | done | |
1851 | done | |
1852 | { ac_configure_args0=; unset ac_configure_args0;} | |
1853 | { ac_configure_args1=; unset ac_configure_args1;} | |
1854 | ||
1855 | # When interrupted or exit'd, cleanup temporary files, and complete | |
1856 | # config.log. We remove comments because anyway the quotes in there | |
1857 | # would cause problems or look ugly. | |
1858 | # WARNING: Use '\'' to represent an apostrophe within the trap. | |
1859 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. | |
1860 | trap 'exit_status=$? | |
1861 | # Save into config.log some information that might help in debugging. | |
1862 | { | |
1863 | echo | |
1864 | ||
1865 | $as_echo "## ---------------- ## | |
1866 | ## Cache variables. ## | |
1867 | ## ---------------- ##" | |
1868 | echo | |
1869 | # The following way of writing the cache mishandles newlines in values, | |
1870 | ( | |
1871 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do | |
1872 | eval ac_val=\$$ac_var | |
1873 | case $ac_val in #( | |
1874 | *${as_nl}*) | |
1875 | case $ac_var in #( | |
1876 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
1877 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
1878 | esac | |
1879 | case $ac_var in #( | |
1880 | _ | IFS | as_nl) ;; #( | |
1881 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
1882 | *) { eval $ac_var=; unset $ac_var;} ;; | |
1883 | esac ;; | |
1884 | esac | |
1885 | done | |
1886 | (set) 2>&1 | | |
1887 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( | |
1888 | *${as_nl}ac_space=\ *) | |
1889 | sed -n \ | |
1890 | "s/'\''/'\''\\\\'\'''\''/g; | |
1891 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" | |
1892 | ;; #( | |
1893 | *) | |
1894 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
1895 | ;; | |
1896 | esac | | |
1897 | sort | |
1898 | ) | |
1899 | echo | |
1900 | ||
1901 | $as_echo "## ----------------- ## | |
1902 | ## Output variables. ## | |
1903 | ## ----------------- ##" | |
1904 | echo | |
1905 | for ac_var in $ac_subst_vars | |
1906 | do | |
1907 | eval ac_val=\$$ac_var | |
1908 | case $ac_val in | |
1909 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
1910 | esac | |
1911 | $as_echo "$ac_var='\''$ac_val'\''" | |
1912 | done | sort | |
1913 | echo | |
1914 | ||
1915 | if test -n "$ac_subst_files"; then | |
1916 | $as_echo "## ------------------- ## | |
1917 | ## File substitutions. ## | |
1918 | ## ------------------- ##" | |
1919 | echo | |
1920 | for ac_var in $ac_subst_files | |
1921 | do | |
1922 | eval ac_val=\$$ac_var | |
1923 | case $ac_val in | |
1924 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
1925 | esac | |
1926 | $as_echo "$ac_var='\''$ac_val'\''" | |
1927 | done | sort | |
1928 | echo | |
1929 | fi | |
1930 | ||
1931 | if test -s confdefs.h; then | |
1932 | $as_echo "## ----------- ## | |
1933 | ## confdefs.h. ## | |
1934 | ## ----------- ##" | |
1935 | echo | |
1936 | cat confdefs.h | |
1937 | echo | |
1938 | fi | |
1939 | test "$ac_signal" != 0 && | |
1940 | $as_echo "$as_me: caught signal $ac_signal" | |
1941 | $as_echo "$as_me: exit $exit_status" | |
1942 | } >&5 | |
1943 | rm -f core *.core core.conftest.* && | |
1944 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && | |
1945 | exit $exit_status | |
1946 | ' 0 | |
1947 | for ac_signal in 1 2 13 15; do | |
1948 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal | |
1949 | done | |
1950 | ac_signal=0 | |
1951 | ||
1952 | # confdefs.h avoids OS command line length limits that DEFS can exceed. | |
1953 | rm -f -r conftest* confdefs.h | |
1954 | ||
1955 | $as_echo "/* confdefs.h */" > confdefs.h | |
1956 | ||
1957 | # Predefined preprocessor variables. | |
1958 | ||
1959 | cat >>confdefs.h <<_ACEOF | |
1960 | #define PACKAGE_NAME "$PACKAGE_NAME" | |
1961 | _ACEOF | |
1962 | ||
1963 | cat >>confdefs.h <<_ACEOF | |
1964 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" | |
1965 | _ACEOF | |
1966 | ||
1967 | cat >>confdefs.h <<_ACEOF | |
1968 | #define PACKAGE_VERSION "$PACKAGE_VERSION" | |
1969 | _ACEOF | |
1970 | ||
1971 | cat >>confdefs.h <<_ACEOF | |
1972 | #define PACKAGE_STRING "$PACKAGE_STRING" | |
1973 | _ACEOF | |
1974 | ||
1975 | cat >>confdefs.h <<_ACEOF | |
1976 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" | |
1977 | _ACEOF | |
1978 | ||
1979 | cat >>confdefs.h <<_ACEOF | |
1980 | #define PACKAGE_URL "$PACKAGE_URL" | |
1981 | _ACEOF | |
1982 | ||
1983 | ||
1984 | # Let the site file select an alternate cache file if it wants to. | |
1985 | # Prefer an explicitly selected file to automatically selected ones. | |
1986 | ac_site_file1=NONE | |
1987 | ac_site_file2=NONE | |
1988 | if test -n "$CONFIG_SITE"; then | |
1989 | # We do not want a PATH search for config.site. | |
1990 | case $CONFIG_SITE in #(( | |
1991 | -*) ac_site_file1=./$CONFIG_SITE;; | |
1992 | */*) ac_site_file1=$CONFIG_SITE;; | |
1993 | *) ac_site_file1=./$CONFIG_SITE;; | |
1994 | esac | |
1995 | elif test "x$prefix" != xNONE; then | |
1996 | ac_site_file1=$prefix/share/config.site | |
1997 | ac_site_file2=$prefix/etc/config.site | |
1998 | else | |
1999 | ac_site_file1=$ac_default_prefix/share/config.site | |
2000 | ac_site_file2=$ac_default_prefix/etc/config.site | |
2001 | fi | |
2002 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" | |
2003 | do | |
2004 | test "x$ac_site_file" = xNONE && continue | |
2005 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then | |
2006 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 | |
2007 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} | |
2008 | sed 's/^/| /' "$ac_site_file" >&5 | |
2009 | . "$ac_site_file" \ | |
2010 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2011 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2012 | as_fn_error $? "failed to load site script $ac_site_file | |
2013 | See \`config.log' for more details" "$LINENO" 5; } | |
2014 | fi | |
2015 | done | |
2016 | ||
2017 | if test -r "$cache_file"; then | |
2018 | # Some versions of bash will fail to source /dev/null (special files | |
2019 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. | |
2020 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then | |
2021 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 | |
2022 | $as_echo "$as_me: loading cache $cache_file" >&6;} | |
2023 | case $cache_file in | |
2024 | [\\/]* | ?:[\\/]* ) . "$cache_file";; | |
2025 | *) . "./$cache_file";; | |
2026 | esac | |
2027 | fi | |
2028 | else | |
2029 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 | |
2030 | $as_echo "$as_me: creating cache $cache_file" >&6;} | |
2031 | >$cache_file | |
2032 | fi | |
2033 | ||
2034 | # Check that the precious variables saved in the cache have kept the same | |
2035 | # value. | |
2036 | ac_cache_corrupted=false | |
2037 | for ac_var in $ac_precious_vars; do | |
2038 | eval ac_old_set=\$ac_cv_env_${ac_var}_set | |
2039 | eval ac_new_set=\$ac_env_${ac_var}_set | |
2040 | eval ac_old_val=\$ac_cv_env_${ac_var}_value | |
2041 | eval ac_new_val=\$ac_env_${ac_var}_value | |
2042 | case $ac_old_set,$ac_new_set in | |
2043 | set,) | |
2044 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 | |
2045 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} | |
2046 | ac_cache_corrupted=: ;; | |
2047 | ,set) | |
2048 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 | |
2049 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} | |
2050 | ac_cache_corrupted=: ;; | |
2051 | ,);; | |
2052 | *) | |
2053 | if test "x$ac_old_val" != "x$ac_new_val"; then | |
2054 | # differences in whitespace do not lead to failure. | |
2055 | ac_old_val_w=`echo x $ac_old_val` | |
2056 | ac_new_val_w=`echo x $ac_new_val` | |
2057 | if test "$ac_old_val_w" != "$ac_new_val_w"; then | |
2058 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 | |
2059 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} | |
2060 | ac_cache_corrupted=: | |
2061 | else | |
2062 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 | |
2063 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} | |
2064 | eval $ac_var=\$ac_old_val | |
2065 | fi | |
2066 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 | |
2067 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} | |
2068 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 | |
2069 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} | |
2070 | fi;; | |
2071 | esac | |
2072 | # Pass precious variables to config.status. | |
2073 | if test "$ac_new_set" = set; then | |
2074 | case $ac_new_val in | |
2075 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2076 | *) ac_arg=$ac_var=$ac_new_val ;; | |
2077 | esac | |
2078 | case " $ac_configure_args " in | |
2079 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. | |
2080 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; | |
2081 | esac | |
2082 | fi | |
2083 | done | |
2084 | if $ac_cache_corrupted; then | |
2085 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2086 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2087 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 | |
2088 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} | |
2089 | as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 | |
2090 | fi | |
2091 | ## -------------------- ## | |
2092 | ## Main body of script. ## | |
2093 | ## -------------------- ## | |
2094 | ||
2095 | ac_ext=c | |
2096 | ac_cpp='$CPP $CPPFLAGS' | |
2097 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
2098 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
2099 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
2100 | ||
2101 | ||
2102 | ||
2103 | ||
2104 | am__api_version='1.11' | |
2105 | ||
2106 | ac_aux_dir= | |
2107 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do | |
2108 | if test -f "$ac_dir/install-sh"; then | |
2109 | ac_aux_dir=$ac_dir | |
2110 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
2111 | break | |
2112 | elif test -f "$ac_dir/install.sh"; then | |
2113 | ac_aux_dir=$ac_dir | |
2114 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
2115 | break | |
2116 | elif test -f "$ac_dir/shtool"; then | |
2117 | ac_aux_dir=$ac_dir | |
2118 | ac_install_sh="$ac_aux_dir/shtool install -c" | |
2119 | break | |
2120 | fi | |
2121 | done | |
2122 | if test -z "$ac_aux_dir"; then | |
2123 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 | |
2124 | fi | |
2125 | ||
2126 | # These three variables are undocumented and unsupported, | |
2127 | # and are intended to be withdrawn in a future Autoconf release. | |
2128 | # They can cause serious problems if a builder's source tree is in a directory | |
2129 | # whose full name contains unusual characters. | |
2130 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. | |
2131 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. | |
2132 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. | |
2133 | ||
2134 | ||
2135 | # Find a good install program. We prefer a C program (faster), | |
2136 | # so one script is as good as another. But avoid the broken or | |
2137 | # incompatible versions: | |
2138 | # SysV /etc/install, /usr/sbin/install | |
2139 | # SunOS /usr/etc/install | |
2140 | # IRIX /sbin/install | |
2141 | # AIX /bin/install | |
2142 | # AmigaOS /C/install, which installs bootblocks on floppy discs | |
2143 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | |
2144 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
2145 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
2146 | # OS/2's system install, which has a completely different semantic | |
2147 | # ./install, which can be erroneously created by make from ./install.sh. | |
2148 | # Reject install programs that cannot install multiple files. | |
2149 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 | |
2150 | $as_echo_n "checking for a BSD-compatible install... " >&6; } | |
2151 | if test -z "$INSTALL"; then | |
2152 | if ${ac_cv_path_install+:} false; then : | |
2153 | $as_echo_n "(cached) " >&6 | |
2154 | else | |
2155 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2156 | for as_dir in $PATH | |
2157 | do | |
2158 | IFS=$as_save_IFS | |
2159 | test -z "$as_dir" && as_dir=. | |
2160 | # Account for people who put trailing slashes in PATH elements. | |
2161 | case $as_dir/ in #(( | |
2162 | ./ | .// | /[cC]/* | \ | |
2163 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ | |
2164 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ | |
2165 | /usr/ucb/* ) ;; | |
2166 | *) | |
2167 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
2168 | # Don't use installbsd from OSF since it installs stuff as root | |
2169 | # by default. | |
2170 | for ac_prog in ginstall scoinst install; do | |
2171 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2172 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then | |
2173 | if test $ac_prog = install && | |
2174 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
2175 | # AIX install. It has an incompatible calling convention. | |
2176 | : | |
2177 | elif test $ac_prog = install && | |
2178 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
2179 | # program-specific install script used by HP pwplus--don't use. | |
2180 | : | |
2181 | else | |
2182 | rm -rf conftest.one conftest.two conftest.dir | |
2183 | echo one > conftest.one | |
2184 | echo two > conftest.two | |
2185 | mkdir conftest.dir | |
2186 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && | |
2187 | test -s conftest.one && test -s conftest.two && | |
2188 | test -s conftest.dir/conftest.one && | |
2189 | test -s conftest.dir/conftest.two | |
2190 | then | |
2191 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" | |
2192 | break 3 | |
2193 | fi | |
2194 | fi | |
2195 | fi | |
2196 | done | |
2197 | done | |
2198 | ;; | |
2199 | esac | |
2200 | ||
2201 | done | |
2202 | IFS=$as_save_IFS | |
2203 | ||
2204 | rm -rf conftest.one conftest.two conftest.dir | |
2205 | ||
2206 | fi | |
2207 | if test "${ac_cv_path_install+set}" = set; then | |
2208 | INSTALL=$ac_cv_path_install | |
2209 | else | |
2210 | # As a last resort, use the slow shell script. Don't cache a | |
2211 | # value for INSTALL within a source directory, because that will | |
2212 | # break other packages using the cache if that directory is | |
2213 | # removed, or if the value is a relative name. | |
2214 | INSTALL=$ac_install_sh | |
2215 | fi | |
2216 | fi | |
2217 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 | |
2218 | $as_echo "$INSTALL" >&6; } | |
2219 | ||
2220 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
2221 | # It thinks the first close brace ends the variable substitution. | |
2222 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
2223 | ||
2224 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' | |
2225 | ||
2226 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
2227 | ||
2228 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5 | |
2229 | $as_echo_n "checking whether build environment is sane... " >&6; } | |
2230 | # Just in case | |
2231 | sleep 1 | |
2232 | echo timestamp > conftest.file | |
2233 | # Reject unsafe characters in $srcdir or the absolute working directory | |
2234 | # name. Accept space and tab only in the latter. | |
2235 | am_lf=' | |
2236 | ' | |
2237 | case `pwd` in | |
2238 | *[\\\"\#\$\&\'\`$am_lf]*) | |
2239 | as_fn_error $? "unsafe absolute working directory name" "$LINENO" 5;; | |
2240 | esac | |
2241 | case $srcdir in | |
2242 | *[\\\"\#\$\&\'\`$am_lf\ \ ]*) | |
2243 | as_fn_error $? "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;; | |
2244 | esac | |
2245 | ||
2246 | # Do `set' in a subshell so we don't clobber the current shell's | |
2247 | # arguments. Must try -L first in case configure is actually a | |
2248 | # symlink; some systems play weird games with the mod time of symlinks | |
2249 | # (eg FreeBSD returns the mod time of the symlink's containing | |
2250 | # directory). | |
2251 | if ( | |
2252 | set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null` | |
2253 | if test "$*" = "X"; then | |
2254 | # -L didn't work. | |
2255 | set X `ls -t "$srcdir/configure" conftest.file` | |
2256 | fi | |
2257 | rm -f conftest.file | |
2258 | if test "$*" != "X $srcdir/configure conftest.file" \ | |
2259 | && test "$*" != "X conftest.file $srcdir/configure"; then | |
2260 | ||
2261 | # If neither matched, then we have a broken ls. This can happen | |
2262 | # if, for instance, CONFIG_SHELL is bash and it inherits a | |
2263 | # broken ls alias from the environment. This has actually | |
2264 | # happened. Such a system could not be considered "sane". | |
2265 | as_fn_error $? "ls -t appears to fail. Make sure there is not a broken | |
2266 | alias in your environment" "$LINENO" 5 | |
2267 | fi | |
2268 | ||
2269 | test "$2" = conftest.file | |
2270 | ) | |
2271 | then | |
2272 | # Ok. | |
2273 | : | |
2274 | else | |
2275 | as_fn_error $? "newly created file is older than distributed files! | |
2276 | Check your system clock" "$LINENO" 5 | |
2277 | fi | |
2278 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
2279 | $as_echo "yes" >&6; } | |
2280 | test "$program_prefix" != NONE && | |
2281 | program_transform_name="s&^&$program_prefix&;$program_transform_name" | |
2282 | # Use a double $ so make ignores it. | |
2283 | test "$program_suffix" != NONE && | |
2284 | program_transform_name="s&\$&$program_suffix&;$program_transform_name" | |
2285 | # Double any \ or $. | |
2286 | # By default was `s,x,x', remove it if useless. | |
2287 | ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' | |
2288 | program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` | |
2289 | ||
2290 | # expand $ac_aux_dir to an absolute path | |
2291 | am_aux_dir=`cd $ac_aux_dir && pwd` | |
2292 | ||
2293 | if test x"${MISSING+set}" != xset; then | |
2294 | case $am_aux_dir in | |
2295 | *\ * | *\ *) | |
2296 | MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;; | |
2297 | *) | |
2298 | MISSING="\${SHELL} $am_aux_dir/missing" ;; | |
2299 | esac | |
2300 | fi | |
2301 | # Use eval to expand $SHELL | |
2302 | if eval "$MISSING --run true"; then | |
2303 | am_missing_run="$MISSING --run " | |
2304 | else | |
2305 | am_missing_run= | |
2306 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5 | |
2307 | $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;} | |
2308 | fi | |
2309 | ||
2310 | if test x"${install_sh}" != xset; then | |
2311 | case $am_aux_dir in | |
2312 | *\ * | *\ *) | |
2313 | install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;; | |
2314 | *) | |
2315 | install_sh="\${SHELL} $am_aux_dir/install-sh" | |
2316 | esac | |
2317 | fi | |
2318 | ||
2319 | # Installed binaries are usually stripped using `strip' when the user | |
2320 | # run `make install-strip'. However `strip' might not be the right | |
2321 | # tool to use in cross-compilation environments, therefore Automake | |
2322 | # will honor the `STRIP' environment variable to overrule this program. | |
2323 | if test "$cross_compiling" != no; then | |
2324 | if test -n "$ac_tool_prefix"; then | |
2325 | # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. | |
2326 | set dummy ${ac_tool_prefix}strip; ac_word=$2 | |
2327 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2328 | $as_echo_n "checking for $ac_word... " >&6; } | |
2329 | if ${ac_cv_prog_STRIP+:} false; then : | |
2330 | $as_echo_n "(cached) " >&6 | |
2331 | else | |
2332 | if test -n "$STRIP"; then | |
2333 | ac_cv_prog_STRIP="$STRIP" # Let the user override the test. | |
2334 | else | |
2335 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2336 | for as_dir in $PATH | |
2337 | do | |
2338 | IFS=$as_save_IFS | |
2339 | test -z "$as_dir" && as_dir=. | |
2340 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2341 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2342 | ac_cv_prog_STRIP="${ac_tool_prefix}strip" | |
2343 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2344 | break 2 | |
2345 | fi | |
2346 | done | |
2347 | done | |
2348 | IFS=$as_save_IFS | |
2349 | ||
2350 | fi | |
2351 | fi | |
2352 | STRIP=$ac_cv_prog_STRIP | |
2353 | if test -n "$STRIP"; then | |
2354 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 | |
2355 | $as_echo "$STRIP" >&6; } | |
2356 | else | |
2357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2358 | $as_echo "no" >&6; } | |
2359 | fi | |
2360 | ||
2361 | ||
2362 | fi | |
2363 | if test -z "$ac_cv_prog_STRIP"; then | |
2364 | ac_ct_STRIP=$STRIP | |
2365 | # Extract the first word of "strip", so it can be a program name with args. | |
2366 | set dummy strip; ac_word=$2 | |
2367 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2368 | $as_echo_n "checking for $ac_word... " >&6; } | |
2369 | if ${ac_cv_prog_ac_ct_STRIP+:} false; then : | |
2370 | $as_echo_n "(cached) " >&6 | |
2371 | else | |
2372 | if test -n "$ac_ct_STRIP"; then | |
2373 | ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. | |
2374 | else | |
2375 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2376 | for as_dir in $PATH | |
2377 | do | |
2378 | IFS=$as_save_IFS | |
2379 | test -z "$as_dir" && as_dir=. | |
2380 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2381 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2382 | ac_cv_prog_ac_ct_STRIP="strip" | |
2383 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2384 | break 2 | |
2385 | fi | |
2386 | done | |
2387 | done | |
2388 | IFS=$as_save_IFS | |
2389 | ||
2390 | fi | |
2391 | fi | |
2392 | ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP | |
2393 | if test -n "$ac_ct_STRIP"; then | |
2394 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 | |
2395 | $as_echo "$ac_ct_STRIP" >&6; } | |
2396 | else | |
2397 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2398 | $as_echo "no" >&6; } | |
2399 | fi | |
2400 | ||
2401 | if test "x$ac_ct_STRIP" = x; then | |
2402 | STRIP=":" | |
2403 | else | |
2404 | case $cross_compiling:$ac_tool_warned in | |
2405 | yes:) | |
2406 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
2407 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
2408 | ac_tool_warned=yes ;; | |
2409 | esac | |
2410 | STRIP=$ac_ct_STRIP | |
2411 | fi | |
2412 | else | |
2413 | STRIP="$ac_cv_prog_STRIP" | |
2414 | fi | |
2415 | ||
2416 | fi | |
2417 | INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s" | |
2418 | ||
2419 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5 | |
2420 | $as_echo_n "checking for a thread-safe mkdir -p... " >&6; } | |
2421 | if test -z "$MKDIR_P"; then | |
2422 | if ${ac_cv_path_mkdir+:} false; then : | |
2423 | $as_echo_n "(cached) " >&6 | |
2424 | else | |
2425 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2426 | for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin | |
2427 | do | |
2428 | IFS=$as_save_IFS | |
2429 | test -z "$as_dir" && as_dir=. | |
2430 | for ac_prog in mkdir gmkdir; do | |
2431 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2432 | { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue | |
2433 | case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #( | |
2434 | 'mkdir (GNU coreutils) '* | \ | |
2435 | 'mkdir (coreutils) '* | \ | |
2436 | 'mkdir (fileutils) '4.1*) | |
2437 | ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext | |
2438 | break 3;; | |
2439 | esac | |
2440 | done | |
2441 | done | |
2442 | done | |
2443 | IFS=$as_save_IFS | |
2444 | ||
2445 | fi | |
2446 | ||
2447 | test -d ./--version && rmdir ./--version | |
2448 | if test "${ac_cv_path_mkdir+set}" = set; then | |
2449 | MKDIR_P="$ac_cv_path_mkdir -p" | |
2450 | else | |
2451 | # As a last resort, use the slow shell script. Don't cache a | |
2452 | # value for MKDIR_P within a source directory, because that will | |
2453 | # break other packages using the cache if that directory is | |
2454 | # removed, or if the value is a relative name. | |
2455 | MKDIR_P="$ac_install_sh -d" | |
2456 | fi | |
2457 | fi | |
2458 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5 | |
2459 | $as_echo "$MKDIR_P" >&6; } | |
2460 | ||
2461 | mkdir_p="$MKDIR_P" | |
2462 | case $mkdir_p in | |
2463 | [\\/$]* | ?:[\\/]*) ;; | |
2464 | */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;; | |
2465 | esac | |
2466 | ||
2467 | for ac_prog in gawk mawk nawk awk | |
2468 | do | |
2469 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
2470 | set dummy $ac_prog; ac_word=$2 | |
2471 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2472 | $as_echo_n "checking for $ac_word... " >&6; } | |
2473 | if ${ac_cv_prog_AWK+:} false; then : | |
2474 | $as_echo_n "(cached) " >&6 | |
2475 | else | |
2476 | if test -n "$AWK"; then | |
2477 | ac_cv_prog_AWK="$AWK" # Let the user override the test. | |
2478 | else | |
2479 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2480 | for as_dir in $PATH | |
2481 | do | |
2482 | IFS=$as_save_IFS | |
2483 | test -z "$as_dir" && as_dir=. | |
2484 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2485 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2486 | ac_cv_prog_AWK="$ac_prog" | |
2487 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2488 | break 2 | |
2489 | fi | |
2490 | done | |
2491 | done | |
2492 | IFS=$as_save_IFS | |
2493 | ||
2494 | fi | |
2495 | fi | |
2496 | AWK=$ac_cv_prog_AWK | |
2497 | if test -n "$AWK"; then | |
2498 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 | |
2499 | $as_echo "$AWK" >&6; } | |
2500 | else | |
2501 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2502 | $as_echo "no" >&6; } | |
2503 | fi | |
2504 | ||
2505 | ||
2506 | test -n "$AWK" && break | |
2507 | done | |
2508 | ||
2509 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 | |
2510 | $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } | |
2511 | set x ${MAKE-make} | |
2512 | ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` | |
2513 | if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : | |
2514 | $as_echo_n "(cached) " >&6 | |
2515 | else | |
2516 | cat >conftest.make <<\_ACEOF | |
2517 | SHELL = /bin/sh | |
2518 | all: | |
2519 | @echo '@@@%%%=$(MAKE)=@@@%%%' | |
2520 | _ACEOF | |
2521 | # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. | |
2522 | case `${MAKE-make} -f conftest.make 2>/dev/null` in | |
2523 | *@@@%%%=?*=@@@%%%*) | |
2524 | eval ac_cv_prog_make_${ac_make}_set=yes;; | |
2525 | *) | |
2526 | eval ac_cv_prog_make_${ac_make}_set=no;; | |
2527 | esac | |
2528 | rm -f conftest.make | |
2529 | fi | |
2530 | if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then | |
2531 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
2532 | $as_echo "yes" >&6; } | |
2533 | SET_MAKE= | |
2534 | else | |
2535 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2536 | $as_echo "no" >&6; } | |
2537 | SET_MAKE="MAKE=${MAKE-make}" | |
2538 | fi | |
2539 | ||
2540 | rm -rf .tst 2>/dev/null | |
2541 | mkdir .tst 2>/dev/null | |
2542 | if test -d .tst; then | |
2543 | am__leading_dot=. | |
2544 | else | |
2545 | am__leading_dot=_ | |
2546 | fi | |
2547 | rmdir .tst 2>/dev/null | |
2548 | ||
2549 | if test "`cd $srcdir && pwd`" != "`pwd`"; then | |
2550 | # Use -I$(srcdir) only when $(srcdir) != ., so that make's output | |
2551 | # is not polluted with repeated "-I." | |
2552 | am__isrc=' -I$(srcdir)' | |
2553 | # test to see if srcdir already configured | |
2554 | if test -f $srcdir/config.status; then | |
2555 | as_fn_error $? "source directory already configured; run \"make distclean\" there first" "$LINENO" 5 | |
2556 | fi | |
2557 | fi | |
2558 | ||
2559 | # test whether we have cygpath | |
2560 | if test -z "$CYGPATH_W"; then | |
2561 | if (cygpath --version) >/dev/null 2>/dev/null; then | |
2562 | CYGPATH_W='cygpath -w' | |
2563 | else | |
2564 | CYGPATH_W=echo | |
2565 | fi | |
2566 | fi | |
2567 | ||
2568 | ||
2569 | # Define the identity of the package. | |
2570 | PACKAGE='rendercheck' | |
2571 | VERSION='1.4' | |
2572 | ||
2573 | ||
2574 | cat >>confdefs.h <<_ACEOF | |
2575 | #define PACKAGE "$PACKAGE" | |
2576 | _ACEOF | |
2577 | ||
2578 | ||
2579 | cat >>confdefs.h <<_ACEOF | |
2580 | #define VERSION "$VERSION" | |
2581 | _ACEOF | |
2582 | ||
2583 | # Some tools Automake needs. | |
2584 | ||
2585 | ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"} | |
2586 | ||
2587 | ||
2588 | AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"} | |
2589 | ||
2590 | ||
2591 | AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"} | |
2592 | ||
2593 | ||
2594 | AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"} | |
2595 | ||
2596 | ||
2597 | MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"} | |
2598 | ||
2599 | # We need awk for the "check" target. The system "awk" is bad on | |
2600 | # some platforms. | |
2601 | # Always define AMTAR for backward compatibility. | |
2602 | ||
2603 | AMTAR=${AMTAR-"${am_missing_run}tar"} | |
2604 | ||
2605 | am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -' | |
2606 | ||
2607 | ||
2608 | ||
2609 | ||
2610 | ||
2611 | ||
2612 | ||
2613 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 | |
2614 | $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } | |
2615 | # Check whether --enable-maintainer-mode was given. | |
2616 | if test "${enable_maintainer_mode+set}" = set; then : | |
2617 | enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval | |
2618 | else | |
2619 | USE_MAINTAINER_MODE=no | |
2620 | fi | |
2621 | ||
2622 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_MAINTAINER_MODE" >&5 | |
2623 | $as_echo "$USE_MAINTAINER_MODE" >&6; } | |
2624 | if test $USE_MAINTAINER_MODE = yes; then | |
2625 | MAINTAINER_MODE_TRUE= | |
2626 | MAINTAINER_MODE_FALSE='#' | |
2627 | else | |
2628 | MAINTAINER_MODE_TRUE='#' | |
2629 | MAINTAINER_MODE_FALSE= | |
2630 | fi | |
2631 | ||
2632 | MAINT=$MAINTAINER_MODE_TRUE | |
2633 | ||
2634 | ||
2635 | ||
2636 | # Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS | |
2637 | ||
2638 | ||
2639 | ||
2640 | ||
2641 | ||
2642 | ||
2643 | ||
2644 | ||
2645 | ||
2646 | ||
2647 | ||
2648 | DEPDIR="${am__leading_dot}deps" | |
2649 | ||
2650 | ac_config_commands="$ac_config_commands depfiles" | |
2651 | ||
2652 | ||
2653 | am_make=${MAKE-make} | |
2654 | cat > confinc << 'END' | |
2655 | am__doit: | |
2656 | @echo this is the am__doit target | |
2657 | .PHONY: am__doit | |
2658 | END | |
2659 | # If we don't find an include directive, just comment out the code. | |
2660 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5 | |
2661 | $as_echo_n "checking for style of include used by $am_make... " >&6; } | |
2662 | am__include="#" | |
2663 | am__quote= | |
2664 | _am_result=none | |
2665 | # First try GNU make style include. | |
2666 | echo "include confinc" > confmf | |
2667 | # Ignore all kinds of additional output from `make'. | |
2668 | case `$am_make -s -f confmf 2> /dev/null` in #( | |
2669 | *the\ am__doit\ target*) | |
2670 | am__include=include | |
2671 | am__quote= | |
2672 | _am_result=GNU | |
2673 | ;; | |
2674 | esac | |
2675 | # Now try BSD make style include. | |
2676 | if test "$am__include" = "#"; then | |
2677 | echo '.include "confinc"' > confmf | |
2678 | case `$am_make -s -f confmf 2> /dev/null` in #( | |
2679 | *the\ am__doit\ target*) | |
2680 | am__include=.include | |
2681 | am__quote="\"" | |
2682 | _am_result=BSD | |
2683 | ;; | |
2684 | esac | |
2685 | fi | |
2686 | ||
2687 | ||
2688 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5 | |
2689 | $as_echo "$_am_result" >&6; } | |
2690 | rm -f confinc confmf | |
2691 | ||
2692 | # Check whether --enable-dependency-tracking was given. | |
2693 | if test "${enable_dependency_tracking+set}" = set; then : | |
2694 | enableval=$enable_dependency_tracking; | |
2695 | fi | |
2696 | ||
2697 | if test "x$enable_dependency_tracking" != xno; then | |
2698 | am_depcomp="$ac_aux_dir/depcomp" | |
2699 | AMDEPBACKSLASH='\' | |
2700 | fi | |
2701 | if test "x$enable_dependency_tracking" != xno; then | |
2702 | AMDEP_TRUE= | |
2703 | AMDEP_FALSE='#' | |
2704 | else | |
2705 | AMDEP_TRUE='#' | |
2706 | AMDEP_FALSE= | |
2707 | fi | |
2708 | ||
2709 | ||
2710 | ac_ext=c | |
2711 | ac_cpp='$CPP $CPPFLAGS' | |
2712 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
2713 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
2714 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
2715 | if test -n "$ac_tool_prefix"; then | |
2716 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. | |
2717 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 | |
2718 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2719 | $as_echo_n "checking for $ac_word... " >&6; } | |
2720 | if ${ac_cv_prog_CC+:} false; then : | |
2721 | $as_echo_n "(cached) " >&6 | |
2722 | else | |
2723 | if test -n "$CC"; then | |
2724 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2725 | else | |
2726 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2727 | for as_dir in $PATH | |
2728 | do | |
2729 | IFS=$as_save_IFS | |
2730 | test -z "$as_dir" && as_dir=. | |
2731 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2732 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2733 | ac_cv_prog_CC="${ac_tool_prefix}gcc" | |
2734 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2735 | break 2 | |
2736 | fi | |
2737 | done | |
2738 | done | |
2739 | IFS=$as_save_IFS | |
2740 | ||
2741 | fi | |
2742 | fi | |
2743 | CC=$ac_cv_prog_CC | |
2744 | if test -n "$CC"; then | |
2745 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
2746 | $as_echo "$CC" >&6; } | |
2747 | else | |
2748 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2749 | $as_echo "no" >&6; } | |
2750 | fi | |
2751 | ||
2752 | ||
2753 | fi | |
2754 | if test -z "$ac_cv_prog_CC"; then | |
2755 | ac_ct_CC=$CC | |
2756 | # Extract the first word of "gcc", so it can be a program name with args. | |
2757 | set dummy gcc; ac_word=$2 | |
2758 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2759 | $as_echo_n "checking for $ac_word... " >&6; } | |
2760 | if ${ac_cv_prog_ac_ct_CC+:} false; then : | |
2761 | $as_echo_n "(cached) " >&6 | |
2762 | else | |
2763 | if test -n "$ac_ct_CC"; then | |
2764 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
2765 | else | |
2766 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2767 | for as_dir in $PATH | |
2768 | do | |
2769 | IFS=$as_save_IFS | |
2770 | test -z "$as_dir" && as_dir=. | |
2771 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2772 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2773 | ac_cv_prog_ac_ct_CC="gcc" | |
2774 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2775 | break 2 | |
2776 | fi | |
2777 | done | |
2778 | done | |
2779 | IFS=$as_save_IFS | |
2780 | ||
2781 | fi | |
2782 | fi | |
2783 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
2784 | if test -n "$ac_ct_CC"; then | |
2785 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 | |
2786 | $as_echo "$ac_ct_CC" >&6; } | |
2787 | else | |
2788 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2789 | $as_echo "no" >&6; } | |
2790 | fi | |
2791 | ||
2792 | if test "x$ac_ct_CC" = x; then | |
2793 | CC="" | |
2794 | else | |
2795 | case $cross_compiling:$ac_tool_warned in | |
2796 | yes:) | |
2797 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
2798 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
2799 | ac_tool_warned=yes ;; | |
2800 | esac | |
2801 | CC=$ac_ct_CC | |
2802 | fi | |
2803 | else | |
2804 | CC="$ac_cv_prog_CC" | |
2805 | fi | |
2806 | ||
2807 | if test -z "$CC"; then | |
2808 | if test -n "$ac_tool_prefix"; then | |
2809 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. | |
2810 | set dummy ${ac_tool_prefix}cc; ac_word=$2 | |
2811 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2812 | $as_echo_n "checking for $ac_word... " >&6; } | |
2813 | if ${ac_cv_prog_CC+:} false; then : | |
2814 | $as_echo_n "(cached) " >&6 | |
2815 | else | |
2816 | if test -n "$CC"; then | |
2817 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2818 | else | |
2819 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2820 | for as_dir in $PATH | |
2821 | do | |
2822 | IFS=$as_save_IFS | |
2823 | test -z "$as_dir" && as_dir=. | |
2824 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2825 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2826 | ac_cv_prog_CC="${ac_tool_prefix}cc" | |
2827 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2828 | break 2 | |
2829 | fi | |
2830 | done | |
2831 | done | |
2832 | IFS=$as_save_IFS | |
2833 | ||
2834 | fi | |
2835 | fi | |
2836 | CC=$ac_cv_prog_CC | |
2837 | if test -n "$CC"; then | |
2838 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
2839 | $as_echo "$CC" >&6; } | |
2840 | else | |
2841 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2842 | $as_echo "no" >&6; } | |
2843 | fi | |
2844 | ||
2845 | ||
2846 | fi | |
2847 | fi | |
2848 | if test -z "$CC"; then | |
2849 | # Extract the first word of "cc", so it can be a program name with args. | |
2850 | set dummy cc; ac_word=$2 | |
2851 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2852 | $as_echo_n "checking for $ac_word... " >&6; } | |
2853 | if ${ac_cv_prog_CC+:} false; then : | |
2854 | $as_echo_n "(cached) " >&6 | |
2855 | else | |
2856 | if test -n "$CC"; then | |
2857 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2858 | else | |
2859 | ac_prog_rejected=no | |
2860 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2861 | for as_dir in $PATH | |
2862 | do | |
2863 | IFS=$as_save_IFS | |
2864 | test -z "$as_dir" && as_dir=. | |
2865 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2866 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2867 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then | |
2868 | ac_prog_rejected=yes | |
2869 | continue | |
2870 | fi | |
2871 | ac_cv_prog_CC="cc" | |
2872 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2873 | break 2 | |
2874 | fi | |
2875 | done | |
2876 | done | |
2877 | IFS=$as_save_IFS | |
2878 | ||
2879 | if test $ac_prog_rejected = yes; then | |
2880 | # We found a bogon in the path, so make sure we never use it. | |
2881 | set dummy $ac_cv_prog_CC | |
2882 | shift | |
2883 | if test $# != 0; then | |
2884 | # We chose a different compiler from the bogus one. | |
2885 | # However, it has the same basename, so the bogon will be chosen | |
2886 | # first if we set CC to just the basename; use the full file name. | |
2887 | shift | |
2888 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" | |
2889 | fi | |
2890 | fi | |
2891 | fi | |
2892 | fi | |
2893 | CC=$ac_cv_prog_CC | |
2894 | if test -n "$CC"; then | |
2895 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
2896 | $as_echo "$CC" >&6; } | |
2897 | else | |
2898 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2899 | $as_echo "no" >&6; } | |
2900 | fi | |
2901 | ||
2902 | ||
2903 | fi | |
2904 | if test -z "$CC"; then | |
2905 | if test -n "$ac_tool_prefix"; then | |
2906 | for ac_prog in cl.exe | |
2907 | do | |
2908 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
2909 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
2910 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2911 | $as_echo_n "checking for $ac_word... " >&6; } | |
2912 | if ${ac_cv_prog_CC+:} false; then : | |
2913 | $as_echo_n "(cached) " >&6 | |
2914 | else | |
2915 | if test -n "$CC"; then | |
2916 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
2917 | else | |
2918 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2919 | for as_dir in $PATH | |
2920 | do | |
2921 | IFS=$as_save_IFS | |
2922 | test -z "$as_dir" && as_dir=. | |
2923 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2924 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2925 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" | |
2926 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2927 | break 2 | |
2928 | fi | |
2929 | done | |
2930 | done | |
2931 | IFS=$as_save_IFS | |
2932 | ||
2933 | fi | |
2934 | fi | |
2935 | CC=$ac_cv_prog_CC | |
2936 | if test -n "$CC"; then | |
2937 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
2938 | $as_echo "$CC" >&6; } | |
2939 | else | |
2940 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2941 | $as_echo "no" >&6; } | |
2942 | fi | |
2943 | ||
2944 | ||
2945 | test -n "$CC" && break | |
2946 | done | |
2947 | fi | |
2948 | if test -z "$CC"; then | |
2949 | ac_ct_CC=$CC | |
2950 | for ac_prog in cl.exe | |
2951 | do | |
2952 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
2953 | set dummy $ac_prog; ac_word=$2 | |
2954 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2955 | $as_echo_n "checking for $ac_word... " >&6; } | |
2956 | if ${ac_cv_prog_ac_ct_CC+:} false; then : | |
2957 | $as_echo_n "(cached) " >&6 | |
2958 | else | |
2959 | if test -n "$ac_ct_CC"; then | |
2960 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
2961 | else | |
2962 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2963 | for as_dir in $PATH | |
2964 | do | |
2965 | IFS=$as_save_IFS | |
2966 | test -z "$as_dir" && as_dir=. | |
2967 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2968 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
2969 | ac_cv_prog_ac_ct_CC="$ac_prog" | |
2970 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2971 | break 2 | |
2972 | fi | |
2973 | done | |
2974 | done | |
2975 | IFS=$as_save_IFS | |
2976 | ||
2977 | fi | |
2978 | fi | |
2979 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
2980 | if test -n "$ac_ct_CC"; then | |
2981 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 | |
2982 | $as_echo "$ac_ct_CC" >&6; } | |
2983 | else | |
2984 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2985 | $as_echo "no" >&6; } | |
2986 | fi | |
2987 | ||
2988 | ||
2989 | test -n "$ac_ct_CC" && break | |
2990 | done | |
2991 | ||
2992 | if test "x$ac_ct_CC" = x; then | |
2993 | CC="" | |
2994 | else | |
2995 | case $cross_compiling:$ac_tool_warned in | |
2996 | yes:) | |
2997 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
2998 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
2999 | ac_tool_warned=yes ;; | |
3000 | esac | |
3001 | CC=$ac_ct_CC | |
3002 | fi | |
3003 | fi | |
3004 | ||
3005 | fi | |
3006 | ||
3007 | ||
3008 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3009 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3010 | as_fn_error $? "no acceptable C compiler found in \$PATH | |
3011 | See \`config.log' for more details" "$LINENO" 5; } | |
3012 | ||
3013 | # Provide some information about the compiler. | |
3014 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 | |
3015 | set X $ac_compile | |
3016 | ac_compiler=$2 | |
3017 | for ac_option in --version -v -V -qversion; do | |
3018 | { { ac_try="$ac_compiler $ac_option >&5" | |
3019 | case "(($ac_try" in | |
3020 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3021 | *) ac_try_echo=$ac_try;; | |
3022 | esac | |
3023 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3024 | $as_echo "$ac_try_echo"; } >&5 | |
3025 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err | |
3026 | ac_status=$? | |
3027 | if test -s conftest.err; then | |
3028 | sed '10a\ | |
3029 | ... rest of stderr output deleted ... | |
3030 | 10q' conftest.err >conftest.er1 | |
3031 | cat conftest.er1 >&5 | |
3032 | fi | |
3033 | rm -f conftest.er1 conftest.err | |
3034 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3035 | test $ac_status = 0; } | |
3036 | done | |
3037 | ||
3038 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3039 | /* end confdefs.h. */ | |
3040 | ||
3041 | int | |
3042 | main () | |
3043 | { | |
3044 | ||
3045 | ; | |
3046 | return 0; | |
3047 | } | |
3048 | _ACEOF | |
3049 | ac_clean_files_save=$ac_clean_files | |
3050 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" | |
3051 | # Try to create an executable without -o first, disregard a.out. | |
3052 | # It will help us diagnose broken compilers, and finding out an intuition | |
3053 | # of exeext. | |
3054 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 | |
3055 | $as_echo_n "checking whether the C compiler works... " >&6; } | |
3056 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` | |
3057 | ||
3058 | # The possible output files: | |
3059 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" | |
3060 | ||
3061 | ac_rmfiles= | |
3062 | for ac_file in $ac_files | |
3063 | do | |
3064 | case $ac_file in | |
3065 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
3066 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; | |
3067 | esac | |
3068 | done | |
3069 | rm -f $ac_rmfiles | |
3070 | ||
3071 | if { { ac_try="$ac_link_default" | |
3072 | case "(($ac_try" in | |
3073 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3074 | *) ac_try_echo=$ac_try;; | |
3075 | esac | |
3076 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3077 | $as_echo "$ac_try_echo"; } >&5 | |
3078 | (eval "$ac_link_default") 2>&5 | |
3079 | ac_status=$? | |
3080 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3081 | test $ac_status = 0; }; then : | |
3082 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. | |
3083 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' | |
3084 | # in a Makefile. We should not override ac_cv_exeext if it was cached, | |
3085 | # so that the user can short-circuit this test for compilers unknown to | |
3086 | # Autoconf. | |
3087 | for ac_file in $ac_files '' | |
3088 | do | |
3089 | test -f "$ac_file" || continue | |
3090 | case $ac_file in | |
3091 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) | |
3092 | ;; | |
3093 | [ab].out ) | |
3094 | # We found the default executable, but exeext='' is most | |
3095 | # certainly right. | |
3096 | break;; | |
3097 | *.* ) | |
3098 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; | |
3099 | then :; else | |
3100 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
3101 | fi | |
3102 | # We set ac_cv_exeext here because the later test for it is not | |
3103 | # safe: cross compilers may not add the suffix if given an `-o' | |
3104 | # argument, so we may need to know it at that point already. | |
3105 | # Even if this section looks crufty: it has the advantage of | |
3106 | # actually working. | |
3107 | break;; | |
3108 | * ) | |
3109 | break;; | |
3110 | esac | |
3111 | done | |
3112 | test "$ac_cv_exeext" = no && ac_cv_exeext= | |
3113 | ||
3114 | else | |
3115 | ac_file='' | |
3116 | fi | |
3117 | if test -z "$ac_file"; then : | |
3118 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3119 | $as_echo "no" >&6; } | |
3120 | $as_echo "$as_me: failed program was:" >&5 | |
3121 | sed 's/^/| /' conftest.$ac_ext >&5 | |
3122 | ||
3123 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3124 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3125 | as_fn_error 77 "C compiler cannot create executables | |
3126 | See \`config.log' for more details" "$LINENO" 5; } | |
3127 | else | |
3128 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
3129 | $as_echo "yes" >&6; } | |
3130 | fi | |
3131 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 | |
3132 | $as_echo_n "checking for C compiler default output file name... " >&6; } | |
3133 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 | |
3134 | $as_echo "$ac_file" >&6; } | |
3135 | ac_exeext=$ac_cv_exeext | |
3136 | ||
3137 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out | |
3138 | ac_clean_files=$ac_clean_files_save | |
3139 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 | |
3140 | $as_echo_n "checking for suffix of executables... " >&6; } | |
3141 | if { { ac_try="$ac_link" | |
3142 | case "(($ac_try" in | |
3143 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3144 | *) ac_try_echo=$ac_try;; | |
3145 | esac | |
3146 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3147 | $as_echo "$ac_try_echo"; } >&5 | |
3148 | (eval "$ac_link") 2>&5 | |
3149 | ac_status=$? | |
3150 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3151 | test $ac_status = 0; }; then : | |
3152 | # If both `conftest.exe' and `conftest' are `present' (well, observable) | |
3153 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will | |
3154 | # work properly (i.e., refer to `conftest.exe'), while it won't with | |
3155 | # `rm'. | |
3156 | for ac_file in conftest.exe conftest conftest.*; do | |
3157 | test -f "$ac_file" || continue | |
3158 | case $ac_file in | |
3159 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
3160 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
3161 | break;; | |
3162 | * ) break;; | |
3163 | esac | |
3164 | done | |
3165 | else | |
3166 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3167 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3168 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link | |
3169 | See \`config.log' for more details" "$LINENO" 5; } | |
3170 | fi | |
3171 | rm -f conftest conftest$ac_cv_exeext | |
3172 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 | |
3173 | $as_echo "$ac_cv_exeext" >&6; } | |
3174 | ||
3175 | rm -f conftest.$ac_ext | |
3176 | EXEEXT=$ac_cv_exeext | |
3177 | ac_exeext=$EXEEXT | |
3178 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3179 | /* end confdefs.h. */ | |
3180 | #include <stdio.h> | |
3181 | int | |
3182 | main () | |
3183 | { | |
3184 | FILE *f = fopen ("conftest.out", "w"); | |
3185 | return ferror (f) || fclose (f) != 0; | |
3186 | ||
3187 | ; | |
3188 | return 0; | |
3189 | } | |
3190 | _ACEOF | |
3191 | ac_clean_files="$ac_clean_files conftest.out" | |
3192 | # Check that the compiler produces executables we can run. If not, either | |
3193 | # the compiler is broken, or we cross compile. | |
3194 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 | |
3195 | $as_echo_n "checking whether we are cross compiling... " >&6; } | |
3196 | if test "$cross_compiling" != yes; then | |
3197 | { { ac_try="$ac_link" | |
3198 | case "(($ac_try" in | |
3199 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3200 | *) ac_try_echo=$ac_try;; | |
3201 | esac | |
3202 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3203 | $as_echo "$ac_try_echo"; } >&5 | |
3204 | (eval "$ac_link") 2>&5 | |
3205 | ac_status=$? | |
3206 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3207 | test $ac_status = 0; } | |
3208 | if { ac_try='./conftest$ac_cv_exeext' | |
3209 | { { case "(($ac_try" in | |
3210 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3211 | *) ac_try_echo=$ac_try;; | |
3212 | esac | |
3213 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3214 | $as_echo "$ac_try_echo"; } >&5 | |
3215 | (eval "$ac_try") 2>&5 | |
3216 | ac_status=$? | |
3217 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3218 | test $ac_status = 0; }; }; then | |
3219 | cross_compiling=no | |
3220 | else | |
3221 | if test "$cross_compiling" = maybe; then | |
3222 | cross_compiling=yes | |
3223 | else | |
3224 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3225 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3226 | as_fn_error $? "cannot run C compiled programs. | |
3227 | If you meant to cross compile, use \`--host'. | |
3228 | See \`config.log' for more details" "$LINENO" 5; } | |
3229 | fi | |
3230 | fi | |
3231 | fi | |
3232 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 | |
3233 | $as_echo "$cross_compiling" >&6; } | |
3234 | ||
3235 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out | |
3236 | ac_clean_files=$ac_clean_files_save | |
3237 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 | |
3238 | $as_echo_n "checking for suffix of object files... " >&6; } | |
3239 | if ${ac_cv_objext+:} false; then : | |
3240 | $as_echo_n "(cached) " >&6 | |
3241 | else | |
3242 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3243 | /* end confdefs.h. */ | |
3244 | ||
3245 | int | |
3246 | main () | |
3247 | { | |
3248 | ||
3249 | ; | |
3250 | return 0; | |
3251 | } | |
3252 | _ACEOF | |
3253 | rm -f conftest.o conftest.obj | |
3254 | if { { ac_try="$ac_compile" | |
3255 | case "(($ac_try" in | |
3256 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3257 | *) ac_try_echo=$ac_try;; | |
3258 | esac | |
3259 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3260 | $as_echo "$ac_try_echo"; } >&5 | |
3261 | (eval "$ac_compile") 2>&5 | |
3262 | ac_status=$? | |
3263 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3264 | test $ac_status = 0; }; then : | |
3265 | for ac_file in conftest.o conftest.obj conftest.*; do | |
3266 | test -f "$ac_file" || continue; | |
3267 | case $ac_file in | |
3268 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; | |
3269 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` | |
3270 | break;; | |
3271 | esac | |
3272 | done | |
3273 | else | |
3274 | $as_echo "$as_me: failed program was:" >&5 | |
3275 | sed 's/^/| /' conftest.$ac_ext >&5 | |
3276 | ||
3277 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3278 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3279 | as_fn_error $? "cannot compute suffix of object files: cannot compile | |
3280 | See \`config.log' for more details" "$LINENO" 5; } | |
3281 | fi | |
3282 | rm -f conftest.$ac_cv_objext conftest.$ac_ext | |
3283 | fi | |
3284 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 | |
3285 | $as_echo "$ac_cv_objext" >&6; } | |
3286 | OBJEXT=$ac_cv_objext | |
3287 | ac_objext=$OBJEXT | |
3288 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 | |
3289 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } | |
3290 | if ${ac_cv_c_compiler_gnu+:} false; then : | |
3291 | $as_echo_n "(cached) " >&6 | |
3292 | else | |
3293 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3294 | /* end confdefs.h. */ | |
3295 | ||
3296 | int | |
3297 | main () | |
3298 | { | |
3299 | #ifndef __GNUC__ | |
3300 | choke me | |
3301 | #endif | |
3302 | ||
3303 | ; | |
3304 | return 0; | |
3305 | } | |
3306 | _ACEOF | |
3307 | if ac_fn_c_try_compile "$LINENO"; then : | |
3308 | ac_compiler_gnu=yes | |
3309 | else | |
3310 | ac_compiler_gnu=no | |
3311 | fi | |
3312 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
3313 | ac_cv_c_compiler_gnu=$ac_compiler_gnu | |
3314 | ||
3315 | fi | |
3316 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 | |
3317 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } | |
3318 | if test $ac_compiler_gnu = yes; then | |
3319 | GCC=yes | |
3320 | else | |
3321 | GCC= | |
3322 | fi | |
3323 | ac_test_CFLAGS=${CFLAGS+set} | |
3324 | ac_save_CFLAGS=$CFLAGS | |
3325 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 | |
3326 | $as_echo_n "checking whether $CC accepts -g... " >&6; } | |
3327 | if ${ac_cv_prog_cc_g+:} false; then : | |
3328 | $as_echo_n "(cached) " >&6 | |
3329 | else | |
3330 | ac_save_c_werror_flag=$ac_c_werror_flag | |
3331 | ac_c_werror_flag=yes | |
3332 | ac_cv_prog_cc_g=no | |
3333 | CFLAGS="-g" | |
3334 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3335 | /* end confdefs.h. */ | |
3336 | ||
3337 | int | |
3338 | main () | |
3339 | { | |
3340 | ||
3341 | ; | |
3342 | return 0; | |
3343 | } | |
3344 | _ACEOF | |
3345 | if ac_fn_c_try_compile "$LINENO"; then : | |
3346 | ac_cv_prog_cc_g=yes | |
3347 | else | |
3348 | CFLAGS="" | |
3349 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3350 | /* end confdefs.h. */ | |
3351 | ||
3352 | int | |
3353 | main () | |
3354 | { | |
3355 | ||
3356 | ; | |
3357 | return 0; | |
3358 | } | |
3359 | _ACEOF | |
3360 | if ac_fn_c_try_compile "$LINENO"; then : | |
3361 | ||
3362 | else | |
3363 | ac_c_werror_flag=$ac_save_c_werror_flag | |
3364 | CFLAGS="-g" | |
3365 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3366 | /* end confdefs.h. */ | |
3367 | ||
3368 | int | |
3369 | main () | |
3370 | { | |
3371 | ||
3372 | ; | |
3373 | return 0; | |
3374 | } | |
3375 | _ACEOF | |
3376 | if ac_fn_c_try_compile "$LINENO"; then : | |
3377 | ac_cv_prog_cc_g=yes | |
3378 | fi | |
3379 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
3380 | fi | |
3381 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
3382 | fi | |
3383 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
3384 | ac_c_werror_flag=$ac_save_c_werror_flag | |
3385 | fi | |
3386 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 | |
3387 | $as_echo "$ac_cv_prog_cc_g" >&6; } | |
3388 | if test "$ac_test_CFLAGS" = set; then | |
3389 | CFLAGS=$ac_save_CFLAGS | |
3390 | elif test $ac_cv_prog_cc_g = yes; then | |
3391 | if test "$GCC" = yes; then | |
3392 | CFLAGS="-g -O2" | |
3393 | else | |
3394 | CFLAGS="-g" | |
3395 | fi | |
3396 | else | |
3397 | if test "$GCC" = yes; then | |
3398 | CFLAGS="-O2" | |
3399 | else | |
3400 | CFLAGS= | |
3401 | fi | |
3402 | fi | |
3403 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 | |
3404 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } | |
3405 | if ${ac_cv_prog_cc_c89+:} false; then : | |
3406 | $as_echo_n "(cached) " >&6 | |
3407 | else | |
3408 | ac_cv_prog_cc_c89=no | |
3409 | ac_save_CC=$CC | |
3410 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3411 | /* end confdefs.h. */ | |
3412 | #include <stdarg.h> | |
3413 | #include <stdio.h> | |
3414 | #include <sys/types.h> | |
3415 | #include <sys/stat.h> | |
3416 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ | |
3417 | struct buf { int x; }; | |
3418 | FILE * (*rcsopen) (struct buf *, struct stat *, int); | |
3419 | static char *e (p, i) | |
3420 | char **p; | |
3421 | int i; | |
3422 | { | |
3423 | return p[i]; | |
3424 | } | |
3425 | static char *f (char * (*g) (char **, int), char **p, ...) | |
3426 | { | |
3427 | char *s; | |
3428 | va_list v; | |
3429 | va_start (v,p); | |
3430 | s = g (p, va_arg (v,int)); | |
3431 | va_end (v); | |
3432 | return s; | |
3433 | } | |
3434 | ||
3435 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has | |
3436 | function prototypes and stuff, but not '\xHH' hex character constants. | |
3437 | These don't provoke an error unfortunately, instead are silently treated | |
3438 | as 'x'. The following induces an error, until -std is added to get | |
3439 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an | |
3440 | array size at least. It's necessary to write '\x00'==0 to get something | |
3441 | that's true only with -std. */ | |
3442 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; | |
3443 | ||
3444 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters | |
3445 | inside strings and character constants. */ | |
3446 | #define FOO(x) 'x' | |
3447 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; | |
3448 | ||
3449 | int test (int i, double x); | |
3450 | struct s1 {int (*f) (int a);}; | |
3451 | struct s2 {int (*f) (double a);}; | |
3452 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); | |
3453 | int argc; | |
3454 | char **argv; | |
3455 | int | |
3456 | main () | |
3457 | { | |
3458 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; | |
3459 | ; | |
3460 | return 0; | |
3461 | } | |
3462 | _ACEOF | |
3463 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ | |
3464 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
3465 | do | |
3466 | CC="$ac_save_CC $ac_arg" | |
3467 | if ac_fn_c_try_compile "$LINENO"; then : | |
3468 | ac_cv_prog_cc_c89=$ac_arg | |
3469 | fi | |
3470 | rm -f core conftest.err conftest.$ac_objext | |
3471 | test "x$ac_cv_prog_cc_c89" != "xno" && break | |
3472 | done | |
3473 | rm -f conftest.$ac_ext | |
3474 | CC=$ac_save_CC | |
3475 | ||
3476 | fi | |
3477 | # AC_CACHE_VAL | |
3478 | case "x$ac_cv_prog_cc_c89" in | |
3479 | x) | |
3480 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 | |
3481 | $as_echo "none needed" >&6; } ;; | |
3482 | xno) | |
3483 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 | |
3484 | $as_echo "unsupported" >&6; } ;; | |
3485 | *) | |
3486 | CC="$CC $ac_cv_prog_cc_c89" | |
3487 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 | |
3488 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; | |
3489 | esac | |
3490 | if test "x$ac_cv_prog_cc_c89" != xno; then : | |
3491 | ||
3492 | fi | |
3493 | ||
3494 | ac_ext=c | |
3495 | ac_cpp='$CPP $CPPFLAGS' | |
3496 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3497 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3498 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3499 | ||
3500 | depcc="$CC" am_compiler_list= | |
3501 | ||
3502 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5 | |
3503 | $as_echo_n "checking dependency style of $depcc... " >&6; } | |
3504 | if ${am_cv_CC_dependencies_compiler_type+:} false; then : | |
3505 | $as_echo_n "(cached) " >&6 | |
3506 | else | |
3507 | if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then | |
3508 | # We make a subdir and do the tests there. Otherwise we can end up | |
3509 | # making bogus files that we don't know about and never remove. For | |
3510 | # instance it was reported that on HP-UX the gcc test will end up | |
3511 | # making a dummy file named `D' -- because `-MD' means `put the output | |
3512 | # in D'. | |
3513 | mkdir conftest.dir | |
3514 | # Copy depcomp to subdir because otherwise we won't find it if we're | |
3515 | # using a relative directory. | |
3516 | cp "$am_depcomp" conftest.dir | |
3517 | cd conftest.dir | |
3518 | # We will build objects and dependencies in a subdirectory because | |
3519 | # it helps to detect inapplicable dependency modes. For instance | |
3520 | # both Tru64's cc and ICC support -MD to output dependencies as a | |
3521 | # side effect of compilation, but ICC will put the dependencies in | |
3522 | # the current directory while Tru64 will put them in the object | |
3523 | # directory. | |
3524 | mkdir sub | |
3525 | ||
3526 | am_cv_CC_dependencies_compiler_type=none | |
3527 | if test "$am_compiler_list" = ""; then | |
3528 | am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp` | |
3529 | fi | |
3530 | am__universal=false | |
3531 | case " $depcc " in #( | |
3532 | *\ -arch\ *\ -arch\ *) am__universal=true ;; | |
3533 | esac | |
3534 | ||
3535 | for depmode in $am_compiler_list; do | |
3536 | # Setup a source with many dependencies, because some compilers | |
3537 | # like to wrap large dependency lists on column 80 (with \), and | |
3538 | # we should not choose a depcomp mode which is confused by this. | |
3539 | # | |
3540 | # We need to recreate these files for each test, as the compiler may | |
3541 | # overwrite some of them when testing with obscure command lines. | |
3542 | # This happens at least with the AIX C compiler. | |
3543 | : > sub/conftest.c | |
3544 | for i in 1 2 3 4 5 6; do | |
3545 | echo '#include "conftst'$i'.h"' >> sub/conftest.c | |
3546 | # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with | |
3547 | # Solaris 8's {/usr,}/bin/sh. | |
3548 | touch sub/conftst$i.h | |
3549 | done | |
3550 | echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf | |
3551 | ||
3552 | # We check with `-c' and `-o' for the sake of the "dashmstdout" | |
3553 | # mode. It turns out that the SunPro C++ compiler does not properly | |
3554 | # handle `-M -o', and we need to detect this. Also, some Intel | |
3555 | # versions had trouble with output in subdirs | |
3556 | am__obj=sub/conftest.${OBJEXT-o} | |
3557 | am__minus_obj="-o $am__obj" | |
3558 | case $depmode in | |
3559 | gcc) | |
3560 | # This depmode causes a compiler race in universal mode. | |
3561 | test "$am__universal" = false || continue | |
3562 | ;; | |
3563 | nosideeffect) | |
3564 | # after this tag, mechanisms are not by side-effect, so they'll | |
3565 | # only be used when explicitly requested | |
3566 | if test "x$enable_dependency_tracking" = xyes; then | |
3567 | continue | |
3568 | else | |
3569 | break | |
3570 | fi | |
3571 | ;; | |
3572 | msvisualcpp | msvcmsys) | |
3573 | # This compiler won't grok `-c -o', but also, the minuso test has | |
3574 | # not run yet. These depmodes are late enough in the game, and | |
3575 | # so weak that their functioning should not be impacted. | |
3576 | am__obj=conftest.${OBJEXT-o} | |
3577 | am__minus_obj= | |
3578 | ;; | |
3579 | none) break ;; | |
3580 | esac | |
3581 | if depmode=$depmode \ | |
3582 | source=sub/conftest.c object=$am__obj \ | |
3583 | depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \ | |
3584 | $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \ | |
3585 | >/dev/null 2>conftest.err && | |
3586 | grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 && | |
3587 | grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 && | |
3588 | grep $am__obj sub/conftest.Po > /dev/null 2>&1 && | |
3589 | ${MAKE-make} -s -f confmf > /dev/null 2>&1; then | |
3590 | # icc doesn't choke on unknown options, it will just issue warnings | |
3591 | # or remarks (even with -Werror). So we grep stderr for any message | |
3592 | # that says an option was ignored or not supported. | |
3593 | # When given -MP, icc 7.0 and 7.1 complain thusly: | |
3594 | # icc: Command line warning: ignoring option '-M'; no argument required | |
3595 | # The diagnosis changed in icc 8.0: | |
3596 | # icc: Command line remark: option '-MP' not supported | |
3597 | if (grep 'ignoring option' conftest.err || | |
3598 | grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else | |
3599 | am_cv_CC_dependencies_compiler_type=$depmode | |
3600 | break | |
3601 | fi | |
3602 | fi | |
3603 | done | |
3604 | ||
3605 | cd .. | |
3606 | rm -rf conftest.dir | |
3607 | else | |
3608 | am_cv_CC_dependencies_compiler_type=none | |
3609 | fi | |
3610 | ||
3611 | fi | |
3612 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5 | |
3613 | $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; } | |
3614 | CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type | |
3615 | ||
3616 | if | |
3617 | test "x$enable_dependency_tracking" != xno \ | |
3618 | && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then | |
3619 | am__fastdepCC_TRUE= | |
3620 | am__fastdepCC_FALSE='#' | |
3621 | else | |
3622 | am__fastdepCC_TRUE='#' | |
3623 | am__fastdepCC_FALSE= | |
3624 | fi | |
3625 | ||
3626 | ||
3627 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5 | |
3628 | $as_echo_n "checking for $CC option to accept ISO C99... " >&6; } | |
3629 | if ${ac_cv_prog_cc_c99+:} false; then : | |
3630 | $as_echo_n "(cached) " >&6 | |
3631 | else | |
3632 | ac_cv_prog_cc_c99=no | |
3633 | ac_save_CC=$CC | |
3634 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3635 | /* end confdefs.h. */ | |
3636 | #include <stdarg.h> | |
3637 | #include <stdbool.h> | |
3638 | #include <stdlib.h> | |
3639 | #include <wchar.h> | |
3640 | #include <stdio.h> | |
3641 | ||
3642 | // Check varargs macros. These examples are taken from C99 6.10.3.5. | |
3643 | #define debug(...) fprintf (stderr, __VA_ARGS__) | |
3644 | #define showlist(...) puts (#__VA_ARGS__) | |
3645 | #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__)) | |
3646 | static void | |
3647 | test_varargs_macros (void) | |
3648 | { | |
3649 | int x = 1234; | |
3650 | int y = 5678; | |
3651 | debug ("Flag"); | |
3652 | debug ("X = %d\n", x); | |
3653 | showlist (The first, second, and third items.); | |
3654 | report (x>y, "x is %d but y is %d", x, y); | |
3655 | } | |
3656 | ||
3657 | // Check long long types. | |
3658 | #define BIG64 18446744073709551615ull | |
3659 | #define BIG32 4294967295ul | |
3660 | #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0) | |
3661 | #if !BIG_OK | |
3662 | your preprocessor is broken; | |
3663 | #endif | |
3664 | #if BIG_OK | |
3665 | #else | |
3666 | your preprocessor is broken; | |
3667 | #endif | |
3668 | static long long int bignum = -9223372036854775807LL; | |
3669 | static unsigned long long int ubignum = BIG64; | |
3670 | ||
3671 | struct incomplete_array | |
3672 | { | |
3673 | int datasize; | |
3674 | double data[]; | |
3675 | }; | |
3676 | ||
3677 | struct named_init { | |
3678 | int number; | |
3679 | const wchar_t *name; | |
3680 | double average; | |
3681 | }; | |
3682 | ||
3683 | typedef const char *ccp; | |
3684 | ||
3685 | static inline int | |
3686 | test_restrict (ccp restrict text) | |
3687 | { | |
3688 | // See if C++-style comments work. | |
3689 | // Iterate through items via the restricted pointer. | |
3690 | // Also check for declarations in for loops. | |
3691 | for (unsigned int i = 0; *(text+i) != '\0'; ++i) | |
3692 | continue; | |
3693 | return 0; | |
3694 | } | |
3695 | ||
3696 | // Check varargs and va_copy. | |
3697 | static void | |
3698 | test_varargs (const char *format, ...) | |
3699 | { | |
3700 | va_list args; | |
3701 | va_start (args, format); | |
3702 | va_list args_copy; | |
3703 | va_copy (args_copy, args); | |
3704 | ||
3705 | const char *str; | |
3706 | int number; | |
3707 | float fnumber; | |
3708 | ||
3709 | while (*format) | |
3710 | { | |
3711 | switch (*format++) | |
3712 | { | |
3713 | case 's': // string | |
3714 | str = va_arg (args_copy, const char *); | |
3715 | break; | |
3716 | case 'd': // int | |
3717 | number = va_arg (args_copy, int); | |
3718 | break; | |
3719 | case 'f': // float | |
3720 | fnumber = va_arg (args_copy, double); | |
3721 | break; | |
3722 | default: | |
3723 | break; | |
3724 | } | |
3725 | } | |
3726 | va_end (args_copy); | |
3727 | va_end (args); | |
3728 | } | |
3729 | ||
3730 | int | |
3731 | main () | |
3732 | { | |
3733 | ||
3734 | // Check bool. | |
3735 | _Bool success = false; | |
3736 | ||
3737 | // Check restrict. | |
3738 | if (test_restrict ("String literal") == 0) | |
3739 | success = true; | |
3740 | char *restrict newvar = "Another string"; | |
3741 | ||
3742 | // Check varargs. | |
3743 | test_varargs ("s, d' f .", "string", 65, 34.234); | |
3744 | test_varargs_macros (); | |
3745 | ||
3746 | // Check flexible array members. | |
3747 | struct incomplete_array *ia = | |
3748 | malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10)); | |
3749 | ia->datasize = 10; | |
3750 | for (int i = 0; i < ia->datasize; ++i) | |
3751 | ia->data[i] = i * 1.234; | |
3752 | ||
3753 | // Check named initializers. | |
3754 | struct named_init ni = { | |
3755 | .number = 34, | |
3756 | .name = L"Test wide string", | |
3757 | .average = 543.34343, | |
3758 | }; | |
3759 | ||
3760 | ni.number = 58; | |
3761 | ||
3762 | int dynamic_array[ni.number]; | |
3763 | dynamic_array[ni.number - 1] = 543; | |
3764 | ||
3765 | // work around unused variable warnings | |
3766 | return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x' | |
3767 | || dynamic_array[ni.number - 1] != 543); | |
3768 | ||
3769 | ; | |
3770 | return 0; | |
3771 | } | |
3772 | _ACEOF | |
3773 | for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99 | |
3774 | do | |
3775 | CC="$ac_save_CC $ac_arg" | |
3776 | if ac_fn_c_try_compile "$LINENO"; then : | |
3777 | ac_cv_prog_cc_c99=$ac_arg | |
3778 | fi | |
3779 | rm -f core conftest.err conftest.$ac_objext | |
3780 | test "x$ac_cv_prog_cc_c99" != "xno" && break | |
3781 | done | |
3782 | rm -f conftest.$ac_ext | |
3783 | CC=$ac_save_CC | |
3784 | ||
3785 | fi | |
3786 | # AC_CACHE_VAL | |
3787 | case "x$ac_cv_prog_cc_c99" in | |
3788 | x) | |
3789 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 | |
3790 | $as_echo "none needed" >&6; } ;; | |
3791 | xno) | |
3792 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 | |
3793 | $as_echo "unsupported" >&6; } ;; | |
3794 | *) | |
3795 | CC="$CC $ac_cv_prog_cc_c99" | |
3796 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5 | |
3797 | $as_echo "$ac_cv_prog_cc_c99" >&6; } ;; | |
3798 | esac | |
3799 | if test "x$ac_cv_prog_cc_c99" != xno; then : | |
3800 | ||
3801 | fi | |
3802 | ||
3803 | ||
3804 | ||
3805 | ac_ext=c | |
3806 | ac_cpp='$CPP $CPPFLAGS' | |
3807 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3808 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3809 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3810 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 | |
3811 | $as_echo_n "checking how to run the C preprocessor... " >&6; } | |
3812 | # On Suns, sometimes $CPP names a directory. | |
3813 | if test -n "$CPP" && test -d "$CPP"; then | |
3814 | CPP= | |
3815 | fi | |
3816 | if test -z "$CPP"; then | |
3817 | if ${ac_cv_prog_CPP+:} false; then : | |
3818 | $as_echo_n "(cached) " >&6 | |
3819 | else | |
3820 | # Double quotes because CPP needs to be expanded | |
3821 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
3822 | do | |
3823 | ac_preproc_ok=false | |
3824 | for ac_c_preproc_warn_flag in '' yes | |
3825 | do | |
3826 | # Use a header file that comes with gcc, so configuring glibc | |
3827 | # with a fresh cross-compiler works. | |
3828 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
3829 | # <limits.h> exists even on freestanding compilers. | |
3830 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
3831 | # not just through cpp. "Syntax error" is here to catch this case. | |
3832 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3833 | /* end confdefs.h. */ | |
3834 | #ifdef __STDC__ | |
3835 | # include <limits.h> | |
3836 | #else | |
3837 | # include <assert.h> | |
3838 | #endif | |
3839 | Syntax error | |
3840 | _ACEOF | |
3841 | if ac_fn_c_try_cpp "$LINENO"; then : | |
3842 | ||
3843 | else | |
3844 | # Broken: fails on valid input. | |
3845 | continue | |
3846 | fi | |
3847 | rm -f conftest.err conftest.i conftest.$ac_ext | |
3848 | ||
3849 | # OK, works on sane cases. Now check whether nonexistent headers | |
3850 | # can be detected and how. | |
3851 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3852 | /* end confdefs.h. */ | |
3853 | #include <ac_nonexistent.h> | |
3854 | _ACEOF | |
3855 | if ac_fn_c_try_cpp "$LINENO"; then : | |
3856 | # Broken: success on invalid input. | |
3857 | continue | |
3858 | else | |
3859 | # Passes both tests. | |
3860 | ac_preproc_ok=: | |
3861 | break | |
3862 | fi | |
3863 | rm -f conftest.err conftest.i conftest.$ac_ext | |
3864 | ||
3865 | done | |
3866 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
3867 | rm -f conftest.i conftest.err conftest.$ac_ext | |
3868 | if $ac_preproc_ok; then : | |
3869 | break | |
3870 | fi | |
3871 | ||
3872 | done | |
3873 | ac_cv_prog_CPP=$CPP | |
3874 | ||
3875 | fi | |
3876 | CPP=$ac_cv_prog_CPP | |
3877 | else | |
3878 | ac_cv_prog_CPP=$CPP | |
3879 | fi | |
3880 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 | |
3881 | $as_echo "$CPP" >&6; } | |
3882 | ac_preproc_ok=false | |
3883 | for ac_c_preproc_warn_flag in '' yes | |
3884 | do | |
3885 | # Use a header file that comes with gcc, so configuring glibc | |
3886 | # with a fresh cross-compiler works. | |
3887 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
3888 | # <limits.h> exists even on freestanding compilers. | |
3889 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
3890 | # not just through cpp. "Syntax error" is here to catch this case. | |
3891 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3892 | /* end confdefs.h. */ | |
3893 | #ifdef __STDC__ | |
3894 | # include <limits.h> | |
3895 | #else | |
3896 | # include <assert.h> | |
3897 | #endif | |
3898 | Syntax error | |
3899 | _ACEOF | |
3900 | if ac_fn_c_try_cpp "$LINENO"; then : | |
3901 | ||
3902 | else | |
3903 | # Broken: fails on valid input. | |
3904 | continue | |
3905 | fi | |
3906 | rm -f conftest.err conftest.i conftest.$ac_ext | |
3907 | ||
3908 | # OK, works on sane cases. Now check whether nonexistent headers | |
3909 | # can be detected and how. | |
3910 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3911 | /* end confdefs.h. */ | |
3912 | #include <ac_nonexistent.h> | |
3913 | _ACEOF | |
3914 | if ac_fn_c_try_cpp "$LINENO"; then : | |
3915 | # Broken: success on invalid input. | |
3916 | continue | |
3917 | else | |
3918 | # Passes both tests. | |
3919 | ac_preproc_ok=: | |
3920 | break | |
3921 | fi | |
3922 | rm -f conftest.err conftest.i conftest.$ac_ext | |
3923 | ||
3924 | done | |
3925 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
3926 | rm -f conftest.i conftest.err conftest.$ac_ext | |
3927 | if $ac_preproc_ok; then : | |
3928 | ||
3929 | else | |
3930 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3931 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3932 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check | |
3933 | See \`config.log' for more details" "$LINENO" 5; } | |
3934 | fi | |
3935 | ||
3936 | ac_ext=c | |
3937 | ac_cpp='$CPP $CPPFLAGS' | |
3938 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3939 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3940 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3941 | ||
3942 | ||
3943 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 | |
3944 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } | |
3945 | if ${ac_cv_path_GREP+:} false; then : | |
3946 | $as_echo_n "(cached) " >&6 | |
3947 | else | |
3948 | if test -z "$GREP"; then | |
3949 | ac_path_GREP_found=false | |
3950 | # Loop through the user's path and test for each of PROGNAME-LIST | |
3951 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3952 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
3953 | do | |
3954 | IFS=$as_save_IFS | |
3955 | test -z "$as_dir" && as_dir=. | |
3956 | for ac_prog in grep ggrep; do | |
3957 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3958 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" | |
3959 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue | |
3960 | # Check for GNU ac_path_GREP and select it if it is found. | |
3961 | # Check for GNU $ac_path_GREP | |
3962 | case `"$ac_path_GREP" --version 2>&1` in | |
3963 | *GNU*) | |
3964 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; | |
3965 | *) | |
3966 | ac_count=0 | |
3967 | $as_echo_n 0123456789 >"conftest.in" | |
3968 | while : | |
3969 | do | |
3970 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
3971 | mv "conftest.tmp" "conftest.in" | |
3972 | cp "conftest.in" "conftest.nl" | |
3973 | $as_echo 'GREP' >> "conftest.nl" | |
3974 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
3975 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
3976 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
3977 | if test $ac_count -gt ${ac_path_GREP_max-0}; then | |
3978 | # Best one so far, save it but keep looking for a better one | |
3979 | ac_cv_path_GREP="$ac_path_GREP" | |
3980 | ac_path_GREP_max=$ac_count | |
3981 | fi | |
3982 | # 10*(2^10) chars as input seems more than enough | |
3983 | test $ac_count -gt 10 && break | |
3984 | done | |
3985 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
3986 | esac | |
3987 | ||
3988 | $ac_path_GREP_found && break 3 | |
3989 | done | |
3990 | done | |
3991 | done | |
3992 | IFS=$as_save_IFS | |
3993 | if test -z "$ac_cv_path_GREP"; then | |
3994 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 | |
3995 | fi | |
3996 | else | |
3997 | ac_cv_path_GREP=$GREP | |
3998 | fi | |
3999 | ||
4000 | fi | |
4001 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 | |
4002 | $as_echo "$ac_cv_path_GREP" >&6; } | |
4003 | GREP="$ac_cv_path_GREP" | |
4004 | ||
4005 | ||
4006 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 | |
4007 | $as_echo_n "checking for egrep... " >&6; } | |
4008 | if ${ac_cv_path_EGREP+:} false; then : | |
4009 | $as_echo_n "(cached) " >&6 | |
4010 | else | |
4011 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 | |
4012 | then ac_cv_path_EGREP="$GREP -E" | |
4013 | else | |
4014 | if test -z "$EGREP"; then | |
4015 | ac_path_EGREP_found=false | |
4016 | # Loop through the user's path and test for each of PROGNAME-LIST | |
4017 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4018 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
4019 | do | |
4020 | IFS=$as_save_IFS | |
4021 | test -z "$as_dir" && as_dir=. | |
4022 | for ac_prog in egrep; do | |
4023 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4024 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" | |
4025 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue | |
4026 | # Check for GNU ac_path_EGREP and select it if it is found. | |
4027 | # Check for GNU $ac_path_EGREP | |
4028 | case `"$ac_path_EGREP" --version 2>&1` in | |
4029 | *GNU*) | |
4030 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; | |
4031 | *) | |
4032 | ac_count=0 | |
4033 | $as_echo_n 0123456789 >"conftest.in" | |
4034 | while : | |
4035 | do | |
4036 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4037 | mv "conftest.tmp" "conftest.in" | |
4038 | cp "conftest.in" "conftest.nl" | |
4039 | $as_echo 'EGREP' >> "conftest.nl" | |
4040 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
4041 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
4042 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
4043 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then | |
4044 | # Best one so far, save it but keep looking for a better one | |
4045 | ac_cv_path_EGREP="$ac_path_EGREP" | |
4046 | ac_path_EGREP_max=$ac_count | |
4047 | fi | |
4048 | # 10*(2^10) chars as input seems more than enough | |
4049 | test $ac_count -gt 10 && break | |
4050 | done | |
4051 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4052 | esac | |
4053 | ||
4054 | $ac_path_EGREP_found && break 3 | |
4055 | done | |
4056 | done | |
4057 | done | |
4058 | IFS=$as_save_IFS | |
4059 | if test -z "$ac_cv_path_EGREP"; then | |
4060 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 | |
4061 | fi | |
4062 | else | |
4063 | ac_cv_path_EGREP=$EGREP | |
4064 | fi | |
4065 | ||
4066 | fi | |
4067 | fi | |
4068 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 | |
4069 | $as_echo "$ac_cv_path_EGREP" >&6; } | |
4070 | EGREP="$ac_cv_path_EGREP" | |
4071 | ||
4072 | ||
4073 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 | |
4074 | $as_echo_n "checking for ANSI C header files... " >&6; } | |
4075 | if ${ac_cv_header_stdc+:} false; then : | |
4076 | $as_echo_n "(cached) " >&6 | |
4077 | else | |
4078 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4079 | /* end confdefs.h. */ | |
4080 | #include <stdlib.h> | |
4081 | #include <stdarg.h> | |
4082 | #include <string.h> | |
4083 | #include <float.h> | |
4084 | ||
4085 | int | |
4086 | main () | |
4087 | { | |
4088 | ||
4089 | ; | |
4090 | return 0; | |
4091 | } | |
4092 | _ACEOF | |
4093 | if ac_fn_c_try_compile "$LINENO"; then : | |
4094 | ac_cv_header_stdc=yes | |
4095 | else | |
4096 | ac_cv_header_stdc=no | |
4097 | fi | |
4098 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4099 | ||
4100 | if test $ac_cv_header_stdc = yes; then | |
4101 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
4102 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4103 | /* end confdefs.h. */ | |
4104 | #include <string.h> | |
4105 | ||
4106 | _ACEOF | |
4107 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4108 | $EGREP "memchr" >/dev/null 2>&1; then : | |
4109 | ||
4110 | else | |
4111 | ac_cv_header_stdc=no | |
4112 | fi | |
4113 | rm -f conftest* | |
4114 | ||
4115 | fi | |
4116 | ||
4117 | if test $ac_cv_header_stdc = yes; then | |
4118 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
4119 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4120 | /* end confdefs.h. */ | |
4121 | #include <stdlib.h> | |
4122 | ||
4123 | _ACEOF | |
4124 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4125 | $EGREP "free" >/dev/null 2>&1; then : | |
4126 | ||
4127 | else | |
4128 | ac_cv_header_stdc=no | |
4129 | fi | |
4130 | rm -f conftest* | |
4131 | ||
4132 | fi | |
4133 | ||
4134 | if test $ac_cv_header_stdc = yes; then | |
4135 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
4136 | if test "$cross_compiling" = yes; then : | |
4137 | : | |
4138 | else | |
4139 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4140 | /* end confdefs.h. */ | |
4141 | #include <ctype.h> | |
4142 | #include <stdlib.h> | |
4143 | #if ((' ' & 0x0FF) == 0x020) | |
4144 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
4145 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
4146 | #else | |
4147 | # define ISLOWER(c) \ | |
4148 | (('a' <= (c) && (c) <= 'i') \ | |
4149 | || ('j' <= (c) && (c) <= 'r') \ | |
4150 | || ('s' <= (c) && (c) <= 'z')) | |
4151 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) | |
4152 | #endif | |
4153 | ||
4154 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
4155 | int | |
4156 | main () | |
4157 | { | |
4158 | int i; | |
4159 | for (i = 0; i < 256; i++) | |
4160 | if (XOR (islower (i), ISLOWER (i)) | |
4161 | || toupper (i) != TOUPPER (i)) | |
4162 | return 2; | |
4163 | return 0; | |
4164 | } | |
4165 | _ACEOF | |
4166 | if ac_fn_c_try_run "$LINENO"; then : | |
4167 | ||
4168 | else | |
4169 | ac_cv_header_stdc=no | |
4170 | fi | |
4171 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
4172 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
4173 | fi | |
4174 | ||
4175 | fi | |
4176 | fi | |
4177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 | |
4178 | $as_echo "$ac_cv_header_stdc" >&6; } | |
4179 | if test $ac_cv_header_stdc = yes; then | |
4180 | ||
4181 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h | |
4182 | ||
4183 | fi | |
4184 | ||
4185 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. | |
4186 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ | |
4187 | inttypes.h stdint.h unistd.h | |
4188 | do : | |
4189 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
4190 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
4191 | " | |
4192 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
4193 | cat >>confdefs.h <<_ACEOF | |
4194 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
4195 | _ACEOF | |
4196 | ||
4197 | fi | |
4198 | ||
4199 | done | |
4200 | ||
4201 | ||
4202 | ||
4203 | ||
4204 | if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then | |
4205 | if test -n "$ac_tool_prefix"; then | |
4206 | # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. | |
4207 | set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 | |
4208 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4209 | $as_echo_n "checking for $ac_word... " >&6; } | |
4210 | if ${ac_cv_path_PKG_CONFIG+:} false; then : | |
4211 | $as_echo_n "(cached) " >&6 | |
4212 | else | |
4213 | case $PKG_CONFIG in | |
4214 | [\\/]* | ?:[\\/]*) | |
4215 | ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. | |
4216 | ;; | |
4217 | *) | |
4218 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4219 | for as_dir in $PATH | |
4220 | do | |
4221 | IFS=$as_save_IFS | |
4222 | test -z "$as_dir" && as_dir=. | |
4223 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4224 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4225 | ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
4226 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4227 | break 2 | |
4228 | fi | |
4229 | done | |
4230 | done | |
4231 | IFS=$as_save_IFS | |
4232 | ||
4233 | ;; | |
4234 | esac | |
4235 | fi | |
4236 | PKG_CONFIG=$ac_cv_path_PKG_CONFIG | |
4237 | if test -n "$PKG_CONFIG"; then | |
4238 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 | |
4239 | $as_echo "$PKG_CONFIG" >&6; } | |
4240 | else | |
4241 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4242 | $as_echo "no" >&6; } | |
4243 | fi | |
4244 | ||
4245 | ||
4246 | fi | |
4247 | if test -z "$ac_cv_path_PKG_CONFIG"; then | |
4248 | ac_pt_PKG_CONFIG=$PKG_CONFIG | |
4249 | # Extract the first word of "pkg-config", so it can be a program name with args. | |
4250 | set dummy pkg-config; ac_word=$2 | |
4251 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4252 | $as_echo_n "checking for $ac_word... " >&6; } | |
4253 | if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : | |
4254 | $as_echo_n "(cached) " >&6 | |
4255 | else | |
4256 | case $ac_pt_PKG_CONFIG in | |
4257 | [\\/]* | ?:[\\/]*) | |
4258 | ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. | |
4259 | ;; | |
4260 | *) | |
4261 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4262 | for as_dir in $PATH | |
4263 | do | |
4264 | IFS=$as_save_IFS | |
4265 | test -z "$as_dir" && as_dir=. | |
4266 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4267 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4268 | ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" | |
4269 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4270 | break 2 | |
4271 | fi | |
4272 | done | |
4273 | done | |
4274 | IFS=$as_save_IFS | |
4275 | ||
4276 | ;; | |
4277 | esac | |
4278 | fi | |
4279 | ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG | |
4280 | if test -n "$ac_pt_PKG_CONFIG"; then | |
4281 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 | |
4282 | $as_echo "$ac_pt_PKG_CONFIG" >&6; } | |
4283 | else | |
4284 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4285 | $as_echo "no" >&6; } | |
4286 | fi | |
4287 | ||
4288 | if test "x$ac_pt_PKG_CONFIG" = x; then | |
4289 | PKG_CONFIG="" | |
4290 | else | |
4291 | case $cross_compiling:$ac_tool_warned in | |
4292 | yes:) | |
4293 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
4294 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
4295 | ac_tool_warned=yes ;; | |
4296 | esac | |
4297 | PKG_CONFIG=$ac_pt_PKG_CONFIG | |
4298 | fi | |
4299 | else | |
4300 | PKG_CONFIG="$ac_cv_path_PKG_CONFIG" | |
4301 | fi | |
4302 | ||
4303 | fi | |
4304 | if test -n "$PKG_CONFIG"; then | |
4305 | _pkg_min_version=0.9.0 | |
4306 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 | |
4307 | $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } | |
4308 | if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then | |
4309 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
4310 | $as_echo "yes" >&6; } | |
4311 | else | |
4312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4313 | $as_echo "no" >&6; } | |
4314 | PKG_CONFIG="" | |
4315 | fi | |
4316 | ||
4317 | fi | |
4318 | # Make sure we can run config.sub. | |
4319 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || | |
4320 | as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 | |
4321 | ||
4322 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 | |
4323 | $as_echo_n "checking build system type... " >&6; } | |
4324 | if ${ac_cv_build+:} false; then : | |
4325 | $as_echo_n "(cached) " >&6 | |
4326 | else | |
4327 | ac_build_alias=$build_alias | |
4328 | test "x$ac_build_alias" = x && | |
4329 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` | |
4330 | test "x$ac_build_alias" = x && | |
4331 | as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 | |
4332 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || | |
4333 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 | |
4334 | ||
4335 | fi | |
4336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 | |
4337 | $as_echo "$ac_cv_build" >&6; } | |
4338 | case $ac_cv_build in | |
4339 | *-*-*) ;; | |
4340 | *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; | |
4341 | esac | |
4342 | build=$ac_cv_build | |
4343 | ac_save_IFS=$IFS; IFS='-' | |
4344 | set x $ac_cv_build | |
4345 | shift | |
4346 | build_cpu=$1 | |
4347 | build_vendor=$2 | |
4348 | shift; shift | |
4349 | # Remember, the first character of IFS is used to create $*, | |
4350 | # except with old shells: | |
4351 | build_os=$* | |
4352 | IFS=$ac_save_IFS | |
4353 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac | |
4354 | ||
4355 | ||
4356 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 | |
4357 | $as_echo_n "checking host system type... " >&6; } | |
4358 | if ${ac_cv_host+:} false; then : | |
4359 | $as_echo_n "(cached) " >&6 | |
4360 | else | |
4361 | if test "x$host_alias" = x; then | |
4362 | ac_cv_host=$ac_cv_build | |
4363 | else | |
4364 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || | |
4365 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 | |
4366 | fi | |
4367 | ||
4368 | fi | |
4369 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 | |
4370 | $as_echo "$ac_cv_host" >&6; } | |
4371 | case $ac_cv_host in | |
4372 | *-*-*) ;; | |
4373 | *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; | |
4374 | esac | |
4375 | host=$ac_cv_host | |
4376 | ac_save_IFS=$IFS; IFS='-' | |
4377 | set x $ac_cv_host | |
4378 | shift | |
4379 | host_cpu=$1 | |
4380 | host_vendor=$2 | |
4381 | shift; shift | |
4382 | # Remember, the first character of IFS is used to create $*, | |
4383 | # except with old shells: | |
4384 | host_os=$* | |
4385 | IFS=$ac_save_IFS | |
4386 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac | |
4387 | ||
4388 | ||
4389 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 | |
4390 | $as_echo_n "checking for a sed that does not truncate output... " >&6; } | |
4391 | if ${ac_cv_path_SED+:} false; then : | |
4392 | $as_echo_n "(cached) " >&6 | |
4393 | else | |
4394 | ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ | |
4395 | for ac_i in 1 2 3 4 5 6 7; do | |
4396 | ac_script="$ac_script$as_nl$ac_script" | |
4397 | done | |
4398 | echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed | |
4399 | { ac_script=; unset ac_script;} | |
4400 | if test -z "$SED"; then | |
4401 | ac_path_SED_found=false | |
4402 | # Loop through the user's path and test for each of PROGNAME-LIST | |
4403 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4404 | for as_dir in $PATH | |
4405 | do | |
4406 | IFS=$as_save_IFS | |
4407 | test -z "$as_dir" && as_dir=. | |
4408 | for ac_prog in sed gsed; do | |
4409 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4410 | ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" | |
4411 | { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue | |
4412 | # Check for GNU ac_path_SED and select it if it is found. | |
4413 | # Check for GNU $ac_path_SED | |
4414 | case `"$ac_path_SED" --version 2>&1` in | |
4415 | *GNU*) | |
4416 | ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; | |
4417 | *) | |
4418 | ac_count=0 | |
4419 | $as_echo_n 0123456789 >"conftest.in" | |
4420 | while : | |
4421 | do | |
4422 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4423 | mv "conftest.tmp" "conftest.in" | |
4424 | cp "conftest.in" "conftest.nl" | |
4425 | $as_echo '' >> "conftest.nl" | |
4426 | "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
4427 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
4428 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
4429 | if test $ac_count -gt ${ac_path_SED_max-0}; then | |
4430 | # Best one so far, save it but keep looking for a better one | |
4431 | ac_cv_path_SED="$ac_path_SED" | |
4432 | ac_path_SED_max=$ac_count | |
4433 | fi | |
4434 | # 10*(2^10) chars as input seems more than enough | |
4435 | test $ac_count -gt 10 && break | |
4436 | done | |
4437 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4438 | esac | |
4439 | ||
4440 | $ac_path_SED_found && break 3 | |
4441 | done | |
4442 | done | |
4443 | done | |
4444 | IFS=$as_save_IFS | |
4445 | if test -z "$ac_cv_path_SED"; then | |
4446 | as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 | |
4447 | fi | |
4448 | else | |
4449 | ac_cv_path_SED=$SED | |
4450 | fi | |
4451 | ||
4452 | fi | |
4453 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 | |
4454 | $as_echo "$ac_cv_path_SED" >&6; } | |
4455 | SED="$ac_cv_path_SED" | |
4456 | rm -f conftest.sed | |
4457 | ||
4458 | ||
4459 | ||
4460 | ||
4461 | ||
4462 | if test "x$GCC" = xyes ; then | |
4463 | CWARNFLAGS="-Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes \ | |
4464 | -Wmissing-declarations -Wnested-externs -fno-strict-aliasing \ | |
4465 | -Wbad-function-cast -Wformat=2" | |
4466 | case `$CC -dumpversion` in | |
4467 | 3.4.* | 4.*) | |
4468 | CWARNFLAGS="$CWARNFLAGS -Wold-style-definition -Wdeclaration-after-statement" | |
4469 | ;; | |
4470 | esac | |
4471 | else | |
4472 | ac_fn_c_check_decl "$LINENO" "__SUNPRO_C" "ac_cv_have_decl___SUNPRO_C" "$ac_includes_default" | |
4473 | if test "x$ac_cv_have_decl___SUNPRO_C" = xyes; then : | |
4474 | SUNCC="yes" | |
4475 | else | |
4476 | SUNCC="no" | |
4477 | fi | |
4478 | ||
4479 | if test "x$SUNCC" = "xyes"; then | |
4480 | CWARNFLAGS="-v" | |
4481 | fi | |
4482 | fi | |
4483 | ||
4484 | ||
4485 | ||
4486 | # If the module's configure.ac calls AC_PROG_CC later on, CC gets set to C89 | |
4487 | ||
4488 | ||
4489 | ||
4490 | # Check whether --enable-strict-compilation was given. | |
4491 | if test "${enable_strict_compilation+set}" = set; then : | |
4492 | enableval=$enable_strict_compilation; STRICT_COMPILE=$enableval | |
4493 | else | |
4494 | STRICT_COMPILE=no | |
4495 | fi | |
4496 | ||
4497 | if test "x$STRICT_COMPILE" = "xyes"; then | |
4498 | ac_fn_c_check_decl "$LINENO" "__SUNPRO_C" "ac_cv_have_decl___SUNPRO_C" "$ac_includes_default" | |
4499 | if test "x$ac_cv_have_decl___SUNPRO_C" = xyes; then : | |
4500 | SUNCC="yes" | |
4501 | else | |
4502 | SUNCC="no" | |
4503 | fi | |
4504 | ||
4505 | ac_fn_c_check_decl "$LINENO" "__INTEL_COMPILER" "ac_cv_have_decl___INTEL_COMPILER" "$ac_includes_default" | |
4506 | if test "x$ac_cv_have_decl___INTEL_COMPILER" = xyes; then : | |
4507 | INTELCC="yes" | |
4508 | else | |
4509 | INTELCC="no" | |
4510 | fi | |
4511 | ||
4512 | if test "x$GCC" = xyes ; then | |
4513 | STRICT_CFLAGS="-pedantic -Werror" | |
4514 | elif test "x$SUNCC" = "xyes"; then | |
4515 | STRICT_CFLAGS="-errwarn" | |
4516 | elif test "x$INTELCC" = "xyes"; then | |
4517 | STRICT_CFLAGS="-Werror" | |
4518 | fi | |
4519 | fi | |
4520 | CWARNFLAGS="$CWARNFLAGS $STRICT_CFLAGS" | |
4521 | ||
4522 | ||
4523 | ||
4524 | ||
4525 | cat >>confdefs.h <<_ACEOF | |
4526 | #define PACKAGE_VERSION_MAJOR `echo $PACKAGE_VERSION | cut -d . -f 1` | |
4527 | _ACEOF | |
4528 | ||
4529 | PVM=`echo $PACKAGE_VERSION | cut -d . -f 2 | cut -d - -f 1` | |
4530 | if test "x$PVM" = "x"; then | |
4531 | PVM="0" | |
4532 | fi | |
4533 | ||
4534 | cat >>confdefs.h <<_ACEOF | |
4535 | #define PACKAGE_VERSION_MINOR $PVM | |
4536 | _ACEOF | |
4537 | ||
4538 | PVP=`echo $PACKAGE_VERSION | cut -d . -f 3 | cut -d - -f 1` | |
4539 | if test "x$PVP" = "x"; then | |
4540 | PVP="0" | |
4541 | fi | |
4542 | ||
4543 | cat >>confdefs.h <<_ACEOF | |
4544 | #define PACKAGE_VERSION_PATCHLEVEL $PVP | |
4545 | _ACEOF | |
4546 | ||
4547 | ||
4548 | ||
4549 | CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \ | |
4550 | mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \ | |
4551 | || (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \ | |
4552 | echo 'git directory not found: installing possibly empty changelog.' >&2)" | |
4553 | ||
4554 | ||
4555 | ||
4556 | ||
4557 | macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros` | |
4558 | INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \ | |
4559 | mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \ | |
4560 | || (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \ | |
4561 | echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)" | |
4562 | ||
4563 | ||
4564 | ||
4565 | ||
4566 | ||
4567 | ||
4568 | if test x$APP_MAN_SUFFIX = x ; then | |
4569 | APP_MAN_SUFFIX=1 | |
4570 | fi | |
4571 | if test x$APP_MAN_DIR = x ; then | |
4572 | APP_MAN_DIR='$(mandir)/man$(APP_MAN_SUFFIX)' | |
4573 | fi | |
4574 | ||
4575 | if test x$LIB_MAN_SUFFIX = x ; then | |
4576 | LIB_MAN_SUFFIX=3 | |
4577 | fi | |
4578 | if test x$LIB_MAN_DIR = x ; then | |
4579 | LIB_MAN_DIR='$(mandir)/man$(LIB_MAN_SUFFIX)' | |
4580 | fi | |
4581 | ||
4582 | if test x$FILE_MAN_SUFFIX = x ; then | |
4583 | case $host_os in | |
4584 | solaris*) FILE_MAN_SUFFIX=4 ;; | |
4585 | *) FILE_MAN_SUFFIX=5 ;; | |
4586 | esac | |
4587 | fi | |
4588 | if test x$FILE_MAN_DIR = x ; then | |
4589 | FILE_MAN_DIR='$(mandir)/man$(FILE_MAN_SUFFIX)' | |
4590 | fi | |
4591 | ||
4592 | if test x$MISC_MAN_SUFFIX = x ; then | |
4593 | case $host_os in | |
4594 | solaris*) MISC_MAN_SUFFIX=5 ;; | |
4595 | *) MISC_MAN_SUFFIX=7 ;; | |
4596 | esac | |
4597 | fi | |
4598 | if test x$MISC_MAN_DIR = x ; then | |
4599 | MISC_MAN_DIR='$(mandir)/man$(MISC_MAN_SUFFIX)' | |
4600 | fi | |
4601 | ||
4602 | if test x$DRIVER_MAN_SUFFIX = x ; then | |
4603 | case $host_os in | |
4604 | solaris*) DRIVER_MAN_SUFFIX=7 ;; | |
4605 | *) DRIVER_MAN_SUFFIX=4 ;; | |
4606 | esac | |
4607 | fi | |
4608 | if test x$DRIVER_MAN_DIR = x ; then | |
4609 | DRIVER_MAN_DIR='$(mandir)/man$(DRIVER_MAN_SUFFIX)' | |
4610 | fi | |
4611 | ||
4612 | if test x$ADMIN_MAN_SUFFIX = x ; then | |
4613 | case $host_os in | |
4614 | solaris*) ADMIN_MAN_SUFFIX=1m ;; | |
4615 | *) ADMIN_MAN_SUFFIX=8 ;; | |
4616 | esac | |
4617 | fi | |
4618 | if test x$ADMIN_MAN_DIR = x ; then | |
4619 | ADMIN_MAN_DIR='$(mandir)/man$(ADMIN_MAN_SUFFIX)' | |
4620 | fi | |
4621 | ||
4622 | ||
4623 | ||
4624 | ||
4625 | ||
4626 | ||
4627 | ||
4628 | ||
4629 | ||
4630 | ||
4631 | ||
4632 | ||
4633 | ||
4634 | ||
4635 | ||
4636 | XORG_MAN_PAGE="X Version 11" | |
4637 | ||
4638 | MAN_SUBSTS="\ | |
4639 | -e 's|__vendorversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ | |
4640 | -e 's|__xorgversion__|\"\$(PACKAGE_STRING)\" \"\$(XORG_MAN_PAGE)\"|' \ | |
4641 | -e 's|__xservername__|Xorg|g' \ | |
4642 | -e 's|__xconfigfile__|xorg.conf|g' \ | |
4643 | -e 's|__projectroot__|\$(prefix)|g' \ | |
4644 | -e 's|__apploaddir__|\$(appdefaultdir)|g' \ | |
4645 | -e 's|__appmansuffix__|\$(APP_MAN_SUFFIX)|g' \ | |
4646 | -e 's|__drivermansuffix__|\$(DRIVER_MAN_SUFFIX)|g' \ | |
4647 | -e 's|__adminmansuffix__|\$(ADMIN_MAN_SUFFIX)|g' \ | |
4648 | -e 's|__libmansuffix__|\$(LIB_MAN_SUFFIX)|g' \ | |
4649 | -e 's|__miscmansuffix__|\$(MISC_MAN_SUFFIX)|g' \ | |
4650 | -e 's|__filemansuffix__|\$(FILE_MAN_SUFFIX)|g'" | |
4651 | ||
4652 | ||
4653 | ||
4654 | # Check whether --enable-silent-rules was given. | |
4655 | if test "${enable_silent_rules+set}" = set; then : | |
4656 | enableval=$enable_silent_rules; | |
4657 | fi | |
4658 | ||
4659 | case $enable_silent_rules in | |
4660 | yes) AM_DEFAULT_VERBOSITY=0;; | |
4661 | no) AM_DEFAULT_VERBOSITY=1;; | |
4662 | *) AM_DEFAULT_VERBOSITY=0;; | |
4663 | esac | |
4664 | AM_BACKSLASH='\' | |
4665 | ||
4666 | ||
4667 | ||
4668 | # Checks for header files. | |
4669 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 | |
4670 | $as_echo_n "checking for ANSI C header files... " >&6; } | |
4671 | if ${ac_cv_header_stdc+:} false; then : | |
4672 | $as_echo_n "(cached) " >&6 | |
4673 | else | |
4674 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4675 | /* end confdefs.h. */ | |
4676 | #include <stdlib.h> | |
4677 | #include <stdarg.h> | |
4678 | #include <string.h> | |
4679 | #include <float.h> | |
4680 | ||
4681 | int | |
4682 | main () | |
4683 | { | |
4684 | ||
4685 | ; | |
4686 | return 0; | |
4687 | } | |
4688 | _ACEOF | |
4689 | if ac_fn_c_try_compile "$LINENO"; then : | |
4690 | ac_cv_header_stdc=yes | |
4691 | else | |
4692 | ac_cv_header_stdc=no | |
4693 | fi | |
4694 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4695 | ||
4696 | if test $ac_cv_header_stdc = yes; then | |
4697 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
4698 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4699 | /* end confdefs.h. */ | |
4700 | #include <string.h> | |
4701 | ||
4702 | _ACEOF | |
4703 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4704 | $EGREP "memchr" >/dev/null 2>&1; then : | |
4705 | ||
4706 | else | |
4707 | ac_cv_header_stdc=no | |
4708 | fi | |
4709 | rm -f conftest* | |
4710 | ||
4711 | fi | |
4712 | ||
4713 | if test $ac_cv_header_stdc = yes; then | |
4714 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
4715 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4716 | /* end confdefs.h. */ | |
4717 | #include <stdlib.h> | |
4718 | ||
4719 | _ACEOF | |
4720 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4721 | $EGREP "free" >/dev/null 2>&1; then : | |
4722 | ||
4723 | else | |
4724 | ac_cv_header_stdc=no | |
4725 | fi | |
4726 | rm -f conftest* | |
4727 | ||
4728 | fi | |
4729 | ||
4730 | if test $ac_cv_header_stdc = yes; then | |
4731 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
4732 | if test "$cross_compiling" = yes; then : | |
4733 | : | |
4734 | else | |
4735 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4736 | /* end confdefs.h. */ | |
4737 | #include <ctype.h> | |
4738 | #include <stdlib.h> | |
4739 | #if ((' ' & 0x0FF) == 0x020) | |
4740 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
4741 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
4742 | #else | |
4743 | # define ISLOWER(c) \ | |
4744 | (('a' <= (c) && (c) <= 'i') \ | |
4745 | || ('j' <= (c) && (c) <= 'r') \ | |
4746 | || ('s' <= (c) && (c) <= 'z')) | |
4747 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) | |
4748 | #endif | |
4749 | ||
4750 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
4751 | int | |
4752 | main () | |
4753 | { | |
4754 | int i; | |
4755 | for (i = 0; i < 256; i++) | |
4756 | if (XOR (islower (i), ISLOWER (i)) | |
4757 | || toupper (i) != TOUPPER (i)) | |
4758 | return 2; | |
4759 | return 0; | |
4760 | } | |
4761 | _ACEOF | |
4762 | if ac_fn_c_try_run "$LINENO"; then : | |
4763 | ||
4764 | else | |
4765 | ac_cv_header_stdc=no | |
4766 | fi | |
4767 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
4768 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
4769 | fi | |
4770 | ||
4771 | fi | |
4772 | fi | |
4773 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 | |
4774 | $as_echo "$ac_cv_header_stdc" >&6; } | |
4775 | if test $ac_cv_header_stdc = yes; then | |
4776 | ||
4777 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h | |
4778 | ||
4779 | fi | |
4780 | ||
4781 | for ac_header in err.h | |
4782 | do : | |
4783 | ac_fn_c_check_header_mongrel "$LINENO" "err.h" "ac_cv_header_err_h" "$ac_includes_default" | |
4784 | if test "x$ac_cv_header_err_h" = xyes; then : | |
4785 | cat >>confdefs.h <<_ACEOF | |
4786 | #define HAVE_ERR_H 1 | |
4787 | _ACEOF | |
4788 | ||
4789 | fi | |
4790 | ||
4791 | done | |
4792 | ||
4793 | ||
4794 | # Checks for pkg-config packages | |
4795 | ||
4796 | pkg_failed=no | |
4797 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RC" >&5 | |
4798 | $as_echo_n "checking for RC... " >&6; } | |
4799 | ||
4800 | if test -n "$RC_CFLAGS"; then | |
4801 | pkg_cv_RC_CFLAGS="$RC_CFLAGS" | |
4802 | elif test -n "$PKG_CONFIG"; then | |
4803 | if test -n "$PKG_CONFIG" && \ | |
4804 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xrender x11\""; } >&5 | |
4805 | ($PKG_CONFIG --exists --print-errors "xrender x11") 2>&5 | |
4806 | ac_status=$? | |
4807 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4808 | test $ac_status = 0; }; then | |
4809 | pkg_cv_RC_CFLAGS=`$PKG_CONFIG --cflags "xrender x11" 2>/dev/null` | |
4810 | else | |
4811 | pkg_failed=yes | |
4812 | fi | |
4813 | else | |
4814 | pkg_failed=untried | |
4815 | fi | |
4816 | if test -n "$RC_LIBS"; then | |
4817 | pkg_cv_RC_LIBS="$RC_LIBS" | |
4818 | elif test -n "$PKG_CONFIG"; then | |
4819 | if test -n "$PKG_CONFIG" && \ | |
4820 | { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xrender x11\""; } >&5 | |
4821 | ($PKG_CONFIG --exists --print-errors "xrender x11") 2>&5 | |
4822 | ac_status=$? | |
4823 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4824 | test $ac_status = 0; }; then | |
4825 | pkg_cv_RC_LIBS=`$PKG_CONFIG --libs "xrender x11" 2>/dev/null` | |
4826 | else | |
4827 | pkg_failed=yes | |
4828 | fi | |
4829 | else | |
4830 | pkg_failed=untried | |
4831 | fi | |
4832 | ||
4833 | ||
4834 | ||
4835 | if test $pkg_failed = yes; then | |
4836 | ||
4837 | if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then | |
4838 | _pkg_short_errors_supported=yes | |
4839 | else | |
4840 | _pkg_short_errors_supported=no | |
4841 | fi | |
4842 | if test $_pkg_short_errors_supported = yes; then | |
4843 | RC_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "xrender x11" 2>&1` | |
4844 | else | |
4845 | RC_PKG_ERRORS=`$PKG_CONFIG --print-errors "xrender x11" 2>&1` | |
4846 | fi | |
4847 | # Put the nasty error message in config.log where it belongs | |
4848 | echo "$RC_PKG_ERRORS" >&5 | |
4849 | ||
4850 | as_fn_error $? "Package requirements (xrender x11) were not met: | |
4851 | ||
4852 | $RC_PKG_ERRORS | |
4853 | ||
4854 | Consider adjusting the PKG_CONFIG_PATH environment variable if you | |
4855 | installed software in a non-standard prefix. | |
4856 | ||
4857 | Alternatively, you may set the environment variables RC_CFLAGS | |
4858 | and RC_LIBS to avoid the need to call pkg-config. | |
4859 | See the pkg-config man page for more details. | |
4860 | " "$LINENO" 5 | |
4861 | elif test $pkg_failed = untried; then | |
4862 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
4863 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
4864 | as_fn_error $? "The pkg-config script could not be found or is too old. Make sure it | |
4865 | is in your PATH or set the PKG_CONFIG environment variable to the full | |
4866 | path to pkg-config. | |
4867 | ||
4868 | Alternatively, you may set the environment variables RC_CFLAGS | |
4869 | and RC_LIBS to avoid the need to call pkg-config. | |
4870 | See the pkg-config man page for more details. | |
4871 | ||
4872 | To get pkg-config, see <http://pkg-config.freedesktop.org/>. | |
4873 | See \`config.log' for more details" "$LINENO" 5; } | |
4874 | else | |
4875 | RC_CFLAGS=$pkg_cv_RC_CFLAGS | |
4876 | RC_LIBS=$pkg_cv_RC_LIBS | |
4877 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
4878 | $as_echo "yes" >&6; } | |
4879 | : | |
4880 | fi | |
4881 | ||
4882 | ac_config_files="$ac_config_files Makefile man/Makefile" | |
4883 | ||
4884 | ||
4885 | cat >confcache <<\_ACEOF | |
4886 | # This file is a shell script that caches the results of configure | |
4887 | # tests run on this system so they can be shared between configure | |
4888 | # scripts and configure runs, see configure's option --config-cache. | |
4889 | # It is not useful on other systems. If it contains results you don't | |
4890 | # want to keep, you may remove or edit it. | |
4891 | # | |
4892 | # config.status only pays attention to the cache file if you give it | |
4893 | # the --recheck option to rerun configure. | |
4894 | # | |
4895 | # `ac_cv_env_foo' variables (set or unset) will be overridden when | |
4896 | # loading this file, other *unset* `ac_cv_foo' will be assigned the | |
4897 | # following values. | |
4898 | ||
4899 | _ACEOF | |
4900 | ||
4901 | # The following way of writing the cache mishandles newlines in values, | |
4902 | # but we know of no workaround that is simple, portable, and efficient. | |
4903 | # So, we kill variables containing newlines. | |
4904 | # Ultrix sh set writes to stderr and can't be redirected directly, | |
4905 | # and sets the high bit in the cache file unless we assign to the vars. | |
4906 | ( | |
4907 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do | |
4908 | eval ac_val=\$$ac_var | |
4909 | case $ac_val in #( | |
4910 | *${as_nl}*) | |
4911 | case $ac_var in #( | |
4912 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
4913 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
4914 | esac | |
4915 | case $ac_var in #( | |
4916 | _ | IFS | as_nl) ;; #( | |
4917 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
4918 | *) { eval $ac_var=; unset $ac_var;} ;; | |
4919 | esac ;; | |
4920 | esac | |
4921 | done | |
4922 | ||
4923 | (set) 2>&1 | | |
4924 | case $as_nl`(ac_space=' '; set) 2>&1` in #( | |
4925 | *${as_nl}ac_space=\ *) | |
4926 | # `set' does not quote correctly, so add quotes: double-quote | |
4927 | # substitution turns \\\\ into \\, and sed turns \\ into \. | |
4928 | sed -n \ | |
4929 | "s/'/'\\\\''/g; | |
4930 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" | |
4931 | ;; #( | |
4932 | *) | |
4933 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
4934 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
4935 | ;; | |
4936 | esac | | |
4937 | sort | |
4938 | ) | | |
4939 | sed ' | |
4940 | /^ac_cv_env_/b end | |
4941 | t clear | |
4942 | :clear | |
4943 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ | |
4944 | t end | |
4945 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ | |
4946 | :end' >>confcache | |
4947 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else | |
4948 | if test -w "$cache_file"; then | |
4949 | if test "x$cache_file" != "x/dev/null"; then | |
4950 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 | |
4951 | $as_echo "$as_me: updating cache $cache_file" >&6;} | |
4952 | if test ! -f "$cache_file" || test -h "$cache_file"; then | |
4953 | cat confcache >"$cache_file" | |
4954 | else | |
4955 | case $cache_file in #( | |
4956 | */* | ?:*) | |
4957 | mv -f confcache "$cache_file"$$ && | |
4958 | mv -f "$cache_file"$$ "$cache_file" ;; #( | |
4959 | *) | |
4960 | mv -f confcache "$cache_file" ;; | |
4961 | esac | |
4962 | fi | |
4963 | fi | |
4964 | else | |
4965 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 | |
4966 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} | |
4967 | fi | |
4968 | fi | |
4969 | rm -f confcache | |
4970 | ||
4971 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
4972 | # Let make expand exec_prefix. | |
4973 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
4974 | ||
4975 | # Transform confdefs.h into DEFS. | |
4976 | # Protect against shell expansion while executing Makefile rules. | |
4977 | # Protect against Makefile macro expansion. | |
4978 | # | |
4979 | # If the first sed substitution is executed (which looks for macros that | |
4980 | # take arguments), then branch to the quote section. Otherwise, | |
4981 | # look for a macro that doesn't take arguments. | |
4982 | ac_script=' | |
4983 | :mline | |
4984 | /\\$/{ | |
4985 | N | |
4986 | s,\\\n,, | |
4987 | b mline | |
4988 | } | |
4989 | t clear | |
4990 | :clear | |
4991 | s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g | |
4992 | t quote | |
4993 | s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g | |
4994 | t quote | |
4995 | b any | |
4996 | :quote | |
4997 | s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g | |
4998 | s/\[/\\&/g | |
4999 | s/\]/\\&/g | |
5000 | s/\$/$$/g | |
5001 | H | |
5002 | :any | |
5003 | ${ | |
5004 | g | |
5005 | s/^\n// | |
5006 | s/\n/ /g | |
5007 | p | |
5008 | } | |
5009 | ' | |
5010 | DEFS=`sed -n "$ac_script" confdefs.h` | |
5011 | ||
5012 | ||
5013 | ac_libobjs= | |
5014 | ac_ltlibobjs= | |
5015 | U= | |
5016 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue | |
5017 | # 1. Remove the extension, and $U if already installed. | |
5018 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' | |
5019 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` | |
5020 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR | |
5021 | # will be set to the directory where LIBOBJS objects are built. | |
5022 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" | |
5023 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' | |
5024 | done | |
5025 | LIBOBJS=$ac_libobjs | |
5026 | ||
5027 | LTLIBOBJS=$ac_ltlibobjs | |
5028 | ||
5029 | ||
5030 | if test -n "$EXEEXT"; then | |
5031 | am__EXEEXT_TRUE= | |
5032 | am__EXEEXT_FALSE='#' | |
5033 | else | |
5034 | am__EXEEXT_TRUE='#' | |
5035 | am__EXEEXT_FALSE= | |
5036 | fi | |
5037 | ||
5038 | if test -z "${MAINTAINER_MODE_TRUE}" && test -z "${MAINTAINER_MODE_FALSE}"; then | |
5039 | as_fn_error $? "conditional \"MAINTAINER_MODE\" was never defined. | |
5040 | Usually this means the macro was only invoked conditionally." "$LINENO" 5 | |
5041 | fi | |
5042 | if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then | |
5043 | as_fn_error $? "conditional \"AMDEP\" was never defined. | |
5044 | Usually this means the macro was only invoked conditionally." "$LINENO" 5 | |
5045 | fi | |
5046 | if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then | |
5047 | as_fn_error $? "conditional \"am__fastdepCC\" was never defined. | |
5048 | Usually this means the macro was only invoked conditionally." "$LINENO" 5 | |
5049 | fi | |
5050 | ||
5051 | : "${CONFIG_STATUS=./config.status}" | |
5052 | ac_write_fail=0 | |
5053 | ac_clean_files_save=$ac_clean_files | |
5054 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" | |
5055 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 | |
5056 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} | |
5057 | as_write_fail=0 | |
5058 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 | |
5059 | #! $SHELL | |
5060 | # Generated by $as_me. | |
5061 | # Run this file to recreate the current configuration. | |
5062 | # Compiler output produced by configure, useful for debugging | |
5063 | # configure, is in config.log if it exists. | |
5064 | ||
5065 | debug=false | |
5066 | ac_cs_recheck=false | |
5067 | ac_cs_silent=false | |
5068 | ||
5069 | SHELL=\${CONFIG_SHELL-$SHELL} | |
5070 | export SHELL | |
5071 | _ASEOF | |
5072 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 | |
5073 | ## -------------------- ## | |
5074 | ## M4sh Initialization. ## | |
5075 | ## -------------------- ## | |
5076 | ||
5077 | # Be more Bourne compatible | |
5078 | DUALCASE=1; export DUALCASE # for MKS sh | |
5079 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : | |
5080 | emulate sh | |
5081 | NULLCMD=: | |
5082 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which | |
5083 | # is contrary to our usage. Disable this feature. | |
5084 | alias -g '${1+"$@"}'='"$@"' | |
5085 | setopt NO_GLOB_SUBST | |
5086 | else | |
5087 | case `(set -o) 2>/dev/null` in #( | |
5088 | *posix*) : | |
5089 | set -o posix ;; #( | |
5090 | *) : | |
5091 | ;; | |
5092 | esac | |
5093 | fi | |
5094 | ||
5095 | ||
5096 | as_nl=' | |
5097 | ' | |
5098 | export as_nl | |
5099 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
5100 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
5101 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
5102 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
5103 | # Prefer a ksh shell builtin over an external printf program on Solaris, | |
5104 | # but without wasting forks for bash or zsh. | |
5105 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
5106 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
5107 | as_echo='print -r --' | |
5108 | as_echo_n='print -rn --' | |
5109 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
5110 | as_echo='printf %s\n' | |
5111 | as_echo_n='printf %s' | |
5112 | else | |
5113 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
5114 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
5115 | as_echo_n='/usr/ucb/echo -n' | |
5116 | else | |
5117 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
5118 | as_echo_n_body='eval | |
5119 | arg=$1; | |
5120 | case $arg in #( | |
5121 | *"$as_nl"*) | |
5122 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
5123 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
5124 | esac; | |
5125 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
5126 | ' | |
5127 | export as_echo_n_body | |
5128 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
5129 | fi | |
5130 | export as_echo_body | |
5131 | as_echo='sh -c $as_echo_body as_echo' | |
5132 | fi | |
5133 | ||
5134 | # The user is always right. | |
5135 | if test "${PATH_SEPARATOR+set}" != set; then | |
5136 | PATH_SEPARATOR=: | |
5137 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
5138 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
5139 | PATH_SEPARATOR=';' | |
5140 | } | |
5141 | fi | |
5142 | ||
5143 | ||
5144 | # IFS | |
5145 | # We need space, tab and new line, in precisely that order. Quoting is | |
5146 | # there to prevent editors from complaining about space-tab. | |
5147 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
5148 | # splitting by setting IFS to empty value.) | |
5149 | IFS=" "" $as_nl" | |
5150 | ||
5151 | # Find who we are. Look in the path if we contain no directory separator. | |
5152 | as_myself= | |
5153 | case $0 in #(( | |
5154 | *[\\/]* ) as_myself=$0 ;; | |
5155 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5156 | for as_dir in $PATH | |
5157 | do | |
5158 | IFS=$as_save_IFS | |
5159 | test -z "$as_dir" && as_dir=. | |
5160 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
5161 | done | |
5162 | IFS=$as_save_IFS | |
5163 | ||
5164 | ;; | |
5165 | esac | |
5166 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
5167 | # in which case we are not to be found in the path. | |
5168 | if test "x$as_myself" = x; then | |
5169 | as_myself=$0 | |
5170 | fi | |
5171 | if test ! -f "$as_myself"; then | |
5172 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
5173 | exit 1 | |
5174 | fi | |
5175 | ||
5176 | # Unset variables that we do not need and which cause bugs (e.g. in | |
5177 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
5178 | # suppresses any "Segmentation fault" message there. '((' could | |
5179 | # trigger a bug in pdksh 5.2.14. | |
5180 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
5181 | do eval test x\${$as_var+set} = xset \ | |
5182 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
5183 | done | |
5184 | PS1='$ ' | |
5185 | PS2='> ' | |
5186 | PS4='+ ' | |
5187 | ||
5188 | # NLS nuisances. | |
5189 | LC_ALL=C | |
5190 | export LC_ALL | |
5191 | LANGUAGE=C | |
5192 | export LANGUAGE | |
5193 | ||
5194 | # CDPATH. | |
5195 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
5196 | ||
5197 | ||
5198 | # as_fn_error STATUS ERROR [LINENO LOG_FD] | |
5199 | # ---------------------------------------- | |
5200 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
5201 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
5202 | # script with STATUS, using 1 if that was 0. | |
5203 | as_fn_error () | |
5204 | { | |
5205 | as_status=$1; test $as_status -eq 0 && as_status=1 | |
5206 | if test "$4"; then | |
5207 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
5208 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
5209 | fi | |
5210 | $as_echo "$as_me: error: $2" >&2 | |
5211 | as_fn_exit $as_status | |
5212 | } # as_fn_error | |
5213 | ||
5214 | ||
5215 | # as_fn_set_status STATUS | |
5216 | # ----------------------- | |
5217 | # Set $? to STATUS, without forking. | |
5218 | as_fn_set_status () | |
5219 | { | |
5220 | return $1 | |
5221 | } # as_fn_set_status | |
5222 | ||
5223 | # as_fn_exit STATUS | |
5224 | # ----------------- | |
5225 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
5226 | as_fn_exit () | |
5227 | { | |
5228 | set +e | |
5229 | as_fn_set_status $1 | |
5230 | exit $1 | |
5231 | } # as_fn_exit | |
5232 | ||
5233 | # as_fn_unset VAR | |
5234 | # --------------- | |
5235 | # Portably unset VAR. | |
5236 | as_fn_unset () | |
5237 | { | |
5238 | { eval $1=; unset $1;} | |
5239 | } | |
5240 | as_unset=as_fn_unset | |
5241 | # as_fn_append VAR VALUE | |
5242 | # ---------------------- | |
5243 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
5244 | # advantage of any shell optimizations that allow amortized linear growth over | |
5245 | # repeated appends, instead of the typical quadratic growth present in naive | |
5246 | # implementations. | |
5247 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
5248 | eval 'as_fn_append () | |
5249 | { | |
5250 | eval $1+=\$2 | |
5251 | }' | |
5252 | else | |
5253 | as_fn_append () | |
5254 | { | |
5255 | eval $1=\$$1\$2 | |
5256 | } | |
5257 | fi # as_fn_append | |
5258 | ||
5259 | # as_fn_arith ARG... | |
5260 | # ------------------ | |
5261 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
5262 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
5263 | # must be portable across $(()) and expr. | |
5264 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
5265 | eval 'as_fn_arith () | |
5266 | { | |
5267 | as_val=$(( $* )) | |
5268 | }' | |
5269 | else | |
5270 | as_fn_arith () | |
5271 | { | |
5272 | as_val=`expr "$@" || test $? -eq 1` | |
5273 | } | |
5274 | fi # as_fn_arith | |
5275 | ||
5276 | ||
5277 | if expr a : '\(a\)' >/dev/null 2>&1 && | |
5278 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
5279 | as_expr=expr | |
5280 | else | |
5281 | as_expr=false | |
5282 | fi | |
5283 | ||
5284 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then | |
5285 | as_basename=basename | |
5286 | else | |
5287 | as_basename=false | |
5288 | fi | |
5289 | ||
5290 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then | |
5291 | as_dirname=dirname | |
5292 | else | |
5293 | as_dirname=false | |
5294 | fi | |
5295 | ||
5296 | as_me=`$as_basename -- "$0" || | |
5297 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ | |
5298 | X"$0" : 'X\(//\)$' \| \ | |
5299 | X"$0" : 'X\(/\)' \| . 2>/dev/null || | |
5300 | $as_echo X/"$0" | | |
5301 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
5302 | s//\1/ | |
5303 | q | |
5304 | } | |
5305 | /^X\/\(\/\/\)$/{ | |
5306 | s//\1/ | |
5307 | q | |
5308 | } | |
5309 | /^X\/\(\/\).*/{ | |
5310 | s//\1/ | |
5311 | q | |
5312 | } | |
5313 | s/.*/./; q'` | |
5314 | ||
5315 | # Avoid depending upon Character Ranges. | |
5316 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
5317 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
5318 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
5319 | as_cr_digits='0123456789' | |
5320 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
5321 | ||
5322 | ECHO_C= ECHO_N= ECHO_T= | |
5323 | case `echo -n x` in #((((( | |
5324 | -n*) | |
5325 | case `echo 'xy\c'` in | |
5326 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
5327 | xy) ECHO_C='\c';; | |
5328 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
5329 | ECHO_T=' ';; | |
5330 | esac;; | |
5331 | *) | |
5332 | ECHO_N='-n';; | |
5333 | esac | |
5334 | ||
5335 | rm -f conf$$ conf$$.exe conf$$.file | |
5336 | if test -d conf$$.dir; then | |
5337 | rm -f conf$$.dir/conf$$.file | |
5338 | else | |
5339 | rm -f conf$$.dir | |
5340 | mkdir conf$$.dir 2>/dev/null | |
5341 | fi | |
5342 | if (echo >conf$$.file) 2>/dev/null; then | |
5343 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
5344 | as_ln_s='ln -s' | |
5345 | # ... but there are two gotchas: | |
5346 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
5347 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
5348 | # In both cases, we have to default to `cp -p'. | |
5349 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
5350 | as_ln_s='cp -p' | |
5351 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
5352 | as_ln_s=ln | |
5353 | else | |
5354 | as_ln_s='cp -p' | |
5355 | fi | |
5356 | else | |
5357 | as_ln_s='cp -p' | |
5358 | fi | |
5359 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file | |
5360 | rmdir conf$$.dir 2>/dev/null | |
5361 | ||
5362 | ||
5363 | # as_fn_mkdir_p | |
5364 | # ------------- | |
5365 | # Create "$as_dir" as a directory, including parents if necessary. | |
5366 | as_fn_mkdir_p () | |
5367 | { | |
5368 | ||
5369 | case $as_dir in #( | |
5370 | -*) as_dir=./$as_dir;; | |
5371 | esac | |
5372 | test -d "$as_dir" || eval $as_mkdir_p || { | |
5373 | as_dirs= | |
5374 | while :; do | |
5375 | case $as_dir in #( | |
5376 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
5377 | *) as_qdir=$as_dir;; | |
5378 | esac | |
5379 | as_dirs="'$as_qdir' $as_dirs" | |
5380 | as_dir=`$as_dirname -- "$as_dir" || | |
5381 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
5382 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
5383 | X"$as_dir" : 'X\(//\)$' \| \ | |
5384 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
5385 | $as_echo X"$as_dir" | | |
5386 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
5387 | s//\1/ | |
5388 | q | |
5389 | } | |
5390 | /^X\(\/\/\)[^/].*/{ | |
5391 | s//\1/ | |
5392 | q | |
5393 | } | |
5394 | /^X\(\/\/\)$/{ | |
5395 | s//\1/ | |
5396 | q | |
5397 | } | |
5398 | /^X\(\/\).*/{ | |
5399 | s//\1/ | |
5400 | q | |
5401 | } | |
5402 | s/.*/./; q'` | |
5403 | test -d "$as_dir" && break | |
5404 | done | |
5405 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
5406 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" | |
5407 | ||
5408 | ||
5409 | } # as_fn_mkdir_p | |
5410 | if mkdir -p . 2>/dev/null; then | |
5411 | as_mkdir_p='mkdir -p "$as_dir"' | |
5412 | else | |
5413 | test -d ./-p && rmdir ./-p | |
5414 | as_mkdir_p=false | |
5415 | fi | |
5416 | ||
5417 | if test -x / >/dev/null 2>&1; then | |
5418 | as_test_x='test -x' | |
5419 | else | |
5420 | if ls -dL / >/dev/null 2>&1; then | |
5421 | as_ls_L_option=L | |
5422 | else | |
5423 | as_ls_L_option= | |
5424 | fi | |
5425 | as_test_x=' | |
5426 | eval sh -c '\'' | |
5427 | if test -d "$1"; then | |
5428 | test -d "$1/."; | |
5429 | else | |
5430 | case $1 in #( | |
5431 | -*)set "./$1";; | |
5432 | esac; | |
5433 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( | |
5434 | ???[sx]*):;;*)false;;esac;fi | |
5435 | '\'' sh | |
5436 | ' | |
5437 | fi | |
5438 | as_executable_p=$as_test_x | |
5439 | ||
5440 | # Sed expression to map a string onto a valid CPP name. | |
5441 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" | |
5442 | ||
5443 | # Sed expression to map a string onto a valid variable name. | |
5444 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" | |
5445 | ||
5446 | ||
5447 | exec 6>&1 | |
5448 | ## ----------------------------------- ## | |
5449 | ## Main body of $CONFIG_STATUS script. ## | |
5450 | ## ----------------------------------- ## | |
5451 | _ASEOF | |
5452 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 | |
5453 | ||
5454 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5455 | # Save the log message, to keep $0 and so on meaningful, and to | |
5456 | # report actual input values of CONFIG_FILES etc. instead of their | |
5457 | # values after options handling. | |
5458 | ac_log=" | |
5459 | This file was extended by rendercheck $as_me 1.4, which was | |
5460 | generated by GNU Autoconf 2.68. Invocation command line was | |
5461 | ||
5462 | CONFIG_FILES = $CONFIG_FILES | |
5463 | CONFIG_HEADERS = $CONFIG_HEADERS | |
5464 | CONFIG_LINKS = $CONFIG_LINKS | |
5465 | CONFIG_COMMANDS = $CONFIG_COMMANDS | |
5466 | $ $0 $@ | |
5467 | ||
5468 | on `(hostname || uname -n) 2>/dev/null | sed 1q` | |
5469 | " | |
5470 | ||
5471 | _ACEOF | |
5472 | ||
5473 | case $ac_config_files in *" | |
5474 | "*) set x $ac_config_files; shift; ac_config_files=$*;; | |
5475 | esac | |
5476 | ||
5477 | ||
5478 | ||
5479 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
5480 | # Files that config.status was made for. | |
5481 | config_files="$ac_config_files" | |
5482 | config_commands="$ac_config_commands" | |
5483 | ||
5484 | _ACEOF | |
5485 | ||
5486 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5487 | ac_cs_usage="\ | |
5488 | \`$as_me' instantiates files and other configuration actions | |
5489 | from templates according to the current configuration. Unless the files | |
5490 | and actions are specified as TAGs, all are instantiated by default. | |
5491 | ||
5492 | Usage: $0 [OPTION]... [TAG]... | |
5493 | ||
5494 | -h, --help print this help, then exit | |
5495 | -V, --version print version number and configuration settings, then exit | |
5496 | --config print configuration, then exit | |
5497 | -q, --quiet, --silent | |
5498 | do not print progress messages | |
5499 | -d, --debug don't remove temporary files | |
5500 | --recheck update $as_me by reconfiguring in the same conditions | |
5501 | --file=FILE[:TEMPLATE] | |
5502 | instantiate the configuration file FILE | |
5503 | ||
5504 | Configuration files: | |
5505 | $config_files | |
5506 | ||
5507 | Configuration commands: | |
5508 | $config_commands | |
5509 | ||
5510 | Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>." | |
5511 | ||
5512 | _ACEOF | |
5513 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
5514 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" | |
5515 | ac_cs_version="\\ | |
5516 | rendercheck config.status 1.4 | |
5517 | configured by $0, generated by GNU Autoconf 2.68, | |
5518 | with options \\"\$ac_cs_config\\" | |
5519 | ||
5520 | Copyright (C) 2010 Free Software Foundation, Inc. | |
5521 | This config.status script is free software; the Free Software Foundation | |
5522 | gives unlimited permission to copy, distribute and modify it." | |
5523 | ||
5524 | ac_pwd='$ac_pwd' | |
5525 | srcdir='$srcdir' | |
5526 | INSTALL='$INSTALL' | |
5527 | MKDIR_P='$MKDIR_P' | |
5528 | AWK='$AWK' | |
5529 | test -n "\$AWK" || AWK=awk | |
5530 | _ACEOF | |
5531 | ||
5532 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5533 | # The default lists apply if the user does not specify any file. | |
5534 | ac_need_defaults=: | |
5535 | while test $# != 0 | |
5536 | do | |
5537 | case $1 in | |
5538 | --*=?*) | |
5539 | ac_option=`expr "X$1" : 'X\([^=]*\)='` | |
5540 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` | |
5541 | ac_shift=: | |
5542 | ;; | |
5543 | --*=) | |
5544 | ac_option=`expr "X$1" : 'X\([^=]*\)='` | |
5545 | ac_optarg= | |
5546 | ac_shift=: | |
5547 | ;; | |
5548 | *) | |
5549 | ac_option=$1 | |
5550 | ac_optarg=$2 | |
5551 | ac_shift=shift | |
5552 | ;; | |
5553 | esac | |
5554 | ||
5555 | case $ac_option in | |
5556 | # Handling of the options. | |
5557 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) | |
5558 | ac_cs_recheck=: ;; | |
5559 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) | |
5560 | $as_echo "$ac_cs_version"; exit ;; | |
5561 | --config | --confi | --conf | --con | --co | --c ) | |
5562 | $as_echo "$ac_cs_config"; exit ;; | |
5563 | --debug | --debu | --deb | --de | --d | -d ) | |
5564 | debug=: ;; | |
5565 | --file | --fil | --fi | --f ) | |
5566 | $ac_shift | |
5567 | case $ac_optarg in | |
5568 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
5569 | '') as_fn_error $? "missing file argument" ;; | |
5570 | esac | |
5571 | as_fn_append CONFIG_FILES " '$ac_optarg'" | |
5572 | ac_need_defaults=false;; | |
5573 | --he | --h | --help | --hel | -h ) | |
5574 | $as_echo "$ac_cs_usage"; exit ;; | |
5575 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
5576 | | -silent | --silent | --silen | --sile | --sil | --si | --s) | |
5577 | ac_cs_silent=: ;; | |
5578 | ||
5579 | # This is an error. | |
5580 | -*) as_fn_error $? "unrecognized option: \`$1' | |
5581 | Try \`$0 --help' for more information." ;; | |
5582 | ||
5583 | *) as_fn_append ac_config_targets " $1" | |
5584 | ac_need_defaults=false ;; | |
5585 | ||
5586 | esac | |
5587 | shift | |
5588 | done | |
5589 | ||
5590 | ac_configure_extra_args= | |
5591 | ||
5592 | if $ac_cs_silent; then | |
5593 | exec 6>/dev/null | |
5594 | ac_configure_extra_args="$ac_configure_extra_args --silent" | |
5595 | fi | |
5596 | ||
5597 | _ACEOF | |
5598 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
5599 | if \$ac_cs_recheck; then | |
5600 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion | |
5601 | shift | |
5602 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 | |
5603 | CONFIG_SHELL='$SHELL' | |
5604 | export CONFIG_SHELL | |
5605 | exec "\$@" | |
5606 | fi | |
5607 | ||
5608 | _ACEOF | |
5609 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5610 | exec 5>>config.log | |
5611 | { | |
5612 | echo | |
5613 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX | |
5614 | ## Running $as_me. ## | |
5615 | _ASBOX | |
5616 | $as_echo "$ac_log" | |
5617 | } >&5 | |
5618 | ||
5619 | _ACEOF | |
5620 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
5621 | # | |
5622 | # INIT-COMMANDS | |
5623 | # | |
5624 | AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir" | |
5625 | ||
5626 | _ACEOF | |
5627 | ||
5628 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5629 | ||
5630 | # Handling of arguments. | |
5631 | for ac_config_target in $ac_config_targets | |
5632 | do | |
5633 | case $ac_config_target in | |
5634 | "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;; | |
5635 | "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; | |
5636 | "man/Makefile") CONFIG_FILES="$CONFIG_FILES man/Makefile" ;; | |
5637 | ||
5638 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; | |
5639 | esac | |
5640 | done | |
5641 | ||
5642 | ||
5643 | # If the user did not use the arguments to specify the items to instantiate, | |
5644 | # then the envvar interface is used. Set only those that are not. | |
5645 | # We use the long form for the default assignment because of an extremely | |
5646 | # bizarre bug on SunOS 4.1.3. | |
5647 | if $ac_need_defaults; then | |
5648 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files | |
5649 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands | |
5650 | fi | |
5651 | ||
5652 | # Have a temporary directory for convenience. Make it in the build tree | |
5653 | # simply because there is no reason against having it here, and in addition, | |
5654 | # creating and moving files from /tmp can sometimes cause problems. | |
5655 | # Hook for its removal unless debugging. | |
5656 | # Note that there is a small window in which the directory will not be cleaned: | |
5657 | # after its creation but before its name has been assigned to `$tmp'. | |
5658 | $debug || | |
5659 | { | |
5660 | tmp= ac_tmp= | |
5661 | trap 'exit_status=$? | |
5662 | : "${ac_tmp:=$tmp}" | |
5663 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status | |
5664 | ' 0 | |
5665 | trap 'as_fn_exit 1' 1 2 13 15 | |
5666 | } | |
5667 | # Create a (secure) tmp directory for tmp files. | |
5668 | ||
5669 | { | |
5670 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && | |
5671 | test -d "$tmp" | |
5672 | } || | |
5673 | { | |
5674 | tmp=./conf$$-$RANDOM | |
5675 | (umask 077 && mkdir "$tmp") | |
5676 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 | |
5677 | ac_tmp=$tmp | |
5678 | ||
5679 | # Set up the scripts for CONFIG_FILES section. | |
5680 | # No need to generate them if there are no CONFIG_FILES. | |
5681 | # This happens for instance with `./config.status config.h'. | |
5682 | if test -n "$CONFIG_FILES"; then | |
5683 | ||
5684 | ||
5685 | ac_cr=`echo X | tr X '\015'` | |
5686 | # On cygwin, bash can eat \r inside `` if the user requested igncr. | |
5687 | # But we know of no other shell where ac_cr would be empty at this | |
5688 | # point, so we can use a bashism as a fallback. | |
5689 | if test "x$ac_cr" = x; then | |
5690 | eval ac_cr=\$\'\\r\' | |
5691 | fi | |
5692 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` | |
5693 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then | |
5694 | ac_cs_awk_cr='\\r' | |
5695 | else | |
5696 | ac_cs_awk_cr=$ac_cr | |
5697 | fi | |
5698 | ||
5699 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && | |
5700 | _ACEOF | |
5701 | ||
5702 | ||
5703 | { | |
5704 | echo "cat >conf$$subs.awk <<_ACEOF" && | |
5705 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && | |
5706 | echo "_ACEOF" | |
5707 | } >conf$$subs.sh || | |
5708 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 | |
5709 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` | |
5710 | ac_delim='%!_!# ' | |
5711 | for ac_last_try in false false false false false :; do | |
5712 | . ./conf$$subs.sh || | |
5713 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 | |
5714 | ||
5715 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` | |
5716 | if test $ac_delim_n = $ac_delim_num; then | |
5717 | break | |
5718 | elif $ac_last_try; then | |
5719 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 | |
5720 | else | |
5721 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
5722 | fi | |
5723 | done | |
5724 | rm -f conf$$subs.sh | |
5725 | ||
5726 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
5727 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && | |
5728 | _ACEOF | |
5729 | sed -n ' | |
5730 | h | |
5731 | s/^/S["/; s/!.*/"]=/ | |
5732 | p | |
5733 | g | |
5734 | s/^[^!]*!// | |
5735 | :repl | |
5736 | t repl | |
5737 | s/'"$ac_delim"'$// | |
5738 | t delim | |
5739 | :nl | |
5740 | h | |
5741 | s/\(.\{148\}\)..*/\1/ | |
5742 | t more1 | |
5743 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ | |
5744 | p | |
5745 | n | |
5746 | b repl | |
5747 | :more1 | |
5748 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
5749 | p | |
5750 | g | |
5751 | s/.\{148\}// | |
5752 | t nl | |
5753 | :delim | |
5754 | h | |
5755 | s/\(.\{148\}\)..*/\1/ | |
5756 | t more2 | |
5757 | s/["\\]/\\&/g; s/^/"/; s/$/"/ | |
5758 | p | |
5759 | b | |
5760 | :more2 | |
5761 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
5762 | p | |
5763 | g | |
5764 | s/.\{148\}// | |
5765 | t delim | |
5766 | ' <conf$$subs.awk | sed ' | |
5767 | /^[^""]/{ | |
5768 | N | |
5769 | s/\n// | |
5770 | } | |
5771 | ' >>$CONFIG_STATUS || ac_write_fail=1 | |
5772 | rm -f conf$$subs.awk | |
5773 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
5774 | _ACAWK | |
5775 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && | |
5776 | for (key in S) S_is_set[key] = 1 | |
5777 | FS = "" | |
5778 | ||
5779 | } | |
5780 | { | |
5781 | line = $ 0 | |
5782 | nfields = split(line, field, "@") | |
5783 | substed = 0 | |
5784 | len = length(field[1]) | |
5785 | for (i = 2; i < nfields; i++) { | |
5786 | key = field[i] | |
5787 | keylen = length(key) | |
5788 | if (S_is_set[key]) { | |
5789 | value = S[key] | |
5790 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) | |
5791 | len += length(value) + length(field[++i]) | |
5792 | substed = 1 | |
5793 | } else | |
5794 | len += 1 + keylen | |
5795 | } | |
5796 | ||
5797 | print line | |
5798 | } | |
5799 | ||
5800 | _ACAWK | |
5801 | _ACEOF | |
5802 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5803 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then | |
5804 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" | |
5805 | else | |
5806 | cat | |
5807 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ | |
5808 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 | |
5809 | _ACEOF | |
5810 | ||
5811 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), | |
5812 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and | |
5813 | # trailing colons and then remove the whole line if VPATH becomes empty | |
5814 | # (actually we leave an empty line to preserve line numbers). | |
5815 | if test "x$srcdir" = x.; then | |
5816 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ | |
5817 | h | |
5818 | s/// | |
5819 | s/^/:/ | |
5820 | s/[ ]*$/:/ | |
5821 | s/:\$(srcdir):/:/g | |
5822 | s/:\${srcdir}:/:/g | |
5823 | s/:@srcdir@:/:/g | |
5824 | s/^:*// | |
5825 | s/:*$// | |
5826 | x | |
5827 | s/\(=[ ]*\).*/\1/ | |
5828 | G | |
5829 | s/\n// | |
5830 | s/^[^=]*=[ ]*$// | |
5831 | }' | |
5832 | fi | |
5833 | ||
5834 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5835 | fi # test -n "$CONFIG_FILES" | |
5836 | ||
5837 | ||
5838 | eval set X " :F $CONFIG_FILES :C $CONFIG_COMMANDS" | |
5839 | shift | |
5840 | for ac_tag | |
5841 | do | |
5842 | case $ac_tag in | |
5843 | :[FHLC]) ac_mode=$ac_tag; continue;; | |
5844 | esac | |
5845 | case $ac_mode$ac_tag in | |
5846 | :[FHL]*:*);; | |
5847 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; | |
5848 | :[FH]-) ac_tag=-:-;; | |
5849 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; | |
5850 | esac | |
5851 | ac_save_IFS=$IFS | |
5852 | IFS=: | |
5853 | set x $ac_tag | |
5854 | IFS=$ac_save_IFS | |
5855 | shift | |
5856 | ac_file=$1 | |
5857 | shift | |
5858 | ||
5859 | case $ac_mode in | |
5860 | :L) ac_source=$1;; | |
5861 | :[FH]) | |
5862 | ac_file_inputs= | |
5863 | for ac_f | |
5864 | do | |
5865 | case $ac_f in | |
5866 | -) ac_f="$ac_tmp/stdin";; | |
5867 | *) # Look for the file first in the build tree, then in the source tree | |
5868 | # (if the path is not absolute). The absolute path cannot be DOS-style, | |
5869 | # because $ac_f cannot contain `:'. | |
5870 | test -f "$ac_f" || | |
5871 | case $ac_f in | |
5872 | [\\/$]*) false;; | |
5873 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; | |
5874 | esac || | |
5875 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; | |
5876 | esac | |
5877 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac | |
5878 | as_fn_append ac_file_inputs " '$ac_f'" | |
5879 | done | |
5880 | ||
5881 | # Let's still pretend it is `configure' which instantiates (i.e., don't | |
5882 | # use $as_me), people would be surprised to read: | |
5883 | # /* config.h. Generated by config.status. */ | |
5884 | configure_input='Generated from '` | |
5885 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' | |
5886 | `' by configure.' | |
5887 | if test x"$ac_file" != x-; then | |
5888 | configure_input="$ac_file. $configure_input" | |
5889 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 | |
5890 | $as_echo "$as_me: creating $ac_file" >&6;} | |
5891 | fi | |
5892 | # Neutralize special characters interpreted by sed in replacement strings. | |
5893 | case $configure_input in #( | |
5894 | *\&* | *\|* | *\\* ) | |
5895 | ac_sed_conf_input=`$as_echo "$configure_input" | | |
5896 | sed 's/[\\\\&|]/\\\\&/g'`;; #( | |
5897 | *) ac_sed_conf_input=$configure_input;; | |
5898 | esac | |
5899 | ||
5900 | case $ac_tag in | |
5901 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ | |
5902 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; | |
5903 | esac | |
5904 | ;; | |
5905 | esac | |
5906 | ||
5907 | ac_dir=`$as_dirname -- "$ac_file" || | |
5908 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
5909 | X"$ac_file" : 'X\(//\)[^/]' \| \ | |
5910 | X"$ac_file" : 'X\(//\)$' \| \ | |
5911 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || | |
5912 | $as_echo X"$ac_file" | | |
5913 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
5914 | s//\1/ | |
5915 | q | |
5916 | } | |
5917 | /^X\(\/\/\)[^/].*/{ | |
5918 | s//\1/ | |
5919 | q | |
5920 | } | |
5921 | /^X\(\/\/\)$/{ | |
5922 | s//\1/ | |
5923 | q | |
5924 | } | |
5925 | /^X\(\/\).*/{ | |
5926 | s//\1/ | |
5927 | q | |
5928 | } | |
5929 | s/.*/./; q'` | |
5930 | as_dir="$ac_dir"; as_fn_mkdir_p | |
5931 | ac_builddir=. | |
5932 | ||
5933 | case "$ac_dir" in | |
5934 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
5935 | *) | |
5936 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
5937 | # A ".." for each directory in $ac_dir_suffix. | |
5938 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
5939 | case $ac_top_builddir_sub in | |
5940 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
5941 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
5942 | esac ;; | |
5943 | esac | |
5944 | ac_abs_top_builddir=$ac_pwd | |
5945 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
5946 | # for backward compatibility: | |
5947 | ac_top_builddir=$ac_top_build_prefix | |
5948 | ||
5949 | case $srcdir in | |
5950 | .) # We are building in place. | |
5951 | ac_srcdir=. | |
5952 | ac_top_srcdir=$ac_top_builddir_sub | |
5953 | ac_abs_top_srcdir=$ac_pwd ;; | |
5954 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
5955 | ac_srcdir=$srcdir$ac_dir_suffix; | |
5956 | ac_top_srcdir=$srcdir | |
5957 | ac_abs_top_srcdir=$srcdir ;; | |
5958 | *) # Relative name. | |
5959 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
5960 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
5961 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
5962 | esac | |
5963 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix | |
5964 | ||
5965 | ||
5966 | case $ac_mode in | |
5967 | :F) | |
5968 | # | |
5969 | # CONFIG_FILE | |
5970 | # | |
5971 | ||
5972 | case $INSTALL in | |
5973 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; | |
5974 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; | |
5975 | esac | |
5976 | ac_MKDIR_P=$MKDIR_P | |
5977 | case $MKDIR_P in | |
5978 | [\\/$]* | ?:[\\/]* ) ;; | |
5979 | */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;; | |
5980 | esac | |
5981 | _ACEOF | |
5982 | ||
5983 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
5984 | # If the template does not know about datarootdir, expand it. | |
5985 | # FIXME: This hack should be removed a few years after 2.60. | |
5986 | ac_datarootdir_hack=; ac_datarootdir_seen= | |
5987 | ac_sed_dataroot=' | |
5988 | /datarootdir/ { | |
5989 | p | |
5990 | q | |
5991 | } | |
5992 | /@datadir@/p | |
5993 | /@docdir@/p | |
5994 | /@infodir@/p | |
5995 | /@localedir@/p | |
5996 | /@mandir@/p' | |
5997 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in | |
5998 | *datarootdir*) ac_datarootdir_seen=yes;; | |
5999 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) | |
6000 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 | |
6001 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} | |
6002 | _ACEOF | |
6003 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
6004 | ac_datarootdir_hack=' | |
6005 | s&@datadir@&$datadir&g | |
6006 | s&@docdir@&$docdir&g | |
6007 | s&@infodir@&$infodir&g | |
6008 | s&@localedir@&$localedir&g | |
6009 | s&@mandir@&$mandir&g | |
6010 | s&\\\${datarootdir}&$datarootdir&g' ;; | |
6011 | esac | |
6012 | _ACEOF | |
6013 | ||
6014 | # Neutralize VPATH when `$srcdir' = `.'. | |
6015 | # Shell code in configure.ac might set extrasub. | |
6016 | # FIXME: do we really want to maintain this feature? | |
6017 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
6018 | ac_sed_extra="$ac_vpsub | |
6019 | $extrasub | |
6020 | _ACEOF | |
6021 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
6022 | :t | |
6023 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b | |
6024 | s|@configure_input@|$ac_sed_conf_input|;t t | |
6025 | s&@top_builddir@&$ac_top_builddir_sub&;t t | |
6026 | s&@top_build_prefix@&$ac_top_build_prefix&;t t | |
6027 | s&@srcdir@&$ac_srcdir&;t t | |
6028 | s&@abs_srcdir@&$ac_abs_srcdir&;t t | |
6029 | s&@top_srcdir@&$ac_top_srcdir&;t t | |
6030 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |
6031 | s&@builddir@&$ac_builddir&;t t | |
6032 | s&@abs_builddir@&$ac_abs_builddir&;t t | |
6033 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | |
6034 | s&@INSTALL@&$ac_INSTALL&;t t | |
6035 | s&@MKDIR_P@&$ac_MKDIR_P&;t t | |
6036 | $ac_datarootdir_hack | |
6037 | " | |
6038 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ | |
6039 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
6040 | ||
6041 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && | |
6042 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && | |
6043 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ | |
6044 | "$ac_tmp/out"`; test -z "$ac_out"; } && | |
6045 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' | |
6046 | which seems to be undefined. Please make sure it is defined" >&5 | |
6047 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' | |
6048 | which seems to be undefined. Please make sure it is defined" >&2;} | |
6049 | ||
6050 | rm -f "$ac_tmp/stdin" | |
6051 | case $ac_file in | |
6052 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; | |
6053 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; | |
6054 | esac \ | |
6055 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
6056 | ;; | |
6057 | ||
6058 | ||
6059 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 | |
6060 | $as_echo "$as_me: executing $ac_file commands" >&6;} | |
6061 | ;; | |
6062 | esac | |
6063 | ||
6064 | ||
6065 | case $ac_file$ac_mode in | |
6066 | "depfiles":C) test x"$AMDEP_TRUE" != x"" || { | |
6067 | # Autoconf 2.62 quotes --file arguments for eval, but not when files | |
6068 | # are listed without --file. Let's play safe and only enable the eval | |
6069 | # if we detect the quoting. | |
6070 | case $CONFIG_FILES in | |
6071 | *\'*) eval set x "$CONFIG_FILES" ;; | |
6072 | *) set x $CONFIG_FILES ;; | |
6073 | esac | |
6074 | shift | |
6075 | for mf | |
6076 | do | |
6077 | # Strip MF so we end up with the name of the file. | |
6078 | mf=`echo "$mf" | sed -e 's/:.*$//'` | |
6079 | # Check whether this is an Automake generated Makefile or not. | |
6080 | # We used to match only the files named `Makefile.in', but | |
6081 | # some people rename them; so instead we look at the file content. | |
6082 | # Grep'ing the first line is not enough: some people post-process | |
6083 | # each Makefile.in and add a new line on top of each file to say so. | |
6084 | # Grep'ing the whole file is not good either: AIX grep has a line | |
6085 | # limit of 2048, but all sed's we know have understand at least 4000. | |
6086 | if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then | |
6087 | dirpart=`$as_dirname -- "$mf" || | |
6088 | $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
6089 | X"$mf" : 'X\(//\)[^/]' \| \ | |
6090 | X"$mf" : 'X\(//\)$' \| \ | |
6091 | X"$mf" : 'X\(/\)' \| . 2>/dev/null || | |
6092 | $as_echo X"$mf" | | |
6093 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
6094 | s//\1/ | |
6095 | q | |
6096 | } | |
6097 | /^X\(\/\/\)[^/].*/{ | |
6098 | s//\1/ | |
6099 | q | |
6100 | } | |
6101 | /^X\(\/\/\)$/{ | |
6102 | s//\1/ | |
6103 | q | |
6104 | } | |
6105 | /^X\(\/\).*/{ | |
6106 | s//\1/ | |
6107 | q | |
6108 | } | |
6109 | s/.*/./; q'` | |
6110 | else | |
6111 | continue | |
6112 | fi | |
6113 | # Extract the definition of DEPDIR, am__include, and am__quote | |
6114 | # from the Makefile without running `make'. | |
6115 | DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"` | |
6116 | test -z "$DEPDIR" && continue | |
6117 | am__include=`sed -n 's/^am__include = //p' < "$mf"` | |
6118 | test -z "am__include" && continue | |
6119 | am__quote=`sed -n 's/^am__quote = //p' < "$mf"` | |
6120 | # When using ansi2knr, U may be empty or an underscore; expand it | |
6121 | U=`sed -n 's/^U = //p' < "$mf"` | |
6122 | # Find all dependency output files, they are included files with | |
6123 | # $(DEPDIR) in their names. We invoke sed twice because it is the | |
6124 | # simplest approach to changing $(DEPDIR) to its actual value in the | |
6125 | # expansion. | |
6126 | for file in `sed -n " | |
6127 | s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \ | |
6128 | sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do | |
6129 | # Make sure the directory exists. | |
6130 | test -f "$dirpart/$file" && continue | |
6131 | fdir=`$as_dirname -- "$file" || | |
6132 | $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
6133 | X"$file" : 'X\(//\)[^/]' \| \ | |
6134 | X"$file" : 'X\(//\)$' \| \ | |
6135 | X"$file" : 'X\(/\)' \| . 2>/dev/null || | |
6136 | $as_echo X"$file" | | |
6137 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
6138 | s//\1/ | |
6139 | q | |
6140 | } | |
6141 | /^X\(\/\/\)[^/].*/{ | |
6142 | s//\1/ | |
6143 | q | |
6144 | } | |
6145 | /^X\(\/\/\)$/{ | |
6146 | s//\1/ | |
6147 | q | |
6148 | } | |
6149 | /^X\(\/\).*/{ | |
6150 | s//\1/ | |
6151 | q | |
6152 | } | |
6153 | s/.*/./; q'` | |
6154 | as_dir=$dirpart/$fdir; as_fn_mkdir_p | |
6155 | # echo "creating $dirpart/$file" | |
6156 | echo '# dummy' > "$dirpart/$file" | |
6157 | done | |
6158 | done | |
6159 | } | |
6160 | ;; | |
6161 | ||
6162 | esac | |
6163 | done # for ac_tag | |
6164 | ||
6165 | ||
6166 | as_fn_exit 0 | |
6167 | _ACEOF | |
6168 | ac_clean_files=$ac_clean_files_save | |
6169 | ||
6170 | test $ac_write_fail = 0 || | |
6171 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 | |
6172 | ||
6173 | ||
6174 | # configure is writing to config.log, and then calls config.status. | |
6175 | # config.status does its own redirection, appending to config.log. | |
6176 | # Unfortunately, on DOS this fails, as config.log is still kept open | |
6177 | # by configure, so config.status won't be able to write to it; its | |
6178 | # output is simply discarded. So we exec the FD to /dev/null, | |
6179 | # effectively closing config.log, so it can be properly (re)opened and | |
6180 | # appended to by config.status. When coming back to configure, we | |
6181 | # need to make the FD available again. | |
6182 | if test "$no_create" != yes; then | |
6183 | ac_cs_success=: | |
6184 | ac_config_status_args= | |
6185 | test "$silent" = yes && | |
6186 | ac_config_status_args="$ac_config_status_args --quiet" | |
6187 | exec 5>/dev/null | |
6188 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false | |
6189 | exec 5>>config.log | |
6190 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which | |
6191 | # would make configure fail if this is the last instruction. | |
6192 | $ac_cs_success || as_fn_exit 1 | |
6193 | fi | |
6194 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then | |
6195 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 | |
6196 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} | |
6197 | fi | |
6198 |
0 | # -*- Autoconf -*- | |
1 | # Process this file with autoconf to produce a configure script. | |
2 | ||
3 | AC_PREREQ(2.60) | |
4 | AC_INIT([rendercheck], | |
5 | [1.4], | |
6 | [https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], | |
7 | [rendercheck]) | |
8 | ||
9 | AC_CONFIG_SRCDIR([Makefile.am]) | |
10 | AM_INIT_AUTOMAKE([foreign dist-bzip2]) | |
11 | ||
12 | AM_MAINTAINER_MODE | |
13 | ||
14 | # Require X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS | |
15 | m4_ifndef([XORG_MACROS_VERSION], | |
16 | [m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])]) | |
17 | XORG_MACROS_VERSION(1.8) | |
18 | XORG_DEFAULT_OPTIONS | |
19 | ||
20 | # Checks for header files. | |
21 | AC_HEADER_STDC | |
22 | AC_CHECK_HEADERS([err.h]) | |
23 | ||
24 | # Checks for pkg-config packages | |
25 | PKG_CHECK_MODULES(RC, [xrender x11]) | |
26 | ||
27 | AC_CONFIG_FILES([Makefile | |
28 | man/Makefile]) | |
29 | ||
30 | AC_OUTPUT |
0 | #! /bin/sh | |
1 | # depcomp - compile a program generating dependencies as side-effects | |
2 | ||
3 | scriptversion=2009-04-28.21; # UTC | |
4 | ||
5 | # Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2009 Free | |
6 | # Software Foundation, Inc. | |
7 | ||
8 | # This program is free software; you can redistribute it and/or modify | |
9 | # it under the terms of the GNU General Public License as published by | |
10 | # the Free Software Foundation; either version 2, or (at your option) | |
11 | # any later version. | |
12 | ||
13 | # This program is distributed in the hope that it will be useful, | |
14 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
15 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
16 | # GNU General Public License for more details. | |
17 | ||
18 | # You should have received a copy of the GNU General Public License | |
19 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
20 | ||
21 | # As a special exception to the GNU General Public License, if you | |
22 | # distribute this file as part of a program that contains a | |
23 | # configuration script generated by Autoconf, you may include it under | |
24 | # the same distribution terms that you use for the rest of that program. | |
25 | ||
26 | # Originally written by Alexandre Oliva <oliva@dcc.unicamp.br>. | |
27 | ||
28 | case $1 in | |
29 | '') | |
30 | echo "$0: No command. Try \`$0 --help' for more information." 1>&2 | |
31 | exit 1; | |
32 | ;; | |
33 | -h | --h*) | |
34 | cat <<\EOF | |
35 | Usage: depcomp [--help] [--version] PROGRAM [ARGS] | |
36 | ||
37 | Run PROGRAMS ARGS to compile a file, generating dependencies | |
38 | as side-effects. | |
39 | ||
40 | Environment variables: | |
41 | depmode Dependency tracking mode. | |
42 | source Source file read by `PROGRAMS ARGS'. | |
43 | object Object file output by `PROGRAMS ARGS'. | |
44 | DEPDIR directory where to store dependencies. | |
45 | depfile Dependency file to output. | |
46 | tmpdepfile Temporary file to use when outputing dependencies. | |
47 | libtool Whether libtool is used (yes/no). | |
48 | ||
49 | Report bugs to <bug-automake@gnu.org>. | |
50 | EOF | |
51 | exit $? | |
52 | ;; | |
53 | -v | --v*) | |
54 | echo "depcomp $scriptversion" | |
55 | exit $? | |
56 | ;; | |
57 | esac | |
58 | ||
59 | if test -z "$depmode" || test -z "$source" || test -z "$object"; then | |
60 | echo "depcomp: Variables source, object and depmode must be set" 1>&2 | |
61 | exit 1 | |
62 | fi | |
63 | ||
64 | # Dependencies for sub/bar.o or sub/bar.obj go into sub/.deps/bar.Po. | |
65 | depfile=${depfile-`echo "$object" | | |
66 | sed 's|[^\\/]*$|'${DEPDIR-.deps}'/&|;s|\.\([^.]*\)$|.P\1|;s|Pobj$|Po|'`} | |
67 | tmpdepfile=${tmpdepfile-`echo "$depfile" | sed 's/\.\([^.]*\)$/.T\1/'`} | |
68 | ||
69 | rm -f "$tmpdepfile" | |
70 | ||
71 | # Some modes work just like other modes, but use different flags. We | |
72 | # parameterize here, but still list the modes in the big case below, | |
73 | # to make depend.m4 easier to write. Note that we *cannot* use a case | |
74 | # here, because this file can only contain one case statement. | |
75 | if test "$depmode" = hp; then | |
76 | # HP compiler uses -M and no extra arg. | |
77 | gccflag=-M | |
78 | depmode=gcc | |
79 | fi | |
80 | ||
81 | if test "$depmode" = dashXmstdout; then | |
82 | # This is just like dashmstdout with a different argument. | |
83 | dashmflag=-xM | |
84 | depmode=dashmstdout | |
85 | fi | |
86 | ||
87 | cygpath_u="cygpath -u -f -" | |
88 | if test "$depmode" = msvcmsys; then | |
89 | # This is just like msvisualcpp but w/o cygpath translation. | |
90 | # Just convert the backslash-escaped backslashes to single forward | |
91 | # slashes to satisfy depend.m4 | |
92 | cygpath_u="sed s,\\\\\\\\,/,g" | |
93 | depmode=msvisualcpp | |
94 | fi | |
95 | ||
96 | case "$depmode" in | |
97 | gcc3) | |
98 | ## gcc 3 implements dependency tracking that does exactly what | |
99 | ## we want. Yay! Note: for some reason libtool 1.4 doesn't like | |
100 | ## it if -MD -MP comes after the -MF stuff. Hmm. | |
101 | ## Unfortunately, FreeBSD c89 acceptance of flags depends upon | |
102 | ## the command line argument order; so add the flags where they | |
103 | ## appear in depend2.am. Note that the slowdown incurred here | |
104 | ## affects only configure: in makefiles, %FASTDEP% shortcuts this. | |
105 | for arg | |
106 | do | |
107 | case $arg in | |
108 | -c) set fnord "$@" -MT "$object" -MD -MP -MF "$tmpdepfile" "$arg" ;; | |
109 | *) set fnord "$@" "$arg" ;; | |
110 | esac | |
111 | shift # fnord | |
112 | shift # $arg | |
113 | done | |
114 | "$@" | |
115 | stat=$? | |
116 | if test $stat -eq 0; then : | |
117 | else | |
118 | rm -f "$tmpdepfile" | |
119 | exit $stat | |
120 | fi | |
121 | mv "$tmpdepfile" "$depfile" | |
122 | ;; | |
123 | ||
124 | gcc) | |
125 | ## There are various ways to get dependency output from gcc. Here's | |
126 | ## why we pick this rather obscure method: | |
127 | ## - Don't want to use -MD because we'd like the dependencies to end | |
128 | ## up in a subdir. Having to rename by hand is ugly. | |
129 | ## (We might end up doing this anyway to support other compilers.) | |
130 | ## - The DEPENDENCIES_OUTPUT environment variable makes gcc act like | |
131 | ## -MM, not -M (despite what the docs say). | |
132 | ## - Using -M directly means running the compiler twice (even worse | |
133 | ## than renaming). | |
134 | if test -z "$gccflag"; then | |
135 | gccflag=-MD, | |
136 | fi | |
137 | "$@" -Wp,"$gccflag$tmpdepfile" | |
138 | stat=$? | |
139 | if test $stat -eq 0; then : | |
140 | else | |
141 | rm -f "$tmpdepfile" | |
142 | exit $stat | |
143 | fi | |
144 | rm -f "$depfile" | |
145 | echo "$object : \\" > "$depfile" | |
146 | alpha=ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz | |
147 | ## The second -e expression handles DOS-style file names with drive letters. | |
148 | sed -e 's/^[^:]*: / /' \ | |
149 | -e 's/^['$alpha']:\/[^:]*: / /' < "$tmpdepfile" >> "$depfile" | |
150 | ## This next piece of magic avoids the `deleted header file' problem. | |
151 | ## The problem is that when a header file which appears in a .P file | |
152 | ## is deleted, the dependency causes make to die (because there is | |
153 | ## typically no way to rebuild the header). We avoid this by adding | |
154 | ## dummy dependencies for each header file. Too bad gcc doesn't do | |
155 | ## this for us directly. | |
156 | tr ' ' ' | |
157 | ' < "$tmpdepfile" | | |
158 | ## Some versions of gcc put a space before the `:'. On the theory | |
159 | ## that the space means something, we add a space to the output as | |
160 | ## well. | |
161 | ## Some versions of the HPUX 10.20 sed can't process this invocation | |
162 | ## correctly. Breaking it into two sed invocations is a workaround. | |
163 | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" | |
164 | rm -f "$tmpdepfile" | |
165 | ;; | |
166 | ||
167 | hp) | |
168 | # This case exists only to let depend.m4 do its work. It works by | |
169 | # looking at the text of this script. This case will never be run, | |
170 | # since it is checked for above. | |
171 | exit 1 | |
172 | ;; | |
173 | ||
174 | sgi) | |
175 | if test "$libtool" = yes; then | |
176 | "$@" "-Wp,-MDupdate,$tmpdepfile" | |
177 | else | |
178 | "$@" -MDupdate "$tmpdepfile" | |
179 | fi | |
180 | stat=$? | |
181 | if test $stat -eq 0; then : | |
182 | else | |
183 | rm -f "$tmpdepfile" | |
184 | exit $stat | |
185 | fi | |
186 | rm -f "$depfile" | |
187 | ||
188 | if test -f "$tmpdepfile"; then # yes, the sourcefile depend on other files | |
189 | echo "$object : \\" > "$depfile" | |
190 | ||
191 | # Clip off the initial element (the dependent). Don't try to be | |
192 | # clever and replace this with sed code, as IRIX sed won't handle | |
193 | # lines with more than a fixed number of characters (4096 in | |
194 | # IRIX 6.2 sed, 8192 in IRIX 6.5). We also remove comment lines; | |
195 | # the IRIX cc adds comments like `#:fec' to the end of the | |
196 | # dependency line. | |
197 | tr ' ' ' | |
198 | ' < "$tmpdepfile" \ | |
199 | | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' | \ | |
200 | tr ' | |
201 | ' ' ' >> "$depfile" | |
202 | echo >> "$depfile" | |
203 | ||
204 | # The second pass generates a dummy entry for each header file. | |
205 | tr ' ' ' | |
206 | ' < "$tmpdepfile" \ | |
207 | | sed -e 's/^.*\.o://' -e 's/#.*$//' -e '/^$/ d' -e 's/$/:/' \ | |
208 | >> "$depfile" | |
209 | else | |
210 | # The sourcefile does not contain any dependencies, so just | |
211 | # store a dummy comment line, to avoid errors with the Makefile | |
212 | # "include basename.Plo" scheme. | |
213 | echo "#dummy" > "$depfile" | |
214 | fi | |
215 | rm -f "$tmpdepfile" | |
216 | ;; | |
217 | ||
218 | aix) | |
219 | # The C for AIX Compiler uses -M and outputs the dependencies | |
220 | # in a .u file. In older versions, this file always lives in the | |
221 | # current directory. Also, the AIX compiler puts `$object:' at the | |
222 | # start of each line; $object doesn't have directory information. | |
223 | # Version 6 uses the directory in both cases. | |
224 | dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` | |
225 | test "x$dir" = "x$object" && dir= | |
226 | base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` | |
227 | if test "$libtool" = yes; then | |
228 | tmpdepfile1=$dir$base.u | |
229 | tmpdepfile2=$base.u | |
230 | tmpdepfile3=$dir.libs/$base.u | |
231 | "$@" -Wc,-M | |
232 | else | |
233 | tmpdepfile1=$dir$base.u | |
234 | tmpdepfile2=$dir$base.u | |
235 | tmpdepfile3=$dir$base.u | |
236 | "$@" -M | |
237 | fi | |
238 | stat=$? | |
239 | ||
240 | if test $stat -eq 0; then : | |
241 | else | |
242 | rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" | |
243 | exit $stat | |
244 | fi | |
245 | ||
246 | for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" | |
247 | do | |
248 | test -f "$tmpdepfile" && break | |
249 | done | |
250 | if test -f "$tmpdepfile"; then | |
251 | # Each line is of the form `foo.o: dependent.h'. | |
252 | # Do two passes, one to just change these to | |
253 | # `$object: dependent.h' and one to simply `dependent.h:'. | |
254 | sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" | |
255 | # That's a tab and a space in the []. | |
256 | sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" | |
257 | else | |
258 | # The sourcefile does not contain any dependencies, so just | |
259 | # store a dummy comment line, to avoid errors with the Makefile | |
260 | # "include basename.Plo" scheme. | |
261 | echo "#dummy" > "$depfile" | |
262 | fi | |
263 | rm -f "$tmpdepfile" | |
264 | ;; | |
265 | ||
266 | icc) | |
267 | # Intel's C compiler understands `-MD -MF file'. However on | |
268 | # icc -MD -MF foo.d -c -o sub/foo.o sub/foo.c | |
269 | # ICC 7.0 will fill foo.d with something like | |
270 | # foo.o: sub/foo.c | |
271 | # foo.o: sub/foo.h | |
272 | # which is wrong. We want: | |
273 | # sub/foo.o: sub/foo.c | |
274 | # sub/foo.o: sub/foo.h | |
275 | # sub/foo.c: | |
276 | # sub/foo.h: | |
277 | # ICC 7.1 will output | |
278 | # foo.o: sub/foo.c sub/foo.h | |
279 | # and will wrap long lines using \ : | |
280 | # foo.o: sub/foo.c ... \ | |
281 | # sub/foo.h ... \ | |
282 | # ... | |
283 | ||
284 | "$@" -MD -MF "$tmpdepfile" | |
285 | stat=$? | |
286 | if test $stat -eq 0; then : | |
287 | else | |
288 | rm -f "$tmpdepfile" | |
289 | exit $stat | |
290 | fi | |
291 | rm -f "$depfile" | |
292 | # Each line is of the form `foo.o: dependent.h', | |
293 | # or `foo.o: dep1.h dep2.h \', or ` dep3.h dep4.h \'. | |
294 | # Do two passes, one to just change these to | |
295 | # `$object: dependent.h' and one to simply `dependent.h:'. | |
296 | sed "s,^[^:]*:,$object :," < "$tmpdepfile" > "$depfile" | |
297 | # Some versions of the HPUX 10.20 sed can't process this invocation | |
298 | # correctly. Breaking it into two sed invocations is a workaround. | |
299 | sed 's,^[^:]*: \(.*\)$,\1,;s/^\\$//;/^$/d;/:$/d' < "$tmpdepfile" | | |
300 | sed -e 's/$/ :/' >> "$depfile" | |
301 | rm -f "$tmpdepfile" | |
302 | ;; | |
303 | ||
304 | hp2) | |
305 | # The "hp" stanza above does not work with aCC (C++) and HP's ia64 | |
306 | # compilers, which have integrated preprocessors. The correct option | |
307 | # to use with these is +Maked; it writes dependencies to a file named | |
308 | # 'foo.d', which lands next to the object file, wherever that | |
309 | # happens to be. | |
310 | # Much of this is similar to the tru64 case; see comments there. | |
311 | dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` | |
312 | test "x$dir" = "x$object" && dir= | |
313 | base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` | |
314 | if test "$libtool" = yes; then | |
315 | tmpdepfile1=$dir$base.d | |
316 | tmpdepfile2=$dir.libs/$base.d | |
317 | "$@" -Wc,+Maked | |
318 | else | |
319 | tmpdepfile1=$dir$base.d | |
320 | tmpdepfile2=$dir$base.d | |
321 | "$@" +Maked | |
322 | fi | |
323 | stat=$? | |
324 | if test $stat -eq 0; then : | |
325 | else | |
326 | rm -f "$tmpdepfile1" "$tmpdepfile2" | |
327 | exit $stat | |
328 | fi | |
329 | ||
330 | for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" | |
331 | do | |
332 | test -f "$tmpdepfile" && break | |
333 | done | |
334 | if test -f "$tmpdepfile"; then | |
335 | sed -e "s,^.*\.[a-z]*:,$object:," "$tmpdepfile" > "$depfile" | |
336 | # Add `dependent.h:' lines. | |
337 | sed -ne '2,${ | |
338 | s/^ *// | |
339 | s/ \\*$// | |
340 | s/$/:/ | |
341 | p | |
342 | }' "$tmpdepfile" >> "$depfile" | |
343 | else | |
344 | echo "#dummy" > "$depfile" | |
345 | fi | |
346 | rm -f "$tmpdepfile" "$tmpdepfile2" | |
347 | ;; | |
348 | ||
349 | tru64) | |
350 | # The Tru64 compiler uses -MD to generate dependencies as a side | |
351 | # effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'. | |
352 | # At least on Alpha/Redhat 6.1, Compaq CCC V6.2-504 seems to put | |
353 | # dependencies in `foo.d' instead, so we check for that too. | |
354 | # Subdirectories are respected. | |
355 | dir=`echo "$object" | sed -e 's|/[^/]*$|/|'` | |
356 | test "x$dir" = "x$object" && dir= | |
357 | base=`echo "$object" | sed -e 's|^.*/||' -e 's/\.o$//' -e 's/\.lo$//'` | |
358 | ||
359 | if test "$libtool" = yes; then | |
360 | # With Tru64 cc, shared objects can also be used to make a | |
361 | # static library. This mechanism is used in libtool 1.4 series to | |
362 | # handle both shared and static libraries in a single compilation. | |
363 | # With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d. | |
364 | # | |
365 | # With libtool 1.5 this exception was removed, and libtool now | |
366 | # generates 2 separate objects for the 2 libraries. These two | |
367 | # compilations output dependencies in $dir.libs/$base.o.d and | |
368 | # in $dir$base.o.d. We have to check for both files, because | |
369 | # one of the two compilations can be disabled. We should prefer | |
370 | # $dir$base.o.d over $dir.libs/$base.o.d because the latter is | |
371 | # automatically cleaned when .libs/ is deleted, while ignoring | |
372 | # the former would cause a distcleancheck panic. | |
373 | tmpdepfile1=$dir.libs/$base.lo.d # libtool 1.4 | |
374 | tmpdepfile2=$dir$base.o.d # libtool 1.5 | |
375 | tmpdepfile3=$dir.libs/$base.o.d # libtool 1.5 | |
376 | tmpdepfile4=$dir.libs/$base.d # Compaq CCC V6.2-504 | |
377 | "$@" -Wc,-MD | |
378 | else | |
379 | tmpdepfile1=$dir$base.o.d | |
380 | tmpdepfile2=$dir$base.d | |
381 | tmpdepfile3=$dir$base.d | |
382 | tmpdepfile4=$dir$base.d | |
383 | "$@" -MD | |
384 | fi | |
385 | ||
386 | stat=$? | |
387 | if test $stat -eq 0; then : | |
388 | else | |
389 | rm -f "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" | |
390 | exit $stat | |
391 | fi | |
392 | ||
393 | for tmpdepfile in "$tmpdepfile1" "$tmpdepfile2" "$tmpdepfile3" "$tmpdepfile4" | |
394 | do | |
395 | test -f "$tmpdepfile" && break | |
396 | done | |
397 | if test -f "$tmpdepfile"; then | |
398 | sed -e "s,^.*\.[a-z]*:,$object:," < "$tmpdepfile" > "$depfile" | |
399 | # That's a tab and a space in the []. | |
400 | sed -e 's,^.*\.[a-z]*:[ ]*,,' -e 's,$,:,' < "$tmpdepfile" >> "$depfile" | |
401 | else | |
402 | echo "#dummy" > "$depfile" | |
403 | fi | |
404 | rm -f "$tmpdepfile" | |
405 | ;; | |
406 | ||
407 | #nosideeffect) | |
408 | # This comment above is used by automake to tell side-effect | |
409 | # dependency tracking mechanisms from slower ones. | |
410 | ||
411 | dashmstdout) | |
412 | # Important note: in order to support this mode, a compiler *must* | |
413 | # always write the preprocessed file to stdout, regardless of -o. | |
414 | "$@" || exit $? | |
415 | ||
416 | # Remove the call to Libtool. | |
417 | if test "$libtool" = yes; then | |
418 | while test "X$1" != 'X--mode=compile'; do | |
419 | shift | |
420 | done | |
421 | shift | |
422 | fi | |
423 | ||
424 | # Remove `-o $object'. | |
425 | IFS=" " | |
426 | for arg | |
427 | do | |
428 | case $arg in | |
429 | -o) | |
430 | shift | |
431 | ;; | |
432 | $object) | |
433 | shift | |
434 | ;; | |
435 | *) | |
436 | set fnord "$@" "$arg" | |
437 | shift # fnord | |
438 | shift # $arg | |
439 | ;; | |
440 | esac | |
441 | done | |
442 | ||
443 | test -z "$dashmflag" && dashmflag=-M | |
444 | # Require at least two characters before searching for `:' | |
445 | # in the target name. This is to cope with DOS-style filenames: | |
446 | # a dependency such as `c:/foo/bar' could be seen as target `c' otherwise. | |
447 | "$@" $dashmflag | | |
448 | sed 's:^[ ]*[^: ][^:][^:]*\:[ ]*:'"$object"'\: :' > "$tmpdepfile" | |
449 | rm -f "$depfile" | |
450 | cat < "$tmpdepfile" > "$depfile" | |
451 | tr ' ' ' | |
452 | ' < "$tmpdepfile" | \ | |
453 | ## Some versions of the HPUX 10.20 sed can't process this invocation | |
454 | ## correctly. Breaking it into two sed invocations is a workaround. | |
455 | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" | |
456 | rm -f "$tmpdepfile" | |
457 | ;; | |
458 | ||
459 | dashXmstdout) | |
460 | # This case only exists to satisfy depend.m4. It is never actually | |
461 | # run, as this mode is specially recognized in the preamble. | |
462 | exit 1 | |
463 | ;; | |
464 | ||
465 | makedepend) | |
466 | "$@" || exit $? | |
467 | # Remove any Libtool call | |
468 | if test "$libtool" = yes; then | |
469 | while test "X$1" != 'X--mode=compile'; do | |
470 | shift | |
471 | done | |
472 | shift | |
473 | fi | |
474 | # X makedepend | |
475 | shift | |
476 | cleared=no eat=no | |
477 | for arg | |
478 | do | |
479 | case $cleared in | |
480 | no) | |
481 | set ""; shift | |
482 | cleared=yes ;; | |
483 | esac | |
484 | if test $eat = yes; then | |
485 | eat=no | |
486 | continue | |
487 | fi | |
488 | case "$arg" in | |
489 | -D*|-I*) | |
490 | set fnord "$@" "$arg"; shift ;; | |
491 | # Strip any option that makedepend may not understand. Remove | |
492 | # the object too, otherwise makedepend will parse it as a source file. | |
493 | -arch) | |
494 | eat=yes ;; | |
495 | -*|$object) | |
496 | ;; | |
497 | *) | |
498 | set fnord "$@" "$arg"; shift ;; | |
499 | esac | |
500 | done | |
501 | obj_suffix=`echo "$object" | sed 's/^.*\././'` | |
502 | touch "$tmpdepfile" | |
503 | ${MAKEDEPEND-makedepend} -o"$obj_suffix" -f"$tmpdepfile" "$@" | |
504 | rm -f "$depfile" | |
505 | cat < "$tmpdepfile" > "$depfile" | |
506 | sed '1,2d' "$tmpdepfile" | tr ' ' ' | |
507 | ' | \ | |
508 | ## Some versions of the HPUX 10.20 sed can't process this invocation | |
509 | ## correctly. Breaking it into two sed invocations is a workaround. | |
510 | sed -e 's/^\\$//' -e '/^$/d' -e '/:$/d' | sed -e 's/$/ :/' >> "$depfile" | |
511 | rm -f "$tmpdepfile" "$tmpdepfile".bak | |
512 | ;; | |
513 | ||
514 | cpp) | |
515 | # Important note: in order to support this mode, a compiler *must* | |
516 | # always write the preprocessed file to stdout. | |
517 | "$@" || exit $? | |
518 | ||
519 | # Remove the call to Libtool. | |
520 | if test "$libtool" = yes; then | |
521 | while test "X$1" != 'X--mode=compile'; do | |
522 | shift | |
523 | done | |
524 | shift | |
525 | fi | |
526 | ||
527 | # Remove `-o $object'. | |
528 | IFS=" " | |
529 | for arg | |
530 | do | |
531 | case $arg in | |
532 | -o) | |
533 | shift | |
534 | ;; | |
535 | $object) | |
536 | shift | |
537 | ;; | |
538 | *) | |
539 | set fnord "$@" "$arg" | |
540 | shift # fnord | |
541 | shift # $arg | |
542 | ;; | |
543 | esac | |
544 | done | |
545 | ||
546 | "$@" -E | | |
547 | sed -n -e '/^# [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' \ | |
548 | -e '/^#line [0-9][0-9]* "\([^"]*\)".*/ s:: \1 \\:p' | | |
549 | sed '$ s: \\$::' > "$tmpdepfile" | |
550 | rm -f "$depfile" | |
551 | echo "$object : \\" > "$depfile" | |
552 | cat < "$tmpdepfile" >> "$depfile" | |
553 | sed < "$tmpdepfile" '/^$/d;s/^ //;s/ \\$//;s/$/ :/' >> "$depfile" | |
554 | rm -f "$tmpdepfile" | |
555 | ;; | |
556 | ||
557 | msvisualcpp) | |
558 | # Important note: in order to support this mode, a compiler *must* | |
559 | # always write the preprocessed file to stdout. | |
560 | "$@" || exit $? | |
561 | ||
562 | # Remove the call to Libtool. | |
563 | if test "$libtool" = yes; then | |
564 | while test "X$1" != 'X--mode=compile'; do | |
565 | shift | |
566 | done | |
567 | shift | |
568 | fi | |
569 | ||
570 | IFS=" " | |
571 | for arg | |
572 | do | |
573 | case "$arg" in | |
574 | -o) | |
575 | shift | |
576 | ;; | |
577 | $object) | |
578 | shift | |
579 | ;; | |
580 | "-Gm"|"/Gm"|"-Gi"|"/Gi"|"-ZI"|"/ZI") | |
581 | set fnord "$@" | |
582 | shift | |
583 | shift | |
584 | ;; | |
585 | *) | |
586 | set fnord "$@" "$arg" | |
587 | shift | |
588 | shift | |
589 | ;; | |
590 | esac | |
591 | done | |
592 | "$@" -E 2>/dev/null | | |
593 | sed -n '/^#line [0-9][0-9]* "\([^"]*\)"/ s::\1:p' | $cygpath_u | sort -u > "$tmpdepfile" | |
594 | rm -f "$depfile" | |
595 | echo "$object : \\" > "$depfile" | |
596 | sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s:: \1 \\:p' >> "$depfile" | |
597 | echo " " >> "$depfile" | |
598 | sed < "$tmpdepfile" -n -e 's% %\\ %g' -e '/^\(.*\)$/ s::\1\::p' >> "$depfile" | |
599 | rm -f "$tmpdepfile" | |
600 | ;; | |
601 | ||
602 | msvcmsys) | |
603 | # This case exists only to let depend.m4 do its work. It works by | |
604 | # looking at the text of this script. This case will never be run, | |
605 | # since it is checked for above. | |
606 | exit 1 | |
607 | ;; | |
608 | ||
609 | none) | |
610 | exec "$@" | |
611 | ;; | |
612 | ||
613 | *) | |
614 | echo "Unknown depmode $depmode" 1>&2 | |
615 | exit 1 | |
616 | ;; | |
617 | esac | |
618 | ||
619 | exit 0 | |
620 | ||
621 | # Local Variables: | |
622 | # mode: shell-script | |
623 | # sh-indentation: 2 | |
624 | # eval: (add-hook 'write-file-hooks 'time-stamp) | |
625 | # time-stamp-start: "scriptversion=" | |
626 | # time-stamp-format: "%:y-%02m-%02d.%02H" | |
627 | # time-stamp-time-zone: "UTC" | |
628 | # time-stamp-end: "; # UTC" | |
629 | # End: |
0 | - Add your test to rendercheck.h TEST_* | |
1 | - Add command line option to main.c case 't'. | |
2 | - Add command line option to main.c usage() | |
3 | - Add your test loop to the bottom of begin_test(). Looping on ops and dests is | |
4 | highly recommended. | |
5 | - Write your test in t_testname.c and add to Makefile.am, with prototype in | |
6 | rendercheck.h | |
7 | - Add a note about your test to README | |
8 | - Be sure to include your MIT license boilerplate on the new file. |
0 | - Check bilinear filtering | |
1 | - Check repeating transformed sources | |
2 | - Check coordinates for more different transformations | |
3 | - Get a useful number being produced for error values, and correct eval_diff's | |
4 | limit. | |
5 | - Check source/mask pixels falling outside the drawable. | |
6 | - Check trapezoids! | |
7 | - get_pixel equivalent that doesn't involve round-trips per call. |
0 | #!/bin/sh | |
1 | # install - install a program, script, or datafile | |
2 | ||
3 | scriptversion=2009-04-28.21; # UTC | |
4 | ||
5 | # This originates from X11R5 (mit/util/scripts/install.sh), which was | |
6 | # later released in X11R6 (xc/config/util/install.sh) with the | |
7 | # following copyright and license. | |
8 | # | |
9 | # Copyright (C) 1994 X Consortium | |
10 | # | |
11 | # Permission is hereby granted, free of charge, to any person obtaining a copy | |
12 | # of this software and associated documentation files (the "Software"), to | |
13 | # deal in the Software without restriction, including without limitation the | |
14 | # rights to use, copy, modify, merge, publish, distribute, sublicense, and/or | |
15 | # sell copies of the Software, and to permit persons to whom the Software is | |
16 | # furnished to do so, subject to the following conditions: | |
17 | # | |
18 | # The above copyright notice and this permission notice shall be included in | |
19 | # all copies or substantial portions of the Software. | |
20 | # | |
21 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
22 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
23 | # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE | |
24 | # X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN | |
25 | # AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNEC- | |
26 | # TION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. | |
27 | # | |
28 | # Except as contained in this notice, the name of the X Consortium shall not | |
29 | # be used in advertising or otherwise to promote the sale, use or other deal- | |
30 | # ings in this Software without prior written authorization from the X Consor- | |
31 | # tium. | |
32 | # | |
33 | # | |
34 | # FSF changes to this file are in the public domain. | |
35 | # | |
36 | # Calling this script install-sh is preferred over install.sh, to prevent | |
37 | # `make' implicit rules from creating a file called install from it | |
38 | # when there is no Makefile. | |
39 | # | |
40 | # This script is compatible with the BSD install script, but was written | |
41 | # from scratch. | |
42 | ||
43 | nl=' | |
44 | ' | |
45 | IFS=" "" $nl" | |
46 | ||
47 | # set DOITPROG to echo to test this script | |
48 | ||
49 | # Don't use :- since 4.3BSD and earlier shells don't like it. | |
50 | doit=${DOITPROG-} | |
51 | if test -z "$doit"; then | |
52 | doit_exec=exec | |
53 | else | |
54 | doit_exec=$doit | |
55 | fi | |
56 | ||
57 | # Put in absolute file names if you don't have them in your path; | |
58 | # or use environment vars. | |
59 | ||
60 | chgrpprog=${CHGRPPROG-chgrp} | |
61 | chmodprog=${CHMODPROG-chmod} | |
62 | chownprog=${CHOWNPROG-chown} | |
63 | cmpprog=${CMPPROG-cmp} | |
64 | cpprog=${CPPROG-cp} | |
65 | mkdirprog=${MKDIRPROG-mkdir} | |
66 | mvprog=${MVPROG-mv} | |
67 | rmprog=${RMPROG-rm} | |
68 | stripprog=${STRIPPROG-strip} | |
69 | ||
70 | posix_glob='?' | |
71 | initialize_posix_glob=' | |
72 | test "$posix_glob" != "?" || { | |
73 | if (set -f) 2>/dev/null; then | |
74 | posix_glob= | |
75 | else | |
76 | posix_glob=: | |
77 | fi | |
78 | } | |
79 | ' | |
80 | ||
81 | posix_mkdir= | |
82 | ||
83 | # Desired mode of installed file. | |
84 | mode=0755 | |
85 | ||
86 | chgrpcmd= | |
87 | chmodcmd=$chmodprog | |
88 | chowncmd= | |
89 | mvcmd=$mvprog | |
90 | rmcmd="$rmprog -f" | |
91 | stripcmd= | |
92 | ||
93 | src= | |
94 | dst= | |
95 | dir_arg= | |
96 | dst_arg= | |
97 | ||
98 | copy_on_change=false | |
99 | no_target_directory= | |
100 | ||
101 | usage="\ | |
102 | Usage: $0 [OPTION]... [-T] SRCFILE DSTFILE | |
103 | or: $0 [OPTION]... SRCFILES... DIRECTORY | |
104 | or: $0 [OPTION]... -t DIRECTORY SRCFILES... | |
105 | or: $0 [OPTION]... -d DIRECTORIES... | |
106 | ||
107 | In the 1st form, copy SRCFILE to DSTFILE. | |
108 | In the 2nd and 3rd, copy all SRCFILES to DIRECTORY. | |
109 | In the 4th, create DIRECTORIES. | |
110 | ||
111 | Options: | |
112 | --help display this help and exit. | |
113 | --version display version info and exit. | |
114 | ||
115 | -c (ignored) | |
116 | -C install only if different (preserve the last data modification time) | |
117 | -d create directories instead of installing files. | |
118 | -g GROUP $chgrpprog installed files to GROUP. | |
119 | -m MODE $chmodprog installed files to MODE. | |
120 | -o USER $chownprog installed files to USER. | |
121 | -s $stripprog installed files. | |
122 | -t DIRECTORY install into DIRECTORY. | |
123 | -T report an error if DSTFILE is a directory. | |
124 | ||
125 | Environment variables override the default commands: | |
126 | CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG | |
127 | RMPROG STRIPPROG | |
128 | " | |
129 | ||
130 | while test $# -ne 0; do | |
131 | case $1 in | |
132 | -c) ;; | |
133 | ||
134 | -C) copy_on_change=true;; | |
135 | ||
136 | -d) dir_arg=true;; | |
137 | ||
138 | -g) chgrpcmd="$chgrpprog $2" | |
139 | shift;; | |
140 | ||
141 | --help) echo "$usage"; exit $?;; | |
142 | ||
143 | -m) mode=$2 | |
144 | case $mode in | |
145 | *' '* | *' '* | *' | |
146 | '* | *'*'* | *'?'* | *'['*) | |
147 | echo "$0: invalid mode: $mode" >&2 | |
148 | exit 1;; | |
149 | esac | |
150 | shift;; | |
151 | ||
152 | -o) chowncmd="$chownprog $2" | |
153 | shift;; | |
154 | ||
155 | -s) stripcmd=$stripprog;; | |
156 | ||
157 | -t) dst_arg=$2 | |
158 | shift;; | |
159 | ||
160 | -T) no_target_directory=true;; | |
161 | ||
162 | --version) echo "$0 $scriptversion"; exit $?;; | |
163 | ||
164 | --) shift | |
165 | break;; | |
166 | ||
167 | -*) echo "$0: invalid option: $1" >&2 | |
168 | exit 1;; | |
169 | ||
170 | *) break;; | |
171 | esac | |
172 | shift | |
173 | done | |
174 | ||
175 | if test $# -ne 0 && test -z "$dir_arg$dst_arg"; then | |
176 | # When -d is used, all remaining arguments are directories to create. | |
177 | # When -t is used, the destination is already specified. | |
178 | # Otherwise, the last argument is the destination. Remove it from $@. | |
179 | for arg | |
180 | do | |
181 | if test -n "$dst_arg"; then | |
182 | # $@ is not empty: it contains at least $arg. | |
183 | set fnord "$@" "$dst_arg" | |
184 | shift # fnord | |
185 | fi | |
186 | shift # arg | |
187 | dst_arg=$arg | |
188 | done | |
189 | fi | |
190 | ||
191 | if test $# -eq 0; then | |
192 | if test -z "$dir_arg"; then | |
193 | echo "$0: no input file specified." >&2 | |
194 | exit 1 | |
195 | fi | |
196 | # It's OK to call `install-sh -d' without argument. | |
197 | # This can happen when creating conditional directories. | |
198 | exit 0 | |
199 | fi | |
200 | ||
201 | if test -z "$dir_arg"; then | |
202 | trap '(exit $?); exit' 1 2 13 15 | |
203 | ||
204 | # Set umask so as not to create temps with too-generous modes. | |
205 | # However, 'strip' requires both read and write access to temps. | |
206 | case $mode in | |
207 | # Optimize common cases. | |
208 | *644) cp_umask=133;; | |
209 | *755) cp_umask=22;; | |
210 | ||
211 | *[0-7]) | |
212 | if test -z "$stripcmd"; then | |
213 | u_plus_rw= | |
214 | else | |
215 | u_plus_rw='% 200' | |
216 | fi | |
217 | cp_umask=`expr '(' 777 - $mode % 1000 ')' $u_plus_rw`;; | |
218 | *) | |
219 | if test -z "$stripcmd"; then | |
220 | u_plus_rw= | |
221 | else | |
222 | u_plus_rw=,u+rw | |
223 | fi | |
224 | cp_umask=$mode$u_plus_rw;; | |
225 | esac | |
226 | fi | |
227 | ||
228 | for src | |
229 | do | |
230 | # Protect names starting with `-'. | |
231 | case $src in | |
232 | -*) src=./$src;; | |
233 | esac | |
234 | ||
235 | if test -n "$dir_arg"; then | |
236 | dst=$src | |
237 | dstdir=$dst | |
238 | test -d "$dstdir" | |
239 | dstdir_status=$? | |
240 | else | |
241 | ||
242 | # Waiting for this to be detected by the "$cpprog $src $dsttmp" command | |
243 | # might cause directories to be created, which would be especially bad | |
244 | # if $src (and thus $dsttmp) contains '*'. | |
245 | if test ! -f "$src" && test ! -d "$src"; then | |
246 | echo "$0: $src does not exist." >&2 | |
247 | exit 1 | |
248 | fi | |
249 | ||
250 | if test -z "$dst_arg"; then | |
251 | echo "$0: no destination specified." >&2 | |
252 | exit 1 | |
253 | fi | |
254 | ||
255 | dst=$dst_arg | |
256 | # Protect names starting with `-'. | |
257 | case $dst in | |
258 | -*) dst=./$dst;; | |
259 | esac | |
260 | ||
261 | # If destination is a directory, append the input filename; won't work | |
262 | # if double slashes aren't ignored. | |
263 | if test -d "$dst"; then | |
264 | if test -n "$no_target_directory"; then | |
265 | echo "$0: $dst_arg: Is a directory" >&2 | |
266 | exit 1 | |
267 | fi | |
268 | dstdir=$dst | |
269 | dst=$dstdir/`basename "$src"` | |
270 | dstdir_status=0 | |
271 | else | |
272 | # Prefer dirname, but fall back on a substitute if dirname fails. | |
273 | dstdir=` | |
274 | (dirname "$dst") 2>/dev/null || | |
275 | expr X"$dst" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
276 | X"$dst" : 'X\(//\)[^/]' \| \ | |
277 | X"$dst" : 'X\(//\)$' \| \ | |
278 | X"$dst" : 'X\(/\)' \| . 2>/dev/null || | |
279 | echo X"$dst" | | |
280 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
281 | s//\1/ | |
282 | q | |
283 | } | |
284 | /^X\(\/\/\)[^/].*/{ | |
285 | s//\1/ | |
286 | q | |
287 | } | |
288 | /^X\(\/\/\)$/{ | |
289 | s//\1/ | |
290 | q | |
291 | } | |
292 | /^X\(\/\).*/{ | |
293 | s//\1/ | |
294 | q | |
295 | } | |
296 | s/.*/./; q' | |
297 | ` | |
298 | ||
299 | test -d "$dstdir" | |
300 | dstdir_status=$? | |
301 | fi | |
302 | fi | |
303 | ||
304 | obsolete_mkdir_used=false | |
305 | ||
306 | if test $dstdir_status != 0; then | |
307 | case $posix_mkdir in | |
308 | '') | |
309 | # Create intermediate dirs using mode 755 as modified by the umask. | |
310 | # This is like FreeBSD 'install' as of 1997-10-28. | |
311 | umask=`umask` | |
312 | case $stripcmd.$umask in | |
313 | # Optimize common cases. | |
314 | *[2367][2367]) mkdir_umask=$umask;; | |
315 | .*0[02][02] | .[02][02] | .[02]) mkdir_umask=22;; | |
316 | ||
317 | *[0-7]) | |
318 | mkdir_umask=`expr $umask + 22 \ | |
319 | - $umask % 100 % 40 + $umask % 20 \ | |
320 | - $umask % 10 % 4 + $umask % 2 | |
321 | `;; | |
322 | *) mkdir_umask=$umask,go-w;; | |
323 | esac | |
324 | ||
325 | # With -d, create the new directory with the user-specified mode. | |
326 | # Otherwise, rely on $mkdir_umask. | |
327 | if test -n "$dir_arg"; then | |
328 | mkdir_mode=-m$mode | |
329 | else | |
330 | mkdir_mode= | |
331 | fi | |
332 | ||
333 | posix_mkdir=false | |
334 | case $umask in | |
335 | *[123567][0-7][0-7]) | |
336 | # POSIX mkdir -p sets u+wx bits regardless of umask, which | |
337 | # is incompatible with FreeBSD 'install' when (umask & 300) != 0. | |
338 | ;; | |
339 | *) | |
340 | tmpdir=${TMPDIR-/tmp}/ins$RANDOM-$$ | |
341 | trap 'ret=$?; rmdir "$tmpdir/d" "$tmpdir" 2>/dev/null; exit $ret' 0 | |
342 | ||
343 | if (umask $mkdir_umask && | |
344 | exec $mkdirprog $mkdir_mode -p -- "$tmpdir/d") >/dev/null 2>&1 | |
345 | then | |
346 | if test -z "$dir_arg" || { | |
347 | # Check for POSIX incompatibilities with -m. | |
348 | # HP-UX 11.23 and IRIX 6.5 mkdir -m -p sets group- or | |
349 | # other-writeable bit of parent directory when it shouldn't. | |
350 | # FreeBSD 6.1 mkdir -m -p sets mode of existing directory. | |
351 | ls_ld_tmpdir=`ls -ld "$tmpdir"` | |
352 | case $ls_ld_tmpdir in | |
353 | d????-?r-*) different_mode=700;; | |
354 | d????-?--*) different_mode=755;; | |
355 | *) false;; | |
356 | esac && | |
357 | $mkdirprog -m$different_mode -p -- "$tmpdir" && { | |
358 | ls_ld_tmpdir_1=`ls -ld "$tmpdir"` | |
359 | test "$ls_ld_tmpdir" = "$ls_ld_tmpdir_1" | |
360 | } | |
361 | } | |
362 | then posix_mkdir=: | |
363 | fi | |
364 | rmdir "$tmpdir/d" "$tmpdir" | |
365 | else | |
366 | # Remove any dirs left behind by ancient mkdir implementations. | |
367 | rmdir ./$mkdir_mode ./-p ./-- 2>/dev/null | |
368 | fi | |
369 | trap '' 0;; | |
370 | esac;; | |
371 | esac | |
372 | ||
373 | if | |
374 | $posix_mkdir && ( | |
375 | umask $mkdir_umask && | |
376 | $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir" | |
377 | ) | |
378 | then : | |
379 | else | |
380 | ||
381 | # The umask is ridiculous, or mkdir does not conform to POSIX, | |
382 | # or it failed possibly due to a race condition. Create the | |
383 | # directory the slow way, step by step, checking for races as we go. | |
384 | ||
385 | case $dstdir in | |
386 | /*) prefix='/';; | |
387 | -*) prefix='./';; | |
388 | *) prefix='';; | |
389 | esac | |
390 | ||
391 | eval "$initialize_posix_glob" | |
392 | ||
393 | oIFS=$IFS | |
394 | IFS=/ | |
395 | $posix_glob set -f | |
396 | set fnord $dstdir | |
397 | shift | |
398 | $posix_glob set +f | |
399 | IFS=$oIFS | |
400 | ||
401 | prefixes= | |
402 | ||
403 | for d | |
404 | do | |
405 | test -z "$d" && continue | |
406 | ||
407 | prefix=$prefix$d | |
408 | if test -d "$prefix"; then | |
409 | prefixes= | |
410 | else | |
411 | if $posix_mkdir; then | |
412 | (umask=$mkdir_umask && | |
413 | $doit_exec $mkdirprog $mkdir_mode -p -- "$dstdir") && break | |
414 | # Don't fail if two instances are running concurrently. | |
415 | test -d "$prefix" || exit 1 | |
416 | else | |
417 | case $prefix in | |
418 | *\'*) qprefix=`echo "$prefix" | sed "s/'/'\\\\\\\\''/g"`;; | |
419 | *) qprefix=$prefix;; | |
420 | esac | |
421 | prefixes="$prefixes '$qprefix'" | |
422 | fi | |
423 | fi | |
424 | prefix=$prefix/ | |
425 | done | |
426 | ||
427 | if test -n "$prefixes"; then | |
428 | # Don't fail if two instances are running concurrently. | |
429 | (umask $mkdir_umask && | |
430 | eval "\$doit_exec \$mkdirprog $prefixes") || | |
431 | test -d "$dstdir" || exit 1 | |
432 | obsolete_mkdir_used=true | |
433 | fi | |
434 | fi | |
435 | fi | |
436 | ||
437 | if test -n "$dir_arg"; then | |
438 | { test -z "$chowncmd" || $doit $chowncmd "$dst"; } && | |
439 | { test -z "$chgrpcmd" || $doit $chgrpcmd "$dst"; } && | |
440 | { test "$obsolete_mkdir_used$chowncmd$chgrpcmd" = false || | |
441 | test -z "$chmodcmd" || $doit $chmodcmd $mode "$dst"; } || exit 1 | |
442 | else | |
443 | ||
444 | # Make a couple of temp file names in the proper directory. | |
445 | dsttmp=$dstdir/_inst.$$_ | |
446 | rmtmp=$dstdir/_rm.$$_ | |
447 | ||
448 | # Trap to clean up those temp files at exit. | |
449 | trap 'ret=$?; rm -f "$dsttmp" "$rmtmp" && exit $ret' 0 | |
450 | ||
451 | # Copy the file name to the temp name. | |
452 | (umask $cp_umask && $doit_exec $cpprog "$src" "$dsttmp") && | |
453 | ||
454 | # and set any options; do chmod last to preserve setuid bits. | |
455 | # | |
456 | # If any of these fail, we abort the whole thing. If we want to | |
457 | # ignore errors from any of these, just make sure not to ignore | |
458 | # errors from the above "$doit $cpprog $src $dsttmp" command. | |
459 | # | |
460 | { test -z "$chowncmd" || $doit $chowncmd "$dsttmp"; } && | |
461 | { test -z "$chgrpcmd" || $doit $chgrpcmd "$dsttmp"; } && | |
462 | { test -z "$stripcmd" || $doit $stripcmd "$dsttmp"; } && | |
463 | { test -z "$chmodcmd" || $doit $chmodcmd $mode "$dsttmp"; } && | |
464 | ||
465 | # If -C, don't bother to copy if it wouldn't change the file. | |
466 | if $copy_on_change && | |
467 | old=`LC_ALL=C ls -dlL "$dst" 2>/dev/null` && | |
468 | new=`LC_ALL=C ls -dlL "$dsttmp" 2>/dev/null` && | |
469 | ||
470 | eval "$initialize_posix_glob" && | |
471 | $posix_glob set -f && | |
472 | set X $old && old=:$2:$4:$5:$6 && | |
473 | set X $new && new=:$2:$4:$5:$6 && | |
474 | $posix_glob set +f && | |
475 | ||
476 | test "$old" = "$new" && | |
477 | $cmpprog "$dst" "$dsttmp" >/dev/null 2>&1 | |
478 | then | |
479 | rm -f "$dsttmp" | |
480 | else | |
481 | # Rename the file to the real destination. | |
482 | $doit $mvcmd -f "$dsttmp" "$dst" 2>/dev/null || | |
483 | ||
484 | # The rename failed, perhaps because mv can't rename something else | |
485 | # to itself, or perhaps because mv is so ancient that it does not | |
486 | # support -f. | |
487 | { | |
488 | # Now remove or move aside any old file at destination location. | |
489 | # We try this two ways since rm can't unlink itself on some | |
490 | # systems and the destination file might be busy for other | |
491 | # reasons. In this case, the final cleanup might fail but the new | |
492 | # file should still install successfully. | |
493 | { | |
494 | test ! -f "$dst" || | |
495 | $doit $rmcmd -f "$dst" 2>/dev/null || | |
496 | { $doit $mvcmd -f "$dst" "$rmtmp" 2>/dev/null && | |
497 | { $doit $rmcmd -f "$rmtmp" 2>/dev/null; :; } | |
498 | } || | |
499 | { echo "$0: cannot unlink or rename $dst" >&2 | |
500 | (exit 1); exit 1 | |
501 | } | |
502 | } && | |
503 | ||
504 | # Now rename the file to the real destination. | |
505 | $doit $mvcmd "$dsttmp" "$dst" | |
506 | } | |
507 | fi || exit 1 | |
508 | ||
509 | trap '' 0 | |
510 | fi | |
511 | done | |
512 | ||
513 | # Local variables: | |
514 | # eval: (add-hook 'write-file-hooks 'time-stamp) | |
515 | # time-stamp-start: "scriptversion=" | |
516 | # time-stamp-format: "%:y-%02m-%02d.%02H" | |
517 | # time-stamp-time-zone: "UTC" | |
518 | # time-stamp-end: "; # UTC" | |
519 | # End: |
0 | /* | |
1 | * Copyright © 2004 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include "rendercheck.h" | |
23 | #include <stdlib.h> | |
24 | #include <stdio.h> | |
25 | #include <string.h> | |
26 | #include <getopt.h> | |
27 | ||
28 | extern int num_ops; | |
29 | extern int num_colors; | |
30 | ||
31 | Bool is_verbose = FALSE, minimalrendering = FALSE; | |
32 | int enabled_tests = ~0; /* Enable all tests by default */ | |
33 | ||
34 | int format_whitelist_len = 0; | |
35 | char **format_whitelist; | |
36 | ||
37 | /* Number of times to repeat operations so that pixmaps will tend to get moved | |
38 | * into offscreen memory and allow hardware acceleration. | |
39 | */ | |
40 | int pixmap_move_iter = 1; | |
41 | ||
42 | int win_width = 40; | |
43 | int win_height = 40; | |
44 | ||
45 | int | |
46 | bit_count(int i) | |
47 | { | |
48 | int count; | |
49 | ||
50 | count = (i >> 1) & 033333333333; | |
51 | count = i - count - ((count >> 1) & 033333333333); | |
52 | count = (((count + (count >> 3)) & 030707070707) % 077); | |
53 | /* HAKMEM 169 */ | |
54 | return count; | |
55 | } | |
56 | ||
57 | /* This is not complete, but decent enough for now.*/ | |
58 | void | |
59 | describe_format(char *desc, int len, XRenderPictFormat *format) | |
60 | { | |
61 | char ad[4] = "", rd[4] = "", gd[4] = "", bd[4] = ""; | |
62 | int ac, rc, gc, bc; | |
63 | int ashift; | |
64 | ||
65 | ac = bit_count(format->direct.alphaMask); | |
66 | rc = bit_count(format->direct.redMask); | |
67 | gc = bit_count(format->direct.greenMask); | |
68 | bc = bit_count(format->direct.blueMask); | |
69 | ||
70 | if (ac != 0) { | |
71 | snprintf(ad, 4, "a%d", ac); | |
72 | ashift = format->direct.alpha; | |
73 | } else if (rc + bc + gc < format->depth) { | |
74 | /* There are bits that are not part of A,R,G,B. Mark them with | |
75 | * an x. | |
76 | */ | |
77 | snprintf(ad, 4, "x%d", format->depth - rc - gc - bc); | |
78 | if (format->direct.red == 0 || format->direct.blue == 0) | |
79 | ashift = format->depth; | |
80 | else | |
81 | ashift = 0; | |
82 | } else | |
83 | ashift = 0; | |
84 | ||
85 | if (rc != 0) | |
86 | snprintf(rd, 4, "r%d", rc); | |
87 | if (gc != 0) | |
88 | snprintf(gd, 4, "g%d", gc); | |
89 | if (bc != 0) | |
90 | snprintf(bd, 4, "b%d", bc); | |
91 | ||
92 | if (ashift > format->direct.red) { | |
93 | if (format->direct.red > format->direct.blue) | |
94 | snprintf(desc, len, "%s%s%s%s", ad, rd, gd, bd); | |
95 | else | |
96 | snprintf(desc, len, "%s%s%s%s", ad, bd, gd, rd); | |
97 | } else { | |
98 | if (format->direct.red > format->direct.blue) | |
99 | snprintf(desc, len, "%s%s%s%s", rd, gd, bd, ad); | |
100 | else | |
101 | snprintf(desc, len, "%s%s%s%s", bd, gd, rd, ad); | |
102 | } | |
103 | } | |
104 | ||
105 | static void | |
106 | usage (char *program) | |
107 | { | |
108 | fprintf(stderr, "usage: %s [-d|--display display] [-v|--verbose]\n" | |
109 | "\t[-t test1,test2,...] [-o op1,op2,...] [-f format1,format2,...]\n" | |
110 | "\t[--sync] [--minimalrendering] [--version]\n" | |
111 | "\tAvailable tests: fill,dcoords,scoords,mcoords,tscoords,\n" | |
112 | "\t\ttmcoords,blend,composite,cacomposite,gradients,repeat,triangles,\n" | |
113 | "\t\tbug7366\n", | |
114 | program); | |
115 | exit(1); | |
116 | } | |
117 | ||
118 | int main(int argc, char **argv) | |
119 | { | |
120 | Display *dpy; | |
121 | XEvent ev; | |
122 | int i, o, maj, min; | |
123 | static Bool is_sync = FALSE, print_version = FALSE; | |
124 | XWindowAttributes a; | |
125 | XSetWindowAttributes as; | |
126 | picture_info window; | |
127 | char *display = NULL; | |
128 | char *test, *format, *opname, *nextname; | |
129 | ||
130 | static struct option longopts[] = { | |
131 | { "display", required_argument, NULL, 'd' }, | |
132 | { "iterations", required_argument, NULL, 'i' }, | |
133 | { "formats", required_argument, NULL, 'f' }, | |
134 | { "tests", required_argument, NULL, 't' }, | |
135 | { "ops", required_argument, NULL, 'o' }, | |
136 | { "verbose", no_argument, NULL, 'v' }, | |
137 | { "sync", no_argument, &is_sync, TRUE}, | |
138 | { "minimalrendering", no_argument, &minimalrendering, | |
139 | TRUE}, | |
140 | { "version", no_argument, &print_version, TRUE }, | |
141 | { NULL, 0, NULL, 0 } | |
142 | }; | |
143 | ||
144 | while ((o = getopt_long(argc, argv, "d:i:f:t:o:v", longopts, NULL)) != -1) { | |
145 | switch (o) { | |
146 | case 'd': | |
147 | display = optarg; | |
148 | break; | |
149 | case 'i': | |
150 | pixmap_move_iter = atoi(optarg); | |
151 | break; | |
152 | case 'o': | |
153 | for (i = 0; i < num_ops; i++) | |
154 | ops[i].disabled = TRUE; | |
155 | ||
156 | nextname = optarg; | |
157 | while ((opname = strsep(&nextname, ",")) != NULL) { | |
158 | for (i = 0; i < num_ops; i++) { | |
159 | if (strcasecmp(ops[i].name, opname) != | |
160 | 0) | |
161 | continue; | |
162 | ops[i].disabled = FALSE; | |
163 | break; | |
164 | } | |
165 | if (i == num_ops) | |
166 | usage(argv[0]); | |
167 | } | |
168 | break; | |
169 | case 'f': | |
170 | nextname = optarg; | |
171 | for (format_whitelist_len = 0;;format_whitelist_len++) | |
172 | { | |
173 | if ((format = strsep(&nextname, ",")) == NULL) | |
174 | break; | |
175 | } | |
176 | ||
177 | format_whitelist = malloc(sizeof(char *) * | |
178 | format_whitelist_len); | |
179 | if (format_whitelist == NULL) | |
180 | errx(1, "malloc"); | |
181 | ||
182 | /* Now the list is separated by \0s, so use strlen to | |
183 | * step between entries. | |
184 | */ | |
185 | format = optarg; | |
186 | for (i = 0; i < format_whitelist_len; i++) { | |
187 | format_whitelist[i] = strdup(format); | |
188 | format += strlen(format) + 1; | |
189 | } | |
190 | ||
191 | break; | |
192 | case 't': | |
193 | nextname = optarg; | |
194 | ||
195 | /* disable all tests */ | |
196 | enabled_tests = 0; | |
197 | ||
198 | while ((test = strsep(&nextname, ",")) != NULL) { | |
199 | if (strcmp(test, "fill") == 0) { | |
200 | enabled_tests |= TEST_FILL; | |
201 | } else if (strcmp(test, "dcoords") == 0) { | |
202 | enabled_tests |= TEST_DSTCOORDS; | |
203 | } else if (strcmp(test, "scoords") == 0) { | |
204 | enabled_tests |= TEST_SRCCOORDS; | |
205 | } else if (strcmp(test, "mcoords") == 0) { | |
206 | enabled_tests |= TEST_MASKCOORDS; | |
207 | } else if (strcmp(test, "tscoords") == 0) { | |
208 | enabled_tests |= TEST_TSRCCOORDS; | |
209 | } else if (strcmp(test, "tmcoords") == 0) { | |
210 | enabled_tests |= TEST_TMASKCOORDS; | |
211 | } else if (strcmp(test, "blend") == 0) { | |
212 | enabled_tests |= TEST_BLEND; | |
213 | } else if (strcmp(test, "composite") == 0) { | |
214 | enabled_tests |= TEST_COMPOSITE; | |
215 | } else if (strcmp(test, "cacomposite") == 0) { | |
216 | enabled_tests |= TEST_CACOMPOSITE; | |
217 | } else if (strcmp(test, "gradients") == 0) { | |
218 | enabled_tests |= TEST_GRADIENTS; | |
219 | } else if (strcmp(test, "repeat") == 0) { | |
220 | enabled_tests |= TEST_REPEAT; | |
221 | } else if (strcmp(test, "triangles") == 0) { | |
222 | enabled_tests |= TEST_TRIANGLES; | |
223 | } else if (strcmp(test, "bug7366") == 0) { | |
224 | enabled_tests |= TEST_BUG7366; | |
225 | } else { | |
226 | usage(argv[0]); | |
227 | } | |
228 | } | |
229 | ||
230 | break; | |
231 | case 'v': | |
232 | is_verbose = TRUE; | |
233 | break; | |
234 | case 0: | |
235 | break; | |
236 | default: | |
237 | usage(argv[0]); | |
238 | break; | |
239 | } | |
240 | } | |
241 | ||
242 | /* Print the version string. Bail out if --version was requested and | |
243 | * continue otherwise. | |
244 | */ | |
245 | puts(PACKAGE_STRING); | |
246 | if (print_version) | |
247 | return 0; | |
248 | ||
249 | dpy = XOpenDisplay(display); | |
250 | if (dpy == NULL) | |
251 | errx(1, "Couldn't open display."); | |
252 | if (is_sync) | |
253 | XSynchronize(dpy, 1); | |
254 | ||
255 | if (!XRenderQueryExtension(dpy, &i, &i)) | |
256 | errx(1, "Render extension missing."); | |
257 | ||
258 | XRenderQueryVersion(dpy, &maj, &min); | |
259 | if (maj != 0 || min < 1) | |
260 | errx(1, "Render extension version too low (%d.%d).", maj, min); | |
261 | ||
262 | printf("Render extension version %d.%d\n", maj, min); | |
263 | ||
264 | /* Conjoint/Disjoint were added in version 0.2, so disable those ops if | |
265 | * the server doesn't support them. | |
266 | */ | |
267 | if (min < 2) { | |
268 | printf("Server doesn't support conjoint/disjoint ops, disabling.\n"); | |
269 | num_ops = PictOpSaturate; | |
270 | } | |
271 | ||
272 | window.d = XCreateSimpleWindow(dpy, RootWindow(dpy, 0), 0, 0, win_width, | |
273 | win_height, 0, 0, WhitePixel(dpy, 0)); | |
274 | ||
275 | as.override_redirect = True; | |
276 | XChangeWindowAttributes(dpy, window.d, CWOverrideRedirect, &as); | |
277 | ||
278 | XGetWindowAttributes(dpy, window.d, &a); | |
279 | window.format = XRenderFindVisualFormat(dpy, a.visual); | |
280 | window.pict = XRenderCreatePicture(dpy, window.d, | |
281 | window.format, 0, NULL); | |
282 | window.name = (char *)malloc(20); | |
283 | if (window.name == NULL) | |
284 | errx(1, "malloc error"); | |
285 | describe_format(window.name, 20, window.format); | |
286 | printf("Window format: %s\n", window.name); | |
287 | strncat(window.name, " window", 20); | |
288 | XSelectInput(dpy, window.d, ExposureMask); | |
289 | XMapWindow(dpy, window.d); | |
290 | ||
291 | /* We have to premultiply the alpha into the r, g, b values of the | |
292 | * sample colors. Render colors are premultiplied with alpha, so r,g,b | |
293 | * can never be greater than alpha. | |
294 | */ | |
295 | for (i = 0; i < num_colors; i++) { | |
296 | colors[i].r *= colors[i].a; | |
297 | colors[i].g *= colors[i].a; | |
298 | colors[i].b *= colors[i].a; | |
299 | } | |
300 | ||
301 | while (XNextEvent(dpy, &ev) == 0) { | |
302 | if (ev.type == Expose && !ev.xexpose.count) { | |
303 | if (do_tests(dpy, &window)) | |
304 | exit(0); | |
305 | else | |
306 | exit(1); | |
307 | } | |
308 | } | |
309 | ||
310 | XCloseDisplay(dpy); | |
311 | return 0; | |
312 | } |
0 | # | |
1 | # Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. | |
2 | # | |
3 | # Permission is hereby granted, free of charge, to any person obtaining a | |
4 | # copy of this software and associated documentation files (the "Software"), | |
5 | # to deal in the Software without restriction, including without limitation | |
6 | # the rights to use, copy, modify, merge, publish, distribute, sublicense, | |
7 | # and/or sell copies of the Software, and to permit persons to whom the | |
8 | # Software is furnished to do so, subject to the following conditions: | |
9 | # | |
10 | # The above copyright notice and this permission notice (including the next | |
11 | # paragraph) shall be included in all copies or substantial portions of the | |
12 | # Software. | |
13 | # | |
14 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
15 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
16 | # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL | |
17 | # THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
18 | # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | |
19 | # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | |
20 | # DEALINGS IN THE SOFTWARE. | |
21 | # | |
22 | ||
23 | appmandir = $(APP_MAN_DIR) | |
24 | ||
25 | appman_PRE = rendercheck.man | |
26 | ||
27 | appman_DATA = $(appman_PRE:man=$(APP_MAN_SUFFIX)) | |
28 | ||
29 | EXTRA_DIST = $(appman_PRE) | |
30 | ||
31 | CLEANFILES = $(appman_DATA) | |
32 | ||
33 | SUFFIXES = .$(APP_MAN_SUFFIX) .man | |
34 | ||
35 | # String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure | |
36 | .man.$(APP_MAN_SUFFIX): | |
37 | $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@ |
0 | # Makefile.in generated by automake 1.11.1 from Makefile.am. | |
1 | # @configure_input@ | |
2 | ||
3 | # Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, | |
4 | # 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation, | |
5 | # Inc. | |
6 | # This Makefile.in is free software; the Free Software Foundation | |
7 | # gives unlimited permission to copy and/or distribute it, | |
8 | # with or without modifications, as long as this notice is preserved. | |
9 | ||
10 | # This program is distributed in the hope that it will be useful, | |
11 | # but WITHOUT ANY WARRANTY, to the extent permitted by law; without | |
12 | # even the implied warranty of MERCHANTABILITY or FITNESS FOR A | |
13 | # PARTICULAR PURPOSE. | |
14 | ||
15 | @SET_MAKE@ | |
16 | ||
17 | # | |
18 | # Copyright (c) 2005, Oracle and/or its affiliates. All rights reserved. | |
19 | # | |
20 | # Permission is hereby granted, free of charge, to any person obtaining a | |
21 | # copy of this software and associated documentation files (the "Software"), | |
22 | # to deal in the Software without restriction, including without limitation | |
23 | # the rights to use, copy, modify, merge, publish, distribute, sublicense, | |
24 | # and/or sell copies of the Software, and to permit persons to whom the | |
25 | # Software is furnished to do so, subject to the following conditions: | |
26 | # | |
27 | # The above copyright notice and this permission notice (including the next | |
28 | # paragraph) shall be included in all copies or substantial portions of the | |
29 | # Software. | |
30 | # | |
31 | # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
32 | # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
33 | # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL | |
34 | # THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
35 | # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING | |
36 | # FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER | |
37 | # DEALINGS IN THE SOFTWARE. | |
38 | # | |
39 | ||
40 | VPATH = @srcdir@ | |
41 | pkgdatadir = $(datadir)/@PACKAGE@ | |
42 | pkgincludedir = $(includedir)/@PACKAGE@ | |
43 | pkglibdir = $(libdir)/@PACKAGE@ | |
44 | pkglibexecdir = $(libexecdir)/@PACKAGE@ | |
45 | am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd | |
46 | install_sh_DATA = $(install_sh) -c -m 644 | |
47 | install_sh_PROGRAM = $(install_sh) -c | |
48 | install_sh_SCRIPT = $(install_sh) -c | |
49 | INSTALL_HEADER = $(INSTALL_DATA) | |
50 | transform = $(program_transform_name) | |
51 | NORMAL_INSTALL = : | |
52 | PRE_INSTALL = : | |
53 | POST_INSTALL = : | |
54 | NORMAL_UNINSTALL = : | |
55 | PRE_UNINSTALL = : | |
56 | POST_UNINSTALL = : | |
57 | build_triplet = @build@ | |
58 | host_triplet = @host@ | |
59 | subdir = man | |
60 | DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in | |
61 | ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 | |
62 | am__aclocal_m4_deps = $(top_srcdir)/configure.ac | |
63 | am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ | |
64 | $(ACLOCAL_M4) | |
65 | mkinstalldirs = $(install_sh) -d | |
66 | CONFIG_CLEAN_FILES = | |
67 | CONFIG_CLEAN_VPATH_FILES = | |
68 | AM_V_GEN = $(am__v_GEN_$(V)) | |
69 | am__v_GEN_ = $(am__v_GEN_$(AM_DEFAULT_VERBOSITY)) | |
70 | am__v_GEN_0 = @echo " GEN " $@; | |
71 | AM_V_at = $(am__v_at_$(V)) | |
72 | am__v_at_ = $(am__v_at_$(AM_DEFAULT_VERBOSITY)) | |
73 | am__v_at_0 = @ | |
74 | SOURCES = | |
75 | DIST_SOURCES = | |
76 | am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; | |
77 | am__vpath_adj = case $$p in \ | |
78 | $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \ | |
79 | *) f=$$p;; \ | |
80 | esac; | |
81 | am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`; | |
82 | am__install_max = 40 | |
83 | am__nobase_strip_setup = \ | |
84 | srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'` | |
85 | am__nobase_strip = \ | |
86 | for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||" | |
87 | am__nobase_list = $(am__nobase_strip_setup); \ | |
88 | for p in $$list; do echo "$$p $$p"; done | \ | |
89 | sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \ | |
90 | $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \ | |
91 | if (++n[$$2] == $(am__install_max)) \ | |
92 | { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \ | |
93 | END { for (dir in files) print dir, files[dir] }' | |
94 | am__base_list = \ | |
95 | sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \ | |
96 | sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | |
97 | am__installdirs = "$(DESTDIR)$(appmandir)" | |
98 | DATA = $(appman_DATA) | |
99 | DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST) | |
100 | ACLOCAL = @ACLOCAL@ | |
101 | ADMIN_MAN_DIR = @ADMIN_MAN_DIR@ | |
102 | ADMIN_MAN_SUFFIX = @ADMIN_MAN_SUFFIX@ | |
103 | AMTAR = @AMTAR@ | |
104 | AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@ | |
105 | APP_MAN_DIR = @APP_MAN_DIR@ | |
106 | APP_MAN_SUFFIX = @APP_MAN_SUFFIX@ | |
107 | AUTOCONF = @AUTOCONF@ | |
108 | AUTOHEADER = @AUTOHEADER@ | |
109 | AUTOMAKE = @AUTOMAKE@ | |
110 | AWK = @AWK@ | |
111 | CC = @CC@ | |
112 | CCDEPMODE = @CCDEPMODE@ | |
113 | CFLAGS = @CFLAGS@ | |
114 | CHANGELOG_CMD = @CHANGELOG_CMD@ | |
115 | CPP = @CPP@ | |
116 | CPPFLAGS = @CPPFLAGS@ | |
117 | CWARNFLAGS = @CWARNFLAGS@ | |
118 | CYGPATH_W = @CYGPATH_W@ | |
119 | DEFS = @DEFS@ | |
120 | DEPDIR = @DEPDIR@ | |
121 | DRIVER_MAN_DIR = @DRIVER_MAN_DIR@ | |
122 | DRIVER_MAN_SUFFIX = @DRIVER_MAN_SUFFIX@ | |
123 | ECHO_C = @ECHO_C@ | |
124 | ECHO_N = @ECHO_N@ | |
125 | ECHO_T = @ECHO_T@ | |
126 | EGREP = @EGREP@ | |
127 | EXEEXT = @EXEEXT@ | |
128 | FILE_MAN_DIR = @FILE_MAN_DIR@ | |
129 | FILE_MAN_SUFFIX = @FILE_MAN_SUFFIX@ | |
130 | GREP = @GREP@ | |
131 | INSTALL = @INSTALL@ | |
132 | INSTALL_CMD = @INSTALL_CMD@ | |
133 | INSTALL_DATA = @INSTALL_DATA@ | |
134 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ | |
135 | INSTALL_SCRIPT = @INSTALL_SCRIPT@ | |
136 | INSTALL_STRIP_PROGRAM = @INSTALL_STRIP_PROGRAM@ | |
137 | LDFLAGS = @LDFLAGS@ | |
138 | LIBOBJS = @LIBOBJS@ | |
139 | LIBS = @LIBS@ | |
140 | LIB_MAN_DIR = @LIB_MAN_DIR@ | |
141 | LIB_MAN_SUFFIX = @LIB_MAN_SUFFIX@ | |
142 | LTLIBOBJS = @LTLIBOBJS@ | |
143 | MAINT = @MAINT@ | |
144 | MAKEINFO = @MAKEINFO@ | |
145 | MAN_SUBSTS = @MAN_SUBSTS@ | |
146 | MISC_MAN_DIR = @MISC_MAN_DIR@ | |
147 | MISC_MAN_SUFFIX = @MISC_MAN_SUFFIX@ | |
148 | MKDIR_P = @MKDIR_P@ | |
149 | OBJEXT = @OBJEXT@ | |
150 | PACKAGE = @PACKAGE@ | |
151 | PACKAGE_BUGREPORT = @PACKAGE_BUGREPORT@ | |
152 | PACKAGE_NAME = @PACKAGE_NAME@ | |
153 | PACKAGE_STRING = @PACKAGE_STRING@ | |
154 | PACKAGE_TARNAME = @PACKAGE_TARNAME@ | |
155 | PACKAGE_URL = @PACKAGE_URL@ | |
156 | PACKAGE_VERSION = @PACKAGE_VERSION@ | |
157 | PATH_SEPARATOR = @PATH_SEPARATOR@ | |
158 | PKG_CONFIG = @PKG_CONFIG@ | |
159 | RC_CFLAGS = @RC_CFLAGS@ | |
160 | RC_LIBS = @RC_LIBS@ | |
161 | SED = @SED@ | |
162 | SET_MAKE = @SET_MAKE@ | |
163 | SHELL = @SHELL@ | |
164 | STRIP = @STRIP@ | |
165 | VERSION = @VERSION@ | |
166 | XORG_MAN_PAGE = @XORG_MAN_PAGE@ | |
167 | abs_builddir = @abs_builddir@ | |
168 | abs_srcdir = @abs_srcdir@ | |
169 | abs_top_builddir = @abs_top_builddir@ | |
170 | abs_top_srcdir = @abs_top_srcdir@ | |
171 | ac_ct_CC = @ac_ct_CC@ | |
172 | am__include = @am__include@ | |
173 | am__leading_dot = @am__leading_dot@ | |
174 | am__quote = @am__quote@ | |
175 | am__tar = @am__tar@ | |
176 | am__untar = @am__untar@ | |
177 | bindir = @bindir@ | |
178 | build = @build@ | |
179 | build_alias = @build_alias@ | |
180 | build_cpu = @build_cpu@ | |
181 | build_os = @build_os@ | |
182 | build_vendor = @build_vendor@ | |
183 | builddir = @builddir@ | |
184 | datadir = @datadir@ | |
185 | datarootdir = @datarootdir@ | |
186 | docdir = @docdir@ | |
187 | dvidir = @dvidir@ | |
188 | exec_prefix = @exec_prefix@ | |
189 | host = @host@ | |
190 | host_alias = @host_alias@ | |
191 | host_cpu = @host_cpu@ | |
192 | host_os = @host_os@ | |
193 | host_vendor = @host_vendor@ | |
194 | htmldir = @htmldir@ | |
195 | includedir = @includedir@ | |
196 | infodir = @infodir@ | |
197 | install_sh = @install_sh@ | |
198 | libdir = @libdir@ | |
199 | libexecdir = @libexecdir@ | |
200 | localedir = @localedir@ | |
201 | localstatedir = @localstatedir@ | |
202 | mandir = @mandir@ | |
203 | mkdir_p = @mkdir_p@ | |
204 | oldincludedir = @oldincludedir@ | |
205 | pdfdir = @pdfdir@ | |
206 | prefix = @prefix@ | |
207 | program_transform_name = @program_transform_name@ | |
208 | psdir = @psdir@ | |
209 | sbindir = @sbindir@ | |
210 | sharedstatedir = @sharedstatedir@ | |
211 | srcdir = @srcdir@ | |
212 | sysconfdir = @sysconfdir@ | |
213 | target_alias = @target_alias@ | |
214 | top_build_prefix = @top_build_prefix@ | |
215 | top_builddir = @top_builddir@ | |
216 | top_srcdir = @top_srcdir@ | |
217 | appmandir = $(APP_MAN_DIR) | |
218 | appman_PRE = rendercheck.man | |
219 | appman_DATA = $(appman_PRE:man=$(APP_MAN_SUFFIX)) | |
220 | EXTRA_DIST = $(appman_PRE) | |
221 | CLEANFILES = $(appman_DATA) | |
222 | SUFFIXES = .$(APP_MAN_SUFFIX) .man | |
223 | all: all-am | |
224 | ||
225 | .SUFFIXES: | |
226 | .SUFFIXES: .$(APP_MAN_SUFFIX) .man | |
227 | $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(am__configure_deps) | |
228 | @for dep in $?; do \ | |
229 | case '$(am__configure_deps)' in \ | |
230 | *$$dep*) \ | |
231 | ( cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh ) \ | |
232 | && { if test -f $@; then exit 0; else break; fi; }; \ | |
233 | exit 1;; \ | |
234 | esac; \ | |
235 | done; \ | |
236 | echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign man/Makefile'; \ | |
237 | $(am__cd) $(top_srcdir) && \ | |
238 | $(AUTOMAKE) --foreign man/Makefile | |
239 | .PRECIOUS: Makefile | |
240 | Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status | |
241 | @case '$?' in \ | |
242 | *config.status*) \ | |
243 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \ | |
244 | *) \ | |
245 | echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \ | |
246 | cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \ | |
247 | esac; | |
248 | ||
249 | $(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES) | |
250 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh | |
251 | ||
252 | $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps) | |
253 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh | |
254 | $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps) | |
255 | cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh | |
256 | $(am__aclocal_m4_deps): | |
257 | install-appmanDATA: $(appman_DATA) | |
258 | @$(NORMAL_INSTALL) | |
259 | test -z "$(appmandir)" || $(MKDIR_P) "$(DESTDIR)$(appmandir)" | |
260 | @list='$(appman_DATA)'; test -n "$(appmandir)" || list=; \ | |
261 | for p in $$list; do \ | |
262 | if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ | |
263 | echo "$$d$$p"; \ | |
264 | done | $(am__base_list) | \ | |
265 | while read files; do \ | |
266 | echo " $(INSTALL_DATA) $$files '$(DESTDIR)$(appmandir)'"; \ | |
267 | $(INSTALL_DATA) $$files "$(DESTDIR)$(appmandir)" || exit $$?; \ | |
268 | done | |
269 | ||
270 | uninstall-appmanDATA: | |
271 | @$(NORMAL_UNINSTALL) | |
272 | @list='$(appman_DATA)'; test -n "$(appmandir)" || list=; \ | |
273 | files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \ | |
274 | test -n "$$files" || exit 0; \ | |
275 | echo " ( cd '$(DESTDIR)$(appmandir)' && rm -f" $$files ")"; \ | |
276 | cd "$(DESTDIR)$(appmandir)" && rm -f $$files | |
277 | tags: TAGS | |
278 | TAGS: | |
279 | ||
280 | ctags: CTAGS | |
281 | CTAGS: | |
282 | ||
283 | ||
284 | distdir: $(DISTFILES) | |
285 | @srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ | |
286 | topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \ | |
287 | list='$(DISTFILES)'; \ | |
288 | dist_files=`for file in $$list; do echo $$file; done | \ | |
289 | sed -e "s|^$$srcdirstrip/||;t" \ | |
290 | -e "s|^$$topsrcdirstrip/|$(top_builddir)/|;t"`; \ | |
291 | case $$dist_files in \ | |
292 | */*) $(MKDIR_P) `echo "$$dist_files" | \ | |
293 | sed '/\//!d;s|^|$(distdir)/|;s,/[^/]*$$,,' | \ | |
294 | sort -u` ;; \ | |
295 | esac; \ | |
296 | for file in $$dist_files; do \ | |
297 | if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \ | |
298 | if test -d $$d/$$file; then \ | |
299 | dir=`echo "/$$file" | sed -e 's,/[^/]*$$,,'`; \ | |
300 | if test -d "$(distdir)/$$file"; then \ | |
301 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ | |
302 | fi; \ | |
303 | if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \ | |
304 | cp -fpR $(srcdir)/$$file "$(distdir)$$dir" || exit 1; \ | |
305 | find "$(distdir)/$$file" -type d ! -perm -700 -exec chmod u+rwx {} \;; \ | |
306 | fi; \ | |
307 | cp -fpR $$d/$$file "$(distdir)$$dir" || exit 1; \ | |
308 | else \ | |
309 | test -f "$(distdir)/$$file" \ | |
310 | || cp -p $$d/$$file "$(distdir)/$$file" \ | |
311 | || exit 1; \ | |
312 | fi; \ | |
313 | done | |
314 | check-am: all-am | |
315 | check: check-am | |
316 | all-am: Makefile $(DATA) | |
317 | installdirs: | |
318 | for dir in "$(DESTDIR)$(appmandir)"; do \ | |
319 | test -z "$$dir" || $(MKDIR_P) "$$dir"; \ | |
320 | done | |
321 | install: install-am | |
322 | install-exec: install-exec-am | |
323 | install-data: install-data-am | |
324 | uninstall: uninstall-am | |
325 | ||
326 | install-am: all-am | |
327 | @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am | |
328 | ||
329 | installcheck: installcheck-am | |
330 | install-strip: | |
331 | $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \ | |
332 | install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \ | |
333 | `test -z '$(STRIP)' || \ | |
334 | echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install | |
335 | mostlyclean-generic: | |
336 | ||
337 | clean-generic: | |
338 | -test -z "$(CLEANFILES)" || rm -f $(CLEANFILES) | |
339 | ||
340 | distclean-generic: | |
341 | -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES) | |
342 | -test . = "$(srcdir)" || test -z "$(CONFIG_CLEAN_VPATH_FILES)" || rm -f $(CONFIG_CLEAN_VPATH_FILES) | |
343 | ||
344 | maintainer-clean-generic: | |
345 | @echo "This command is intended for maintainers to use" | |
346 | @echo "it deletes files that may require special tools to rebuild." | |
347 | clean: clean-am | |
348 | ||
349 | clean-am: clean-generic mostlyclean-am | |
350 | ||
351 | distclean: distclean-am | |
352 | -rm -f Makefile | |
353 | distclean-am: clean-am distclean-generic | |
354 | ||
355 | dvi: dvi-am | |
356 | ||
357 | dvi-am: | |
358 | ||
359 | html: html-am | |
360 | ||
361 | html-am: | |
362 | ||
363 | info: info-am | |
364 | ||
365 | info-am: | |
366 | ||
367 | install-data-am: install-appmanDATA | |
368 | ||
369 | install-dvi: install-dvi-am | |
370 | ||
371 | install-dvi-am: | |
372 | ||
373 | install-exec-am: | |
374 | ||
375 | install-html: install-html-am | |
376 | ||
377 | install-html-am: | |
378 | ||
379 | install-info: install-info-am | |
380 | ||
381 | install-info-am: | |
382 | ||
383 | install-man: | |
384 | ||
385 | install-pdf: install-pdf-am | |
386 | ||
387 | install-pdf-am: | |
388 | ||
389 | install-ps: install-ps-am | |
390 | ||
391 | install-ps-am: | |
392 | ||
393 | installcheck-am: | |
394 | ||
395 | maintainer-clean: maintainer-clean-am | |
396 | -rm -f Makefile | |
397 | maintainer-clean-am: distclean-am maintainer-clean-generic | |
398 | ||
399 | mostlyclean: mostlyclean-am | |
400 | ||
401 | mostlyclean-am: mostlyclean-generic | |
402 | ||
403 | pdf: pdf-am | |
404 | ||
405 | pdf-am: | |
406 | ||
407 | ps: ps-am | |
408 | ||
409 | ps-am: | |
410 | ||
411 | uninstall-am: uninstall-appmanDATA | |
412 | ||
413 | .MAKE: install-am install-strip | |
414 | ||
415 | .PHONY: all all-am check check-am clean clean-generic distclean \ | |
416 | distclean-generic distdir dvi dvi-am html html-am info info-am \ | |
417 | install install-am install-appmanDATA install-data \ | |
418 | install-data-am install-dvi install-dvi-am install-exec \ | |
419 | install-exec-am install-html install-html-am install-info \ | |
420 | install-info-am install-man install-pdf install-pdf-am \ | |
421 | install-ps install-ps-am install-strip installcheck \ | |
422 | installcheck-am installdirs maintainer-clean \ | |
423 | maintainer-clean-generic mostlyclean mostlyclean-generic pdf \ | |
424 | pdf-am ps ps-am uninstall uninstall-am uninstall-appmanDATA | |
425 | ||
426 | ||
427 | # String replacements in MAN_SUBSTS now come from xorg-macros.m4 via configure | |
428 | .man.$(APP_MAN_SUFFIX): | |
429 | $(AM_V_GEN)$(SED) $(MAN_SUBSTS) < $< > $@ | |
430 | ||
431 | # Tell versions [3.59,3.63) of GNU make to not export all variables. | |
432 | # Otherwise a system limit (for SysV at least) may be exceeded. | |
433 | .NOEXPORT: |
0 | .ds q \N'34' | |
1 | .TH rendercheck 1 __xorgversion__ | |
2 | .SH NAME | |
3 | rendercheck \- simple tests of the X Render extension. | |
4 | .SH SYNOPSIS | |
5 | .nf | |
6 | .B rendercheck [\-d|\-\-display display] [\-i|\-\-iter] [\-\-sync] \ | |
7 | [\-t|\-\-tests test1,test2,test3,...] [\-o|\-\-ops op1,op2,op3,...] | |
8 | [\-v|\-\-verbose] [\-\-minimalrendering] | |
9 | .fi | |
10 | .SH DESCRIPTION | |
11 | .B rendercheck | |
12 | is a set of simple tests of the X Render extension. It is designed for authors | |
13 | of Render implementations in X Servers. | |
14 | .SH OPTIONS | |
15 | .TP | |
16 | .BI \-d|\-\-display\ display | |
17 | Specifies the display to test against. | |
18 | .TP | |
19 | .BI \-i|\-\-iter\ iterations | |
20 | Specifies the number of times to repeat each operation before sampling results. | |
21 | Some X Servers may behave differently (hardware vs software rendering paths) | |
22 | depending on the previous operations done, so this may be used to influence the | |
23 | server's choices. | |
24 | .TP | |
25 | .BI \-\-sync | |
26 | Enables synchronous xlib operation, for debugging. | |
27 | .TP | |
28 | .BI \-t|\-\-tests\ test1,test2,test3... | |
29 | Enables only a specific subset of the possible tests. Test names include | |
30 | fill, dcoords, scoords, mcoords, tscoords, tmcoords, blend, composite, | |
31 | cacomposite, gradients, repeat, triangles, and bug7366. | |
32 | Names must be separated by | |
33 | commas and have no spaces. | |
34 | .TP | |
35 | .BI \-f|\-\-formats\ format1,format2,format3... | |
36 | Enables only a specific subset of the possible formats. Only formats listed | |
37 | in the server-supported format list are available. Names must be separated by | |
38 | commas and have no spaces. | |
39 | .TP | |
40 | .BI \-o|\-\-ops | |
41 | Enables only a specific subset of the Render operators. | |
42 | .TP | |
43 | .BI \-v|\-\-verbose | |
44 | Enables verbose printing of information on tests run, and successes and | |
45 | failures. | |
46 | .TP | |
47 | .BI \-\-minimalrendering | |
48 | Disables copying of offscreen destinations to the window, which is on by default | |
49 | to provide the user with visual feedback. | |
50 | .SH BUGS | |
51 | Several limitations are documented in the TODO file accompanying the source. | |
52 | Please report any further bugs you find to http://bugs.freedesktop.org/. | |
53 | .SH AUTHORS | |
54 | Eric Anholt, with help from Keith Packard. |
0 | #! /bin/sh | |
1 | # Common stub for a few missing GNU programs while installing. | |
2 | ||
3 | scriptversion=2009-04-28.21; # UTC | |
4 | ||
5 | # Copyright (C) 1996, 1997, 1999, 2000, 2002, 2003, 2004, 2005, 2006, | |
6 | # 2008, 2009 Free Software Foundation, Inc. | |
7 | # Originally by Fran,cois Pinard <pinard@iro.umontreal.ca>, 1996. | |
8 | ||
9 | # This program is free software; you can redistribute it and/or modify | |
10 | # it under the terms of the GNU General Public License as published by | |
11 | # the Free Software Foundation; either version 2, or (at your option) | |
12 | # any later version. | |
13 | ||
14 | # This program is distributed in the hope that it will be useful, | |
15 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
16 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
17 | # GNU General Public License for more details. | |
18 | ||
19 | # You should have received a copy of the GNU General Public License | |
20 | # along with this program. If not, see <http://www.gnu.org/licenses/>. | |
21 | ||
22 | # As a special exception to the GNU General Public License, if you | |
23 | # distribute this file as part of a program that contains a | |
24 | # configuration script generated by Autoconf, you may include it under | |
25 | # the same distribution terms that you use for the rest of that program. | |
26 | ||
27 | if test $# -eq 0; then | |
28 | echo 1>&2 "Try \`$0 --help' for more information" | |
29 | exit 1 | |
30 | fi | |
31 | ||
32 | run=: | |
33 | sed_output='s/.* --output[ =]\([^ ]*\).*/\1/p' | |
34 | sed_minuso='s/.* -o \([^ ]*\).*/\1/p' | |
35 | ||
36 | # In the cases where this matters, `missing' is being run in the | |
37 | # srcdir already. | |
38 | if test -f configure.ac; then | |
39 | configure_ac=configure.ac | |
40 | else | |
41 | configure_ac=configure.in | |
42 | fi | |
43 | ||
44 | msg="missing on your system" | |
45 | ||
46 | case $1 in | |
47 | --run) | |
48 | # Try to run requested program, and just exit if it succeeds. | |
49 | run= | |
50 | shift | |
51 | "$@" && exit 0 | |
52 | # Exit code 63 means version mismatch. This often happens | |
53 | # when the user try to use an ancient version of a tool on | |
54 | # a file that requires a minimum version. In this case we | |
55 | # we should proceed has if the program had been absent, or | |
56 | # if --run hadn't been passed. | |
57 | if test $? = 63; then | |
58 | run=: | |
59 | msg="probably too old" | |
60 | fi | |
61 | ;; | |
62 | ||
63 | -h|--h|--he|--hel|--help) | |
64 | echo "\ | |
65 | $0 [OPTION]... PROGRAM [ARGUMENT]... | |
66 | ||
67 | Handle \`PROGRAM [ARGUMENT]...' for when PROGRAM is missing, or return an | |
68 | error status if there is no known handling for PROGRAM. | |
69 | ||
70 | Options: | |
71 | -h, --help display this help and exit | |
72 | -v, --version output version information and exit | |
73 | --run try to run the given command, and emulate it if it fails | |
74 | ||
75 | Supported PROGRAM values: | |
76 | aclocal touch file \`aclocal.m4' | |
77 | autoconf touch file \`configure' | |
78 | autoheader touch file \`config.h.in' | |
79 | autom4te touch the output file, or create a stub one | |
80 | automake touch all \`Makefile.in' files | |
81 | bison create \`y.tab.[ch]', if possible, from existing .[ch] | |
82 | flex create \`lex.yy.c', if possible, from existing .c | |
83 | help2man touch the output file | |
84 | lex create \`lex.yy.c', if possible, from existing .c | |
85 | makeinfo touch the output file | |
86 | tar try tar, gnutar, gtar, then tar without non-portable flags | |
87 | yacc create \`y.tab.[ch]', if possible, from existing .[ch] | |
88 | ||
89 | Version suffixes to PROGRAM as well as the prefixes \`gnu-', \`gnu', and | |
90 | \`g' are ignored when checking the name. | |
91 | ||
92 | Send bug reports to <bug-automake@gnu.org>." | |
93 | exit $? | |
94 | ;; | |
95 | ||
96 | -v|--v|--ve|--ver|--vers|--versi|--versio|--version) | |
97 | echo "missing $scriptversion (GNU Automake)" | |
98 | exit $? | |
99 | ;; | |
100 | ||
101 | -*) | |
102 | echo 1>&2 "$0: Unknown \`$1' option" | |
103 | echo 1>&2 "Try \`$0 --help' for more information" | |
104 | exit 1 | |
105 | ;; | |
106 | ||
107 | esac | |
108 | ||
109 | # normalize program name to check for. | |
110 | program=`echo "$1" | sed ' | |
111 | s/^gnu-//; t | |
112 | s/^gnu//; t | |
113 | s/^g//; t'` | |
114 | ||
115 | # Now exit if we have it, but it failed. Also exit now if we | |
116 | # don't have it and --version was passed (most likely to detect | |
117 | # the program). This is about non-GNU programs, so use $1 not | |
118 | # $program. | |
119 | case $1 in | |
120 | lex*|yacc*) | |
121 | # Not GNU programs, they don't have --version. | |
122 | ;; | |
123 | ||
124 | tar*) | |
125 | if test -n "$run"; then | |
126 | echo 1>&2 "ERROR: \`tar' requires --run" | |
127 | exit 1 | |
128 | elif test "x$2" = "x--version" || test "x$2" = "x--help"; then | |
129 | exit 1 | |
130 | fi | |
131 | ;; | |
132 | ||
133 | *) | |
134 | if test -z "$run" && ($1 --version) > /dev/null 2>&1; then | |
135 | # We have it, but it failed. | |
136 | exit 1 | |
137 | elif test "x$2" = "x--version" || test "x$2" = "x--help"; then | |
138 | # Could not run --version or --help. This is probably someone | |
139 | # running `$TOOL --version' or `$TOOL --help' to check whether | |
140 | # $TOOL exists and not knowing $TOOL uses missing. | |
141 | exit 1 | |
142 | fi | |
143 | ;; | |
144 | esac | |
145 | ||
146 | # If it does not exist, or fails to run (possibly an outdated version), | |
147 | # try to emulate it. | |
148 | case $program in | |
149 | aclocal*) | |
150 | echo 1>&2 "\ | |
151 | WARNING: \`$1' is $msg. You should only need it if | |
152 | you modified \`acinclude.m4' or \`${configure_ac}'. You might want | |
153 | to install the \`Automake' and \`Perl' packages. Grab them from | |
154 | any GNU archive site." | |
155 | touch aclocal.m4 | |
156 | ;; | |
157 | ||
158 | autoconf*) | |
159 | echo 1>&2 "\ | |
160 | WARNING: \`$1' is $msg. You should only need it if | |
161 | you modified \`${configure_ac}'. You might want to install the | |
162 | \`Autoconf' and \`GNU m4' packages. Grab them from any GNU | |
163 | archive site." | |
164 | touch configure | |
165 | ;; | |
166 | ||
167 | autoheader*) | |
168 | echo 1>&2 "\ | |
169 | WARNING: \`$1' is $msg. You should only need it if | |
170 | you modified \`acconfig.h' or \`${configure_ac}'. You might want | |
171 | to install the \`Autoconf' and \`GNU m4' packages. Grab them | |
172 | from any GNU archive site." | |
173 | files=`sed -n 's/^[ ]*A[CM]_CONFIG_HEADER(\([^)]*\)).*/\1/p' ${configure_ac}` | |
174 | test -z "$files" && files="config.h" | |
175 | touch_files= | |
176 | for f in $files; do | |
177 | case $f in | |
178 | *:*) touch_files="$touch_files "`echo "$f" | | |
179 | sed -e 's/^[^:]*://' -e 's/:.*//'`;; | |
180 | *) touch_files="$touch_files $f.in";; | |
181 | esac | |
182 | done | |
183 | touch $touch_files | |
184 | ;; | |
185 | ||
186 | automake*) | |
187 | echo 1>&2 "\ | |
188 | WARNING: \`$1' is $msg. You should only need it if | |
189 | you modified \`Makefile.am', \`acinclude.m4' or \`${configure_ac}'. | |
190 | You might want to install the \`Automake' and \`Perl' packages. | |
191 | Grab them from any GNU archive site." | |
192 | find . -type f -name Makefile.am -print | | |
193 | sed 's/\.am$/.in/' | | |
194 | while read f; do touch "$f"; done | |
195 | ;; | |
196 | ||
197 | autom4te*) | |
198 | echo 1>&2 "\ | |
199 | WARNING: \`$1' is needed, but is $msg. | |
200 | You might have modified some files without having the | |
201 | proper tools for further handling them. | |
202 | You can get \`$1' as part of \`Autoconf' from any GNU | |
203 | archive site." | |
204 | ||
205 | file=`echo "$*" | sed -n "$sed_output"` | |
206 | test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` | |
207 | if test -f "$file"; then | |
208 | touch $file | |
209 | else | |
210 | test -z "$file" || exec >$file | |
211 | echo "#! /bin/sh" | |
212 | echo "# Created by GNU Automake missing as a replacement of" | |
213 | echo "# $ $@" | |
214 | echo "exit 0" | |
215 | chmod +x $file | |
216 | exit 1 | |
217 | fi | |
218 | ;; | |
219 | ||
220 | bison*|yacc*) | |
221 | echo 1>&2 "\ | |
222 | WARNING: \`$1' $msg. You should only need it if | |
223 | you modified a \`.y' file. You may need the \`Bison' package | |
224 | in order for those modifications to take effect. You can get | |
225 | \`Bison' from any GNU archive site." | |
226 | rm -f y.tab.c y.tab.h | |
227 | if test $# -ne 1; then | |
228 | eval LASTARG="\${$#}" | |
229 | case $LASTARG in | |
230 | *.y) | |
231 | SRCFILE=`echo "$LASTARG" | sed 's/y$/c/'` | |
232 | if test -f "$SRCFILE"; then | |
233 | cp "$SRCFILE" y.tab.c | |
234 | fi | |
235 | SRCFILE=`echo "$LASTARG" | sed 's/y$/h/'` | |
236 | if test -f "$SRCFILE"; then | |
237 | cp "$SRCFILE" y.tab.h | |
238 | fi | |
239 | ;; | |
240 | esac | |
241 | fi | |
242 | if test ! -f y.tab.h; then | |
243 | echo >y.tab.h | |
244 | fi | |
245 | if test ! -f y.tab.c; then | |
246 | echo 'main() { return 0; }' >y.tab.c | |
247 | fi | |
248 | ;; | |
249 | ||
250 | lex*|flex*) | |
251 | echo 1>&2 "\ | |
252 | WARNING: \`$1' is $msg. You should only need it if | |
253 | you modified a \`.l' file. You may need the \`Flex' package | |
254 | in order for those modifications to take effect. You can get | |
255 | \`Flex' from any GNU archive site." | |
256 | rm -f lex.yy.c | |
257 | if test $# -ne 1; then | |
258 | eval LASTARG="\${$#}" | |
259 | case $LASTARG in | |
260 | *.l) | |
261 | SRCFILE=`echo "$LASTARG" | sed 's/l$/c/'` | |
262 | if test -f "$SRCFILE"; then | |
263 | cp "$SRCFILE" lex.yy.c | |
264 | fi | |
265 | ;; | |
266 | esac | |
267 | fi | |
268 | if test ! -f lex.yy.c; then | |
269 | echo 'main() { return 0; }' >lex.yy.c | |
270 | fi | |
271 | ;; | |
272 | ||
273 | help2man*) | |
274 | echo 1>&2 "\ | |
275 | WARNING: \`$1' is $msg. You should only need it if | |
276 | you modified a dependency of a manual page. You may need the | |
277 | \`Help2man' package in order for those modifications to take | |
278 | effect. You can get \`Help2man' from any GNU archive site." | |
279 | ||
280 | file=`echo "$*" | sed -n "$sed_output"` | |
281 | test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` | |
282 | if test -f "$file"; then | |
283 | touch $file | |
284 | else | |
285 | test -z "$file" || exec >$file | |
286 | echo ".ab help2man is required to generate this page" | |
287 | exit $? | |
288 | fi | |
289 | ;; | |
290 | ||
291 | makeinfo*) | |
292 | echo 1>&2 "\ | |
293 | WARNING: \`$1' is $msg. You should only need it if | |
294 | you modified a \`.texi' or \`.texinfo' file, or any other file | |
295 | indirectly affecting the aspect of the manual. The spurious | |
296 | call might also be the consequence of using a buggy \`make' (AIX, | |
297 | DU, IRIX). You might want to install the \`Texinfo' package or | |
298 | the \`GNU make' package. Grab either from any GNU archive site." | |
299 | # The file to touch is that specified with -o ... | |
300 | file=`echo "$*" | sed -n "$sed_output"` | |
301 | test -z "$file" && file=`echo "$*" | sed -n "$sed_minuso"` | |
302 | if test -z "$file"; then | |
303 | # ... or it is the one specified with @setfilename ... | |
304 | infile=`echo "$*" | sed 's/.* \([^ ]*\) *$/\1/'` | |
305 | file=`sed -n ' | |
306 | /^@setfilename/{ | |
307 | s/.* \([^ ]*\) *$/\1/ | |
308 | p | |
309 | q | |
310 | }' $infile` | |
311 | # ... or it is derived from the source name (dir/f.texi becomes f.info) | |
312 | test -z "$file" && file=`echo "$infile" | sed 's,.*/,,;s,.[^.]*$,,'`.info | |
313 | fi | |
314 | # If the file does not exist, the user really needs makeinfo; | |
315 | # let's fail without touching anything. | |
316 | test -f $file || exit 1 | |
317 | touch $file | |
318 | ;; | |
319 | ||
320 | tar*) | |
321 | shift | |
322 | ||
323 | # We have already tried tar in the generic part. | |
324 | # Look for gnutar/gtar before invocation to avoid ugly error | |
325 | # messages. | |
326 | if (gnutar --version > /dev/null 2>&1); then | |
327 | gnutar "$@" && exit 0 | |
328 | fi | |
329 | if (gtar --version > /dev/null 2>&1); then | |
330 | gtar "$@" && exit 0 | |
331 | fi | |
332 | firstarg="$1" | |
333 | if shift; then | |
334 | case $firstarg in | |
335 | *o*) | |
336 | firstarg=`echo "$firstarg" | sed s/o//` | |
337 | tar "$firstarg" "$@" && exit 0 | |
338 | ;; | |
339 | esac | |
340 | case $firstarg in | |
341 | *h*) | |
342 | firstarg=`echo "$firstarg" | sed s/h//` | |
343 | tar "$firstarg" "$@" && exit 0 | |
344 | ;; | |
345 | esac | |
346 | fi | |
347 | ||
348 | echo 1>&2 "\ | |
349 | WARNING: I can't seem to be able to run \`tar' with the given arguments. | |
350 | You may want to install GNU tar or Free paxutils, or check the | |
351 | command line arguments." | |
352 | exit 1 | |
353 | ;; | |
354 | ||
355 | *) | |
356 | echo 1>&2 "\ | |
357 | WARNING: \`$1' is needed, and is $msg. | |
358 | You might have modified some files without having the | |
359 | proper tools for further handling them. Check the \`README' file, | |
360 | it often tells you about the needed prerequisites for installing | |
361 | this package. You may also peek at any GNU archive site, in case | |
362 | some other package would contain this missing \`$1' program." | |
363 | exit 1 | |
364 | ;; | |
365 | esac | |
366 | ||
367 | exit 0 | |
368 | ||
369 | # Local variables: | |
370 | # eval: (add-hook 'write-file-hooks 'time-stamp) | |
371 | # time-stamp-start: "scriptversion=" | |
372 | # time-stamp-format: "%:y-%02m-%02d.%02H" | |
373 | # time-stamp-time-zone: "UTC" | |
374 | # time-stamp-end: "; # UTC" | |
375 | # End: |
0 | /* | |
1 | * Copyright © 2004 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdlib.h> | |
23 | ||
24 | #include "rendercheck.h" | |
25 | ||
26 | #define mult_chan(src, dst, Fa, Fb) \ | |
27 | min((double)(src) * (double)(Fa) + (double)(dst) * (double)(Fb), 1.0) | |
28 | ||
29 | static double | |
30 | calc_op(int op, double src, double dst, double srca, double dsta) | |
31 | { | |
32 | double Fa, Fb; | |
33 | ||
34 | switch (op) { | |
35 | case PictOpClear: | |
36 | case PictOpDisjointClear: | |
37 | case PictOpConjointClear: | |
38 | return mult_chan(src, dst, 0.0, 0.0); | |
39 | case PictOpSrc: | |
40 | case PictOpDisjointSrc: | |
41 | case PictOpConjointSrc: | |
42 | return mult_chan(src, dst, 1.0, 0.0); | |
43 | case PictOpDst: | |
44 | case PictOpDisjointDst: | |
45 | case PictOpConjointDst: | |
46 | return mult_chan(src, dst, 0.0, 1.0); | |
47 | case PictOpOver: | |
48 | return mult_chan(src, dst, 1.0, 1.0 - srca); | |
49 | case PictOpOverReverse: | |
50 | return mult_chan(src, dst, 1.0 - dsta, 1.0); | |
51 | case PictOpIn: | |
52 | return mult_chan(src, dst, dsta, 0.0); | |
53 | case PictOpInReverse: | |
54 | return mult_chan(src, dst, 0.0, srca); | |
55 | case PictOpOut: | |
56 | return mult_chan(src, dst, 1.0 - dsta, 0.0); | |
57 | case PictOpOutReverse: | |
58 | return mult_chan(src, dst, 0.0, 1.0 - srca); | |
59 | case PictOpAtop: | |
60 | return mult_chan(src, dst, dsta, 1.0 - srca); | |
61 | case PictOpAtopReverse: | |
62 | return mult_chan(src, dst, 1.0 - dsta, srca); | |
63 | case PictOpXor: | |
64 | return mult_chan(src, dst, 1.0 - dsta, 1.0 - srca); | |
65 | case PictOpAdd: | |
66 | return mult_chan(src, dst, 1.0, 1.0); | |
67 | break; | |
68 | case PictOpSaturate: | |
69 | case PictOpDisjointOverReverse: | |
70 | if (srca == 0.0) | |
71 | Fa = 1.0; | |
72 | else | |
73 | Fa = min(1.0, (1.0 - dsta) / srca); | |
74 | return mult_chan(src, dst, Fa, 1.0); | |
75 | case PictOpDisjointOver: | |
76 | if (dsta == 0.0) | |
77 | Fb = 1.0; | |
78 | else | |
79 | Fb = min(1.0, (1.0 - srca) / dsta); | |
80 | return mult_chan(src, dst, 1.0, Fb); | |
81 | case PictOpDisjointIn: | |
82 | if (srca == 0.0) | |
83 | Fa = 0.0; | |
84 | else | |
85 | Fa = max(0.0, 1.0 - (1.0 - dsta) / srca); | |
86 | return mult_chan(src, dst, Fa, 0.0); | |
87 | case PictOpDisjointInReverse: | |
88 | if (dsta == 0.0) | |
89 | Fb = 0.0; | |
90 | else | |
91 | Fb = max(0.0, 1.0 - (1.0 - srca) / dsta); | |
92 | return mult_chan(src, dst, 0.0, Fb); | |
93 | case PictOpDisjointOut: | |
94 | if (srca == 0.0) | |
95 | Fa = 1.0; | |
96 | else | |
97 | Fa = min(1.0, (1.0 - dsta) / srca); | |
98 | return mult_chan(src, dst, Fa, 0.0); | |
99 | case PictOpDisjointOutReverse: | |
100 | if (dsta == 0.0) | |
101 | Fb = 1.0; | |
102 | else | |
103 | Fb = min(1.0, (1.0 - srca) / dsta); | |
104 | return mult_chan(src, dst, 0.0, Fb); | |
105 | case PictOpDisjointAtop: | |
106 | if (srca == 0.0) | |
107 | Fa = 0.0; | |
108 | else | |
109 | Fa = max(0.0, 1.0 - (1.0 - dsta) / srca); | |
110 | if (dsta == 0.0) | |
111 | Fb = 1.0; | |
112 | else | |
113 | Fb = min(1.0, (1.0 - srca) / dsta); | |
114 | return mult_chan(src, dst, Fa, Fb); | |
115 | case PictOpDisjointAtopReverse: | |
116 | if (srca == 0.0) | |
117 | Fa = 1.0; | |
118 | else | |
119 | Fa = min(1.0, (1.0 - dsta) / srca); | |
120 | if (dsta == 0.0) | |
121 | Fb = 0.0; | |
122 | else | |
123 | Fb = max(0.0, 1.0 - (1.0 - srca) / dsta); | |
124 | return mult_chan(src, dst, Fa, Fb); | |
125 | case PictOpDisjointXor: | |
126 | if (srca == 0.0) | |
127 | Fa = 1.0; | |
128 | else | |
129 | Fa = min(1.0, (1.0 - dsta) / srca); | |
130 | if (dsta == 0.0) | |
131 | Fb = 1.0; | |
132 | else | |
133 | Fb = min(1.0, (1.0 - srca) / dsta); | |
134 | return mult_chan(src, dst, Fa, Fb); | |
135 | case PictOpConjointOver: | |
136 | if (dsta == 0.0) | |
137 | Fb = 0.0; | |
138 | else | |
139 | Fb = max(0.0, 1.0 - srca / dsta); | |
140 | return mult_chan(src, dst, 1.0, Fb); | |
141 | case PictOpConjointOverReverse: | |
142 | if (srca == 0.0) | |
143 | Fa = 0.0; | |
144 | else | |
145 | Fa = max(0.0, 1.0 - dsta / srca); | |
146 | return mult_chan(src, dst, Fa, 1.0); | |
147 | case PictOpConjointIn: | |
148 | if (srca == 0.0) | |
149 | Fa = 1.0; | |
150 | else | |
151 | Fa = min(1.0, dsta / srca); | |
152 | return mult_chan(src, dst, Fa, 0.0); | |
153 | case PictOpConjointInReverse: | |
154 | if (dsta == 0.0) | |
155 | Fb = 1.0; | |
156 | else | |
157 | Fb = min(1.0, srca / dsta); | |
158 | return mult_chan(src, dst, 0.0, Fb); | |
159 | case PictOpConjointOut: | |
160 | if (srca == 0.0) | |
161 | Fa = 0.0; | |
162 | else | |
163 | Fa = max(0.0, 1.0 - dsta / srca); | |
164 | return mult_chan(src, dst, Fa, 0.0); | |
165 | case PictOpConjointOutReverse: | |
166 | if (dsta == 0.0) | |
167 | Fb = 0.0; | |
168 | else | |
169 | Fb = max(0.0, 1.0 - srca / dsta); | |
170 | return mult_chan(src, dst, 0.0, Fb); | |
171 | case PictOpConjointAtop: | |
172 | if (srca == 0.0) | |
173 | Fa = 1.0; | |
174 | else | |
175 | Fa = min(1.0, dsta / srca); | |
176 | if (dsta == 0.0) | |
177 | Fb = 0.0; | |
178 | else | |
179 | Fb = max(0.0, 1.0 - srca / dsta); | |
180 | return mult_chan(src, dst, Fa, Fb); | |
181 | case PictOpConjointAtopReverse: | |
182 | if (srca == 0.0) | |
183 | Fa = 0.0; | |
184 | else | |
185 | Fa = max(0.0, 1.0 - dsta / srca); | |
186 | if (dsta == 0.0) | |
187 | Fb = 1.0; | |
188 | else | |
189 | Fb = min(1.0, srca / dsta); | |
190 | return mult_chan(src, dst, Fa, Fb); | |
191 | case PictOpConjointXor: | |
192 | if (srca == 0.0) | |
193 | Fa = 0.0; | |
194 | else | |
195 | Fa = max(0.0, 1.0 - dsta / srca); | |
196 | if (dsta == 0.0) | |
197 | Fb = 0.0; | |
198 | else | |
199 | Fb = max(0.0, 1.0 - srca / dsta); | |
200 | return mult_chan(src, dst, Fa, Fb); | |
201 | default: | |
202 | abort(); | |
203 | } | |
204 | } | |
205 | ||
206 | void | |
207 | do_composite(int op, color4d *src, color4d *mask, color4d *dst, color4d *result, | |
208 | Bool componentAlpha) | |
209 | { | |
210 | color4d srcval, srcalpha; | |
211 | ||
212 | if (mask != NULL && componentAlpha) { | |
213 | srcval.r = src->r * mask->r; | |
214 | srcval.g = src->g * mask->g; | |
215 | srcval.b = src->b * mask->b; | |
216 | srcval.a = src->a * mask->a; | |
217 | srcalpha.r = src->a * mask->r; | |
218 | srcalpha.g = src->a * mask->g; | |
219 | srcalpha.b = src->a * mask->b; | |
220 | srcalpha.a = src->a * mask->a; | |
221 | } else if (mask != NULL) { | |
222 | srcval.r = src->r * mask->a; | |
223 | srcval.g = src->g * mask->a; | |
224 | srcval.b = src->b * mask->a; | |
225 | srcval.a = src->a * mask->a; | |
226 | srcalpha.r = src->a * mask->a; | |
227 | srcalpha.g = src->a * mask->a; | |
228 | srcalpha.b = src->a * mask->a; | |
229 | srcalpha.a = src->a * mask->a; | |
230 | } else { | |
231 | srcval = *src; | |
232 | srcalpha.r = src->a; | |
233 | srcalpha.g = src->a; | |
234 | srcalpha.b = src->a; | |
235 | srcalpha.a = src->a; | |
236 | } | |
237 | ||
238 | result->r = calc_op(op, srcval.r, dst->r, srcalpha.r, dst->a); | |
239 | result->g = calc_op(op, srcval.g, dst->g, srcalpha.g, dst->a); | |
240 | result->b = calc_op(op, srcval.b, dst->b, srcalpha.b, dst->a); | |
241 | result->a = calc_op(op, srcval.a, dst->a, srcalpha.a, dst->a); | |
242 | } |
0 | /* | |
1 | * Copyright © 2004 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <X11/Xlib.h> | |
23 | #include <X11/extensions/Xrender.h> | |
24 | ||
25 | #if HAVE_ERR_H | |
26 | # include <err.h> | |
27 | #else | |
28 | # include <stdarg.h> | |
29 | # include <stdio.h> | |
30 | # include <stdlib.h> | |
31 | static inline void errx(int eval, const char *fmt, ...) { | |
32 | va_list args; | |
33 | ||
34 | va_start(args, fmt); | |
35 | fprintf(stderr, "Fatal Error: "); | |
36 | fprintf(stderr, fmt, args); | |
37 | fprintf(stderr, "\n", args); | |
38 | va_end(args); | |
39 | exit(eval); | |
40 | } | |
41 | #endif | |
42 | ||
43 | #define min(a, b) (a < b ? a : b) | |
44 | #define max(a, b) (a > b ? a : b) | |
45 | ||
46 | #ifndef TRUE | |
47 | #define TRUE 1 | |
48 | #define FALSE 0 | |
49 | #endif | |
50 | ||
51 | typedef struct _color4d | |
52 | { | |
53 | double r, g, b, a; | |
54 | } color4d; | |
55 | ||
56 | typedef struct _picture_info { | |
57 | Drawable d; | |
58 | Picture pict; | |
59 | XRenderPictFormat *format; | |
60 | char *name; /* Possibly, some descriptive name. */ | |
61 | color4d color; /* If a 1x1R pict, the (corrected) color.*/ | |
62 | } picture_info; | |
63 | ||
64 | struct op_info { | |
65 | int op; | |
66 | char *name; | |
67 | Bool disabled; | |
68 | }; | |
69 | ||
70 | #define TEST_FILL 0x0001 | |
71 | #define TEST_DSTCOORDS 0x0002 | |
72 | #define TEST_SRCCOORDS 0x0004 | |
73 | #define TEST_MASKCOORDS 0x0008 | |
74 | #define TEST_TSRCCOORDS 0x0010 | |
75 | #define TEST_TMASKCOORDS 0x0020 | |
76 | #define TEST_BLEND 0x0040 | |
77 | #define TEST_COMPOSITE 0x0080 | |
78 | #define TEST_CACOMPOSITE 0x0100 | |
79 | #define TEST_GRADIENTS 0x0200 | |
80 | #define TEST_REPEAT 0x0400 | |
81 | #define TEST_TRIANGLES 0x0800 | |
82 | #define TEST_BUG7366 0x1000 | |
83 | ||
84 | extern int pixmap_move_iter; | |
85 | extern int win_width, win_height; | |
86 | extern struct op_info ops[]; | |
87 | extern Bool is_verbose, minimalrendering; | |
88 | extern color4d colors[]; | |
89 | extern int enabled_tests; | |
90 | extern int format_whitelist_len; | |
91 | extern char **format_whitelist; | |
92 | extern picture_info *argb32white, *argb32red, *argb32green, *argb32blue; | |
93 | extern int num_ops; | |
94 | extern int num_colors; | |
95 | ||
96 | /* main.c */ | |
97 | void | |
98 | describe_format(char *desc, int len, XRenderPictFormat *format); | |
99 | ||
100 | int | |
101 | bit_count(int i); | |
102 | ||
103 | /* tests.c */ | |
104 | void | |
105 | color_correct(picture_info *pi, color4d *color); | |
106 | ||
107 | void | |
108 | get_pixel(Display *dpy, picture_info *pi, int x, int y, color4d *color); | |
109 | ||
110 | int | |
111 | eval_diff(char *name, color4d *expected, color4d *test, int x, int y, | |
112 | Bool verbose); | |
113 | ||
114 | void | |
115 | argb_fill(Display *dpy, picture_info *p, int x, int y, int w, int h, float a, | |
116 | float r, float g, float b); | |
117 | ||
118 | Bool | |
119 | do_tests(Display *dpy, picture_info *win); | |
120 | ||
121 | void | |
122 | copy_pict_to_win(Display *dpy, picture_info *pict, picture_info *win, | |
123 | int width, int height); | |
124 | ||
125 | /* ops.c */ | |
126 | void | |
127 | do_composite(int op, color4d *src, color4d *mask, color4d *dst, color4d *result, | |
128 | Bool componentAlpha); | |
129 | ||
130 | /* The tests */ | |
131 | Bool | |
132 | blend_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
133 | picture_info *src_color, picture_info *dst_color); | |
134 | ||
135 | Bool | |
136 | composite_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
137 | picture_info *src_color, picture_info *mask_color, picture_info *dst_color, | |
138 | Bool componentAlpha, Bool print_errors); | |
139 | ||
140 | Bool | |
141 | dstcoords_test(Display *dpy, picture_info *win, int op, picture_info *dst, | |
142 | picture_info *bg, picture_info *fg); | |
143 | ||
144 | Bool | |
145 | fill_test(Display *dpy, picture_info *win, picture_info *src); | |
146 | ||
147 | Bool | |
148 | srccoords_test(Display *dpy, picture_info *win, picture_info *white, | |
149 | Bool test_mask); | |
150 | ||
151 | Bool | |
152 | trans_coords_test(Display *dpy, picture_info *win, picture_info *white, | |
153 | Bool test_mask); | |
154 | ||
155 | Bool | |
156 | trans_srccoords_test_2(Display *dpy, picture_info *win, picture_info *white, | |
157 | Bool test_mask); | |
158 | ||
159 | Bool render_to_gradient_test(Display *dpy, picture_info *src); | |
160 | ||
161 | Bool linear_gradient_test(Display *dpy, picture_info *win, | |
162 | picture_info *dst, int op, picture_info *dst_color); | |
163 | ||
164 | Bool | |
165 | repeat_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
166 | picture_info *dst_color, picture_info *c1, picture_info *c2, | |
167 | Bool test_mask); | |
168 | ||
169 | Bool | |
170 | linear_gradient_test(Display *dpy, picture_info *win, | |
171 | picture_info *dst, int op, picture_info *dst_color); | |
172 | ||
173 | Bool | |
174 | triangles_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
175 | picture_info *src_color, picture_info *dst_color); | |
176 | ||
177 | Bool | |
178 | tristrip_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
179 | picture_info *src_color, picture_info *dst_color); | |
180 | ||
181 | Bool | |
182 | trifan_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
183 | picture_info *src_color, picture_info *dst_color); | |
184 | ||
185 | Bool | |
186 | bug7366_test(Display *dpy); |
0 | /* | |
1 | * Copyright © 2005 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | ||
24 | #include "rendercheck.h" | |
25 | ||
26 | #define TEST_WIDTH 10 | |
27 | #define TEST_HEIGHT 10 | |
28 | ||
29 | /* Test a composite of a given operation, source, and destination picture. | |
30 | * Fills the window, and samples from the 0,0 pixel corner. | |
31 | */ | |
32 | Bool | |
33 | blend_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
34 | picture_info *src_color, picture_info *dst_color) | |
35 | { | |
36 | color4d expected, tested, tdst; | |
37 | char testname[20]; | |
38 | int i; | |
39 | ||
40 | for (i = 0; i < pixmap_move_iter; i++) { | |
41 | XRenderComposite(dpy, PictOpSrc, dst_color->pict, 0, | |
42 | dst->pict, 0, 0, 0, 0, 0, 0, TEST_WIDTH, TEST_HEIGHT); | |
43 | XRenderComposite(dpy, ops[op].op, src_color->pict, 0, | |
44 | dst->pict, 0, 0, 0, 0, 0, 0, TEST_WIDTH, TEST_HEIGHT); | |
45 | } | |
46 | get_pixel(dpy, dst, 0, 0, &tested); | |
47 | copy_pict_to_win(dpy, dst, win, TEST_WIDTH, TEST_HEIGHT); | |
48 | ||
49 | tdst = dst_color->color; | |
50 | color_correct(dst, &tdst); | |
51 | do_composite(ops[op].op, &src_color->color, NULL, &tdst, &expected, | |
52 | FALSE); | |
53 | color_correct(dst, &expected); | |
54 | ||
55 | snprintf(testname, 20, "%s blend", ops[op].name); | |
56 | if (!eval_diff(testname, &expected, &tested, 0, 0, is_verbose)) { | |
57 | char srcformat[20]; | |
58 | ||
59 | describe_format(srcformat, 20, src_color->format); | |
60 | printf("src color: %.2f %.2f %.2f %.2f (%s)\n" | |
61 | "dst color: %.2f %.2f %.2f %.2f\n", | |
62 | src_color->color.r, src_color->color.g, | |
63 | src_color->color.b, src_color->color.a, | |
64 | srcformat, | |
65 | dst_color->color.r, dst_color->color.g, | |
66 | dst_color->color.b, dst_color->color.a); | |
67 | printf("src: %s, dst: %s\n", src_color->name, dst->name); | |
68 | return FALSE; | |
69 | } else if (is_verbose) { | |
70 | printf("src: %s, dst: %s\n", src_color->name, dst->name); | |
71 | } | |
72 | return TRUE; | |
73 | } |
0 | /* | |
1 | * Copyright © 2006 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | #include <stdlib.h> | |
24 | #include <string.h> | |
25 | ||
26 | #include "rendercheck.h" | |
27 | ||
28 | static int | |
29 | expecting_error(Display *dpy, XErrorEvent *event) | |
30 | { | |
31 | return TRUE; | |
32 | } | |
33 | ||
34 | /** | |
35 | * Check SetPictureTransform on a source picture causing a crash. | |
36 | */ | |
37 | static Bool | |
38 | bug7366_test_set_picture_transform(Display *dpy) | |
39 | { | |
40 | Picture source_pict; | |
41 | XRenderColor color; | |
42 | XTransform transform; | |
43 | ||
44 | memset(&color, 0, sizeof(color)); | |
45 | source_pict = XRenderCreateSolidFill(dpy, &color); | |
46 | ||
47 | memset(&transform, 0, sizeof(transform)); | |
48 | XRenderSetPictureTransform(dpy, source_pict, &transform); | |
49 | ||
50 | XSync(dpy, FALSE); | |
51 | ||
52 | XRenderFreePicture(dpy, source_pict); | |
53 | ||
54 | return TRUE; | |
55 | } | |
56 | ||
57 | /** | |
58 | * Check setting of AlphaMap to a source picture causing a crash. | |
59 | */ | |
60 | static Bool | |
61 | bug7366_test_set_alpha_map(Display *dpy) | |
62 | { | |
63 | Picture source_pict, pict; | |
64 | XRenderColor color; | |
65 | Drawable pixmap; | |
66 | XRenderPictureAttributes pa; | |
67 | ||
68 | memset(&color, 0, sizeof(color)); | |
69 | source_pict = XRenderCreateSolidFill(dpy, &color); | |
70 | ||
71 | pixmap = XCreatePixmap(dpy, RootWindow(dpy, 0), 1, 1, 32); | |
72 | pict = XRenderCreatePicture(dpy, pixmap, | |
73 | XRenderFindStandardFormat(dpy, PictStandardARGB32), 0, NULL); | |
74 | ||
75 | XSetErrorHandler(expecting_error); | |
76 | pa.alpha_map = source_pict; | |
77 | XRenderChangePicture(dpy, pict, CPAlphaMap, &pa); | |
78 | XSync(dpy, FALSE); | |
79 | XSetErrorHandler(NULL); | |
80 | ||
81 | XFreePixmap(dpy, pixmap); | |
82 | XRenderFreePicture(dpy, pict); | |
83 | XRenderFreePicture(dpy, source_pict); | |
84 | ||
85 | return TRUE; | |
86 | } | |
87 | ||
88 | /** | |
89 | * Check SetPictureClipRectangles on a source potentially causing a crash. | |
90 | */ | |
91 | static Bool | |
92 | bug7366_test_set_picture_clip_rectangles(Display *dpy) | |
93 | { | |
94 | Picture source_pict; | |
95 | XRenderColor color; | |
96 | XRectangle rectangle; | |
97 | ||
98 | memset(&color, 0, sizeof(color)); | |
99 | source_pict = XRenderCreateSolidFill(dpy, &color); | |
100 | ||
101 | memset(&rectangle, 0, sizeof(rectangle)); | |
102 | XSetErrorHandler(expecting_error); | |
103 | XRenderSetPictureClipRectangles(dpy, source_pict, 0, 0, &rectangle, 1); | |
104 | XSync(dpy, FALSE); | |
105 | XSetErrorHandler(NULL); | |
106 | ||
107 | XRenderFreePicture(dpy, source_pict); | |
108 | ||
109 | return TRUE; | |
110 | } | |
111 | ||
112 | /** | |
113 | * Check SetPictureFilter on a source potentially causing a crash. | |
114 | */ | |
115 | static Bool | |
116 | bug7366_test_set_picture_filter(Display *dpy) | |
117 | { | |
118 | Picture source_pict; | |
119 | XRenderColor color; | |
120 | ||
121 | memset(&color, 0, sizeof(color)); | |
122 | source_pict = XRenderCreateSolidFill(dpy, &color); | |
123 | ||
124 | XRenderSetPictureFilter(dpy, source_pict, "bilinear", NULL, 0); | |
125 | XSync(dpy, FALSE); | |
126 | XSetErrorHandler(NULL); | |
127 | ||
128 | XRenderFreePicture(dpy, source_pict); | |
129 | ||
130 | return TRUE; | |
131 | } | |
132 | ||
133 | Bool | |
134 | bug7366_test(Display *dpy) | |
135 | { | |
136 | int maj, min; | |
137 | ||
138 | /* Make sure we actually have gradients available */ | |
139 | XRenderQueryVersion(dpy, &maj, &min); | |
140 | if (maj != 0 || min < 10) | |
141 | return TRUE; | |
142 | ||
143 | bug7366_test_set_picture_transform(dpy); | |
144 | bug7366_test_set_alpha_map(dpy); | |
145 | bug7366_test_set_picture_clip_rectangles(dpy); | |
146 | bug7366_test_set_picture_filter(dpy); | |
147 | ||
148 | /* If the server isn't gone, then we've succeeded. */ | |
149 | return TRUE; | |
150 | } |
0 | /* | |
1 | * Copyright © 2005 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | ||
24 | #include "rendercheck.h" | |
25 | ||
26 | #define TEST_WIDTH 10 | |
27 | #define TEST_HEIGHT 10 | |
28 | ||
29 | /* Test a composite of a given operation, source, mask, and destination picture. | |
30 | * Fills the window, and samples from the 0,0 pixel corner. | |
31 | */ | |
32 | Bool | |
33 | composite_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
34 | picture_info *src_color, picture_info *mask_color, picture_info *dst_color, | |
35 | Bool componentAlpha, Bool print_errors) | |
36 | { | |
37 | color4d expected, tested, tdst, tmsk; | |
38 | char testname[40]; | |
39 | XRenderPictureAttributes pa; | |
40 | Bool success = TRUE; | |
41 | int i; | |
42 | ||
43 | if (componentAlpha) { | |
44 | pa.component_alpha = TRUE; | |
45 | XRenderChangePicture(dpy, mask_color->pict, CPComponentAlpha, | |
46 | &pa); | |
47 | } | |
48 | for (i = 0; i < pixmap_move_iter; i++) { | |
49 | XRenderComposite(dpy, PictOpSrc, dst_color->pict, 0, dst->pict, | |
50 | 0, 0, 0, 0, 0, 0, TEST_WIDTH, TEST_HEIGHT); | |
51 | XRenderComposite(dpy, ops[op].op, src_color->pict, | |
52 | mask_color->pict, dst->pict, 0, 0, 0, 0, 0, 0, | |
53 | TEST_WIDTH, TEST_HEIGHT); | |
54 | } | |
55 | get_pixel(dpy, dst, 0, 0, &tested); | |
56 | copy_pict_to_win(dpy, dst, win, TEST_WIDTH, TEST_HEIGHT); | |
57 | ||
58 | if (componentAlpha) { | |
59 | pa.component_alpha = FALSE; | |
60 | XRenderChangePicture(dpy, mask_color->pict, CPComponentAlpha, | |
61 | &pa); | |
62 | } | |
63 | ||
64 | if (componentAlpha && mask_color->format->direct.redMask == 0) { | |
65 | /* Ax component-alpha masks expand alpha into all color | |
66 | * channels. XXX: This should be located somewhere generic. | |
67 | */ | |
68 | tmsk.a = mask_color->color.a; | |
69 | tmsk.r = mask_color->color.a; | |
70 | tmsk.g = mask_color->color.a; | |
71 | tmsk.b = mask_color->color.a; | |
72 | } else | |
73 | tmsk = mask_color->color; | |
74 | ||
75 | tdst = dst_color->color; | |
76 | color_correct(dst, &tdst); | |
77 | do_composite(ops[op].op, &src_color->color, &tmsk, &tdst, | |
78 | &expected, componentAlpha); | |
79 | color_correct(dst, &expected); | |
80 | ||
81 | snprintf(testname, 40, "%s %scomposite", ops[op].name, | |
82 | componentAlpha ? "CA " : ""); | |
83 | if (!eval_diff(testname, &expected, &tested, 0, 0, is_verbose && | |
84 | print_errors)) { | |
85 | if (print_errors) | |
86 | printf("src color: %.2f %.2f %.2f %.2f\n" | |
87 | "msk color: %.2f %.2f %.2f %.2f\n" | |
88 | "dst color: %.2f %.2f %.2f %.2f\n", | |
89 | src_color->color.r, src_color->color.g, | |
90 | src_color->color.b, src_color->color.a, | |
91 | mask_color->color.r, mask_color->color.g, | |
92 | mask_color->color.b, mask_color->color.a, | |
93 | dst_color->color.r, dst_color->color.g, | |
94 | dst_color->color.b, dst_color->color.a); | |
95 | printf("src: %s, mask: %s, dst: %s\n", src_color->name, | |
96 | mask_color->name, dst->name); | |
97 | success = FALSE; | |
98 | } else if (is_verbose) { | |
99 | printf("src: %s, mask: %s, dst: %s\n", src_color->name, | |
100 | mask_color->name, dst->name); | |
101 | } | |
102 | return success; | |
103 | } |
0 | /* | |
1 | * Copyright © 2005 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | ||
24 | #include "rendercheck.h" | |
25 | ||
26 | #define TEST_WIDTH 10 | |
27 | #define TEST_HEIGHT 10 | |
28 | ||
29 | /* Test destination coordinates by drawing a 3x3 picture offset one pixel. | |
30 | * | |
31 | * Note: fg must have solid 1.0 alpha, but still have an alpha channel. | |
32 | * Otherwise, we're likely to hit a path that maps PictOpOver -> PictOpSrc, | |
33 | * for example. | |
34 | */ | |
35 | Bool | |
36 | dstcoords_test(Display *dpy, picture_info *win, int op, picture_info *dst, | |
37 | picture_info *bg, picture_info *fg) | |
38 | { | |
39 | color4d expected, tested; | |
40 | int x, y, i; | |
41 | Bool failed = FALSE; | |
42 | ||
43 | for (i = 0; i < pixmap_move_iter; i++) { | |
44 | XRenderComposite(dpy, PictOpSrc, bg->pict, 0, dst->pict, 0, 0, | |
45 | 0, 0, 0, 0, TEST_WIDTH, TEST_HEIGHT); | |
46 | XRenderComposite(dpy, op, fg->pict, 0, dst->pict, 0, 0, | |
47 | 0, 0, 1, 1, 3, 3); | |
48 | } | |
49 | ||
50 | copy_pict_to_win(dpy, dst, win, TEST_WIDTH, TEST_HEIGHT); | |
51 | ||
52 | for (x = 0; x < 5; x++) { | |
53 | for (y = 0; y < 5; y++) { | |
54 | get_pixel(dpy, dst, x, y, &tested); | |
55 | if ((x >= 1 && x <= 3) && (y >= 1 && y <= 3)) | |
56 | expected = fg->color; | |
57 | else | |
58 | expected = bg->color; | |
59 | ||
60 | color_correct(dst, &expected); | |
61 | if (!eval_diff("dst coords", &expected, &tested, x, y, | |
62 | is_verbose)) | |
63 | failed = TRUE; | |
64 | } | |
65 | } | |
66 | ||
67 | return !failed; | |
68 | } |
0 | /* | |
1 | * Copyright © 2005 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | #include <string.h> | |
24 | ||
25 | #include "rendercheck.h" | |
26 | ||
27 | /* Test that filling of the 1x1 repeating pictures worked as expected. This is | |
28 | * pretty basic to most of the tests. | |
29 | */ | |
30 | Bool | |
31 | fill_test(Display *dpy, picture_info *win, picture_info *src) | |
32 | { | |
33 | color4d tested; | |
34 | char name[20]; | |
35 | ||
36 | get_pixel(dpy, src, 0, 0, &tested); | |
37 | ||
38 | copy_pict_to_win(dpy, src, win, win_width, win_height); | |
39 | ||
40 | strcpy(name, "fill "); | |
41 | describe_format(name, 20 - strlen(name), src->format); | |
42 | return eval_diff(name, &src->color, &tested, 0, 0, is_verbose); | |
43 | } |
0 | /* | |
1 | * Copyright © 2006 Lars Knoll | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of the copyright holders not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. The copyright holders makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * THE COPYRIGHT HOLDERS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | #include <assert.h> | |
24 | #include "rendercheck.h" | |
25 | ||
26 | typedef struct _stop { | |
27 | double x; | |
28 | color4d color; | |
29 | } stop; | |
30 | ||
31 | static const stop stop_list[][10] = { | |
32 | { | |
33 | { 0., {0, 0, 1.0, 1.0} }, | |
34 | { 1., {1.0, 0, 0, 1.0} }, | |
35 | { -1, {0, 0, 0, 0} } | |
36 | }, | |
37 | { | |
38 | { 0., {0, 0, 1.0, 1.0} }, | |
39 | { .5, {0, 1.0, 0, 1.0} }, | |
40 | { 1., {1.0, 0, 0, 1.0} }, | |
41 | { -1, {0, 0, 0, 0} } | |
42 | }, | |
43 | { | |
44 | { 0., {0, 0, 1.0, 0} }, | |
45 | { 1., {1.0, 0, 0, 1.0} }, | |
46 | { -1, {0, 0, 0, 0} } | |
47 | }, | |
48 | { | |
49 | { 0., {0, 0, 1.0, 0} }, | |
50 | { .5, {0, 1.0, 0, .75} }, | |
51 | { 1., {1.0, 0, 0, .5} }, | |
52 | { -1, {0, 0, 0, 0} } | |
53 | } | |
54 | }; | |
55 | static const int n_stop_list = sizeof(stop_list)/(10*sizeof(stop)); | |
56 | ||
57 | typedef struct _point { | |
58 | double x; | |
59 | double y; | |
60 | } point; | |
61 | ||
62 | static const point linear_gradient_points[] = { | |
63 | { -5, -5 }, { 5, 5 }, | |
64 | { 0, 0 }, { 10, 10 }, | |
65 | }; | |
66 | ||
67 | typedef struct _pixel { | |
68 | int x; | |
69 | int y; | |
70 | } pixel; | |
71 | ||
72 | static const pixel test_pixels [] = { | |
73 | {0, 0}, | |
74 | {0, 5}, | |
75 | {5, 0}, | |
76 | {5, 5}, | |
77 | {3, 7}, | |
78 | {7, 3}, | |
79 | {20, 20}, | |
80 | {30, 13}, | |
81 | {39, 39}, | |
82 | {-1, -1} | |
83 | }; | |
84 | ||
85 | static const int n_linear_gradient_points = sizeof(linear_gradient_points)/(2*sizeof(point)); | |
86 | ||
87 | static Bool got_bad_drawable; | |
88 | ||
89 | static int expecting_bad_drawable(Display *dpy, XErrorEvent *event) | |
90 | { | |
91 | if (event->error_code == BadDrawable) | |
92 | got_bad_drawable = TRUE; | |
93 | ||
94 | return TRUE; | |
95 | } | |
96 | ||
97 | ||
98 | /* Tests that rendering to a linear gradient returns an error as expected. | |
99 | */ | |
100 | Bool | |
101 | render_to_gradient_test(Display *dpy, picture_info *src) | |
102 | { | |
103 | XLinearGradient g; | |
104 | Picture gradient; | |
105 | XFixed stops[10]; | |
106 | XRenderColor colors[10]; | |
107 | const stop *stps = &stop_list[0][0]; | |
108 | int i, p = 0; | |
109 | ||
110 | g.p1.x = XDoubleToFixed(linear_gradient_points[p].x); | |
111 | g.p1.y = XDoubleToFixed(linear_gradient_points[p].y); | |
112 | g.p2.x = XDoubleToFixed(linear_gradient_points[p+1].x); | |
113 | g.p2.y = XDoubleToFixed(linear_gradient_points[p+1].y); | |
114 | for (i = 0; i < 10; ++i) { | |
115 | if (stps[i].x < 0) | |
116 | break; | |
117 | stops[i] = XDoubleToFixed(stps[i].x); | |
118 | colors[i].red = stps[i].color.r*65535; | |
119 | colors[i].green = stps[i].color.g*65535; | |
120 | colors[i].blue = stps[i].color.b*65535; | |
121 | colors[i].alpha = stps[i].color.a*65535; | |
122 | } | |
123 | gradient = XRenderCreateLinearGradient(dpy, &g, stops, colors, i); | |
124 | ||
125 | /* Clear out any failing requests before our expected to fail ones. */ | |
126 | XSync(dpy, FALSE); | |
127 | ||
128 | got_bad_drawable = FALSE; | |
129 | XSetErrorHandler(expecting_bad_drawable); | |
130 | ||
131 | /* Try a real compositing path */ | |
132 | XRenderComposite(dpy, PictOpOver, src->pict, 0, gradient, | |
133 | 0, 0, 0, 0, 0, 0, win_width, win_height); | |
134 | XSync(dpy, FALSE); | |
135 | if (!got_bad_drawable) { | |
136 | printf("render_to_gradient: Failed to get BadDrawable with " | |
137 | "Over\n"); | |
138 | return FALSE; | |
139 | } else { | |
140 | got_bad_drawable = FALSE; | |
141 | } | |
142 | ||
143 | /* Try the copy path to catch bad short-circuiting to 2d. */ | |
144 | XRenderComposite(dpy, PictOpSrc, src->pict, 0, gradient, | |
145 | 0, 0, 0, 0, 0, 0, win_width, win_height); | |
146 | XSync(dpy, FALSE); | |
147 | if (!got_bad_drawable) { | |
148 | printf("render_to_gradient: Failed to get BadDrawable with " | |
149 | "Src\n"); | |
150 | return FALSE; | |
151 | } else { | |
152 | got_bad_drawable = FALSE; | |
153 | } | |
154 | XSetErrorHandler(NULL); | |
155 | ||
156 | XRenderFreePicture(dpy, gradient); | |
157 | ||
158 | return TRUE; | |
159 | } | |
160 | ||
161 | static void gradientPixel(const stop *stops, double pos, unsigned int spread, color4d *result) | |
162 | { | |
163 | const int PRECISION = 1<<16; | |
164 | int ipos = pos * PRECISION - 1; | |
165 | int i; | |
166 | double frac; | |
167 | ||
168 | /* calculate the actual offset. */ | |
169 | if (ipos < 0 || ipos >= PRECISION) { | |
170 | if (spread == RepeatNormal) { | |
171 | ipos = ipos % PRECISION; | |
172 | ipos = ipos < 0 ? PRECISION + ipos : ipos; | |
173 | ||
174 | } else if (spread == RepeatReflect) { | |
175 | const int limit = PRECISION * 2 - 1; | |
176 | ipos = ipos % limit; | |
177 | ipos = ipos < 0 ? limit + ipos : ipos; | |
178 | ipos = ipos >= PRECISION ? limit - ipos : ipos; | |
179 | ||
180 | } else if (spread == RepeatPad) { | |
181 | if (ipos < 0) | |
182 | ipos = 0; | |
183 | else if (ipos >= PRECISION) | |
184 | ipos = PRECISION-1; | |
185 | } else { /* RepeatNone */ | |
186 | result->r = 0; | |
187 | result->g = 0; | |
188 | result->b = 0; | |
189 | result->a = 0; | |
190 | return; | |
191 | } | |
192 | } | |
193 | ||
194 | assert(ipos >= 0); | |
195 | assert(ipos < PRECISION); | |
196 | ||
197 | pos = ipos/(double)PRECISION; | |
198 | ||
199 | if (pos <= stops[0].x) { | |
200 | *result = stops[0].color; | |
201 | return; | |
202 | } | |
203 | ||
204 | for (i = 0; i < 10; ++i) { | |
205 | if (stops[i].x >= pos) | |
206 | break; | |
207 | if (stops[i].x < 0) { | |
208 | *result = stops[i-1].color; | |
209 | result->r *= result->a; | |
210 | result->g *= result->a; | |
211 | result->b *= result->a; | |
212 | return; | |
213 | } | |
214 | } | |
215 | ||
216 | frac = (pos - stops[i-1].x)/(stops[i].x - stops[i-1].x); | |
217 | ||
218 | result->r = (1.-frac)*stops[i-1].color.r + frac*stops[i].color.r; | |
219 | result->g = (1.-frac)*stops[i-1].color.g + frac*stops[i].color.g; | |
220 | result->b = (1.-frac)*stops[i-1].color.b + frac*stops[i].color.b; | |
221 | result->a = (1.-frac)*stops[i-1].color.a + frac*stops[i].color.a; | |
222 | ||
223 | result->r *= result->a; | |
224 | result->g *= result->a; | |
225 | result->b *= result->a; | |
226 | ||
227 | return; | |
228 | } | |
229 | ||
230 | static void calculate_linear_gradient_color(int x, int y, | |
231 | const point *points, | |
232 | const stop *stops, | |
233 | color4d *tgradient, int repeat) | |
234 | { | |
235 | double dx, dy, l, xrel, yrel, pos; | |
236 | dx = points[1].x - points[0].x; | |
237 | dy = points[1].y - points[0].y; | |
238 | l = dx*dx + dy*dy; | |
239 | ||
240 | xrel = x - points[0].x; | |
241 | yrel = y - points[0].y; | |
242 | ||
243 | pos = (dx*xrel + dy*yrel)/l; | |
244 | gradientPixel(stops, pos, repeat, tgradient); | |
245 | } | |
246 | ||
247 | ||
248 | ||
249 | Bool linear_gradient_test(Display *dpy, picture_info *win, | |
250 | picture_info *dst, int op, picture_info *dst_color) | |
251 | { | |
252 | color4d expected, tested, tdst, tgradient; | |
253 | int i, s, p, repeat; | |
254 | Picture gradient; | |
255 | char testname[40]; | |
256 | Bool success = True; | |
257 | ||
258 | for (s = 0; s < n_stop_list; ++s) { | |
259 | for (p = 0; p < n_linear_gradient_points; p += 2) { | |
260 | XLinearGradient g; | |
261 | XFixed stops[10]; | |
262 | XRenderColor colors[10]; | |
263 | const stop *stps = &stop_list[s][0]; | |
264 | g.p1.x = XDoubleToFixed(linear_gradient_points[p].x); | |
265 | g.p1.y = XDoubleToFixed(linear_gradient_points[p].y); | |
266 | g.p2.x = XDoubleToFixed(linear_gradient_points[p+1].x); | |
267 | g.p2.y = XDoubleToFixed(linear_gradient_points[p+1].y); | |
268 | for (i = 0; i < 10; ++i) { | |
269 | if (stps[i].x < 0) | |
270 | break; | |
271 | stops[i] = XDoubleToFixed(stps[i].x); | |
272 | colors[i].red = stps[i].color.r*65535; | |
273 | colors[i].green = stps[i].color.g*65535; | |
274 | colors[i].blue = stps[i].color.b*65535; | |
275 | colors[i].alpha = stps[i].color.a*65535; | |
276 | } | |
277 | gradient = XRenderCreateLinearGradient(dpy, &g, stops, colors, i); | |
278 | ||
279 | for (repeat = 1; repeat < 4; ++repeat) { | |
280 | const pixel *pix; | |
281 | XRenderPictureAttributes pa; | |
282 | pa.repeat = repeat; | |
283 | XRenderChangePicture(dpy, gradient, CPRepeat, &pa); | |
284 | ||
285 | assert (dst_color->pict > 100); | |
286 | XRenderComposite(dpy, PictOpSrc, dst_color->pict, 0, dst->pict, 0, 0, | |
287 | 0, 0, 0, 0, win_width, win_height); | |
288 | XRenderComposite(dpy, ops[op].op, gradient, 0, | |
289 | dst->pict, 0, 0, 0, 0, 0, 0, win_width, win_height); | |
290 | ||
291 | copy_pict_to_win(dpy, dst, win, win_width, win_height); | |
292 | ||
293 | pix = test_pixels; | |
294 | while (pix->x >= 0) { | |
295 | ||
296 | get_pixel(dpy, dst, pix->x, pix->y, &tested); | |
297 | ||
298 | calculate_linear_gradient_color(pix->x, pix->y, &linear_gradient_points[p], | |
299 | stps, &tgradient, repeat); | |
300 | ||
301 | tdst = dst_color->color; | |
302 | color_correct(dst, &tdst); | |
303 | do_composite(ops[op].op, &tgradient, NULL, &tdst, | |
304 | &expected, False); | |
305 | color_correct(dst, &expected); | |
306 | ||
307 | snprintf(testname, 40, "%s linear gradient", ops[op].name); | |
308 | if (!eval_diff(testname, &expected, &tested, 0, 0, is_verbose)) { | |
309 | printf("gradient: %d stops: %d repeat: %d pos: %d/%d\n" | |
310 | "src color: %.2f %.2f %.2f %.2f\n" | |
311 | "dst color: %.2f %.2f %.2f %.2f\n", | |
312 | p/2, s, | |
313 | repeat, pix->x, pix->y, | |
314 | tgradient.r, tgradient.g, | |
315 | tgradient.b, tgradient.a, | |
316 | dst_color->color.r, dst_color->color.g, | |
317 | dst_color->color.b, dst_color->color.a); | |
318 | success = FALSE; | |
319 | } else if (is_verbose) { | |
320 | printf("src: %d/%d, dst: %s\n", s, p, dst->name); | |
321 | } | |
322 | ++pix; | |
323 | } | |
324 | } | |
325 | XRenderFreePicture(dpy, gradient); | |
326 | } | |
327 | } | |
328 | return success; | |
329 | } | |
330 | ||
331 |
0 | /* | |
1 | * Copyright © 2006 Eric Anholt | |
2 | * | |
3 | * Permission is hereby granted, free of charge, to any person obtaining a | |
4 | * copy of this software and associated documentation files (the "Software"), | |
5 | * to deal in the Software without restriction, including without limitation | |
6 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, | |
7 | * and/or sell copies of the Software, and to permit persons to whom the | |
8 | * Software is furnished to do so, subject to the following conditions: | |
9 | * | |
10 | * The above copyright notice and this permission notice (including the next | |
11 | * paragraph) shall be included in all copies or substantial portions of the | |
12 | * Software. | |
13 | * | |
14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL | |
17 | * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | |
19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | |
20 | * SOFTWARE. | |
21 | * | |
22 | * Authors: | |
23 | * Eric Anholt <anholt@FreeBSD.org> | |
24 | * | |
25 | */ | |
26 | ||
27 | #include <stdio.h> | |
28 | #include <stdlib.h> | |
29 | ||
30 | #include "rendercheck.h" | |
31 | ||
32 | /* We choose some sizes larger than win_width/height because AAs like to turn | |
33 | * off repeating when it's unnecessary and we want to make sure that those paths | |
34 | * are sane. | |
35 | */ | |
36 | static const int sizes[] = {1, 2, 4, 8, 10, 16, 20, 32, 64, 100}; | |
37 | ||
38 | /* Sets up a repeating picture at various sizes, with the upper-left corner | |
39 | * filled with a different color than the rest. It tiles this over the whole | |
40 | * destination, then samples the result to see if it tiled appropriately. If | |
41 | * test_mask is set, the repeating picture is used as a component-alpha mask, | |
42 | * with argb32white as the source. | |
43 | */ | |
44 | Bool | |
45 | repeat_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
46 | picture_info *dst_color, picture_info *c1, picture_info *c2, Bool test_mask) | |
47 | { | |
48 | int wi, hi; | |
49 | Bool failed = FALSE; | |
50 | ||
51 | for (wi = 0; wi < sizeof(sizes) / sizeof(int); wi++) { | |
52 | int w = sizes[wi]; | |
53 | for (hi = 0; hi < sizeof(sizes) / sizeof(int); hi++) { | |
54 | picture_info src; | |
55 | int h = sizes[hi]; | |
56 | int c2w = w / 2; | |
57 | int c2h = h / 2; | |
58 | int x, y, i; | |
59 | char name[40]; | |
60 | color4d tdst, c1expected, c2expected; | |
61 | XRenderPictureAttributes pa; | |
62 | ||
63 | pa.component_alpha = test_mask; | |
64 | pa.repeat = TRUE; | |
65 | ||
66 | src.d = XCreatePixmap(dpy, RootWindow(dpy, 0), w, h, 32); | |
67 | src.format = XRenderFindStandardFormat(dpy, PictStandardARGB32); | |
68 | src.pict = XRenderCreatePicture(dpy, src.d, src.format, | |
69 | CPComponentAlpha | CPRepeat, &pa); | |
70 | src.name = "repeat picture"; | |
71 | ||
72 | /* Fill to the first color */ | |
73 | XRenderComposite(dpy, PictOpSrc, c1->pict, None, src.pict, | |
74 | 0, 0, 0, 0, 0, 0, w, h); | |
75 | /* And set the upper-left to the second color */ | |
76 | XRenderComposite(dpy, PictOpSrc, c2->pict, None, src.pict, | |
77 | 0, 0, 0, 0, 0, 0, c2w, c2h); | |
78 | ||
79 | for (i = 0; i < pixmap_move_iter; i++) { | |
80 | /* Fill to dst_color */ | |
81 | XRenderComposite(dpy, PictOpSrc, dst_color->pict, None, | |
82 | dst->pict, 0, 0, 0, 0, 0, 0, win_width, win_height); | |
83 | /* Composite the repeat picture in. */ | |
84 | if (!test_mask) { | |
85 | XRenderComposite(dpy, ops[op].op, | |
86 | src.pict, None, dst->pict, 0, 0, 0, 0, 0, 0, | |
87 | win_width, win_height); | |
88 | } else { | |
89 | /* Using PictOpSrc, color 0 (white), and | |
90 | * component alpha, the mask color should be | |
91 | * written to the destination. | |
92 | */ | |
93 | XRenderComposite(dpy, ops[op].op, | |
94 | argb32white->pict, src.pict, dst->pict, | |
95 | 0, 0, 0, 0, 0, 0, win_width, win_height); | |
96 | } | |
97 | } | |
98 | ||
99 | copy_pict_to_win(dpy, dst, win, win_width, win_height); | |
100 | tdst = dst_color->color; | |
101 | color_correct(dst, &tdst); | |
102 | ||
103 | if (!test_mask) { | |
104 | do_composite(ops[op].op, &c1->color, NULL, &tdst, | |
105 | &c1expected, FALSE); | |
106 | do_composite(ops[op].op, &c2->color, NULL, &tdst, | |
107 | &c2expected, FALSE); | |
108 | } else { | |
109 | do_composite(ops[op].op, &argb32white->color, | |
110 | &c1->color, &tdst, &c1expected, TRUE); | |
111 | do_composite(ops[op].op, &argb32white->color, | |
112 | &c2->color, &tdst, &c2expected, TRUE); | |
113 | } | |
114 | color_correct(dst, &c1expected); | |
115 | color_correct(dst, &c2expected); | |
116 | ||
117 | snprintf(name, 40, "%dx%d %s %s-repeat", w, h, | |
118 | ops[op].name, test_mask ? "mask" : "src"); | |
119 | for (x = 0; x < win_width; x++) { | |
120 | for (y = 0; y < win_height; y++) { | |
121 | int samplex = x % w; | |
122 | int sampley = y % h; | |
123 | color4d *expected, tested; | |
124 | ||
125 | if (samplex < c2w && sampley < c2h) { | |
126 | expected = &c2expected; | |
127 | } else { | |
128 | expected = &c1expected; | |
129 | } | |
130 | get_pixel(dpy, dst, x, y, &tested); | |
131 | ||
132 | if (!eval_diff(name, expected, &tested, x, y, | |
133 | is_verbose)) | |
134 | failed = TRUE; | |
135 | } | |
136 | } | |
137 | XRenderFreePicture(dpy, src.pict); | |
138 | XFreePixmap(dpy, src.d); | |
139 | } | |
140 | } | |
141 | return !failed; | |
142 | } |
0 | /* | |
1 | * Copyright © 2005 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | #include <stdlib.h> | |
24 | ||
25 | #include "rendercheck.h" | |
26 | ||
27 | /* Originally a bullseye, this pattern has been modified so that flipping | |
28 | * will result in errors as well. | |
29 | */ | |
30 | static int target_colors[5][5] = { | |
31 | {1, 1, 1, 1, 1}, | |
32 | {1, 0, 0, 0, 1}, | |
33 | {1, 1, 1, 0, 1}, | |
34 | {1, 0, 0, 1, 1}, | |
35 | {1, 1, 1, 1, 1}, | |
36 | }; | |
37 | ||
38 | static picture_info *create_target_picture(Display *dpy) | |
39 | { | |
40 | picture_info *p; | |
41 | int i; | |
42 | ||
43 | p = malloc(sizeof(picture_info)); | |
44 | ||
45 | p->d = XCreatePixmap(dpy, RootWindow(dpy, 0), 5, 5, 32); | |
46 | p->format = XRenderFindStandardFormat(dpy, PictStandardARGB32); | |
47 | p->pict = XRenderCreatePicture(dpy, p->d, p->format, 0, NULL); | |
48 | p->name = "target picture"; | |
49 | ||
50 | for (i = 0; i < 25; i++) { | |
51 | int x = i % 5; | |
52 | int y = i / 5; | |
53 | color4d *c = &colors[target_colors[x][y]]; | |
54 | ||
55 | argb_fill(dpy, p, x, y, 1, 1, c->a, c->r, c->g, c->b); | |
56 | } | |
57 | ||
58 | return p; | |
59 | } | |
60 | ||
61 | static void destroy_target_picture(Display *dpy, picture_info *p) | |
62 | { | |
63 | XRenderFreePicture(dpy, p->pict); | |
64 | XFreePixmap(dpy, p->d); | |
65 | free(p); | |
66 | } | |
67 | ||
68 | /* Test source or mask coordinates by drawing from a 5x5 picture into the 0,0 | |
69 | * pixel. | |
70 | * XXX: Something besides PictOpSrc should also be used, at least in the | |
71 | * !test_mask case, to avoid getting CopyArea acceleration (easy to implement) | |
72 | * rather than a more general Composite implementation. | |
73 | */ | |
74 | Bool | |
75 | srccoords_test(Display *dpy, picture_info *win, picture_info *white, | |
76 | Bool test_mask) | |
77 | { | |
78 | color4d expected, tested; | |
79 | int i; | |
80 | XRenderPictureAttributes pa; | |
81 | Bool failed = FALSE; | |
82 | int tested_colors[5][5]; | |
83 | picture_info *src; | |
84 | ||
85 | src = create_target_picture(dpy); | |
86 | if (src == NULL) { | |
87 | fprintf(stderr, "couldn't allocate picture for test\n"); | |
88 | return FALSE; | |
89 | } | |
90 | ||
91 | for (i = 0; i < 25; i++) { | |
92 | char name[20]; | |
93 | int x = i % 5, y = i / 5; | |
94 | ||
95 | if (!test_mask) | |
96 | XRenderComposite(dpy, PictOpSrc, src->pict, 0, | |
97 | win->pict, x, y, 0, 0, 0, 0, 1, 1); | |
98 | else { | |
99 | /* Using PictOpSrc, color 0 (white), and component | |
100 | * alpha, the mask color should be written to the | |
101 | * destination. | |
102 | */ | |
103 | pa.component_alpha = TRUE; | |
104 | XRenderChangePicture(dpy, src->pict, CPComponentAlpha, | |
105 | &pa); | |
106 | XRenderComposite(dpy, PictOpSrc, white->pict, src->pict, | |
107 | win->pict, 0, 0, x, y, 0, 0, 1, 1); | |
108 | pa.component_alpha = FALSE; | |
109 | XRenderChangePicture(dpy, src->pict, CPComponentAlpha, | |
110 | &pa); | |
111 | } | |
112 | get_pixel(dpy, win, 0, 0, &tested); | |
113 | ||
114 | expected = colors[target_colors[x][y]]; | |
115 | color_correct(win, &expected); | |
116 | if (tested.r == 1.0) { | |
117 | if (tested.g == 1.0 && tested.b == 1.0) | |
118 | tested_colors[x][y] = 0; | |
119 | else if (tested.g == 0.0 && tested.b == 0.0) | |
120 | tested_colors[x][y] = 1; | |
121 | else tested_colors[x][y] = 9; | |
122 | } else | |
123 | tested_colors[x][y] = 9; | |
124 | ||
125 | if (test_mask) | |
126 | snprintf(name, 20, "mask coords"); | |
127 | else | |
128 | snprintf(name, 20, "src coords"); | |
129 | if (!eval_diff(name, &expected, &tested, x, y, | |
130 | is_verbose)) | |
131 | failed = TRUE; | |
132 | } | |
133 | if (failed) { | |
134 | int j; | |
135 | ||
136 | printf("expected vs tested:\n"); | |
137 | for (i = 0; i < 5; i++) { | |
138 | for (j = 0; j < 5; j++) | |
139 | printf("%d", target_colors[j][i]); | |
140 | printf(" "); | |
141 | for (j = 0; j < 5; j++) | |
142 | printf("%d", tested_colors[j][i]); | |
143 | printf("\n"); | |
144 | } | |
145 | } | |
146 | ||
147 | destroy_target_picture(dpy, src); | |
148 | ||
149 | return !failed; | |
150 | } |
0 | /* | |
1 | * Copyright © 2006 Eric Anholt | |
2 | * | |
3 | * Permission is hereby granted, free of charge, to any person obtaining a | |
4 | * copy of this software and associated documentation files (the "Software"), | |
5 | * to deal in the Software without restriction, including without limitation | |
6 | * the rights to use, copy, modify, merge, publish, distribute, sublicense, | |
7 | * and/or sell copies of the Software, and to permit persons to whom the | |
8 | * Software is furnished to do so, subject to the following conditions: | |
9 | * | |
10 | * The above copyright notice and this permission notice (including the next | |
11 | * paragraph) shall be included in all copies or substantial portions of the | |
12 | * Software. | |
13 | * | |
14 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR | |
15 | * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, | |
16 | * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL | |
17 | * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER | |
18 | * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, | |
19 | * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | |
20 | * SOFTWARE. | |
21 | * | |
22 | * Authors: | |
23 | * Eric Anholt <anholt@FreeBSD.org> | |
24 | * | |
25 | */ | |
26 | ||
27 | #include <stdio.h> | |
28 | ||
29 | #include "rendercheck.h" | |
30 | ||
31 | #define TEST_WIDTH 10 | |
32 | #define TEST_HEIGHT 10 | |
33 | ||
34 | /* Test basic functionality of the triangle operations. We don't care that much | |
35 | * probably (nobody has used them yet), but we can trivially test by filling | |
36 | * doing two triangles that will exactly cover the rectangle from 2,2 to 4,4. | |
37 | */ | |
38 | Bool | |
39 | triangles_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
40 | picture_info *src_color, picture_info *dst_color) | |
41 | { | |
42 | XTriangle triangles[2]; | |
43 | color4d tdst, tsrc; | |
44 | int x, y; | |
45 | Bool success = TRUE; | |
46 | ||
47 | triangles[0].p1.x = XDoubleToFixed(2); | |
48 | triangles[0].p1.y = XDoubleToFixed(2); | |
49 | triangles[0].p2.x = XDoubleToFixed(4); | |
50 | triangles[0].p2.y = XDoubleToFixed(2); | |
51 | triangles[0].p3.x = XDoubleToFixed(4); | |
52 | triangles[0].p3.y = XDoubleToFixed(4); | |
53 | ||
54 | triangles[1].p1.x = XDoubleToFixed(2); | |
55 | triangles[1].p1.y = XDoubleToFixed(2); | |
56 | triangles[1].p2.x = XDoubleToFixed(2); | |
57 | triangles[1].p2.y = XDoubleToFixed(4); | |
58 | triangles[1].p3.x = XDoubleToFixed(4); | |
59 | triangles[1].p3.y = XDoubleToFixed(4); | |
60 | ||
61 | /* Fill the dst to dst_color */ | |
62 | XRenderComposite(dpy, PictOpSrc, dst_color->pict, None, dst->pict, 0, 0, | |
63 | 0, 0, 0, 0, TEST_WIDTH, TEST_HEIGHT); | |
64 | /* Paint the triangles with src_color */ | |
65 | XRenderCompositeTriangles(dpy, ops[op].op, src_color->pict, dst->pict, | |
66 | XRenderFindStandardFormat(dpy, PictStandardA8), 0, 0, triangles, 2); | |
67 | ||
68 | copy_pict_to_win(dpy, dst, win, TEST_WIDTH, TEST_HEIGHT); | |
69 | ||
70 | /* Color expected outside of the triangles */ | |
71 | tdst = dst_color->color; | |
72 | color_correct(dst, &tdst); | |
73 | ||
74 | /* Color expected inside of the triangles */ | |
75 | do_composite(ops[op].op, &src_color->color, NULL, &tdst, &tsrc, FALSE); | |
76 | color_correct(dst, &tsrc); | |
77 | ||
78 | for (x = 0; x < 5; x++) { | |
79 | for (y = 0; y < 5; y++) { | |
80 | color4d expected, tested; | |
81 | ||
82 | if (x >= 2 && x < 4 && y >= 2 && y < 4) { | |
83 | expected = tsrc; | |
84 | } else { | |
85 | expected = tdst; | |
86 | } | |
87 | ||
88 | get_pixel(dpy, dst, x, y, &tested); | |
89 | ||
90 | if (!eval_diff("triangles", &expected, &tested, x, y, | |
91 | is_verbose)) | |
92 | { | |
93 | success = FALSE; | |
94 | } | |
95 | } | |
96 | } | |
97 | if (!success) { | |
98 | printf("src color: %.2f %.2f %.2f %.2f\n" | |
99 | "dst color: %.2f %.2f %.2f %.2f\n", | |
100 | src_color->color.r, src_color->color.g, | |
101 | src_color->color.b, src_color->color.a, | |
102 | dst_color->color.r, dst_color->color.g, | |
103 | dst_color->color.b, dst_color->color.a); | |
104 | } | |
105 | ||
106 | return success; | |
107 | } | |
108 | ||
109 | Bool | |
110 | trifan_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
111 | picture_info *src_color, picture_info *dst_color) | |
112 | { | |
113 | XPointFixed points[4]; | |
114 | color4d tdst, tsrc; | |
115 | int x, y; | |
116 | Bool success = TRUE; | |
117 | ||
118 | points[0].x = XDoubleToFixed(2); | |
119 | points[0].y = XDoubleToFixed(2); | |
120 | points[1].x = XDoubleToFixed(4); | |
121 | points[1].y = XDoubleToFixed(2); | |
122 | points[2].x = XDoubleToFixed(4); | |
123 | points[2].y = XDoubleToFixed(4); | |
124 | points[3].x = XDoubleToFixed(2); | |
125 | points[3].y = XDoubleToFixed(4); | |
126 | ||
127 | /* Fill the dst to dst_color */ | |
128 | XRenderComposite(dpy, PictOpSrc, dst_color->pict, None, dst->pict, 0, 0, | |
129 | 0, 0, 0, 0, TEST_WIDTH, TEST_HEIGHT); | |
130 | /* Paint the triangles with src_color */ | |
131 | XRenderCompositeTriFan(dpy, ops[op].op, src_color->pict, dst->pict, | |
132 | XRenderFindStandardFormat(dpy, PictStandardA8), 0, 0, points, 4); | |
133 | ||
134 | copy_pict_to_win(dpy, dst, win, TEST_WIDTH, TEST_HEIGHT); | |
135 | ||
136 | /* Color expected outside of the triangles */ | |
137 | tdst = dst_color->color; | |
138 | color_correct(dst, &tdst); | |
139 | ||
140 | /* Color expected inside of the triangles */ | |
141 | do_composite(ops[op].op, &src_color->color, NULL, &tdst, &tsrc, FALSE); | |
142 | color_correct(dst, &tsrc); | |
143 | ||
144 | for (x = 0; x < 5; x++) { | |
145 | for (y = 0; y < 5; y++) { | |
146 | color4d expected, tested; | |
147 | ||
148 | if (x >= 2 && x < 4 && y >= 2 && y < 4) { | |
149 | expected = tsrc; | |
150 | } else { | |
151 | expected = tdst; | |
152 | } | |
153 | ||
154 | get_pixel(dpy, dst, x, y, &tested); | |
155 | ||
156 | if (!eval_diff("triangles", &expected, &tested, x, y, | |
157 | is_verbose)) | |
158 | { | |
159 | success = FALSE; | |
160 | } | |
161 | } | |
162 | } | |
163 | if (!success) { | |
164 | printf("src color: %.2f %.2f %.2f %.2f\n" | |
165 | "dst color: %.2f %.2f %.2f %.2f\n", | |
166 | src_color->color.r, src_color->color.g, | |
167 | src_color->color.b, src_color->color.a, | |
168 | dst_color->color.r, dst_color->color.g, | |
169 | dst_color->color.b, dst_color->color.a); | |
170 | } | |
171 | ||
172 | return success; | |
173 | } | |
174 | ||
175 | Bool | |
176 | tristrip_test(Display *dpy, picture_info *win, picture_info *dst, int op, | |
177 | picture_info *src_color, picture_info *dst_color) | |
178 | { | |
179 | XPointFixed points[4]; | |
180 | color4d tdst, tsrc; | |
181 | int x, y; | |
182 | Bool success = TRUE; | |
183 | ||
184 | points[0].x = XDoubleToFixed(2); | |
185 | points[0].y = XDoubleToFixed(2); | |
186 | points[1].x = XDoubleToFixed(4); | |
187 | points[1].y = XDoubleToFixed(2); | |
188 | points[2].x = XDoubleToFixed(2); | |
189 | points[2].y = XDoubleToFixed(4); | |
190 | points[3].x = XDoubleToFixed(4); | |
191 | points[3].y = XDoubleToFixed(4); | |
192 | ||
193 | /* Fill the dst to dst_color */ | |
194 | XRenderComposite(dpy, PictOpSrc, dst_color->pict, None, dst->pict, 0, 0, | |
195 | 0, 0, 0, 0, TEST_WIDTH, TEST_HEIGHT); | |
196 | /* Paint the triangles with src_color */ | |
197 | XRenderCompositeTriStrip(dpy, ops[op].op, src_color->pict, dst->pict, | |
198 | XRenderFindStandardFormat(dpy, PictStandardA8), 0, 0, points, 4); | |
199 | ||
200 | copy_pict_to_win(dpy, dst, win, TEST_WIDTH, TEST_HEIGHT); | |
201 | ||
202 | /* Color expected outside of the triangles */ | |
203 | tdst = dst_color->color; | |
204 | color_correct(dst, &tdst); | |
205 | ||
206 | /* Color expected inside of the triangles */ | |
207 | do_composite(ops[op].op, &src_color->color, NULL, &tdst, &tsrc, FALSE); | |
208 | color_correct(dst, &tsrc); | |
209 | ||
210 | for (x = 0; x < 5; x++) { | |
211 | for (y = 0; y < 5; y++) { | |
212 | color4d expected, tested; | |
213 | ||
214 | if (x >= 2 && x < 4 && y >= 2 && y < 4) { | |
215 | expected = tsrc; | |
216 | } else { | |
217 | expected = tdst; | |
218 | } | |
219 | ||
220 | get_pixel(dpy, dst, x, y, &tested); | |
221 | ||
222 | if (!eval_diff("triangles", &expected, &tested, x, y, | |
223 | is_verbose)) | |
224 | { | |
225 | success = FALSE; | |
226 | } | |
227 | } | |
228 | } | |
229 | if (!success) { | |
230 | printf("src color: %.2f %.2f %.2f %.2f\n" | |
231 | "dst color: %.2f %.2f %.2f %.2f\n", | |
232 | src_color->color.r, src_color->color.g, | |
233 | src_color->color.b, src_color->color.a, | |
234 | dst_color->color.r, dst_color->color.g, | |
235 | dst_color->color.b, dst_color->color.a); | |
236 | } | |
237 | ||
238 | return success; | |
239 | } |
0 | /* | |
1 | * Copyright © 2005 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | #include <stdlib.h> | |
24 | ||
25 | #include "rendercheck.h" | |
26 | ||
27 | static int dot_colors[5][5] = { | |
28 | {7, 7, 7, 7, 7}, | |
29 | {7, 7, 7, 7, 7}, | |
30 | {7, 0, 7, 7, 7}, | |
31 | {7, 7, 7, 7, 7}, | |
32 | {7, 7, 7, 7, 7}, | |
33 | }; | |
34 | ||
35 | static picture_info *create_dot_picture(Display *dpy) | |
36 | { | |
37 | picture_info *p; | |
38 | int i; | |
39 | ||
40 | p = malloc(sizeof(picture_info)); | |
41 | ||
42 | p->d = XCreatePixmap(dpy, RootWindow(dpy, 0), 5, 5, 32); | |
43 | p->format = XRenderFindStandardFormat(dpy, PictStandardARGB32); | |
44 | p->pict = XRenderCreatePicture(dpy, p->d, p->format, 0, NULL); | |
45 | p->name = "dot picture"; | |
46 | ||
47 | for (i = 0; i < 25; i++) { | |
48 | int x = i % 5; | |
49 | int y = i / 5; | |
50 | color4d *c = &colors[dot_colors[x][y]]; | |
51 | ||
52 | argb_fill(dpy, p, x, y, 1, 1, c->a, c->r, c->g, c->b); | |
53 | } | |
54 | ||
55 | return p; | |
56 | } | |
57 | ||
58 | static void destroy_dot_picture(Display *dpy, picture_info *p) | |
59 | { | |
60 | XRenderFreePicture(dpy, p->pict); | |
61 | XFreePixmap(dpy, p->d); | |
62 | free(p); | |
63 | } | |
64 | ||
65 | static void init_transform (XTransform *t) | |
66 | { | |
67 | int i, j; | |
68 | ||
69 | for (i = 0; i < 3; i++) | |
70 | for (j = 0; j < 3; j++) | |
71 | t->matrix[i][j] = XDoubleToFixed((i == j) ? 1 : 0); | |
72 | } | |
73 | ||
74 | /* Test drawing a 5x5 source image scaled 8x, as either a source or mask. | |
75 | */ | |
76 | Bool | |
77 | trans_coords_test(Display *dpy, picture_info *win, picture_info *white, | |
78 | Bool test_mask) | |
79 | { | |
80 | color4d tested; | |
81 | int x, y; | |
82 | Bool failed = FALSE; | |
83 | int tested_colors[40][40], expected_colors[40][40]; | |
84 | XTransform t; | |
85 | picture_info *src; | |
86 | ||
87 | src = create_dot_picture(dpy); | |
88 | if (src == NULL) { | |
89 | fprintf(stderr, "couldn't allocate picture for test\n"); | |
90 | return FALSE; | |
91 | } | |
92 | ||
93 | init_transform(&t); | |
94 | t.matrix[2][2] = XDoubleToFixed(8); | |
95 | ||
96 | XRenderSetPictureTransform(dpy, src->pict, &t); | |
97 | ||
98 | if (!test_mask) | |
99 | XRenderComposite(dpy, PictOpSrc, src->pict, 0, | |
100 | win->pict, 0, 0, 0, 0, 0, 0, 40, 40); | |
101 | else { | |
102 | XRenderComposite(dpy, PictOpSrc, white->pict, src->pict, | |
103 | win->pict, 0, 0, 0, 0, 0, 0, 40, 40); | |
104 | } | |
105 | ||
106 | for (x = 0; x < 40; x++) { | |
107 | for (y = 0; y < 40; y++) { | |
108 | int src_sample_x, src_sample_y; | |
109 | ||
110 | src_sample_x = x / 8; | |
111 | src_sample_y = y / 8; | |
112 | expected_colors[x][y] = dot_colors[src_sample_x][src_sample_y]; | |
113 | ||
114 | get_pixel(dpy, win, x, y, &tested); | |
115 | ||
116 | if (tested.r == 1.0 && tested.g == 1.0 && tested.b == 1.0) { | |
117 | tested_colors[x][y] = 0; | |
118 | } else if (tested.r == 0.0 && tested.g == 0.0 && | |
119 | tested.b == 0.0) { | |
120 | tested_colors[x][y] = 7; | |
121 | } else { | |
122 | tested_colors[x][y] = 9; | |
123 | } | |
124 | if (tested_colors[x][y] != expected_colors[x][y]) | |
125 | failed = TRUE; | |
126 | } | |
127 | } | |
128 | ||
129 | if (failed) { | |
130 | printf("%s transform coordinates test failed.\n", | |
131 | test_mask ? "mask" : "src"); | |
132 | printf("expected vs tested:\n"); | |
133 | for (y = 0; y < 40; y++) { | |
134 | for (x = 0; x < 40; x++) | |
135 | printf("%d", expected_colors[x][y]); | |
136 | printf(" "); | |
137 | for (x = 0; x < 40; x++) | |
138 | printf("%d", tested_colors[x][y]); | |
139 | printf("\n"); | |
140 | } | |
141 | printf(" vs tested (same)\n"); | |
142 | for (y = 0; y < 40; y++) { | |
143 | for (x = 0; x < 40; x++) | |
144 | printf("%d", tested_colors[x][y]); | |
145 | printf("\n"); | |
146 | } | |
147 | } | |
148 | ||
149 | init_transform(&t); | |
150 | ||
151 | XRenderSetPictureTransform(dpy, src->pict, &t); | |
152 | ||
153 | destroy_dot_picture(dpy, src); | |
154 | ||
155 | return !failed; | |
156 | } |
0 | /* | |
1 | * Copyright © 2007 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | #include <stdlib.h> | |
24 | ||
25 | #include "rendercheck.h" | |
26 | ||
27 | /* Originally a bullseye, this pattern has been modified so that flipping | |
28 | * will result in errors as well. | |
29 | */ | |
30 | static int target_colors[5][5] = { | |
31 | {1, 1, 1, 1, 1}, | |
32 | {1, 0, 0, 0, 1}, | |
33 | {1, 1, 1, 0, 1}, | |
34 | {1, 0, 0, 1, 1}, | |
35 | {1, 1, 1, 1, 1}, | |
36 | }; | |
37 | ||
38 | static picture_info *create_target_picture(Display *dpy) | |
39 | { | |
40 | picture_info *p; | |
41 | int i; | |
42 | ||
43 | p = malloc(sizeof(picture_info)); | |
44 | ||
45 | p->d = XCreatePixmap(dpy, RootWindow(dpy, 0), 5, 5, 32); | |
46 | p->format = XRenderFindStandardFormat(dpy, PictStandardARGB32); | |
47 | p->pict = XRenderCreatePicture(dpy, p->d, p->format, 0, NULL); | |
48 | p->name = "target picture"; | |
49 | ||
50 | for (i = 0; i < 25; i++) { | |
51 | int x = i % 5; | |
52 | int y = i / 5; | |
53 | color4d *c = &colors[target_colors[y][x]]; | |
54 | ||
55 | argb_fill(dpy, p, x, y, 1, 1, c->a, c->r, c->g, c->b); | |
56 | } | |
57 | ||
58 | return p; | |
59 | } | |
60 | ||
61 | static void destroy_target_picture(Display *dpy, picture_info *p) | |
62 | { | |
63 | XRenderFreePicture(dpy, p->pict); | |
64 | XFreePixmap(dpy, p->d); | |
65 | free(p); | |
66 | } | |
67 | ||
68 | ||
69 | /* Test source or mask coordinates by drawing from a 5x5 picture into the 0,0 | |
70 | * pixel, rotated 90 degrees to the left. | |
71 | */ | |
72 | Bool | |
73 | trans_srccoords_test_2(Display *dpy, picture_info *win, picture_info *white, | |
74 | Bool test_mask) | |
75 | { | |
76 | color4d expected, tested; | |
77 | int i; | |
78 | XRenderPictureAttributes pa; | |
79 | Bool failed = FALSE; | |
80 | int tested_colors[5][5]; | |
81 | picture_info *src; | |
82 | XTransform t; | |
83 | ||
84 | src = create_target_picture(dpy); | |
85 | if (src == NULL) { | |
86 | fprintf(stderr, "couldn't allocate picture for test\n"); | |
87 | return FALSE; | |
88 | } | |
89 | ||
90 | /* Transform that rotates right from the destination coords to the | |
91 | * src coords. | |
92 | */ | |
93 | t.matrix[0][0] = XDoubleToFixed(0); | |
94 | t.matrix[0][1] = XDoubleToFixed(-1); | |
95 | t.matrix[0][2] = XDoubleToFixed(5); | |
96 | t.matrix[1][0] = XDoubleToFixed(1); | |
97 | t.matrix[1][1] = XDoubleToFixed(0); | |
98 | t.matrix[1][2] = XDoubleToFixed(0); | |
99 | t.matrix[2][0] = XDoubleToFixed(0); | |
100 | t.matrix[2][1] = XDoubleToFixed(0); | |
101 | t.matrix[2][2] = XDoubleToFixed(1); | |
102 | XRenderSetPictureTransform(dpy, src->pict, &t); | |
103 | ||
104 | if (!test_mask) { | |
105 | XRenderComposite(dpy, PictOpSrc, src->pict, 0, | |
106 | win->pict, 0, 0, 0, 0, 0, 0, 5, 5); | |
107 | } else { | |
108 | /* Using PictOpSrc, color 0 (white), and component | |
109 | * alpha, the mask color should be written to the | |
110 | * destination. | |
111 | */ | |
112 | pa.component_alpha = TRUE; | |
113 | XRenderChangePicture(dpy, src->pict, CPComponentAlpha, | |
114 | &pa); | |
115 | XRenderComposite(dpy, PictOpSrc, white->pict, src->pict, | |
116 | win->pict, 0, 0, 0, 0, 0, 0, 5, 5); | |
117 | pa.component_alpha = FALSE; | |
118 | XRenderChangePicture(dpy, src->pict, CPComponentAlpha, | |
119 | &pa); | |
120 | } | |
121 | ||
122 | for (i = 0; i < 25; i++) { | |
123 | char name[20]; | |
124 | int x = i % 5, y = i / 5, srcx, srcy; | |
125 | ||
126 | get_pixel(dpy, win, x, y, &tested); | |
127 | ||
128 | /* Map from our destination coordinates to where they are | |
129 | * in the source picture. Rotate right. | |
130 | */ | |
131 | srcx = 4 - y; | |
132 | srcy = x; | |
133 | expected = colors[target_colors[srcy][srcx]]; | |
134 | color_correct(win, &expected); | |
135 | if (tested.r == 1.0) { | |
136 | if (tested.g == 1.0 && tested.b == 1.0) | |
137 | tested_colors[y][x] = 0; | |
138 | else if (tested.g == 0.0 && tested.b == 0.0) | |
139 | tested_colors[y][x] = 1; | |
140 | else tested_colors[y][x] = 9; | |
141 | } else | |
142 | tested_colors[y][x] = 9; | |
143 | ||
144 | if (test_mask) | |
145 | snprintf(name, 20, "mask coords"); | |
146 | else | |
147 | snprintf(name, 20, "src coords"); | |
148 | if (!eval_diff(name, &expected, &tested, x, y, is_verbose)) | |
149 | failed = TRUE; | |
150 | } | |
151 | if (failed) { | |
152 | int x, y; | |
153 | ||
154 | printf("expected vs tested:\n"); | |
155 | for (y = 0; y < 5; y++) { | |
156 | for (x = 0; x < 5; x++) { | |
157 | int srcx = 4 - y; | |
158 | int srcy = x; | |
159 | ||
160 | printf("%d", target_colors[srcy][srcx]); | |
161 | } | |
162 | printf(" "); | |
163 | for (x = 0; x < 5; x++) | |
164 | printf("%d", tested_colors[y][x]); | |
165 | printf("\n"); | |
166 | } | |
167 | } | |
168 | ||
169 | destroy_target_picture(dpy, src); | |
170 | ||
171 | return !failed; | |
172 | } |
0 | /* | |
1 | * Copyright © 2004 Eric Anholt | |
2 | * | |
3 | * Permission to use, copy, modify, distribute, and sell this software and its | |
4 | * documentation for any purpose is hereby granted without fee, provided that | |
5 | * the above copyright notice appear in all copies and that both that | |
6 | * copyright notice and this permission notice appear in supporting | |
7 | * documentation, and that the name of Eric Anholt not be used in | |
8 | * advertising or publicity pertaining to distribution of the software without | |
9 | * specific, written prior permission. Eric Anholt makes no | |
10 | * representations about the suitability of this software for any purpose. It | |
11 | * is provided "as is" without express or implied warranty. | |
12 | * | |
13 | * ERIC ANHOLT DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, | |
14 | * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO | |
15 | * EVENT SHALL ERIC ANHOLT BE LIABLE FOR ANY SPECIAL, INDIRECT OR | |
16 | * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, | |
17 | * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER | |
18 | * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR | |
19 | * PERFORMANCE OF THIS SOFTWARE. | |
20 | */ | |
21 | ||
22 | #include <stdio.h> | |
23 | #include <stdlib.h> | |
24 | #include <string.h> | |
25 | #include <math.h> | |
26 | ||
27 | #include "rendercheck.h" | |
28 | ||
29 | static XRenderPictFormat **format_list; | |
30 | static int nformats; | |
31 | static int argb32index; | |
32 | ||
33 | /* Note: changing the order of these colors may disrupt tests that depend on | |
34 | * specific colors. Just add to the end if you need. These are | |
35 | * not premultiplied, but will be in main(). | |
36 | */ | |
37 | color4d colors[] = { | |
38 | {1.0, 1.0, 1.0, 1.0}, | |
39 | {1.0, 0, 0, 1.0}, | |
40 | {0, 1.0, 0, 1.0}, | |
41 | {0, 0, 1.0, 1.0}, | |
42 | {0.5, 0, 0, .5}, | |
43 | }; | |
44 | ||
45 | /* Convenience pointers to 1x1 repeating colors */ | |
46 | picture_info *argb32white, *argb32red, *argb32green, *argb32blue; | |
47 | ||
48 | int num_colors = sizeof(colors) / sizeof(colors[0]); | |
49 | ||
50 | struct op_info ops[] = { | |
51 | {PictOpClear, "Clear"}, | |
52 | {PictOpSrc, "Src"}, | |
53 | {PictOpDst, "Dst"}, | |
54 | {PictOpOver, "Over"}, | |
55 | {PictOpOverReverse, "OverReverse"}, | |
56 | {PictOpIn, "In"}, | |
57 | {PictOpInReverse, "InReverse"}, | |
58 | {PictOpOut, "Out"}, | |
59 | {PictOpOutReverse, "OutReverse"}, | |
60 | {PictOpAtop, "Atop"}, | |
61 | {PictOpAtopReverse, "AtopReverse"}, | |
62 | {PictOpXor, "Xor"}, | |
63 | {PictOpAdd, "Add"}, | |
64 | {PictOpSaturate, "Saturate"}, | |
65 | {PictOpDisjointClear, "DisjointClear"}, | |
66 | {PictOpDisjointSrc, "DisjointSrc"}, | |
67 | {PictOpDisjointDst, "DisjointDst"}, | |
68 | {PictOpDisjointOver, "DisjointOver"}, | |
69 | {PictOpDisjointOverReverse, "DisjointOverReverse"}, | |
70 | {PictOpDisjointIn, "DisjointIn"}, | |
71 | {PictOpDisjointInReverse, "DisjointInReverse"}, | |
72 | {PictOpDisjointOut, "DisjointOut"}, | |
73 | {PictOpDisjointOutReverse, "DisjointOutReverse"}, | |
74 | {PictOpDisjointAtop, "DisjointAtop"}, | |
75 | {PictOpDisjointAtopReverse, "DisjointAtopReverse"}, | |
76 | {PictOpDisjointXor, "DisjointXor"}, | |
77 | {PictOpConjointClear, "ConjointClear"}, | |
78 | {PictOpConjointSrc, "ConjointSrc"}, | |
79 | {PictOpConjointDst, "ConjointDst"}, | |
80 | {PictOpConjointOver, "ConjointOver"}, | |
81 | {PictOpConjointOverReverse, "ConjointOverReverse"}, | |
82 | {PictOpConjointIn, "ConjointIn"}, | |
83 | {PictOpConjointInReverse, "ConjointInReverse"}, | |
84 | {PictOpConjointOut, "ConjointOut"}, | |
85 | {PictOpConjointOutReverse, "ConjointOutReverse"}, | |
86 | {PictOpConjointAtop, "ConjointAtop"}, | |
87 | {PictOpConjointAtopReverse, "ConjointAtopReverse"}, | |
88 | {PictOpConjointXor, "ConjointXor"}, | |
89 | }; | |
90 | ||
91 | int num_ops = sizeof(ops) / sizeof(ops[0]); | |
92 | ||
93 | #define round_pix(pix, mask) \ | |
94 | ((double)((int)(pix * (mask ) + .5)) / (double)(mask)) | |
95 | ||
96 | void | |
97 | color_correct(picture_info *pi, color4d *color) | |
98 | { | |
99 | if (!pi->format->direct.redMask) { | |
100 | color->r = 0.0; | |
101 | color->g = 0.0; | |
102 | color->b = 0.0; | |
103 | } else { | |
104 | color->r = round_pix(color->r, pi->format->direct.redMask); | |
105 | color->g = round_pix(color->g, pi->format->direct.greenMask); | |
106 | color->b = round_pix(color->b, pi->format->direct.blueMask); | |
107 | } | |
108 | if (!pi->format->direct.alphaMask) | |
109 | color->a = 1.0; | |
110 | else | |
111 | color->a = round_pix(color->a, pi->format->direct.alphaMask); | |
112 | } | |
113 | ||
114 | void | |
115 | get_pixel(Display *dpy, picture_info *pi, int x, int y, color4d *color) | |
116 | { | |
117 | XImage *image; | |
118 | unsigned long val; | |
119 | unsigned long rm, gm, bm, am; | |
120 | XRenderDirectFormat *layout = &pi->format->direct; | |
121 | ||
122 | image = XGetImage(dpy, pi->d, x, y, 1, 1, 0xffffffff, ZPixmap); | |
123 | ||
124 | val = XGetPixel(image, 0, 0); | |
125 | ||
126 | rm = (unsigned long)layout->redMask << layout->red; | |
127 | gm = (unsigned long)layout->greenMask << layout->green; | |
128 | bm = (unsigned long)layout->blueMask << layout->blue; | |
129 | am = (unsigned long)layout->alphaMask << layout->alpha; | |
130 | if (am != 0) | |
131 | color->a = (double)(val & am) / (double)am; | |
132 | else | |
133 | color->a = 1.0; | |
134 | if (rm != 0) { | |
135 | color->r = (double)(val & rm) / (double)rm; | |
136 | color->g = (double)(val & gm) / (double)gm; | |
137 | color->b = (double)(val & bm) / (double)bm; | |
138 | } else { | |
139 | color->r = 0.0; | |
140 | color->g = 0.0; | |
141 | color->b = 0.0; | |
142 | } | |
143 | XDestroyImage(image); | |
144 | } | |
145 | ||
146 | int | |
147 | eval_diff(char *name, color4d *expected, color4d *test, int x, int y, | |
148 | Bool verbose) | |
149 | { | |
150 | double rscale, gscale, bscale, ascale; | |
151 | double rdiff, gdiff, bdiff, adiff, diff; | |
152 | ||
153 | /* XXX: Need to be provided mask shifts so we can produce useful error | |
154 | * values. | |
155 | */ | |
156 | rscale = 1.0 * (1 << 5); | |
157 | gscale = 1.0 * (1 << 6); | |
158 | bscale = 1.0 * (1 << 5); | |
159 | ascale = 1.0 * 32; | |
160 | rdiff = fabs(test->r - expected->r) * rscale; | |
161 | bdiff = fabs(test->g - expected->g) * gscale; | |
162 | gdiff = fabs(test->b - expected->b) * bscale; | |
163 | adiff = fabs(test->a - expected->a) * ascale; | |
164 | /*rdiff = log2(1.0 + rdiff); | |
165 | gdiff = log2(1.0 + gdiff); | |
166 | bdiff = log2(1.0 + bdiff); | |
167 | adiff = log2(1.0 + adiff);*/ | |
168 | diff = max(max(max(rdiff, gdiff), bdiff), adiff); | |
169 | if (diff > 3.0) { | |
170 | printf("%s test error of %.4f at (%d, %d) --\n" | |
171 | " R G B A\n" | |
172 | "got: %.2f %.2f %.2f %.2f\n" | |
173 | "expected: %.2f %.2f %.2f %.2f\n", name, diff, x, y, | |
174 | test->r, test->g, test->b, test->a, | |
175 | expected->r, expected->g, expected->b, expected->a); | |
176 | return FALSE; | |
177 | } else if (verbose) { | |
178 | printf("%s test succeeded at (%d, %d) with %.4f: " | |
179 | "%.2f %.2f %.2f %.2f\n", name, x, y, diff, | |
180 | expected->r, expected->g, expected->b, expected->a); | |
181 | } | |
182 | return TRUE; | |
183 | } | |
184 | ||
185 | void | |
186 | argb_fill(Display *dpy, picture_info *p, int x, int y, int w, int h, float a, | |
187 | float r, float g, float b) | |
188 | { | |
189 | XRenderColor rendercolor; | |
190 | ||
191 | rendercolor.red = r * 65535; | |
192 | rendercolor.green = g * 65535; | |
193 | rendercolor.blue = b * 65535; | |
194 | rendercolor.alpha = a * 65535; | |
195 | ||
196 | XRenderFillRectangle(dpy, PictOpSrc, p->pict, &rendercolor, x, y, w, h); | |
197 | } | |
198 | ||
199 | #define ARRAY_SIZE(x) (sizeof(x) / sizeof((x)[0])) | |
200 | ||
201 | /* Create a set of direct format XRenderPictFormats for later use. This lets | |
202 | * us get more formats than just the standard required set, and lets us attach | |
203 | * names to them. | |
204 | */ | |
205 | static void | |
206 | create_formats_list(Display *dpy) | |
207 | { | |
208 | int i; | |
209 | int nformats_allocated = 5; | |
210 | XRenderPictFormat templ; | |
211 | ||
212 | memset(&templ, 0, sizeof(templ)); | |
213 | templ.type = PictTypeDirect; | |
214 | ||
215 | format_list = malloc(sizeof(XRenderPictFormat *) * nformats_allocated); | |
216 | if (format_list == NULL) | |
217 | errx(1, "malloc error"); | |
218 | nformats = 0; | |
219 | ||
220 | argb32index = -1; | |
221 | for (i = 0; ; i++) { | |
222 | char name[20]; | |
223 | int alphabits, redbits; | |
224 | ||
225 | if (nformats + 1 == nformats_allocated) { | |
226 | nformats_allocated *= 2; | |
227 | format_list = realloc(format_list, sizeof(XRenderPictFormat *) * | |
228 | nformats_allocated); | |
229 | if (format_list == NULL) | |
230 | errx(1, "realloc error"); | |
231 | } | |
232 | ||
233 | format_list[nformats] = XRenderFindFormat(dpy, PictFormatType, &templ, | |
234 | i); | |
235 | if (format_list[nformats] == NULL) | |
236 | break; | |
237 | ||
238 | alphabits = bit_count(format_list[nformats]->direct.alphaMask); | |
239 | redbits = bit_count(format_list[nformats]->direct.redMask); | |
240 | ||
241 | /* Our testing code isn't all that hot, so don't bother trying at | |
242 | * the low depths yet. | |
243 | */ | |
244 | if ((redbits >= 1 && redbits <= 4) || | |
245 | (alphabits >= 1 && alphabits <= 4)) | |
246 | { | |
247 | continue; | |
248 | } | |
249 | ||
250 | describe_format(name, 20, format_list[nformats]); | |
251 | ||
252 | if (format_whitelist_len != 0) { | |
253 | Bool ok = FALSE; | |
254 | int j; | |
255 | ||
256 | for (j = 0; j < format_whitelist_len; j++) { | |
257 | if (strcmp(format_whitelist[j], name) == 0) { | |
258 | ok = TRUE; | |
259 | break; | |
260 | } | |
261 | } | |
262 | if (!ok) { | |
263 | printf("Ignoring server-supported format: %s\n", name); | |
264 | continue; | |
265 | } | |
266 | } | |
267 | ||
268 | if (format_list[nformats] == XRenderFindStandardFormat(dpy, | |
269 | PictStandardARGB32)) | |
270 | { | |
271 | argb32index = nformats; | |
272 | } | |
273 | ||
274 | printf("Found server-supported format: %s\n", name); | |
275 | ||
276 | nformats++; | |
277 | } | |
278 | if (argb32index == -1) { | |
279 | errx(1, "required ARGB32 format not found"); | |
280 | } | |
281 | } | |
282 | ||
283 | Bool | |
284 | do_tests(Display *dpy, picture_info *win) | |
285 | { | |
286 | int i, j, src, dst = 0, mask; | |
287 | int num_dests; | |
288 | picture_info *dests, *pictures_1x1, *pictures_10x10, picture_3x3, *pictures_solid; | |
289 | int success_mask = 0, tests_passed = 0, tests_total = 0; | |
290 | int num_tests; | |
291 | ||
292 | create_formats_list(dpy); | |
293 | ||
294 | num_dests = nformats; | |
295 | dests = (picture_info *)malloc(num_dests * sizeof(dests[0])); | |
296 | if (dests == NULL) | |
297 | errx(1, "malloc error"); | |
298 | ||
299 | for (i = 0; i < num_dests; i++) { | |
300 | dests[i].format = format_list[i]; | |
301 | dests[i].d = XCreatePixmap(dpy, RootWindow(dpy, 0), | |
302 | win_width, win_height, dests[i].format->depth); | |
303 | dests[i].pict = XRenderCreatePicture(dpy, dests[i].d, | |
304 | dests[i].format, 0, NULL); | |
305 | ||
306 | dests[i].name = (char *)malloc(20); | |
307 | if (dests[i].name == NULL) | |
308 | errx(1, "malloc error"); | |
309 | describe_format(dests[i].name, 20, dests[i].format); | |
310 | } | |
311 | ||
312 | pictures_1x1 = (picture_info *)malloc(num_colors * nformats * | |
313 | sizeof(picture_info)); | |
314 | if (pictures_1x1 == NULL) | |
315 | errx(1, "malloc error"); | |
316 | ||
317 | for (i = 0; i < num_colors * nformats; i++) { | |
318 | XRenderPictureAttributes pa; | |
319 | color4d *c = &colors[i / nformats]; | |
320 | ||
321 | /* The standard PictFormat numbers go from 0 to 4 */ | |
322 | pictures_1x1[i].format = format_list[i % nformats]; | |
323 | pictures_1x1[i].d = XCreatePixmap(dpy, RootWindow(dpy, 0), 1, | |
324 | 1, pictures_1x1[i].format->depth); | |
325 | pa.repeat = TRUE; | |
326 | pictures_1x1[i].pict = XRenderCreatePicture(dpy, | |
327 | pictures_1x1[i].d, pictures_1x1[i].format, CPRepeat, &pa); | |
328 | ||
329 | pictures_1x1[i].name = (char *)malloc(20); | |
330 | if (pictures_1x1[i].name == NULL) | |
331 | errx(1, "malloc error"); | |
332 | sprintf(pictures_1x1[i].name, "1x1R "); | |
333 | describe_format(pictures_1x1[i].name + | |
334 | strlen(pictures_1x1[i].name), 20 - | |
335 | strlen(pictures_1x1[i].name), pictures_1x1[i].format); | |
336 | ||
337 | argb_fill(dpy, &pictures_1x1[i], 0, 0, 1, 1, | |
338 | c->a, c->r, c->g, c->b); | |
339 | ||
340 | pictures_1x1[i].color = *c; | |
341 | color_correct(&pictures_1x1[i], &pictures_1x1[i].color); | |
342 | } | |
343 | argb32white = &pictures_1x1[0 * nformats + argb32index]; | |
344 | argb32red = &pictures_1x1[1 * nformats + argb32index]; | |
345 | argb32green = &pictures_1x1[2 * nformats + argb32index]; | |
346 | argb32blue = &pictures_1x1[3 * nformats + argb32index]; | |
347 | ||
348 | pictures_10x10 = (picture_info *)malloc(num_colors * nformats * | |
349 | sizeof(picture_info)); | |
350 | if (pictures_10x10 == NULL) | |
351 | errx(1, "malloc error"); | |
352 | ||
353 | for (i = 0; i < num_colors * nformats; i++) { | |
354 | XRenderPictureAttributes pa; | |
355 | color4d *c = &colors[i / nformats]; | |
356 | ||
357 | /* The standard PictFormat numbers go from 0 to 4 */ | |
358 | pictures_10x10[i].format = format_list[i % nformats]; | |
359 | pictures_10x10[i].d = XCreatePixmap(dpy, RootWindow(dpy, 0), 10, | |
360 | 10, pictures_10x10[i].format->depth); | |
361 | pa.repeat = TRUE; | |
362 | pictures_10x10[i].pict = XRenderCreatePicture(dpy, | |
363 | pictures_10x10[i].d, pictures_10x10[i].format, 0, NULL); | |
364 | ||
365 | pictures_10x10[i].name = (char *)malloc(20); | |
366 | if (pictures_10x10[i].name == NULL) | |
367 | errx(1, "malloc error"); | |
368 | sprintf(pictures_10x10[i].name, "10x10 "); | |
369 | describe_format(pictures_10x10[i].name + | |
370 | strlen(pictures_10x10[i].name), 20 - | |
371 | strlen(pictures_10x10[i].name), pictures_10x10[i].format); | |
372 | ||
373 | argb_fill(dpy, &pictures_10x10[i], 0, 0, 10, 10, | |
374 | c->a, c->r, c->g, c->b); | |
375 | ||
376 | pictures_10x10[i].color = *c; | |
377 | color_correct(&pictures_10x10[i], &pictures_10x10[i].color); | |
378 | } | |
379 | ||
380 | picture_3x3.d = XCreatePixmap(dpy, RootWindow(dpy, 0), 3, 3, 32); | |
381 | picture_3x3.format = XRenderFindStandardFormat(dpy, PictStandardARGB32); | |
382 | picture_3x3.pict = XRenderCreatePicture(dpy, picture_3x3.d, | |
383 | picture_3x3.format, 0, NULL); | |
384 | picture_3x3.name = "3x3 sample picture"; | |
385 | for (i = 0; i < 9; i++) { | |
386 | int x = i % 3; | |
387 | int y = i / 3; | |
388 | color4d *c = &colors[i % num_colors]; | |
389 | ||
390 | argb_fill(dpy, &picture_3x3, x, y, 1, 1, c->a, c->r, c->g, c->b); | |
391 | } | |
392 | ||
393 | pictures_solid = malloc(num_colors * sizeof(picture_info)); | |
394 | for (i = 0; i < num_colors; i++) { | |
395 | XRenderColor c; | |
396 | pictures_solid[i].color = colors[i]; | |
397 | c.alpha = (int)(colors[i].a*65535); | |
398 | c.red = (int)(colors[i].r*65535); | |
399 | c.green = (int)(colors[i].g*65535); | |
400 | c.blue = (int)(colors[i].b*65535); | |
401 | pictures_solid[i].pict = XRenderCreateSolidFill(dpy, &c); | |
402 | pictures_solid[i].format = format_list[argb32index]; | |
403 | pictures_solid[i].name = "Solid"; | |
404 | } | |
405 | ||
406 | #define RECORD_RESULTS() \ | |
407 | do { \ | |
408 | group_ok = group_ok && ok; \ | |
409 | if (ok) \ | |
410 | tests_passed++; \ | |
411 | tests_total++; \ | |
412 | } while (0) | |
413 | ||
414 | num_tests = num_colors * nformats; | |
415 | ||
416 | if (enabled_tests & TEST_FILL) { | |
417 | Bool ok, group_ok = TRUE; | |
418 | ||
419 | printf("Beginning testing of filling of 1x1R pictures\n"); | |
420 | for (i = 0; i < num_tests; i++) { | |
421 | ok = fill_test(dpy, win, &pictures_1x1[i]); | |
422 | RECORD_RESULTS(); | |
423 | } | |
424 | ||
425 | printf("Beginning testing of filling of 10x10 pictures\n"); | |
426 | for (i = 0; i < num_tests; i++) { | |
427 | ok = fill_test(dpy, win, &pictures_10x10[i]); | |
428 | RECORD_RESULTS(); | |
429 | } | |
430 | if (group_ok) | |
431 | success_mask |= TEST_FILL; | |
432 | } | |
433 | ||
434 | if (enabled_tests & TEST_DSTCOORDS) { | |
435 | Bool ok, group_ok = TRUE; | |
436 | ||
437 | printf("Beginning dest coords test\n"); | |
438 | for (i = 0; i < 2; i++) { | |
439 | ok = dstcoords_test(dpy, win, | |
440 | i == 0 ? PictOpSrc : PictOpOver, win, | |
441 | argb32white, argb32red); | |
442 | RECORD_RESULTS(); | |
443 | } | |
444 | if (group_ok) | |
445 | success_mask |= TEST_DSTCOORDS; | |
446 | } | |
447 | ||
448 | if (enabled_tests & TEST_SRCCOORDS) { | |
449 | Bool ok, group_ok = TRUE; | |
450 | ||
451 | printf("Beginning src coords test\n"); | |
452 | ok = srccoords_test(dpy, win, argb32white, FALSE); | |
453 | RECORD_RESULTS(); | |
454 | if (group_ok) | |
455 | success_mask |= TEST_SRCCOORDS; | |
456 | } | |
457 | ||
458 | if (enabled_tests & TEST_MASKCOORDS) { | |
459 | Bool ok, group_ok = TRUE; | |
460 | ||
461 | printf("Beginning mask coords test\n"); | |
462 | ok = srccoords_test(dpy, win, argb32white, TRUE); | |
463 | RECORD_RESULTS(); | |
464 | if (group_ok) | |
465 | success_mask |= TEST_MASKCOORDS; | |
466 | } | |
467 | ||
468 | if (enabled_tests & TEST_TSRCCOORDS) { | |
469 | Bool ok, group_ok = TRUE; | |
470 | ||
471 | printf("Beginning transformed src coords test\n"); | |
472 | ok = trans_coords_test(dpy, win, argb32white, FALSE); | |
473 | RECORD_RESULTS(); | |
474 | ||
475 | printf("Beginning transformed src coords test 2\n"); | |
476 | ok = trans_srccoords_test_2(dpy, win, argb32white, FALSE); | |
477 | RECORD_RESULTS(); | |
478 | if (group_ok) | |
479 | success_mask |= TEST_TSRCCOORDS; | |
480 | } | |
481 | ||
482 | if (enabled_tests & TEST_TMASKCOORDS) { | |
483 | Bool ok, group_ok = TRUE; | |
484 | ||
485 | printf("Beginning transformed mask coords test\n"); | |
486 | ok = trans_coords_test(dpy, win, argb32white, TRUE); | |
487 | RECORD_RESULTS(); | |
488 | ||
489 | printf("Beginning transformed mask coords test 2\n"); | |
490 | ok = trans_srccoords_test_2(dpy, win, argb32white, TRUE); | |
491 | RECORD_RESULTS(); | |
492 | ||
493 | if (group_ok) | |
494 | success_mask |= TEST_TMASKCOORDS; | |
495 | } | |
496 | ||
497 | if (enabled_tests & TEST_BLEND) { | |
498 | Bool ok, group_ok = TRUE; | |
499 | ||
500 | for (i = 0; i < num_ops; i++) { | |
501 | if (ops[i].disabled) | |
502 | continue; | |
503 | ||
504 | for (j = 0; j <= num_dests; j++) { | |
505 | picture_info *pi; | |
506 | ||
507 | if (j != num_dests) | |
508 | pi = &dests[j]; | |
509 | else | |
510 | pi = win; | |
511 | printf("Beginning %s blend test on %s\n", ops[i].name, | |
512 | pi->name); | |
513 | ||
514 | for (src = 0; src < num_tests; src++) { | |
515 | for (dst = 0; dst < num_tests; dst++) { | |
516 | ok = blend_test(dpy, win, pi, i, | |
517 | &pictures_1x1[src], | |
518 | &pictures_1x1[dst]); | |
519 | RECORD_RESULTS(); | |
520 | ok = blend_test(dpy, win, pi, i, | |
521 | &pictures_10x10[src], | |
522 | &pictures_1x1[dst]); | |
523 | RECORD_RESULTS(); | |
524 | } | |
525 | } | |
526 | for (src = 0; src < num_colors; src++) { | |
527 | for (dst = 0; dst < num_colors; dst++) { | |
528 | ok = blend_test(dpy, win, pi, i, &pictures_solid[src], &pictures_1x1[dst]); | |
529 | RECORD_RESULTS(); | |
530 | } | |
531 | } | |
532 | } | |
533 | } | |
534 | if (group_ok) | |
535 | success_mask |= TEST_BLEND; | |
536 | } | |
537 | ||
538 | if (enabled_tests & TEST_COMPOSITE) { | |
539 | Bool ok, group_ok = TRUE; | |
540 | ||
541 | for (i = 0; i < num_ops; i++) { | |
542 | if (ops[i].disabled) | |
543 | continue; | |
544 | ||
545 | for (j = 0; j <= num_dests; j++) { | |
546 | picture_info *pi; | |
547 | ||
548 | if (j != num_dests) | |
549 | pi = &dests[j]; | |
550 | else | |
551 | pi = win; | |
552 | printf("Beginning %s composite mask test on %s\n", | |
553 | ops[i].name, pi->name); | |
554 | ||
555 | for (src = 0; src < num_tests; src++) { | |
556 | for (mask = 0; mask < num_tests; mask++) { | |
557 | for (dst = 0; dst < num_tests; dst++) { | |
558 | ok = composite_test(dpy, win, pi, i, | |
559 | &pictures_10x10[src], | |
560 | &pictures_10x10[mask], | |
561 | &pictures_1x1[dst], FALSE, TRUE); | |
562 | RECORD_RESULTS(); | |
563 | ok = composite_test(dpy, win, pi, i, | |
564 | &pictures_1x1[src], | |
565 | &pictures_10x10[mask], | |
566 | &pictures_1x1[dst], FALSE, TRUE); | |
567 | RECORD_RESULTS(); | |
568 | ok = composite_test(dpy, win, pi, i, | |
569 | &pictures_10x10[src], | |
570 | &pictures_1x1[mask], | |
571 | &pictures_1x1[dst], FALSE, TRUE); | |
572 | RECORD_RESULTS(); | |
573 | ok = composite_test(dpy, win, pi, i, | |
574 | &pictures_1x1[src], | |
575 | &pictures_1x1[mask], | |
576 | &pictures_1x1[dst], FALSE, TRUE); | |
577 | RECORD_RESULTS(); | |
578 | } | |
579 | } | |
580 | } | |
581 | } | |
582 | } | |
583 | if (group_ok) | |
584 | success_mask |= TEST_COMPOSITE; | |
585 | } | |
586 | ||
587 | if (enabled_tests & TEST_CACOMPOSITE) { | |
588 | Bool ok, group_ok = TRUE; | |
589 | ||
590 | for (i = 0; i < num_ops; i++) { | |
591 | if (ops[i].disabled) | |
592 | continue; | |
593 | ||
594 | for (j = 0; j <= num_dests; j++) { | |
595 | picture_info *pi; | |
596 | ||
597 | if (j != num_dests) | |
598 | pi = &dests[j]; | |
599 | else | |
600 | pi = win; | |
601 | printf("Beginning %s composite CA mask test on %s\n", | |
602 | ops[i].name, pi->name); | |
603 | ||
604 | for (src = 0; src < num_tests; src++) { | |
605 | for (mask = 0; mask < num_tests; mask++) { | |
606 | for (dst = 0; dst < num_tests; dst++) { | |
607 | ok = composite_test(dpy, win, pi, i, | |
608 | &pictures_10x10[src], | |
609 | &pictures_10x10[mask], | |
610 | &pictures_1x1[dst], TRUE, TRUE); | |
611 | RECORD_RESULTS(); | |
612 | ok = composite_test(dpy, win, pi, i, | |
613 | &pictures_1x1[src], | |
614 | &pictures_10x10[mask], | |
615 | &pictures_1x1[dst], TRUE, TRUE); | |
616 | RECORD_RESULTS(); | |
617 | ok = composite_test(dpy, win, pi, i, | |
618 | &pictures_10x10[src], | |
619 | &pictures_1x1[mask], | |
620 | &pictures_1x1[dst], TRUE, TRUE); | |
621 | RECORD_RESULTS(); | |
622 | ok = composite_test(dpy, win, pi, i, | |
623 | &pictures_1x1[src], | |
624 | &pictures_1x1[mask], | |
625 | &pictures_1x1[dst], TRUE, TRUE); | |
626 | RECORD_RESULTS(); | |
627 | } | |
628 | } | |
629 | } | |
630 | } | |
631 | } | |
632 | if (group_ok) | |
633 | success_mask |= TEST_CACOMPOSITE; | |
634 | } | |
635 | ||
636 | if (enabled_tests & TEST_GRADIENTS) { | |
637 | Bool ok, group_ok = TRUE; | |
638 | ||
639 | printf("Beginning render to linear gradient test\n"); | |
640 | ok = render_to_gradient_test(dpy, &pictures_1x1[0]); | |
641 | RECORD_RESULTS(); | |
642 | ||
643 | for (i = 0; i < num_ops; i++) { | |
644 | if (ops[i].disabled) | |
645 | continue; | |
646 | ||
647 | for (j = 0; j <= num_dests; j++) { | |
648 | picture_info *pi; | |
649 | ||
650 | if (j != num_dests) | |
651 | pi = &dests[j]; | |
652 | else | |
653 | pi = win; | |
654 | printf("Beginning %s linear gradient test on %s\n", | |
655 | ops[i].name, pi->name); | |
656 | ||
657 | for (src = 0; src < num_tests; src++) { | |
658 | ok = linear_gradient_test(dpy, win, pi, i, | |
659 | &pictures_1x1[src]); | |
660 | RECORD_RESULTS(); | |
661 | } | |
662 | } | |
663 | } | |
664 | if (group_ok) | |
665 | success_mask |= TEST_GRADIENTS; | |
666 | } | |
667 | ||
668 | if (enabled_tests & TEST_REPEAT) { | |
669 | Bool ok, group_ok = TRUE; | |
670 | ||
671 | for (i = 0; i < num_ops; i++) { | |
672 | if (ops[i].disabled) | |
673 | continue; | |
674 | ||
675 | for (j = 0; j <= num_dests; j++) { | |
676 | picture_info *pi; | |
677 | ||
678 | if (j != num_dests) | |
679 | pi = &dests[j]; | |
680 | else | |
681 | pi = win; | |
682 | printf("Beginning %s src repeat test on %s\n", | |
683 | ops[i].name, pi->name); | |
684 | /* Test with white dest, and generated repeating src | |
685 | * consisting of colors 1 and 2 (r, g). | |
686 | */ | |
687 | ok = repeat_test(dpy, win, pi, i, argb32white, argb32red, | |
688 | argb32green, FALSE); | |
689 | RECORD_RESULTS(); | |
690 | ||
691 | printf("Beginning %s mask repeat test on %s\n", | |
692 | ops[i].name, pi->name); | |
693 | /* Test with white dest, translucent red src, and generated | |
694 | * repeating mask consisting of colors 1 and 2 (r, g). | |
695 | */ | |
696 | ok = repeat_test(dpy, win, pi, i, argb32white, argb32red, | |
697 | argb32green, TRUE); | |
698 | RECORD_RESULTS(); | |
699 | } | |
700 | } | |
701 | if (group_ok) | |
702 | success_mask |= TEST_REPEAT; | |
703 | } | |
704 | ||
705 | if (enabled_tests & TEST_TRIANGLES) { | |
706 | Bool ok, group_ok = TRUE; | |
707 | ||
708 | for (i = 0; i < num_ops; i++) { | |
709 | if (ops[i].disabled) | |
710 | continue; | |
711 | ||
712 | for (j = 0; j <= num_dests; j++) { | |
713 | picture_info *pi; | |
714 | ||
715 | if (j != num_dests) | |
716 | pi = &dests[j]; | |
717 | else | |
718 | pi = win; | |
719 | ||
720 | printf("Beginning %s Triangles test on %s\n", | |
721 | ops[i].name, pi->name); | |
722 | ok = triangles_test(dpy, win, pi, i, | |
723 | argb32red, argb32white); | |
724 | RECORD_RESULTS(); | |
725 | ||
726 | printf("Beginning %s TriStrip test on %s\n", | |
727 | ops[i].name, pi->name); | |
728 | ok = tristrip_test(dpy, win, pi, i, | |
729 | argb32red, argb32white); | |
730 | RECORD_RESULTS(); | |
731 | ||
732 | printf("Beginning %s TriFan test on %s\n", | |
733 | ops[i].name, pi->name); | |
734 | ok = trifan_test(dpy, win, pi, i, | |
735 | argb32red, argb32white); | |
736 | RECORD_RESULTS(); | |
737 | } | |
738 | } | |
739 | if (group_ok) | |
740 | success_mask |= TEST_TRIANGLES; | |
741 | } | |
742 | ||
743 | if (enabled_tests & TEST_BUG7366) { | |
744 | Bool ok, group_ok = TRUE; | |
745 | ||
746 | ok = bug7366_test(dpy); | |
747 | RECORD_RESULTS(); | |
748 | ||
749 | if (group_ok) | |
750 | success_mask |= TEST_BUG7366; | |
751 | } | |
752 | ||
753 | printf("%d tests passed of %d total\n", tests_passed, tests_total); | |
754 | ||
755 | return tests_passed == tests_total; | |
756 | } | |
757 | ||
758 | /** | |
759 | * \brief copies the contents of a picture to the window. | |
760 | * | |
761 | * This is used in tests so that the user sees flashing colors indicating that | |
762 | * rendercheck is really doing things. The minimalrendering commandline option | |
763 | * indicates that this behavior should be disabled. | |
764 | */ | |
765 | void | |
766 | copy_pict_to_win(Display *dpy, picture_info *pict, picture_info *win, | |
767 | int width, int height) | |
768 | { | |
769 | if (pict == win || minimalrendering) | |
770 | return; | |
771 | ||
772 | XRenderComposite(dpy, PictOpSrc, pict->pict, 0, win->pict, 0, 0, | |
773 | 0, 0, 0, 0, width, height); | |
774 | } |