OSDN Git Service

Skl: Add the initial support for rendering on Skl
[android-x86/hardware-intel-common-vaapi.git] / src / Makefile.am
1 # Copyright (c) 2007 Intel Corporation. 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
5 # "Software"), to deal in the Software without restriction, including
6 # without limitation the rights to use, copy, modify, merge, publish,
7 # distribute, sub license, and/or sell copies of the Software, and to
8 # permit persons to whom the Software is furnished to do so, subject to
9 # the following conditions:
10
11 # The above copyright notice and this permission notice (including the
12 # next paragraph) shall be included in all copies or substantial portions
13 # of the Software.
14
15 # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
16 # OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17 # MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
18 # IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
19 # ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
20 # TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
21 # SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
22
23 SUBDIRS         = shaders
24 DIST_SUBDIRS    = $(SUBDIRS)
25 EXTRA_DIST      =
26 BUILT_SOURCES   =
27
28 AM_CPPFLAGS = \
29         -DPTHREADS              \
30         $(DRM_CFLAGS)           \
31         $(LIBVA_DEPS_CFLAGS)    \
32         $(NULL)
33
34 driver_cflags = \
35         -Wall                   \
36         -fvisibility=hidden     \
37         $(NULL)
38
39 driver_ldflags = \
40         -module -avoid-version  \
41         -no-undefined           \
42         -Wl,--no-undefined      \
43         $(NULL)
44
45 driver_libs = \
46         -lpthread -lm -ldl      \
47         $(DRM_LIBS) -ldrm_intel \
48         $(NULL)
49
50 source_c = \
51         dso_utils.c             \
52         gen6_mfc.c              \
53         gen6_mfc_common.c       \
54         gen6_mfd.c              \
55         gen6_vme.c              \
56         gen7_vme.c              \
57         gen7_mfc.c              \
58         gen7_mfd.c              \
59         gen75_mfd.c             \
60         gen75_mfc.c             \
61         gen8_mfc.c              \
62         gen8_mfd.c              \
63         gen8_vme.c              \
64         gen75_picture_process.c \
65         gen75_vme.c             \
66         gen75_vpp_gpe.c         \
67         gen75_vpp_vebox.c       \
68         i965_avc_bsd.c          \
69         i965_avc_hw_scoreboard.c\
70         i965_avc_ildb.c         \
71         i965_decoder_utils.c    \
72         i965_device_info.c      \
73         i965_drv_video.c        \
74         i965_encoder.c          \
75         i965_encoder_utils.c    \
76         i965_media.c            \
77         i965_media_h264.c       \
78         i965_media_mpeg2.c      \
79         i965_gpe_utils.c        \
80         i965_post_processing.c  \
81         gen8_post_processing.c  \
82         i965_render.c           \
83         i965_vpp_avs.c          \
84         gen8_render.c           \
85         gen9_render.c           \
86         intel_batchbuffer.c     \
87         intel_batchbuffer_dump.c\
88         intel_driver.c          \
89         intel_memman.c          \
90         object_heap.c           \
91         intel_media_common.c            \
92         $(NULL)
93
94 source_h = \
95         dso_utils.h             \
96         gen6_mfc.h              \
97         gen6_mfd.h              \
98         gen6_vme.h              \
99         gen7_mfd.h              \
100         gen75_picture_process.h \
101         gen75_vpp_gpe.h         \
102         gen75_vpp_vebox.h       \
103         i965_avc_bsd.h          \
104         i965_avc_hw_scoreboard.h\
105         i965_avc_ildb.h         \
106         i965_decoder.h          \
107         i965_decoder_utils.h    \
108         i965_defines.h          \
109         i965_drv_video.h        \
110         i965_encoder.h          \
111         i965_encoder_utils.h    \
112         i965_media.h            \
113         i965_media_h264.h       \
114         i965_media_mpeg2.h      \
115         i965_mutext.h           \
116         i965_gpe_utils.h        \
117         i965_pciids.h           \
118         i965_post_processing.h  \
119         i965_render.h           \
120         i965_structs.h          \
121         i965_vpp_avs.h          \
122         intel_batchbuffer.h     \
123         intel_batchbuffer_dump.h\
124         intel_compiler.h        \
125         intel_driver.h          \
126         intel_media.h           \
127         intel_memman.h          \
128         intel_version.h         \
129         object_heap.h           \
130         sysdeps.h               \
131         va_backend_compat.h     \
132         i965_fourcc.h           \
133         $(NULL)
134
135 i965_drv_video_la_LTLIBRARIES   = i965_drv_video.la
136 i965_drv_video_ladir            = $(LIBVA_DRIVERS_PATH)
137 i965_drv_video_la_CFLAGS        = $(driver_cflags)
138 i965_drv_video_la_LDFLAGS       = $(driver_ldflags)
139 i965_drv_video_la_LIBADD        = $(driver_libs)
140 i965_drv_video_la_SOURCES       = $(source_c)
141 noinst_HEADERS                  = $(source_h)
142
143 if USE_X11
144 source_c                        += i965_output_dri.c
145 source_h                        += i965_output_dri.h
146 endif
147
148 if USE_WAYLAND
149 source_c                        += i965_output_wayland.c
150 source_h                        += i965_output_wayland.h
151 source_h                        += $(protocol_source_h)
152 driver_cflags                   += $(WAYLAND_CFLAGS)
153 endif
154
155 # git version
156 VERSION_FILE                    = .VERSION
157 OLD_VERSION_FILE                = $(VERSION_FILE).old
158 NEW_VERSION_FILE                = $(VERSION_FILE).new
159 PKG_VERSION_FILE                = $(VERSION_FILE).pkg
160
161 intel_version.h: gen-version
162         $(AM_V_GEN)                                                      \
163         OV=`[ -f $(OLD_VERSION_FILE) ] && cat $(OLD_VERSION_FILE) || :`; \
164         NV=`cat $(NEW_VERSION_FILE)`;                                    \
165         if [ "$$OV" != "$$NV" -o ! -f intel_version.h ]; then            \
166                 cp -f $(NEW_VERSION_FILE) $(OLD_VERSION_FILE);           \
167                 $(SED) -e "s|\@INTEL_DRIVER_GIT_VERSION\@|$${NV}|"       \
168                         $(srcdir)/intel_version.h.in > intel_version.h;  \
169         fi
170
171 gen-version:
172         @echo $(VERSION) > $(NEW_VERSION_FILE)
173 if HAVE_GIT
174         @[ -d $(top_srcdir)/.git ] && \
175         (cd $(top_srcdir) && $(GIT) describe --tags) > $(NEW_VERSION_FILE) || :
176 endif
177         @[ -f $(srcdir)/$(PKG_VERSION_FILE) ] && \
178         cp -f $(srcdir)/$(PKG_VERSION_FILE) $(NEW_VERSION_FILE) || :
179
180 $(PKG_VERSION_FILE): $(NEW_VERSION_FILE)
181         @cp -f $< $@
182
183 BUILT_SOURCES   += intel_version.h
184 EXTRA_DIST      += intel_version.h.in $(PKG_VERSION_FILE)
185
186 # Wayland protocol
187 protocol_source_h = wayland-drm-client-protocol.h
188 i965_output_wayland.c: $(protocol_source_h)
189 @wayland_scanner_rules@
190
191 DIST_SUBDIRS    += wayland
192
193 # Extra clean files so that maintainer-clean removes *everything*
194 MAINTAINERCLEANFILES = Makefile.in config.h.in