(ChangeableColor) ColorController interface and its dummy implementation
[platform/core/uifw/dali-adaptor.git] / build / tizen / configure.ac
1 #
2 # Copyright (c) 2014 Samsung Electronics Co., Ltd.
3 #
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
7 #
8 # http://www.apache.org/licenses/LICENSE-2.0
9 #
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 #
16
17 m4_define([dali_version],[0.1.0])
18 AC_INIT([dali], [dali_version])
19 AM_INIT_AUTOMAKE([-Wall foreign])
20
21 AC_PROG_CXX
22 AC_PROG_LIBTOOL
23 AC_PROG_MKDIR_P
24
25 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
26
27 LT_INIT
28
29 DALI_ADAPTOR_VERSION=dali_version
30 AC_SUBST(DALI_ADAPTOR_VERSION)
31
32 FREETYPE_REQUIRED=9.16.3
33
34 PKG_CHECK_MODULES(CAPI_APPFW_APPLICATION, capi-appfw-application)
35 PKG_CHECK_MODULES(DALICORE, dali-core)
36 PKG_CHECK_MODULES(DLOG, dlog)
37 PKG_CHECK_MODULES(ELEMENTARY, elementary)
38 PKG_CHECK_MODULES(ECORE, ecore)
39 PKG_CHECK_MODULES(ECORE_X, ecore-x)
40 PKG_CHECK_MODULES(ECORE_IPC, ecore-ipc)
41 PKG_CHECK_MODULES(EXIF, libexif)
42 PKG_CHECK_MODULES(FREETYPE, [freetype2 >= $FREETYPE_REQUIRED])
43 PKG_CHECK_MODULES(FEEDBACK, feedback)
44 PKG_CHECK_MODULES(FONTCONFIG, fontconfig)
45 PKG_CHECK_MODULES(MMFSOUND, mm-sound)
46 PKG_CHECK_MODULES(PNG, libpng)
47 PKG_CHECK_MODULES(SENSOR, sensor)
48 PKG_CHECK_MODULES(TTS, tts)
49 PKG_CHECK_MODULES(VCONF, vconf)
50 PKG_CHECK_MODULES(X11, x11)
51 PKG_CHECK_MODULES(XML, libxml-2.0)
52 PKG_CHECK_MODULES(LIBDRM, libdrm)
53 PKG_CHECK_MODULES(LIBEXIF, libexif)
54 PKG_CHECK_MODULES(CAPI_SYSTEM_SYSTEM_SETTINGS, capi-system-system-settings)
55 PKG_CHECK_MODULES(EFL_ASSIST, efl-assist)
56
57 # Check for availability of BulletPhysics
58 PKG_CHECK_EXISTS(bullet, [
59   BULLET_CFLAGS=`pkg-config --cflags bullet`
60   BULLET_LIBS=`pkg-config --libs bullet`
61   BULLET=yes
62 ], [
63   AC_MSG_WARN([BulletPhysics development files not found, not building bullet plugin])
64   BULLET_CFLAGS=
65   BULLET_LIBS=
66   BULLET=no
67 ])
68
69 AC_SUBST(BULLET_CFLAGS)
70 AC_SUBST(BULLET_LIBS)
71 AM_CONDITIONAL([USE_BULLET], [test x$BULLET = xyes])
72
73 DALI_ADAPTOR_CFLAGS=-DPLATFORM_SLP
74
75 AC_ARG_ENABLE(exportall,
76               [AC_HELP_STRING([--enable-exportall],
77                               [enables the exporting of all the symbols in the library])],
78               [enable_exportall=yes],
79               [enable_exportall=no])
80
81 AC_ARG_ENABLE([debug],
82               [AC_HELP_STRING([--enable-debug],
83                               [Turns on debugging])],
84               [enable_debug=$enableval],
85               [enable_debug=no])
86
87 if test "x$enable_debug" = "xyes"; then
88   DALI_ADAPTOR_CFLAGS="$DALI_ADAPTOR_CFLAGS -DDEBUG_ENABLED"
89 fi
90
91 if test "x$enable_debug" = "xno" -a "x$enable_exportall" = "xno"; then
92   DALI_ADAPTOR_CFLAGS="$DALI_ADAPTOR_CFLAGS -fvisibility=hidden -DHIDE_DALI_INTERNALS"
93 fi
94
95 AC_ARG_ENABLE([gles],
96               [AC_HELP_STRING([--enable-gles],
97                               [Specify the OpenGL ES version for backwards compatibility])],
98               [enable_gles=$enableval],
99               [enable_gles=30])
100
101 DALI_ADAPTOR_CFLAGS="$DALI_ADAPTOR_CFLAGS -DDALI_GLES_VERSION=${enable_gles}"
102
103 AC_ARG_WITH([jpeg-turbo],
104             [AC_HELP_STRING([--with-jpeg-turbo],
105                             [Use the JPEG Turbo library])],
106             [with_jpeg_turbo=$withval],
107             [with_jpeg_turbo=yes])
108
109 AM_CONDITIONAL(TURBO_JPEG_IS_ON, test $with_jpeg_turbo = yes)
110
111 # Tizen Profile options
112 AC_ARG_ENABLE([profile],
113               [AC_HELP_STRING([--enable-profile=COMMON,MOBILE,TV],
114                             [Select the variant of tizen])],
115               [dali_profile=$enableval],
116               [dali_profile=COMMON])
117
118 if test "x$enable_profile" = "xyes"; then
119   dali_profile=COMMON
120 fi
121 if test "x$enable_profile" = "x"; then
122   dali_profile=COMMON
123 fi
124
125 DALI_ADAPTOR_CFLAGS="$DALI_ADAPTOR_CFLAGS -DDALI_PROFILE_${dali_profile}"
126 DALI_PROFILE_CFLAGS=" -DDALI_PROFILE_${dali_profile}"
127 AM_CONDITIONAL([COMMON_PROFILE], [test x$dali_profile = xCOMMON])
128 AM_CONDITIONAL([MOBILE_PROFILE], [test x$dali_profile = xMOBILE])
129 AM_CONDITIONAL([TV_PROFILE], [test x$dali_profile = xTV])
130
131 if test "x$enable_profile" = "xMOBILE"; then
132 PKG_CHECK_MODULES(OPENGLES20, opengl-es-20)
133 PKG_CHECK_MODULES(ASSIMP, assimp)
134 PKG_CHECK_MODULES(DEVICED, deviced)
135 PKG_CHECK_MODULES(EVAS, evas)
136 PKG_CHECK_MODULES(NATIVE_BUFFER, native-buffer)
137 PKG_CHECK_MODULES(NATIVE_BUFFER_POOL, native-buffer-pool)
138 fi
139
140 if test "x$enable_profile" = "xTV"; then
141 PKG_CHECK_MODULES(OPENGLES20, gles20)
142 PKG_CHECK_MODULES(ASSIMP, assimp)
143 PKG_CHECK_MODULES(HAPTIC, haptic)
144 fi
145
146 if test "x$enable_profile" = "xCOMMON"; then
147 PKG_CHECK_MODULES(OPENGLES20, gles20)
148 PKG_CHECK_MODULES(HAPTIC, haptic)
149 fi
150
151 if test x$DALI_DATA_RW_DIR != x; then
152   dataReadWriteDir=$DALI_DATA_RW_DIR
153 else
154   dataReadWriteDir=${prefix}/share/dali/
155 fi
156
157 if test x$DALI_DATA_RO_DIR != x; then
158   dataReadOnlyDir=$DALI_DATA_RO_DIR
159 else
160   dataReadOnlyDir=${prefix}/share/dali/
161 fi
162
163 if test x$FONT_PRELOADED_PATH != x; then
164   fontPreloadedPath=$FONT_PRELOADED_PATH
165 else
166   fontPreloadedPath=/usr/share/fonts/
167 fi
168
169 if test x$FONT_DOWNLOADED_PATH != x; then
170   fontDownloadedPath=$FONT_DOWNLOADED_PATH
171 else
172   fontDownloadedPath=/opt/share/fonts/
173 fi
174
175 if test x$FONT_APPLICATION_PATH != x; then
176   fontApplicationPath=$FONT_APPLICATION_PATH
177 else
178   fontApplicationPath=~/.fonts/
179 fi
180
181 if test x$FONT_CONFIGURATION_FILE != x; then
182   fontConfigurationFilePath=$FONT_CONFIGURATION_FILE
183 fi
184
185 AC_SUBST(dataReadWriteDir)
186 AC_SUBST(dataReadOnlyDir)
187 AC_SUBST(fontPreloadedPath)
188 AC_SUBST(fontDownloadedPath)
189 AC_SUBST(fontApplicationPath)
190 AC_SUBST(fontConfigurationFilePath)
191 AC_SUBST(DALI_ADAPTOR_CFLAGS)
192 AC_SUBST(DALI_PROFILE_CFLAGS)
193
194 # Specify the include directory for development headers
195 #devincludepath=${includedir}/dali/internal
196 devincludepath=${includedir}
197 AC_SUBST(devincludepath)
198
199
200 AC_CONFIG_FILES([
201  Makefile
202  common/Makefile
203  dali-adaptor/Makefile
204  dali.pc
205  dali-application/Makefile
206  dali-application.pc
207  dali-evas/Makefile
208  dali-evas.pc
209  dali-native-buffer/Makefile
210  dali-native-buffer.pc
211  plugins/Makefile
212 ])
213
214 AC_OUTPUT
215
216 echo "
217 Configuration
218 -------------
219   Prefix:                           $prefix
220   Debug Build:                      $enable_debug
221   Compile flags                     $DALI_ADAPTOR_CFLAGS
222   Using JPEG Turbo Library:         $with_jpeg_turbo
223   Profile:                          $dali_profile
224   Data Dir (Read/Write):            $dataReadWriteDir
225   Data Dir (Read Only):             $dataReadOnlyDir
226   Font Path (Preloaded):            $fontPreloadedPath
227   Font Path (Downloaded):           $fontDownloadedPath
228   Font Path (Application):          $fontApplicationPath
229   Font Configuration File:          $fontConfigurationFilePath
230 "