1 dnl configure.ac: Autoconfiscation for Subversion
2 dnl Process this file with autoconf to produce a configure script.
6 dnl Get the version of Subversion, using m4's esyscmd() command to do this
7 dnl at m4-time, since AC_INIT() requires it then.
9 [esyscmd(python build/getversion.py subversion/include/svn_version.h)],
10 [http://subversion.tigris.org/])
12 AC_CONFIG_SRCDIR(subversion/include/svn_types.h)
13 AC_CONFIG_AUX_DIR([build])
15 AC_MSG_NOTICE([Configuring Subversion ]AC_PACKAGE_VERSION)
17 AC_SUBST([abs_srcdir], ["`cd $srcdir && pwd`"])
18 AC_SUBST([abs_builddir], ["`pwd`"])
20 # Generate config.nice early (before the arguments are munged)
21 SVN_CONFIG_NICE(config.nice)
23 # ==== Check for programs ====================================================
25 # Look for a C compiler (before anything can set CFLAGS)
28 # Look for a C pre-processor
31 # Grab target_cpu, so we can use it in the Solaris pkginfo file
34 # Look for an extended grep, this macro appeared in autoconf-2.53b,
35 # before that, the search for an EGREP was always performed.
36 ifdef([AC_PROG_EGREP],[AC_PROG_EGREP],[])
41 # If $INSTALL is relative path to our fallback install-sh, then convert
42 # to an absolute path, as in some cases (e.g. Solaris VPATH build), libtool
43 # may try to use it from a changed working directory.
44 if test "$INSTALL" = "build/install-sh -c"; then
45 INSTALL="$abs_srcdir/$INSTALL"
48 AC_SUBST([MKDIR], ["$INSTALL -d"])
51 dnl find Apache with a recent-enough magic module number.
52 SVN_FIND_APACHE(20020903)
54 # ==== Libraries, for which we may have source to build ======================
56 dnl verify apr version and set apr flags
57 dnl These regular expressions should not contain "\(" and "\)".
58 dnl The specific reason we require APR 0.9.7 is:
59 dnl It contains fixes to its file writing routines
60 dnl now generating errors instead of silently ignoring
61 dnl them. Only .7 and later can guarantee repository
62 dnl integrity with FSFS.
64 APR_VER_REGEXES=["0\.9\.[7-9] 0\.9\.1[0-9] 1\."]
65 APU_VER_REGEXES=["0\.9\.[7-9] 0\.9\.1[0-9] 1\."]
67 SVN_LIB_APR($APR_VER_REGEXES)
68 SVN_LIB_APRUTIL($APU_VER_REGEXES)
70 # Either a space-separated list of allowable Neon versions, or "any" to
71 # mean allow anything.
72 NEON_ALLOWED_LIST="0.25.0 0.25.1 0.25.2 0.25.3 0.25.4 0.25.5 0.26.0 0.26.1 0.26.2 0.26.3 0.26.4 0.27.2"
73 NEON_RECOMMENDED_VER=0.27.2
74 NEON_URL="http://www.webdav.org/neon/neon-${NEON_RECOMMENDED_VER}.tar.gz"
75 dnl You can skip the neon version check only if you know what you are doing
76 AC_ARG_ENABLE(neon-version-check,
77 AS_HELP_STRING([--disable-neon-version-check],
78 [do not check the Neon version]),
80 if test "$enableval" = "no" ; then
81 NEON_ALLOWED_LIST="any"
85 SVN_LIB_NEON($NEON_ALLOWED_LIST, $NEON_RECOMMENDED_VER, $NEON_URL)
87 dnl Search for serf as an alternative to neon
91 SQLITE_ALLOWED_LIST="3.*"
92 SQLITE_RECOMMENDED_VER="3.5.3"
93 SQLITE_URL="http://www.sqlite.org/sqlite-${SQLITE_RECOMMENDED_VER}.tar.gz"
94 SVN_LIB_SQLITE($SQLITE_ALLOWED_LIST, $SQLITE_RECOMMENDED_VER, $SQLITE_URL)
96 dnl Set up a number of directories ---------------------
98 dnl Create SVN_BINDIR for proper substitution
99 if test "${bindir}" = '${exec_prefix}/bin'; then
100 if test "${exec_prefix}" = "NONE"; then
101 if test "${prefix}" = "NONE"; then
102 SVN_BINDIR="${ac_default_prefix}/bin"
104 SVN_BINDIR="${prefix}/bin"
107 SVN_BINDIR="${exec_prefix}/bin"
110 SVN_BINDIR="${bindir}"
113 dnl fully evaluate this value. when we substitute it into our tool scripts,
114 dnl they will not have things such as ${bindir} available
115 SVN_BINDIR="`eval echo ${SVN_BINDIR}`"
118 dnl provide ${bindir} in svn_private_config.h for use in compiled code
119 AC_DEFINE_UNQUOTED(SVN_BINDIR, "${SVN_BINDIR}",
120 [Defined to be the path to the installed binaries])
122 dnl This purposely does *not* allow for multiple parallel installs.
123 dnl However, it is compatible with most gettext usages.
124 localedir='${datadir}/locale'
127 dnl For SVN_LOCALE_DIR, we have to expand it to something. See SVN_BINDIR.
128 if test "${datadir}" = '${prefix}/share' && test "${prefix}" = "NONE"; then
129 exp_localedir='${ac_default_prefix}/share/locale'
131 exp_localedir=$localedir
133 SVN_EXPAND_VAR(svn_localedir, "${exp_localedir}")
134 AC_DEFINE_UNQUOTED(SVN_LOCALE_DIR, "${svn_localedir}",
135 [Defined to be the path to the installed locale dirs])
137 dnl Check for libtool -- we'll definitely need it for all our shared libs!
138 echo "configuring libtool now"
139 AC_ARG_ENABLE(experimental-libtool,
140 AS_HELP_STRING([--enable-experimental-libtool],[Use APR's libtool]),
141 [experimental_libtool=$enableval],[experimental_libtool=no])
143 if test "$experimental_libtool" = "yes"; then
144 echo "using APR's libtool"
145 sh_libtool="`$apr_config --apr-libtool`"
146 LIBTOOL="$sh_libtool"
147 SVN_LIBTOOL="$sh_libtool"
149 sh_libtool="$abs_builddir/libtool"
150 SVN_LIBTOOL="\$(SHELL) $sh_libtool"
151 dnl libtoolize requires that the following line not be indented
154 AC_SUBST(SVN_LIBTOOL)
156 dnl Determine if the libtool version supports --tag or not
159 AC_MSG_CHECKING([whether libtool accepts --tag=XXX])
161 AC_LANG_CONFTEST([AC_LANG_PROGRAM()])
162 if $sh_libtool --tag=CC --mode=compile \
163 $CC -c $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext >&5
166 SVN_LT_CCTAG="--tag=CC"
167 SVN_LT_CXXTAG="--tag=CXX"
172 rm -f conftest.$ac_ext
173 AC_SUBST(SVN_LT_CCTAG)
174 AC_SUBST(SVN_LT_CXXTAG)
176 dnl Before configuring libtool check for --enable-all-static option
177 AC_ARG_ENABLE(all-static,
178 AS_HELP_STRING([--enable-all-static],
179 [Build completely static (standalone) binaries.]),
181 if test "$enableval" = "yes" ; then
182 LT_LDFLAGS="-all-static $LT_LDFLAGS"
188 dnl Check if -no-undefined is needed for the platform.
189 dnl It should always work but with libtool 1.4.3 on OS X it breaks the build.
190 dnl So we only turn it on for platforms where we know we really need it.
191 AC_MSG_CHECKING([whether libtool needs -no-undefined])
195 LT_NO_UNDEFINED="-no-undefined"
202 AC_SUBST(LT_NO_UNDEFINED)
204 AC_MSG_CHECKING([whether to avoid circular linkage at all costs])
208 AC_DEFINE([SVN_AVOID_CIRCULAR_LINKAGE_AT_ALL_COSTS_HACK], 1,
209 [Define if circular linkage is not possible on this platform.])
219 AS_HELP_STRING([--with-trang=PATH],
220 [Specify the command to run the trang schema converter]),
224 if test "$trang" = "yes"; then
225 AC_PATH_PROG(TRANG, trang, none)
232 dnl Check for libraries --------------------
234 # Berkeley DB on SCO OpenServer needs -lsocket
235 AC_CHECK_LIB(socket, socket)
237 # Build the BDB filesystem library only if we have an appropriate
238 # version of Berkeley DB.
240 powerpc-apple-darwin*)
241 # Berkeley DB 4.0 does not work on OS X.
242 SVN_FS_WANT_DB_MAJOR=4
243 SVN_FS_WANT_DB_MINOR=1
244 SVN_FS_WANT_DB_PATCH=25
247 SVN_FS_WANT_DB_MAJOR=4
248 SVN_FS_WANT_DB_MINOR=0
249 SVN_FS_WANT_DB_PATCH=14
252 # Look for libdb4.so first:
253 SVN_LIB_BERKELEY_DB($SVN_FS_WANT_DB_MAJOR, $SVN_FS_WANT_DB_MINOR,
254 $SVN_FS_WANT_DB_PATCH, [db4 db])
256 AC_DEFINE_UNQUOTED(SVN_FS_WANT_DB_MAJOR, $SVN_FS_WANT_DB_MAJOR,
257 [The desired major version for the Berkeley DB])
258 AC_DEFINE_UNQUOTED(SVN_FS_WANT_DB_MINOR, $SVN_FS_WANT_DB_MINOR,
259 [The desired minor version for the Berkeley DB])
260 AC_DEFINE_UNQUOTED(SVN_FS_WANT_DB_PATCH, $SVN_FS_WANT_DB_PATCH,
261 [The desired patch version for the Berkeley DB])
265 if test "$svn_lib_sasl" = "yes"; then
266 AC_DEFINE(SVN_HAVE_SASL, 1,
267 [Defined if Cyrus SASL v2 is present on the system])
270 dnl Mac OS KeyChain -------------------
272 AC_ARG_ENABLE(keychain,
273 AS_HELP_STRING([--disable-keychain],
274 [Disable use of Mac OS KeyChain for auth credentials]),
275 [enable_keychain=$enableval],[enable_keychain=yes])
277 AC_MSG_CHECKING([for Mac OS KeyChain Services])
279 if test "$enable_keychain" = "yes"; then
280 AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <AvailabilityMacros.h>
281 #if !DARWIN || (MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_2)
282 #error KeyChain API unavailable.
283 #endif]], [[]])],[],[enable_keychain=no])
286 if test "$enable_keychain" = "yes"; then
287 dnl ### Hack. We should only need to pass the -framework options when
288 dnl linking libsvn_subr, since it is the only library that uses Keychain.
290 dnl Unfortunately, libtool 1.5.x doesn't track transitive dependencies for
291 dnl OS X frameworks like it does for normal libraries, so we need to
292 dnl explicitly pass the option to all the users of libsvn_subr to allow
293 dnl static builds to link successfully.
295 dnl This does mean that all executables we link will be linked directly
296 dnl to these frameworks - even when building shared libraries - but that
297 dnl shouldn't cause any problems.
298 LIBS="$LIBS -framework Security"
299 LIBS="$LIBS -framework CoreFoundation"
300 LIBS="$LIBS -framework CoreServices"
301 AC_DEFINE([SVN_HAVE_KEYCHAIN_SERVICES], [1], [Is Mac OS KeyChain support enabled?])
308 dnl I18n -------------------
311 AS_HELP_STRING([--disable-nls],[Disable gettext functionality]),
312 [enable_nls=$enableval],[enable_nls=yes])
315 if test "$enable_nls" = "yes"; then
316 dnl First, check to see if there is a working msgfmt.
317 AC_PATH_PROG(MSGFMT, msgfmt, none)
318 AC_PATH_PROG(MSGMERGE, msgmerge, none)
319 AC_PATH_PROG(XGETTEXT, xgettext, none)
320 if test "$MSGFMT" != "none"; then
321 AC_SEARCH_LIBS(bindtextdomain, [intl], [],
323 AC_MSG_WARN([bindtextdomain() not found. Disabling NLS.])
326 if test "$enable_nls" = "yes"; then
327 AC_DEFINE(ENABLE_NLS, 1,
328 [Define to 1 if translation of program messages to the user's
329 native language is requested.])
340 #define _(x) dgettext(PACKAGE_NAME, x)
343 #define gettext(x) (x)
344 #define dgettext(domain,x) (x)
348 dnl Used to simulate makefile conditionals.
350 NO_GETTEXT_CODESET=\#
351 if test $USE_NLS = "yes"; then
352 AC_CHECK_FUNCS(bind_textdomain_codeset,
353 [ GETTEXT_CODESET="" ],
354 [ NO_GETTEXT_CODESET="" ])
356 AC_SUBST(GETTEXT_CODESET)
357 AC_SUBST(NO_GETTEXT_CODESET)
359 # Check if we are using GNU gettext.
362 if test $USE_NLS = "yes"; then
363 AC_MSG_CHECKING(if we are using GNU gettext)
364 if $MSGFMT --version 2>&1 | $EGREP GNU > /dev/null; then
368 AC_MSG_RESULT($GNU_GETTEXT)
370 AC_SUBST(MSGFMTFLAGS)
372 INSTALL_STATIC_RULES="install-bin install-docs"
373 INSTALL_RULES="install-fsmod-lib install-ramod-lib install-lib install-include install-static"
374 INSTALL_RULES="$INSTALL_RULES $INSTALL_APACHE_RULE"
375 BUILD_RULES="fsmod-lib ramod-lib lib bin test $BUILD_APACHE_RULE"
377 if test "$svn_lib_berkeley_db" = "yes"; then
378 BUILD_RULES="$BUILD_RULES bdb-lib bdb-test"
379 INSTALL_RULES="`echo $INSTALL_RULES | sed 's/install-fsmod-lib/install-fsmod-lib install-bdb-lib/'`"
380 INSTALL_STATIC_RULES="$INSTALL_STATIC_RULES install-bdb-lib"
381 BDB_TEST_DEPS="\$(BDB_TEST_DEPS)"
382 BDB_TEST_PROGRAMS="\$(BDB_TEST_PROGRAMS)"
385 if test "$svn_lib_neon" = "yes"; then
386 BUILD_RULES="$BUILD_RULES neon-lib"
387 INSTALL_RULES="`echo $INSTALL_RULES | sed 's/install-ramod-lib/install-ramod-lib install-neon-lib/'`"
388 INSTALL_STATIC_RULES="$INSTALL_STATIC_RULES install-neon-lib"
391 if test "$svn_lib_serf" = "yes"; then
392 BUILD_RULES="$BUILD_RULES serf-lib"
393 INSTALL_RULES="`echo $INSTALL_RULES | sed 's/install-ramod-lib/install-ramod-lib install-serf-lib/'`"
394 INSTALL_STATIC_RULES="$INSTALL_STATIC_RULES install-serf-lib"
397 if test "$USE_NLS" = "yes"; then
398 BUILD_RULES="$BUILD_RULES locale"
399 INSTALL_RULES="$INSTALL_RULES install-locale"
402 AC_SUBST(BUILD_RULES)
403 AC_SUBST(INSTALL_STATIC_RULES)
404 AC_SUBST(INSTALL_RULES)
405 AC_SUBST(BDB_TEST_DEPS)
406 AC_SUBST(BDB_TEST_PROGRAMS)
408 dnl Check for header files ----------------
410 dnl Standard C headers
413 dnl Check for typedefs, structures, and compiler characteristics ----------
415 dnl if compiler doesn't understand `const', then define it empty
418 dnl if non-existent, define size_t to be `unsigned'
422 dnl Check for library functions ----------
424 dnl libsvn_string uses memcmp()
427 dnl svn_error's default warning handler uses vfprintf()
430 dnl check for functions needed in special file handling
431 AC_CHECK_FUNCS(symlink readlink)
434 dnl Process some configuration options ----------
437 AS_HELP_STRING([--with-ssl],
438 [This option does NOT affect the Subversion build process in any
439 way. It enables OpenSSL support in the Neon library. If and
440 only if you are building Neon as an integrated part of the
441 Subversion build process, rather than linking to an already
442 installed version of Neon, you probably want to pass this
443 option so that Neon (and so indirectly, Subversion) will be
444 capable of https:// access.]),
448 AS_HELP_STRING([--enable-debug],
449 [Turn on debugging]),
451 if test "$enableval" = "yes" ; then
452 enable_debugging="yes"
454 enable_debugging="no"
458 AC_ARG_ENABLE(maintainer-mode,
459 AS_HELP_STRING([--enable-maintainer-mode],
460 [Turn on debugging and very strict compile-time warnings]),
462 if test "$enableval" = "yes" ; then
463 if test "$enable_debugging" = "no" ; then
464 AC_MSG_ERROR(Can't have --disable-debug and --enable-maintainer-mode)
467 if test "$GCC" = "yes"; then
468 CFLAGS="$CFLAGS -Wpointer-arith -Wwrite-strings -Wshadow"
469 CXXFLAGS="$CXXFLAGS -Wpointer-arith -Wwrite-strings -Wshadow"
474 if test "$enable_debugging" = "yes" ; then
475 dnl At the moment, we don't want optimization, because we're
477 CFLAGS=["`echo $CFLAGS' ' | sed -e 's/-O[^ ]* //g'`"]
478 CXXFLAGS=["`echo $CXXFLAGS' ' | sed -e 's/-O[^ ]* //g'`"]
479 dnl SVN_DEBUG enables specific features for developer builds
480 dnl AP_DEBUG enables specific (Apache) features for developer builds
481 CFLAGS="$CFLAGS -DSVN_DEBUG -DAP_DEBUG"
482 CXXFLAGS="$CXXFLAGS -DSVN_DEBUG -DAP_DEBUG"
484 if test "$enable_debugging" = "no" ; then
485 CFLAGS=["`echo $CFLAGS' ' | sed -e 's/-g[0-9] //g' | sed -e 's/-g//g'`"]
486 CXXFLAGS=["`echo $CXXFLAGS' ' | sed -e 's/-g[0-9] //g' | sed -e 's/-g//g'`"]
492 AS_HELP_STRING([--with-editor=PATH],
493 [Specify a default editor for the subversion client.]),
496 if test "$withval" = "yes" ; then
497 AC_MSG_ERROR([--with-editor requires an argument.])
499 SVN_CLIENT_EDITOR=$withval
500 AC_DEFINE_UNQUOTED(SVN_CLIENT_EDITOR, "$SVN_CLIENT_EDITOR",
501 [The path of a default editor for the client.])
510 AC_ARG_ENABLE(mod-activation,
511 AS_HELP_STRING([--disable-mod-activation],
512 [Do not enable mod_dav_svn in httpd.conf]),
514 if test "$enableval" = "no" ; then
516 AC_MSG_NOTICE([Disabling apache module activation])
518 AC_MSG_NOTICE([Enabling apache module activation])
521 AC_SUBST(MOD_ACTIVATION)
526 AS_HELP_STRING([--enable-gprof],
527 [Produce gprof profiling data in 'gmon.out' (GCC only).]),
529 if test "$enableval" = "yes" ; then
530 dnl Probably other compilers support -pg or something similar;
531 dnl feel free to extend this to include them.
532 if test "$GCC" = "yes"; then
533 if test "$enable_shared" = "yes" ; then
534 AC_MSG_ERROR(Can't have --enable-gprof without --disable-shared (we
535 recommend also using --enable-all-static).)
537 if test ! "$enable_all_static" = "yes" ; then
538 AC_MSG_WARN(We recommend --enable-all-static with --enable-gprof.)
540 AC_MSG_NOTICE([Enabling gprof profiling data (to gmon.out).])
542 CXXFLAGS="$CXXFLAGS -pg"
543 LT_LDFLAGS="$LT_LDFLAGS -pg"
545 AC_MSG_ERROR(We only support --enable-gprof with GCC right now.)
551 # Scripting and Bindings languages
553 # Python: Used for testsuite, and bindings
556 PYTHON="`$abs_srcdir/build/find_python.sh`"
557 if test -z "$PYTHON"; then
558 AC_MSG_WARN([Python 2.0 or later is required to run the testsuite])
559 AC_MSG_WARN([or to use the Subversion Python bindings])
561 AC_MSG_WARN([If you have a suitable Python installed, but not on the])
562 AC_MSG_WARN([PATH, set the environment variable PYTHON to the full path])
563 AC_MSG_WARN([to the Python executable, and re-run configure])
565 AC_PATH_PROGS(PYTHON, "$PYTHON", none)
567 # The minimum version for the JVM runtime for our Java bytecode.
568 JAVA_OLDEST_WORKING_VER='1.2'
569 # SVN_CHECK_JDK sets $JAVA_CLASSPATH
570 SVN_CHECK_JDK($JAVA_OLDEST_WORKING_VER)
572 AC_PATH_PROG(PERL, perl, none)
574 AC_PATH_PROG(RUBY, ruby, none)
575 if test "$RUBY" != "none"; then
576 if "$RUBY" -r mkmf -e 'exit(have_func("rb_hash_foreach") ? 0 : 1)'; then
577 AC_PATH_PROG(RDOC, rdoc, none)
578 AC_CACHE_CHECK([for Ruby major version], [svn_cv_ruby_major],[
579 svn_cv_ruby_major="`$RUBY -rrbconfig -e 'print Config::CONFIG.fetch(%q(MAJOR))'`"
581 RUBY_MAJOR="$svn_cv_ruby_major"
583 AC_CACHE_CHECK([for Ruby minor version], [svn_cv_ruby_minor],[
584 svn_cv_ruby_minor="`$RUBY -rrbconfig -e 'print Config::CONFIG.fetch(%q(MINOR))'`"
586 RUBY_MINOR="$svn_cv_ruby_minor"
592 AC_MSG_WARN([The detected Ruby is too old for Subversion to use])
593 AC_MSG_WARN([A Ruby which has rb_hash_foreach is required to use the])
594 AC_MSG_WARN([Subversion Ruby bindings])
595 AC_MSG_WARN([Upgrade to the official 1.8.2 release, or later])
601 dnl decide whether we want to link against the RA libraries
603 AS_HELP_STRING([--enable-dso], [Turn on DSO loading of RA libraries]),
605 if test "$enableval" = "yes"; then
607 if test "$enable_shared" = "no"; then
608 AC_MSG_ERROR([--enable-dso conflicts with --disable-shared])
613 if test "$enable_shared" = "no" || test "$enable_dso" != "yes"; then
614 ### We want ra_local first to handle the following scenario:
615 ### user has neon and db3 in /usr/local, and db4 in
616 ### /usr/local/BerkeleyDB.4.0. If libsvn_ra_neon.la comes before
617 ### libsvn_fs.la then libtool ends up linking libsvn_fs to the db3
618 ### in /usr/local/lib
619 AC_DEFINE(SVN_LIBSVN_CLIENT_LINKS_RA_LOCAL, 1,
620 [Defined if libsvn_client should link against libsvn_ra_local])
621 svn_ra_lib_deps="\$(RA_LOCAL_DEPS)"
622 svn_ra_lib_install_deps="install-ramod-lib"
623 svn_ra_lib_link="\$(RA_LOCAL_LINK)"
625 AC_DEFINE(SVN_LIBSVN_CLIENT_LINKS_RA_SVN, 1,
626 [Defined if libsvn_client should link against libsvn_ra_svn])
627 svn_ra_lib_deps="$svn_ra_lib_deps \$(RA_SVN_DEPS)"
628 svn_ra_lib_link="$svn_ra_lib_link \$(RA_SVN_LINK)"
630 if test "$svn_lib_neon" = "yes"; then
631 AC_DEFINE(SVN_LIBSVN_CLIENT_LINKS_RA_NEON, 1,
632 [Defined if libsvn_client should link against libsvn_ra_neon])
633 svn_ra_lib_deps="$svn_ra_lib_deps \$(RA_NEON_DEPS)"
634 svn_ra_lib_install_deps="$svn_ra_lib_install_deps install-neon-lib"
635 svn_ra_lib_link="$svn_ra_lib_link \$(RA_NEON_LINK)"
638 if test "$svn_lib_serf" = "yes"; then
639 AC_DEFINE(SVN_LIBSVN_CLIENT_LINKS_RA_SERF, 1,
640 [Defined if libsvn_client should link against libsvn_ra_serf])
641 svn_ra_lib_deps="$svn_ra_lib_deps \$(RA_SERF_DEPS)"
642 svn_ra_lib_install_deps="$svn_ra_lib_install_deps install-serf-lib"
643 svn_ra_lib_link="$svn_ra_lib_link \$(RA_SERF_LINK)"
646 SVN_RA_LIB_DEPS=$svn_ra_lib_deps
647 SVN_RA_LIB_INSTALL_DEPS=$svn_ra_lib_install_deps
648 SVN_RA_LIB_LINK=$svn_ra_lib_link
650 AC_DEFINE(SVN_LIBSVN_FS_LINKS_FS_FS, 1,
651 [Defined if libsvn_fs should link against libsvn_fs_fs])
652 svn_fs_lib_deps="\$(FS_FS_DEPS)"
653 svn_fs_lib_install_deps="install-fsmod-lib"
654 svn_fs_lib_link="\$(FS_FS_LINK)"
656 if test "$svn_lib_berkeley_db" = "yes"; then
657 AC_DEFINE(SVN_LIBSVN_FS_LINKS_FS_BASE, 1,
658 [Defined if libsvn_fs should link against libsvn_fs_base])
659 svn_fs_lib_deps="$svn_fs_lib_deps \$(FS_BASE_DEPS)"
660 svn_fs_lib_install_deps="$svn_fs_lib_install_deps install-bdb-lib"
661 svn_fs_lib_link="$svn_fs_lib_link \$(FS_BASE_LINK)"
664 SVN_FS_LIB_DEPS=$svn_fs_lib_deps
665 SVN_FS_LIB_INSTALL_DEPS=$svn_fs_lib_install_deps
666 SVN_FS_LIB_LINK=$svn_fs_lib_link
669 AC_SUBST(SVN_RA_LIB_DEPS)
670 AC_SUBST(SVN_RA_LIB_INSTALL_DEPS)
671 AC_SUBST(SVN_RA_LIB_LINK)
672 AC_SUBST(SVN_FS_LIB_DEPS)
673 AC_SUBST(SVN_FS_LIB_INSTALL_DEPS)
674 AC_SUBST(SVN_FS_LIB_LINK)
676 # ==== JavaHL ================================================================
678 dnl Possibly compile JavaHL
680 AC_ARG_ENABLE(javahl,
681 AS_HELP_STRING([--enable-javahl],
682 [Enable compilation of Java high-level bindings (requires C++)]),
683 [ if test "$enableval" = "yes" ; then
684 do_javahl_build="yes"
689 INSTALL_EXTRA_JAVAHL_LIB=""
691 JAVAHL_TESTS_TARGET=""
693 if test "$do_javahl_build" = "yes"; then
694 dnl Check for suitable JDK
695 if test "$JDK_SUITABLE" = "no"; then
696 AC_MSG_ERROR([Cannot compile JavaHL without a suitable JDK.
697 Please specify a suitable JDK using the --with-jdk option.])
702 dnl The temporary directory where libtool compiles libsvnjavahl.
703 dnl N.B. objdir is "the name of the directory that contains temporary
704 dnl libtool files" and it is set by libtool.m4
705 JAVAHL_OBJDIR='$(libsvnjavahl_PATH)'/$objdir
708 if test "$os_arch" = "Darwin"; then
709 dnl On Darwin, JNI libs must be installed as .jnilib
710 INSTALL_EXTRA_JAVAHL_LIB='ln -sf $(libdir)/libsvnjavahl-1.dylib $(libdir)/libsvnjavahl-1.jnilib'
711 FIX_JAVAHL_LIB="ln -sf libsvnjavahl-1.dylib $JAVAHL_OBJDIR/libsvnjavahl-1.jnilib"
713 # This segment (and the rest of r10800) is very likely unnecessary
714 # with libtool 1.5, which automatically adds libstdc++ as a
715 # dependency to the C++ libraries it builds. So at some future time
716 # when autogen.sh requires libtool 1.5 or higher, we can get rid of
718 AC_MSG_CHECKING([for additional flags to link C++ libraries])
719 if test "x$ac_compiler_gnu" = "xyes"; then
720 LT_CXX_LIBADD="-lstdc++"
721 AC_MSG_RESULT([$LT_CXX_LIBADD])
723 AC_MSG_RESULT([none needed])
726 AC_SUBST(INSTALL_EXTRA_JAVAHL_LIB)
727 AC_SUBST(JAVAHL_OBJDIR)
728 AC_SUBST(FIX_JAVAHL_LIB)
729 AC_SUBST(LT_CXX_LIBADD)
732 AS_HELP_STRING([--with-junit=PATH],
733 [Specify a path to the junit JAR file.]),
735 if test "$withval" = "yes" ; then
736 AC_MSG_ERROR([--with-junit requires an argument.])
738 if test -n "$JAVA_CLASSPATH"; then
739 JAVA_CLASSPATH="$withval:$JAVA_CLASSPATH"
741 JAVA_CLASSPATH="$withval"
743 JAVAHL_TESTS_TARGET="javahl-tests"
746 AC_SUBST(JAVA_CLASSPATH)
747 AC_SUBST(JAVAHL_TESTS_TARGET)
749 # ==== Miscellaneous bits ====================================================
751 dnl Since this is used only on Unix-y systems, define the path separator as '/'
752 AC_DEFINE_UNQUOTED(SVN_PATH_LOCAL_SEPARATOR, '/',
753 [Defined to be the path separator used on your local filesystem])
755 AC_DEFINE_UNQUOTED(SVN_NULL_DEVICE_NAME, "/dev/null",
756 [Defined to be the null device for the system])
758 DEFAULT_FS_TYPE="fsfs"
759 AC_DEFINE_UNQUOTED(DEFAULT_FS_TYPE, "$DEFAULT_FS_TYPE",
760 [The fs type to use by default])
762 # BSD/OS (BSDi) needs to use a different include syntax in Makefile
763 INCLUDE_OUTPUTS="include \$(top_srcdir)/build-outputs.mk"
766 # Check whether they've installed GNU make
767 if ! make --version > /dev/null 2>&1; then
769 INCLUDE_OUTPUTS=".include \"\$(top_srcdir)/build-outputs.mk\""
773 AC_SUBST(INCLUDE_OUTPUTS)
775 # ==== Detection complete - output and run config.status =====================
777 AC_CONFIG_HEADER(subversion/svn_private_config.h)
778 AC_CONFIG_FILES([Makefile])
779 AC_CONFIG_COMMANDS(mkdir-init, [make mkdir-init])
781 SVN_CONFIG_SCRIPT(tools/backup/hot-backup.py)
782 SVN_CONFIG_SCRIPT(contrib/client-side/svn_load_dirs/svn_load_dirs.pl)
783 SVN_CONFIG_SCRIPT(contrib/client-side/svncopy/svncopy.pl)
784 SVN_CONFIG_SCRIPT(contrib/client-side/svncopy/testsvncopy.pl)
785 SVN_CONFIG_SCRIPT(tools/hook-scripts/commit-access-control.pl)
786 SVN_CONFIG_SCRIPT(tools/hook-scripts/commit-email.pl)
787 SVN_CONFIG_SCRIPT(subversion/bindings/swig/perl/native/Makefile.PL)
788 SVN_CONFIG_SCRIPT(packages/solaris/pkginfo)
789 AC_SUBST(SVN_CONFIG_SCRIPT_FILES)
793 # ==== Print final messages to user ==========================================
795 dnl Configure is long - users tend to miss warnings printed during it.
796 dnl Hence, print a warnings about what we did and didn't configure at the
797 dnl end, where people will actually see them.
799 case "$svn_lib_berkeley_db" in
801 db_version="$SVN_FS_WANT_DB_MAJOR.$SVN_FS_WANT_DB_MINOR.$SVN_FS_WANT_DB_PATCH"
802 AC_MSG_WARN([we have configured without BDB filesystem support
805 You don't seem to have Berkeley DB version $db_version or newer
806 installed and linked to APR-UTIL. We have created Makefiles which
807 will build without the Berkeley DB back-end; your repositories will
808 use FSFS as the default back-end. You can find the latest version of
810 http://www.oracle.com/technology/software/products/berkeley-db/index.html