• R/O
  • HTTP
  • SSH
  • HTTPS

Commit

Tags
Keine Tags

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

The MinGW.org Windows System Libraries


Commit MetaInfo

Revision1612b9f8989f8927c10f3b9e33b8fec5f553f4f7 (tree)
Zeit2020-04-08 19:02:23
AutorKeith Marshall <keith@user...>
CommiterKeith Marshall

Log Message

Automatically enumerate manpages for publication.

Ändern Zusammenfassung

Diff

--- a/mingwrt/ChangeLog
+++ b/mingwrt/ChangeLog
@@ -1,3 +1,12 @@
1+2020-04-08 Keith Marshall <keith@users.osdn.me>
2+
3+ Automatically enumerate manpages for publication.
4+
5+ * Makefile.in (manpages): New macro; define, and use it...
6+ (mingwrt-man3): ...for this, to enumerate associated manpage sources.
7+ (manpage_copy, mancopy, manpage_ref): New macros; define them, and...
8+ (basename.3, getdelim.3): ...use them.
9+
110 2020-04-07 Keith Marshall <keith@users.osdn.me>
211
312 Document MinGW MBCS/wide character conversion functions.
--- a/mingwrt/Makefile.in
+++ b/mingwrt/Makefile.in
@@ -839,9 +839,13 @@ install-%-optional-dll: %.dll.a bindir libdir
839839 # Install manpages.
840840 #
841841 vpath %.man ${mingwrt_srcdir}/man
842+manpages = $(basename $(notdir $(wildcard $1/man/*.$2.man)))
843+mancopy = $(call manpage_ref,$1,$2.man)$(eval $1: %: %.$0-recursive)
844+manpage_ref = $(eval $1: export reference_manpage = $2)
845+
842846 install-man install-manpages: install-mingwrt-manpages
843-mingwrt-man$(man3ext): $(addsuffix .$(man3ext),basename dirname getline getdelim)
844-install-mingwrt-manpages: mandir mingwrt-man3
847+mingwrt-man$(man3ext): $(call manpages,${mingwrt_srcdir},$(man3ext))
848+install-mingwrt-manpages: mandir mingwrt-man$(man3ext)
845849
846850 mingwrt-man%:
847851 $(call mkinstalldirs,,${man$*dir})
@@ -854,11 +858,9 @@ mingwrt-man%:
854858 format_manpage = sed \
855859 -e "s/%PAGEREF%/`echo $1 | tr a-z A-Z` $(2:.%=%) `date -r $3 +%d-%b-%Y`/"
856860
857-basename.$(man3ext): export reference_manpage = dirname.$(man3ext).man
858-basename.$(man3ext): %: %.mancopy-recursive
859-
860-getdelim.$(man3ext): export reference_manpage = getline.$(man3ext).man
861-getdelim.$(man3ext): %: %.mancopy-recursive
861+manpage_copy = $(eval $1$3: $2.$3)$(call mancopy,$2.$3,$4)
862+$(call manpage_copy,mingwrt-man,basename,$(man3ext),dirname.$(man3ext))
863+$(call manpage_copy,mingwrt-man,getdelim,$(man3ext),getline.$(man3ext))
862864
863865 %.mancopy-recursive:
864866 $(MAKE) --no-print-directory $*.mancopy