Minor changes
[public/netxms.git] / configure.ac
CommitLineData
cd4c8ca3 1# $Id: configure.ac,v 1.224 2006-11-20 23:37:03 victor Exp $
d16cf8a5
AK
2#
3# Process this file with autoconf to produce a configure script.
4#
5
02727160 6AC_INIT([NetXMS], [0.2.14], [NetXMS Team <bugs@netxms.org>])
ba1d810c
AK
7AC_CONFIG_AUX_DIR(config)
8AM_CONFIG_HEADER(config.h)
d16cf8a5
AK
9AM_INIT_AUTOMAKE
10
e356b9b7
VK
11PLATFORM=`uname -s`
12
c29360a9 13ALL_STATIC_FLAG=""
5387ff75
VK
14
15# --------------------------------------------------------------------------
16# checks for programs.
17
e356b9b7 18if test "x$PLATFORM" = "xHP-UX"; then
2bc9fd0b 19 CCC="aCC"
e356b9b7 20fi
2bc9fd0b 21AC_PROG_CC(aCC gcc cc cl)
5387ff75 22AC_PROG_CPP
2bc9fd0b 23AC_PROG_CXX
5387ff75 24AC_PROG_INSTALL
b32538f9
VK
25AC_PROG_LEX
26AC_PROG_YACC
882e43d4 27AC_PROG_LN_S
5387ff75 28
d16cf8a5 29# --------------------------------------------------------------------------
d3c8926d 30# Misc. settings
463b332e 31CPPFLAGS="$CPPFLAGS -D_POSIX_PTHREAD_SEMANTICS -D_XOPEN_SOURCE=500 -D_XOPEN_SOURCE_EXTENDED=1 -D_THREAD_SAFE"
e8636669 32SUBAGENT_LIBS=""
5387ff75 33
e0760102 34# --------------------------------------------------------------------------
d3c8926d
VK
35# disable C++ exceptions
36
16dff090
VK
37if test "x$CC" = "xgcc" ; then
38
d3c8926d
VK
39AC_LANG_PUSH([C++])
40
44adbac8 41AC_MSG_CHECKING(whether C++ compiler accepts -fno-rtti)
6cd235ca
AK
42OLD_CXXFLGAS="$CXXFLAGS"
43CXXFLAGS="$CXXFLAGS -fno-rtti"
d3c8926d
VK
44AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[ ]])],
45 [ AC_MSG_RESULT(yes) ],
46 [
6cd235ca 47 CXXFLAGS="$OLD_CXXFLAGS"
d3c8926d
VK
48 AC_MSG_RESULT(no)
49 ])
50
44adbac8 51AC_MSG_CHECKING(whether C++ compiler accepts -fno-exceptions)
6cd235ca
AK
52OLD_CXXFLGAS="$CXXFLAGS"
53CXXFLAGS="$CXXFLAGS -fno-exceptions"
d3c8926d
VK
54AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ ]], [[ ]])],
55 [ AC_MSG_RESULT(yes) ],
56 [
6cd235ca 57 CXXFLAGS="$OLD_CXXFLAGS"
d3c8926d
VK
58 AC_MSG_RESULT(no)
59 ])
60
61AC_LANG_POP([C++])
62
16dff090
VK
63fi
64
d3c8926d 65# --------------------------------------------------------------------------
16dff090 66# set CPPFLAGS and LDFLAGS depending on OS
7c9c94a7 67
2bc9fd0b 68case "$PLATFORM" in
7c9c94a7
VK
69 AIX)
70 LDFLAGS="-no-undefined $LDFLAGS"
71 ;;
16dff090 72 HP-UX)
17d715ba 73 CPPFLAGS="$CPPFLAGS -D_HPUX -D_HPUX_SOURCE"
dbb51c0d 74 if test "x$CXX" = "xaCC"; then
dff54fed
VK
75 CXXFLAGS="-mt $CXXFLAGS +W749 +W829"
76 LDFLAGS="$LDFLAGS -mt"
dbb51c0d 77 fi
16dff090 78 ;;
7c9c94a7
VK
79 *)
80 ;;
81esac
82
83# --------------------------------------------------------------------------
d16cf8a5
AK
84# misc
85
86AC_ARG_VAR(PERL,local path to the perl interpreter)
87perl_possible_path="/usr/bin:/usr/local/bin:/bin:/opt/perl/bin:/opt/perl/usr/bin:/opt/perl/usr/local/bin"
88AC_PATH_PROG(PERL,perl,/usr/bin/env perl,$perl_possible_path)
89
90if test -d /usr/local/include; then
91 CFLAGS="$CFLAGS -I/usr/local/include"
2cb1fb26 92 CPPFLAGS="$CPPFLAGS -I/usr/local/include"
d16cf8a5
AK
93fi
94
95if test -d /usr/kerberos/include; then
96 CFLAGS="$CFLAGS -I/usr/kerberos/include"
2cb1fb26 97 CPPFLAGS="$CPPFLAGS -I/usr/kerberos/include"
d16cf8a5 98fi
521d90e7 99
d16cf8a5
AK
100if test -d /usr/local/lib; then
101 LDFLAGS="$LDFLAGS -L/usr/local/lib"
102fi
103
104# --------------------------------------------------------------------------
105# command line options
106
9486b324
VK
107AC_ARG_WITH(sqlite,
108[AS_HELP_STRING(--with-sqlite,build SQLite database driver)],
109[ if test "x$withval" != "xno" ; then
110 if test "x$withval" != "x" && test "x$withval" != "xyes" ; then
111 LD_RUN_PATH="${withval}/lib${LD_RUN_PATH:+:}${LD_RUN_PATH}"
112 LDFLAGS="$LDFLAGS -L${withval}/lib"
113 CPPFLAGS="$CPPFLAGS -I${withval}/include"
114 fi
115 DYNAMIC_COMPONENTS="yes"
116 with_sqlite="yes"
117 AC_DEFINE(WITH_SQLITE,,[with sqlite])
118 DB_DRIVERS="$DB_DRIVERS sqlite"
119 AC_CHECK_LIB(sqlite3, sqlite3_open, ,
120 [AC_MSG_ERROR(libsqlite3 is required for SQLite support)])
121fi ])
122
c4b88c3d
VK
123AC_ARG_WITH(odbc,
124[AS_HELP_STRING(--with-odbc,build ODBC database driver)],
125[ if test "x$withval" != "xno" ; then
126 if test "x$withval" != "x" && test "x$withval" != "xyes" ; then
127 LD_RUN_PATH="${withval}/lib${LD_RUN_PATH:+:}${LD_RUN_PATH}"
128 LDFLAGS="$LDFLAGS -L${withval}/lib"
129 CPPFLAGS="$CPPFLAGS -I${withval}/include"
130 fi
e8636669 131 DYNAMIC_COMPONENTS="yes"
c4b88c3d
VK
132 with_odbc="yes"
133 AC_DEFINE(WITH_ODBC,,[with odbc])
134 DB_DRIVERS="$DB_DRIVERS odbc"
135 AC_CHECK_LIB(odbc, SQLAllocHandle, ,
b11f69d6 136 [AC_MSG_ERROR(libodbc is required for ODBC support)])
c4b88c3d
VK
137fi ])
138
d16cf8a5 139AC_ARG_WITH(mysql,
c4b88c3d 140[AS_HELP_STRING(--with-mysql,build MySQL database driver)],
d16cf8a5
AK
141[ if test "x$withval" != "xno" ; then
142 if test "x$withval" != "x" && test "x$withval" != "xyes" ; then
143 LD_RUN_PATH="${withval}/lib${LD_RUN_PATH:+:}${LD_RUN_PATH}"
144 LDFLAGS="$LDFLAGS -L${withval}/lib -L${withval}/lib/mysql -L${withval}/mysql/lib"
6693a1d0 145 CPPFLAGS="$CPPFLAGS -I${withval}/include -I${withval}/include/mysql -I${withval}/mysql/include"
d16cf8a5 146 else
007ae516
VK
147 LD_RUN_PATH="/usr/local/mysql/lib:/usr/local/mysql/lib/mysql:/usr/lib64/mysql:/usr/lib/mysql:/usr/mysql/lib:/usr/mysql/lib/mysql:/usr/local/lib/mysql:${LD_RUN_PATH:+:}${LD_RUN_PATH}"
148 LDFLAGS="$LDFLAGS -L/usr/local/mysql/lib -L/usr/lib64/mysql -L/usr/lib/mysql -L/usr/mysql/lib -L/usr/local/lib/mysql -L/usr/local/mysql/lib/mysql -L/usr/mysql/lib/mysql"
6693a1d0 149 CPPFLAGS="$CPPFLAGS -I/usr/local/mysql/include -I/usr/include/mysql -I/usr/mysql/include -I/usr/local/include/mysql -I/usr/local/mysql/include/mysql -I/usr/mysql/include/mysql"
d16cf8a5 150 fi
e8636669 151 DYNAMIC_COMPONENTS="yes"
d16cf8a5 152 AC_CHECK_LIB(m, floor)
d16cf8a5
AK
153 with_mysql="yes"
154 AC_DEFINE(WITH_MYSQL,,[with mysql])
6693a1d0 155 DB_DRIVERS="$DB_DRIVERS mysql"
d16cf8a5 156 AC_CHECK_LIB(mysqlclient, mysql_init, ,
b11f69d6 157 [AC_MSG_ERROR(libmysqlclient is requred for MySQL support)])
d16cf8a5
AK
158 AC_MSG_CHECKING(whether mysql clients can run)
159 AC_RUN_IFELSE([AC_LANG_SOURCE([[
160 #include <stdio.h>
161 #include <mysql.h>
162 int main(void)
163 {
164 MYSQL *a = mysql_init(NULL);
165 return 0;
166 }
167 ]])],[],[
168 AC_MSG_RESULT(no)
169 AC_MSG_ERROR(Your MySQL client libraries aren't properly installed)
170 ],[])
171 AC_MSG_RESULT(yes)
172 AC_CHECK_FUNCS(mysql_real_escape_string)
6693a1d0 173fi ])
d16cf8a5
AK
174
175AC_ARG_WITH(pgsql,
c4b88c3d 176[AS_HELP_STRING(--with-pgsql,build PostgreSQL database driver)],
d16cf8a5 177[ if test "x$withval" != "xno" ; then
6693a1d0
AK
178 if test "x$withval" != "x" && test "x$withval" != "xyes" ; then
179 LD_RUN_PATH="${withval}/lib${LD_RUN_PATH:+:}${LD_RUN_PATH}"
180 LDFLAGS="$LDFLAGS -L${withval}/lib -L${withval}/lib/pgsql -L${withval}/lib/postgresql -L${withval}/pgsql/lib -L${withval}/postgresql/lib"
181 CPPFLAGS="$CPPFLAGS -I${withval}/include -I${withval}/include/pgsql -I${withval}/include/postgresql -I${withval}/pgsql/include -I${withval}/postgresql/include"
182 else
007ae516
VK
183 LD_RUN_PATH="/usr/local/pgsql/lib:/usr/local/pgsql/lib/pgsql:/usr/lib64/pgsql:/usr/lib/pgsql:/usr/pgsql/lib:/usr/pgsql/lib/pgsql:/usr/local/lib/pgsql:/usr/local/postgresql/lib:/usr/local/postgresql/lib/postgresql:/usr/lib/postgresql:/usr/postgresql/lib:/usr/postgresql/lib/postgresql:/usr/local/lib/postgresql:${LD_RUN_PATH:+:}${LD_RUN_PATH}"
184 LDFLAGS="$LDFLAGS -L/usr/local/pgsql/lib -L/usr/lib64/pgsql -L/usr/lib/pgsql -L/usr/pgsql/lib -L/usr/local/lib/pgsql -L/usr/local/pgsql/lib/pgsql -L/usr/pgsql/lib/pgsql -L/usr/local/postgresql/lib -L/usr/lib/postgresql -L/usr/postgresql/lib -L/usr/local/lib/postgresql -L/usr/local/postgresql/lib/postgresql -L/usr/postgresql/lib/postgresql"
6693a1d0
AK
185 CPPFLAGS="$CPPFLAGS -I/usr/local/pgsql/include -I/usr/include/pgsql -I/usr/pgsql/include -I/usr/local/include/pgsql -I/usr/local/pgsql/include/pgsql -I/usr/pgsql/include/pgsql -I/usr/local/postgresql/include -I/usr/include/postgresql -I/usr/postgresql/include -I/usr/local/include/postgresql -I/usr/local/postgresql/include/postgresql -I/usr/postgresql/include/postgresql"
186 fi
e8636669 187 DYNAMIC_COMPONENTS="yes"
6693a1d0 188 AC_CHECK_LIB(m, floor)
6693a1d0
AK
189 with_pgsql="yes"
190 DB_DRIVERS="$DB_DRIVERS pgsql"
191 AC_DEFINE(WITH_PGSQL,,[with pgsql])
192 AC_CHECK_LIB(pq, PQconnectdb, ,
b11f69d6 193 [AC_MSG_ERROR(libpq is required for PostgreSQL support)])
6693a1d0
AK
194 AC_MSG_CHECKING(whether postgresql clients can run)
195 AC_RUN_IFELSE([AC_LANG_SOURCE([[
196 #include <stdio.h>
197 #include <libpq-fe.h>
198 int main(void)
199 {
200 PGconn *a = PQconnectdb("");
201 return 0;
202 }
203 ]])],[],[
204 AC_MSG_RESULT(no)
205 AC_MSG_ERROR(Your PostgreSQL client libraries aren't properly installed)
206 ],[])
207 AC_MSG_RESULT(yes)
208fi ])
d16cf8a5 209
3a7ce527
AK
210AC_ARG_WITH(server,
211[AS_HELP_STRING(--with-server,build server)],
212[
d7ede5c0 213 MODULES="$MODULES libnxmap libnxsnmp libnxsl server nxmibc nxscript"
abc48356 214 TOP_LEVEL_MODULES="$TOP_LEVEL_MODULES sql images"
3f2f9f2b 215 CONTRIB_MODULES="$CONTRIB_MODULES mibs backgrounds"
d7ede5c0 216 BUILD_SERVER="yes"
e8636669 217 DYNAMIC_COMPONENTS="yes"
d7ede5c0 218 NEED_ZLIB="yes"
3a7ce527 219])
3a7ce527
AK
220
221
e0760102
VK
222AC_ARG_WITH(client,
223[AS_HELP_STRING(--with-client,build client library and tools)],
224[
09c70d92 225 MODULES="$MODULES libnxmap libnxcl nxevent nxpush nxreport console"
e0760102 226 BUILD_CLIENT="yes"
e8636669 227 DYNAMIC_COMPONENTS="yes"
e0760102
VK
228])
229
230
d8ca9c03
VK
231AC_ARG_WITH(mdebug,
232[AS_HELP_STRING(--with-mdebug,use debug version of memory allocation functions)],
233[
234 CFLAGS="$CFLAGS -DNETXMS_MEMORY_DEBUG"
235 CPPFLAGS="$CPPFLAGS -DNETXMS_MEMORY_DEBUG"
236])
237
238
3a7ce527
AK
239SUBAGENT_DIRS=""
240AC_ARG_WITH(agent,
241[AS_HELP_STRING(--with-agent,build agent)],
242[
a7442678 243 BUILD_AGENT=yes
0c3c0c39 244 MODULES="$MODULES agent"
2bc9fd0b 245 case "$PLATFORM" in
3a7ce527
AK
246 Linux)
247 SUBAGENT_DIRS="linux"
248 ;;
249 FreeBSD)
250 SUBAGENT_DIRS="freebsd"
251 ;;
992ba479
AK
252 OpenBSD)
253 SUBAGENT_DIRS="openbsd"
254 ;;
3a7ce527
AK
255 SunOS)
256 SUBAGENT_DIRS="sunos"
257 ;;
d0b5a098
VK
258 AIX)
259 SUBAGENT_DIRS="aix"
260 ;;
9bdf494f
AK
261 HP-UX)
262 SUBAGENT_DIRS="hpux"
263 ;;
3a7ce527
AK
264 *)
265 # unknown
266 ;;
267 esac
e8636669
VK
268 DYNAMIC_COMPONENTS="yes"
269])
270
271AC_ARG_WITH(static-agent,
272[AS_HELP_STRING(--with-static-agent,build statically linked agent)],
273[
2b23dc1e
VK
274 BUILD_STATIC_AGENT="yes"
275 MODULES="$MODULES agent"
e8636669
VK
276 CFLAGS="$CFLAGS -D_STATIC_AGENT"
277 CPPFLAGS="$CPPFLAGS -D_STATIC_AGENT"
c29360a9
VK
278 LDFLAGS="$LDFLAGS"
279 ALL_STATIC_FLAG="-all-static"
280 #STATIC_SUBAGENT_LIST="ping portcheck"
e8636669
VK
281 case `uname -s` in
282 Linux)
283 SUBAGENT_DIRS="linux"
d0b5a098
VK
284 SUBAGENT_LIBS="../subagents/linux/libnsm_linux.la"
285 STATIC_SUBAGENT_LIST="linux $STATIC_SUBAGENT_LIST"
e8636669
VK
286 ;;
287 FreeBSD)
288 SUBAGENT_DIRS="freebsd"
d0b5a098
VK
289 SUBAGENT_LIBS="../subagents/freebsd/libnsm_freebsd.la"
290 STATIC_SUBAGENT_LIST="freebsd $STATIC_SUBAGENT_LIST"
e8636669 291 ;;
992ba479
AK
292 OpenBSD)
293 SUBAGENT_DIRS="openbsd"
294 SUBAGENT_LIBS="../subagents/openbsd/libnsm_openbsd.la"
295 STATIC_SUBAGENT_LIST="openbsd $STATIC_SUBAGENT_LIST"
296 ;;
e8636669
VK
297 SunOS)
298 SUBAGENT_DIRS="sunos"
d0b5a098
VK
299 SUBAGENT_LIBS="../subagents/sunos/libnsm_sunos.la"
300 STATIC_SUBAGENT_LIST="sunos $STATIC_SUBAGENT_LIST"
301 ;;
302 AIX)
303 SUBAGENT_DIRS="aix"
304 SUBAGENT_LIBS="../subagents/aix/libnsm_aix.la"
305 STATIC_SUBAGENT_LIST="aix $STATIC_SUBAGENT_LIST"
e8636669 306 ;;
c29360a9
VK
307 HP-UX)
308 SUBAGENT_DIRS="hpux"
309 SUBAGENT_LIBS="../subagents/hpux/libnsm_hpux.la"
310 STATIC_SUBAGENT_LIST="hpux $STATIC_SUBAGENT_LIST"
311 ;;
e8636669
VK
312 *)
313 # unknown
314 ;;
315 esac
3a7ce527 316])
0c3c0c39 317
2b23dc1e
VK
318AC_ARG_WITH(ipso-agent,
319[AS_HELP_STRING(--with-ipso-agent,build statically linked IPSO agent)],
320[
cd4c8ca3 321 USE_PTH="yes"
2b23dc1e
VK
322 BUILD_STATIC_AGENT="yes"
323 MODULES="$MODULES agent"
cd4c8ca3 324 CPPFLAGS="$CPPFLAGS -D_STATIC_AGENT -D_IPSO -D_USE_GNU_PTH -I/usr/local/include"
2b23dc1e
VK
325 LDFLAGS="$LDFLAGS -all-static"
326 STATIC_SUBAGENT_LIST="ipso ping portcheck ups"
2a1e4b34 327 SUBAGENT_DIRS="ipso"
2b23dc1e
VK
328 SUBAGENT_LIBS="../subagents/ipso/libnsm_ipso.la ../subagents/ping/libnsm_ping.la ../subagents/portCheck/libnsm_portCheck.la ../subagents/ups/libnsm_ups.la"
329])
330
c688d2a7 331UNSTABLE_SUBAGENT_DIRS=""
59ec7d94 332AC_ARG_ENABLE(unstable,
0c78251f 333[AS_HELP_STRING(--enable-unstable,build experimental/unstable components)],
c688d2a7
AK
334[
335 UNSTABLE_SUBAGENT_DIRS="logscan"
336])
337
dff54fed 338AC_ARG_ENABLE(iconv,
3265ba38 339[AS_HELP_STRING(--disable-iconv,do not use iconv() for text conversions)],
dff54fed
VK
340[
341 DISABLE_ICONV="yes"
342 CPPFLAGS="$CPPFLAGS -D__DISABLE_ICONV"
343])
344
0c3c0c39
AK
345AC_ARG_WITH(dist,
346[AS_HELP_STRING(--with-dist,for maintainers only)],
c2eaebc6 347 DB_DRIVERS="mysql pgsql odbc mssql sqlite"
574f8820 348 MODULES="libnxsnmp libnxsl server agent libnxmap libnxcl nxevent nxpush nxreport nxmibc console nxhttpd nxscript"
24b1570c 349 SUBAGENT_DIRS="linux freebsd openbsd sunos aix ipso hpux"
5b0c7d0d 350 NXCONFIG="nxconfig"
abc48356 351 TOP_LEVEL_MODULES="sql images"
3f2f9f2b 352 CONTRIB_MODULES="mibs backgrounds"
a22ba463 353 UNSTABLE_SUBAGENT_DIRS="logscan"
0c3c0c39
AK
354)
355
2654e540 356AC_ARG_WITH(nxhttpd,
9b648a2f 357[AS_HELP_STRING(--with-nxhttpd,build web interface)],
b97191d2 358[
987b646a 359 if test "x$withval" != "xno" ; then
1d410d50 360 MODULES="$MODULES libnxmap libnxcl nxhttpd"
987b646a
AK
361 BUILD_WEB_CLIENT="yes"
362 DYNAMIC_COMPONENTS="yes"
363 fi
b97191d2
AK
364])
365
b67a9e12
VK
366AC_ARG_ENABLE(encryption,
367[AS_HELP_STRING(--disable-encryption,disable encryption support)],
368[
369 DISABLE_ENCRYPTION="yes"
370])
371
372if test "x$DISABLE_ENCRYPTION" != "xyes"; then
6619a6b0 373AC_ARG_WITH(openssl,
a7442678
AK
374 [AS_HELP_STRING(--with-openssl,specify OpenSSL location)],
375 [
a7442678
AK
376 if test "x$withval" != "xno" ; then
377 if test "x$withval" != "x" && test "x$withval" != "xyes" ; then
378 LD_RUN_PATH="${withval}/lib${LD_RUN_PATH:+:}${LD_RUN_PATH}"
379 LDFLAGS="$LDFLAGS -L${withval}/lib"
380 CPPFLAGS="$CPPFLAGS -I${withval}/include"
381 else
2b23dc1e 382 LD_RUN_PATH="/usr/local/lib:/opt/openssl/lib:/usr/local/ssl/lib:${LD_RUN_PATH:+:}${LD_RUN_PATH}"
a7442678
AK
383 LDFLAGS="$LDFLAGS -L/usr/local/lib -L/opt/openssl/lib"
384 CPPFLAGS="$CPPFLAGS -I/usr/local/include -I/opt/openssl/include"
385 fi
ad6eb83b
AK
386 AC_CHECK_LIB(crypto, RSA_new,
387 [
388 AC_DEFINE(WITH_OPENSSL,,[with openssl])
389 AC_CHECK_LIB(crypto, EVP_aes_256_cbc,
390 [], [AC_DEFINE(NETXMS_NO_AES,,[desc])])
391 AC_CHECK_LIB(crypto, EVP_bf_cbc,
392 [], [AC_DEFINE(NETXMS_NO_BF,,[desc])])
393 AC_CHECK_LIB(crypto, EVP_idea_cbc,
394 [], [AC_DEFINE(NETXMS_NO_IDEA,,[desc])])
395 AC_CHECK_LIB(crypto, EVP_des_ede3_cbc,
396 [], [AC_DEFINE(NETXMS_NO_DES,,[desc])])
397 ],
a7442678
AK
398 [AC_MSG_ERROR(libcrypto is required for encryption support)])
399 fi
a7442678 400 ],
ad6eb83b
AK
401 [
402 AC_CHECK_LIB(crypto, RSA_new,
403 [
404 AC_DEFINE(WITH_OPENSSL,,[with openssl])
405 AC_CHECK_LIB(crypto, EVP_aes_256_cbc,
406 [], [AC_DEFINE(NETXMS_NO_AES,,[desc])])
407 AC_CHECK_LIB(crypto, EVP_bf_cbc,
408 [], [AC_DEFINE(NETXMS_NO_BF,,[desc])])
409 AC_CHECK_LIB(crypto, EVP_idea_cbc,
410 [], [AC_DEFINE(NETXMS_NO_IDEA,,[desc])])
411 AC_CHECK_LIB(crypto, EVP_des_ede3_cbc,
412 [], [AC_DEFINE(NETXMS_NO_DES,,[desc])])
413 ],
414 [AC_MSG_RESULT(libcrypto is required for encryption support)])
415 ])
b67a9e12 416fi
6619a6b0 417
0c3c0c39
AK
418AC_SUBST(DB_DRIVERS)
419AC_SUBST(MODULES)
3a7ce527 420AC_SUBST(SUBAGENT_DIRS)
5b0c7d0d 421AC_SUBST(NXCONFIG)
abc48356
VK
422AC_SUBST(TOP_LEVEL_MODULES)
423AC_SUBST(CONTRIB_MODULES)
e8636669
VK
424AC_SUBST(STATIC_SUBAGENT_LIST)
425AC_SUBST(SUBAGENT_LIBS)
c2eaebc6 426AC_SUBST(BUILD_SERVER)
c688d2a7 427AC_SUBST(UNSTABLE_SUBAGENT_DIRS)
e8636669
VK
428
429# --------------------------------------------------------------------------
430# If --with-static-agent selected, other components cannot be selected
431# Select shared or static libraries depending on agent build type
432if test "x$BUILD_STATIC_AGENT" = "xyes" ; then
433 if test "x$DYNAMIC_COMPONENTS" = "xyes" ; then
434 AC_MSG_ERROR(Static agent and other components are mutally exclusive.)
435 fi
172b3b8e 436 enable_shared=no
e8636669 437else
172b3b8e 438 enable_static=no
e8636669
VK
439fi
440
441AC_LIBTOOL_DLOPEN
442AC_PROG_LIBTOOL
3a7ce527 443
d16cf8a5
AK
444# --------------------------------------------------------------------------
445# checks for libs.
446
447#AC_CHECK_LIB([socket], [socket])
448#AC_CHECK_LIB([nsl], [gethostbyname])
449
521d90e7 450AC_CHECK_LIB(socket, if_nameindex)
87bb64a7 451AC_CHECK_LIB(dl, dlopen)
1b3c0ef0 452AC_CHECK_LIB(kstat, kstat_open)
d16cf8a5 453
e0760102
VK
454if test "x$BUILD_SERVER" = "xyes" ; then
455 AC_CHECK_LIB(termcap, tgetstr, [], [AC_CHECK_LIB(ncurses, tgetstr, [], AC_CHECK_LIB(curses, tgetstr))])
456 AC_CHECK_LIB(readline, readline)
457fi
458
08ffa53e 459# --------------------------------------------------------------------------
d16cf8a5
AK
460# checks for headers.
461
462AC_HEADER_STDC
463AC_HEADER_STAT
464AC_HEADER_TIME
6b42b6f1 465AC_CHECK_HEADERS([stdarg.h])
ade50e8b 466AC_CHECK_HEADERS([sys/int_types.h sys/time.h])
ca6ad6bb 467AC_CHECK_HEADERS([arpa/inet.h netdb.h netinet/in.h net/nh.h sys/socket.h])
70fed300 468AC_CHECK_HEADERS([fcntl.h dirent.h sys/ioctl.h sys/sockio.h poll.h termios.h])
ade50e8b
AK
469AC_CHECK_HEADERS([net/if.h net/if_arp.h net/if_dl.h],,,
470[[#ifdef HAVE_SYS_TYPES_H
471# include <sys/types.h>
472#endif
473#ifdef HAVE_SYS_TIME_H
474# include <sys/time.h>
475#endif
476#ifdef HAVE_SYS_SOCKET_H
477# include <sys/socket.h>
478#endif
479]])
14ab1131 480AC_CHECK_HEADERS([readline/readline.h])
f52be742 481AC_CHECK_HEADERS([byteswap.h])
eca0b061 482AC_CHECK_HEADERS([sys/mman.h])
31a11006 483AC_CHECK_HEADERS([sys/utsname.h])
d16cf8a5 484
d16cf8a5
AK
485# --------------------------------------------------------------------------
486# types
487AC_CHECK_SIZEOF(short)
488AC_CHECK_SIZEOF(int)
489AC_CHECK_SIZEOF(long)
490AC_CHECK_SIZEOF(long long)
491
492AC_TYPE_PID_T
493AC_TYPE_SIGNAL
494AC_TYPE_SIZE_T
495AC_STRUCT_TIMEZONE
496
521d90e7 497AC_CHECK_TYPES([int64_t, uint64_t, u_int64_t])
4c779d83
VK
498AC_CHECK_TYPES([off_t, socklen_t],,,[
499#if HAVE_SYS_TYPES_H
500#include <sys/types.h>
501#endif
502#if HAVE_SYS_SOCKET_H
503#include <sys/socket.h>
504#endif
505])
521d90e7 506
d16cf8a5
AK
507# --------------------------------------------------------------------------
508# C/CPP caps
509
510AC_PROG_GCC_TRADITIONAL
511AC_C_CONST
512AC_C_BIGENDIAN
513
514# --------------------------------------------------------------------------
80e3de8d
VK
515# check for zlib
516
517if test "x$NEED_ZLIB" = "xyes"; then
518 AC_CHECK_HEADER(zlib.h,,AC_MSG_ERROR([*** ZLib development package not installed - please install first ***]))
519 AC_CHECK_LIB(z, deflate)
520fi
521
522# --------------------------------------------------------------------------
f52be742
VK
523# macros
524
ca6ad6bb
VK
525AC_CHECK_DECLS([__bswap_32, __bswap_64, htonll, ntohll],,,[
526#ifdef HAVE_SYS_TYPES_H
527# include <sys/types.h>
528#endif
f52be742
VK
529#if HAVE_BYTESWAP_H
530#include <byteswap.h>
531#endif
ca6ad6bb
VK
532#if HAVE_NETINET_IN_H
533#include <netinet/in.h>
534#endif
535#if HAVE_NET_NH_H
536#include <net/nh.h>
537#endif
f52be742 538])
85303064
VK
539AC_CHECK_DECLS([SIOCGIFADDR, SIOCGIFNETMASK, SIOCGIFHWADDR],,,[
540#if HAVE_SYS_IOCTL_H
541#include <sys/ioctl.h>
542#endif
543#if HAVE_SYS_SOCKIO_H
544#include <sys/sockio.h>
545#endif
546])
f52be742
VK
547
548# --------------------------------------------------------------------------
e25cadc9
VK
549# AIX specific
550
ca6ad6bb 551AC_CHECK_HEADERS([procinfo.h],,,[[ ]])
e25cadc9 552AC_CHECK_DECLS([getkerninfo])
ca6ad6bb
VK
553AC_CHECK_FUNCS([getprocs64],,,[
554#if HAVE_PROCINFO_H
555#include <procinfo.h>
556#endif
557])
e25cadc9
VK
558
559# --------------------------------------------------------------------------
d16cf8a5
AK
560# library functions
561
562AC_FUNC_ERROR_AT_LINE
abc48356
VK
563#AC_FUNC_MALLOC
564#AC_FUNC_REALLOC
d16cf8a5 565AC_FUNC_MEMCMP
d16cf8a5
AK
566AC_FUNC_SELECT_ARGTYPES
567AC_FUNC_STRFTIME
568AC_FUNC_STRTOD
569AC_FUNC_VPRINTF
570
b50f1100
VK
571AC_CHECK_FUNCS([gettimeofday memmove memset strchr strcspn strdup strerror])
572AC_CHECK_FUNCS([strrchr strtol strtoul strtoll strtoull])
467e30e1 573AC_CHECK_FUNCS([if_nametoindex daemon mmap strerror_r scandir uname poll])
fde73127 574AC_CHECK_FUNCS([nanosleep getopt_long])
d16cf8a5 575
73d7fbdb
VK
576AC_CHECK_DECLS([getopt_long])
577
2a1e4b34 578AC_CHECK_HEADERS([sys/sysctl.h vm/vm_param.h])
f91feddc 579AC_CHECK_FUNCS([sysctlbyname sysctlnametomib])
2a1e4b34 580
70fed300
AK
581AC_CHECK_FUNCS([tcgetattr tcsetattr cfsetospeed cfsetispeed])
582
d16cf8a5
AK
583# sockets/resolver (probably for solaris)
584AC_CHECK_FUNC(connect, , [AC_CHECK_LIB(socket, connect)])
585AC_CHECK_FUNC(gethostbyname, , [AC_CHECK_LIB(resolv, gethostbyname)])
586AC_CHECK_FUNC(gethostbyname, , [AC_CHECK_LIB(nsl, gethostbyname)])
587
588if test "x$ac_cv_lib_nsl_gethostbyname" != "xyes" && test "x$ac_cv_func_gethostbyname" != "xyes" ; then
589 AC_CHECK_FUNC(gethostbyname, , [AC_CHECK_LIB(socket, gethostbyname)])
590fi
591
592if test "$ac_cv_lib_nsl_gethostbyname" = "$ac_cv_func_gethostbyname" ; then
593 AC_MSG_CHECKING([if we can include libnsl + libsocket])
594 LIBS="-lnsl -lsocket $LIBS"
595 AC_LINK_IFELSE([AC_LANG_PROGRAM([[]], [[(void) gethostbyname]])],[my_ac_link_result=yes],[my_ac_link_result=no ])
596 if test "$my_ac_link_result" = "no" ; then
597 AC_MSG_RESULT([failure])
598 AC_MSG_ERROR([unable to use gethostbyname()])
599 else
600 AC_MSG_RESULT([success])
601 fi
602fi
603
3d9b275c 604#ALK: CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE" PTHREAD_LIBS="-pthread",
d16cf8a5 605# posix threads
cd4c8ca3
VK
606if test "x$USE_PTH" = "xyes"; then
607 AC_CHECK_HEADER(pth.h,,AC_MSG_ERROR([*** GNU Pth thread support not installed - please install first ***]))
608else
609 AC_CHECK_HEADER(pthread.h,,AC_MSG_ERROR([*** POSIX thread support not installed - please install first ***]))
dff54fed
VK
610
611# --------------------------------------------------------------------------
612# check for pthread library
613
614if test "x$CXX" = "xaCC"; then
615 PTHREAD_LIBS=""
616else
617 PTHREAD_LIBS=error
618 AC_MSG_CHECKING(for old style FreeBSD -pthread flag)
619 AC_EGREP_CPP(yes,
620 [#if defined(__FreeBSD_cc_version) || defined(__OpenBSD__)
621 yes
622 #endif
623 ], AC_MSG_RESULT(yes)
624 CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE" PTHREAD_LIBS="-pthread",
625 AC_MSG_RESULT(no))
626 if test "x$PTHREAD_LIBS" = xerror; then
627 AC_CHECK_LIB(pthread, pthread_attr_init,
628 PTHREAD_LIBS="-lpthread")
629 fi
630 if test "x$PTHREAD_LIBS" = xerror; then
631 AC_CHECK_LIB(pthreads, pthread_attr_init,
632 PTHREAD_LIBS="-lpthreads")
633 fi
634 if test "x$PTHREAD_LIBS" = xerror; then
635 AC_CHECK_FUNC(pthread_attr_init,
636 PTHREAD_LIBS="")
637 fi
d16cf8a5 638fi
dff54fed 639
b9e22217 640# HP-UX
dff54fed
VK
641#if test "x$PTHREAD_LIBS" = xerror; then
642# AC_CHECK_LIB(pthread, __pthread_attr_init_system,
643# PTHREAD_LIBS="-lpthread")
644#fi
645
d16cf8a5
AK
646if test "x$PTHREAD_LIBS" = xerror; then
647 AC_MSG_ERROR(*** Unable to locate working posix thread library ***)
648fi
a0537937 649LDFLAGS="$LDFLAGS $PTHREAD_LIBS"
d16cf8a5
AK
650AC_SUBST(PTHREAD_LIBS)
651
696fc54f 652# Extensions to posix threads
6cd41ceb
VK
653AC_CHECK_HEADERS([pthread_np.h],,,[
654#include <pthread.h>
655])
696fc54f
VK
656AC_CHECK_FUNCS([pthread_cond_reltimedwait_np])
657
a0537937
VK
658# Check for recursive mutexes
659AC_CHECK_FUNCS([pthread_mutexattr_settype pthread_mutexattr_setkind_np])
6cd41ceb 660AC_CHECK_DECLS([PTHREAD_MUTEX_RECURSIVE, PTHREAD_MUTEX_RECURSIVE_NP, MUTEX_TYPE_COUNTING_FAST],,,[
a0537937 661#include <pthread.h>
6cd41ceb
VK
662#if HAVE_PTHREAD_NP_H
663#include <pthread_np.h>
664#endif
a0537937
VK
665])
666
7e56bf2e
VK
667# Check for read/write locks
668# On Linux, rwlock functions declared always, but pthread_rwlock_t may need
669# additional defines
670AC_CHECK_FUNCS([pthread_rwlock_init pthread_rwlock_timedrdlock pthread_rwlock_timedwrlock])
671if test "$ac_cv_func_pthread_rwlock_init" = "yes"; then
672 AC_CACHE_CHECK([for pthread_rwlock_t], ac_cv_struct_pthread_rw,
673 [AC_TRY_COMPILE([#include <sys/types.h>
674 #include <pthread.h>],
675 [pthread_rwlock_t rwlock=PTHREAD_RWLOCK_INITIALIZER;],
676 ac_cv_struct_pthread_rw=yes, [
677 AC_TRY_COMPILE([#define _XOPEN_SOURCE 500
678 #include <sys/types.h>
679 #include <pthread.h>],
680 [pthread_rwlock_t rwlock=PTHREAD_RWLOCK_INITIALIZER;],
681 ac_cv_struct_pthread_rw=yes, ac_cv_struct_pthread_rw=no)
682 if test "$ac_cv_struct_pthread_rw" = "yes"; then
683 CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=500"
684 fi
685 ])])
686 if test "$ac_cv_struct_pthread_rw" = "yes"; then
df7156b3 687 AC_DEFINE(HAVE_PTHREAD_RWLOCK, 1, Define to 1 if you have working pthread read/write locks)
7e56bf2e
VK
688 fi
689fi
690
cd4c8ca3
VK
691# End of "if USE_PTH=yes then ... else ..."
692fi
693
3e39fcde
VK
694# --------------------------------------------------------------------------
695# check for UNICODE stuff
696
93571e7f 697AC_CHECK_HEADERS([wchar.h iconv.h])
3e39fcde 698AC_CHECK_SIZEOF(wchar_t)
dff54fed 699
3265ba38 700if test "x$DISABLE_ICONV" != "xyes"; then
dff54fed
VK
701 AC_CHECK_LIB(iconv, iconv,
702 [ ac_found_iconv=yes
703 LDFLAGS="$LDFLAGS -liconv"
704 ])
705 AC_CHECK_FUNCS(iconv, ac_found_iconv=yes, ac_found_iconv=no)
706else
707 ac_found_iconv=no
708fi
93571e7f
VK
709
710AC_MSG_CHECKING(whether iconv supports UCS-2-INTERNAL)
711AC_RUN_IFELSE(
712 [AC_LANG_PROGRAM([
713#if HAVE_ICONV_H
714#include <iconv.h>
715#endif
716 ], [
717 return iconv_open("UTF-8","UCS-2-INTERNAL")==(iconv_t)(-1);
718 ])
719 ],
720 [ AC_MSG_RESULT(yes)
721 AC_DEFINE(HAVE_ICONV_UCS_2_INTERNAL, 1, Define to 1 if iconv supports UCS-2-INTERNAL)
722 valid_ucs2_code="UCS-2-INTERNAL"
723 ],
724 [ AC_MSG_RESULT(no) ],
725 [ AC_MSG_RESULT(no) ]
726)
727
728AC_MSG_CHECKING(whether iconv supports UCS-2)
729AC_RUN_IFELSE(
730 [AC_LANG_PROGRAM([
731#if HAVE_ICONV_H
732#include <iconv.h>
733#endif
734 ], [
735 return iconv_open("UTF-8","UCS-2")==(iconv_t)(-1);
736 ])
737 ],
738 [ AC_MSG_RESULT(yes)
739 AC_DEFINE(HAVE_ICONV_UCS_2, 1, Define to 1 if iconv supports UCS-2)
740 valid_ucs2_code="UCS-2"
741 ],
742 [ AC_MSG_RESULT(no) ],
743 [ AC_MSG_RESULT(yes)
744 AC_DEFINE(HAVE_ICONV_UCS_2, 1, Define to 1 if iconv supports UCS-2)
745 ]
746)
747
748AC_MSG_CHECKING(whether iconv supports UCS2)
749AC_RUN_IFELSE(
750 [AC_LANG_PROGRAM([
751#if HAVE_ICONV_H
752#include <iconv.h>
753#endif
754 ], [
755 return iconv_open("UTF-8","UCS2")==(iconv_t)(-1);
756 ])
757 ],
758 [ AC_MSG_RESULT(yes)
759 AC_DEFINE(HAVE_ICONV_UCS2, 1, Define to 1 if iconv supports UCS2)
760 valid_ucs2_code="UCS2"
761 ],
762 [ AC_MSG_RESULT(no) ],
763 [ AC_MSG_RESULT(no) ]
764)
765
44bccbbc
VK
766AC_MSG_CHECKING(whether iconv supports UCS-2BE)
767AC_RUN_IFELSE(
768 [AC_LANG_PROGRAM([
769#if HAVE_ICONV_H
770#include <iconv.h>
771#endif
772 ], [
773 return iconv_open("UTF-8","UCS-2BE")==(iconv_t)(-1);
774 ])
775 ],
776 [ AC_MSG_RESULT(yes)
777 AC_DEFINE(HAVE_ICONV_UCS_2BE, 1, Define to 1 if iconv supports UCS-2BE)
778 valid_ucs2_code="UCS-2BE"
779 ],
780 [ AC_MSG_RESULT(no) ],
781 [ AC_MSG_RESULT(no) ]
782)
783
5e40a69e
VK
784AC_MSG_CHECKING(whether iconv supports ISO8859-1)
785AC_RUN_IFELSE(
786 [AC_LANG_PROGRAM([
787#if HAVE_ICONV_H
788#include <iconv.h>
789#endif
790 ], [
791 return iconv_open("UTF-8","ISO8859-1")==(iconv_t)(-1);
792 ])
793 ],
794 [ AC_MSG_RESULT(yes)
795 AC_DEFINE(HAVE_ICONV_ISO8859_1, 1, Define to 1 if iconv supports ISO8859-1)
796 ],
797 [ AC_MSG_RESULT(no) ],
798 [ AC_MSG_RESULT(no) ]
799)
800
801AC_MSG_CHECKING(whether iconv supports ISO-8859-1)
802AC_RUN_IFELSE(
803 [AC_LANG_PROGRAM([
804#if HAVE_ICONV_H
805#include <iconv.h>
806#endif
807 ], [
808 return iconv_open("UTF-8","ISO-8859-1")==(iconv_t)(-1);
809 ])
810 ],
811 [ AC_MSG_RESULT(yes)
812 AC_DEFINE(HAVE_ICONV_ISO_8859_1, 1, Define to 1 if iconv supports ISO-8859-1)
813 ],
814 [ AC_MSG_RESULT(no) ],
815 [ AC_MSG_RESULT(no) ]
816)
817
818AC_MSG_CHECKING(whether iconv supports ASCII)
819AC_RUN_IFELSE(
820 [AC_LANG_PROGRAM([
821#if HAVE_ICONV_H
822#include <iconv.h>
823#endif
824 ], [
825 return iconv_open("UTF-8","ASCII")==(iconv_t)(-1);
826 ])
827 ],
828 [ AC_MSG_RESULT(yes)
829 AC_DEFINE(HAVE_ICONV_ASCII, 1, Define to 1 if iconv supports ASCII)
830 ],
831 [ AC_MSG_RESULT(no) ],
832 [ AC_MSG_RESULT(no) ]
833)
834
93571e7f
VK
835AC_MSG_CHECKING(whether iconv supports //IGNORE)
836AC_RUN_IFELSE(
837 [AC_LANG_PROGRAM([
838#if HAVE_ICONV_H
839#include <iconv.h>
840#endif
841 ], [
842 return iconv_open("UTF-8//IGNORE","$valid_ucs2_code")==(iconv_t)(-1);
843 ])
844 ],
845 [ AC_MSG_RESULT(yes)
846 AC_DEFINE(HAVE_ICONV_IGNORE, 1, Define to 1 if iconv supports //IGNORE option)
847 ],
848 [ AC_MSG_RESULT(no) ],
849 [ AC_MSG_RESULT(no) ]
850)
3e39fcde 851
19619a35
AK
852# taken from ZSH's configure
853# Check if iconv uses const in prototype declaration
24b1570c 854if test "x$ac_found_iconv" = "xyes"; then
19619a35
AK
855 AC_CACHE_CHECK(for iconv declaration, ac_cv_iconv_const,
856 [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <stdlib.h>
857 #include <iconv.h>]],
858 [[#ifdef __cplusplus
859 "C"
860 #endif
861 #if defined(__STDC__) || defined(__cplusplus)
862 size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
863 #else
864 size_t iconv();
865 #endif]])],
866 [ac_cv_iconv_const=],
867 [ac_cv_iconv_const=const])])
868 AC_DEFINE_UNQUOTED([ICONV_CONST], $ac_cv_iconv_const,
869 [Define as const if the declaration of iconv() needs const.])
870fi
871
872
93571e7f 873if test $ac_cv_sizeof_wchar_t -eq 2; then
3e39fcde
VK
874 AC_DEFINE(HAVE_USEABLE_WCHAR_T, 1, Define to 1 if you have useable wchar_t)
875fi
876
c29360a9
VK
877# --------------------------------------------------------------------------
878# variables
879
880AC_SUBST(ALL_STATIC_FLAG)
881
82fa7c5d 882# misc
f8a000b8 883CPPFLAGS="$CPPFLAGS -DDATADIR=\\\"\${pkgdatadir}\\\" -DLIBDIR=\\\"\${libdir}\\\""
82fa7c5d 884
d16cf8a5
AK
885# --------------------------------------------------------------------------
886
887# shared libs versions
888#
889# versioning scheme: current:revision:age
890#
891# current
892# The number of the current interface exported by the library. A current
893# value of `0', means that you are calling the interface exported by this
894# library interface 0.
895#
896# revision
897# The implementation number of the most recent interface exported by this
898# library. In this case, a revision value of `0' means that this is the
899# first implementation of the interface.
900# If the next release of this library exports the same interface, but has a
901# different implementation (perhaps some bugs have been fixed), the revision
902# number will be higher, but current number will be the same. In that case,
903# when given a choice, the library with the highest revision will always
904# be used by the runtime loader.
905#
906# age
907# The number of previous additional interfaces supported by this library.
908# If age were `2', then this library can be linked into executables which
909# were built with a release of this library that exported the current
910# interface number, current, or any of the previous two interfaces.
911# By definition age must be less than or equal to current. At the outset,
912# only the first ever interface is implemented, so age can only be `0'.
913#
914#
915#
916
c7d14846
VK
917NETXMS_LIBRARY_VERSION=0:2:0
918AC_SUBST(NETXMS_LIBRARY_VERSION)
d16cf8a5
AK
919
920# --------------------------------------------------------------------------
921
922AC_CONFIG_FILES([
d16cf8a5 923 README
0c3c0c39
AK
924 Makefile
925 contrib/Makefile
0c3c0c39
AK
926 contrib/dct/Makefile
927 contrib/startup/Makefile
daaefaaf 928 contrib/startup/gentoo/Makefile
0c3c0c39 929 contrib/startup/redhat/Makefile
82fa7c5d 930 contrib/mibs/Makefile
3f2f9f2b 931 contrib/backgrounds/Makefile
0c3c0c39 932 doc/Makefile
a48203d2
VK
933 doc/internal/Makefile
934 doc/manuals/Makefile
935 doc/misc/Makefile
0c3c0c39
AK
936 images/Makefile
937 include/Makefile
938 m4/Makefile
939 netware/Makefile
940 sql/Makefile
0c3c0c39
AK
941 src/Makefile
942 src/libnetxms/Makefile
d853cd74 943 src/libnxsnmp/Makefile
0c3c0c39 944 src/libnxcl/Makefile
c002b04a 945 src/libnxsl/Makefile
1d410d50 946 src/libnxmap/Makefile
1b1edd49
VK
947 src/install/Makefile
948 src/install/windows/Makefile
0c3c0c39 949 src/console/Makefile
8c7d057b
VK
950 src/console/nxuilib/Makefile
951 src/console/nxuilib/res/Makefile
f7d8c3b2 952 src/console/nxuilib/sounds/Makefile
e4d08190 953 src/console/nxlexer/Makefile
0c3c0c39
AK
954 src/console/win32/Makefile
955 src/console/win32/icons/Makefile
956 src/console/win32/res/Makefile
957 src/console/win32starter/Makefile
672441ac 958 src/console/nxav/Makefile
2b463d08 959 src/console/nxav/res/Makefile
52996299
VK
960 src/console/nxnotify/Makefile
961 src/console/nxnotify/res/Makefile
672441ac 962 src/console/cmdline/Makefile
2b463d08
VK
963 src/console/PocketPC/Makefile
964 src/console/PocketPC/res/Makefile
0c3c0c39 965 src/nxevent/Makefile
09c70d92 966 src/nxpush/Makefile
1e8eed7a 967 src/nxreport/Makefile
148f47cf 968 src/nxmibc/Makefile
f519aa3e 969 src/nxscript/Makefile
0c3c0c39
AK
970 src/server/Makefile
971 src/server/core/Makefile
a551fe4d 972 src/server/netxmsd/Makefile
0c3c0c39
AK
973 src/server/dbdrv/Makefile
974 src/server/dbdrv/odbc/Makefile
975 src/server/dbdrv/mssql/Makefile
976 src/server/dbdrv/mysql/Makefile
977 src/server/dbdrv/pgsql/Makefile
9486b324 978 src/server/dbdrv/sqlite/Makefile
d8f2e39b
VK
979 src/server/smsdrv/Makefile
980 src/server/smsdrv/generic/Makefile
0c3c0c39
AK
981 src/server/tools/Makefile
982 src/server/tools/nxget/Makefile
983 src/server/tools/nxaction/Makefile
984 src/server/tools/nxadm/Makefile
5b0c7d0d
VK
985 src/server/tools/nxconfig/Makefile
986 src/server/tools/nxconfig/res/Makefile
f90d7fc5 987 src/server/tools/nxdbmgr/Makefile
d853cd74 988 src/server/tools/nxsnmpget/Makefile
734c670f 989 src/server/tools/nxsnmpwalk/Makefile
665b4ccf 990 src/server/tools/nxsnmpset/Makefile
d24fdaf4 991 src/server/tools/nxupload/Makefile
0c3c0c39
AK
992 src/server/libnxsrv/Makefile
993 src/agent/Makefile
994 src/agent/core/Makefile
5795bf90 995 src/agent/install/Makefile
0c3c0c39
AK
996 src/agent/subagents/Makefile
997 src/agent/subagents/linux/Makefile
998 src/agent/subagents/sunos/Makefile
d0b5a098 999 src/agent/subagents/aix/Makefile
9bdf494f 1000 src/agent/subagents/hpux/Makefile
0c3c0c39
AK
1001 src/agent/subagents/skeleton/Makefile
1002 src/agent/subagents/freebsd/Makefile
992ba479 1003 src/agent/subagents/openbsd/Makefile
2b23dc1e 1004 src/agent/subagents/ipso/Makefile
0c3c0c39 1005 src/agent/subagents/netware/Makefile
1bc607cc
VK
1006 src/agent/subagents/winnt/Makefile
1007 src/agent/subagents/win9x/Makefile
0c3c0c39 1008 src/agent/subagents/winperf/Makefile
93f15c2a 1009 src/agent/subagents/portCheck/Makefile
b36a6eb9 1010 src/agent/subagents/logscan/Makefile
abc48356 1011 src/agent/subagents/ping/Makefile
2f06a66e 1012 src/agent/subagents/ups/Makefile
9b648a2f
AK
1013 src/nxhttpd/Makefile
1014 src/nxhttpd/static/Makefile
2654e540 1015 src/nxhttpd/static/images/Makefile
15294d05
VK
1016 src/nxhttpd/libtpt/Makefile
1017 src/nxhttpd/libtpt/include/Makefile
1018 src/nxhttpd/libtpt/include/libtpt/Makefile
1019 src/nxhttpd/libtpt/source/Makefile
0c3c0c39 1020 tools/Makefile
d16cf8a5
AK
1021])
1022
12249937
VK
1023AC_OUTPUT
1024
6f926182
AK
1025#echo "Updating libtool-1"
1026#sed 's/-lc_r/-lc_rXXX/' < ./libtool > libtool.new && mv libtool.new libtool && chmod +x ./libtool
5cecf50e
AK
1027
1028echo "Updating libtool-2"
1029sed 's,$SED -e "/${host}-//g",$SED -e "s/${host}-//g",g' < ./libtool > libtool.new && mv libtool.new libtool && chmod +x ./libtool
1030
6f926182
AK
1031#if test ! "x$BUILD_SERVER" = "xyes" ; then
1032# echo "Updating libtool-3"
1033# $PERL tools/patch_libtool.pl <libtool >libtool.new
1034# mv libtool.new libtool
1035# chmod 755 libtool
1036#fi
a7442678
AK
1037
1038
1039
1040###########################
1041#
1042echo
1043echo
1044echo
1045echo '---------------------------------------------------------------------'
1046echo ' Configure results'
1047echo '---------------------------------------------------------------------'
1048echo
1049 echo "Prefix : ${prefix}"
1050if test "x${BUILD_SERVER}" = "xyes"; then
1051 echo "Build Server : YES"
1052else
1053 echo "Build Server : NO"
1054fi
1055if test "x${ac_cv_lib_crypto_RSA_new}" = "xyes"; then
1056 echo "Encryption enabled : YES"
1057else
1058 echo "Encryption enabled : NO"
1059fi
1060if test "x${DB_DRIVERS}" != "x"; then
1061 echo "Build DB-Drivers : ${DB_DRIVERS}"
1062else
1063 echo "Build DB-Drivers : NO"
1064fi
1065if test "x${BUILD_CLIENT}" = "xyes"; then
1066 echo "Build Clients : YES"
1067else
1068 echo "Build Clients : NO"
1069fi
2654e540
AK
1070if test "x${BUILD_WEB_CLIENT}" = "xyes"; then
1071 echo "Build Web Interface : YES"
1072else
c2503081 1073 echo "Build Web Interface : NO"
2654e540 1074fi
a7442678
AK
1075if test "x${BUILD_AGENT}" = "xyes"; then
1076 echo "Build Agent : YES"
1077 echo "Subagents list : ${SUBAGENT_DIRS}"
1078else
1079 echo "Build Agent : NO"
1080fi
e8636669
VK
1081if test "x${BUILD_STATIC_AGENT}" = "xyes"; then
1082 echo "Build Static Agent : YES"
1083 echo "Subagents list : ${STATIC_SUBAGENT_LIST}"
1084else
1085 echo "Build Static Agent : NO"
1086fi