Commit 244588a4 authored by Sam Thursfield's avatar Sam Thursfield Committed by Niels Möller

Make documentation optional.

parent 31f6181d
2012-08-22 Niels Möller <nisse@lysator.liu.se>
From Sam Thursfield <sam.thursfield@codethink.co.uk>:
* configure.ac: Make documentation optional, to avoid requiring
TeX. New option --disable-documentation, and Makefile substitution
IF_DOCUMENTATION.
* Makefile.in: Use IF_DOCUMENTATION.
2012-07-12 Niels Möller <nisse@lysator.liu.se>
* asm.m4 (ALIGN): Use << operator rather than **, with m4 eval.
......
......@@ -35,7 +35,7 @@ TARGETS = aesdata$(EXEEXT) desdata$(EXEEXT) twofishdata$(EXEEXT) \
$(LIBTARGETS) @IF_SHARED@ $(SHLIBTARGETS)
IMPLICIT_TARGETS = @IF_DLL@ $(LIBNETTLE_FILE) $(LIBHOGWEED_FILE)
DOCTARGETS = nettle.info nettle.html nettle.pdf
DOCTARGETS = @IF_DOCUMENTATION@ nettle.info nettle.html nettle.pdf
PKGCONFIG_FILES = nettle.pc @IF_HOGWEED@ hogweed.pc
pkgconfigdir = $(libdir)/pkgconfig
......@@ -302,7 +302,8 @@ hogweed.pc: hogweed.pc.in config.status
./config.status $@
# Installation
install-here: install-info install-headers install-static install-pkgconfig \
install-doc: @IF_DOCUMENTATION@ install-info
install-here: install-doc install-headers install-static install-pkgconfig \
@IF_SHARED@ install-shared-nettle @IF_HOGWEED@ install-shared-hogweed
install-static: $(LIBTARGETS)
......
......@@ -60,6 +60,10 @@ AC_ARG_ENABLE(gcov,
AC_HELP_STRING([--enable-gcov], [Instrument for gcov (requires a modern gcc)]),,
[enable_gcov=no])
AC_ARG_ENABLE(documentation,
AC_HELP_STRING([--enable-documentation], [Generate TeX documentation (default=auto)]),,
[enable_documentation=auto])
LSH_RPATH_INIT([`echo $with_lib_path | sed 's/:/ /g'` \
`echo $exec_prefix | sed "s@^NONE@$prefix/lib@g" | sed "s@^NONE@$ac_default_prefix/lib@g"` \
/usr/local/lib /sw/local/lib /sw/lib \
......@@ -572,8 +576,31 @@ else
IF_SHARED='#'
fi
# Documentation tools
if test "x$enable_documentation" != "xno"; then
AC_PATH_PROG(MAKEINFO, makeinfo, not-found)
if test "x$MAKEINFO" != "xnot-found"; then
enable_documentation=yes
AC_SUBST(MAKEINFO)
else
if test "x$enable_documentation" == "xauto" ; then
enable_documentation=no
else
AC_MSG_ERROR([Cannot find 'makeinfo', required for documentation.])
fi
fi
fi
if test "x$enable_documentation" = "xyes" ; then
IF_DOCUMENTATION=''
else
IF_DOCUMENTATION='#'
fi
AC_SUBST(IF_HOGWEED)
AC_SUBST(IF_SHARED)
AC_SUBST(IF_DOCUMENTATION)
AC_SUBST(IF_DLL)
OPENSSL_LIBFLAGS=''
......@@ -656,4 +683,5 @@ AC_MSG_NOTICE([summary of build options:
Compiler: ${CC}
Shared libraries: ${enable_shared}
Public key crypto: ${enable_public_key}
Documentation: ${enable_documentation}
])
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment