apple/glx/log: added missing va_end() after va_copy()
[mesa.git] / src / glx / Makefile.am
1 # Copyright © 2012 Intel Corporation
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 DEALINGS
20 # IN THE SOFTWARE.
21
22
23 SUBDIRS =
24
25 EXTRA_DIST = SConscript meson.build
26
27 if HAVE_XF86VIDMODE
28 EXTRA_DEFINES_XF86VIDMODE = -DXF86VIDMODE
29 endif
30
31 AM_CFLAGS = \
32 -I$(top_srcdir)/include \
33 -I$(top_srcdir)/include/GL/internal \
34 -I$(top_srcdir)/src \
35 -I$(top_srcdir)/src/loader \
36 -I$(top_builddir)/src/mapi \
37 -I$(top_srcdir)/src/mapi \
38 -I$(top_builddir)/src/mapi/glapi \
39 -I$(top_srcdir)/src/mapi/glapi \
40 $(VISIBILITY_CFLAGS) \
41 $(EXTRA_DEFINES_XF86VIDMODE) \
42 -D_REENTRANT \
43 -DDEFAULT_DRIVER_DIR=\"$(DRI_DRIVER_SEARCH_DIR)\" \
44 $(DEFINES) \
45 $(LIBDRM_CFLAGS) \
46 $(DRI2PROTO_CFLAGS) \
47 $(GLPROTO_CFLAGS) \
48 $(X11_INCLUDES)
49
50 lib_LTLIBRARIES = lib@GL_LIB@.la
51
52 noinst_LTLIBRARIES = libglx.la
53
54 libglx_la_SOURCES = \
55 clientattrib.c \
56 clientinfo.c \
57 compsize.c \
58 create_context.c \
59 eval.c \
60 glxclient.h \
61 glxcmds.c \
62 glxconfig.c \
63 glxconfig.h \
64 glxcurrent.c \
65 glx_error.c \
66 glx_error.h \
67 glxext.c \
68 glxextensions.c \
69 glxextensions.h \
70 glxhash.c \
71 glxhash.h \
72 glx_pbuffer.c \
73 glx_query.c \
74 indirect.c \
75 indirect_glx.c \
76 indirect_init.c \
77 indirect_init.h \
78 indirect_size.c \
79 indirect_texture_compression.c \
80 indirect_transpose_matrix.c \
81 indirect_vertex_array.c \
82 indirect_vertex_array.h \
83 indirect_vertex_array_priv.h \
84 indirect_vertex_program.c \
85 indirect_window_pos.c \
86 packrender.h \
87 packsingle.h \
88 pixel.c \
89 pixelstore.c \
90 query_renderer.c \
91 render2.c \
92 renderpix.c \
93 single2.c \
94 singlepix.c \
95 vertarr.c
96
97 libglx_la_LIBADD = \
98 $(top_builddir)/src/loader/libloader.la \
99 $(top_builddir)/src/util/libmesautil.la \
100 $(top_builddir)/src/util/libxmlconfig.la
101
102 if HAVE_DRISW
103 libglx_la_SOURCES += \
104 drisw_glx.c \
105 drisw_priv.h
106 endif
107
108 if HAVE_DRICOMMON
109 libglx_la_SOURCES += \
110 dri_common.c \
111 dri_common.h \
112 dri_common_query_renderer.c \
113 dri_common_interop.c \
114 xfont.c
115 endif
116
117 if HAVE_DRI2
118 libglx_la_SOURCES += \
119 dri2.c \
120 dri2_glx.c \
121 dri2.h \
122 dri2_priv.h \
123 dri_glx.c \
124 dri_sarea.h \
125 XF86dri.c \
126 xf86dri.h \
127 xf86dristr.h
128 endif
129
130 if HAVE_DRI3
131 libglx_la_SOURCES += \
132 dri3_glx.c \
133 dri3_priv.h
134
135 libglx_la_LIBADD += $(top_builddir)/src/loader/libloader_dri3_helper.la
136 endif
137
138 if HAVE_APPLEDRI
139 libglx_la_SOURCES += \
140 applegl_glx.c
141
142 SUBDIRS += apple
143 libglx_la_LIBADD += $(builddir)/apple/libappleglx.la
144 endif
145
146 if HAVE_WINDOWSDRI
147 libglx_la_SOURCES += \
148 driwindows_glx.c
149
150 SUBDIRS += windows
151 libglx_la_LIBADD += \
152 $(builddir)/windows/libwindowsdri.la \
153 $(builddir)/windows/libwindowsglx.la
154 endif
155
156 if USE_LIBGLVND
157 AM_CFLAGS += \
158 -DGL_LIB_NAME=\"lib@GL_LIB@.so.0\" \
159 $(GLVND_CFLAGS)
160
161 libglx_la_SOURCES += \
162 g_glxglvnddispatchfuncs.c \
163 g_glxglvnddispatchindices.h \
164 glxglvnd.c \
165 glxglvnd.h \
166 glxglvnddispatchfuncs.h
167
168 GL_LIB_VERSION=0
169 else
170 AM_CFLAGS += \
171 -DGL_LIB_NAME=\"lib@GL_LIB@.so.1\"
172 GL_LIB_VERSION=1:2
173 endif
174
175 # Push the libdrm furhter up, as due to libtool bug we might end up relinking
176 # against the system one.
177 GL_LIBS = \
178 $(LIBDRM_LIBS) \
179 libglx.la \
180 $(top_builddir)/src/mapi/glapi/libglapi.la \
181 $(top_builddir)/src/mapi/shared-glapi/libglapi.la \
182 $(GL_LIB_DEPS)
183
184 GL_LDFLAGS = \
185 -no-undefined \
186 -version-number $(GL_LIB_VERSION) \
187 $(BSYMBOLIC) \
188 $(GC_SECTIONS) \
189 $(LD_NO_UNDEFINED)
190
191 lib@GL_LIB@_la_SOURCES =
192 lib@GL_LIB@_la_LIBADD = $(GL_LIBS)
193 lib@GL_LIB@_la_LDFLAGS = $(GL_LDFLAGS)
194
195 if HAVE_WINDOWSDRI
196 lib@GL_LIB@_la_LDFLAGS += -lgdi32 -lopengl32 -Wl,--disable-stdcall-fixup
197 endif
198
199 SUBDIRS += . tests
200
201 include $(top_srcdir)/install-lib-links.mk