diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 17:44:12 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 17:44:12 +0000 |
commit | 8ccb487c21368a7fdc8c7c72315325bf0aa06147 (patch) | |
tree | b2056fae01d325924508a41731edfbd4c3cddd23 /doc/man/date-of-man-include.am | |
parent | Initial commit. (diff) | |
download | mc-8ccb487c21368a7fdc8c7c72315325bf0aa06147.tar.xz mc-8ccb487c21368a7fdc8c7c72315325bf0aa06147.zip |
Adding upstream version 3:4.8.29.upstream/3%4.8.29upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | doc/man/date-of-man-include.am | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/man/date-of-man-include.am b/doc/man/date-of-man-include.am new file mode 100644 index 0000000..c6b1e69 --- /dev/null +++ b/doc/man/date-of-man-include.am @@ -0,0 +1,24 @@ +SED_PARAMETERS = \ + -e "s/%DATE_OF_MAN_PAGE%/$${MAN_DATE}/g" \ + -e "s/%MAN_VERSION%/@MAN_VERSION@/g" \ + -e "s{%sysconfdir%{@sysconfdir@{g" \ + -e "s{%libexecdir%{@libexecdir@{g" \ + -e "s{%pkglibexecdir%{$(libexecdir)/@PACKAGE@{g" \ + -e "s{%pkgdatadir%{$(datadir)/@PACKAGE@{g" + +MAN_DATE_CMD = \ + LC_ALL=$(DATE_LANG) @PERL_FOR_BUILD@ -CS -MPOSIX -e '\ + @fi=lstat("'$${MAN_FILE}'"); \ + print POSIX::strftime("$(DATE_FORMAT)", localtime($$fi[9]));' 2>/dev/null + +mc.1: $(srcdir)/mc.1.in + MAN_FILE=$<; MAN_DATE=$$($(MAN_DATE_CMD)); \ + sed $(SED_PARAMETERS) $< > $@ + +mcedit.1: $(srcdir)/mcedit.1.in + MAN_FILE=$<; MAN_DATE=$$($(MAN_DATE_CMD)); \ + sed $(SED_PARAMETERS) $< > $@ + +mcview.1: $(srcdir)/mcview.1.in + MAN_FILE=$<; MAN_DATE=$$($(MAN_DATE_CMD)); \ + sed $(SED_PARAMETERS) $< > $@ |