https://gcc.gnu.org/g:5d3b2f07b13682e49b18b7b06797d4965a600b56
commit r15-9253-g5d3b2f07b13682e49b18b7b06797d4965a600b56 Author: Jakub Jelinek <ja...@redhat.com> Date: Mon Apr 7 13:53:20 2025 +0200 cobol: Fix up update_web_docs_git for COBOL [PR119227] As mentioned in the PR, the COBOL documentation is currently not present in onlinedocs at all. While the script generates gcobol{,-io}.{pdf,html}, it generates them in the gcc/gcc/cobol/ subdirectory of the update_web_docs_git temporary directory and nothing find it there afterwards, all the processing is on for file in */*.html *.ps *.pdf *.tar; do So, this patch puts gcobol{,-io}.html into gcobol/ subdirectory and gcobol{,-io}.pdf into the current directory, so that it is picked up. With this it makes into onlinedocs: find . -name \*cobol\* ./onlinedocs/gcobol.pdf.gz ./onlinedocs/gcobol.pdf ./onlinedocs/gcobol_io.pdf.gz ./onlinedocs/gcobol_io.pdf ./onlinedocs/gcobol ./onlinedocs/gcobol/gcobol_io.html.gz ./onlinedocs/gcobol/gcobol_io.html ./onlinedocs/gcobol/gcobol.html.gz ./onlinedocs/gcobol/gcobol.html ./onlinedocs/gnat_rm/gnat_005frm_002finterfacing_005fto_005fother_005flanguages-interfacing-to-cobol.html.gz ./onlinedocs/gnat_rm/gnat_005frm_002finterfacing_005fto_005fother_005flanguages-interfacing-to-cobol.html ./onlinedocs/gnat_rm/gnat_005frm_002fimplementation_005fadvice-rm-f-7-cobol-support.html.gz ./onlinedocs/gnat_rm/gnat_005frm_002fimplementation_005fadvice-rm-f-7-cobol-support.html ./onlinedocs/gnat_rm/gnat_005frm_002fimplementation_005fadvice-rm-b-4-95-98-interfacing-with-cobol.html.gz ./onlinedocs/gnat_rm/gnat_005frm_002fimplementation_005fadvice-rm-b-4-95-98-interfacing-with-cobol.html 2025-04-07 Jakub Jelinek <ja...@redhat.com> PR web/119227 * update_web_docs_git: Rename mdoc2pdf_html to cobol_mdoc2pdf_html, perform mkdir -p $DOCSDIR/gcobol gcobol, remove $d/ from pdf and in html replace it with gcobol/; update uses of the renamed function. Diff: --- maintainer-scripts/update_web_docs_git | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/maintainer-scripts/update_web_docs_git b/maintainer-scripts/update_web_docs_git index 574397cec54b..424808847b6b 100755 --- a/maintainer-scripts/update_web_docs_git +++ b/maintainer-scripts/update_web_docs_git @@ -205,11 +205,12 @@ done # # The COBOL FE maintains man pages. Convert them to HTML and PDF. # -mdoc2pdf_html() { +cobol_mdoc2pdf_html() { + mkdir -p $DOCSDIR/gcobol gcobol input="$1" d="${input%/*}" - pdf="$d/$2" - html="$d/$3" + pdf="$2" + html="gcobol/$3" groff -mdoc -T pdf "$input" > "${pdf}~" mv "${pdf}~" "${pdf}" mandoc -T html "$filename" > "${html}~" @@ -221,10 +222,10 @@ find . -name gcobol.[13] | do case ${filename##*.} in 1) - mdoc2pdf_html "$filename" gcobol.pdf gcobol.html + cobol_mdoc2pdf_html "$filename" gcobol.pdf gcobol.html ;; 3) - mdoc2pdf_html "$filename" gcobol_io.pdf gcobol_io.html + cobol_mdoc2pdf_html "$filename" gcobol_io.pdf gcobol_io.html ;; esac done