1XCOMM $XdotOrg: xc/config/cf/xorg.cf,v 1.44 2005/01/27 03:50:46 ajax Exp $
2/*
3 * This configuration file contains all of the configuration
4 * information for the Xorg based X Servers.
5 *
6 * Most of these settings can be overridden in a vendor.cf or the
7 * BeforeVendor part of the site.def file.
8 */
9XCOMM $Xorg: xfree86.cf,v 1.4 2000/08/17 19:41:49 cpqbld Exp $
10
11/* Get and set version information. */
12
13#include "date.def"
14#include "xorgversion.def"
15
16#if !defined(XorgVersionString) && \
17    defined(XORG_VERSION_MAJOR) && defined(XORG_VERSION_MINOR) && \
18    defined(XORG_VERSION_PATCH) && defined(XORG_VERSION_SNAP)
19# if XORG_VERSION_SNAP == 0
20#  if XORG_VERSION_PATCH == 0
21#   define XorgVersionString `echo XORG_VERSION_MAJOR XORG_VERSION_MINOR | sed 's/ /./g'`
22#  else
23#   define XorgVersionString `echo XORG_VERSION_MAJOR XORG_VERSION_MINOR XORG_VERSION_PATCH | sed 's/ /./g'`
24#  endif
25# else
26#  define XorgVersionString `echo XORG_VERSION_MAJOR XORG_VERSION_MINOR XORG_VERSION_PATCH XORG_VERSION_SNAP | sed 's/ /./g'`
27# endif
28#endif
29
30#if !defined(XORG_DATE) && defined(XF86_DATE)
31# define XORG_DATE XF86_DATE
32#endif
33
34/*
35 * Xorg versions are M.m.P.s, and XorgVersion is:
36 *
37 *    M * 10000000 + m * 100000 + P * 1000 + s
38 *
39 */
40
41#ifndef XorgVersion
42#  define XorgVersion (((XORG_VERSION_MAJOR) * 10000000) + ((XORG_VERSION_MINOR) * 100000) + ((XORG_VERSION_PATCH) * 1000) + XORG_VERSION_SNAP)
43#endif
44
45#ifndef VersionDefines
46# define VersionDefines -DXORG_VERSION_CURRENT="$(XORG_VERSION_CURRENT)"
47#endif
48
49/* Place the version of the relevant changelog file here */
50#ifndef ReleaseVersion
51# define ReleaseVersion  RELEASE-1
52#endif
53
54XORG_VERSION_CURRENT = XorgVersion
55RELEASE_VERSION = ReleaseVersion
56
57#if !defined(XorgManVersionString) && \
58    defined(XORG_VERSION_MAJOR) && defined(XORG_VERSION_MINOR) && \
59    defined(XORG_VERSION_PATCH) && defined(XORG_VERSION_SNAP)
60# if XORG_VERSION_SNAP == 0
61#define XorgManVersionString `echo XORG_VERSION_MAJOR XORG_VERSION_MINOR XORG_VERSION_PATCH | sed -e 's/ /./g' -e 's/^/Version\\\ /'`
62#else
63#define XorgManVersionString `echo XORG_VERSION_MAJOR XORG_VERSION_MINOR XORG_VERSION_PATCH XORG_VERSION_SNAP | sed -e 's/ /./g' -e 's/^/Version\\\ /'`
64# endif
65#endif
66
67#if !defined(XorgDateString) && defined(XORG_DATE)
68# define XorgDateString XORG_DATE
69#endif
70
71#if !defined(XFree86DateString) && defined(XorgDateString)
72# define XFree86DateString XorgDateString
73#endif
74
75#ifndef BuildDateCmd
76# define BuildDateCmd	date +%Y%m%d
77#endif
78
79#if !defined(BuildDate)
80# define BuildDate 	`BuildDateCmd`
81#endif
82
83#ifndef ChangelogDateCmd
84# define ChangelogDateCmd if tail $(CHANGELOGFILE) 2>/dev/null | \	@@\
85	fgrep '$$XdotOrg:' >/dev/null 2>&1; then \			@@\
86	  tail $(CHANGELOGFILE) | fgrep '$$XdotOrg:' | \		@@\
87	  sed s,'.* \([0-9][0-9]*\)/\([0-9][0-9]*\)/\([0-9][0-9]*\).*,\1\2\3,'; \ @@\
88	else echo 0; fi
89#endif
90
91#if !defined(ChangelogDate)
92# define ChangelogDate	`ChangelogDateCmd`
93#endif
94
95#ifndef XVendorString
96# define XVendorString	"The X.Org Foundation"
97#endif
98
99#ifndef XVendorRelease
100# define XVendorRelease	XorgVersion
101#endif
102
103#ifndef XVendorManVersionString
104#define XVendorManVersionString XorgManVersionString
105#endif
106
107#ifndef XVendorManNameString
108#define XVendorManNameString X.Org
109#endif
110
111/*
112 * This enables some settings for developers.
113 */
114
115#ifndef XFree86Devel
116# if !defined(PatheticCpp) || !PatheticCpp
117#  if (XorgVersion % 1000)
118#   define XFree86Devel		YES
119#  else
120#   define XFree86Devel		NO
121#  endif
122# else
123#  define XFree86Devel		NO	/* Assume the worst */
124# endif
125#endif
126
127#ifndef BuildDebug
128# define BuildDebug 		YES
129#endif
130
131/*
132 * settings for the config file parser
133 */
134
135#ifndef XConfigFile
136#define XConfigFile		xorg.conf
137#endif
138#ifndef XConfigDir
139#define XConfigDir		$(LIBDIR)
140#endif
141#ifndef XLogFile
142#define XLogFile		Xorg
143#endif
144#ifndef XServerName
145# define XServerName		Xorg
146#endif
147
148/*
149 * BuildXFree86ConfigTools:
150 *
151 * Turning this on allows the XFree86 config tools to build when
152 * BuildServersOnly is YES.  This requires more than the servonly CVS
153 * module.  This cannot be used to disable building the config tools with
154 * a full build.
155 */
156#ifndef BuildXFree86ConfigTools
157#ifdef BuildServersOnly
158#define BuildXFree86ConfigTools		!BuildServersOnly
159#else
160#define BuildXFree86ConfigTools		YES
161#endif
162#endif
163
164#ifndef BuildLibrariesForConfigTools
165#define BuildLibrariesForConfigTools	BuildXFree86ConfigTools
166#endif
167
168#if BuildXFree86ConfigTools && BuildLibrariesForConfigTools
169#define BuildLibraries		YES
170#define BuildXF86MiscLibrary	YES
171#define BuildXF86VidModeLibrary	YES
172#define BuildXKBlib		YES
173#define BuildXKBfilelib		YES
174#define BuildXKBuilib		YES
175#endif
176
177/*
178 * When this is set, modules are always built separately from the libraries
179 * that statically link into an Xserver.  This is for platforms where the
180 * module and native object formats are different (e.g., OS/2).
181 */
182#ifndef BuildModuleInSubdir
183#define BuildModuleInSubdir	NO
184#endif
185
186#ifndef DoLoadableServer
187#define DoLoadableServer	NO
188#endif
189
190#ifndef MakeDllModules
191#if DoLoadableServer
192#define MakeDllModules		YES
193#else
194#define MakeDllModules		NO
195#endif
196#endif
197
198/*
199 * Default settings for which X Servers to build.
200 */
201
202/* OS.cf files may set this for OS-specific input drivers */
203#ifndef OSXInputDrivers
204#define OSXInputDrivers /**/
205#endif
206
207/* This may be set in host.def for 3rd party input drivers */
208#ifndef ExtraXInputDrivers
209#define ExtraXInputDrivers /**/
210#endif
211
212/* XInput drivers */
213#ifndef XInputDrivers
214#define XInputDrivers		mouse keyboard acecad calcomp citron \
215				digitaledge dmc dynapro elographics tek4957 \
216				microtouch mutouch penmount spaceorb summa \
217				wacom void magellan /* magictouch */ hyperpen \
218				jamstudio fpit \
219				palmax OSXInputDrivers ExtraXInputDrivers
220#endif
221
222
223/* Deprecated keyboard driver */
224#ifndef UseDeprecatedKeyboardDriver
225#define UseDeprecatedKeyboardDriver NO
226#endif
227
228/* <linux/input.h> support mainly for USB support */
229#ifndef HasLinuxInput
230# define HasLinuxInput NO
231#endif
232
233/* OS.cf files may set this for OS-specific drivers */
234#ifndef XF86OSCardDrivers
235#define XF86OSCardDrivers /**/
236#endif
237
238/* This may be set in host.def for 3rd party drivers */
239#ifndef XF86ExtraCardDrivers
240#define XF86ExtraCardDrivers /**/
241#endif
242
243/* OS.cf files may set this for OS-specific drivers */
244#ifndef HasAgpGart
245#define HasAgpGart NO
246#endif
247
248/* Some DRI drivers are disabled because they are either insecure or unusable on
249 * this architecture.  This switch allows you to enable building these drivers.
250 */
251#ifndef BuildDevelDRIDrivers
252#define BuildDevelDRIDrivers NO
253#endif
254
255/* The glide driver only works for the loadable server at the moment */
256#ifndef HasGlide2
257#define HasGlide2 NO
258#endif
259#if HasGlide2 && DoLoadableServer
260#define GlideDriver glide
261#else
262#define GlideDriver /**/
263#endif
264
265/*
266 * There are three parameters that determine where and how the Matrox HAL
267 * library is used:
268 *
269 *   HaveMatroxHal  -- You have the HALlib.a binary library installed
270 *                     in xfree86/drivers/mga/HALlib, and you want it to
271 *                     be used.
272 *                     Default: NO
273 *
274 *   BuildMatroxHal -- You have the source for the HALlib library (installed
275 *                     in xfree86/drivers/mga/hallib), and want to build and
276 *                     use it.
277 *                     Default: NO
278 *
279 *   UseMatroxHal   -- You want to build support for loading/using the HAL
280 *                     library into the mga driver.  For module server builds
281 *                     you don't need to have the HALlib library to do this.
282 *                     but you want to build support for loading it and using
283 *                     it into the mga driver module.
284 *                     Default: YES for loadable server build
285 *                              (HaveMatroxHal || BuildMatroxHal) for static
286 */
287
288#ifndef HaveMatroxHal
289#define HaveMatroxHal NO
290#endif
291
292#ifndef BuildMatroxHal
293#define BuildMatroxHal NO
294#endif
295
296#ifndef UseMatroxHal
297#if DoLoadableServer
298#define UseMatroxHal YES
299#else
300#define UseMatroxHal (HaveMatroxHal || BuildMatroxHal)
301#endif
302#endif
303
304/*
305 * Many architectures share common X Server pieces.  List them here.
306 */
307#if defined(i386Architecture) || defined(ia64Architecture) || \
308    defined(AMD64Architecture) || defined(SparcArchitecture) || \
309    defined(Sparc64Architecture) || defined(MipsArchitecture) || \
310    defined(AlphaArchitecture) || defined(PpcArchitecture) || \
311    defined(Mc68020Architecture) || defined(Arm32Architecture) || \
312    defined(HPArchitecture) || defined(SuperHArchitecture)
313# ifndef XorgServer
314#  define XorgServer		YES
315# endif
316/* 1bpp module */
317# ifndef XF1Bpp
318#  define XF1Bpp		YES
319# endif
320/* 4bpp module */
321# ifndef XF4Bpp
322#  define XF4Bpp		YES
323# endif
324/* 8/32bpp overlay module */
325# ifndef XF8_32Bpp
326#  define XF8_32Bpp		YES
327# endif
328/* 8/16bpp dual fb module */
329# ifndef XF8_16Bpp
330#  define XF8_16Bpp		YES
331# endif
332/* shadow fb module */
333# ifndef XFShadowFB
334#  define XFShadowFB		YES
335# endif
336/* fbdevhw module */
337# ifndef XF86FBDevHw
338#  define XF86FBDevHw		YES
339# endif
340/* XAA module */
341# ifndef XF86XAA
342#  define XF86XAA		YES
343# endif
344/* Exa module */
345# ifndef XF86EXA
346#  define XF86EXA		YES
347# endif
348/* ramdac module */
349# ifndef XF86Ramdac
350#  define XF86Ramdac		YES
351# endif
352/* I2C module */
353# ifndef XF86I2C
354#  define XF86I2C		YES
355# endif
356/* DDC module */
357# ifndef XF86DDC
358#  define XF86DDC		YES
359# endif
360/* RAC (Resource Access Control) module */
361# ifndef XF86RAC
362#  define XF86RAC		YES
363# endif
364/* int10 module */
365# ifndef XF86Int10
366#  define XF86Int10		YES
367# endif
368/* vbe module */
369# ifndef XF86VBE
370#  define XF86VBE		YES
371# endif
372#endif
373
374/*
375 * Intel x86 and ia64 drivers
376 */
377#if defined(i386Architecture) || defined(ia64Architecture)
378/* vgahw module */
379# ifndef XF86VgaHw
380#  define XF86VgaHw		YES
381# endif
382/* Amiga framebuffer module.  Required by vesa module. */
383# ifndef XF86AFB
384#  define XF86AFB		YES
385# endif
386
387/*
388 * Drivers under development, but not ready for binary releases, or
389 * drivers included on this platform only for build testing.
390 */
391# ifndef DevelDrivers
392#  if XFree86Devel
393#   define DevelDrivers		imstt newport
394#  else
395#   define DevelDrivers		/**/
396#  endif
397# endif
398
399/* Pure PCI drivers should go first */
400# ifndef XF86CardDrivers
401#  /* Don't build the nsc driver on IA64 */
402#  ifndef ia64Architecture
403#   define i386Drivers		nsc i810
404#  else
405#   define i386Drivers		/**/
406#  endif
407#  define XF86CardDrivers	mga glint nv tga s3 s3virge sis rendition \
408				neomagic i740 tdfx savage \
409				cirrus vmware tseng trident chips apm \
410				GlideDriver i128 i386Drivers \
411				ati DevelDrivers ark \
412				cyrix siliconmotion via \
413				vesa vga \
414				dummy XF86OSCardDrivers XF86ExtraCardDrivers
415# endif
416
417# ifndef DevelDRIDrivers
418#  define DevelDRIDrivers	ffb mach64 unichrome
419# endif
420
421# ifndef DriDrivers
422#  ifndef ia64Architecture
423#   define i386DRIDrivers i810 i915 sis
424#  else
425   /* SiS is 64-bit unclean as of this writing. */
426#   define i386DRIDrivers /**/
427#  endif
428#  define DriDrivers		i386DRIDrivers mga r128 radeon r200 tdfx
429# endif
430#endif /* i386Architecture || ia64Architecture */
431
432#if defined(AMD64Architecture)
433/* vgahw module */
434# ifndef XF86VgaHw
435#  define XF86VgaHw		YES
436# endif
437/* Amiga framebuffer module.  Required by vesa module. */
438# ifndef XF86AFB
439#  define XF86AFB		YES
440# endif
441
442/*
443 * Drivers under development, but not ready for binary releases, or
444 * drivers included on this platform only for build testing.
445 */
446# ifndef DevelDrivers
447#  if XFree86Devel
448#   define DevelDrivers         /**/
449#  else
450#   define DevelDrivers         /**/
451#  endif
452# endif
453
454/* Pure PCI drivers should go first */
455# ifndef XF86CardDrivers
456#  define XF86CardDrivers	mga glint nv tga s3 s3virge sis rendition \
457				neomagic tdfx savage cirrus tseng trident \
458				chips apm i128 ati ark cyrix siliconmotion \
459				vga dummy vesa i810 vmware \
460				XF86OSCardDrivers XF86ExtraCardDrivers DevelDrivers
461# endif
462
463/* SiS is 64-bit unclean as of this writing. */
464# ifndef DriDrivers
465#  define DriDrivers		i915 mga r128 radeon r200 tdfx
466# endif
467#endif /*AMD64Arcitecture*/
468
469/* SPARC and UltraSPARC drivers */
470
471#if  (defined(SparcArchitecture) || defined(Sparc64Architecture)) && \
472    !defined(LynxOSArchitecture) && \
473    !defined(NetBSDArchitecture) && \
474    !defined(OpenBSDArchitecture)
475/* 8/32wid fb module */
476# ifndef XF8_32Wid
477#  define XF8_32Wid		YES
478# endif
479/* vgahw module */
480# ifndef XF86VgaHw
481#  define XF86VgaHw		YES
482# endif
483/* Amiga framebuffer module.  Required by vesa module. */
484# ifndef XF86AFB
485#  define XF86AFB		YES
486# endif
487
488# ifndef DevelDrivers
489#  if XFree86Devel
490   /*
491    * Some of these are compiled just for the fun of it.  Undoubtedly some
492    * require changes (or even removal) for things like endianness, etc.  Move
493    * those known to work into the main XF86CardDrivers #define.
494    */
495#   define DevelDrivers		apm ark chips cirrus i128 i740 i810 imstt \
496				neomagic newport nv rendition s3virge savage \
497				siliconmotion tga trident vmware dummy
498#  else
499#   define DevelDrivers		/* */
500#  endif
501# endif
502
503/* Pure SBUS and PCI drivers should go first */
504# ifndef XF86CardDrivers
505#  ifdef SunArchitecture
506#   define XF86CardDrivers	/* sunffb */ sunleo suncg6 suncg3 suncg14 \
507				suntcx sunbw2 glint mga tdfx ati vesa vga \
508				dummy XF86OSCardDrivers XF86ExtraCardDrivers \
509				DevelDrivers
510#  else
511#   define XF86CardDrivers	sunffb sunleo suncg6 suncg3 suncg14 suntcx \
512				sunbw2 glint mga tdfx ati vesa vga dummy \
513				XF86OSCardDrivers XF86ExtraCardDrivers \
514				DevelDrivers
515#  endif
516# endif
517# ifndef DriDrivers
518#  define DriDrivers		ffb
519# endif
520
521#endif
522
523/* Sparc64 Drivers */
524#if defined(OpenBSDArchitecture) && defined(Sparc64Architecture)
525/* Amiga framebuffer module */
526# ifndef XF86AFB
527#  define XF86AFB		NO
528# endif
529/* vgahw module */
530# ifndef XF86VgaHw
531#  define XF86VgaHw		YES
532# endif
533# ifndef UseX86Emu
534#  define UseX86Emu		NO
535# endif
536
537# ifndef DevelDrivers
538#  if XFree86Devel
539#   define DevelDrivers		/* */
540#  else
541#   define DevelDrivers		/* */
542#  endif
543# endif
544
545/* Pure PCI drivers should go first */
546# ifndef XF86CardDrivers
547#  define XF86CardDrivers	ati dummy \
548				DevelDrivers \
549				XF86OSCardDrivers XF86ExtraCardDrivers
550# endif
551#endif /* OpenBSDArchitecture && Sparc64Architecture */
552
553/* MIPS drivers */
554
555#ifdef MipsArchitecture
556/* vgahw module */
557# ifndef XF86VgaHw
558#  define XF86VgaHw		YES
559# endif
560
561# ifndef DevelDrivers
562#  if XFree86Devel
563#   define DevelDrivers		/* */
564#  else
565#   define DevelDrivers		/* */
566#  endif
567# endif
568
569# ifndef XF86CardDrivers
570#  define XF86CardDrivers	mga glint nv s3 s3virge sis savage \
571				trident chips tdfx ati dummy \
572				DevelDrivers newport \
573				XF86OSCardDrivers XF86ExtraCardDrivers
574# endif
575#endif /* MipsArchitecture */
576
577/*
578 * DEC Alpha drivers
579 */
580#ifdef AlphaArchitecture
581/* vgahw module */
582# ifndef XF86VgaHw
583#  define XF86VgaHw		YES
584# endif
585
586# ifndef DevelDrivers
587#  if XFree86Devel
588#   define DevelDrivers		/* */
589#  else
590#   define DevelDrivers		/* */
591#  endif
592# endif
593
594/* Pure PCI drivers should go first */
595# ifndef XF86CardDrivers
596#  define XF86CardDrivers	mga tdfx glint s3 s3virge rendition tga ati \
597				savage nv cirrus DevelDrivers siliconmotion  \
598				vga dummy XF86OSCardDrivers \
599				XF86ExtraCardDrivers
600# endif
601/*
602 *  Glide is available for Alpha, therefore build tdfx DRM module.
603 *  SiS is 64-bit unclean as of this writing.
604 */
605# ifndef DriDrivers
606#  define DriDrivers		tdfx mga r128 radeon r200
607# endif
608#endif /* AlphaArchitecture */
609
610/*
611 * Motorola 68k and PowerPC drivers
612 */
613#if defined(PpcArchitecture) || defined(Mc68020Architecture)
614/* Amiga framebuffer module */
615# ifndef XF86AFB
616#  define XF86AFB		YES
617# endif
618/* vgahw module */
619# ifndef XF86VgaHw
620#  define XF86VgaHw		YES
621# endif
622
623# ifndef DevelDrivers
624#  if XFree86Devel
625#   define DevelDrivers		imstt
626#  else
627#   define DevelDrivers		/* */
628#  endif
629# endif
630
631/* Pure PCI drivers should go first */
632# ifndef XF86CardDrivers
633#  define XF86CardDrivers	ati mga glint nv s3 s3virge sis savage\
634				trident chips tdfx \
635				DevelDrivers vga dummy \
636				XF86OSCardDrivers XF86ExtraCardDrivers
637# endif
638/*  The tdfx driver needs Glide, which is not available for PPC. */
639# ifndef DriDrivers
640#  define DriDrivers		mga r128 radeon r200
641# endif
642#endif  /* PpcArchitecture || Mc68020Architecture */
643
644/*
645 * Intel StrongARM and Hewlett-Packard PA-RISC
646 */
647#if defined(Arm32Architecture) || defined(HPArchitecture)
648/* vgahw module */
649# ifndef XF86VgaHw
650#  define XF86VgaHw		YES
651# endif
652
653# ifndef DevelDrivers
654#  if XFree86Devel
655#   define DevelDrivers		/* */
656#  else
657#   define DevelDrivers		/* */
658#  endif
659# endif
660
661/* Pure PCI drivers should go first */
662# ifndef XF86CardDrivers
663#  define XF86CardDrivers	ati mga glint nv s3 s3virge sis savage\
664				trident chips tdfx \
665				DevelDrivers vga dummy \
666				XF86OSCardDrivers XF86ExtraCardDrivers
667# endif
668# ifndef DriDrivers
669#  define DriDrivers		mga r128 radeon r200
670# endif
671#endif
672
673/* SuperH drivers */
674#if defined(SuperHArchitecture)
675# ifndef XF86CardDrivers
676#  define XF86CardDrivers		XF86OSCardDrivers XF86ExtraCardDrivers
677# endif
678#endif
679
680/*
681 * For PowerPC 64bit systems
682 * only libraries are strictly needed
683 */
684#if defined(Ppc64Architecture)
685# ifndef XorgServer
686#  define XorgServer		YES
687# endif
688/* 1bpp module */
689# ifndef XF1Bpp
690#  define XF1Bpp		NO
691# endif
692/* 4bpp module */
693# ifndef XF4Bpp
694#  define XF4Bpp		NO
695# endif
696/* 8/32bpp overlay module */
697# ifndef XF8_32Bpp
698#  define XF8_32Bpp		YES
699# endif
700/* 8/16bpp dual fb module */
701# ifndef XF8_16Bpp
702#  define XF8_16Bpp		YES
703# endif
704/* shadow fb module */
705# ifndef XFShadowFB
706#  define XFShadowFB		YES
707# endif
708/* fbdevhw module */
709# ifndef XF86FBDevHw
710#  define XF86FBDevHw		YES
711# endif
712/* XAA module */
713# ifndef XF86XAA
714#  define XF86XAA		YES
715# endif
716/* Exa module */
717# ifndef XF86EXA
718#  define XF86EXA		YES
719# endif
720/* ramdac module */
721# ifndef XF86Ramdac
722#  define XF86Ramdac		YES
723# endif
724/* I2C module */
725# ifndef XF86I2C
726#  define XF86I2C		YES
727# endif
728/* DDC module */
729# ifndef XF86DDC
730#  define XF86DDC		YES
731# endif
732/* RAC (Resource Access Control) module */
733# ifndef XF86RAC
734#  define XF86RAC		YES
735# endif
736/* int10 module */
737# ifndef XF86Int10
738#  define XF86Int10		YES
739# endif
740/* vbe module */
741# ifndef XF86VBE
742#  define XF86VBE		YES
743# endif
744
745/* vgahw module */
746# ifndef XF86VgaHw
747#  define XF86VgaHw		YES
748# endif
749/* Amiga framebuffer module */
750# ifndef XF86AFB
751#  define XF86AFB		NO
752# endif
753
754# ifndef DevelDrivers
755#  if XFree86Devel
756#   define DevelDrivers
757#  else
758#   define DevelDrivers		/* */
759#  endif
760# endif
761
762/* Pure PCI drivers should go first */
763# ifndef XF86CardDrivers
764#  define XF86CardDrivers	ati mga dummy \
765				DevelDrivers \
766				XF86OSCardDrivers XF86ExtraCardDrivers
767# endif
768# define TdfxDriDriver		/**/
769# ifndef DriDrivers
770#  define DriDrivers		r128
771# endif
772#endif /* Ppc64Architecture */
773
774/*
775 * For Mips/Arc platforms, the default is to build all modules which
776 * are supported on this platform.
777 */
778#ifdef ArcArchitecture
779# ifndef XorgServer
780#  define XorgServer		YES
781# endif
782#endif
783
784#if BuildDebug
785# define DebugDefines -DBUILDDEBUG
786#else
787# define DebugDefines /**/
788#endif
789
790#ifndef XorgServer
791# define XorgServer		NO
792#endif
793#if !XorgServer
794# undef DoLoadableServer
795# define DoLoadableServer	NO
796#endif
797
798/*
799 * Fbdev module defines.  They are set to indicate the fb types supported
800 * on different architectures.
801 */
802#ifndef XF86AFB
803# define XF86AFB		NO
804#endif
805#ifndef XF86ILBM
806# define XF86ILBM		NO
807#endif
808#ifndef XF86IPLAN2P2
809# define XF86IPLAN2P2		NO
810#endif
811#ifndef XF86IPLAN2P4
812# define XF86IPLAN2P4		NO
813#endif
814#ifndef XF86IPLAN2P8
815# define XF86IPLAN2P8		NO
816#endif
817#if XF86AFB
818AFB_DEFS = -DUSE_AFB
819#endif
820#if XF86ILBM
821ILBM_DEFS = -DUSE_ILBM
822#endif
823#if XF86IPLAN2P2
824IPLAN2P2_DEFS = -DUSE_IPLAN2P2
825#endif
826#if XF86IPLAN2P4
827IPLAN2P4_DEFS = -DUSE_IPLAN2P4
828#endif
829#if XF86IPLAN2P8
830IPLAN2P8_DEFS = -DUSE_IPLAN2P8
831#endif
832#ifndef FbdevDefines
833# define FbdevDefines $(AFB_DEFS) $(ILBM_DEFS) $(IPLAN2P2_DEFS) \
834		     $(IPLAN2P4_DEFS) $(IPLAN2P8_DEFS)
835#endif
836
837/*
838 * The default is to install the X servers setuid-root on most OSs.
839 * It the servers are only started by xdm, they should not be setuid-root.
840 */
841#if !defined(i386MachArchitecture) && !defined(OS2Architecture)
842# ifndef InstallXserverSetUID
843#  define InstallXserverSetUID	YES
844# endif
845#endif
846
847/*
848 * Build GLX server interface
849 *   --- Doesn't work for 1-bit and 4-bit servers
850 */
851#ifndef BuildGlxExt
852#  define BuildGlxExt	YES
853#endif
854
855#ifndef BuildXF86DRI
856#define BuildXF86DRI	NO
857#endif
858
859#ifndef GlxUseSGISI
860#define GlxUseSGISI	NO
861#endif
862
863#if BuildXF86DRI
864
865#ifndef DriDrivers
866#define DriDrivers /**/
867#endif
868
869#ifndef DevelDRIDrivers
870#define DevelDRIDrivers /**/
871#endif
872
873#ifndef BuildGLXLibrary
874#  if defined (BuildServersOnly) && BuildServersOnly
875#    define BuildGLXLibrary	NO
876#  else
877#    define BuildGLXLibrary	YES
878#  endif
879#endif
880
881/*
882 * One and ONLY one of the GlxBuiltIn* drivers can be defined to be YES.
883 * If more than one are defined, the compilation will fail with multiply
884 * defined references of GLX and OpenGL functions.
885 */
886
887/*
888 * The first is a built-in driver that does software rendering client-side
889 * and renders to the X server via Xlib.
890 */
891
892#  ifndef GlxBuiltInXMesa
893#    define GlxBuiltInXMesa         NO
894#  endif
895
896/*
897 * The rest are hardware-specific DRI drivers.
898 */
899#  ifndef GlxBuiltInGamma
900#    define GlxBuiltInGamma        NO
901#  endif
902#  ifndef GlxBuiltInTdfx
903#    define GlxBuiltInTdfx         NO
904#  endif
905#  ifndef GlxBuiltInMga
906#    define GlxBuiltInMga          NO
907#  endif
908#  ifndef GlxBuiltInI810
909#    define GlxBuiltInI810         NO
910#  endif
911#  ifndef GlxBuiltInI915
912#    define GlxBuiltInI915         NO
913#  endif
914#  ifndef GlxBuiltInR128
915#    define GlxBuiltInR128         NO
916#  endif
917#  ifndef GlxBuiltInRadeon
918#    define GlxBuiltInRadeon       NO
919#  endif
920#  ifndef GlxBuiltInR200
921#    define GlxBuiltInR200         NO
922#  endif
923#  ifndef GlxBuiltInFfb
924#    define GlxBuiltInFfb          NO
925#  endif
926#  ifndef GlxBuiltInSIS
927#    define GlxBuiltInSIS          NO
928#  endif
929
930#  if GlxBuiltInTdfx || \
931      GlxBuiltInMga || \
932      GlxBuiltInI810 || \
933      GlxBuiltInI915 || \
934      GlxBuiltInR128 || \
935      GlxBuiltInRadeon || \
936      GlxBuiltInR200 || \
937      GlxBuiltInFfb || \
938      GlxBuiltInSIS
939#    define GlxDriverUsesMesa      YES
940#  else
941#    define GlxDriverUsesMesa      NO
942#  endif
943
944#  if GlxBuiltInGamma || \
945      GlxBuiltInTdfx || \
946      GlxBuiltInMga || \
947      GlxBuiltInI810 || \
948      GlxBuiltInI915 || \
949      GlxBuiltInR128 || \
950      GlxBuiltInRadeon || \
951      GlxBuiltInR200 || \
952      GlxBuiltInFfb || \
953      GlxBuiltInSIS
954#    define GlxUseBuiltInDRIDriver YES
955#    define DRIDynLoadDefines /**/
956#  else
957#    define GlxUseBuiltInDRIDriver NO
958#    define DRIDynLoadDefines -DGLX_USE_DLOPEN
959#  endif
960
961#  if GlxUseBuiltInDRIDriver
962#    undef DriDrivers
963#    if GlxBuiltInGamma
964#      define DriDrivers gamma
965#    endif
966#    if GlxBuiltInTdfx
967#      define DriDrivers tdfx
968#    endif
969#    if GlxBuiltInMga
970#      define DriDrivers mga
971#    endif
972#    if GlxBuiltInI810
973#      define DriDrivers i810
974#    endif
975#    if GlxBuiltInI915
976#      define DriDrivers i915
977#    endif
978#    if GlxBuiltInR128
979#      define DriDrivers r128
980#    endif
981#    if GlxBuiltInRadeon
982#      define DriDrivers radeon
983#    endif
984#    if GlxBuiltInR200
985#      define DriDrivers r200
986#    endif
987#    if GlxBuiltInSIS
988#      define DriDrivers sis
989#    endif
990#    if GlxBuiltInFfb
991#      define DriDrivers ffb
992#    endif
993#  endif
994
995#endif
996
997/*
998 * This enables building DRI support into video drivers, which can be done
999 * even on platforms that don't have functional DRI support.
1000 *
1001 * Defining BuildXF86DRIDriverSupport to YES will not work until we have a
1002 * separate set of defines set up for building driver-only support for the
1003 * DRI.
1004 */
1005#ifndef BuildXF86DRIDriverSupport
1006# define BuildXF86DRIDriverSupport NO
1007#endif
1008
1009#if BuildGlxExt
1010
1011#  if BuildXF86DRI
1012#    define DRIDefines -DXF86DRI -DGLX_DIRECT_RENDERING DRIDynLoadDefines
1013#  else
1014#    define DRIDefines /**/
1015#  endif
1016#  if defined(GlxUseSGISI) && GlxUseSGISI
1017#    define GlxCoreLibDefines -DGLX_USE_SGI_SI
1018#  else
1019#    define GlxCoreLibDefines -DGLX_USE_MESA
1020#  endif
1021
1022#  if defined(SparcArchitecture)  \
1023   || defined (Sparc64Architecture) \
1024   || defined(ia64Architecture) \
1025   || defined(s390xArchitecture) \
1026   || defined(AMD64Architecture)
1027#    define GlxArchDefines -D__GLX_ALIGN64
1028#  elif defined(AlphaArchitecture)
1029/* On the Alpha we need to ensure floating point accuracy for 3D */
1030#    define GlxArchDefines -D__GLX_ALIGN64 -mieee
1031#  elif defined(DarwinArchitecture)
1032/* GLX contains lots of uninitialized globals, which can upset Darwin */
1033#    define GlxArchDefines -fno-common
1034#  else
1035#    define GlxArchDefines /**/
1036#  endif
1037
1038#  ifndef GlxExtraDefines
1039#    define GlxExtraDefines DRIDefines GlxCoreLibDefines GlxArchDefines
1040#  endif
1041
1042#else
1043
1044/* If we are not building GLX, then make sure the DRI is not built */
1045#  undef  BuildXF86DRI
1046#  define BuildXF86DRI   NO
1047#  undef  BuildXF86DRIDriverSupport
1048#  define BuildXF86DRIDriverSupport NO
1049
1050#endif
1051
1052#if !BuildXF86DRI
1053# define GlxUseBuiltInDRIDriver NO	/* For libOSmesa */
1054#endif
1055
1056# ifndef UseX86Emu
1057#  define UseX86Emu		YES
1058# endif
1059
1060#define X86INT10_STUB   0
1061#define X86EMU_GENERIC  1
1062#define X86VM           2
1063#define X86EMU_OS       3
1064
1065#ifndef XF86INT10_BUILD
1066# if UseX86Emu
1067#  define XF86INT10_BUILD		X86EMU_GENERIC
1068# else
1069#  define XF86INT10_BUILD		X86INT10_STUB
1070# endif
1071#endif
1072/*
1073 * Build the Rush extension library (non standard extension for cooperation
1074 * between glide library and X server). Enabled by default only for Linux.
1075 */
1076#ifndef BuildXF86RushExt
1077# define BuildXF86RushExt	NO
1078#endif
1079
1080#ifndef BuildDBElib
1081# define BuildDBElib	YES
1082#endif
1083
1084#ifndef BuildRECORDlib
1085# define BuildRECORDlib	YES
1086#endif
1087
1088#ifndef BuildXKBlib
1089# define BuildXKBlib	YES
1090#endif
1091
1092#ifndef BuildScreenSaverExt
1093# define BuildScreenSaverExt	YES
1094#endif
1095
1096/*
1097 * Build XInput support
1098 */
1099#ifndef BuildXInputExt
1100# define BuildXInputExt		YES
1101#endif
1102
1103/* Build Xinerama (aka panoramiX) extension */
1104#ifndef BuildXinerama
1105# define BuildXinerama		YES
1106#endif
1107
1108/* Build Render extension */
1109#ifndef BuildRender
1110# define BuildRender		YES
1111#endif
1112
1113#if 0
1114#ifndef JoystickSupport
1115# define JoystickSupport	NO
1116#endif
1117#endif
1118
1119#if 0
1120/*
1121 * Build the extra extension libs even when not including the extra extensions
1122 * in the servers
1123 */
1124#ifndef BuildScreenSaverLibrary
1125# define BuildScreenSaverLibrary   YES
1126#endif
1127#ifndef BuildXF86MiscLibrary
1128# define BuildXF86MiscLibrary	YES
1129#endif
1130#ifndef BuildXF86DGALibrary
1131# define BuildXF86DGALibrary	YES
1132#endif
1133#ifndef BuildXF86VidModeLibrary
1134# define BuildXF86VidModeLibrary YES
1135#endif
1136#ifndef BuildXvLibrary
1137# define BuildXvLibrary		YES
1138#endif
1139#ifndef BuildXvMCLibrary
1140# define BuildXvMCLibrary	YES
1141#endif
1142#ifndef BuildGLXLibrary
1143# define BuildGLXLibrary	YES
1144#endif
1145#ifndef BuildXResLibrary
1146# define BuildXResLibrary       YES
1147#endif
1148#endif
1149
1150/*
1151 * Build the XFree86-VidMode extension
1152 */
1153#ifndef BuildXF86VidModeExt
1154# define BuildXF86VidModeExt		YES
1155#endif
1156
1157/* Don't build this now because the interface hasn't been done yet */
1158/*
1159 * Build the XFree86-Misc extension
1160 */
1161#ifndef BuildXF86MiscExt
1162# define BuildXF86MiscExt		YES
1163#endif
1164
1165/*
1166 * Build the XFree86-Bigfont extension
1167 */
1168#ifndef BuildXF86BigfontExt
1169# define BuildXF86BigfontExt		YES
1170#endif
1171
1172/*
1173 * Build the XFree86 DGA support
1174 */
1175#ifndef BuildXF86DGA
1176# define BuildXF86DGA			YES
1177#endif
1178
1179/*
1180 * Build the DPMS extension support
1181 */
1182#ifndef BuildDPMSExt
1183# define BuildDPMSExt			YES
1184#endif
1185
1186/*
1187 * Build the X Video Extension
1188 */
1189#ifndef BuildXvExt
1190# define BuildXvExt			YES
1191#endif
1192
1193/*
1194 * Build the X Video Motion Compensation Extension
1195 */
1196#ifndef BuildXvMCExt
1197# define BuildXvMCExt			YES
1198#endif
1199
1200/*
1201 * Build the X-Resource Extension
1202 */
1203#ifndef BuildXResExt
1204# define BuildXResExt                   YES
1205#endif
1206
1207#if Malloc0ReturnsNull
1208# ifndef XtMalloc0ReturnsNullDefines
1209#  define XtMalloc0ReturnsNullDefines	Malloc0ReturnsNullDefines -DXTMALLOC_BC
1210# endif
1211#endif
1212
1213#ifndef UseInternalMalloc
1214# define UseInternalMalloc	NO
1215#endif
1216
1217#ifndef HasDlsymBug
1218# define HasDlsymBug		NO
1219#endif
1220
1221#ifndef HasMTRRSupport
1222# define HasMTRRSupport		NO
1223#endif
1224
1225/*
1226 * Build the font server
1227 */
1228#ifndef BuildFontServer
1229# define BuildFontServer	YES
1230#endif
1231
1232/*
1233 * Include fonts support
1234 */
1235#ifndef BuildSpeedo
1236# define BuildSpeedo		NO
1237#endif
1238
1239#ifndef BuildType1
1240# define BuildType1		NO
1241#endif
1242
1243#ifndef BuildCID
1244# define BuildCID		YES
1245#endif
1246
1247#ifndef BuildFreeType
1248# define BuildFreeType		YES
1249#endif
1250
1251/*
1252 * By default, build all of the fonts.
1253 */
1254#ifndef Build75DpiFonts
1255# define Build75DpiFonts	YES
1256#endif
1257#ifndef Build100DpiFonts
1258# define Build100DpiFonts	YES
1259#endif
1260#ifndef BuildSpeedoFonts
1261# define BuildSpeedoFonts	NO
1262#endif
1263#ifndef BuildType1Fonts
1264# define BuildType1Fonts	YES
1265#endif
1266#ifndef BuildCIDFonts
1267# define BuildCIDFonts		YES
1268#endif
1269#ifndef BuildTrueTypeFonts
1270# define BuildTrueTypeFonts	YES
1271#endif
1272#ifndef BuildCyrillicFonts
1273# define BuildCyrillicFonts	YES
1274#endif
1275
1276/*
1277 * Build scanpci?
1278 */
1279#ifndef SystemV
1280#define SystemV			NO
1281#endif
1282#ifndef SystemV4
1283#define SystemV4		NO
1284#endif
1285#ifndef BuildScanpci
1286# if SystemV || SystemV4 || \
1287    (defined(LinuxArchitecture) && !defined(Mc68020Architecture)) || \
1288    defined(i386BsdArchitecture) || defined(LynxOSArchitecture) || \
1289    defined(OS2Architecture) || defined(GNUMachArchitecture) || \
1290    (defined(KFreeBSDArchitecture) && defined(i386Architecture))
1291#   define BuildScanpci		YES
1292# else
1293#   define BuildScanpci		NO
1294# endif
1295#endif
1296
1297#ifndef CompressAllFonts
1298# define CompressAllFonts	YES
1299#endif
1300
1301#ifndef GzipFontCompression
1302# define GzipFontCompression	YES
1303#endif
1304
1305/* Disable stripping installed programs for this release. */
1306#ifndef StripInstalledPrograms
1307# define StripInstalledPrograms	NO
1308#endif
1309
1310#ifndef InstallJapaneseDocs
1311#define InstallJapaneseDocs	NO
1312#endif
1313
1314#if BuildXF86DGA
1315# define XFree86DGADefines	-DXFreeXDGA
1316#else
1317# define XFree86DGADefines	/**/
1318#endif
1319
1320#if BuildXvExt
1321# define XFree86XvDefines	-DXvExtension
1322#else
1323# define XFree86XvDefines	/**/
1324#endif
1325
1326#if BuildXvMCExt
1327# define XFree86XvMCDefines	-DXvMCExtension
1328#else
1329# define XFree86XvMCDefines	/**/
1330#endif
1331
1332#if BuildXResExt
1333# define XFree86XResDefines     -DXResExtension
1334#else
1335# define XFree86XResDefines     /**/
1336#endif
1337
1338#ifndef DlopenHack
1339# define DlopenHack		-DDLOPEN_HACK
1340#endif
1341
1342#ifndef ExtraLoaderDefines
1343# if MakeDllModules
1344#  define ExtraLoaderDefines	DlopenHack
1345# else
1346#  define ExtraLoaderDefines	/**/
1347# endif
1348#endif
1349
1350#if DoLoadableServer
1351# define XFree86LoaderDefines	-DXFree86LOADER ExtraLoaderDefines
1352#else
1353# define XFree86LoaderDefines	/**/
1354#endif
1355
1356#ifndef HasBsdMake
1357#define HasBsdMake		NO
1358#endif
1359
1360#ifndef MakeHasPosixVariableSubstitutions
1361# if !HasBsdMake && !defined(SunArchitecture)
1362#  define MakeHasPosixVariableSubstitutions	NO
1363# else
1364#  define MakeHasPosixVariableSubstitutions	YES
1365# endif
1366#endif
1367
1368#ifndef UseSmartScheduler
1369#define UseSmartScheduler YES
1370#endif
1371
1372#if UseSmartScheduler
1373#define SmartScheduleDefines -DSMART_SCHEDULE
1374#else
1375#define SmartScheduleDefines /**/
1376#endif
1377
1378/* Server defines required for all OSs */
1379#ifndef XFree86ServerDefines
1380# define XFree86ServerDefines	-DAVOID_GLYPHBLT -DPIXPRIV -DSINGLEDEPTH \
1381				XFree86DGADefines XFree86XvDefines \
1382				XFree86LoaderDefines -DXFree86Server \
1383				VidModeExtensionDefines \
1384				XFree86XvMCDefines \
1385				SmartScheduleDefines \
1386				DebugDefines XFree86XResDefines \
1387				-DX_BYTE_ORDER=$(X_BYTE_ORDER) \
1388				VersionDefines
1389#endif
1390
1391#ifndef XFree86ServerOSDefines
1392# define XFree86ServerOSDefines	-DDDXOSINIT -DSERVER_LOCK -DDDXOSFATALERROR \
1393				-DDDXOSVERRORF
1394#endif
1395
1396#ifndef XFree86ConsoleDefines
1397# if defined(i386BsdArchitecture) || defined(AlphaBsdArchitecture) || (defined(KFreeBSDArchitecture) && defined(i386Architecture))
1398#  define XFree86ConsoleDefines	-DPCCONS_SUPPORT -DSYSCONS_SUPPORT -DPCVT_SUPPORT
1399# elif defined(KFreeBSDArchitecture)
1400#  define XFree86ConsoleDefines -DSYSCONS_SUPPORT
1401# else
1402#  define XFree86ConsoleDefines	/**/
1403# endif
1404#endif
1405
1406/* Support for USB mouse */
1407#ifndef UsbMouseSupport
1408# define UsbMouseSupport NO
1409#endif
1410/* Does this OS have libusb ? */
1411#ifndef HasLibUsb
1412# define HasLibUsb	NO
1413#endif
1414
1415#ifndef UseServerLock
1416# define UseServerLock	YES
1417#endif
1418
1419#ifndef XnestServer
1420# define XnestServer		YES
1421#endif
1422#ifndef XVirtualFramebufferServer
1423# define XVirtualFramebufferServer	YES
1424#endif
1425
1426#ifndef ServerExtraDefines
1427# define ServerExtraDefines	XFree86ServerDefines
1428#endif
1429
1430#ifndef ServerOSDefines
1431# define ServerOSDefines	XFree86ServerOSDefines
1432#endif
1433
1434#ifndef DriverSDKDir
1435# define DriverSDKDir     $(USRLIBDIR)/Server
1436#endif
1437
1438#ifndef DriverSDKModuleDir
1439# define DriverSDKModuleDir     $(USRLIBDIR)/Server/modules
1440#endif
1441
1442#ifndef DriverSDKIncludeDir
1443# define DriverSDKIncludeDir     $(USRLIBDIR)/Server/include
1444#endif
1445
1446DRIVERSDKDIR = DriverSDKDir
1447DRIVERSDKMODULEDIR = DriverSDKModuleDir
1448DRIVERSDKINCLUDEDIR = DriverSDKIncludeDir
1449
1450/*
1451 * Some commonly refered to directories are defined here.
1452 */
1453
1454       XF86SRC = $(SERVERSRC)/hw/xfree86
1455    XF86COMSRC = $(XF86SRC)/common
1456 XF86PARSERSRC = $(XF86SRC)/parser
1457     XF86OSSRC = $(XF86SRC)/os-support
1458 XF86DRIVERSRC = $(XF86SRC)/drivers
1459     DRIVERSRC = $(XF86DRIVERSRC)
1460
1461/*
1462 * Installed location of the XFree86 documentation
1463 */
1464
1465        XFREE86DOCDIR = $(DOCDIR)
1466      XFREE86PSDOCDIR = $(DOCPSDIR)
1467     XFREE86PDFDOCDIR = $(DOCPDFDIR)
1468    XFREE86HTMLDOCDIR = $(DOCHTMLDIR)
1469XFREE86JAPANESEDOCDIR = $(DOCDIR)/Japanese
1470
1471/*
1472 * Other stuff used in the X Server source.
1473 */
1474
1475#ifndef OtherIConfigFiles
1476# define OtherIConfigFiles $(IRULESRC)/xfree86.cf $(IRULESRC)/xf86.rules
1477#endif
1478
1479#ifndef UseRgbTxt
1480# define UseRgbTxt	YES
1481#endif
1482
1483#ifndef ManSuffix
1484# define ManSuffix	1
1485#endif
1486
1487/*
1488 * GNU Compiler stuff
1489 */
1490#ifndef HasGcc3
1491# define HasGcc3 NO
1492#endif
1493#ifndef HasGcc2
1494# define HasGcc2 HasGcc3
1495#endif
1496#ifndef HasGcc
1497# define HasGcc HasGcc2
1498#endif
1499#ifndef HasGcc2ForCplusplus
1500# define HasGcc2ForCplusplus HasGcc2
1501#endif
1502
1503#if HasGcc
1504# ifndef Gcc28Warnings
1505#  if (GccMajorVersion > 2) || \
1506      ((GccMajorVersion == 2) && (GccMinorVersion >= 8))
1507#   define Gcc28Warnings -Wundef
1508#  else
1509#   define Gcc28Warnings /* */
1510#  endif
1511# ifndef HasGcc34
1512#  if (((GccMajorVersion == 3) && (GccMinorVersion >= 4)) ||	\
1513 	(GccMajorVersion > 3))
1514#   define HasGcc34 YES
1515#  else
1516#   define HasGcc34 NO
1517#  endif
1518# endif
1519# endif
1520# ifndef GccWarningOptions
1521#  if XFree86Devel
1522#   define GccWarningOptions -Wall -Wpointer-arith -Wstrict-prototypes \
1523			  -Wmissing-prototypes -Wmissing-declarations \
1524			  -Wredundant-decls -Wnested-externs Gcc28Warnings
1525#  else
1526#   define GccWarningOptions -Wall -Wpointer-arith Gcc28Warnings
1527#  endif
1528# endif
1529# ifndef DefaultCCOptions
1530#  if defined(UseInstalled)
1531#   define DefaultCCOptions /* -ansi */
1532#  else
1533#   define DefaultCCOptions -ansi GccWarningOptions
1534#  endif
1535# endif
1536# if defined(UseInstalled)
1537#  ifndef UseGccMakeDepend
1538#   define UseGccMakeDepend YES
1539#  endif
1540# endif
1541#endif
1542
1543/* Make imake noisier.  Note that this is ineffective for 3.0 <= GCC <= 3.2 */
1544#ifndef ImakeWarningFlags
1545# ifdef Gcc28Warnings
1546#  define ImakeWarningFlags Gcc28Warnings
1547# else
1548#  define ImakeWarningFlags /* */
1549# endif
1550#endif
1551
1552#if  ((GccMajorVersion == 3) &&  (GccMinorVersion >= 1)) || (GccMajorVersion > 3)
1553# define GccAliasingArgs      -fno-strict-aliasing
1554#else
1555# define GccAliasingArgs      /* */
1556#endif
1557
1558#if HasGcc2 && defined(i386Architecture)
1559# ifndef DefaultGcc2i386Opt
1560#  define DefaultGcc2i386Opt -O2 -fno-strength-reduce GccAliasingArgs
1561# endif
1562#endif
1563
1564#if HasGcc2 && defined(AArch64Architecture)
1565# ifndef DefaultGcc2AArch64Opt
1566#  define DefaultGcc2AArch64Opt -O2 GccAliasingArgs
1567# endif
1568#endif
1569
1570#if HasGcc2 && defined(AMD64Architecture)
1571# ifndef DefaultGcc2AMD64Opt
1572#  define DefaultGcc2AMD64Opt -O2 -fno-strength-reduce GccAliasingArgs
1573# endif
1574#endif
1575
1576#if HasGcc2 && defined(AlphaArchitecture)
1577# ifndef DefaultGcc2AxpOpt
1578#  define DefaultGcc2AxpOpt -O2 GccAliasingArgs
1579# endif
1580#endif
1581
1582#if HasGcc2 && defined(Ppc64Architecture)
1583# ifndef DefaultGcc2Ppc64Opt
1584#  define DefaultGcc2Ppc64Opt -O2 GccAliasingArgs
1585# endif
1586#endif
1587
1588#if HasGcc2 && defined(MipsArchitecture)
1589# ifndef DefaultGcc2MipsOpt
1590#  define DefaultGcc2MipsOpt -O2 GccAliasingArgs
1591# endif
1592#endif
1593
1594#if HasGcc2 && defined(OpenRISC1000Architecture)
1595# ifndef DefaultGcc2OpenRISC1000Opt
1596#  define DefaultGcc2OpenRISC1000Opt -O2 GccAliasingArgs
1597# endif
1598#endif
1599
1600#if HasGcc2 && defined(PpcArchitecture)
1601# ifndef DefaultGcc2PpcOpt
1602#  define DefaultGcc2PpcOpt -O2 GccAliasingArgs
1603# endif
1604#endif
1605
1606#ifndef DefaultGcc2DebugOpt
1607# define DefaultGcc2DebugOpt -g
1608#endif
1609
1610#ifndef DebuggableLibraries
1611# define DebuggableLibraries NO
1612#endif
1613
1614#if HasGcc2 && DebuggableLibraries
1615# define LibraryDebugOpt DefaultGcc2DebugOpt
1616#endif
1617
1618/*
1619 * Some versions of gcc have optimisation bugs that cause problems building
1620 * some files.  The definitions here cover those.
1621 */
1622
1623#ifndef Egcs112Bug
1624  /* Not exactly precise, but it'll do for now... */
1625# if HasGcc2 && defined(i386Architecture) && \
1626     (GccMajorVersion == 2) && (GccMinorVersion > 8)
1627#  define Egcs112Bug YES
1628# else
1629#  define Egcs112Bug NO
1630# endif
1631#endif
1632
1633#ifdef i386Architecture
1634# ifndef HasX86Support
1635#  define HasX86Support YES
1636# endif
1637# ifndef HasMMXSupport
1638#  define HasMMXSupport YES
1639# endif
1640# ifndef HasSSESupport
1641#  define HasSSESupport NO
1642# endif
1643# ifndef Has3DNowSupport
1644#  define Has3DNowSupport NO
1645# endif
1646#elif defined (AMD64Architecture)
1647# ifndef HasX86Support
1648#  define HasX86Support NO
1649# endif
1650# ifndef HasMMXSupport
1651#  define HasMMXSupport NO
1652# endif
1653# ifndef HasSSESupport
1654#  define HasSSESupport NO
1655# endif
1656# ifndef Has3DNowSupport
1657#  define Has3DNowSupport NO
1658# endif
1659#else
1660# ifndef HasX86Support
1661#  define HasX86Support NO
1662# endif
1663# ifndef HasMMXSupport
1664#  define HasMMXSupport NO
1665# endif
1666# ifndef HasSSESupport
1667#  define HasSSESupport NO
1668# endif
1669# ifndef Has3DNowSupport
1670#  define Has3DNowSupport NO
1671# endif
1672#endif
1673
1674#ifndef StaticNeedsPicForShared
1675# if defined (AMD64Architecture)\
1676  || defined (AlphaArchitecture) \
1677  || defined (ia64Architecture) \
1678  || defined (PpcArchitecture) \
1679  || defined (SparcArchitecture) \
1680  || defined (s390xArchitecture)
1681#  define StaticNeedsPicForShared YES
1682# else
1683#  define StaticNeedsPicForShared NO
1684# endif
1685#endif
1686
1687#if (defined(SparcArchitecture) || defined(Sparc64Architecture)) \
1688    && !defined(LargePositionIndependentCFlags) \
1689    && defined(HasGcc)
1690# define LargePositionIndependentCFlags -fPIC
1691#endif
1692
1693#ifndef XF8_32Wid
1694# define XF8_32Wid		NO
1695#endif
1696
1697#if CrossCompiling
1698#include <cross.def>
1699#endif
1700#include <xf86.rules>
1701
1702