OSDN Git Service

glx: implement GLX part of interop interface (v2)
[android-x86/external-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 if HAVE_SHARED_GLAPI
23 SHARED_GLAPI_CFLAGS = -DGLX_SHARED_GLAPI
24 SHARED_GLAPI_LIB = $(top_builddir)/src/mapi/shared-glapi/libglapi.la
25 endif
26
27 SUBDIRS =
28
29 EXTRA_DIST = SConscript
30
31 if HAVE_XF86VIDMODE
32 EXTRA_DEFINES_XF86VIDMODE = -DXF86VIDMODE
33 endif
34
35 AM_CFLAGS = \
36         -I$(top_srcdir)/include \
37         -I$(top_srcdir)/include/GL/internal \
38         -I$(top_srcdir)/src \
39         -I$(top_srcdir)/src/loader \
40         -I$(top_srcdir)/src/mapi \
41         -I$(top_srcdir)/src/mapi/glapi \
42         -I$(top_builddir)/src/mapi \
43         -I$(top_builddir)/src/mapi/glapi \
44         $(VISIBILITY_CFLAGS) \
45         $(SHARED_GLAPI_CFLAGS) \
46         $(EXTRA_DEFINES_XF86VIDMODE) \
47         -D_REENTRANT \
48         -DDEFAULT_DRIVER_DIR=\"$(DRI_DRIVER_SEARCH_DIR)\" \
49         -DGL_LIB_NAME=\"lib@GL_LIB@.so.1\" \
50         $(DEFINES) \
51         $(LIBDRM_CFLAGS) \
52         $(DRI2PROTO_CFLAGS) \
53         $(GLPROTO_CFLAGS) \
54         $(X11_INCLUDES)
55
56 lib_LTLIBRARIES = lib@GL_LIB@.la
57
58 noinst_LTLIBRARIES = libglx.la
59
60 libglx_la_SOURCES = \
61         clientattrib.c \
62         clientinfo.c \
63         compsize.c \
64         create_context.c \
65         eval.c \
66         glxclient.h \
67         glxcmds.c \
68         glxconfig.c \
69         glxconfig.h \
70         glxcurrent.c \
71         glx_error.c \
72         glx_error.h \
73         glxext.c \
74         glxextensions.c \
75         glxextensions.h \
76         glxhash.c \
77         glxhash.h \
78         glx_pbuffer.c \
79         glx_query.c \
80         indirect.c \
81         indirect_glx.c \
82         indirect_init.c \
83         indirect_init.h \
84         indirect_size.c \
85         indirect_texture_compression.c \
86         indirect_transpose_matrix.c \
87         indirect_vertex_array.c \
88         indirect_vertex_array.h \
89         indirect_vertex_array_priv.h \
90         indirect_vertex_program.c \
91         indirect_window_pos.c \
92         packrender.h \
93         packsingle.h \
94         pixel.c \
95         pixelstore.c \
96         query_renderer.c \
97         render2.c \
98         renderpix.c \
99         single2.c \
100         singlepix.c \
101         vertarr.c
102
103 libglx_la_LIBADD = $(top_builddir)/src/loader/libloader.la
104
105 if HAVE_DRISW
106 libglx_la_SOURCES += \
107         drisw_glx.c \
108         drisw_priv.h
109 endif
110
111 if HAVE_DRICOMMON
112 libglx_la_SOURCES += \
113         dri_common.c \
114         dri_common.h \
115         dri_common_query_renderer.c \
116         dri_common_interop.c \
117         xfont.c
118 endif
119
120 if HAVE_DRI2
121 libglx_la_SOURCES += \
122         dri2.c \
123         dri2_glx.c \
124         dri2.h \
125         dri2_priv.h \
126         dri_glx.c \
127         dri_sarea.h \
128         XF86dri.c \
129         xf86dri.h \
130         xf86dristr.h
131 endif
132
133 if HAVE_DRI3
134 libglx_la_SOURCES += \
135         dri3_glx.c \
136         dri3_priv.h
137
138 libglx_la_LIBADD += $(top_builddir)/src/loader/libloader_dri3_helper.la
139 endif
140
141 if HAVE_APPLEDRI
142 libglx_la_SOURCES += \
143         applegl_glx.c
144
145 SUBDIRS += apple
146 libglx_la_LIBADD += $(builddir)/apple/libappleglx.la
147 endif
148
149 GL_LIBS = \
150         libglx.la \
151         $(top_builddir)/src/mapi/glapi/libglapi.la \
152         $(SHARED_GLAPI_LIB) \
153         $(GL_LIB_DEPS)
154
155 GL_LDFLAGS = \
156         -no-undefined \
157         -version-number 1:2 \
158         $(BSYMBOLIC) \
159         $(GC_SECTIONS) \
160         $(LD_NO_UNDEFINED)
161
162 lib@GL_LIB@_la_SOURCES =
163 lib@GL_LIB@_la_LIBADD = $(GL_LIBS)
164 lib@GL_LIB@_la_LDFLAGS = $(GL_LDFLAGS)
165
166 SUBDIRS += . tests
167
168 include $(top_srcdir)/install-lib-links.mk