diff options
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 605 |
1 files changed, 308 insertions, 297 deletions
diff --git a/configure.ac b/configure.ac index 4f4aa244..a07f78fc 100644 --- a/configure.ac +++ b/configure.ac @@ -9,7 +9,7 @@ AC_INIT([rpkitools], [1.0]) dnl AC_REVISION([$Revision$]) -AC_CONFIG_SRCDIR([rcynic/rcynic.c]) +AC_CONFIG_SRCDIR([rp/rcynic/rcynic.c]) AC_CONFIG_AUX_DIR([buildtools]) # I'm not sure we should really be using the $host_* variables as we @@ -153,109 +153,157 @@ case $enable_runtime_dependencies in ;; esac +# Figure out whether we want RP tools, CA tools, or both + +AC_MSG_CHECKING([whether user wants the RP tools]) +case $enable_rp_tools in + yes|no) + build_rp_tools=$enable_rp_tools + ;; + *) + AC_MSG_ERROR([Unrecognized value for --enable-rp-tools: $enable_rp_tools]) + ;; +esac +AC_MSG_RESULT([$build_rp_tools]) + +AC_MSG_CHECKING([whether user wants the CA tools]) +case $enable_ca_tools in + yes|no) + build_ca_tools=$enable_ca_tools + ;; + *) + AC_MSG_ERROR([Unrecognized value for --enable-ca-tools: $enable_ca_tools]) + ;; +esac +AC_MSG_RESULT([$build_ca_tools]) + +if test $build_rp_tools = no && test $build_ca_tools = no +then + AC_MSG_ERROR([Building with neither RP tools nor CA tools makes no sense]) +fi + # Figure out whether we need to build our own OpenSSL library or can # use the system libraries. We're looking for two recent features: # CMS and RFC 3779 support. We also have to check whether the user # has an opinion on all this. In the "auto" case (no # --with-system-openssl option specified in any form), we may need to # check a platform-specific location (eg, /usr/local on FreeBSD). +# +# At this point all of the C code is in the RP tools package, so we can +# skip all this if we're just building the CA tools. -old_CFLAGS="$CFLAGS" -old_LDFLAGS="$LDFLAGS" +if test $build_rp_tools = no +then -case $with_system_openssl in - yes|auto) - if test $CFLAGS_or_LDFLAGS_were_set = no - then - case $host_os in - freebsd*) - CFLAGS="-I/usr/local/include $CFLAGS" - LDFLAGS="-L/usr/local/lib $LDFLAGS" - ;; - esac - fi - ;; - no|/usr) - : - ;; + build_openssl=no - *) - CFLAGS="-I$with_system_openssl/include $CFLAGS" - LDFLAGS="-L$with_system_openssl/lib $LDFLAGS" -esac +else -case $with_system_openssl in - no) - have_usable_openssl=no - ;; - *) - AC_CHECK_LIB([crypto], [v3_addr_validate_path], - [system_openssl_has_rfc3779=yes], - [system_openssl_has_rfc3779=no]) + old_CFLAGS="$CFLAGS" + old_LDFLAGS="$LDFLAGS" + + case $with_system_openssl in + yes|auto) + if test $CFLAGS_or_LDFLAGS_were_set = no + then + case $host_os in + freebsd*) + CFLAGS="-I/usr/local/include $CFLAGS" + LDFLAGS="-L/usr/local/lib $LDFLAGS" + ;; + esac + fi + ;; + no|/usr) + : + ;; - AC_CHECK_LIB([crypto], [CMS_verify], - [system_openssl_has_cms=yes], - [system_openssl_has_cms=no]) + *) + CFLAGS="-I$with_system_openssl/include $CFLAGS" + LDFLAGS="-L$with_system_openssl/lib $LDFLAGS" + esac - if test $system_openssl_has_rfc3779 = yes && test $system_openssl_has_cms = yes - then - have_usable_openssl=yes - else + case $with_system_openssl in + no) have_usable_openssl=no - fi -esac + ;; + *) + AC_CHECK_LIB([crypto], [v3_addr_validate_path], + [system_openssl_has_rfc3779=yes], + [system_openssl_has_rfc3779=no]) + + AC_CHECK_LIB([crypto], [CMS_verify], + [system_openssl_has_cms=yes], + [system_openssl_has_cms=no]) + + AC_MSG_CHECKING([whether system OpenSSL library is usable]) + if test $system_openssl_has_rfc3779 = yes && test $system_openssl_has_cms = yes + then + have_usable_openssl=yes + else + have_usable_openssl=no + fi + AC_MSG_RESULT([$have_usable_openssl]) + esac -case $with_system_openssl in - yes) - build_openssl=no - if test $have_usable_openssl = no - then - AC_MSG_ERROR([Can't find OpenSSL crypto library with CMS and RFC 3779 support, try --with-system-openssl=/path/to/openssl]) - fi - ;; - no) - build_openssl=yes - ;; - auto) - if test $have_usable_openssl = no - then + AC_MSG_CHECKING([whether we need to build a private copy of OpenSSL]) + case $with_system_openssl in + yes) + build_openssl=no + if test $have_usable_openssl = no + then + AC_MSG_ERROR([Can't find OpenSSL crypto library with CMS and RFC 3779 support, try --with-system-openssl=/path/to/openssl]) + fi + ;; + no) build_openssl=yes - else + ;; + auto) + if test $have_usable_openssl = no + then + build_openssl=yes + else + build_openssl=no + fi + ;; + *) build_openssl=no - fi - ;; - *) - build_openssl=no - if test $have_usable_openssl = no - then - AC_MSG_ERROR([Can't find OpenSSL crypto library with CMS and RFC 3779 support in $with_system_openssl]) - fi -esac + if test $have_usable_openssl = no + then + AC_MSG_ERROR([Can't find OpenSSL crypto library with CMS and RFC 3779 support in $with_system_openssl]) + fi + esac + AC_MSG_RESULT([$build_openssl]) -if test $build_openssl = yes -then - CFLAGS="$old_CFLAGS" - LDFLAGS="$old_LDFLAGS" -fi + build_openssl_asm=undefined -case $enable_openssl_asm in - yes|no) - build_openssl_asm=$enable_openssl_asm - ;; - auto) - case $host in - x86_64-*-linux*) - build_openssl_asm=no + if test $build_openssl = yes + then + CFLAGS="$old_CFLAGS" + LDFLAGS="$old_LDFLAGS" + + AC_MSG_CHECKING([whether to enable assembly code in OpenSSL]) + case $enable_openssl_asm in + yes|no) + build_openssl_asm=$enable_openssl_asm ;; - *) - build_openssl_asm=yes + auto) + case $host in + x86_64-*-linux*) + build_openssl_asm=no + ;; + *) + build_openssl_asm=yes + ;; + esac ;; - esac - ;; - *) - AC_MSG_ERROR([Unrecognized value for --enable-openssl-asm: $enable_openssl_asm]) - ;; -esac + *) + AC_MSG_ERROR([Unrecognized value for --enable-openssl-asm: $enable_openssl_asm]) + ;; + esac + AC_MSG_RESULT([$enable_openssl_asm]) + fi +fi # RCYNIC_DIR is a "precious" argument variable to this script (see # autoconf doc), which means that autoconf is careful with whatever @@ -355,6 +403,12 @@ AC_SUBST(RCYNIC_CRON_USER) AC_MSG_RESULT([$use_rcynic_jail]) +# Perhaps there should be a way to set these, but for now just +# wire them in here so at least they're consistent in all Makefiles. + +AC_SUBST(RCYNIC_USER, [rcynic]) +AC_SUBST(RCYNIC_GROUP, [rcynic]) + if test $use_rcynic_jail = yes && test "X$LD_STATIC_FLAG" != "X" then RCYNIC_STATIC_RSYNC='static-rsync/rsync' @@ -383,38 +437,39 @@ AC_MSG_RESULT([$enable_target_installation]) # rcynic jail setup is complicated enough that it's simplest to have # different rule sets for different platforms. Icky, but.... # rpki-rtr isn't as complicated, but has similar issues, same hack. -# rpkid isn't as complicated either, but same hack. +# ca isn't as complicated either, but same hack. case $host_os in darwin*) - RCYNIC_MAKE_RULES='rcynic/rules.darwin.mk' - RTR_ORIGIN_MAKE_RULES='rtr-origin/rules.darwin.mk' - RPKID_MAKE_RULES='rpkid/rules.darwin.mk' + RCYNIC_MAKE_RULES='rp/rcynic/rules.darwin.mk' + RTR_ORIGIN_MAKE_RULES='rp/rpki-rtr/rules.darwin.mk' + CA_MAKE_RULES='ca/rules.darwin.mk' ;; freebsd*) - RCYNIC_MAKE_RULES='rcynic/rules.freebsd.mk' - RTR_ORIGIN_MAKE_RULES='rtr-origin/rules.freebsd.mk' - RPKID_MAKE_RULES='rpkid/rules.freebsd.mk' + RCYNIC_MAKE_RULES='rp/rcynic/rules.freebsd.mk' + RTR_ORIGIN_MAKE_RULES='rp/rpki-rtr/rules.freebsd.mk' + CA_MAKE_RULES='ca/rules.freebsd.mk' ;; linux*) - RCYNIC_MAKE_RULES='rcynic/rules.linux.mk' - RTR_ORIGIN_MAKE_RULES='rtr-origin/rules.linux.mk' - RPKID_MAKE_RULES='rpkid/rules.linux.mk' + RCYNIC_MAKE_RULES='rp/rcynic/rules.linux.mk' + RTR_ORIGIN_MAKE_RULES='rp/rpki-rtr/rules.linux.mk' + CA_MAKE_RULES='ca/rules.linux.mk' ;; *) - RCYNIC_MAKE_RULES='rcynic/rules.unknown.mk' - RTR_ORIGIN_MAKE_RULES='rtr-origin/rules.unknown.mk' - RPKID_MAKE_RULES='rpkid/rules.unknown.mk' + RCYNIC_MAKE_RULES='rp/rcynic/rules.unknown.mk' + RTR_ORIGIN_MAKE_RULES='rp/rpki-rtr/rules.unknown.mk' + CA_MAKE_RULES='ca/rules.unknown.mk' ;; esac AC_SUBST_FILE(RCYNIC_MAKE_RULES) AC_SUBST_FILE(RTR_ORIGIN_MAKE_RULES) -AC_SUBST_FILE(RPKID_MAKE_RULES) +AC_SUBST_FILE(CA_MAKE_RULES) # Where to put HTML files is similarly platform dependent, we have to know. # rcynic-cron will skip generating HTML files if it has no place to put them. +AC_MSG_CHECKING([where rcynic-html output should go]) case $host_os in freebsd*) RCYNIC_HTML_DIR="/usr/local/www/apache${APACHE_VERSION}/data/rcynic" @@ -433,6 +488,7 @@ case $host_os in RCYNIC_HTML_DIR='' ;; esac +AC_MSG_RESULT([$RCYNIC_HTML_DIR]) AC_SUBST(RCYNIC_HTML_DIR) @@ -441,7 +497,7 @@ AC_SUBST(RCYNIC_HTML_DIR) RCYNIC_INSTALL_TARGETS='install-always' RTR_ORIGIN_INSTALL_TARGETS='install-always' -RPKID_INSTALL_TARGETS='install-always' +CA_INSTALL_TARGETS='install-always' if test $use_rcynic_jail = yes then @@ -452,202 +508,162 @@ if test $enable_target_installation = yes then RCYNIC_INSTALL_TARGETS="$RCYNIC_INSTALL_TARGETS install-postconf" RTR_ORIGIN_INSTALL_TARGETS="$RTR_ORIGIN_INSTALL_TARGETS install-postconf" - RPKID_INSTALL_TARGETS="$RPKID_INSTALL_TARGETS install-postconf" + CA_INSTALL_TARGETS="$CA_INSTALL_TARGETS install-postconf" fi AC_SUBST(RCYNIC_INSTALL_TARGETS) AC_SUBST(RTR_ORIGIN_INSTALL_TARGETS) -AC_SUBST(RPKID_INSTALL_TARGETS) +AC_SUBST(CA_INSTALL_TARGETS) # Now a bunch of checks to figure out what we can do with Python. If # we don't have Python at all, none of the rest of this matters. If # we do have Python, we need to check for required packages and # versions. -have_python=no -have_acceptable_python=no -have_python_h=no -have_django=no -have_acceptable_django=no -have_lxml=no -have_mysqldb=no -have_pyyaml=no -have_vobject=no -have_django_south=no -have_acceptable_django_south=no -have_argparse=no - -if test "x$PYTHON" != "x" +if test "x$PYTHON" = "x" then - have_python=yes - - AC_MSG_CHECKING([for Python version 2.6 or higher]) - have_acceptable_python=`$PYTHON -c 'import sys; print "yes" if sys.version_info[[0]] == 2 and sys.version_info[[1]] >= 6 else "no"'` - AC_MSG_RESULT([$have_acceptable_python]) + AC_MSG_ERROR([I can't find a Python binary at all, this isn't going to work. Perhaps you need to set PATH?]) +fi - AC_MSG_CHECKING([distutils to find out where Python.h should be]) - python_h=`$PYTHON -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_inc() + "/Python.h"'` - AC_MSG_RESULT([$python_h]) +AC_MSG_CHECKING([for Python version 2.6 or higher]) +have_acceptable_python=`$PYTHON -c 'import sys; print "yes" if sys.version_info[[0]] == 2 and sys.version_info[[1]] >= 6 else "no"'` +AC_MSG_RESULT([$have_acceptable_python]) - AC_CHECK_HEADER([$python_h], [have_python_h=yes], [have_python_h=no]) +AC_MSG_CHECKING([distutils to find out where Python.h should be]) +python_h=`$PYTHON -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_inc() + "/Python.h"'` +AC_MSG_RESULT([$python_h]) - AC_MSG_CHECKING([for lxml.etree]) - if $PYTHON -c 'import lxml.etree' 2>/dev/null - then - have_lxml=yes - fi - AC_MSG_RESULT([$have_lxml]) +AC_CHECK_HEADER([$python_h], [have_python_h=yes], [have_python_h=no]) - AC_MSG_CHECKING([for MySQLdb]) - if $PYTHON -c 'import MySQLdb' 2>/dev/null - then - have_mysqldb=yes - fi - AC_MSG_RESULT([$have_mysqldb]) +AC_MSG_CHECKING([for lxml.etree]) +if $PYTHON -c 'import lxml.etree' 2>/dev/null; then have_lxml=yes; else have_lxml=no; fi +AC_MSG_RESULT([$have_lxml]) - AC_MSG_CHECKING([for Django]) - if $PYTHON -c 'import django' 2>/dev/null - then - have_django="yes" - fi - AC_MSG_RESULT([$have_django]) +AC_MSG_CHECKING([for MySQLdb]) +if $PYTHON -c 'import MySQLdb' 2>/dev/null; then have_mysqldb=yes; else have_mysqldb=no; fi +AC_MSG_RESULT([$have_mysqldb]) - if test $have_django = yes - then - AC_MSG_CHECKING([for Django 1.3.7 or higher]) - have_acceptable_django=`$PYTHON -c "import django; print 'no' if django.VERSION < (1, 3, 7) else 'yes'"` - AC_MSG_RESULT([$have_acceptable_django]) - fi +AC_MSG_CHECKING([for Django]) +if $PYTHON -c 'import django' 2>/dev/null; then have_django=yes; else have_django=no; fi +AC_MSG_RESULT([$have_django]) - AC_MSG_CHECKING([for PyYAML]) - if $PYTHON -c 'import yaml' 2>/dev/null - then - have_pyyaml=yes - fi - AC_MSG_RESULT([$have_pyyaml]) - - AC_MSG_CHECKING([for vobject]) - if $PYTHON -c 'import vobject' 2>/dev/null - then - have_vobject=yes - fi - AC_MSG_RESULT([$have_vobject]) - - AC_MSG_CHECKING([for Django South]) - if $PYTHON -c 'import south' 2>/dev/null - then - have_django_south=yes - fi - AC_MSG_RESULT([$have_django_south]) +if test $have_django = yes +then + AC_MSG_CHECKING([for Django 1.3.7 or higher]) + have_acceptable_django=`$PYTHON -c "import django; print 'no' if django.VERSION < (1, 3, 7) else 'yes'"` + AC_MSG_RESULT([$have_acceptable_django]) +else + have_acceptable_django=no +fi - if test $have_django_south = yes - then - AC_MSG_CHECKING([for Django South 0.7.5 or later]) - have_acceptable_django_south=`$PYTHON -c "import south; print 'no' if map(int,south.__version__.split('.')) < [[0, 7, 5]] else 'yes'"` - AC_MSG_RESULT([$have_acceptable_django_south]) - fi +AC_MSG_CHECKING([for PyYAML]) +if $PYTHON -c 'import yaml' 2>/dev/null; then have_pyyaml=yes; else have_pyyaml=no; fi +AC_MSG_RESULT([$have_pyyaml]) - AC_MSG_CHECKING([for argparse]) - if $PYTHON -c 'import argparse' 2>/dev/null - then - have_argparse=yes - fi - AC_MSG_RESULT([$have_argparse]) -fi +AC_MSG_CHECKING([for vobject]) +if $PYTHON -c 'import vobject' 2>/dev/null; then have_vobject=yes; else have_vobject=no; fi +AC_MSG_RESULT([$have_vobject]) -ok=yes +AC_MSG_CHECKING([for Django South]) +if $PYTHON -c 'import south' 2>/dev/null; then have_django_south=yes; else have_django_south=no; fi +AC_MSG_RESULT([$have_django_south]) -if test $have_python = no +if test $have_django_south = yes then - ok=no - AC_MSG_WARN([I can't find a Python binary, perhaps you need to set PATH?]) + AC_MSG_CHECKING([for Django South 0.7.5 or later]) + have_acceptable_django_south=`$PYTHON -c "import south; print 'no' if map(int,south.__version__.split('.')) < [[0, 7, 5]] else 'yes'"` + AC_MSG_RESULT([$have_acceptable_django_south]) +else + have_acceptable_django_south=no fi -if test $have_acceptable_python = no -then - ok=no - AC_MSG_WARN([The RPKI code requires Python version 2.x, for x = 6 or higher.]) -fi +AC_MSG_CHECKING([for argparse]) +if $PYTHON -c 'import argparse' 2>/dev/null; then have_argparse=yes; else have_argparse=no; fi +AC_MSG_RESULT([$have_argparse]) -case $enable_rp_tools in - yes) build_rp_tools=yes - ;; - no) build_rp_tools=no - ;; - *) AC_MSG_ERROR([Unrecognized value for --enable-rp-tools: $enable_rp_tools]) - ;; -esac +# Warnings and dependency errors. Exit on fatal errors deferred until +# the very end of this, so we can warn the user about all known +# problems in a single pass. Errors that prevent build or basic +# installation are always fatal; errors that prevent proper operation +# at runtime or during post-installation setup can be converted to +# warnings by --disable-runtime-dependencies. -case $enable_ca_tools in - yes) build_ca_tools=yes - if test $have_python_h = no - then - ok=no - AC_MSG_WARN([I can't find Python.h. Python sources are required to build the CA tools.]) - fi - if test $have_lxml = no - then - ok=no - AC_MSG_WARN([The RPKI tools require the Python LXML module.]) - fi - if test $have_acceptable_django = no - then - ok=no - AC_MSG_WARN([The RPKI CA tools require Django 1.3.7 or higher.]) - fi - if test $have_vobject = no - then - ok=no - AC_MSG_WARN([The RPKI CA GUI requires the Python vobject module.]) - fi - if test $have_acceptable_django_south = no - then - ok=no - AC_MSG_WARN([The RPKI CA tools require Django South 0.7.5 or higher.]) - fi - if test $have_argparse = no - then - ok=no - AC_MSG_WARN([The RPKI CA tools require the Python argparse module.]) - fi - # - # This should be the last test in this group, so that failures get the --disable-ca-tools warning. - # - if test $ok = no - then - AC_MSG_WARN([If you do not wish to install the RPKI CA tools, please specify --disable-ca-tools as an argument to this configure script.]) - fi - ;; - no) build_ca_tools=no - ;; - *) AC_MSG_ERROR([Unrecognized value for --enable-ca-tools: $enable_ca_tools]);; -esac - -if test $build_ca_tools = yes && test $have_pyyaml = no -then - AC_MSG_WARN([PyYAML missing, so "make test" will not work properly.]) -fi +build_ok=yes +runtime_ok=yes -if test "x$XSLTPROC" = "x" +if test $have_acceptable_python = no then - AC_MSG_WARN([xsltproc missing, so "make test" will not work properly.]) + runtime_ok=no + AC_MSG_WARN([The RPKI code requires Python version 2.x, for x = 6 or higher.]) fi -if test "x$RRDTOOL" = "x" +if test $build_rp_tools = yes then - ok=no - AC_MSG_WARN([rcynic-html requires rrdtool.]) + if test $have_python_h = no + then + build_ok=no + AC_MSG_WARN([I can't find Python.h. Python sources are required to build the RP tools.]) + fi + if test "x$RRDTOOL" = "x" + then + runtime_ok=no + AC_MSG_WARN([rcynic-html requires rrdtool.]) + fi + if test $use_rcynic_jail = no && test "X$RSYNC" = "X" + then + runtime_ok=no + AC_MSG_WARN([The RPKI relying party tools require rsync.]) + fi fi -if test $use_rcynic_jail = no && test "X$RSYNC" = "X" +if test $build_ca_tools = yes then - ok=no - AC_MSG_WARN([The RPKI relying party tools require rsync.]) + if test $have_lxml = no + then + runtime_ok=no + AC_MSG_WARN([The RPKI tools require the Python LXML module.]) + fi + if test $have_acceptable_django = no + then + runtime_ok=no + AC_MSG_WARN([The RPKI CA tools require Django 1.3.7 or higher.]) + fi + if test $have_vobject = no + then + runtime_ok=no + AC_MSG_WARN([The RPKI CA GUI requires the Python vobject module.]) + fi + if test $have_acceptable_django_south = no + then + runtime_ok=no + AC_MSG_WARN([The RPKI CA tools require Django South 0.7.5 or higher.]) + fi + if test $have_argparse = no + then + runtime_ok=no + AC_MSG_WARN([The RPKI CA tools require the Python argparse module.]) + fi + if test $have_pyyaml = no + then + AC_MSG_WARN([PyYAML missing, so "make test" will not work properly.]) + fi + if test "x$XSLTPROC" = "x" + then + AC_MSG_WARN([xsltproc missing, so "make test" will not work properly.]) + fi fi -if test $ok = no +if test $build_ok = no || test $runtime_ok = no then - if test $enable_runtime_dependencies = yes + if test $build_rp_tools = yes + then + AC_MSG_WARN([If you do not wish to install the RPKI RP tools, please specify --disable-rp-tools as an argument to this configure script.]) + fi + if test $build_ca_tools = yes + then + AC_MSG_WARN([If you do not wish to install the RPKI CA tools, please specify --disable-ca-tools as an argument to this configure script.]) + fi + if test $build_ok = no || test $enable_runtime_dependencies = yes then AC_MSG_ERROR([Please correct the problems above then re-run this configuration script.]) else @@ -750,22 +766,17 @@ else AC_MSG_RESULT([$WSGI_PYTHON_EGG_CACHE_DIR]) fi -# Figure out which parts of this package we have to build. +# Tell the Makefiles and setup.py which parts of this package we've decided to build. - TOP_LEVEL_SUBDIRS="h" -test $build_openssl = yes && TOP_LEVEL_SUBDIRS="$TOP_LEVEL_SUBDIRS openssl" -test $build_rp_tools = yes && TOP_LEVEL_SUBDIRS="$TOP_LEVEL_SUBDIRS rcynic utils rtr-origin" -test $build_ca_tools = yes && TOP_LEVEL_SUBDIRS="$TOP_LEVEL_SUBDIRS rpkid" +if test $build_openssl = yes; then OPENSSL_TARGET=openssl; else OPENSSL_TARGET=noop; fi +if test $build_rp_tools = yes; then RP_TARGET=rp; else RP_TARGET=noop; fi +if test $build_ca_tools = yes; then CA_TARGET=ca; else CA_TARGET=noop; fi -AC_SUBST(TOP_LEVEL_SUBDIRS) +AC_SUBST(OPENSSL_TARGET) +AC_SUBST(RP_TARGET) +AC_SUBST(CA_TARGET) -AC_CONFIG_FILES([Makefile - h/Makefile]) - -if test "X$RCYNIC_STATIC_RSYNC" != "X" -then - AC_CONFIG_FILES([rcynic/static-rsync/Makefile]) -fi +AC_CONFIG_FILES([Makefile]) # OpenSSL has its own build system that bears no relationship to # anything but itself, and our use of it is a bit weird, so this is a @@ -773,7 +784,8 @@ fi if test $build_openssl = yes then - AC_CONFIG_FILES([openssl/Makefile openssl/tests/Makefile]) + AC_CONFIG_FILES([openssl/Makefile + openssl/tests/Makefile]) AC_MSG_CHECKING([what configuration target to use when building OpenSSL]) case $host in @@ -818,41 +830,40 @@ fi if test $build_rp_tools = yes then - AC_CONFIG_FILES([rcynic/Makefile - utils/Makefile - utils/find_roa/Makefile - utils/hashdir/Makefile - utils/print_rpki_manifest/Makefile - utils/print_roa/Makefile - utils/scan_roas/Makefile - utils/scan_routercerts/Makefile - utils/uri/Makefile - rtr-origin/Makefile]) + AC_CONFIG_FILES([rp/Makefile + rp/rcynic/Makefile + rp/rcynic/static-rsync/Makefile + rp/utils/Makefile + rp/rpki-rtr/Makefile]) fi if test $build_ca_tools = yes then - AC_CONFIG_FILES([rpkid/Makefile - rpkid/tests/Makefile]) + AC_CONFIG_FILES([ca/Makefile + ca/tests/Makefile]) fi -if test $build_ca_tools = yes && - test "X$enable_wsgi_daemon_mode" = "Xyes" -then - AC_MSG_ERROR([You must specify the user to run the wsgi process as with --enable-wsgi-daemon-mode=USER]) -fi - -if test $build_ca_tools = yes && - test "X$enable_wsgi_daemon_mode" != "Xno" +if test $build_ca_tools = yes then - save_IFS="$IFS" - IFS=':' read user group <<_EOF + case $enable_wsgi_daemon_mode in + no) + ;; + yes) + AC_MSG_ERROR([You must specify the user to run the wsgi process as with --enable-wsgi-daemon-mode=USER]) + ;; + *) + AC_MSG_CHECKING([how to run mod_wsgi daemon mode]) + save_IFS="$IFS" + IFS=':' + read user group <<_EOF $enable_wsgi_daemon_mode _EOF - IFS="$save_IFS" - AC_SUBST(WSGI_DAEMON_PROCESS, "WSGIDaemonProcess rpkigui user=$user ${group:+group=}${group} display-name=%{GROUP}") - AC_SUBST(WSGI_PROCESS_GROUP, "WSGIProcessGroup rpkigui") - AC_MSG_RESULT([running mod_wsgi in daemon mode with user "$user" and group "${group:-default}"]) + IFS="$save_IFS" + AC_SUBST(WSGI_DAEMON_PROCESS, "WSGIDaemonProcess rpkigui user=$user ${group:+group=}${group} display-name=%{GROUP}") + AC_SUBST(WSGI_PROCESS_GROUP, "WSGIProcessGroup rpkigui") + AC_MSG_RESULT([with user "$user" and group "${group:-default}"]) + ;; + esac fi # Now that we're finally done with all the conditional changes to |