diff --git a/.codedocs b/.codedocs index 699b91566fa..077aaf51d8b 100644 --- a/.codedocs +++ b/.codedocs @@ -1,3 +1,3 @@ -EXCLUDE = addon cmake doc examples jquery templates testing winbuild src/logos.cpp src/lodepng.cpp +EXCLUDE = addon cmake doc examples jquery templates testing deps/iconv_winbuild src/logos.cpp src/lodepng.cpp FILE_PATTERNS = *.h *.cpp *.md USE_MDFILE_AS_MAINPAGE = src/doxygen.md diff --git a/.dockerignore b/.dockerignore new file mode 100644 index 00000000000..f3bb41bd177 --- /dev/null +++ b/.dockerignore @@ -0,0 +1,27 @@ +*~ +.*sw? +\#* +.DS_Store + +*.rej +*.orig + +*.pro +/packages/rpm/doxygen.spec +*.idb +*.pdb + +/doxygen_docs +/doxygen.tag +/build* +/qtools_docs +/warnings.log + +tags + +.idea + +/examples/html/* +/examples/latex/* + +Dockerfile diff --git a/.editorconfig b/.editorconfig index ddc5adf72ce..7531b008533 100644 --- a/.editorconfig +++ b/.editorconfig @@ -3,3 +3,7 @@ [*] indent_style = space indent_size = 2 +charset = utf-8 + +[*.py] +indent_size = 4 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 00000000000..aeebd08e9d0 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,9 @@ +* text=auto eol=lf +* text + +### Protected +*.pdf binary +*.ico binary +*.jpg binary +*.png binary +*.lib binary \ No newline at end of file diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 00000000000..56aba5b48c9 --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,13 @@ +# These are supported funding model platforms + +github: doxygen +patreon: # Replace with a single Patreon username +open_collective: # Replace with a single Open Collective username +ko_fi: # Replace with a single Ko-fi username +tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel +community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry +liberapay: # Replace with a single Liberapay username +issuehunt: # Replace with a single IssueHunt username +otechie: # Replace with a single Otechie username +lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry +custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2'] diff --git a/.github/ISSUE_TEMPLATE/report-a-bug-or-issue.md b/.github/ISSUE_TEMPLATE/report-a-bug-or-issue.md index d328fe79be2..bbb736b1889 100644 --- a/.github/ISSUE_TEMPLATE/report-a-bug-or-issue.md +++ b/.github/ISSUE_TEMPLATE/report-a-bug-or-issue.md @@ -10,9 +10,6 @@ assignees: '' **Describe the bug** Describe what you see that (you think) is wrong. -**Expected behavior** -Describe what you would have expected or think is correct. - **Screenshots** If useful, add screenshots to help explain your problem. @@ -20,8 +17,11 @@ If useful, add screenshots to help explain your problem. Attach a self contained example that allows us to reproduce the problem. Such an example typically exist of some source code (can be dummy code) and a doxygen configuration file used (you can strip it using `doxygen -s -u`). After you verified the example demonstrates the problem, put it in a zip (or tarball) and attach it to the bug report. Try to avoid linking to external sources, since they might disappear in the future. +**Expected behavior** +Describe what you would have expected or think is correct. + **Version** -Mention the version of doxygen used (output of `doxygen --version`) and the platform on which you run doxygen (e.g. Windows 10, 64 bit). If you run doxygen under Linux please also mention the name and version of the distribution used (output of `lsb_release -a`) and mention if you compiled doxygen yourself or that you use a binary that comes with the distribution or from the doxygen website. +Mention the version of doxygen used (output of `doxygen --version`) and the platform on which you run doxygen (e.g. Windows 10, 64 bit). If you run doxygen under Linux please also mention the name and version of the distribution used (output of `lsb_release -a`) and mention if you compiled doxygen yourself or that you use a binary that comes with the distribution or from the doxygen website. **Stack trace** If you encounter a crash and can build doxygen from sources yourself with debug info (`-DCMAKE_BUILD_TYPE=Debug`), a stack trace can be very helpful (especially if it is not possible to capture the problem in a small example that can be shared). diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 00000000000..5ace4600a1f --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: "github-actions" + directory: "/" + schedule: + interval: "weekly" diff --git a/.github/workflows/build_cmake.yml b/.github/workflows/build_cmake.yml index f09a604af5a..891dbcccc06 100644 --- a/.github/workflows/build_cmake.yml +++ b/.github/workflows/build_cmake.yml @@ -4,6 +4,9 @@ on: [push, pull_request] jobs: build: + permissions: + contents: write # to push pages branch (peaceiris/actions-gh-pages) + name: ${{ matrix.config.name }} runs-on: ${{ matrix.config.os }} strategy: @@ -11,158 +14,186 @@ jobs: matrix: config: - { - name: "Ubuntu Latest GCC Release", - os: ubuntu-18.04, + name: "Ubuntu Latest GCC Release (Intel)", + os: ubuntu-22.04, build_type: "Release", cc: "gcc", cxx: "g++", build_gen: "Unix Makefiles", - cmake_extra_opts: "-Dbuild_search=YES -Dbuild_app=YES -Dbuild_parse=YES -Dbuild_xmlparser=YES -Duse_sqlite3=ON" + cmake_extra_opts: "-Dbuild_search=YES -Dbuild_app=YES -Dbuild_parse=YES" } - { - name: "Ubuntu Latest GCC Debug", - os: ubuntu-18.04, + name: "Ubuntu Latest GCC Debug (Intel)", + os: ubuntu-22.04, build_type: "Debug", cc: "gcc", cxx: "g++", build_gen: "Unix Makefiles", - cmake_extra_opts: "-Dbuild_search=YES -Dbuild_app=YES -Dbuild_parse=YES -Dbuild_xmlparser=YES -Duse_sqlite3=ON" + cmake_extra_opts: "-Dbuild_search=YES -Dbuild_app=YES -Dbuild_parse=YES" } - { - name: "Ubuntu Latest Clang Release", - os: ubuntu-20.04, + name: "Ubuntu Latest Clang Release (Intel)", + os: ubuntu-22.04, build_type: "Release", cc: "clang", cxx: "clang++", build_gen: "Unix Makefiles", - cmake_extra_opts: "-Duse_libclang=YES -Dstatic_libclang=YES -Duse_libc++=NO -Duse_sqlite3=ON" + cmake_extra_opts: "-Duse_libclang=YES -Dstatic_libclang=YES -Duse_libc++=NO" } - { - name: "Ubuntu Latest Clang Debug", - os: ubuntu-20.04, + name: "Ubuntu Latest Clang Debug (Intel)", + os: ubuntu-22.04, build_type: "Debug", cc: "clang", cxx: "clang++", build_gen: "Unix Makefiles", - cmake_extra_opts: "-Duse_libclang=YES -Dstatic_libclang=YES -Duse_libc++=NO -Duse_sqlite3=ON" + cmake_extra_opts: "-Duse_libclang=YES -Dstatic_libclang=YES -Duse_libc++=NO" } + - { - name: "macOS Latest Release", - os: macos-latest, + name: "Ubuntu Latest GCC Release (Arm)", + os: ubuntu-24.04-arm, + build_type: "Release", cc: "gcc", cxx: "g++", + build_gen: "Unix Makefiles", + cmake_extra_opts: "-Dbuild_search=YES -Dbuild_app=YES -Dbuild_parse=YES" + } + - { + name: "Ubuntu Latest GCC Debug (Arm)", + os: ubuntu-24.04-arm, + build_type: "Debug", cc: "gcc", cxx: "g++", + build_gen: "Unix Makefiles", + cmake_extra_opts: "-Dbuild_search=YES -Dbuild_app=YES -Dbuild_parse=YES" + } + - { + name: "Ubuntu Latest Clang Release (Arm)", + os: ubuntu-24.04-arm, + build_type: "Release", cc: "clang", cxx: "clang++", + build_gen: "Unix Makefiles", + cmake_extra_opts: "-Duse_libclang=YES -Dstatic_libclang=YES -Duse_libc++=NO" + } + - { + name: "Ubuntu Latest Clang Debug (Arm)", + os: ubuntu-24.04-arm, + build_type: "Debug", cc: "clang", cxx: "clang++", + build_gen: "Unix Makefiles", + cmake_extra_opts: "-Duse_libclang=YES -Dstatic_libclang=YES -Duse_libc++=NO" + } + - { + name: "macOS Latest Release (Intel)", + os: macos-13, build_type: "Release", cc: "clang", cxx: "clang++", build_gen: "Unix Makefiles" } - { - name: "macOS Latest Debug", - os: macos-latest, + name: "macOS Latest Debug (Intel)", + os: macos-13, build_type: "Debug", cc: "clang", cxx: "clang++", build_gen: "Unix Makefiles" } - { - name: "Windows Latest MSVC Debug", + name: "macOS Latest Release (Apple Silicon)", + os: macos-14, + build_type: "Release", cc: "clang", cxx: "clang++", + build_gen: "Unix Makefiles" + } + - { + name: "macOS Latest Debug (Apple Silicon)", + os: macos-14, + build_type: "Debug", cc: "clang", cxx: "clang++", + build_gen: "Unix Makefiles" + } + - { + name: "Windows Latest MSVC Debug", os: windows-latest, build_type: "Debug", cc: "cl", cxx: "cl", build_gen: "NMake Makefiles" } - { - name: "Windows Latest MSVC Release", + name: "Windows Latest MSVC Release", os: windows-latest, build_type: "Release", cc: "cl", cxx: "cl", build_gen: "NMake Makefiles" } steps: - name: Checkout doxygen - uses: actions/checkout@v1 - - - name: Download MikTex (Windows) - run: | - $wc = New-Object System.Net.WebClient; - $maxAttempts=5; - $attemptCount=0; - Do { - $attemptCount++; - Try { - $wc.DownloadFile("https://ctan.math.illinois.edu/systems/win32/miktex/setup/windows-x64/miktexsetup-4.1-x64.zip","miktexsetup-4.1-x64.zip") - } Catch [Exception] { - Write-Host $_.Exception | format-list -force - } - } while (((Test-Path "miktexsetup-4.1-x64.zip") -eq $false) -and ($attemptCount -le $maxAttempts)) - shell: pwsh - if: matrix.config.os == 'windows-latest' - + uses: actions/checkout@v4 + with: + fetch-depth: 0 + - name: Install libiconv (Windows) uses: suisei-cn/actions-download-file@v1 - with: + with: url: "https://github.com/pffang/libiconv-for-Windows/releases/download/v1.16/libiconv-for-Windows_1.16.7z" - target: . + target: . if: matrix.config.os == 'windows-latest' - name: Install LaTeX (Linux) - run: sudo apt-get install texlive texlive-latex-recommended texlive-extra-utils texlive-latex-extra texlive-font-utils + run: | + sudo apt update --fix-missing + sudo apt upgrade + sudo apt update + sudo apt-get install texlive texlive-latex-recommended texlive-extra-utils texlive-latex-extra texlive-font-utils if: startsWith(matrix.config.os,'ubuntu-') - name: Install LaTeX (MacOS) run: | - brew install --cask mactex; + brew update || true + brew install --cask mactex || true echo "/Library/TeX/texbin/" >> $GITHUB_PATH - if: matrix.config.os == 'macos-latest' - - - name: Install libclang (Ubuntu 20.04) + if: startsWith(matrix.config.os,'macos-') + + - name: Install libclang (Ubuntu 22.04) run: | - sudo apt remove llvm-8 clang-8 libclang-common-8-dev clang-format-8 libllvm8 - sudo apt remove llvm-9 llvm-9-dev llvm-9-tools llvm-9-runtime clang-9 libclang-common-9-dev clang-format-9 libllvm9 - #sudo apt remove llvm-10 llvm-10-dev llvm-10-tools llvm-10-runtime clang-10 clang-format-10 libclang-common-10-dev libclang-cpp10 libclang1-10 libllvm10 - sudo apt remove llvm-11 llvm-11-dev llvm-11-tools llvm-11-runtime clang-11 clang-format-11 libclang-common-11-dev libclang-cpp11 libclang1-11 libllvm11 - sudo apt remove llvm-12 llvm-12-dev llvm-12-tools llvm-12-runtime clang-12 clang-format-12 libclang-common-12-dev libclang-cpp12 libclang1-12 libllvm12 + sudo apt update + sudo apt remove llvm-13 llvm-13-dev llvm-13-tools llvm-13-runtime clang-13 clang-format-13 libclang-common-13-dev libclang-cpp13 libclang1-13 libllvm13 + sudo apt remove llvm-15 llvm-15-dev llvm-15-tools llvm-15-runtime clang-15 clang-format-15 libclang-common-15-dev libclang-cpp15 libclang1-15 libllvm15 sudo apt-get autoremove sudo apt-get clean - sudo apt install libclang-common-10-dev libclang-10-dev + sudo apt install libclang-common-14-dev libclang-14-dev apt list --installed | egrep '(clang|llvm)' ls -d /usr/lib/llvm-*/include/ - sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-10 100 - sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-10 100 + sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-14 100 + sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-14 100 ls -al /usr/bin/clang++ ls -al /etc/alternatives/clang++ which clang++ clang++ -v - if: matrix.config.os == 'ubuntu-20.04' - - - name: Install libxapian (Ubuntu 18.04) - run: | - sudo apt install libxapian-dev - if: matrix.config.os == 'ubuntu-18.04' - - - name: Extract MikTex zip (Windows) - shell: bash - run: | - unzip miktexsetup-4.1-x64.zip - if: matrix.config.os == 'windows-latest' + if: matrix.config.cc == 'clang' && matrix.config.os == 'ubuntu-22.04' - - name: Download MikTex packages (Windows) - shell: bash + - name: Install libclang (Ubuntu 24.04 ARM) run: | - ./miktexsetup_standalone --verbose \ - --local-package-repository=C:/miktex-repository \ - --remote-package-repository="https://ctan.math.illinois.edu/systems/win32/miktex/tm/packages/" \ - --package-set=essential \ - download - if: matrix.config.os == 'windows-latest' + sudo apt update + sudo apt remove llvm-14 llvm-14-dev llvm-14-tools llvm-14-runtime clang-14 clang-format-14 libclang-common-14-dev libclang-cpp14 libclang1-14 libllvm14 + sudo apt remove llvm-15 llvm-15-dev llvm-15-tools llvm-15-runtime clang-15 clang-format-15 libclang-common-15-dev libclang-cpp15 libclang1-15 libllvm15 + sudo apt remove llvm-16 llvm-16-dev llvm-16-tools llvm-16-runtime clang-16 clang-format-16 libclang-common-16-dev libclang-cpp16 libclang1-16 libllvm16 + sudo apt-get autoremove + sudo apt-get clean + sudo apt install -y libclang-common-18-dev libclang-18-dev clang-18 llvm-18 llvm-18-dev + apt list --installed | egrep '(clang|llvm)' + ls -d /usr/lib/llvm-*/include/ + sudo update-alternatives --install /usr/bin/clang clang /usr/bin/clang-18 100 + sudo update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-18 100 + ls -al /usr/bin/clang++ + ls -al /etc/alternatives/clang++ + which clang++ + clang++ -v + if: matrix.config.os == 'ubuntu-24.04-arm' - - name: Install MikTex packages (Windows) - shell: bash + - name: Install libxapian (Ubuntu 22.04) run: | - ./miktexsetup_standalone --local-package-repository=C:/miktex-repository \ - --package-set=essential \ - --shared \ - install - if: matrix.config.os == 'windows-latest' + sudo apt update + sudo apt install libxapian-dev + if: matrix.config.os == 'ubuntu-22.04' || matrix.config.os == 'ubuntu-24.04-arm' - - name: Setting MikTex paths (Windows) - shell: bash - run: | - echo "C:/Program Files/MiKTeX/miktex/bin/x64/" >> $GITHUB_PATH - export PATH="/c/Program Files/MiKTeX/miktex/bin/x64/:$PATH" - - echo "Configuring MiKTeX to install missing packages on the fly" - initexmf --admin --verbose --set-config-value='[MPM]AutoInstall=1' + - name: Install LaTeX (Windows) + uses: teatimeguest/setup-texlive-action@v3 + with: + packages: >- + scheme-medium + collection-latexextra + babel-dutch + cjk + bibtex if: matrix.config.os == 'windows-latest' - name: Install Ghostscript (Linux) - run: sudo apt-get install ghostscript + run: | + sudo apt update + sudo apt-get install ghostscript if: startsWith(matrix.config.os,'ubuntu-') - + - name: Install Ghostscript (Windows) run: choco install ghostscript @@ -176,7 +207,7 @@ jobs: export GSpath=`echo "$GSpath" | sed -e "s%/c%C:%"` echo "$GSpath" >> $GITHUB_PATH if: matrix.config.os == 'windows-latest' - + - name: Install xmllint (Linux) run: | sudo apt-get update @@ -184,50 +215,78 @@ jobs: if: startsWith(matrix.config.os,'ubuntu-') - name: Install xmllint (MacOS) - run: brew install libxml2 - if: matrix.config.os == 'macos-latest' + run: | + brew install --force --overwrite python@3.11 # temp hack + brew install --force --overwrite python@3.12 # temp hack + brew update + brew install libxml2 + if: startsWith(matrix.config.os,'macos-') - name: Install bison (MacOS) run: | + brew update brew install bison; - echo "/usr/local/opt/bison/bin" >> $GITHUB_PATH - if: matrix.config.os == 'macos-latest' - + echo "$(brew --prefix bison)/bin" >> $GITHUB_PATH + #echo "/usr/local/opt/bison/bin" >> $GITHUB_PATH + if: startsWith(matrix.config.os,'macos-') + - name: Install bison/flex (Windows) - run: - choco install winflexbison + run: | + #Choco-Install -PackageName winflexbison + choco install winflexbison3 if: matrix.config.os == 'windows-latest' - name: Install Graphviz (Linux) - run: sudo apt-get install graphviz + run: | + sudo apt update + sudo apt-get install graphviz if: startsWith(matrix.config.os,'ubuntu-') - name: Install Graphviz (MacOS) - run: brew install graphviz - if: matrix.config.os == 'macos-latest' + run: | + if ! brew install graphviz; then + # Workaround issue with unexpected symlinks: https://github.com/actions/runner-images/issues/6817 + for f in 2to3 idle3 pydoc3 python3 python3-config; do + rm /usr/local/bin/$f || true + done + # Try again + brew install graphviz + fi + if: startsWith(matrix.config.os,'macos-') - name: Install Graphviz (Windows) run: choco install graphviz.portable if: matrix.config.os == 'windows-latest' -# - name: Install Perl (Windows) -# run: -# choco install activeperl -# if: matrix.config.os == 'windows-latest' - - name: Setup VS Environment (Windows) uses: seanmiddleditch/gha-setup-vsdevenv@master if: matrix.config.os == 'windows-latest' - name: Refresh Env (Windows) - run: + run: | + Import-Module $env:ChocolateyInstall\helpers\chocolateyProfile.psm1 refreshenv if: matrix.config.os == 'windows-latest' - - - name: Install Qt - uses: jurplel/install-qt-action@v2 - + + - name: Install Qt 6.8 + uses: jdpurcell/install-qt-action@v5 + with: + version: 6.8.* + if: matrix.config.os == 'ubuntu-24.04-arm' + + - name: Install Qt 6.2 + uses: jdpurcell/install-qt-action@v5 + with: + version: 6.2.* + if: startsWith(matrix.config.os,'macos-') + + - name: Install Qt 5 + uses: jdpurcell/install-qt-action@v5 + with: + version: 5.* + if: startsWith(matrix.config.os,'macos-')!=true && matrix.config.os != 'ubuntu-24.04-arm' + - name: Check tool versions (Linux / MacOS) shell: bash run: | @@ -292,7 +351,7 @@ jobs: -G "${{ matrix.config.build_gen }}" -Dbuild_doc=YES -Dbuild_wizard=YES - ${{ matrix.config.cmake_extra_opts }} + ${{ matrix.config.cmake_extra_opts }} RESULT_VARIABLE result ) if (NOT result EQUAL 0) @@ -305,7 +364,7 @@ jobs: include(ProcessorCount) ProcessorCount(N) execute_process( - COMMAND cmake --build build --parallel ${N} + COMMAND cmake --build build --parallel ${N} RESULT_VARIABLE result OUTPUT_VARIABLE output ERROR_VARIABLE output @@ -319,7 +378,7 @@ jobs: endif() - name: Archive build artifacts - uses: actions/upload-artifact@v2 + uses: actions/upload-artifact@v4 with: name: "${{ matrix.config.name }} build artifacts" path: build/bin/ @@ -327,13 +386,12 @@ jobs: - name: Run tests (Linux / MacOS) shell: cmake -P {0} run: | - include(ProcessorCount) - ProcessorCount(N) - set(ENV{CTEST_OUTPUT_ON_FAILURE} "ON") execute_process( - COMMAND cmake --build build --target tests TEST_FLAGS="--xml --xmlxsd --xhtml --docbook --rtf" + COMMAND + cmake -E env TEST_FLAGS="--xml --xmlxsd --xhtml --qhp --docbook --rtf --man" + cmake --build build --target tests RESULT_VARIABLE result ) if (NOT result EQUAL 0) @@ -344,13 +402,12 @@ jobs: - name: Run tests (Windows) shell: cmake -P {0} run: | - include(ProcessorCount) - ProcessorCount(N) - set(ENV{CTEST_OUTPUT_ON_FAILURE} "ON") execute_process( - COMMAND cmake --build build --target tests TEST_FLAGS="--xml --xmlxsd" + COMMAND + cmake -E env TEST_FLAGS="--xml --xmlxsd --xhtml --qhp --docbook --rtf --man --pdf" + cmake --build build --target tests RESULT_VARIABLE result ) if (NOT result EQUAL 0) @@ -368,4 +425,40 @@ jobs: if (NOT result EQUAL 0) message(FATAL_ERROR "Building documentation failed") endif() - if: matrix.config.os != 'windows-latest' + + - name: Archive html documentation artifacts + uses: actions/upload-artifact@v4 + with: + name: "Html documentation artifacts" + path: build/html/ + if: matrix.config.name == 'Ubuntu Latest GCC Release (Intel)' + + - name: Archive Latex documentation artifacts + uses: actions/upload-artifact@v4 + with: + name: "Latex documentation artifacts" + path: build/latex/doxygen_manual.pdf + if: matrix.config.name == 'Ubuntu Latest GCC Release (Intel)' + + - name: Generate Internal documentation + shell: cmake -P {0} + run: | + execute_process( + COMMAND cmake --build build --target docs_internal + RESULT_VARIABLE result + ) + if (NOT result EQUAL 0) + message(FATAL_ERROR "Building internal documentation failed") + endif() + if: matrix.config.name == 'Ubuntu Latest GCC Release (Intel)' + + - name: Publish Internal documentation to Github pages + uses: peaceiris/actions-gh-pages@v4 + with: + deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }} + external_repository: doxygen/doxygen-docs + publish_dir: build/doxygen_docs/html + force_orphan: true + if: ${{ github.event_name == 'push' && matrix.config.name == 'Ubuntu Latest GCC Release (Intel)' }} + + diff --git a/.github/workflows/coverity.yml b/.github/workflows/coverity.yml new file mode 100644 index 00000000000..3f3ca5db89e --- /dev/null +++ b/.github/workflows/coverity.yml @@ -0,0 +1,80 @@ +name: Coverity for doxygen + +# Just for tests +#on: [push, pull_request] + +# The right schedule +on: + schedule: + - cron: '30 2 * * *' # Run once per day, to avoid Coverity's submission limits + + +permissions: + contents: read + +jobs: + check_date: + runs-on: ubuntu-22.04 + name: Check latest commit + outputs: + should_run: ${{ steps.should_run.outputs.should_run }} + steps: + - uses: actions/checkout@v4 + - name: print latest_commit + run: echo ${{ github.sha }} + + - id: should_run + continue-on-error: true + name: check latest commit is less than a day + if: ${{ github.event_name == 'schedule' }} + run: test -z $(git rev-list --after="24 hours" ${{ github.sha }}) && echo "::set-output name=should_run::false" + + scan: + needs: check_date + if: ${{ needs.check_date.outputs.should_run != 'false' }} + runs-on: ubuntu-22.04 + + env: + CC: gcc + DEBIAN_FRONTEND: noninteractive + + steps: + - name: Checkout doxygen + uses: actions/checkout@v4 + + - name: Download Coverity + run: | + wget -q https://scan.coverity.com/download/cxx/linux64 --post-data "token=$TOKEN&project=doxygen%2Fdoxygen" -O coverity_tool.tgz + mkdir cov-scan + tar ax -f coverity_tool.tgz --strip-components=1 -C cov-scan + env: + TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }} + + - name: Setup environment + run: | + echo "$(pwd)/cov-scan/bin" >> $GITHUB_PATH + echo "NPROC=$(getconf _NPROCESSORS_ONLN)" >> $GITHUB_ENV + + - name: Configure doxygen + run: | + mkdir build + cmake -S . -B build -D CMAKE_BUILD_TYPE=Release -G "Unix Makefiles" + + - name: Run coverity build/scan + run: | + cd build && cov-build --dir cov-int make -j${NPROC} + + - name: Submit results + run: | + cd build + tar zcf cov-scan.tgz cov-int + curl --form token=$TOKEN \ + --form email=$EMAIL \ + --form file=@cov-scan.tgz \ + --form version="$(git rev-parse HEAD)" \ + --form description="Automatic GHA scan" \ + 'https://scan.coverity.com/builds?project=doxygen%2Fdoxygen' + env: + TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }} + EMAIL: ${{ secrets.COVERITY_SCAN_EMAIL }} + diff --git a/.github/workflows/docker_publish.yml b/.github/workflows/docker_publish.yml new file mode 100644 index 00000000000..8d229dc0f27 --- /dev/null +++ b/.github/workflows/docker_publish.yml @@ -0,0 +1,41 @@ +name: Publish Docker package + +on: + release: + types: [published] + +env: + REGISTRY: ghcr.io + IMAGE_NAME: ${{ github.repository }} + +jobs: + build: + runs-on: ubuntu-latest + permissions: + contents: read + packages: write + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Log in to the Container registry + uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 + with: + registry: ${{ env.REGISTRY }} + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@902fa8ec7d6ecbf8d84d538b9b233a880e428804 + with: + images: ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }} + + - name: Build and push Docker image + uses: docker/build-push-action@471d1dc4e07e5cdedd4c2171150001c434f0b7a4 + with: + context: . + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} diff --git a/.github/workflows/doxmlparser-publish.yml b/.github/workflows/doxmlparser-publish.yml new file mode 100644 index 00000000000..34cccbc2e7e --- /dev/null +++ b/.github/workflows/doxmlparser-publish.yml @@ -0,0 +1,34 @@ +name: Upload Python Package + +on: + release: + types: [published] + +permissions: + contents: read + +jobs: + deploy: + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - name: Set up Python + uses: actions/setup-python@v5 + with: + python-version: '3.x' + + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install build + + - name: Build package + run: python -m build -w addon/doxmlparser/ + + - name: Publish package + uses: pypa/gh-action-pypi-publish@release/v1 + with: + packages-dir: addon/doxmlparser/dist/ + user: __token__ + password: ${{ secrets.PYPI_API_TOKEN }} diff --git a/.gitignore b/.gitignore index 987aa13aca0..1283dbe4726 100644 --- a/.gitignore +++ b/.gitignore @@ -18,5 +18,12 @@ /warnings.log tags +.cache/ .idea +cmake-build-debug/ +cmake-build-debug-event-trace/ +.vscode/ + +/examples/html/* +/examples/latex/* diff --git a/BUILD.txt b/BUILD.txt index 400b439d84c..e46c72a55b0 100644 --- a/BUILD.txt +++ b/BUILD.txt @@ -1,5 +1,8 @@ Doxygen uses cmake (http://www.cmake.org/) to build executables for various platforms. -At least cmake version 3.3 is required. +See the Installation section of the manual for dependencies and instructions: +https://www.doxygen.nl/manual/install.html + +For a one-step self-contained environment, you can also use Docker to build and run the included Dockerfile. The first step is to create a build directory where the output should be stored. Doxygen can be fully built outside of the source tree. @@ -8,18 +11,19 @@ The second step is to invoke cmake from within the build directory with the desi For Linux/Unix systems do the following: - mkdir build - cd build - cmake -G "Unix Makefiles" path/to/root/of/doxygen/source/tree - make + mkdir build + cd build + cmake -G "Unix Makefiles" path/to/root/of/doxygen/source/tree + make +Note: "path/to/root/of/doxygen/source/tree" is not the "src" directory but its parent. This also works for MacOS, but if XCode is installed you can also generate an XCode project file - cmake -G XCode path/to/root/of/doxygen/source/tree + cmake -G XCode path/to/root/of/doxygen/source/tree For Windows one can generate a Visual Studio project using - cmake -G "Visual Studio 12 2013" path\to\root\of\doxygen\source\tree + cmake -G "Visual Studio 12 2013" path\to\root\of\doxygen\source\tree (this is for Visual Studio 12, there are typically also generators for other versions of Visual Studio or other compiler environments like MinGW) @@ -31,25 +35,25 @@ Doxygen's cmake configuration provides a number of options: - build_xmlparser Example showing how to parse doxygen's XML output. - build_search Build external search tools (doxysearch and doxyindexer). - build_doc Build user manual. -- use_sqlite3 Add support for sqlite3 output [experimental]. - use_libclang Add support for libclang parsing. +- use_sys_spdlog Use system spdlog library instead of the one bundled. +- use_sys_sqlite3 Use system sqlite3 library instead of the one bundled. - win_static Link with /MT in stead of /MD on windows. -- english_only Only compile in support for the English language. -- force_qt4 Forces doxywizard to build using Qt4 even if Qt5 is installed +- force_qt= Forces doxywizard to build using the specified major version, this can be Qt5 or Qt6 An option can be turned on, by adding -D