summaryrefslogtreecommitdiff
path: root/legacy/evil/configure.ac
blob: 34690f155aa18fee8b8356e2395c6ba085e048ed (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
138
139
140
141
142
143
144
145
146
147
148
149
150
151

### Version

m4_define([evil_version_major], [0])
m4_define([evil_version_minor], [0])
m4_define([evil_version_micro], [1])

m4_define([evil_version],
   [evil_version_major.evil_version_minor.evil_version_micro])

m4_define([lt_rev], m4_eval(evil_version_major + evil_version_minor))
m4_define([lt_cur], evil_version_micro)
m4_define([lt_age], evil_version_minor)

AC_INIT([evil], [evil_version], [enlightenment-devel@lists.sourceforge.net])
AC_PREREQ([2.52])
AC_CONFIG_SRCDIR([configure.ac])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_HEADERS([config.h])
AC_CANONICAL_HOST

### If the host is not Windows, or is ceGCC, we exit
case "$host_os" in
  cegcc*)
    AC_MSG_ERROR([ceGCC compiler is not supported anymore. Exiting...])
    ;;
  mingw*)
    ;;
  *)
    AC_MSG_ERROR([OS must be Windows. Exiting...])
    ;;
esac

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

LT_INIT([win32-dll])

version_info="lt_rev:lt_cur:lt_age"
AC_SUBST(version_info)


### Checks for programs
AM_PROG_AS
AC_PROG_CXX
AC_LANG(C)
AC_PROG_CPP
AC_PROG_CC

# doxygen program for documentation building

EFL_CHECK_DOXYGEN([build_doc="yes"], [build_doc="no"])


### Checks for libraries

win32_libs=""
case "$host_os" in
  mingw32ce*)
    win32_libs="-lws2"
    ;;
  *)
    win32_libs="-lole32 -lws2_32 -lsecur32"
    ;;
esac
AC_SUBST(win32_libs)

EFL_CHECK_MPATROL([have_mpatrol="yes"], [have_mpatrol="no"])


### Checks for header files
AC_CHECK_HEADERS([errno.h])


### Checks for types


### Checks for structures


### Checks for compiler characteristics
AC_C_CONST
AC_C___ATTRIBUTE__

win32_cppflags="-DEFL_EVIL_BUILD"
win32_cflags="-Wall -Wextra -Wshadow -Wdeclaration-after-statement -Wmissing-prototypes -Wstrict-prototypes -Wredundant-decls"
win32_cxxflags=""
have_wince="no"
case "$host_os" in
  mingw32ce*)
    have_wince="yes"
    win32_cppflags="${win32_cppflags} -D_WIN32_WCE=0x0420"
    ;;
  *)
    have_wince="no"
    win32_cxxflags="-fno-rtti -fno-exceptions"
    win32_cppflags="${win32_cppflags} -D_WIN32_WINNT=0x0501 -DSECURITY_WIN32"
    ;;
esac
AC_SUBST(win32_cppflags)
AC_SUBST(win32_cflags)
AC_SUBST(win32_cxxflags)

AM_CONDITIONAL(EVIL_HAVE_WINCE, test "x${have_wince}" = "xyes")


### Checks for linker characteristics


### Checks for library functions


AC_CONFIG_FILES([
Makefile
evil.pc
doc/Makefile
src/Makefile
src/bin/Makefile
src/lib/Makefile
src/lib/dlfcn/Makefile
])

AC_OUTPUT


#####################################################################
## Info

echo
echo
echo
echo "------------------------------------------------------------------------"
echo "$PACKAGE_NAME $PACKAGE_VERSION"
echo "------------------------------------------------------------------------"
echo
echo "Configuration Options Summary:"
echo
echo "  OS...................: ${host_os}"
echo
echo "  Documentation........: ${build_doc}"
echo "  Mpatrol..............: ${have_mpatrol}"
echo
echo "Compilation............: make (or gmake)"
echo "  CPPFLAGS.............: $CPPFLAGS"
echo "  CFLAGS...............: $CFLAGS"
echo "  CXXFLAGS.............: $CXXFLAGS"
echo "  LDFLAGS..............: $LDFLAGS"
echo
echo "Installation...........: make install (as root if needed, with 'su' or 'sudo')"
echo "  prefix...............: $prefix"
echo