mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-23 12:56:51 +03:00
d27a4f86ea
Check perl, python and ruby programs and substitute them in various files. Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
23 lines
670 B
Plaintext
23 lines
670 B
Plaintext
SED_PARAMETERS = \
|
|
-e "s/%DATE_OF_MAN_PAGE%/$${MAN_DATE}/g" \
|
|
-e "s/%DISTR_VERSION%/@DISTR_VERSION@/g" \
|
|
-e "s{%prefix%{@prefix@{g" \
|
|
-e "s{%sysconfdir%{@sysconfdir@{g"
|
|
|
|
MAN_DATE_CMD = \
|
|
LC_ALL=$(DATE_LANG) @PERL@ -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) $< > $@
|