1 # Copyright (c) 2014 Samsung Electronics Co., Ltd.
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
16 m4_define([dali_version],[0.1.1])
17 AC_INIT([dali], [dali_version])
18 AM_INIT_AUTOMAKE([-Wall foreign])
24 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
28 DALI_VERSION=dali_version
29 AC_SUBST(DALI_VERSION)
31 DALI_CFLAGS=-DPLATFORM_TIZEN
33 AC_ARG_ENABLE(exportall,
34 [AC_HELP_STRING([--enable-exportall],
35 [enables the exporting of all the symbols in the library])],
36 [enable_exportall=yes],
37 [enable_exportall=no])
39 AC_ARG_ENABLE([debug],
40 [AC_HELP_STRING([--enable-debug],
41 [Turns on debugging])],
42 [enable_debug=$enableval],
45 AC_ARG_ENABLE([emscripten],
46 [AC_HELP_STRING([--enable-emscripten],
47 [Emscripten builds])],
48 [enable_emscripten=$enableval],
49 [enable_emscripten=no])
51 AC_ARG_ENABLE([backtrace],
52 [AC_HELP_STRING([--enable-backtrace],
53 [Backtrace for exceptions])],
54 [enable_backtrace=$enableval],
55 [enable_backtrace=yes])
57 if test "x$enable_debug" = "xyes"; then
58 DALI_CFLAGS="$DALI_CFLAGS -DDEBUG_ENABLED"
61 if test "x$enable_debug" = "xno" -a "x$enable_exportall" = "xno"; then
62 DALI_CFLAGS="$DALI_CFLAGS -fvisibility=hidden -DHIDE_DALI_INTERNALS"
65 if test "x$enable_emscripten" = "xyes"; then
66 DALI_CFLAGS="$DALI_CFLAGS -DEMSCRIPTEN -std=c++11"
67 # Automatically turn off backtrace support
71 # Must come after Emscripten feature test
72 if test "x$enable_backtrace" = "xyes"; then
73 DALI_CFLAGS="$DALI_CFLAGS -DBACKTRACE_ENABLED"
76 if test x$DALI_DATA_RW_DIR != x; then
77 dataReadWriteDir=$DALI_DATA_RW_DIR
79 dataReadWriteDir=${prefix}/share/dali/
82 if test x$DALI_DATA_RO_DIR != x; then
83 dataReadOnlyDir=$DALI_DATA_RO_DIR
85 dataReadOnlyDir=${prefix}/share/dali/
88 DALI_CFLAGS="$DALI_CFLAGS -I${includedir}"
89 DALI_LDFLAGS="-L${libdir}"
91 AC_SUBST(dataReadWriteDir)
92 AC_SUBST(dataReadOnlyDir)
94 AC_SUBST(DALI_LDFLAGS)
96 # Specify the include directory for development headers
97 devincludepath=${includedir}
98 AC_SUBST(devincludepath)
112 Debug Build: $enable_debug
113 Data Dir (Read/Write): $dataReadWriteDir
114 Data Dir (Read Only): $dataReadOnlyDir
115 Emscripten: $enable_emscripten
116 Backtrace: $enable_backtrace