Makefile.am 5.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181
  1. # Copyright (c) 2004 MontaVista Software, Inc.
  2. # Copyright (c) 2009, 2012, 2014 Red Hat, Inc.
  3. #
  4. # Authors: Steven Dake (sdake@redhat.com)
  5. # Fabio M. Di Nitto (fdinitto@redhat.com)
  6. #
  7. # All rights reserved.
  8. #
  9. # This software licensed under BSD license, the text of which follows:
  10. #
  11. # Redistribution and use in source and binary forms, with or without
  12. # modification, are permitted provided that the following conditions are met:
  13. #
  14. # - Redistributions of source code must retain the above copyright notice,
  15. # this list of conditions and the following disclaimer.
  16. # - Redistributions in binary form must reproduce the above copyright notice,
  17. # this list of conditions and the following disclaimer in the documentation
  18. # and/or other materials provided with the distribution.
  19. # - Neither the name of the MontaVista Software, Inc. nor the names of its
  20. # contributors may be used to endorse or promote products derived from this
  21. # software without specific prior written permission.
  22. #
  23. # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
  24. # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  25. # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
  26. # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
  27. # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
  28. # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
  29. # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
  30. # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
  31. # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
  32. # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
  33. # THE POSSIBILITY OF SUCH DAMAGE.
  34. MAINTAINERCLEANFILES = Makefile.in
  35. xml_man = corosync-xmlproc.8 \
  36. corosync.xml.5
  37. INDEX_HTML = index.html
  38. autogen_man = cpg_context_get.3 \
  39. cpg_context_set.3 \
  40. cpg_dispatch.3 \
  41. cpg_fd_get.3 \
  42. cpg_finalize.3 \
  43. cpg_initialize.3 \
  44. cpg_join.3 \
  45. cpg_leave.3 \
  46. cpg_local_get.3 \
  47. cpg_mcast_joined.3 \
  48. cpg_model_initialize.3 \
  49. cpg_zcb_mcast_joined.3 \
  50. cpg_zcb_alloc.3 \
  51. cpg_zcb_free.3 \
  52. cpg_membership_get.3 \
  53. cpg_iteration_finalize.3 \
  54. cpg_iteration_initialize.3 \
  55. cpg_iteration_next.3 \
  56. quorum_initialize.3 \
  57. quorum_finalize.3 \
  58. quorum_fd_get.3 \
  59. quorum_dispatch.3 \
  60. quorum_context_get.3 \
  61. quorum_context_set.3 \
  62. quorum_getquorate.3 \
  63. quorum_trackstart.3 \
  64. quorum_trackstop.3 \
  65. votequorum_dispatch.3 \
  66. votequorum_fd_get.3 \
  67. votequorum_context_get.3 \
  68. votequorum_context_set.3 \
  69. votequorum_finalize.3 \
  70. votequorum_getinfo.3 \
  71. votequorum_initialize.3 \
  72. votequorum_setexpected.3 \
  73. votequorum_setvotes.3 \
  74. votequorum_trackstart.3 \
  75. votequorum_trackstop.3 \
  76. votequorum_qdevice_register.3 \
  77. votequorum_qdevice_unregister.3 \
  78. votequorum_qdevice_update.3 \
  79. votequorum_qdevice_master_wins.3 \
  80. votequorum_qdevice_poll.3 \
  81. sam_data_getsize.3 \
  82. sam_data_restore.3 \
  83. sam_data_store.3 \
  84. sam_finalize.3 \
  85. sam_hc_callback_register.3 \
  86. sam_hc_send.3 \
  87. sam_initialize.3 \
  88. sam_mark_failed.3 \
  89. sam_register.3 \
  90. sam_start.3 \
  91. sam_stop.3 \
  92. sam_warn_signal_set.3 \
  93. cmap_context_get.3 \
  94. cmap_dec.3 \
  95. cmap_iter_init.3 \
  96. cmap_get.3 \
  97. cmap_inc.3 \
  98. cmap_set.3 \
  99. cmap_iter_next.3 \
  100. cmap_delete.3 \
  101. cmap_iter_finalize.3 \
  102. cmap_finalize.3 \
  103. cmap_dispatch.3 \
  104. cmap_initialize.3 \
  105. cmap_initialize_map.3 \
  106. cmap_track_add.3 \
  107. cmap_context_set.3 \
  108. cmap_fd_get.3 \
  109. cmap_track_delete.3
  110. autogen_common = ipc_common.sh.errors
  111. EXTRA_DIST = $(INDEX_HTML) \
  112. $(xml_man) \
  113. $(autogen_man:%=%.in) \
  114. $(autogen_common)
  115. man_MANS = $(autogen_man)
  116. dist_man_MANS = corosync.conf.5 \
  117. votequorum.5 \
  118. corosync.8 \
  119. corosync-cmapctl.8 \
  120. corosync-blackbox.8 \
  121. corosync-keygen.8 \
  122. corosync-cfgtool.8 \
  123. corosync-cpgtool.8 \
  124. corosync-notifyd.8 \
  125. corosync-quorumtool.8 \
  126. corosync_overview.7 \
  127. cpg_overview.3 \
  128. quorum_overview.3 \
  129. votequorum_overview.3 \
  130. sam_overview.3 \
  131. cmap_overview.3 \
  132. cmap_keys.8
  133. if INSTALL_XMLCONF
  134. dist_man_MANS += $(xml_man)
  135. endif
  136. HTML_DOCS = $(dist_man_MANS:%=%.html) $(man_MANS:%=%.html)
  137. # developer man page generation
  138. %.3: %.3.in $(autogen_common)
  139. @echo Generating $@ man page && \
  140. rm -f $@-t-t $@-t $@ && \
  141. DATE_FMT="%Y-%m-%d" && \
  142. SOURCE_DATE_EPOCH="$${SOURCE_DATE_EPOCH:-$$(date +%s)}" && \
  143. date="$$(date -u -d "@$$SOURCE_DATE_EPOCH" "+$$DATE_FMT" 2>/dev/null || date -u -r "$$SOURCE_DATE_EPOCH" "+$$DATE_FMT" 2>/dev/null || date -u "+$$DATE_FMT")" && \
  144. awk "{print}(\$$1 ~ /@COMMONIPCERRORS@/){exit 0}" ${top_srcdir}/man/$@.in > $@-t-t && \
  145. cat ${top_srcdir}/man/$(autogen_common) >> $@-t-t && \
  146. awk -v p=0 "(\$$1 ~ /@COMMONIPCERRORS@/){p = 1} {if(p==1)print}" ${top_srcdir}/man/$@.in >> $@-t-t && \
  147. cat $@-t-t | \
  148. sed -e 's#@BUILDDATE@#'$$date'#g' \
  149. -e 's#@COMMONIPCERRORS@##g' \
  150. > $@-t && \
  151. rm -f $@-t-t && \
  152. mv $@-t $@
  153. clean-local:
  154. rm -rf $(HTML_DOCS) $(autogen_man)
  155. if BUILD_HTML_DOCS
  156. %.html: %
  157. $(GROFF) -mandoc -Thtml $^ > $@
  158. install-data-local:
  159. $(INSTALL) -d $(DESTDIR)/${docdir}/html
  160. $(INSTALL) -m 644 ${srcdir}/$(INDEX_HTML) $(HTML_DOCS) $(DESTDIR)/${docdir}/html/
  161. uninstall-local:
  162. cd $(DESTDIR)/${docdir}/html && rm -f $(INDEX_HTML) $(HTML_DOCS)
  163. rmdir $(DESTDIR)/${docdir}/html 2> /dev/null || :
  164. all-local: $(HTML_DOCS)
  165. endif