Removed open-gles-20 dependency
[platform/core/uifw/dali-core.git] / build / slp / configure.ac
1 #
2 # Copyright (c) 2014 Samsung Electronics Co., Ltd.
3 #
4 # Licensed under the Flora License, Version 1.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://floralicense.org/license/
9
10 #
11 # Unless required by applicable law or agreed to in writing, software
12 # distributed under the License is distributed on an AS IS BASIS,
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 # See the License for the specific language governing permissions and
15 # limitations under the License.
16 #
17
18 m4_define([dali_version],[0.1.1])
19 AC_INIT([dali], [dali_version])
20 AM_INIT_AUTOMAKE([-Wall foreign])
21
22 AC_PROG_CXX
23 AC_PROG_LIBTOOL
24 AC_PROG_MKDIR_P
25
26 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
27
28 LT_INIT
29
30 DALI_VERSION=dali_version
31 AC_SUBST(DALI_VERSION)
32
33 DALI_CFLAGS=-DPLATFORM_SLP
34
35 AC_ARG_ENABLE(exportall,
36               [AC_HELP_STRING([--enable-exportall],
37                               [enables the exporting of all the symbols in the library])],
38               [enable_exportall=yes],
39               [enable_exportall=no])
40
41 AC_ARG_ENABLE([debug],
42               [AC_HELP_STRING([--enable-debug],
43                               [Turns on debugging])],
44               [enable_debug=$enableval],
45               [enable_debug=no])
46
47 AC_ARG_ENABLE([emscripten],
48               [AC_HELP_STRING([--enable-emscripten],
49                               [Emscripten builds])],
50               [enable_emscripten=$enableval],
51               [enable_emscripten=no])
52
53 AC_ARG_ENABLE([dynamics],
54               [AC_HELP_STRING([--enable-dynamics],
55                               [Builds with dynamics support])],
56               [dynamics_support=$enableval],
57               [dynamics_support=no])
58
59 if test "x$enable_debug" = "xyes"; then
60   DALI_CFLAGS="$DALI_CFLAGS -DDEBUG_ENABLED -DDEBUG_BACKTRACE"
61 fi
62
63 if test "x$enable_debug" = "xno" -a "x$enable_exportall" = "xno"; then
64   DALI_CFLAGS="$DALI_CFLAGS -fvisibility=hidden -DHIDE_DALI_INTERNALS"
65 fi
66
67 if test "x$enable_emscripten" = "xyes"; then
68   DALI_CFLAGS="$DALI_CFLAGS -DEMSCRIPTEN -std=c++11"
69 fi
70
71 if test "x$dynamics_support" = "xyes"; then
72   DALI_CFLAGS="$DALI_CFLAGS -DDYNAMICS_SUPPORT"
73 fi
74
75 AM_CONDITIONAL([DYNAMICS_SUPPORT], [test x$dynamics_support = xyes])
76
77 AC_ARG_ENABLE([performance-monitor],
78               [AC_HELP_STRING([--enable-performance-monitor],
79                               [Enables the performance monitor output])],
80               [enable_performance_monitor=$enableval],
81               [enable_performance_monitor=no])
82
83 if test "x$enable_performance_monitor" = "xyes"; then
84   DALI_CFLAGS="$DALI_CFLAGS -DPERFORMANCE_MONITOR_ENABLED"
85 fi
86
87 if test x$DALI_DATA_RW_DIR != x; then
88   dataReadWriteDir=$DALI_DATA_RW_DIR
89 else
90   dataReadWriteDir=${prefix}/share/dali/
91 fi
92
93 if test x$DALI_DATA_RO_DIR != x; then
94   dataReadOnlyDir=$DALI_DATA_RO_DIR
95 else
96   dataReadOnlyDir=${prefix}/share/dali/
97 fi
98
99 DALI_CFLAGS="$DALI_CFLAGS -I${includedir}"
100 DALI_LDFLAGS="-L${libdir}"
101
102 AC_SUBST(dataReadWriteDir)
103 AC_SUBST(dataReadOnlyDir)
104 AC_SUBST(DALI_CFLAGS)
105 AC_SUBST(DALI_LDFLAGS)
106
107 # Specify the include directory for development headers
108 devincludepath=${includedir}
109 AC_SUBST(devincludepath)
110
111 AC_CONFIG_FILES([
112  Makefile
113  dali-core/Makefile
114  dali-core.pc
115  dali-test-suite-utils.pc
116 ])
117
118 AC_OUTPUT
119
120 echo "
121 Configuration
122 -------------
123   Prefix:                           $prefix
124   Debug Build:                      $enable_debug
125   Performance Monitor:              $enable_performance_monitor
126   Data Dir (Read/Write):            $dataReadWriteDir
127   Data Dir (Read Only):             $dataReadOnlyDir
128   Emscripten:                       $enable_emscripten
129 "