-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathconfigure.in.in
154 lines (131 loc) · 4.24 KB
/
configure.in.in
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
152
153
154
#MIN_CONFIG
AC_PREREQ(2.50)
AC_LANG_CPLUSPLUS
AC_LANG_C
AM_INIT_AUTOMAKE(sim,0.9.6)
AC_PROG_LIBTOOL
AC_STDC_HEADERS
AC_C_BIGENDIAN
KDE_NEED_FLEX
LFLAGS="-o${LEX_OUTPUT_ROOT}.c"
AC_SUBST(LFLAGS)
if test "$CYGWIN" = "yes"; then
LDFLAGS="$LDFLAGS --enable-auto-import"
fi
if ! echo $CXXFLAGS | fgrep '-fno-strict-aliasing' >/dev/null 2>&1 ; then
old_cxxflags=$CXXFLAGS
CXXFLAGS="$CXXFLAGS -fno-strict-aliasing"
AC_TRY_COMPILE([], [return 0;], , CXXFLAGS=$old_cxxflags)
fi
RELEASE_BUILD="no"
AC_ARG_ENABLE(
release,
[ --enable-release enable release build],
RELEASE_BUILD="$enableval")
if test "$RELEASE_BUILD" != "yes"; then
AC_DEFINE(CVS_BUILD, 1, [CVS build])
fi
AC_TYPE_OFF_T
AC_TYPE_PID_T
AC_TYPE_SIZE_T
AC_TYPE_UID_T
AC_STRUCT_TM
AC_PATH_X
if test $have_x = yes; then
AC_DEFINE(HAVE_X,1,[Have X Window System])
fi
AC_HEADER_SYS_WAIT
AC_FUNC_FORK
AC_C_INLINE
AC_C_CONST
KDE_CHECK_SSL
AC_HEADER_STDBOOL
AC_FUNC_ERROR_AT_LINE
AC_FUNC_MMAP
AC_FUNC_MKTIME
AC_FUNC_MEMCMP
AC_FUNC_MALLOC
AC_FUNC_REALLOC
AC_FUNC_STAT
AC_CACHE_CHECK(for tm_gmtoff in struct tm, ac_cv_struct_tm_gmtoff,
AC_TRY_COMPILE([
#include <time.h>
], [
struct tm tm;
tm.tm_gmtoff = 1;
], ac_cv_struct_tm_gmtoff=yes, ac_cv_struct_tm_gmtoff=no))
if test $ac_cv_struct_tm_gmtoff = yes; then
AC_DEFINE(HAVE_TM_GMTOFF, 1, [Define if you have a tm_gmtoff member in struct tm])
fi
AC_CHECK_HEADERS([arpa/inet.h netinet/in.h sys/ioctl.h sys/socket.h])
AC_CHECK_HEADERS([fcntl.h limits.h netdb.h stddef.h termios.h])
AC_CHECK_FUNCS([dup2 gethostbyname gethostname inet_ntoa])
AC_CHECK_FUNCS([memset mkdir munmap rmdir socket])
AC_CHECK_FUNCS([strcspn strdup strerror strstr strtol strtoul])
AC_CHECK_FUNC(strcasecmp,[AC_DEFINE(HAVE_STRCASECMP,1,[Have strcasecmp])])
AC_CHECK_FUNC(chmod,[AC_DEFINE(HAVE_CHMOD,1,[Have chmod])])
AC_CHECK_FUNC(uname,[AC_DEFINE(HAVE_UNAME,1,[Have uname])])
AC_EGREP_HEADER(in_addr_t, netinet/in.h,, AC_DEFINE(in_addr_t,int,[defaults in_addr_t to int]))
AC_EGREP_HEADER(socklen_t, sys/socket.h,, AC_DEFINE(socklen_t,int,[defaults socklen_t to int]))
AC_CHECK_LIB(xnet,inet_addr)
AC_CHECK_LIB(socket, socket)
AC_MSG_CHECKING([for The Ultimate Answer])
AC_MSG_RESULT([42])
EXTRA_LIBS=""
KDE_CHECK_HEADER(qsyntaxhighlighter.h,[AC_DEFINE(HAVE_QSYNTAXHIGHLIGHTER_H,1,[Have qsyntaxhighlighter.h])])
AC_DEFINE_UNQUOTED(PREFIX, "$prefix", [Install prefix])
AC_SUBST(EXTRA_LIBS)
if test "${exec_prefix}" = "NONE" ; then
exec_prefix=$prefix
fi
libdir=`eval echo $libdir`
sim_plugindir="${libdir}/sim"
sim_stylesdir="\${sim_plugindir}/styles"
AC_SUBST(sim_plugindir)
AC_SUBST(sim_stylesdir)
AC_DEFINE_UNQUOTED(PLUGIN_PATH,"${sim_plugindir}",[Plugins path])
LIB_XML2=""
AC_PATH_PROG(XML2_CONFIG, xml2-config, no)
if test "x$XML2_CONFIG" = "xno" ; then
AC_MSG_ERROR([Executable xml2-config not found!
Seems you have no libxml2 devel files installed.
You can download it from http://xmlsoft.org/download.html
])
fi
LIB_XML2=`$XML2_CONFIG --libs 2>/dev/null`
CPPFLAGS="$CPPFLAGS `$XML2_CONFIG --cflags`"
LIB_XSLT=""
AC_PATH_PROG(XSLT_CONFIG, xslt-config, no)
if test "x$XSLT_CONFIG" = "xno" ; then
AC_MSG_ERROR([Executable xslt-config not found!
Seems you have no libxslt devel files installed.
You can download it from http://xmlsoft.org/download.html
])
fi
LIB_XSLT=`$XSLT_CONFIG --libs 2>/dev/null`
CPPFLAGS="$CPPFLAGS `$XSLT_CONFIG --cflags`"
AC_SUBST(LIB_XML2)
AC_SUBST(LIB_XSLT)
ZIP_FLAGS="-j"
AC_PATH_PROG(ZIP, zip, no)
if test "x$ZIP" = "xno" ; then
AC_MSG_ERROR([Executable zip not found!])
fi
AC_SUBST(ZIP)
AC_SUBST(ZIP_FLAGS)
if test "$have_ssl" != "yes" -a "$want_ssl" != "no"; then
AC_MSG_ERROR([SIM requires OpenSSL library.
Please install OpenSSL (libraries and headers).
OpenSSL can be found at http://www.openssl.org
or as RPM from your local distribution site.
])
fi
AM_CONDITIONAL(QT_WIN, test "$kde_use_qt_win" = "yes")
if test "$kde_use_qt_win" = "yes"; then
AC_SUBST(SIM_RC_OBJ, "sim_rc.o")
AC_SUBST(GMSGFMT, "$GMSGFMT --qt")
AC_DEFINE(SIMAPI_EXPORTS, 1, [build libsim.dll])
fi
AM_CONDITIONAL(ENABLE_UPDATE, false)
AM_CONDITIONAL(ENABLE_STYLES_WOOD, false)
AM_CONDITIONAL(ENABLE_STYLES_METAL, false)