build: merge branch 'th/build-cleanup'

This commit is contained in:
Thomas Haller 2016-11-22 11:04:37 +01:00
commit 7b16b28a62
2 changed files with 16 additions and 20 deletions

View file

@ -128,13 +128,9 @@ DISTCHECK_CONFIGURE_FLAGS = \
dist-configure-check:
@echo "*** 'make dist' requires '--enable-gtk-doc --with-introspection --with-libnm-glib'. ***"
@false
if !BUILD_SETTING_DOCS
dist_configure_check += dist-configure-check
endif
if !ENABLE_GTK_DOC
dist_configure_check += dist-configure-check
endif
if !WITH_LEGACY_LIBRARIES
dist_configure_check += dist-configure-check
endif
@ -3953,13 +3949,6 @@ EXTRA_DIST += \
$(man_pages) \
$(man_pages_autogen)
if INSTALL_PREGEN_MANPAGES
install_manpages = true
else
if ENABLE_GTK_DOC
install_manpages = true
endif
endif
install-data-hook-man:
if test -n "$(install_manpages)"; then \
@ -3982,6 +3971,7 @@ uninstall-hook-man:
uninstall_hook += uninstall-hook-man
if ENABLE_GTK_DOC
install_manpages = true
man_MANS += $(man_pages)
CLEANFILES += $(man_pages)
if SETTING_DOCS_AVAILABLE
@ -3990,6 +3980,7 @@ CLEANFILES += $(man_pages_autogen)
endif
else
if INSTALL_PREGEN_MANPAGES
install_manpages = true
man_MANS += \
$(man_pages) \
$(man_pages_autogen)

View file

@ -1103,17 +1103,22 @@ AM_CONDITIONAL(INSTALL_PREGEN_MANPAGES, test "x${install_pregen_manpages}" = "xy
# check if we can build setting property documentation
if test -n "$INTROSPECTION_MAKEFILE" -a "$enable_gtk_doc" = "yes"; then
# If g-i is installed we know we have python, but we might not have pygobject
if python -c 'from gi.repository import GObject' >& /dev/null; then
have_pyobject=yes
if ! python -c 'from gi.repository import GObject' >& /dev/null; then
AC_MSG_ERROR(["--enable-gtk-doc --with-introspection" aims to build the settings documentation. This requires GObject introspection for python (pygobject)])
fi
# gtk-doc depends on perl, but we can check for it anyway
AC_PATH_PROG(PERL, perl, no)
if test "$have_pyobject" = "yes"; then
AC_DEFINE(BUILD_SETTING_DOCS, [1], [Define if you we can build nm-setting-docs.xml, nm-keyfile-docs.xml and nm-ifcfg-rh-docs.xml])
build_setting_docs=yes
fi
build_setting_docs=yes
else
build_setting_docs=no
fi
if test -n "$INTROSPECTION_MAKEFILE"; then
have_introspection=yes
else
have_introspection=no
fi
# check for pre-built setting docs
@ -1121,9 +1126,7 @@ if test "$build_setting_docs" != "yes" \
-a -f man/nm-settings.xml \
-a -f man/nm-settings-keyfile.xml \
-a -f man/nm-settings-ifcfg-rh.xml \
-a -f docs/api/settings-spec.xml \
-a -f clients/cli/settings-docs.c; then
AC_DEFINE(HAVE_SETTING_DOCS, [1], [Define if you have pre-built settings docs])
-a -f docs/api/settings-spec.xml; then
have_setting_docs=yes
fi
@ -1219,6 +1222,8 @@ echo
echo "Miscellaneous:"
echo " documentation: $enable_gtk_doc"
echo " documentation-settings: $build_setting_docs"
echo " introspection: $have_introspection"
echo " tests: $enable_tests"
echo " more-asserts: $more_asserts"
echo " valgrind: $with_valgrind $with_valgrind_suppressions"