Re: [PATCH 01/13] doc: add package version to all manpages

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Dec 26, 2012 at 12:11:17AM +0100, Jan Engelhardt wrote:
> diff --git a/iptables/Makefile.am b/iptables/Makefile.am
> index 61e78db..0f4c1f6 100644
> --- a/iptables/Makefile.am
> +++ b/iptables/Makefile.am
> @@ -27,8 +27,8 @@ xtables_multi_LDADD   += ../libxtables/libxtables.la -lm
>  sbin_PROGRAMS    = xtables-multi
>  man_MANS         = iptables.8 iptables-restore.8 iptables-save.8 \
>                     iptables-xml.1 ip6tables.8 ip6tables-restore.8 \
> -                   ip6tables-save.8 iptables-extensions.8
> -CLEANFILES       = iptables.8 ip6tables.8
> +                   ip6tables-save.8 iptables-extensions.8 iptables-apply.8
> +CLEANFILES       = ${man_MANS}
>  
>  vx_bin_links   = iptables-xml
>  if ENABLE_IPV4
> @@ -38,14 +38,36 @@ if ENABLE_IPV6
>  v6_sbin_links  = ip6tables ip6tables-restore ip6tables-save
>  endif
>  
> -iptables.8: ${srcdir}/iptables.8.in
> -	${AM_VERBOSE_GEN} sed -e 's/@PACKAGE_AND_VERSION@/${PACKAGE} ${PACKAGE_VERSION}/g' $< >$@;
> +fill_in_date = ${AM_V_GEN} sed -e \
> +               's/@PACKAGE_AND_VERSION@/${PACKAGE} ${PACKAGE_VERSION}/g' \
> +               $< >$@;
> +
> +iptables-xml.1: ${srcdir}/iptables-xml.1.in
> +	${fill_in_date}
> +
> +ip6tables-restore.8: ${srcdir}/ip6tables-restore.8.in
> +	${fill_in_date}
> +
> +ip6tables-save.8: ${srcdir}/ip6tables-save.8.in
> +	${fill_in_date}
>  
>  ip6tables.8: ${srcdir}/ip6tables.8.in
> -	${AM_VERBOSE_GEN} sed -e 's/@PACKAGE_AND_VERSION@/${PACKAGE} ${PACKAGE_VERSION}/g' $< >$@;
> +	${fill_in_date}
> +
> +iptables-apply.8: ${srcdir}/iptables-apply.8.in
> +	${fill_in_date}
> +
> +iptables-restore.8: ${srcdir}/iptables-restore.8.in
> +	${fill_in_date}
> +
> +iptables-save.8: ${srcdir}/iptables-save.8.in
> +	${fill_in_date}
> +
> +iptables.8: ${srcdir}/iptables.8.in
> +	${fill_in_date}

This belongs more naturally to the ./configure stage, including
setting the date via AC_SUBST. You should be able to make it with
little changes in configure.ac.

For iptables-extensions.8 it will be a special case, it still requires
part of the magic in the makefile to build the page.
--
To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netfitler Users]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux