Imported Upstream version 1.15.1
[deb_xorg-server.git] / hw / xfree86 / Makefile.am
CommitLineData
a09e091a
JB
1
2if DRI
3DRI_SUBDIR = dri
4DRI_LIB = dri/libdri.la
5endif
6
7if DRI2
8DRI2_SUBDIR = dri2
9DRI2_LIB = dri2/libdri2.la
10endif
11
12if DRI3
13DRI3_BUILDDIR = $(top_builddir)/dri3
14DRI3_LIB = $(DRI3_BUILDDIR)/libdri3.la
15endif
16
17if XF86UTILS
18XF86UTILS_SUBDIR = utils
19endif
20
21if VGAHW
22VGAHW_SUBDIR = vgahw
23endif
24
25if VBE
26VBE_SUBDIR = vbe
27endif
28
29if INT10MODULE
30INT10_SUBDIR = int10
31endif
32
33SUBDIRS = common ddc x86emu $(INT10_SUBDIR) os-support parser \
34 ramdac $(VGAHW_SUBDIR) loader modes $(DRI_SUBDIR) \
35 $(DRI2_SUBDIR) . $(VBE_SUBDIR) i2c dixmods \
36 fbdevhw shadowfb exa $(XF86UTILS_SUBDIR) doc man
37
38DIST_SUBDIRS = common ddc i2c x86emu int10 fbdevhw os-support \
39 parser ramdac shadowfb vbe vgahw \
40 loader dixmods dri dri2 exa modes \
41 utils doc man
42
43bin_PROGRAMS = Xorg
44nodist_Xorg_SOURCES = sdksyms.c
45
46AM_CFLAGS = $(DIX_CFLAGS) @XORG_CFLAGS@
47AM_CPPFLAGS = $(XORG_INCS) -I$(srcdir)/parser -I$(top_srcdir)/miext/cw \
48 -I$(srcdir)/ddc -I$(srcdir)/i2c -I$(srcdir)/modes -I$(srcdir)/ramdac \
49 -I$(srcdir)/dri -I$(srcdir)/dri2 -I$(top_srcdir)/dri3
50
51LOCAL_LIBS = \
52 $(MAIN_LIB) \
53 $(XSERVER_LIBS) \
54 loader/libloader.la \
55 common/libcommon.la \
56 os-support/libxorgos.la \
57 parser/libxf86config_internal.la \
58 dixmods/libdixmods.la \
59 modes/libxf86modes.la \
60 ramdac/libramdac.la \
61 ddc/libddc.la \
62 i2c/libi2c.la \
63 $(XORG_LIBS) \
64 dixmods/libxorgxkb.la \
65 $(DRI_LIB) \
66 $(DRI2_LIB) \
67 $(DRI3_LIB) \
68 $(top_builddir)/miext/sync/libsync.la \
69 $(top_builddir)/mi/libmi.la \
70 $(top_builddir)/os/libos.la
71Xorg_LDADD = \
72 $(LOCAL_LIBS) \
73 $(XORG_SYS_LIBS) \
74 $(XSERVER_SYS_LIBS)
75Xorg_DEPENDENCIES = $(LOCAL_LIBS)
76
77Xorg_LDFLAGS = $(LD_EXPORT_SYMBOLS_FLAG)
78
79BUILT_SOURCES = xorg.conf.example
80DISTCLEANFILES = xorg.conf.example
81EXTRA_DIST = xorgconf.cpp
82
83# Without logdir, X will post an error on the terminal and will not start
84install-data-local:
85 $(AM_V_GEN)$(MKDIR_P) $(DESTDIR)$(logdir)
86if CYGWIN
87 $(INSTALL_DATA) libXorg.exe.a $(DESTDIR)$(libdir)/libXorg.exe.a
88endif
89
90install-exec-hook:
91 (cd $(DESTDIR)$(bindir) && rm -f X && $(LN_S) Xorg$(EXEEXT) X)
92if INSTALL_SETUID
93 chown root $(DESTDIR)$(bindir)/Xorg
94 chmod u+s $(DESTDIR)$(bindir)/Xorg
95endif
96
97uninstall-local:
98if CYGWIN
99 $(AM_V_at)rm -f $(DESTDIR)$(libdir)/libXorg.exe.a
100endif
101
102uninstall-hook:
103 $(AM_V_at)rm -f $(DESTDIR)$(bindir)/X
104
105# Use variables from XORG_MANPAGE_SECTIONS and X Server configuration
106# Do not include manpages.am as values are not appropriate for rc files
107CONF_SUBSTS = -e 's|__filemansuffix__|$(FILE_MAN_SUFFIX)|g' \
108 -e 's|MODULEPATH|$(DEFAULT_MODULE_PATH)|g' \
109 -e 's|DEFAULTFONTPATH|$(COMPILEDDEFAULTFONTPATH)|g'
110
111xorg.conf.example: xorgconf.cpp
112 $(AM_V_GEN)$(SED) $(CONF_SUBSTS) < $(srcdir)/xorgconf.cpp > $@
113
114relink:
115 $(AM_V_at)rm -f Xorg$(EXEEXT) && $(MAKE) Xorg$(EXEEXT)
116
117CLEANFILES = sdksyms.c sdksyms.dep
118EXTRA_DIST += sdksyms.sh
119
120sdksyms.dep sdksyms.c: sdksyms.sh
121 $(AM_V_GEN)CPP='$(CPP)' AWK='$(AWK)' $(SHELL) $(srcdir)/sdksyms.sh $(top_srcdir) $(CFLAGS) $(AM_CFLAGS) $(AM_CPPFLAGS)
122
123SDKSYMS_DEP = sdksyms.dep
124include $(SDKSYMS_DEP)
125
126i2c/libi2c.la:
127 $(AM_V_at)cd i2c && $(MAKE) libi2c.la
128
129dixmods/libdixmods.la:
130 $(AM_V_at)cd dixmods && $(MAKE) libdixmods.la
131
132dixmods/libxorgxkb.la:
133 $(AM_V_at)cd dixmods && $(MAKE) libxorgxkb.la