2012-03-22 21:14:52 +04:00
|
|
|
SED_PARAMETERS = \
|
|
|
|
-e "s/%DATE_OF_MAN_PAGE%/$${MAN_DATE}/g" \
|
2021-04-04 10:12:00 +03:00
|
|
|
-e "s/%MAN_VERSION%/@MAN_VERSION@/g" \
|
2013-02-07 12:37:07 +04:00
|
|
|
-e "s{%sysconfdir%{@sysconfdir@{g" \
|
2022-11-28 22:49:31 +03:00
|
|
|
-e "s{%libexecdir%{@libexecdir@{g" \
|
|
|
|
-e "s{%pkglibexecdir%{$(libexecdir)/@PACKAGE@{g" \
|
|
|
|
-e "s{%pkgdatadir%{$(datadir)/@PACKAGE@{g"
|
2010-06-11 17:14:39 +04:00
|
|
|
|
2012-03-22 21:14:52 +04:00
|
|
|
MAN_DATE_CMD = \
|
2022-08-18 12:40:20 +03:00
|
|
|
LC_ALL=$(DATE_LANG) @PERL_FOR_BUILD@ -CS -MPOSIX -e '\
|
2012-03-22 21:14:52 +04:00
|
|
|
@fi=lstat("'$${MAN_FILE}'"); \
|
|
|
|
print POSIX::strftime("$(DATE_FORMAT)", localtime($$fi[9]));' 2>/dev/null
|
2010-06-11 17:14:39 +04:00
|
|
|
|
2012-03-22 21:14:52 +04:00
|
|
|
mc.1: $(srcdir)/mc.1.in
|
2023-05-19 19:26:02 +03:00
|
|
|
MAN_FILE='$(srcdir)/mc.1.in'; MAN_DATE=$$($(MAN_DATE_CMD)); \
|
|
|
|
$(SED) $(SED_PARAMETERS) '$(srcdir)/mc.1.in' > '$@'
|
2010-06-11 17:14:39 +04:00
|
|
|
|
2012-03-22 21:14:52 +04:00
|
|
|
mcview.1: $(srcdir)/mcview.1.in
|
2023-05-19 19:26:02 +03:00
|
|
|
MAN_FILE='$(srcdir)/mcview.1.in'; MAN_DATE=$$($(MAN_DATE_CMD)); \
|
|
|
|
$(SED) $(SED_PARAMETERS) '$(srcdir)/mcview.1.in' > '$@'
|
2024-02-11 19:34:34 +03:00
|
|
|
|
|
|
|
if USE_INTERNAL_EDIT
|
|
|
|
mcedit.1: $(srcdir)/mcedit.1.in
|
|
|
|
MAN_FILE='$(srcdir)/mcedit.1.in'; MAN_DATE=$$($(MAN_DATE_CMD)); \
|
|
|
|
$(SED) $(SED_PARAMETERS) '$(srcdir)/mcedit.1.in' > '$@'
|
|
|
|
endif
|
2024-04-07 16:05:48 +03:00
|
|
|
|
|
|
|
if USE_DIFF
|
|
|
|
mcdiff.1: $(srcdir)/mcdiff.1.in
|
|
|
|
MAN_FILE='$(srcdir)/mcdiff.1.in'; MAN_DATE=$$($(MAN_DATE_CMD)); \
|
|
|
|
$(SED) $(SED_PARAMETERS) '$(srcdir)/mcdiff.1.in' > '$@'
|
|
|
|
endif
|