diff options
Diffstat (limited to 'contrib')
-rw-r--r-- | contrib/ChangeLog | 7 | ||||
-rwxr-xr-x | contrib/texi2pod.pl | 9 |
2 files changed, 14 insertions, 2 deletions
diff --git a/contrib/ChangeLog b/contrib/ChangeLog index 000d274be84..b98ef7bc989 100644 --- a/contrib/ChangeLog +++ b/contrib/ChangeLog @@ -1,3 +1,10 @@ +2010-08-22 Ralf Wildenhues <Ralf.Wildenhues@gmx.de> + + * texi2pod.pl: Replace @@ before @{ and @}, for @samp{@@}. + Also escape characters with grave accents, to be fixed ... + (unmunge): ... here. + (postprocess): Also handle @/ and @acronym{...}. + 2010-07-02 Sebastian Pop <sebastian.pop@amd.com> * check_GNU_style.sh: Do not print warning messages when there are diff --git a/contrib/texi2pod.pl b/contrib/texi2pod.pl index fcdc14550ba..5a4bbacdf5e 100755 --- a/contrib/texi2pod.pl +++ b/contrib/texi2pod.pl @@ -1,6 +1,6 @@ #! /usr/bin/perl -w -# Copyright (C) 1999, 2000, 2001, 2003 Free Software Foundation, Inc. +# Copyright (C) 1999, 2000, 2001, 2003, 2010 Free Software Foundation, Inc. # This file is part of GCC. @@ -213,10 +213,12 @@ while(<$inf>) { # Now the ones that have to be replaced by special escapes # (which will be turned back into text by unmunge()) + # Replace @@ before @{ and @} in order to parse @samp{@@} correctly. s/&/&/g; + s/\@\@/&at;/g; s/\@\{/{/g; s/\@\}/}/g; - s/\@\@/&at;/g; + s/\@`\{(.)\}/&$1grave;/g; # Inside a verbatim block, handle @var, @samp and @url specially. if ($shift ne "") { @@ -391,9 +393,11 @@ sub postprocess s/\@(?:code|kbd)\{([^\}]*)\}/C<$1>/g; s/\@(?:samp|strong|key|option|env|command|b)\{([^\}]*)\}/B<$1>/g; s/\@sc\{([^\}]*)\}/\U$1/g; + s/\@acronym\{([^\}]*)\}/\U$1/g; s/\@file\{([^\}]*)\}/F<$1>/g; s/\@w\{([^\}]*)\}/S<$1>/g; s/\@(?:dmn|math)\{([^\}]*)\}/$1/g; + s/\@\///g; # keep references of the form @ref{...}, print them bold s/\@(?:ref)\{([^\}]*)\}/B<$1>/g; @@ -462,6 +466,7 @@ sub unmunge # Replace escaped symbols with their equivalents. local $_ = $_[0]; + s/&(.)grave;/E<$1grave>/g; s/</E<lt>/g; s/>/E<gt>/g; s/{/\{/g; |