From: Richard Biener Date: Fri, 23 May 2025 11:32:47 +0000 (+0200) Subject: Conditionalize libgdiagnostic processing on presence X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d5ff1ccee3f39c4f364f671deb127789b754a6a0;p=thirdparty%2Fgcc.git Conditionalize libgdiagnostic processing on presence The following makes update_web_docs_git work on branches without libgdiagnostic. maintainer_scripts/ * update_web_docs_git: Conditionalize libgdiagnostic processing on presence. --- diff --git a/maintainer-scripts/update_web_docs_git b/maintainer-scripts/update_web_docs_git index 424808847b6..00334ddac7d 100755 --- a/maintainer-scripts/update_web_docs_git +++ b/maintainer-scripts/update_web_docs_git @@ -242,11 +242,15 @@ popd cp -a gcc/gcc/jit/docs/_build/html jit mkdir -p $DOCSDIR/jit -pushd gcc/gcc/doc/libgdiagnostics -make html SPHINXBUILD=$SPHINX_VENV/bin/sphinx-build || true -popd -cp -a gcc/gcc/doc/libgdiagnostics/_build/html libgdiagnostics -mkdir -p $DOCSDIR/libgdiagnostics +LIBGDIAGNOSTICS= +if test -d gcc/gcc/doc/libgdiagnostics; then + pushd gcc/gcc/doc/libgdiagnostics + make html SPHINXBUILD=$SPHINX_VENV/bin/sphinx-build || true + popd + cp -a gcc/gcc/doc/libgdiagnostics/_build/html libgdiagnostics + mkdir -p $DOCSDIR/libgdiagnostics + LIBGDIAGNOSTICS=libgdiagnostics +fi # Work around makeinfo generated file names and references with # "_002d" instead of "-". @@ -298,7 +302,7 @@ done # below them, and with some non-HTML files (.png images from us, # plus .css and .js supplied by sphinx, and source files, renamed # from .rst to .txt). -find jit libgdiagnostics \ +find jit $LIBGDIAGNOSTICS \ -name "*.html" -o -name "*.png" \ -o -name "*.css" -o -name "*.js" \ -o -name "*.txt" |