summaryrefslogtreecommitdiff
path: root/configure.ac
blob: 2ea1dd0eb540a55f2ae2ce50ddd80f6d5f1256fd (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
dnl Process this file with autoconf to produce a configure script.

# get rid of that stupid cache mechanism
rm -f config.cache

AC_INIT([expedite], [1.11.99], [enlightenment-devel@lists.sourceforge.net])
AC_PREREQ([2.52])
AC_CONFIG_SRCDIR([configure.ac])
AC_CONFIG_HEADERS([config.h])
AC_CANONICAL_BUILD
AC_CANONICAL_HOST

AM_INIT_AUTOMAKE([1.6 dist-bzip2 subdir-objects])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])

PKG_PROG_PKG_CONFIG


### Checks for programs

AC_ISC_POSIX
m4_ifdef([AC_PROG_OBJC],
   [
    AC_PROG_OBJC
    _AM_DEPENDENCIES(OBJC)
   ],
   [
    AC_CHECK_TOOL([OBJC], [gcc])
    AC_SUBST([OBJC])
    AC_SUBST([OBJCFLAGS])
   ]
)
AC_PROG_CXX
AC_PROG_CC

LT_PROG_RC

### Check for C++11

EFL_CXX_COMPILE_STDCXX_11([ext], [mandatory])

### Checks for libraries

# Evil library for compilation on Windows

case "$host_os" in
   mingw32*)
      PKG_CHECK_MODULES([EVIL], [evil >= 1.7.99])
      AC_DEFINE(HAVE_EVIL, 1, [Set to 1 if Evil library is installed])
      ;;
esac

# EFL dependencies

PKG_CHECK_MODULES([EFL], eina >= 1.7.99 efl >= 1.11.99 eo >= 1.7.99 evas >= 1.7.99 eet >= 1.7.99 ecore-evas >= 1.7.99 ecore >= 1.7.99)

EFL_ENABLE_EO_API_SUPPORT
EFL_ENABLE_BETA_API_SUPPORT

# EFL++ dependencies

PKG_CHECK_MODULES([EFL_CXX], efl-cxx >= 1.11.99 eina-cxx >= 1.11.99 eo-cxx >= 1.11.99 evas-cxx >= 1.11.99 eet-cxx >= 1.11.99)

### Checks for header files


### Checks for types


### Checks for structures


### Checks for compiler characteristics

AC_HEADER_STDC
AC_C_CONST
AM_PROG_CC_C_O
AC_C___ATTRIBUTE__

WIN32_CFLAGS=""
case "$host_os" in
   cegcc*)
      WIN32_CFLAGS="-mwin32"
      ;;
esac
AC_SUBST(WIN32_CFLAGS)

EXPEDITE_CXXFLAGS=""
AC_LANG_PUSH([C++])
CXXFLAGS_save="${CXXFLAGS}"
CXXFLAGS="${CXXFLAGS} -fno-rtti -fno-exceptions"
AC_LINK_IFELSE(
   [AC_LANG_PROGRAM([[]])],
   [have_cxx_flags="yes"],
   [have_cxx_flags="no"])
AC_MSG_CHECKING([whether the compiler supports -fno-rtti -fno-exceptions])
AC_MSG_RESULT([${have_cxx_flags}])
CXXFLAGS="${CXXFLAGS_save}"
if test "x${have_cxx_flags}" = "xyes" ; then
   EXPEDITE_CXXFLAGS="-fno-rtti -fno-exceptions -DEFL_CXX_NO_EXCEPTIONS"
fi
CXXFLAGS="${CXXFLAGS} -std=c++11"

AC_LANG_POP([C++])
AC_SUBST(EXPEDITE_CXXFLAGS)


### Checks for linker characteristics

lt_enable_auto_import=""
case "$host_os" in
   mingw* | cegcc*)
      lt_enable_auto_import="-Wl,--enable-auto-import"
      ;;
esac
AC_SUBST(lt_enable_auto_import)


### Checks for library functions

AC_CHECK_FUNCS([sync])


AC_OUTPUT([
Makefile
expedite.spec
src/Makefile
src/bin/Makefile
data/Makefile
])

echo
echo "  $PACKAGE $VERSION"
echo
echo "  Installation:"
echo "    prefix.......................: ${prefix}"
echo