• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#                                               -*- Autoconf -*-
2# Process this file with autoconf to produce a configure script.
3
4# Requires autoconf tool later than 2.61
5AC_PREREQ([2.61])
6# Initialize the omxvideo package version 1.0.0
7AC_INIT([omxvideo], 1.0.0)
8# Does not strictly follow GNU Coding standards
9AM_INIT_AUTOMAKE([gnu foreign subdir-objects])
10AM_MAINTAINER_MODE
11# defines some macros variable to be included by source
12AC_CONFIG_HEADER([config.h])
13AC_CONFIG_MACRO_DIR([m4])
14
15# Checks for programs.
16AM_PROG_AR
17AC_PROG_CC
18AC_PROG_CPP
19AC_PROG_CXX
20AM_PROG_CC_C_O
21AC_PROG_LIBTOOL
22AC_PROG_AWK
23AC_PROG_INSTALL
24AC_PROG_LN_S
25AC_PROG_MAKE_SET
26
27PKG_PROG_PKG_CONFIG
28
29AC_ARG_ENABLE([target-msm8953],
30        AC_HELP_STRING([--enable-target-msm8953],
31                [Enable conditional compile for target msm8953 [default=no]]),
32        [target_msm8953="${enableval}"])
33
34AC_ARG_ENABLE([target-msm8909],
35        AC_HELP_STRING([--enable-target-msm8909],
36                [Enable conditional compile for target msm8909 [default=no]]),
37        [target_msm8909="${enableval}"])
38
39AC_ARG_ENABLE([target-msm8996],
40        AC_HELP_STRING([--enable-target-msm8996],
41                [Enable conditional compile for target msm8996 [default=no]]),
42        [target_msm8996="${enableval}"])
43
44AC_ARG_ENABLE([target-msm8610],
45        AC_HELP_STRING([--enable-target-msm8610],
46                [Enable conditional compile for target msm8610 [default=no]]),
47        [target_msm8610="${enableval}"])
48
49AC_ARG_ENABLE([target-msm8226],
50        AC_HELP_STRING([--enable-target-msm8226],
51                [Enable conditional compile for target msm8610 [default=no]]),
52        [target_msm8226="${enableval}"])
53
54AC_ARG_ENABLE([target-msm8937],
55        AC_HELP_STRING([--enable-target-msm8937],
56                [Enable conditional compile for target msm8937 [default=no]]),
57        [target_msm8937="${enableval}"])
58
59AC_ARG_ENABLE([is-ubwc-supported],
60        AC_HELP_STRING([--enable-ubwc-supported],
61                [Enable conditional compile for target msm8953 [default=no]]),
62        [targets_that_support_ubwc="${enableval}"])
63
64AC_ARG_ENABLE([targets-that-support-pq],
65        AC_HELP_STRING([--enable-targets-that-support-pq],
66                [Enable conditional compile for target msm8953 [default=no]]),
67        [targets_that_support_pq="${enableval}"])
68
69AC_ARG_ENABLE([targets-that-support-vqzip],
70        AC_HELP_STRING([--enable-targets-that-support-vqzip],
71                [Enable conditional compile for target msm8953 [default=no]]),
72        [targets_that_support_vqzip="${enableval}"])
73
74AC_ARG_ENABLE([target-uses-ion],
75        AC_HELP_STRING([--enable-target-uses-ion],
76                [Enable conditional compile for target target-uses-ion [default=no]]),
77        [target_uses_ion="${enableval}"])
78
79AC_ARG_ENABLE([targets-that-use-flag-msm8226],
80        AC_HELP_STRING([--enable-targets-that-use-flag-msm8226],
81                [Enable conditional compile for target targets_that_use_flag_msm8226 [default=no]]),
82        [targets_that_use_flag_msm8226="${enableval}"])
83
84AC_ARG_ENABLE([target-uses-media-extensions],
85        AC_HELP_STRING([--enable-target-uses-media-extensions],
86                [Enable conditional compile for target target_uses_media_extensions [default=no]]),
87        [target_uses_media_extensions="${enableval}"])
88
89AC_ARG_ENABLE([master-side-cp-target-list],
90        AC_HELP_STRING([--enable-master-side-cp-target-list],
91                [Enable conditional compile for target master_side_cp_target_list [default=no]]),
92        [master_side_cp_target_list="${enableval}"])
93
94AC_ARG_ENABLE([targets-that-use-hevc-adsp-heap],
95        AC_HELP_STRING([-targets-that-use-hevc-adsp-heap],
96                [Enable conditional compile for target target-uses-ion [default=no]]),
97        [targets_that_use_hevc_adsp_heap="${enableval}"])
98
99AC_ARG_ENABLE([use-glib],
100        AC_HELP_STRING([--enable-use-glib],
101                [Enable conditional compile for use glib [default=no]]),
102        [use_glib="${enableval}"])
103
104AC_ARG_ENABLE([build-mm-video],
105        AC_HELP_STRING([--enable-use-glib],
106                [Enable conditional compile for use glib [default=no]]),
107        [build_mm_video="${enableval}"])
108
109AC_ARG_WITH([sanitized-headers],
110        [AS_HELP_STRING([--with-sanitized-headers=DIR],[location of the sanitized Linux kernel headers])],
111        [CPPFLAGS="$CPPFLAGS -I $withval"])
112
113AC_ARG_WITH([glib-headers],
114        [AS_HELP_STRING([--with-binder-inc=DIR],[location of common headers])],
115        [CPPFLAGS="$CPPFLAGS -I$withval"])
116
117AC_ARG_WITH([utils-headers],
118        [AS_HELP_STRING([--with-utils-inc=DIR],[location of common headers])],
119        [CPPFLAGS="$CPPFLAGS -I$withval"])
120
121AC_ARG_WITH([cutils-headers],
122        [AS_HELP_STRING([--with-cutils-inc=DIR],[location of common headers])],
123        [CPPFLAGS="$CPPFLAGS -I$withval"])
124
125AC_ARG_WITH([kernel-headers],
126        [AS_HELP_STRING([--with-kernel-inc=DIR],[location of common headers])],
127        [CPPFLAGS="$CPPFLAGS -I$withval"])
128
129AC_ARG_WITH([kernel-uapi-headers],
130        [AS_HELP_STRING([--with-kernel-uapi-inc=DIR],[location of common headers])],
131        [CPPFLAGS="$CPPFLAGS -I$withval"])
132
133AC_ARG_WITH([adreno-headers],
134        [AS_HELP_STRING([--with-adreno-inc=DIR],[location of common headers])],
135        [CPPFLAGS="$CPPFLAGS -I$withval"])
136
137AC_ARG_WITH([libgpustats-headers],
138        [AS_HELP_STRING([--with-libgpustats-headers=DIR],[location of common headers])],
139        [CPPFLAGS="$CPPFLAGS -I$withval"])
140
141AC_ARG_WITH([libpqstats-headers],
142        [AS_HELP_STRING([--with-libpqstats-headers=DIR],[location of common headers])],
143        [CPPFLAGS="$CPPFLAGS -I$withval"])
144
145AC_ARG_WITH([ui-headers],
146        [AS_HELP_STRING([--with-ui-inc=DIR],[location of common headers])],
147        [CPPFLAGS="$CPPFLAGS -I$withval"])
148
149AC_ARG_WITH([android-headers],
150        [AS_HELP_STRING([--with-gralloc-inc=DIR],[location of common headers])],
151        [CPPFLAGS="$CPPFLAGS -I$withval"])
152
153AC_ARG_WITH([gralloc-headers],
154        [AS_HELP_STRING([--with-strcpyincludes-inc=DIR],[location of common headers])],
155        [CPPFLAGS="$CPPFLAGS -I$withval"])
156
157AC_ARG_WITH([binder-headers],
158        [AS_HELP_STRING([--with-binder-inc=DIR],[location of common headers])],
159        [CPPFLAGS="$CPPFLAGS -I$withval"])
160
161AC_ARG_WITH([display-headers],
162        [AS_HELP_STRING([--with-binder-inc=DIR],[location of common headers])],
163        [CPPFLAGS="$CPPFLAGS -I$withval"])
164
165AC_ARG_WITH([qdutils-headers],
166        [AS_HELP_STRING([--with-binder-inc=DIR],[location of common headers])],
167        [CPPFLAGS="$CPPFLAGS -I$withval"])
168
169AC_ARG_WITH([glib-lib-dir],
170        [AS_HELP_STRING([--with-binder-inc=DIR],[location of common headers])],
171        [CPPFLAGS="$CPPFLAGS -I$withval"])
172
173AM_CONDITIONAL(TARGET_MSM8953, [test "x$target_msm8953" = "xyes"])
174AM_CONDITIONAL(TARGET_MSM8909, [test "x$target_msm8909" = "xyes"])
175AM_CONDITIONAL(TARGET_MSM8996, [test "x$target_msm8996" = "xyes"])
176AM_CONDITIONAL(TARGET_MSM8610, [test "x$target_msm8610" = "xyes"])
177AM_CONDITIONAL(TARGET_MSM8226, [test "x$target_msm8226" = "xyes"])
178AM_CONDITIONAL(TARGET_MSM8937, [test "x$target_msm8937" = "xyes"])
179AM_CONDITIONAL(TARGETS_THAT_SUPPORT_UBWC, [test "x$targets_that_support_ubwc" = "xyes"])
180AM_CONDITIONAL(TARGETS_THAT_SUPPORT_PQ, [test "x$targets_that_support_pq" = "xyes"])
181AM_CONDITIONAL(TARGETS_THAT_SUPPORT_VQZIP, [test "x$targets_that_support_vqzip" = "xyes"])
182AM_CONDITIONAL(TARGET_USES_ION, [test "x$target_uses_ion" = "xyes"])
183AM_CONDITIONAL(TARGETS_THAT_USE_FLAG_MSM8226, [test "x$targets_that_use_flag_msm8226" = "xyes"])
184AM_CONDITIONAL(TARGET_USES_MEDIA_EXTENSIONS, [test "x$target_uses_media_extensions" = "xyes"])
185AM_CONDITIONAL(MASTER_SIDE_CP_TARGET_LIST, [test "x$master_side_cp_target_list" = "xyes"])
186AM_CONDITIONAL(USE_GLIB, [test "x$use_glib" = "xyes"])
187AM_CONDITIONAL(BUILD_MM_VIDEO, [test "x$build_mm_video" = "xyes"])
188
189AC_ARG_WITH([glib],
190      AC_HELP_STRING([--with-glib],
191         [enable glib, building HLOS systems which use glib]))
192
193if (test "x${with_glib}" = "xyes"); then
194        GLIB_CFLAGS="$GLIB_CFLAGS $GTHREAD_CFLAGS"
195        GLIB_LIBS="$GLIB_LIBS $GTHREAD_LIBS"
196
197        AC_SUBST(GLIB_CFLAGS)
198        AC_SUBST(GLIB_LIBS)
199fi
200
201AC_SUBST([CPPFLAGS])
202AC_SUBST([CFLAGS])
203
204AC_CONFIG_FILES([ \
205        Makefile \
206        mm-core/Makefile
207        mm-video-v4l2/Makefile \
208        mm-video-v4l2/vidc/Makefile \
209        mm-video-v4l2/vidc/venc/Makefile \
210        mm-video-v4l2/vidc/vdec/Makefile \
211        ])
212AC_OUTPUT
213