0002-Add-disable-documentation-option.patch 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. From 77ac8fcb78e3085577cd4eb5c4ac7746a5444f13 Mon Sep 17 00:00:00 2001
  2. From: Fabrice Fontaine <fontaine.fabrice@gmail.com>
  3. Date: Fri, 17 May 2019 15:48:35 +0200
  4. Subject: [PATCH] Add --disable-documentation option
  5. This option allows the user to disable man pages which can be useful if
  6. podman is not available
  7. Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
  8. [Upstream status: https://github.com/LudovicRousseau/PCSC/pull/60]
  9. ---
  10. configure.ac | 7 +++++++
  11. src/spy/Makefile.am | 2 ++
  12. 2 files changed, 9 insertions(+)
  13. diff --git a/configure.ac b/configure.ac
  14. index 0fa5168..7d20c6e 100644
  15. --- a/configure.ac
  16. +++ b/configure.ac
  17. @@ -144,6 +144,12 @@ esac
  18. AC_DEFINE_UNQUOTED(PCSC_ARCH, "$PCSC_ARCH", [PC/SC target architecture])
  19. PCSCLITE_FEATURES="${PCSCLITE_FEATURES} $PCSC_ARCH $host"
  20. +# --disable-documentation
  21. +AC_ARG_ENABLE(documentation,
  22. + AS_HELP_STRING([--disable-documentation],[do not build documentation]),
  23. + [ enable_doc="${enableval}" ], [ enable_doc="yes" ] )
  24. +AM_CONDITIONAL(ENABLE_DOC, test "$enable_doc" != "no")
  25. +
  26. # See if socket() is found from libsocket
  27. AC_CHECK_LIB(socket, socket, [LIBS="$LIBS -lsocket"])
  28. @@ -446,6 +452,7 @@ use libsystemd: ${use_libsystemd}
  29. systemd unit directory: ${with_systemdsystemunitdir}
  30. serial config dir.: ${confdir_exp}
  31. filter: ${use_filter}
  32. +documentation: ${enable_doc}
  33. PCSCLITE_FEATURES: ${PCSCLITE_FEATURES}
  34. diff --git a/src/spy/Makefile.am b/src/spy/Makefile.am
  35. index 3c3daee..0a83371 100644
  36. --- a/src/spy/Makefile.am
  37. +++ b/src/spy/Makefile.am
  38. @@ -6,6 +6,7 @@ dist_bin_SCRIPTS = pcsc-spy
  39. libpcscspy_la_SOURCES = \
  40. libpcscspy.c
  41. +if ENABLE_DOC
  42. man_MANS = pcsc-spy.1
  43. pcsc-spy.1: pcsc-spy.pod
  44. @@ -13,6 +14,7 @@ pcsc-spy.1: pcsc-spy.pod
  45. --center="PC/SC lite" \
  46. --release="$(PACKAGE_NAME) $(PACKAGE_VERSION)" \
  47. $(srcdir)/pcsc-spy.pod > $@
  48. +endif
  49. EXTRA_DIST = install_spy.sh uninstall_spy.sh pcsc-spy.pod
  50. CLEANFILES = pcsc-spy.1
  51. --
  52. 2.20.1