configure.ac 41 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139
  1. # -*- Autoconf -*-
  2. # Process this file with autoconf to produce a configure script.
  3. AC_PREREQ([2.59])
  4. AC_INIT(bind10-devel, 20111021, bind10-dev@isc.org)
  5. AC_CONFIG_SRCDIR(README)
  6. AM_INIT_AUTOMAKE
  7. AC_CONFIG_HEADERS([config.h])
  8. # Checks for programs.
  9. AC_PROG_CXX
  10. # Libtool configuration
  11. #
  12. # libtool cannot handle spaces in paths, so exit early if there is one
  13. if [ test `echo $PWD | grep -c ' '` != "0" ]; then
  14. AC_MSG_ERROR([BIND 10 cannot be built in a directory that contains spaces, because of libtool limitations. Please change the directory name, or use a symbolic link that does not contain spaces.])
  15. fi
  16. # On FreeBSD (and probably some others), clang++ does not meet an autoconf
  17. # assumption in identifying libtool configuration regarding shared library:
  18. # the configure script will execute "$CC -shared $CFLAGS/$CXXFLAGS -v" and
  19. # expect the output contains -Lxxx or -Ryyy. This is the case for g++, but
  20. # not for clang++, and, as a result, it will cause various errors in linking
  21. # programs or running them with a shared object (such as some of our python
  22. # scripts).
  23. # To work around this problem we define a temporary variable
  24. # "CXX_LIBTOOL_LDFLAGS". It's expected to be defined as, e.g, "-L/usr/lib"
  25. # to temporarily fake the output so that it will be compatible with that of
  26. # g++.
  27. CFLAGS_SAVED=$CFLAGS
  28. CXXFLAGS_SAVED=$CXXFLAGS
  29. CFLAGS="$CFLAGS $CXX_LIBTOOL_LDFLAGS"
  30. CXXFLAGS="$CXXFLAGS $CXX_LIBTOOL_LDFLAGS"
  31. AC_PROG_LIBTOOL
  32. CFLAGS=$CFLAGS_SAVED
  33. CXXFLAGS=$CXXFLAGS_SAVED
  34. # Use C++ language
  35. AC_LANG([C++])
  36. # Identify the compiler: this check must be after AC_PROG_CXX and AC_LANG.
  37. AM_CONDITIONAL(USE_GXX, test "X${GXX}" = "Xyes")
  38. AC_CHECK_DECL([__SUNPRO_CC], [SUNCXX="yes"], [SUNCXX="no"])
  39. AC_CHECK_DECL([__clang__], [CLANGPP="yes"], [CLANGPP="no"])
  40. AM_CONDITIONAL(USE_CLANGPP, test "X${CLANGPP}" = "Xyes")
  41. # Linker options
  42. # check -R rather than gcc specific -rpath to be as portable as possible.
  43. AC_MSG_CHECKING([whether -R flag is available in linker])
  44. LDFLAGS_SAVED="$LDFLAGS"
  45. LDFLAGS="$LDFLAGS -R/usr/lib"
  46. AC_TRY_LINK([],[],
  47. [ AC_MSG_RESULT(yes)
  48. rpath_available=yes
  49. ],[ AC_MSG_RESULT(no)
  50. rpath_available=no
  51. ])
  52. LDFLAGS=$LDFLAGS_SAVED
  53. # allow building programs with static link. we need to make it selective
  54. # because loadable modules cannot be statically linked.
  55. AC_ARG_ENABLE([static-link],
  56. AC_HELP_STRING([--enable-static-link],
  57. [build programs with static link [[default=no]]]),
  58. [enable_static_link=yes], [enable_static_link=no])
  59. AM_CONDITIONAL(USE_STATIC_LINK, test $enable_static_link = yes)
  60. # Check validity about some libtool options
  61. if test $enable_static_link = yes -a $enable_static = no; then
  62. AC_MSG_ERROR([--enable-static-link requires --enable-static])
  63. fi
  64. if test $enable_shared = no; then
  65. AC_MSG_ERROR([BIND 10 requires shared libraries to be built])
  66. fi
  67. AC_ARG_ENABLE(boost-threads,
  68. AC_HELP_STRING([--enable-boost-threads],
  69. [use boost threads. Currently this only means using its locks instead of dummy locks, in the cache and NSAS]),
  70. use_boost_threads=$enableval, use_boost_threads=no)
  71. # allow configuring without setproctitle.
  72. AC_ARG_ENABLE(setproctitle-check,
  73. AC_HELP_STRING([--disable-setproctitle-check],
  74. [do not check for python setproctitle module (used to give nice names to python processes)]),
  75. setproctitle_check=$enableval, setproctitle_check=yes)
  76. # OS dependent configuration
  77. SET_ENV_LIBRARY_PATH=no
  78. ENV_LIBRARY_PATH=LD_LIBRARY_PATH
  79. case "$host" in
  80. *-solaris*)
  81. # Solaris requires special definitions to get some standard libraries
  82. # (e.g. getopt(3)) available with common used header files.
  83. CPPFLAGS="$CPPFLAGS -D_XPG4_2 -D__EXTENSIONS__"
  84. ;;
  85. *-apple-darwin*)
  86. # libtool doesn't work perfectly with Darwin: libtool embeds the
  87. # final install path in dynamic libraries and our loadable python
  88. # modules always refer to that path even if it's loaded within the
  89. # source tree. This prevents pre-install tests from working.
  90. # To work around this problem we explicitly specify paths to dynamic
  91. # libraries when we use them in the source tree.
  92. SET_ENV_LIBRARY_PATH=yes
  93. ENV_LIBRARY_PATH=DYLD_LIBRARY_PATH
  94. ;;
  95. *-freebsd*)
  96. SET_ENV_LIBRARY_PATH=yes
  97. ;;
  98. *-netbsd*)
  99. SET_ENV_LIBRARY_PATH=yes
  100. ;;
  101. esac
  102. AM_CONDITIONAL(SET_ENV_LIBRARY_PATH, test $SET_ENV_LIBRARY_PATH = yes)
  103. AC_SUBST(SET_ENV_LIBRARY_PATH)
  104. AC_SUBST(ENV_LIBRARY_PATH)
  105. m4_define([_AM_PYTHON_INTERPRETER_LIST], [python python3 python3.1])
  106. AC_ARG_WITH([pythonpath],
  107. AC_HELP_STRING([--with-pythonpath=PATH],
  108. [specify an absolute path to python executable when automatic version check (incorrectly) fails]),
  109. [python_path="$withval"], [python_path="auto"])
  110. if test "$python_path" = auto; then
  111. AM_PATH_PYTHON([3.1])
  112. else
  113. # Older versions of automake can't handle python3 well. This is an
  114. # in-house workaround for them.
  115. PYTHON=$python_path
  116. AC_SUBST(PYTHON)
  117. PYTHON_PREFIX='${prefix}'
  118. AC_SUBST(PYTHON_PREFIX)
  119. PYTHON_EXEC_PREFIX='$(exec_prefix)'
  120. AC_SUBST(PYTHON_EXEC_PREFIX)
  121. PYTHON_VERSION=[`$PYTHON -c "import sys; sys.stdout.write(sys.version[:3])"`]
  122. if test `echo "$PYTHON_VERSION >= 3.1" | bc` != 1 ; then
  123. AC_MSG_ERROR(["Python version too old: $PYTHON_VERSION, need 3.1 or higher"])
  124. fi
  125. AC_SUBST(PYTHON_VERSION)
  126. PYTHON_PLATFORM=`$PYTHON -c "import sys; print(sys.platform)"`
  127. AC_SUBST(PYTHON_PLATFORM)
  128. pythondir='${prefix}/lib/python'$PYTHON_VERSION'/site-packages'
  129. AC_SUBST(pythondir)
  130. pkgpythondir='${pythondir}/'$PACKAGE
  131. AC_SUBST(pkgpythondir)
  132. pyexecdir='${exec_prefix}/lib/python'$PYTHON_VERSION'/site-packages'
  133. AC_SUBST(pyexecdir)
  134. pkgpyexecdir='${pyexecdir}/'$PACKAGE
  135. AC_SUBST(pkgpyexecdir)
  136. fi
  137. # We need to store the default pyexecdir in a separate variable so that
  138. # we can specify in Makefile.am the install directory of various BIND 10
  139. # python scripts and loadable modules; in Makefile.am we cannot replace
  140. # $(pyexecdir) using itself, e.g, this doesn't work:
  141. # pyexecdir = $(pyexecdir)/isc/some_module
  142. # The separate variable makes this setup possible as follows:
  143. # pyexecdir = $(PYTHON_SITEPKG_DIR)/isc/some_module
  144. PYTHON_SITEPKG_DIR=${pyexecdir}
  145. AC_SUBST(PYTHON_SITEPKG_DIR)
  146. # This will be commonly used in various Makefile.am's that need to generate
  147. # python log messages.
  148. PYTHON_LOGMSGPKG_DIR="\$(top_builddir)/src/lib/python/isc/log_messages"
  149. AC_SUBST(PYTHON_LOGMSGPKG_DIR)
  150. # This is python package paths commonly used in python tests. See
  151. # README of log_messages for why it's included.
  152. COMMON_PYTHON_PATH="\$(abs_top_builddir)/src/lib/python/isc/log_messages:\$(abs_top_srcdir)/src/lib/python:\$(abs_top_builddir)/src/lib/python"
  153. AC_SUBST(COMMON_PYTHON_PATH)
  154. # Check for python development environments
  155. if test -x ${PYTHON}-config; then
  156. PYTHON_INCLUDES=`${PYTHON}-config --includes`
  157. for flag in `${PYTHON}-config --ldflags`; do
  158. # add any '-L..." flags to PYTHON_LDFLAGS
  159. flag=`echo $flag | sed -ne 's/^\(\-L.*\)$/\1/p'`
  160. if test "X${flag}" != X; then
  161. PYTHON_LDFLAGS="$PYTHON_LDFLAGS ${flag}"
  162. fi
  163. done
  164. # on some platforms, ${PYTHON}-config --ldflags doesn't provide a -L
  165. # option while having the library under a non trivial directory.
  166. # as a workaround we try the "lib" sub directory under the common
  167. # prefix for this python.
  168. if test -z "${PYTHON_LDFLAGS}"; then
  169. PYTHON_LDFLAGS="-L`${PYTHON}-config --prefix`/lib"
  170. fi
  171. else
  172. if test "X$PYTHON_INCLUDES" = X -o "X$PYTHON_LDFLAGS" = X; then
  173. AC_MSG_WARN([${PYTHON}-config does not exist or is not executable, so we could not detect python development environment. Your system may require an additional package (e.g. "python3-dev"). Alternatively, if you are sure you have python headers and libraries, define PYTHON_INCLUDES and PYTHON_LDFLAGS and run this script.])
  174. fi
  175. fi
  176. # Some OSes including NetBSD don't install libpython.so in a well known path.
  177. # To avoid requiring dynamic library path with our python wrapper loadable
  178. # modules, we embed the path to the modules when possible. We do this even
  179. # when the path is known in the common operational environment (e.g. when
  180. # it's stored in a common "hint" file) for simplicity.
  181. if test $rpath_available = yes; then
  182. python_rpath=
  183. for flag in ${PYTHON_LDFLAGS}; do
  184. python_rpath="${python_rpath} `echo $flag | sed -ne 's/^\(\-L\)/-R/p'`"
  185. done
  186. PYTHON_LDFLAGS="${PYTHON_LDFLAGS} ${python_rpath}"
  187. fi
  188. AC_SUBST(PYTHON_INCLUDES)
  189. AC_SUBST(PYTHON_LDFLAGS)
  190. CPPFLAGS_SAVED="$CPPFLAGS"
  191. CPPFLAGS="$CPPFLAGS ${PYTHON_INCLUDES}"
  192. AC_CHECK_HEADERS([Python.h],, AC_MSG_ERROR([Missing Python.h]))
  193. CPPFLAGS="$CPPFLAGS_SAVED"
  194. # Check for python library. Needed for Python-wrapper libraries.
  195. LDFLAGS_SAVED="$LDFLAGS"
  196. LDFLAGS="$LDFLAGS $PYTHON_LDFLAGS"
  197. python_bin="python${PYTHON_VERSION}"
  198. AC_CHECK_LIB($python_bin, main, python_lib=$python_bin, python_lib=no)
  199. if test $python_lib != "no"; then
  200. PYTHON_LIB="-l$python_lib"
  201. fi
  202. AC_SUBST(PYTHON_LIB)
  203. LDFLAGS=$LDFLAGS_SAVED
  204. # Check for the setproctitle module
  205. if test "$setproctitle_check" = "yes" ; then
  206. AC_MSG_CHECKING(for setproctitle module)
  207. if "$PYTHON" -c 'import setproctitle' 2>/dev/null ; then
  208. AC_MSG_RESULT(ok)
  209. else
  210. AC_MSG_RESULT(missing)
  211. AC_MSG_WARN([Missing setproctitle python module.
  212. Use --disable-setproctitle-check to skip this check.
  213. In this case we will continue, but naming of python processes will not work.])
  214. fi
  215. fi
  216. # TODO: check for _sqlite3.py module
  217. # Compiler dependent settings: define some mandatory CXXFLAGS here.
  218. # We also use a separate variable B10_CXXFLAGS. This will (and should) be
  219. # used as the default value for each specific AM_CXXFLAGS:
  220. # AM_CXXFLAGS = $(B10_CXXFLAGS)
  221. # AM_CXXFLAGS += ... # add module specific flags
  222. # We need this so that we can disable some specific compiler warnings per
  223. # module basis; since AM_CXXFLAGS are placed before CXXFLAGS, and since
  224. # gcc's -Wno-XXX option must be specified after -Wall or -Wextra, we cannot
  225. # specify the default warning flags in CXXFLAGS and let specific modules
  226. # "override" the default.
  227. # This may be used to try linker flags.
  228. AC_DEFUN([BIND10_CXX_TRY_FLAG], [
  229. AC_MSG_CHECKING([whether $CXX supports $1])
  230. bind10_save_CXXFLAGS="$CXXFLAGS"
  231. CXXFLAGS="$CXXFLAGS $1"
  232. AC_LINK_IFELSE([int main(void){ return 0;} ],
  233. [bind10_cxx_flag=yes], [bind10_cxx_flag=no])
  234. CXXFLAGS="$bind10_save_CXXFLAGS"
  235. if test "x$bind10_cxx_flag" = "xyes"; then
  236. ifelse([$2], , :, [$2])
  237. else
  238. ifelse([$3], , :, [$3])
  239. fi
  240. AC_MSG_RESULT([$bind10_cxx_flag])
  241. ])
  242. werror_ok=0
  243. # SunStudio compiler requires special compiler options for boost
  244. # (http://blogs.sun.com/sga/entry/boost_mini_howto)
  245. if test "$SUNCXX" = "yes"; then
  246. CXXFLAGS="$CXXFLAGS -library=stlport4 -features=tmplife -features=tmplrefstatic"
  247. MULTITHREADING_FLAG="-mt"
  248. fi
  249. BIND10_CXX_TRY_FLAG(-Wno-missing-field-initializers,
  250. [WARNING_NO_MISSING_FIELD_INITIALIZERS_CFLAG="-Wno-missing-field-initializers"])
  251. AC_SUBST(WARNING_NO_MISSING_FIELD_INITIALIZERS_CFLAG)
  252. # gcc specific settings:
  253. if test "X$GXX" = "Xyes"; then
  254. B10_CXXFLAGS="-Wall -Wextra -Wwrite-strings -Woverloaded-virtual -Wno-sign-compare"
  255. case "$host" in
  256. *-solaris*)
  257. MULTITHREADING_FLAG=-pthreads
  258. # In Solaris, IN6ADDR_ANY_INIT and IN6ADDR_LOOPBACK_INIT need -Wno-missing-braces
  259. B10_CXXFLAGS="$B10_CXXFLAGS -Wno-missing-braces"
  260. ;;
  261. *)
  262. MULTITHREADING_FLAG=-pthread
  263. ;;
  264. esac
  265. # Certain versions of gcc (g++) have a bug that incorrectly warns about
  266. # the use of anonymous name spaces even if they're closed in a single
  267. # translation unit. For these versions we have to disable -Werror.
  268. CXXFLAGS_SAVED="$CXXFLAGS"
  269. CXXFLAGS="$CXXFLAGS $B10_CXXFLAGS -Werror"
  270. AC_MSG_CHECKING(for in-TU anonymous namespace breakage)
  271. AC_TRY_COMPILE([namespace { class Foo {}; }
  272. namespace isc {class Bar {Foo foo_;};} ],,
  273. [AC_MSG_RESULT(no)
  274. werror_ok=1
  275. B10_CXXFLAGS="$B10_CXXFLAGS -Werror"],
  276. [AC_MSG_RESULT(yes)])
  277. CXXFLAGS="$CXXFLAGS_SAVED"
  278. # Python 3.2 has an unused parameter in one of its headers. This
  279. # has been reported, but not fixed as of yet, so we check if we need
  280. # to set -Wno-unused-parameter.
  281. if test $werror_ok = 1; then
  282. CPPFLAGS_SAVED="$CPPFLAGS"
  283. CPPFLAGS=${PYTHON_INCLUDES}
  284. CXXFLAGS_SAVED="$CXXFLAGS"
  285. CXXFLAGS="$CXXFLAGS $B10_CXXFLAGS -Werror"
  286. AC_MSG_CHECKING([whether we need -Wno-unused-parameter for python])
  287. AC_TRY_COMPILE(
  288. [#include <Python.h>],
  289. [],
  290. [AC_MSG_RESULT(no)],
  291. [
  292. CXXFLAGS="$CXXFLAGS -Wno-unused-parameter"
  293. AC_TRY_COMPILE([#include <Python.h>],
  294. [],
  295. [AC_MSG_RESULT(yes)
  296. PYTHON_CXXFLAGS="${PYTHON_CXXFLAGS} -Wno-unused-parameter"
  297. AC_SUBST(PYTHON_CXXFLAGS)
  298. ],
  299. [AC_MSG_ERROR([Can't compile against Python.h])]
  300. )
  301. ]
  302. )
  303. CXXFLAGS="$CXXFLAGS_SAVED"
  304. CPPFLAGS="$CPPFLAGS_SAVED"
  305. fi
  306. fi dnl GXX = yes
  307. AM_CONDITIONAL(GCC_WERROR_OK, test $werror_ok = 1)
  308. # produce PIC unless we disable shared libraries. need this for python bindings.
  309. if test $enable_shared != "no" -a "X$GXX" = "Xyes"; then
  310. B10_CXXFLAGS="$B10_CXXFLAGS -fPIC"
  311. fi
  312. AC_SUBST(B10_CXXFLAGS)
  313. # Checks for libraries.
  314. AC_SEARCH_LIBS(inet_pton, [nsl])
  315. AC_SEARCH_LIBS(recvfrom, [socket])
  316. AC_SEARCH_LIBS(nanosleep, [rt])
  317. # Checks for header files.
  318. # Checks for typedefs, structures, and compiler characteristics.
  319. AC_HEADER_STDBOOL
  320. AC_TYPE_SIZE_T
  321. # Detect OS type (it may be used to do OS-specific things, e.g.
  322. # interface detection in DHCP)
  323. AC_MSG_CHECKING(OS family)
  324. system=`uname -s`
  325. case $system in
  326. Linux)
  327. OS_TYPE="LINUX"
  328. CPPFLAGS="$CPPFLAGS -DOS_LINUX"
  329. ;;
  330. Darwin | FreeBSD | NetBSD | OpenBSD)
  331. OS_TYPE="BSD"
  332. CPPFLAGS="$CPPFLAGS -DOS_BSD"
  333. ;;
  334. Solaris)
  335. OS_TYPE="Solaris"
  336. CPPFLAGS="$CPPFLAGS -DOS_SOLARIS"
  337. ;;
  338. *)
  339. OS_TYPE="Unknown"
  340. AC_MSG_WARN("Unsupported OS: uname returned $system")
  341. ;;
  342. esac
  343. AC_MSG_RESULT($OS_TYPE)
  344. AM_CONDITIONAL(OS_LINUX, test $OS_TYPE = LINUX)
  345. AM_CONDITIONAL(OS_BSD, test $OS_TYPE = BSD)
  346. AM_CONDITIONAL(OS_SOLARIS, test $OS_TYPE = Solaris)
  347. AC_MSG_CHECKING(for sa_len in struct sockaddr)
  348. AC_TRY_COMPILE([
  349. #include <sys/types.h>
  350. #include <sys/socket.h>],
  351. [struct sockaddr sa; sa.sa_len = 0; return (0);],
  352. [AC_MSG_RESULT(yes)
  353. AC_DEFINE(HAVE_SA_LEN, 1, [Define to 1 if sockaddr has a sa_len member, and corresponding sin_len and sun_len])],
  354. AC_MSG_RESULT(no))
  355. AC_ARG_WITH(pycoverage,
  356. [ --with-pycoverage[=PROGRAM] enable python code coverage using the specified coverage], pycoverage="$withval", pycoverage="no")
  357. if test "$pycoverage" = "no" ; then
  358. # just run the tests normally with python
  359. PYCOVERAGE_RUN="${PYTHON}"
  360. USE_PYCOVERAGE="no"
  361. elif test "$pycoverage" = "yes" ; then
  362. PYCOVERAGE="coverage"
  363. PYCOVERAGE_RUN="${PYCOVERAGE} run --branch --append"
  364. USE_PYCOVERAGE="yes"
  365. else
  366. PYCOVERAGE="$pycoverage"
  367. PYCOVERAGE_RUN="${PYCOVERAGE} run --branch --append"
  368. USE_PYCOVERAGE="yes"
  369. fi
  370. AM_CONDITIONAL(ENABLE_PYTHON_COVERAGE, test x$USE_PYCOVERAGE != xno)
  371. AC_SUBST(PYCOVERAGE)
  372. AC_SUBST(PYCOVERAGE_RUN)
  373. AC_SUBST(USE_PYCOVERAGE)
  374. AC_ARG_WITH(lcov,
  375. [ --with-lcov[=PROGRAM] enable gtest and coverage target using the specified lcov], lcov="$withval", lcov="no")
  376. AC_ARG_WITH(gtest,
  377. [ --with-gtest=PATH specify a path to gtest header files (PATH/include) and library (PATH/lib)],
  378. gtest_path="$withval", gtest_path="no")
  379. USE_LCOV="no"
  380. if test "$lcov" != "no"; then
  381. # force gtest if not set
  382. if test "$gtest_path" = "no"; then
  383. # AC_MSG_ERROR("lcov needs gtest for test coverage report")
  384. AC_MSG_NOTICE([gtest support is now enabled, because used by coverage tests])
  385. gtest_path="yes"
  386. fi
  387. if test "$lcov" != "yes"; then
  388. LCOV=$lcov
  389. else
  390. AC_PATH_PROG([LCOV], [lcov])
  391. fi
  392. if test -x "${LCOV}"; then
  393. USE_LCOV="yes"
  394. else
  395. AC_MSG_ERROR([Cannot find lcov.])
  396. fi
  397. # is genhtml always in the same directory?
  398. GENHTML=`echo "$LCOV" | sed s/lcov$/genhtml/`
  399. if test ! -x $GENHTML; then
  400. AC_MSG_ERROR([genhtml not found, needed for lcov])
  401. fi
  402. # GCC specific?
  403. CXXFLAGS="$CXXFLAGS -fprofile-arcs -ftest-coverage"
  404. LIBS=" $LIBS -lgcov"
  405. AC_SUBST(CPPFLAGS)
  406. AC_SUBST(LIBS)
  407. AC_SUBST(LCOV)
  408. AC_SUBST(GENHTML)
  409. fi
  410. AC_SUBST(USE_LCOV)
  411. # Check for Botan
  412. botan_path="yes"
  413. AC_ARG_WITH([botan],
  414. AC_HELP_STRING([--with-botan=PATH],
  415. [specify exact directory of Botan library]),
  416. [botan_path="$withval"])
  417. if test "${botan_path}" = "no" ; then
  418. AC_MSG_ERROR([Need botan for libcryptolink])
  419. fi
  420. if test "${botan_path}" != "yes" ; then
  421. if test -x "${botan_path}/bin/botan-config" ; then
  422. BOTAN_CONFIG="${botan_path}/bin/botan-config"
  423. else
  424. AC_MSG_ERROR([${botan_path}/bin/botan-config not found])
  425. fi
  426. else
  427. # First see if pkg-config knows of it.
  428. # Unfortunately, the botan.pc files have their minor version in them
  429. # too, so we need to try them one by one
  430. BOTAN_CONFIG=""
  431. AC_PATH_PROG([PKG_CONFIG], [pkg-config])
  432. if test "$PKG_CONFIG" != "" ; then
  433. BOTAN_VERSIONS="botan-1.10 botan-1.9 botan-1.8"
  434. for version in $BOTAN_VERSIONS; do
  435. AC_MSG_CHECKING([Checking botan version with pkg-config $version])
  436. if [ $PKG_CONFIG --exists ${version} ]; then
  437. AC_MSG_RESULT([found])
  438. BOTAN_CONFIG="$PKG_CONFIG ${version}"
  439. break
  440. else
  441. AC_MSG_RESULT([not found])
  442. fi
  443. done
  444. fi
  445. # If we had no pkg-config, or it didn't know about botan, use botan-config
  446. if test "$BOTAN_CONFIG" = "" ; then
  447. AC_PATH_PROG([BOTAN_CONFIG], [botan-config])
  448. fi
  449. fi
  450. BOTAN_LDFLAGS=`${BOTAN_CONFIG} --libs`
  451. BOTAN_INCLUDES=`${BOTAN_CONFIG} --cflags`
  452. # We expect botan-config --libs to contain -L<path_to_libbotan>, but
  453. # this is not always the case. As a heuristics workaround we add
  454. # -L`botan-config --prefix/lib` in this case. Same for BOTAN_INCLUDES
  455. # (but using include instead of lib) below.
  456. if [ $BOTAN_CONFIG --prefix >/dev/null 2>&1 ] ; then
  457. echo ${BOTAN_LDFLAGS} | grep -- -L > /dev/null || \
  458. BOTAN_LDFLAGS="-L`${BOTAN_CONFIG} --prefix`/lib ${BOTAN_LDFLAGS}"
  459. echo ${BOTAN_INCLUDES} | grep -- -I > /dev/null || \
  460. BOTAN_INCLUDES="-I`${BOTAN_CONFIG} --prefix`/include ${BOTAN_INCLUDES}"
  461. fi
  462. # See python_rpath for some info on why we do this
  463. if test $rpath_available = yes; then
  464. BOTAN_RPATH=
  465. for flag in ${BOTAN_LDFLAGS}; do
  466. BOTAN_RPATH="${BOTAN_RPATH} `echo $flag | sed -ne 's/^\(\-L\)/-R/p'`"
  467. done
  468. AC_SUBST(BOTAN_RPATH)
  469. # According to the libtool manual, it should be sufficient if we
  470. # specify the "-R libdir" in our wrapper library of botan (no other
  471. # programs will need libbotan directly); "libdir" should be added to
  472. # the program's binary image. But we've seen in our build environments
  473. # that (some versions of?) libtool doesn't propagate -R as documented,
  474. # and it caused a linker error at run time. To work around this, we
  475. # also add the rpath to the global LDFLAGS.
  476. LDFLAGS="$BOTAN_RPATH $LDFLAGS"
  477. fi
  478. AC_SUBST(BOTAN_LDFLAGS)
  479. AC_SUBST(BOTAN_INCLUDES)
  480. CPPFLAGS_SAVED=$CPPFLAGS
  481. CPPFLAGS="$BOTAN_INCLUDES $CPPFLAGS"
  482. LDFLAGS_SAVED="$LDFLAGS"
  483. LDFLAGS="$BOTAN_LDFLAGS $LDFLAGS"
  484. AC_CHECK_HEADERS([botan/botan.h],,AC_MSG_ERROR([Missing required header files.]))
  485. AC_LINK_IFELSE(
  486. [AC_LANG_PROGRAM([#include <botan/botan.h>
  487. #include <botan/hash.h>
  488. ],
  489. [using namespace Botan;
  490. LibraryInitializer::initialize();
  491. HashFunction *h = get_hash("MD5");
  492. ])],
  493. [AC_MSG_RESULT([checking for Botan library... yes])],
  494. [AC_MSG_RESULT([checking for Botan library... no])
  495. AC_MSG_ERROR([Needs Botan library 1.8 or higher])]
  496. )
  497. CPPFLAGS=$CPPFLAGS_SAVED
  498. LDFLAGS=$LDFLAGS_SAVED
  499. # Check for log4cplus
  500. log4cplus_path="yes"
  501. AC_ARG_WITH([log4cplus],
  502. AC_HELP_STRING([--with-log4cplus=PATH],
  503. [specify exact directory of log4cplus library and headers]),
  504. [log4cplus_path="$withval"])
  505. if test "${log4cplus_path}" = "no" ; then
  506. AC_MSG_ERROR([Need log4cplus])
  507. elif test "${log4cplus_path}" != "yes" ; then
  508. LOG4CPLUS_INCLUDES="-I${log4cplus_path}/include"
  509. LOG4CPLUS_LDFLAGS="-L${log4cplus_path}/lib"
  510. else
  511. # If not specified, try some common paths.
  512. log4cplusdirs="/usr/local /usr/pkg /opt /opt/local"
  513. for d in $log4cplusdirs
  514. do
  515. if test -f $d/include/log4cplus/logger.h; then
  516. LOG4CPLUS_INCLUDES="-I$d/include"
  517. LOG4CPLUS_LDFLAGS="-L$d/lib"
  518. break
  519. fi
  520. done
  521. fi
  522. LOG4CPLUS_LDFLAGS="$LOG4CPLUS_LDFLAGS -llog4cplus $MULTITHREADING_FLAG"
  523. AC_SUBST(LOG4CPLUS_LDFLAGS)
  524. AC_SUBST(LOG4CPLUS_INCLUDES)
  525. CPPFLAGS_SAVED=$CPPFLAGS
  526. CPPFLAGS="$LOG4CPLUS_INCLUDES $CPPFLAGS"
  527. LDFLAGS_SAVED="$LDFLAGS"
  528. LDFLAGS="$LOG4CPLUS_LDFLAGS $LDFLAGS"
  529. AC_CHECK_HEADERS([log4cplus/logger.h],,AC_MSG_ERROR([Missing required header files.]))
  530. AC_LINK_IFELSE(
  531. [AC_LANG_PROGRAM([#include <log4cplus/logger.h>
  532. ],
  533. [using namespace log4cplus;
  534. Logger logger = Logger::getInstance("main");
  535. ])],
  536. [AC_MSG_RESULT([checking for log4cplus library... yes])],
  537. [AC_MSG_RESULT([checking for log4cplus library... no])
  538. AC_MSG_ERROR([Needs log4cplus library])]
  539. )
  540. CPPFLAGS=$CPPFLAGS_SAVED
  541. LDFLAGS=$LDFLAGS_SAVED
  542. #
  543. # Configure Boost header path
  544. #
  545. # If explicitly specified, use it.
  546. AC_ARG_WITH([boost-include],
  547. AC_HELP_STRING([--with-boost-include=PATH],
  548. [specify exact directory for Boost headers]),
  549. [boost_include_path="$withval"])
  550. # If not specified, try some common paths.
  551. if test -z "$with_boost_include"; then
  552. boostdirs="/usr/local /usr/pkg /opt /opt/local"
  553. for d in $boostdirs
  554. do
  555. if test -f $d/include/boost/shared_ptr.hpp; then
  556. boost_include_path=$d/include
  557. break
  558. fi
  559. done
  560. fi
  561. CPPFLAGS_SAVES="$CPPFLAGS"
  562. if test "${boost_include_path}" ; then
  563. BOOST_INCLUDES="-I${boost_include_path}"
  564. CPPFLAGS="$CPPFLAGS $BOOST_INCLUDES"
  565. fi
  566. AC_CHECK_HEADERS([boost/shared_ptr.hpp boost/foreach.hpp boost/interprocess/sync/interprocess_upgradable_mutex.hpp boost/date_time/posix_time/posix_time_types.hpp boost/bind.hpp boost/function.hpp],,
  567. AC_MSG_ERROR([Missing required header files.]))
  568. CPPFLAGS="$CPPFLAGS_SAVES"
  569. AC_SUBST(BOOST_INCLUDES)
  570. if test "${use_boost_threads}" = "yes" ; then
  571. AC_DEFINE([USE_BOOST_THREADS], [], [Use boost threads])
  572. # Using boost::mutex can result in requiring libboost_thread with older
  573. # versions of Boost. We'd like to avoid relying on a compiled Boost library
  574. # whenever possible, so we need to check for it step by step.
  575. #
  576. # NOTE: another fix of this problem is to simply require newer versions of
  577. # boost. If we choose that solution we should simplify the following tricky
  578. # checks accordingly and all Makefile.am's that refer to NEED_LIBBOOST_THREAD.
  579. AC_MSG_CHECKING(for boost::mutex)
  580. CPPFLAGS_SAVES="$CPPFLAGS"
  581. LIBS_SAVES="$LIBS"
  582. CPPFLAGS="$BOOST_INCLUDES $CPPFLAGS $MULTITHREADING_FLAG"
  583. need_libboost_thread=0
  584. need_sunpro_workaround=0
  585. AC_TRY_LINK([
  586. #include <boost/thread.hpp>
  587. ],[
  588. boost::mutex m;
  589. ],
  590. [ AC_MSG_RESULT(yes (without libboost_thread)) ],
  591. # there is one specific problem with SunStudio 5.10
  592. # where including boost/thread causes a compilation failure
  593. # There is a workaround in boost but it checks the version not being 5.10
  594. # This will probably be fixed in the future, in which case this
  595. # is only a temporary workaround
  596. [ AC_TRY_LINK([
  597. #if defined(__SUNPRO_CC) && __SUNPRO_CC == 0x5100
  598. #undef __SUNPRO_CC
  599. #define __SUNPRO_CC 0x5090
  600. #endif
  601. #include <boost/thread.hpp>
  602. ],[
  603. boost::mutex m;
  604. ],
  605. [ AC_MSG_RESULT(yes (with SUNOS workaround))
  606. need_sunpro_workaround=1 ],
  607. [ LIBS=" $LIBS -lboost_thread"
  608. AC_TRY_LINK([
  609. #include <boost/thread.hpp>
  610. ],[
  611. boost::mutex m;
  612. ],
  613. [ AC_MSG_RESULT(yes (with libboost_thread))
  614. need_libboost_thread=1 ],
  615. [ AC_MSG_RESULT(no)
  616. AC_MSG_ERROR([boost::mutex cannot be linked in this build environment.
  617. Perhaps you are using an older version of Boost that requires libboost_thread for the mutex support, which does not appear to be available.
  618. You may want to check the availability of the library or to upgrade Boost.])
  619. ])])])
  620. CPPFLAGS="$CPPFLAGS_SAVES"
  621. LIBS="$LIBS_SAVES"
  622. AM_CONDITIONAL(NEED_LIBBOOST_THREAD, test $need_libboost_thread = 1)
  623. if test $need_sunpro_workaround = 1; then
  624. AC_DEFINE([NEED_SUNPRO_WORKAROUND], [], [Need boost sunstudio workaround])
  625. fi
  626. else
  627. AM_CONDITIONAL(NEED_LIBBOOST_THREAD, test "${use_boost_threads}" = "yes")
  628. fi
  629. #
  630. # Check availability of gtest, which will be used for unit tests.
  631. #
  632. if test "$gtest_path" != "no"
  633. then
  634. DISTCHECK_GTEST_CONFIGURE_FLAG="--with-gtest=\"$gtest_path\""
  635. if test "$gtest_path" != "yes"; then
  636. GTEST_PATHS=$gtest_path
  637. if test -x "${gtest_path}/bin/gtest-config" ; then
  638. GTEST_CONFIG="${gtest_path}/bin/gtest-config"
  639. fi
  640. else
  641. AC_PATH_PROG([GTEST_CONFIG], [gtest-config])
  642. fi
  643. if test -x "${GTEST_CONFIG}" ; then :
  644. # using cppflags instead of cxxflags
  645. GTEST_INCLUDES=`${GTEST_CONFIG} --cppflags`
  646. GTEST_LDFLAGS=`${GTEST_CONFIG} --ldflags`
  647. GTEST_LDADD=`${GTEST_CONFIG} --libs`
  648. GTEST_FOUND="true"
  649. else
  650. AC_MSG_WARN([Unable to locate Google Test gtest-config.])
  651. if test -z "${GTEST_PATHS}" ; then
  652. GTEST_PATHS="/usr /usr/local"
  653. fi
  654. GTEST_FOUND="false"
  655. fi
  656. if test "${GTEST_FOUND}" != "true"; then
  657. GTEST_FOUND="false"
  658. for dir in $GTEST_PATHS; do
  659. if test -f "$dir/include/gtest/gtest.h"; then
  660. GTEST_INCLUDES="-I$dir/include"
  661. GTEST_LDFLAGS="-L$dir/lib"
  662. GTEST_LDADD="-lgtest"
  663. GTEST_FOUND="true"
  664. break
  665. fi
  666. done
  667. fi
  668. if test "${GTEST_FOUND}" != "true"; then
  669. AC_MSG_ERROR([Cannot find gtest in: $GTEST_PATHS])
  670. fi
  671. else
  672. GTEST_INCLUDES=
  673. GTEST_LDFLAGS=
  674. GTEST_LDADD=
  675. DISTCHECK_GTEST_CONFIGURE_FLAG=
  676. fi
  677. AM_CONDITIONAL(HAVE_GTEST, test $gtest_path != "no")
  678. AC_SUBST(DISTCHECK_GTEST_CONFIGURE_FLAG)
  679. AC_SUBST(GTEST_INCLUDES)
  680. AC_SUBST(GTEST_LDFLAGS)
  681. AC_SUBST(GTEST_LDADD)
  682. dnl check for pkg-config itself so we don't try the m4 macro without pkg-config
  683. AC_CHECK_PROG(HAVE_PKG_CONFIG, pkg-config, yes, no)
  684. if test "x$HAVE_PKG_CONFIG" = "xno" ; then
  685. AC_MSG_ERROR(Please install pkg-config)
  686. fi
  687. PKG_CHECK_MODULES(SQLITE, sqlite3 >= 3.3.9, enable_features="$enable_features SQLite3")
  688. # I can't get some of the #include <asio.hpp> right without this
  689. # TODO: find the real cause of asio/boost wanting pthreads
  690. # (this currently only occurs for src/lib/cc/session_unittests)
  691. PTHREAD_LDFLAGS=
  692. AC_CHECK_LIB(pthread, pthread_create,[ PTHREAD_LDFLAGS=-lpthread ], [])
  693. AC_SUBST(PTHREAD_LDFLAGS)
  694. AC_SUBST(MULTITHREADING_FLAG)
  695. #
  696. # ASIO: we extensively use it as the C++ event management module.
  697. #
  698. # Use local ASIO headers from ext
  699. #
  700. CPPFLAGS="$CPPFLAGS -I\$(top_srcdir)/ext/asio"
  701. #
  702. # Use our 'coroutine' header from ext
  703. CPPFLAGS="$CPPFLAGS -I\$(top_srcdir)/ext/coroutine"
  704. #
  705. # Disable threads: Currently we don't use them.
  706. CPPFLAGS="$CPPFLAGS -DASIO_DISABLE_THREADS=1"
  707. #
  708. # kqueue portability: ASIO uses kqueue by default if it's available (it's
  709. # generally available in BSD variants). Unfortunately, some public
  710. # implementation of kqueue forces a conversion from a pointer to an integer,
  711. # which is prohibited in C++ unless reinterpret_cast, C++'s most evil beast
  712. # (and ASIO doesn't use it anyway) is used. This will cause build error for
  713. # some of our C++ files including ASIO header files. The following check
  714. # detects such cases and tells ASIO not to use kqueue if so.
  715. AC_CHECK_FUNC(kqueue, ac_cv_have_kqueue=yes, ac_cv_have_kqueue=no)
  716. if test "X$ac_cv_have_kqueue" = "Xyes"; then
  717. AC_MSG_CHECKING([whether kqueue EV_SET compiles in C++])
  718. AC_TRY_COMPILE([
  719. #include <sys/types.h>
  720. #include <sys/param.h>
  721. #include <sys/event.h>],
  722. [char* udata;
  723. EV_SET(NULL, 0, 0, 0, 0, 0, udata);],
  724. [AC_MSG_RESULT(yes)],
  725. [AC_MSG_RESULT([no, disable kqueue for ASIO])
  726. CPPFLAGS="$CPPFLAGS -DASIO_DISABLE_KQUEUE=1"
  727. ])
  728. fi
  729. # /dev/poll issue: ASIO uses /dev/poll by default if it's available (generally
  730. # the case with Solaris). Unfortunately its /dev/poll specific code would
  731. # trigger the gcc's "missing-field-initializers" warning, which would
  732. # subsequently make the build fail with -Werror. Further, older versions of
  733. # gcc don't provide an option to selectively suppress this warning.
  734. # So, for the moment, we simply disable the use of /dev/poll. Unless we
  735. # implement recursive DNS server with randomized ports, we don't need the
  736. # scalability that /dev/poll can provide, so this decision wouldn't affect
  737. # run time performance. Hopefully we can find a better solution or the ASIO
  738. # code will be updated by the time we really need it.
  739. AC_CHECK_HEADERS(sys/devpoll.h, ac_cv_have_devpoll=yes, ac_cv_have_devpoll=no)
  740. if test "X$ac_cv_have_devpoll" = "Xyes" -a "X$GXX" = "Xyes"; then
  741. CPPFLAGS="$CPPFLAGS -DASIO_DISABLE_DEV_POLL=1"
  742. fi
  743. #
  744. # Perl is optional; it is used only by some of the system test scripts.
  745. #
  746. AC_PATH_PROGS(PERL, perl5 perl)
  747. AC_SUBST(PERL)
  748. AC_PATH_PROGS(AWK, gawk awk)
  749. AC_SUBST(AWK)
  750. AC_ARG_ENABLE(man, [AC_HELP_STRING([--enable-man],
  751. [regenerate man pages [default=no]])], enable_man=yes, enable_man=no)
  752. AM_CONDITIONAL(ENABLE_MAN, test x$enable_man != xno)
  753. AC_ARG_ENABLE(install-configurations,
  754. [AC_HELP_STRING([--disable-install-configurations],
  755. [do not install configuration])], install_configurations=$enableval, install_configurations=yes)
  756. AM_CONDITIONAL(INSTALL_CONFIGURATIONS, test x$install_configurations = xyes || test x$install_configurations = xtrue)
  757. AC_CONFIG_FILES([Makefile
  758. doc/Makefile
  759. doc/guide/Makefile
  760. compatcheck/Makefile
  761. src/Makefile
  762. src/bin/Makefile
  763. src/bin/bind10/Makefile
  764. src/bin/bind10/tests/Makefile
  765. src/bin/cmdctl/Makefile
  766. src/bin/cmdctl/tests/Makefile
  767. src/bin/bindctl/Makefile
  768. src/bin/bindctl/tests/Makefile
  769. src/bin/cfgmgr/Makefile
  770. src/bin/cfgmgr/plugins/Makefile
  771. src/bin/cfgmgr/plugins/tests/Makefile
  772. src/bin/cfgmgr/tests/Makefile
  773. src/bin/host/Makefile
  774. src/bin/loadzone/Makefile
  775. src/bin/loadzone/tests/correct/Makefile
  776. src/bin/loadzone/tests/error/Makefile
  777. src/bin/msgq/Makefile
  778. src/bin/msgq/tests/Makefile
  779. src/bin/auth/Makefile
  780. src/bin/auth/tests/Makefile
  781. src/bin/auth/benchmarks/Makefile
  782. src/bin/dhcp6/Makefile
  783. src/bin/dhcp6/tests/Makefile
  784. src/bin/dhcp4/Makefile
  785. src/bin/dhcp4/tests/Makefile
  786. src/bin/resolver/Makefile
  787. src/bin/resolver/tests/Makefile
  788. src/bin/sockcreator/Makefile
  789. src/bin/sockcreator/tests/Makefile
  790. src/bin/xfrin/Makefile
  791. src/bin/xfrin/tests/Makefile
  792. src/bin/xfrin/tests/testdata/Makefile
  793. src/bin/xfrout/Makefile
  794. src/bin/xfrout/tests/Makefile
  795. src/bin/zonemgr/Makefile
  796. src/bin/zonemgr/tests/Makefile
  797. src/bin/stats/Makefile
  798. src/bin/stats/tests/Makefile
  799. src/bin/usermgr/Makefile
  800. src/bin/tests/Makefile
  801. src/lib/Makefile
  802. src/lib/asiolink/Makefile
  803. src/lib/asiolink/tests/Makefile
  804. src/lib/asiodns/Makefile
  805. src/lib/asiodns/tests/Makefile
  806. src/lib/bench/Makefile
  807. src/lib/bench/example/Makefile
  808. src/lib/bench/tests/Makefile
  809. src/lib/cc/Makefile
  810. src/lib/cc/tests/Makefile
  811. src/lib/python/Makefile
  812. src/lib/python/isc/Makefile
  813. src/lib/python/isc/acl/Makefile
  814. src/lib/python/isc/acl/tests/Makefile
  815. src/lib/python/isc/util/Makefile
  816. src/lib/python/isc/util/tests/Makefile
  817. src/lib/python/isc/datasrc/Makefile
  818. src/lib/python/isc/datasrc/tests/Makefile
  819. src/lib/python/isc/dns/Makefile
  820. src/lib/python/isc/cc/Makefile
  821. src/lib/python/isc/cc/tests/Makefile
  822. src/lib/python/isc/config/Makefile
  823. src/lib/python/isc/config/tests/Makefile
  824. src/lib/python/isc/log/Makefile
  825. src/lib/python/isc/log/tests/Makefile
  826. src/lib/python/isc/log_messages/Makefile
  827. src/lib/python/isc/log_messages/work/Makefile
  828. src/lib/python/isc/net/Makefile
  829. src/lib/python/isc/net/tests/Makefile
  830. src/lib/python/isc/notify/Makefile
  831. src/lib/python/isc/notify/tests/Makefile
  832. src/lib/python/isc/testutils/Makefile
  833. src/lib/python/isc/bind10/Makefile
  834. src/lib/python/isc/bind10/tests/Makefile
  835. src/lib/python/isc/xfrin/Makefile
  836. src/lib/python/isc/xfrin/tests/Makefile
  837. src/lib/config/Makefile
  838. src/lib/config/tests/Makefile
  839. src/lib/config/tests/testdata/Makefile
  840. src/lib/cryptolink/Makefile
  841. src/lib/cryptolink/tests/Makefile
  842. src/lib/dns/Makefile
  843. src/lib/dns/tests/Makefile
  844. src/lib/dns/tests/testdata/Makefile
  845. src/lib/dns/python/Makefile
  846. src/lib/dns/python/tests/Makefile
  847. src/lib/dns/benchmarks/Makefile
  848. src/lib/dhcp/Makefile
  849. src/lib/dhcp/tests/Makefile
  850. src/lib/exceptions/Makefile
  851. src/lib/exceptions/tests/Makefile
  852. src/lib/datasrc/Makefile
  853. src/lib/datasrc/tests/Makefile
  854. src/lib/datasrc/tests/testdata/Makefile
  855. src/lib/xfr/Makefile
  856. src/lib/log/Makefile
  857. src/lib/log/compiler/Makefile
  858. src/lib/log/tests/Makefile
  859. src/lib/resolve/Makefile
  860. src/lib/resolve/tests/Makefile
  861. src/lib/testutils/Makefile
  862. src/lib/testutils/testdata/Makefile
  863. src/lib/nsas/Makefile
  864. src/lib/nsas/tests/Makefile
  865. src/lib/cache/Makefile
  866. src/lib/cache/tests/Makefile
  867. src/lib/server_common/Makefile
  868. src/lib/server_common/tests/Makefile
  869. src/lib/util/Makefile
  870. src/lib/util/io/Makefile
  871. src/lib/util/unittests/Makefile
  872. src/lib/util/python/Makefile
  873. src/lib/util/pyunittests/Makefile
  874. src/lib/util/tests/Makefile
  875. src/lib/acl/Makefile
  876. src/lib/acl/tests/Makefile
  877. tests/Makefile
  878. tests/system/Makefile
  879. tests/tools/Makefile
  880. tests/tools/badpacket/Makefile
  881. tests/tools/badpacket/tests/Makefile
  882. ])
  883. AC_OUTPUT([doc/version.ent
  884. compatcheck/sqlite3-difftbl-check.py
  885. src/bin/cfgmgr/b10-cfgmgr.py
  886. src/bin/cfgmgr/tests/b10-cfgmgr_test.py
  887. src/bin/cmdctl/cmdctl.py
  888. src/bin/cmdctl/run_b10-cmdctl.sh
  889. src/bin/cmdctl/tests/cmdctl_test
  890. src/bin/cmdctl/cmdctl.spec.pre
  891. src/bin/xfrin/tests/xfrin_test
  892. src/bin/xfrin/xfrin.py
  893. src/bin/xfrin/run_b10-xfrin.sh
  894. src/bin/xfrout/xfrout.py
  895. src/bin/xfrout/xfrout.spec.pre
  896. src/bin/xfrout/tests/xfrout_test
  897. src/bin/xfrout/tests/xfrout_test.py
  898. src/bin/xfrout/run_b10-xfrout.sh
  899. src/bin/resolver/resolver.spec.pre
  900. src/bin/resolver/spec_config.h.pre
  901. src/bin/zonemgr/zonemgr.py
  902. src/bin/zonemgr/zonemgr.spec.pre
  903. src/bin/zonemgr/tests/zonemgr_test
  904. src/bin/zonemgr/run_b10-zonemgr.sh
  905. src/bin/stats/stats.py
  906. src/bin/stats/stats_httpd.py
  907. src/bin/bind10/bind10_src.py
  908. src/bin/bind10/run_bind10.sh
  909. src/bin/bind10/tests/bind10_test.py
  910. src/bin/bindctl/run_bindctl.sh
  911. src/bin/bindctl/bindctl_main.py
  912. src/bin/bindctl/tests/bindctl_test
  913. src/bin/loadzone/run_loadzone.sh
  914. src/bin/loadzone/tests/correct/correct_test.sh
  915. src/bin/loadzone/tests/error/error_test.sh
  916. src/bin/loadzone/b10-loadzone.py
  917. src/bin/usermgr/run_b10-cmdctl-usermgr.sh
  918. src/bin/usermgr/b10-cmdctl-usermgr.py
  919. src/bin/msgq/msgq.py
  920. src/bin/msgq/tests/msgq_test
  921. src/bin/msgq/run_msgq.sh
  922. src/bin/auth/auth.spec.pre
  923. src/bin/auth/spec_config.h.pre
  924. src/bin/dhcp4/spec_config.h.pre
  925. src/bin/dhcp6/spec_config.h.pre
  926. src/bin/tests/process_rename_test.py
  927. src/lib/config/tests/data_def_unittests_config.h
  928. src/lib/python/isc/config/tests/config_test
  929. src/lib/python/isc/cc/tests/cc_test
  930. src/lib/python/isc/notify/tests/notify_out_test
  931. src/lib/python/isc/log/tests/log_console.py
  932. src/lib/python/isc/log_messages/work/__init__.py
  933. src/lib/dns/gen-rdatacode.py
  934. src/lib/python/bind10_config.py
  935. src/lib/cc/session_config.h.pre
  936. src/lib/cc/tests/session_unittests_config.h
  937. src/lib/log/tests/console_test.sh
  938. src/lib/log/tests/destination_test.sh
  939. src/lib/log/tests/init_logger_test.sh
  940. src/lib/log/tests/local_file_test.sh
  941. src/lib/log/tests/severity_test.sh
  942. src/lib/log/tests/tempdir.h
  943. src/lib/util/python/mkpywrapper.py
  944. src/lib/util/python/gen_wiredata.py
  945. src/lib/server_common/tests/data_path.h
  946. tests/lettuce/setup_intree_bind10.sh
  947. tests/system/conf.sh
  948. tests/system/run.sh
  949. tests/system/glue/setup.sh
  950. tests/system/glue/nsx1/b10-config.db
  951. tests/system/bindctl/nsx1/b10-config.db.template
  952. tests/system/ixfr/db.example.n0
  953. tests/system/ixfr/db.example.n2
  954. tests/system/ixfr/db.example.n2.refresh
  955. tests/system/ixfr/db.example.n4
  956. tests/system/ixfr/db.example.n6
  957. tests/system/ixfr/ixfr_init.sh
  958. tests/system/ixfr/b10-config.db
  959. tests/system/ixfr/common_tests.sh
  960. tests/system/ixfr/in-1/setup.sh
  961. tests/system/ixfr/in-2/setup.sh
  962. tests/system/ixfr/in-3/setup.sh
  963. tests/system/ixfr/in-4/setup.sh
  964. ], [
  965. chmod +x compatcheck/sqlite3-difftbl-check.py
  966. chmod +x src/bin/cmdctl/run_b10-cmdctl.sh
  967. chmod +x src/bin/xfrin/run_b10-xfrin.sh
  968. chmod +x src/bin/xfrout/run_b10-xfrout.sh
  969. chmod +x src/bin/zonemgr/run_b10-zonemgr.sh
  970. chmod +x src/bin/bind10/run_bind10.sh
  971. chmod +x src/bin/cmdctl/tests/cmdctl_test
  972. chmod +x src/bin/xfrin/tests/xfrin_test
  973. chmod +x src/bin/xfrout/tests/xfrout_test
  974. chmod +x src/bin/zonemgr/tests/zonemgr_test
  975. chmod +x src/bin/bindctl/tests/bindctl_test
  976. chmod +x src/bin/bindctl/run_bindctl.sh
  977. chmod +x src/bin/loadzone/run_loadzone.sh
  978. chmod +x src/bin/loadzone/tests/correct/correct_test.sh
  979. chmod +x src/bin/loadzone/tests/error/error_test.sh
  980. chmod +x src/bin/usermgr/run_b10-cmdctl-usermgr.sh
  981. chmod +x src/bin/msgq/run_msgq.sh
  982. chmod +x src/bin/msgq/tests/msgq_test
  983. chmod +x src/lib/dns/gen-rdatacode.py
  984. chmod +x src/lib/log/tests/console_test.sh
  985. chmod +x src/lib/log/tests/destination_test.sh
  986. chmod +x src/lib/log/tests/init_logger_test.sh
  987. chmod +x src/lib/log/tests/local_file_test.sh
  988. chmod +x src/lib/log/tests/severity_test.sh
  989. chmod +x src/lib/util/python/mkpywrapper.py
  990. chmod +x src/lib/util/python/gen_wiredata.py
  991. chmod +x src/lib/python/isc/log/tests/log_console.py
  992. chmod +x tests/system/conf.sh
  993. chmod +x tests/system/run.sh
  994. chmod +x tests/system/ixfr/ixfr_init.sh
  995. chmod +x tests/system/ixfr/common_tests.sh
  996. chmod +x tests/system/ixfr/in-1/setup.sh
  997. chmod +x tests/system/ixfr/in-2/setup.sh
  998. chmod +x tests/system/ixfr/in-3/setup.sh
  999. chmod +x tests/system/ixfr/in-4/setup.sh
  1000. ])
  1001. AC_OUTPUT
  1002. dnl Print the results
  1003. dnl
  1004. cat > config.report << END
  1005. BIND 10 source configure results:
  1006. -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
  1007. Package:
  1008. Name: $PACKAGE_NAME
  1009. Version: $PACKAGE_VERSION
  1010. C++ Compiler: $CXX
  1011. Flags:
  1012. DEFS: $DEFS
  1013. CPPFLAGS: $CPPFLAGS
  1014. CXXFLAGS: $CXXFLAGS
  1015. LDFLAGS: $LDFLAGS
  1016. B10_CXXFLAGS: $B10_CXXFLAGS
  1017. OS Family: $OS_TYPE
  1018. dnl includes too
  1019. Python: ${PYTHON_INCLUDES}
  1020. ${PYTHON_CXXFLAGS}
  1021. ${PYTHON_LDFLAGS}
  1022. ${PYTHON_LIB}
  1023. Boost: ${BOOST_INCLUDES}
  1024. Botan: ${BOTAN_INCLUDES}
  1025. ${BOTAN_LDFLAGS}
  1026. Log4cplus: ${LOG4CPLUS_INCLUDES}
  1027. ${LOG4CPLUS_LDFLAGS}
  1028. SQLite: $SQLITE_CFLAGS
  1029. $SQLITE_LIBS
  1030. Features:
  1031. $enable_features
  1032. Developer:
  1033. Google Tests: $gtest_path
  1034. C++ Code Coverage: $USE_LCOV
  1035. Python Code Coverage: $USE_PYCOVERAGE
  1036. Generate Manuals: $enable_man
  1037. END
  1038. cat config.report
  1039. cat <<EOF
  1040. Now you can type "make" to build BIND 10
  1041. EOF