From 21791cc23f69321598c3fca680600b73c29be8e0 Mon Sep 17 00:00:00 2001 From: Abhinav Anil Sharma Date: Tue, 28 Nov 2023 22:37:31 -0500 Subject: [PATCH 1/7] i#6417 x86-32 flakiness: debug client.flush --- .github/workflows/ci-aarch64-native.yml | 103 ---- .github/workflows/ci-aarchxx.yml | 308 ----------- .github/workflows/ci-clang-format.yml | 112 ---- .github/workflows/ci-docs.yml | 155 ------ .github/workflows/ci-osx.yml | 111 ---- .github/workflows/ci-package.yml | 660 ------------------------ .github/workflows/ci-riscv64.yml | 123 ----- .github/workflows/ci-windows.yml | 253 --------- .github/workflows/ci-x86.yml | 201 +------- suite/runsuite.cmake | 1 + suite/tests/CMakeLists.txt | 1 + 11 files changed, 6 insertions(+), 2022 deletions(-) delete mode 100644 .github/workflows/ci-aarch64-native.yml delete mode 100644 .github/workflows/ci-aarchxx.yml delete mode 100644 .github/workflows/ci-clang-format.yml delete mode 100644 .github/workflows/ci-docs.yml delete mode 100644 .github/workflows/ci-osx.yml delete mode 100644 .github/workflows/ci-package.yml delete mode 100644 .github/workflows/ci-riscv64.yml delete mode 100644 .github/workflows/ci-windows.yml diff --git a/.github/workflows/ci-aarch64-native.yml b/.github/workflows/ci-aarch64-native.yml deleted file mode 100644 index 23d8913dc59..00000000000 --- a/.github/workflows/ci-aarch64-native.yml +++ /dev/null @@ -1,103 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# Copyright (c) 2023 Arm Limited All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for aarch64 Continuous Integration testing. - -name: ci-aarch64-native - -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - workflow_dispatch: - -jobs: - aarch64-native: - runs-on: [self-hosted, linux, ARM64] - steps: - - name: Check out repository code - uses: actions/checkout@v3 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - name: Cancel previous runs - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - # We also need origin/master for pre-commit source file checks in runsuite.cmake. - # But fetching multiple branches isn't supported yet: actions/checkout#214 - # Pending PR that adds this support actions/checkout#155 - # TODO i#4549: When necessary support is available, remove/replace the - # workaround here and from every job in other Github Actions CI workflows. - - name: Fetch master - run: git fetch --no-tags --depth=1 origin master - - - name: Create build directory - run: mkdir build - - - name: Run Suite - working-directory: build - run: ../suite/runsuite_wrapper.pl travis - env: - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-32 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-aarchxx.yml b/.github/workflows/ci-aarchxx.yml deleted file mode 100644 index 49bd04c479b..00000000000 --- a/.github/workflows/ci-aarchxx.yml +++ /dev/null @@ -1,308 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for AArchXX Continuous Integration testing. - -name: ci-aarchxx -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # AArch64 cross-compile with gcc, with some tests run under QEMU. - # We use a more recent Ubuntu for a more recent QEMU. - aarch64-cross-compile: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu \ - qemu-user qemu-user-binfmt - sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ - zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ - liblz4-1:arm64 liblz4-dev:arm64 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ - sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/aarchxx-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # ARM cross-compile with gcc, with some tests run under QEMU. - # We use a more recent Ubuntu for a more recent QEMU. - arm-cross-compile: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf \ - qemu-user qemu-user-binfmt - sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ - zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ - liblz4-1:armhf liblz4-dev:armhf - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ - sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/aarchxx-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # Android ARM cross-compile with gcc, no tests: - android-arm-cross-compile: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Fetch and install Android NDK for Andoid cross-compile build. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake - cd /tmp - wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip - unzip -q android-ndk-r10e-linux-x86_64.zip - export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e - android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ - --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ - --install-dir=/tmp/android-gcc-arm-ndk-10e - # Manually force using ld.bfd, setting CMAKE_LINKER does not work. - ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld - ln -sf arm-linux-androideabi-ld.bfd \ - /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld - - - name: Run Suite - working-directory: ${{ github.workspace }} - env: - DYNAMORIO_CROSS_ANDROID_ONLY: yes - DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - run: ./suite/runsuite_wrapper.pl automated_ci - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/android-arm-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # AArch64 drdecode and drmemtrace on x86: - a64-on-x86: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ - liblz4-dev - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci - env: - DYNAMORIO_A64_ON_X86_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/a64-on-x86 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-clang-format.yml b/.github/workflows/ci-clang-format.yml deleted file mode 100644 index 541564270b3..00000000000 --- a/.github/workflows/ci-clang-format.yml +++ /dev/null @@ -1,112 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for clang-format Continuous Integration testing. - -name: ci-clang-format -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # 64-bit Linux build with clang, no tests (runsuite.cmake disables the tests), - # install and require clang-format. - # We used to build 32-bit with clang but have decided that is not worth - # the CI resources: 64-bit hits most clang-only warnings and 64-bit - # is the primary target these days. - clang-format: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - - name: Create Build Environment - run: | - wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - - sudo add-apt-repository 'deb http://apt.llvm.org/focal/ llvm-toolchain-focal-14 main' - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev clang-format-14 libunwind-dev - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only require_format - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - DYNAMORIO_CLANG: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/clang-format - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml deleted file mode 100644 index 87d04fcd549..00000000000 --- a/.github/workflows/ci-docs.yml +++ /dev/null @@ -1,155 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for building doxygen docs for the web site. - -name: ci-docs -on: - # Built weekly: 10pm EST Fridays. A re-build even with no content - # changes updates timestamps on every page, increasing the repo size. - # We thus use manual builds for rare docs changes we want to deploy to - # the website and have automated builds match our weekly package builds. - schedule: - - cron: '0 3 * * FRI' - # Manual trigger using the Actions page. - workflow_dispatch: - inputs: - version: - description: 'Version number for docs (blank for cronbuild)' - required: false - default: '' - build: - description: 'Build number for docs' - required: true - default: '0' - -defaults: - run: - shell: bash - -jobs: - ########################################################################### - # Docs deployment, building on Linux. - docs: - # We use a more recent Ubuntu for better markdown support. - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - # We do shallow clones and assume DrM will update its DR at least once - # every 250 DR commits. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install needed packages. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ - liblz4-dev libunwind-dev - - - name: Get Version - id: version - # XXX: For now we duplicate this version number here with CMakeLists.txt. - # We should find a way to share (xref i#1565). - # We support setting the version and build for manual builds. - # We only use a non-zero build # when making multiple manual builds in one day. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Docs - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DEPLOY_DOCS: yes - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Check Out Web - uses: actions/checkout@v2 - with: - repository: DynamoRIO/dynamorio.github.io - token: ${{ secrets.DOCS_TOKEN }} - path: dynamorio.github.io - - - name: Deploy Embedded Docs - run: | - rsync -av --delete html_embed/ dynamorio.github.io/docs/ - cd dynamorio.github.io - git config --local user.name "cronbuild" - git config --local user.email "dynamorio-devs@googlegroups.com" - git add -A - git commit -m "Snapshot for cronbuild-${{ steps.version.outputs.version_number }}" - git push - env: - # We need a personal access token for write access to another repo. - GITHUB_TOKEN: ${{ secrets.DOCS_TOKEN }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/docs - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs diff --git a/.github/workflows/ci-osx.yml b/.github/workflows/ci-osx.yml deleted file mode 100644 index 0bf789ee7df..00000000000 --- a/.github/workflows/ci-osx.yml +++ /dev/null @@ -1,111 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for Mac OSX Continuous Integration testing. - -name: ci-osx -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # 64-bit OSX build with clang and run tests: - osx-x86-64: - runs-on: macos-11 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - - name: Create Build Environment - # XXX: We should install doxygen too but it's a different version and - # hits issues about incompatible options in the Doxyfile. - run: | - brew install nasm zlib snappy lz4 - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - # Change xcode version for current session: - # https://www.unix.com/man-page/osx/1/xcode-select/ - # https://github.community/t/selecting-an-xcode-version/16204/3 - # To find available versions, add the following as a step above: - # - run: ls -l /Applications - DEVELOPER_DIR: /Applications/Xcode_13.2.1.app/Contents/Developer - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/osx-x86-64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-package.yml b/.github/workflows/ci-package.yml deleted file mode 100644 index e93f9018675..00000000000 --- a/.github/workflows/ci-package.yml +++ /dev/null @@ -1,660 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for release packages. - -name: ci-package -on: - # Our weekly cronbuild: 9pm EST on Fridays. - schedule: - - cron: '0 2 * * SAT' - # Manual trigger using the Actions page. - workflow_dispatch: - inputs: - version: - description: 'Package version number (blank for cronbuild)' - required: false - default: '' - build: - description: 'Package build number' - required: true - default: '0' - -defaults: - run: - shell: bash - -jobs: - ########################################################################### - # Linux x86 tarball with 64-bit and 32-bit builds: - linux-x86: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - # We do shallow clones and assume DrM will update its DR at least once - # every 250 DR commits. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install multilib for non-cross-compiling Linux build. - # GA CI uses packages.microsoft.com which is missing i386 packages, and - # attempts at using apt with us.archive-ubuntu.com hit dep issues: - # so we manually install the i386 packages we need. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' - apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Get Version - id: version - # XXX: For now we duplicate this version number here with CMakeLists.txt. - # We should find a way to share (xref i#1565). - # We support setting the version and build for manual builds. - # We only use a non-zero build # when making multiple manual builds in one day. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - # We do not update the web documentation here because a newer - # Doxygen is needed but we have not yet tested our tests and - # packages built on newer Ubuntu on GA CI. - DEPLOY_DOCS: no - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload Artifacts - uses: actions/upload-artifact@v2 - with: - name: linux-tarball - path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/linux-x86 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Linux AArch64 tarball: - linux-aarch64: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu - sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ - zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ - liblz4-1:arm64 liblz4-dev:arm64 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ - sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload AArch64 - uses: actions/upload-artifact@v2 - with: - name: aarch64-tarball - path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/linux-aarch64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Linux ARM tarball (package.cmake does not support same job as AArch64): - linux-arm: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf - sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ - zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ - liblz4-1:armhf liblz4-dev:armhf - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ - sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload ARM - uses: actions/upload-artifact@v2 - with: - name: arm-tarball - path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/linux-arm - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Android ARM tarball: - android-arm: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Fetch and install Android NDK for Andoid cross-compile build. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake - cd /tmp - wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip - unzip -q android-ndk-r10e-linux-x86_64.zip - export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e - android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ - --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ - --install-dir=/tmp/android-gcc-arm-ndk-10e - # Manually force using ld.bfd, setting CMAKE_LINKER does not work. - ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld - ln -sf arm-linux-androideabi-ld.bfd \ - /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - DYNAMORIO_CROSS_ANDROID_ONLY: yes - DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload Artifacts - uses: actions/upload-artifact@v2 - with: - name: android-tarball - path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/android-arm - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Windows .zip with 32-bit and 64-bit x86 builds: - windows: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - shell: cmd - # We need to set up WiX for Dr. Memory. - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - dir "c:\Program Files (x86)\WiX Toolset"* - set PATH=C:\Program Files (x86)\WiX Toolset v3.11\bin;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload Artifacts - uses: actions/upload-artifact@v2 - with: - name: windows-zip - path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/windows - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Create release and populate with files. - # We can't have each OS job create the release because only the first - # succeeds and the others fail: there is no check in the create-release - # action to use an existing release if it already exists. - # Thus, our strategy is to share files from the build jobs with this - # single release job via artifacts. - - create_release: - needs: [linux-x86, linux-aarch64, linux-arm, android-arm, windows] - runs-on: ubuntu-20.04 - - steps: - # We need a checkout to run git log for the version. - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER="10.0.$((`git log -n 1 --format=%ct` / (60*60*24)))" - export PREFIX="cronbuild-" - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - export PREFIX="release_" - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - echo "::set-output name=version_string::${PREFIX}${VERSION_NUMBER}" - - - name: Create Release - id: create_release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - tag_name: ${{ steps.version.outputs.version_string }} - release_name: ${{ steps.version.outputs.version_string }} - body: | - Auto-generated periodic build. - draft: false - prerelease: false - - - name: Download Linux - uses: actions/download-artifact@v2 - with: - name: linux-tarball - - name: Upload Linux - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download AArch64 - uses: actions/download-artifact@v2 - with: - name: aarch64-tarball - - name: Upload AArch64 - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download ARM - uses: actions/download-artifact@v2 - with: - name: arm-tarball - - name: Upload ARM - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download Android - uses: actions/download-artifact@v2 - with: - name: android-tarball - - name: Upload Android - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download Windows - uses: actions/download-artifact@v2 - with: - name: windows-zip - - name: Upload Windows - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip - asset_name: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip - asset_content_type: application/zip - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/create_release - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs diff --git a/.github/workflows/ci-riscv64.yml b/.github/workflows/ci-riscv64.yml deleted file mode 100644 index 1029e14986d..00000000000 --- a/.github/workflows/ci-riscv64.yml +++ /dev/null @@ -1,123 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for RISCV64 Continuous Integration testing. - -name: ci-riscv64 -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # RISCV64 cross-compile with gcc - # We use ubuntu 22.04 because the compilition here need python (3.10.x) - riscv64-cross-compile: - runs-on: ubuntu-22.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - # Unfortunately, only kinetic (ubuntu 22.10) has linunwind-riscv64 packages. - # I prefer debian-ports here, it is more close to upstream. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake crossbuild-essential-riscv64 git \ - qemu-user qemu-user-binfmt - sudo add-apt-repository 'deb [trusted=yes arch=riscv64] http://deb.debian.org/debian sid main' - apt download libunwind8:riscv64 libunwind-dev:riscv64 liblzma5:riscv64 \ - zlib1g:riscv64 zlib1g-dev:riscv64 libsnappy1v5:riscv64 libsnappy-dev:riscv64 \ - liblz4-1:riscv64 liblz4-dev:riscv64 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/riscv64-linux-gnu/include/ - if test -e "../extract/lib/riscv64-linux-gnu/"; then \ - sudo rsync -av ../extract/lib/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/lib/; \ - fi - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_RISCV64_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - QEMU_LD_PREFIX: /usr/riscv64-linux-gnu/ - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/aarchxx-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-windows.yml b/.github/workflows/ci-windows.yml deleted file mode 100644 index d630e68bc61..00000000000 --- a/.github/workflows/ci-windows.yml +++ /dev/null @@ -1,253 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for Windows Continuous Integration testing. - -# TODO i#2145: point at Qt5 for testing drgui build. - -name: ci-windows -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: cmd - -jobs: - ########################################################################### - # 32-bit VS2019 and tests: - vs2019-32: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - name: Fetch Sources - run: git fetch --no-tags --depth=1 origin master - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja 32_only debug_only - env: - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/vs2019-32 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - ########################################################################### - # 64-bit VS2019 and tests: - vs2019-64: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - name: Fetch Sources - run: git fetch --no-tags --depth=1 origin master - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja 64_only debug_only - env: - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/vs2019-64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - ########################################################################### - # 32-bit and 64-bit VS2019 release builds: - vs2019-builds: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - name: Fetch Sources - run: git fetch --no-tags --depth=1 origin master - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja nontest_only - env: - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/vs2019-builds - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-x86.yml b/.github/workflows/ci-x86.yml index e7e81b1de4c..b4b8b13535d 100644 --- a/.github/workflows/ci-x86.yml +++ b/.github/workflows/ci-x86.yml @@ -111,67 +111,9 @@ jobs: CI_TRIGGER: ${{ github.event_name }} CI_BRANCH: ${{ github.ref }} - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-32 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # 64-bit Linux build with gcc and run tests. - x86-64: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install multilib for non-cross-compiling Linux build. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} + - name: Setup tmate session + if: ${{ failure() }} + uses: mxschmitt/action-tmate@v3 - name: Send failure mail to dynamorio-devs if: failure() && github.ref == 'refs/heads/master' @@ -186,142 +128,7 @@ jobs: on ${{github.event_name}} at ${{github.ref}} body: | Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # Ubuntu22 64-bit Linux build with gcc and run tests. - # XXX: A matrix could combine this with the 20.04 but our auto-cancel - # step cancels the 2nd job so we need to solve that first. - x86-64-ubuntu22: - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install multilib for non-cross-compiling Linux build. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-64-ubuntu22 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # Ubuntu22 64-bit Linux build with gcc and run tests. - # XXX: A matrix could combine this with the 20.04 but our auto-cancel - # step cancels the 2nd job so we need to solve that first. - x86-32-ubuntu22: - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install multilib for non-cross-compiling Linux build. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' - apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ - echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-32-ubuntu22 + Workflow: ${{github.workflow}}/x86-32 Repository: ${{github.repository}} Branch ref: ${{github.ref}} SHA: ${{github.sha}} diff --git a/suite/runsuite.cmake b/suite/runsuite.cmake index 56e12a8aaa2..2af38db31de 100644 --- a/suite/runsuite.cmake +++ b/suite/runsuite.cmake @@ -93,6 +93,7 @@ if (UNIX AND NOT APPLE AND NOT ANDROID AND NOT cross_riscv64_linux_only) set(arg_debug_only ON) endif () endif () +set(extra_ctest_args INCLUDE_LABEL TMATE_DEBUG)#NOCHECK set(build_tests "BUILD_TESTS:BOOL=ON") diff --git a/suite/tests/CMakeLists.txt b/suite/tests/CMakeLists.txt index 9d63cb47626..ff7b6ed25d4 100644 --- a/suite/tests/CMakeLists.txt +++ b/suite/tests/CMakeLists.txt @@ -5895,3 +5895,4 @@ if (RISCV64) PROPERTIES LABELS RUNS_ON_QEMU) endif () endif () +set_tests_properties(code_api|client.flush PROPERTIES LABELS TMATE_DEBUG)#NOCHECK From 7c449a25d81e2a59e47ff614b79b9f588720abc6 Mon Sep 17 00:00:00 2001 From: Abhinav Anil Sharma Date: Wed, 13 Dec 2023 13:14:14 -0500 Subject: [PATCH 2/7] Use dr_fragment_app_pc with increment/decrement --- suite/tests/client-interface/flush.dll.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/suite/tests/client-interface/flush.dll.c b/suite/tests/client-interface/flush.dll.c index abe4b9a6e0f..e5abcafc6b0 100644 --- a/suite/tests/client-interface/flush.dll.c +++ b/suite/tests/client-interface/flush.dll.c @@ -1,5 +1,5 @@ /* ********************************************************** - * Copyright (c) 2011-2021 Google, Inc. All rights reserved. + * Copyright (c) 2011-2023 Google, Inc. All rights reserved. * Copyright (c) 2007-2010 VMware, Inc. All rights reserved. * **********************************************************/ @@ -79,7 +79,7 @@ find(void *tag) } static void -increment(void *tag) +increment(app_pc tag) { elem_t *elem; @@ -106,7 +106,7 @@ increment(void *tag) } static void -decrement(void *tag) +decrement(app_pc tag) { elem_t *elem; @@ -161,14 +161,14 @@ static dr_emit_flags_t trace_event(void *drcontext, void *tag, instrlist_t *trace, bool translating) { if (!translating) - increment(tag); + increment(dr_fragment_app_pc(tag)); return DR_EMIT_DEFAULT; } static void deleted_event(void *dcontext, void *tag) { - decrement(tag); + decrement(dr_fragment_app_pc(tag)); } void @@ -246,7 +246,7 @@ bb_event(void *drcontext, void *tag, instrlist_t *bb, bool for_trace, bool trans { instr_t *instr; if (!translating) - increment(tag); + increment(dr_fragment_app_pc(tag)); /* I'm looking for a specific BB in the test .exe. I've marked * it with a couple nops. From 2f304ad06d68596fe802858a9bad9cad369b9723 Mon Sep 17 00:00:00 2001 From: Abhinav Anil Sharma Date: Wed, 13 Dec 2023 13:15:25 -0500 Subject: [PATCH 3/7] Revert "i#6417 x86-32 flakiness: debug client.flush" This reverts commit 21791cc23f69321598c3fca680600b73c29be8e0. --- .github/workflows/ci-aarch64-native.yml | 103 ++++ .github/workflows/ci-aarchxx.yml | 308 +++++++++++ .github/workflows/ci-clang-format.yml | 112 ++++ .github/workflows/ci-docs.yml | 155 ++++++ .github/workflows/ci-osx.yml | 111 ++++ .github/workflows/ci-package.yml | 660 ++++++++++++++++++++++++ .github/workflows/ci-riscv64.yml | 123 +++++ .github/workflows/ci-windows.yml | 253 +++++++++ .github/workflows/ci-x86.yml | 201 +++++++- suite/runsuite.cmake | 1 - suite/tests/CMakeLists.txt | 1 - 11 files changed, 2022 insertions(+), 6 deletions(-) create mode 100644 .github/workflows/ci-aarch64-native.yml create mode 100644 .github/workflows/ci-aarchxx.yml create mode 100644 .github/workflows/ci-clang-format.yml create mode 100644 .github/workflows/ci-docs.yml create mode 100644 .github/workflows/ci-osx.yml create mode 100644 .github/workflows/ci-package.yml create mode 100644 .github/workflows/ci-riscv64.yml create mode 100644 .github/workflows/ci-windows.yml diff --git a/.github/workflows/ci-aarch64-native.yml b/.github/workflows/ci-aarch64-native.yml new file mode 100644 index 00000000000..23d8913dc59 --- /dev/null +++ b/.github/workflows/ci-aarch64-native.yml @@ -0,0 +1,103 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# Copyright (c) 2023 Arm Limited All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for aarch64 Continuous Integration testing. + +name: ci-aarch64-native + +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + workflow_dispatch: + +jobs: + aarch64-native: + runs-on: [self-hosted, linux, ARM64] + steps: + - name: Check out repository code + uses: actions/checkout@v3 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - name: Cancel previous runs + uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + # We also need origin/master for pre-commit source file checks in runsuite.cmake. + # But fetching multiple branches isn't supported yet: actions/checkout#214 + # Pending PR that adds this support actions/checkout#155 + # TODO i#4549: When necessary support is available, remove/replace the + # workaround here and from every job in other Github Actions CI workflows. + - name: Fetch master + run: git fetch --no-tags --depth=1 origin master + + - name: Create build directory + run: mkdir build + + - name: Run Suite + working-directory: build + run: ../suite/runsuite_wrapper.pl travis + env: + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-32 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-aarchxx.yml b/.github/workflows/ci-aarchxx.yml new file mode 100644 index 00000000000..49bd04c479b --- /dev/null +++ b/.github/workflows/ci-aarchxx.yml @@ -0,0 +1,308 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for AArchXX Continuous Integration testing. + +name: ci-aarchxx +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # AArch64 cross-compile with gcc, with some tests run under QEMU. + # We use a more recent Ubuntu for a more recent QEMU. + aarch64-cross-compile: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu \ + qemu-user qemu-user-binfmt + sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ + zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ + liblz4-1:arm64 liblz4-dev:arm64 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ + sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/aarchxx-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # ARM cross-compile with gcc, with some tests run under QEMU. + # We use a more recent Ubuntu for a more recent QEMU. + arm-cross-compile: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf \ + qemu-user qemu-user-binfmt + sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ + zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ + liblz4-1:armhf liblz4-dev:armhf + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ + sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/aarchxx-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # Android ARM cross-compile with gcc, no tests: + android-arm-cross-compile: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Fetch and install Android NDK for Andoid cross-compile build. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake + cd /tmp + wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip + unzip -q android-ndk-r10e-linux-x86_64.zip + export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e + android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ + --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ + --install-dir=/tmp/android-gcc-arm-ndk-10e + # Manually force using ld.bfd, setting CMAKE_LINKER does not work. + ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld + ln -sf arm-linux-androideabi-ld.bfd \ + /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld + + - name: Run Suite + working-directory: ${{ github.workspace }} + env: + DYNAMORIO_CROSS_ANDROID_ONLY: yes + DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + run: ./suite/runsuite_wrapper.pl automated_ci + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/android-arm-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # AArch64 drdecode and drmemtrace on x86: + a64-on-x86: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ + liblz4-dev + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci + env: + DYNAMORIO_A64_ON_X86_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/a64-on-x86 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-clang-format.yml b/.github/workflows/ci-clang-format.yml new file mode 100644 index 00000000000..541564270b3 --- /dev/null +++ b/.github/workflows/ci-clang-format.yml @@ -0,0 +1,112 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for clang-format Continuous Integration testing. + +name: ci-clang-format +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # 64-bit Linux build with clang, no tests (runsuite.cmake disables the tests), + # install and require clang-format. + # We used to build 32-bit with clang but have decided that is not worth + # the CI resources: 64-bit hits most clang-only warnings and 64-bit + # is the primary target these days. + clang-format: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + - name: Create Build Environment + run: | + wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - + sudo add-apt-repository 'deb http://apt.llvm.org/focal/ llvm-toolchain-focal-14 main' + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev clang-format-14 libunwind-dev + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only require_format + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + DYNAMORIO_CLANG: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/clang-format + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml new file mode 100644 index 00000000000..87d04fcd549 --- /dev/null +++ b/.github/workflows/ci-docs.yml @@ -0,0 +1,155 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for building doxygen docs for the web site. + +name: ci-docs +on: + # Built weekly: 10pm EST Fridays. A re-build even with no content + # changes updates timestamps on every page, increasing the repo size. + # We thus use manual builds for rare docs changes we want to deploy to + # the website and have automated builds match our weekly package builds. + schedule: + - cron: '0 3 * * FRI' + # Manual trigger using the Actions page. + workflow_dispatch: + inputs: + version: + description: 'Version number for docs (blank for cronbuild)' + required: false + default: '' + build: + description: 'Build number for docs' + required: true + default: '0' + +defaults: + run: + shell: bash + +jobs: + ########################################################################### + # Docs deployment, building on Linux. + docs: + # We use a more recent Ubuntu for better markdown support. + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + # We do shallow clones and assume DrM will update its DR at least once + # every 250 DR commits. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install needed packages. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ + liblz4-dev libunwind-dev + + - name: Get Version + id: version + # XXX: For now we duplicate this version number here with CMakeLists.txt. + # We should find a way to share (xref i#1565). + # We support setting the version and build for manual builds. + # We only use a non-zero build # when making multiple manual builds in one day. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Docs + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DEPLOY_DOCS: yes + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Check Out Web + uses: actions/checkout@v2 + with: + repository: DynamoRIO/dynamorio.github.io + token: ${{ secrets.DOCS_TOKEN }} + path: dynamorio.github.io + + - name: Deploy Embedded Docs + run: | + rsync -av --delete html_embed/ dynamorio.github.io/docs/ + cd dynamorio.github.io + git config --local user.name "cronbuild" + git config --local user.email "dynamorio-devs@googlegroups.com" + git add -A + git commit -m "Snapshot for cronbuild-${{ steps.version.outputs.version_number }}" + git push + env: + # We need a personal access token for write access to another repo. + GITHUB_TOKEN: ${{ secrets.DOCS_TOKEN }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/docs + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs diff --git a/.github/workflows/ci-osx.yml b/.github/workflows/ci-osx.yml new file mode 100644 index 00000000000..0bf789ee7df --- /dev/null +++ b/.github/workflows/ci-osx.yml @@ -0,0 +1,111 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for Mac OSX Continuous Integration testing. + +name: ci-osx +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # 64-bit OSX build with clang and run tests: + osx-x86-64: + runs-on: macos-11 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + - name: Create Build Environment + # XXX: We should install doxygen too but it's a different version and + # hits issues about incompatible options in the Doxyfile. + run: | + brew install nasm zlib snappy lz4 + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + # Change xcode version for current session: + # https://www.unix.com/man-page/osx/1/xcode-select/ + # https://github.community/t/selecting-an-xcode-version/16204/3 + # To find available versions, add the following as a step above: + # - run: ls -l /Applications + DEVELOPER_DIR: /Applications/Xcode_13.2.1.app/Contents/Developer + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/osx-x86-64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-package.yml b/.github/workflows/ci-package.yml new file mode 100644 index 00000000000..e93f9018675 --- /dev/null +++ b/.github/workflows/ci-package.yml @@ -0,0 +1,660 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for release packages. + +name: ci-package +on: + # Our weekly cronbuild: 9pm EST on Fridays. + schedule: + - cron: '0 2 * * SAT' + # Manual trigger using the Actions page. + workflow_dispatch: + inputs: + version: + description: 'Package version number (blank for cronbuild)' + required: false + default: '' + build: + description: 'Package build number' + required: true + default: '0' + +defaults: + run: + shell: bash + +jobs: + ########################################################################### + # Linux x86 tarball with 64-bit and 32-bit builds: + linux-x86: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + # We do shallow clones and assume DrM will update its DR at least once + # every 250 DR commits. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install multilib for non-cross-compiling Linux build. + # GA CI uses packages.microsoft.com which is missing i386 packages, and + # attempts at using apt with us.archive-ubuntu.com hit dep issues: + # so we manually install the i386 packages we need. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' + apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Get Version + id: version + # XXX: For now we duplicate this version number here with CMakeLists.txt. + # We should find a way to share (xref i#1565). + # We support setting the version and build for manual builds. + # We only use a non-zero build # when making multiple manual builds in one day. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + # We do not update the web documentation here because a newer + # Doxygen is needed but we have not yet tested our tests and + # packages built on newer Ubuntu on GA CI. + DEPLOY_DOCS: no + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload Artifacts + uses: actions/upload-artifact@v2 + with: + name: linux-tarball + path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/linux-x86 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Linux AArch64 tarball: + linux-aarch64: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu + sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ + zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ + liblz4-1:arm64 liblz4-dev:arm64 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ + sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload AArch64 + uses: actions/upload-artifact@v2 + with: + name: aarch64-tarball + path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/linux-aarch64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Linux ARM tarball (package.cmake does not support same job as AArch64): + linux-arm: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf + sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ + zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ + liblz4-1:armhf liblz4-dev:armhf + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ + sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload ARM + uses: actions/upload-artifact@v2 + with: + name: arm-tarball + path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/linux-arm + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Android ARM tarball: + android-arm: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Fetch and install Android NDK for Andoid cross-compile build. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake + cd /tmp + wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip + unzip -q android-ndk-r10e-linux-x86_64.zip + export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e + android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ + --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ + --install-dir=/tmp/android-gcc-arm-ndk-10e + # Manually force using ld.bfd, setting CMAKE_LINKER does not work. + ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld + ln -sf arm-linux-androideabi-ld.bfd \ + /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + DYNAMORIO_CROSS_ANDROID_ONLY: yes + DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload Artifacts + uses: actions/upload-artifact@v2 + with: + name: android-tarball + path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/android-arm + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Windows .zip with 32-bit and 64-bit x86 builds: + windows: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + shell: cmd + # We need to set up WiX for Dr. Memory. + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + dir "c:\Program Files (x86)\WiX Toolset"* + set PATH=C:\Program Files (x86)\WiX Toolset v3.11\bin;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload Artifacts + uses: actions/upload-artifact@v2 + with: + name: windows-zip + path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/windows + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Create release and populate with files. + # We can't have each OS job create the release because only the first + # succeeds and the others fail: there is no check in the create-release + # action to use an existing release if it already exists. + # Thus, our strategy is to share files from the build jobs with this + # single release job via artifacts. + + create_release: + needs: [linux-x86, linux-aarch64, linux-arm, android-arm, windows] + runs-on: ubuntu-20.04 + + steps: + # We need a checkout to run git log for the version. + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER="10.0.$((`git log -n 1 --format=%ct` / (60*60*24)))" + export PREFIX="cronbuild-" + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + export PREFIX="release_" + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + echo "::set-output name=version_string::${PREFIX}${VERSION_NUMBER}" + + - name: Create Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ steps.version.outputs.version_string }} + release_name: ${{ steps.version.outputs.version_string }} + body: | + Auto-generated periodic build. + draft: false + prerelease: false + + - name: Download Linux + uses: actions/download-artifact@v2 + with: + name: linux-tarball + - name: Upload Linux + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download AArch64 + uses: actions/download-artifact@v2 + with: + name: aarch64-tarball + - name: Upload AArch64 + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download ARM + uses: actions/download-artifact@v2 + with: + name: arm-tarball + - name: Upload ARM + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download Android + uses: actions/download-artifact@v2 + with: + name: android-tarball + - name: Upload Android + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download Windows + uses: actions/download-artifact@v2 + with: + name: windows-zip + - name: Upload Windows + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip + asset_name: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip + asset_content_type: application/zip + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/create_release + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs diff --git a/.github/workflows/ci-riscv64.yml b/.github/workflows/ci-riscv64.yml new file mode 100644 index 00000000000..1029e14986d --- /dev/null +++ b/.github/workflows/ci-riscv64.yml @@ -0,0 +1,123 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for RISCV64 Continuous Integration testing. + +name: ci-riscv64 +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # RISCV64 cross-compile with gcc + # We use ubuntu 22.04 because the compilition here need python (3.10.x) + riscv64-cross-compile: + runs-on: ubuntu-22.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + # Unfortunately, only kinetic (ubuntu 22.10) has linunwind-riscv64 packages. + # I prefer debian-ports here, it is more close to upstream. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake crossbuild-essential-riscv64 git \ + qemu-user qemu-user-binfmt + sudo add-apt-repository 'deb [trusted=yes arch=riscv64] http://deb.debian.org/debian sid main' + apt download libunwind8:riscv64 libunwind-dev:riscv64 liblzma5:riscv64 \ + zlib1g:riscv64 zlib1g-dev:riscv64 libsnappy1v5:riscv64 libsnappy-dev:riscv64 \ + liblz4-1:riscv64 liblz4-dev:riscv64 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/riscv64-linux-gnu/include/ + if test -e "../extract/lib/riscv64-linux-gnu/"; then \ + sudo rsync -av ../extract/lib/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/lib/; \ + fi + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_RISCV64_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + QEMU_LD_PREFIX: /usr/riscv64-linux-gnu/ + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/aarchxx-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-windows.yml b/.github/workflows/ci-windows.yml new file mode 100644 index 00000000000..d630e68bc61 --- /dev/null +++ b/.github/workflows/ci-windows.yml @@ -0,0 +1,253 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for Windows Continuous Integration testing. + +# TODO i#2145: point at Qt5 for testing drgui build. + +name: ci-windows +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: cmd + +jobs: + ########################################################################### + # 32-bit VS2019 and tests: + vs2019-32: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - name: Fetch Sources + run: git fetch --no-tags --depth=1 origin master + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja 32_only debug_only + env: + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/vs2019-32 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + ########################################################################### + # 64-bit VS2019 and tests: + vs2019-64: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - name: Fetch Sources + run: git fetch --no-tags --depth=1 origin master + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja 64_only debug_only + env: + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/vs2019-64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + ########################################################################### + # 32-bit and 64-bit VS2019 release builds: + vs2019-builds: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - name: Fetch Sources + run: git fetch --no-tags --depth=1 origin master + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja nontest_only + env: + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/vs2019-builds + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-x86.yml b/.github/workflows/ci-x86.yml index b4b8b13535d..e7e81b1de4c 100644 --- a/.github/workflows/ci-x86.yml +++ b/.github/workflows/ci-x86.yml @@ -111,10 +111,6 @@ jobs: CI_TRIGGER: ${{ github.event_name }} CI_BRANCH: ${{ github.ref }} - - name: Setup tmate session - if: ${{ failure() }} - uses: mxschmitt/action-tmate@v3 - - name: Send failure mail to dynamorio-devs if: failure() && github.ref == 'refs/heads/master' uses: dawidd6/action-send-mail@v2 @@ -138,3 +134,200 @@ jobs: See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} to: dynamorio-devs@googlegroups.com from: Github Action CI + + # 64-bit Linux build with gcc and run tests. + x86-64: + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install multilib for non-cross-compiling Linux build. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # Ubuntu22 64-bit Linux build with gcc and run tests. + # XXX: A matrix could combine this with the 20.04 but our auto-cancel + # step cancels the 2nd job so we need to solve that first. + x86-64-ubuntu22: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install multilib for non-cross-compiling Linux build. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-64-ubuntu22 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # Ubuntu22 64-bit Linux build with gcc and run tests. + # XXX: A matrix could combine this with the 20.04 but our auto-cancel + # step cancels the 2nd job so we need to solve that first. + x86-32-ubuntu22: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install multilib for non-cross-compiling Linux build. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' + apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ + echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-32-ubuntu22 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/suite/runsuite.cmake b/suite/runsuite.cmake index 2af38db31de..56e12a8aaa2 100644 --- a/suite/runsuite.cmake +++ b/suite/runsuite.cmake @@ -93,7 +93,6 @@ if (UNIX AND NOT APPLE AND NOT ANDROID AND NOT cross_riscv64_linux_only) set(arg_debug_only ON) endif () endif () -set(extra_ctest_args INCLUDE_LABEL TMATE_DEBUG)#NOCHECK set(build_tests "BUILD_TESTS:BOOL=ON") diff --git a/suite/tests/CMakeLists.txt b/suite/tests/CMakeLists.txt index ff7b6ed25d4..9d63cb47626 100644 --- a/suite/tests/CMakeLists.txt +++ b/suite/tests/CMakeLists.txt @@ -5895,4 +5895,3 @@ if (RISCV64) PROPERTIES LABELS RUNS_ON_QEMU) endif () endif () -set_tests_properties(code_api|client.flush PROPERTIES LABELS TMATE_DEBUG)#NOCHECK From 7dd94e146fd693e09b18c18dbb25856a876e4522 Mon Sep 17 00:00:00 2001 From: Abhinav Anil Sharma Date: Wed, 13 Dec 2023 15:37:32 -0500 Subject: [PATCH 4/7] Reapply "i#6417 x86-32 flakiness: debug client.flush" This reverts commit 2f304ad06d68596fe802858a9bad9cad369b9723. --- .github/workflows/ci-aarch64-native.yml | 103 ---- .github/workflows/ci-aarchxx.yml | 308 ----------- .github/workflows/ci-clang-format.yml | 112 ---- .github/workflows/ci-docs.yml | 155 ------ .github/workflows/ci-osx.yml | 111 ---- .github/workflows/ci-package.yml | 660 ------------------------ .github/workflows/ci-riscv64.yml | 123 ----- .github/workflows/ci-windows.yml | 253 --------- .github/workflows/ci-x86.yml | 201 +------- suite/runsuite.cmake | 1 + suite/tests/CMakeLists.txt | 1 + 11 files changed, 6 insertions(+), 2022 deletions(-) delete mode 100644 .github/workflows/ci-aarch64-native.yml delete mode 100644 .github/workflows/ci-aarchxx.yml delete mode 100644 .github/workflows/ci-clang-format.yml delete mode 100644 .github/workflows/ci-docs.yml delete mode 100644 .github/workflows/ci-osx.yml delete mode 100644 .github/workflows/ci-package.yml delete mode 100644 .github/workflows/ci-riscv64.yml delete mode 100644 .github/workflows/ci-windows.yml diff --git a/.github/workflows/ci-aarch64-native.yml b/.github/workflows/ci-aarch64-native.yml deleted file mode 100644 index 23d8913dc59..00000000000 --- a/.github/workflows/ci-aarch64-native.yml +++ /dev/null @@ -1,103 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# Copyright (c) 2023 Arm Limited All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for aarch64 Continuous Integration testing. - -name: ci-aarch64-native - -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - workflow_dispatch: - -jobs: - aarch64-native: - runs-on: [self-hosted, linux, ARM64] - steps: - - name: Check out repository code - uses: actions/checkout@v3 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - name: Cancel previous runs - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - # We also need origin/master for pre-commit source file checks in runsuite.cmake. - # But fetching multiple branches isn't supported yet: actions/checkout#214 - # Pending PR that adds this support actions/checkout#155 - # TODO i#4549: When necessary support is available, remove/replace the - # workaround here and from every job in other Github Actions CI workflows. - - name: Fetch master - run: git fetch --no-tags --depth=1 origin master - - - name: Create build directory - run: mkdir build - - - name: Run Suite - working-directory: build - run: ../suite/runsuite_wrapper.pl travis - env: - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-32 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-aarchxx.yml b/.github/workflows/ci-aarchxx.yml deleted file mode 100644 index 49bd04c479b..00000000000 --- a/.github/workflows/ci-aarchxx.yml +++ /dev/null @@ -1,308 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for AArchXX Continuous Integration testing. - -name: ci-aarchxx -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # AArch64 cross-compile with gcc, with some tests run under QEMU. - # We use a more recent Ubuntu for a more recent QEMU. - aarch64-cross-compile: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu \ - qemu-user qemu-user-binfmt - sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ - zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ - liblz4-1:arm64 liblz4-dev:arm64 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ - sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/aarchxx-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # ARM cross-compile with gcc, with some tests run under QEMU. - # We use a more recent Ubuntu for a more recent QEMU. - arm-cross-compile: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf \ - qemu-user qemu-user-binfmt - sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ - zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ - liblz4-1:armhf liblz4-dev:armhf - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ - sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/aarchxx-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # Android ARM cross-compile with gcc, no tests: - android-arm-cross-compile: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Fetch and install Android NDK for Andoid cross-compile build. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake - cd /tmp - wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip - unzip -q android-ndk-r10e-linux-x86_64.zip - export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e - android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ - --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ - --install-dir=/tmp/android-gcc-arm-ndk-10e - # Manually force using ld.bfd, setting CMAKE_LINKER does not work. - ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld - ln -sf arm-linux-androideabi-ld.bfd \ - /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld - - - name: Run Suite - working-directory: ${{ github.workspace }} - env: - DYNAMORIO_CROSS_ANDROID_ONLY: yes - DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - run: ./suite/runsuite_wrapper.pl automated_ci - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/android-arm-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # AArch64 drdecode and drmemtrace on x86: - a64-on-x86: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ - liblz4-dev - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci - env: - DYNAMORIO_A64_ON_X86_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/a64-on-x86 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-clang-format.yml b/.github/workflows/ci-clang-format.yml deleted file mode 100644 index 541564270b3..00000000000 --- a/.github/workflows/ci-clang-format.yml +++ /dev/null @@ -1,112 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for clang-format Continuous Integration testing. - -name: ci-clang-format -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # 64-bit Linux build with clang, no tests (runsuite.cmake disables the tests), - # install and require clang-format. - # We used to build 32-bit with clang but have decided that is not worth - # the CI resources: 64-bit hits most clang-only warnings and 64-bit - # is the primary target these days. - clang-format: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - - name: Create Build Environment - run: | - wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - - sudo add-apt-repository 'deb http://apt.llvm.org/focal/ llvm-toolchain-focal-14 main' - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev clang-format-14 libunwind-dev - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only require_format - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - DYNAMORIO_CLANG: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/clang-format - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml deleted file mode 100644 index 87d04fcd549..00000000000 --- a/.github/workflows/ci-docs.yml +++ /dev/null @@ -1,155 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for building doxygen docs for the web site. - -name: ci-docs -on: - # Built weekly: 10pm EST Fridays. A re-build even with no content - # changes updates timestamps on every page, increasing the repo size. - # We thus use manual builds for rare docs changes we want to deploy to - # the website and have automated builds match our weekly package builds. - schedule: - - cron: '0 3 * * FRI' - # Manual trigger using the Actions page. - workflow_dispatch: - inputs: - version: - description: 'Version number for docs (blank for cronbuild)' - required: false - default: '' - build: - description: 'Build number for docs' - required: true - default: '0' - -defaults: - run: - shell: bash - -jobs: - ########################################################################### - # Docs deployment, building on Linux. - docs: - # We use a more recent Ubuntu for better markdown support. - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - # We do shallow clones and assume DrM will update its DR at least once - # every 250 DR commits. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install needed packages. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ - liblz4-dev libunwind-dev - - - name: Get Version - id: version - # XXX: For now we duplicate this version number here with CMakeLists.txt. - # We should find a way to share (xref i#1565). - # We support setting the version and build for manual builds. - # We only use a non-zero build # when making multiple manual builds in one day. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Docs - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DEPLOY_DOCS: yes - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Check Out Web - uses: actions/checkout@v2 - with: - repository: DynamoRIO/dynamorio.github.io - token: ${{ secrets.DOCS_TOKEN }} - path: dynamorio.github.io - - - name: Deploy Embedded Docs - run: | - rsync -av --delete html_embed/ dynamorio.github.io/docs/ - cd dynamorio.github.io - git config --local user.name "cronbuild" - git config --local user.email "dynamorio-devs@googlegroups.com" - git add -A - git commit -m "Snapshot for cronbuild-${{ steps.version.outputs.version_number }}" - git push - env: - # We need a personal access token for write access to another repo. - GITHUB_TOKEN: ${{ secrets.DOCS_TOKEN }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/docs - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs diff --git a/.github/workflows/ci-osx.yml b/.github/workflows/ci-osx.yml deleted file mode 100644 index 0bf789ee7df..00000000000 --- a/.github/workflows/ci-osx.yml +++ /dev/null @@ -1,111 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for Mac OSX Continuous Integration testing. - -name: ci-osx -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # 64-bit OSX build with clang and run tests: - osx-x86-64: - runs-on: macos-11 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - - name: Create Build Environment - # XXX: We should install doxygen too but it's a different version and - # hits issues about incompatible options in the Doxyfile. - run: | - brew install nasm zlib snappy lz4 - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - # Change xcode version for current session: - # https://www.unix.com/man-page/osx/1/xcode-select/ - # https://github.community/t/selecting-an-xcode-version/16204/3 - # To find available versions, add the following as a step above: - # - run: ls -l /Applications - DEVELOPER_DIR: /Applications/Xcode_13.2.1.app/Contents/Developer - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/osx-x86-64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-package.yml b/.github/workflows/ci-package.yml deleted file mode 100644 index e93f9018675..00000000000 --- a/.github/workflows/ci-package.yml +++ /dev/null @@ -1,660 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for release packages. - -name: ci-package -on: - # Our weekly cronbuild: 9pm EST on Fridays. - schedule: - - cron: '0 2 * * SAT' - # Manual trigger using the Actions page. - workflow_dispatch: - inputs: - version: - description: 'Package version number (blank for cronbuild)' - required: false - default: '' - build: - description: 'Package build number' - required: true - default: '0' - -defaults: - run: - shell: bash - -jobs: - ########################################################################### - # Linux x86 tarball with 64-bit and 32-bit builds: - linux-x86: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - # We do shallow clones and assume DrM will update its DR at least once - # every 250 DR commits. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install multilib for non-cross-compiling Linux build. - # GA CI uses packages.microsoft.com which is missing i386 packages, and - # attempts at using apt with us.archive-ubuntu.com hit dep issues: - # so we manually install the i386 packages we need. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' - apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Get Version - id: version - # XXX: For now we duplicate this version number here with CMakeLists.txt. - # We should find a way to share (xref i#1565). - # We support setting the version and build for manual builds. - # We only use a non-zero build # when making multiple manual builds in one day. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - # We do not update the web documentation here because a newer - # Doxygen is needed but we have not yet tested our tests and - # packages built on newer Ubuntu on GA CI. - DEPLOY_DOCS: no - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload Artifacts - uses: actions/upload-artifact@v2 - with: - name: linux-tarball - path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/linux-x86 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Linux AArch64 tarball: - linux-aarch64: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu - sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ - zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ - liblz4-1:arm64 liblz4-dev:arm64 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ - sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload AArch64 - uses: actions/upload-artifact@v2 - with: - name: aarch64-tarball - path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/linux-aarch64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Linux ARM tarball (package.cmake does not support same job as AArch64): - linux-arm: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf - sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' - apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ - zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ - liblz4-1:armhf liblz4-dev:armhf - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ - sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload ARM - uses: actions/upload-artifact@v2 - with: - name: arm-tarball - path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/linux-arm - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Android ARM tarball: - android-arm: - runs-on: ubuntu-20.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - # Fetch and install Android NDK for Andoid cross-compile build. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake - cd /tmp - wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip - unzip -q android-ndk-r10e-linux-x86_64.zip - export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e - android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ - --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ - --install-dir=/tmp/android-gcc-arm-ndk-10e - # Manually force using ld.bfd, setting CMAKE_LINKER does not work. - ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld - ln -sf arm-linux-androideabi-ld.bfd \ - /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - DYNAMORIO_CROSS_ANDROID_ONLY: yes - DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload Artifacts - uses: actions/upload-artifact@v2 - with: - name: android-tarball - path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/android-arm - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Windows .zip with 32-bit and 64-bit x86 builds: - windows: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Fetch Sources - run: | - git fetch --no-tags --depth=1 origin master - # Include Dr. Memory in packages. - git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory - cd drmemory && git submodule update --init --recursive --depth 250 && cd .. - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - - - name: Build Package - working-directory: ${{ github.workspace }} - shell: cmd - # We need to set up WiX for Dr. Memory. - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - dir "c:\Program Files (x86)\WiX Toolset"* - set PATH=C:\Program Files (x86)\WiX Toolset v3.11\bin;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja - env: - CI_TARGET: package - VERSION_NUMBER: ${{ steps.version.outputs.version_number }} - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Upload Artifacts - uses: actions/upload-artifact@v2 - with: - name: windows-zip - path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/windows - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs - - ########################################################################### - # Create release and populate with files. - # We can't have each OS job create the release because only the first - # succeeds and the others fail: there is no check in the create-release - # action to use an existing release if it already exists. - # Thus, our strategy is to share files from the build jobs with this - # single release job via artifacts. - - create_release: - needs: [linux-x86, linux-aarch64, linux-arm, android-arm, windows] - runs-on: ubuntu-20.04 - - steps: - # We need a checkout to run git log for the version. - - uses: actions/checkout@v2 - with: - submodules: true - - - name: Get Version - id: version - # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. - run: | - if test -z "${{ github.event.inputs.version }}"; then - export VERSION_NUMBER="10.0.$((`git log -n 1 --format=%ct` / (60*60*24)))" - export PREFIX="cronbuild-" - else - export VERSION_NUMBER=${{ github.event.inputs.version }} - export PREFIX="release_" - fi - if [ "${{ github.event.inputs.build }}" -ne 0 ]; then - export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" - fi - echo "::set-output name=version_number::${VERSION_NUMBER}" - echo "::set-output name=version_string::${PREFIX}${VERSION_NUMBER}" - - - name: Create Release - id: create_release - uses: actions/create-release@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - tag_name: ${{ steps.version.outputs.version_string }} - release_name: ${{ steps.version.outputs.version_string }} - body: | - Auto-generated periodic build. - draft: false - prerelease: false - - - name: Download Linux - uses: actions/download-artifact@v2 - with: - name: linux-tarball - - name: Upload Linux - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download AArch64 - uses: actions/download-artifact@v2 - with: - name: aarch64-tarball - - name: Upload AArch64 - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download ARM - uses: actions/download-artifact@v2 - with: - name: arm-tarball - - name: Upload ARM - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download Android - uses: actions/download-artifact@v2 - with: - name: android-tarball - - name: Upload Android - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz - asset_name: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz - asset_content_type: application/x-gzip - - - name: Download Windows - uses: actions/download-artifact@v2 - with: - name: windows-zip - - name: Upload Windows - uses: actions/upload-release-asset@v1 - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - with: - upload_url: ${{ steps.create_release.outputs.upload_url }} - # This action doesn't seem to support a glob so we need the exact name. - asset_path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip - asset_name: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip - asset_content_type: application/zip - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/create_release - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action package jobs diff --git a/.github/workflows/ci-riscv64.yml b/.github/workflows/ci-riscv64.yml deleted file mode 100644 index 1029e14986d..00000000000 --- a/.github/workflows/ci-riscv64.yml +++ /dev/null @@ -1,123 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for RISCV64 Continuous Integration testing. - -name: ci-riscv64 -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: bash - -jobs: - # RISCV64 cross-compile with gcc - # We use ubuntu 22.04 because the compilition here need python (3.10.x) - riscv64-cross-compile: - runs-on: ubuntu-22.04 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install cross-compiler for cross-compiling Linux build. - # Unfortunately there are no libunwind or compression cross-compile - # packages so we unpack the native versions and copy their files. - # Unfortunately, only kinetic (ubuntu 22.10) has linunwind-riscv64 packages. - # I prefer debian-ports here, it is more close to upstream. - - name: Create Build Environment - run: | - sudo apt-get update - sudo apt-get -y install doxygen vera++ cmake crossbuild-essential-riscv64 git \ - qemu-user qemu-user-binfmt - sudo add-apt-repository 'deb [trusted=yes arch=riscv64] http://deb.debian.org/debian sid main' - apt download libunwind8:riscv64 libunwind-dev:riscv64 liblzma5:riscv64 \ - zlib1g:riscv64 zlib1g-dev:riscv64 libsnappy1v5:riscv64 libsnappy-dev:riscv64 \ - liblz4-1:riscv64 liblz4-dev:riscv64 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - for i in include lib; do sudo rsync -av ../extract/usr/${i}/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/${i}/; done - sudo rsync -av ../extract/usr/include/ /usr/riscv64-linux-gnu/include/ - if test -e "../extract/lib/riscv64-linux-gnu/"; then \ - sudo rsync -av ../extract/lib/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/lib/; \ - fi - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_RISCV64_LINUX_ONLY: yes - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - QEMU_LD_PREFIX: /usr/riscv64-linux-gnu/ - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/aarchxx-cross-compile - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-windows.yml b/.github/workflows/ci-windows.yml deleted file mode 100644 index d630e68bc61..00000000000 --- a/.github/workflows/ci-windows.yml +++ /dev/null @@ -1,253 +0,0 @@ -# ********************************************************** -# Copyright (c) 2020-2023 Google, Inc. All rights reserved. -# ********************************************************** - -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions are met: -# -# * Redistributions of source code must retain the above copyright notice, -# this list of conditions and the following disclaimer. -# -# * Redistributions in binary form must reproduce the above copyright notice, -# this list of conditions and the following disclaimer in the documentation -# and/or other materials provided with the distribution. -# -# * Neither the name of Google, Inc. nor the names of its contributors may be -# used to endorse or promote products derived from this software without -# specific prior written permission. -# -# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -# DAMAGE. - -# Github Actions workflow for Windows Continuous Integration testing. - -# TODO i#2145: point at Qt5 for testing drgui build. - -name: ci-windows -on: - # Run on pushes to master and on pull request changes, including from a - # forked repo with no "push" trigger, while avoiding duplicate triggers. - push: - branches: - - master - pull_request: - types: [opened, reopened, synchronize] - merge_group: - - # Manual trigger using the Actions page. May remove when integration complete. - workflow_dispatch: - -defaults: - run: - shell: cmd - -jobs: - ########################################################################### - # 32-bit VS2019 and tests: - vs2019-32: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - name: Fetch Sources - run: git fetch --no-tags --depth=1 origin master - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja 32_only debug_only - env: - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/vs2019-32 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - ########################################################################### - # 64-bit VS2019 and tests: - vs2019-64: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - name: Fetch Sources - run: git fetch --no-tags --depth=1 origin master - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja 64_only debug_only - env: - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/vs2019-64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - ########################################################################### - # 32-bit and 64-bit VS2019 release builds: - vs2019-builds: - runs-on: windows-2019 - - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - name: Fetch Sources - run: git fetch --no-tags --depth=1 origin master - - - name: Download Packages - shell: powershell - run: | - md c:\projects\install - (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") - (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: | - echo ------ Setting up paths ------ - 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul - set PATH=c:\projects\install\ninja;%PATH% - 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul - set PATH=c:\projects\install\doxygen;%PATH% - call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" - echo ------ Running suite ------ - echo PATH is "%PATH%" - echo Running in directory "%CD%" - perl suite/runsuite_wrapper.pl automated_ci use_ninja nontest_only - env: - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/vs2019-builds - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI diff --git a/.github/workflows/ci-x86.yml b/.github/workflows/ci-x86.yml index e7e81b1de4c..b4b8b13535d 100644 --- a/.github/workflows/ci-x86.yml +++ b/.github/workflows/ci-x86.yml @@ -111,67 +111,9 @@ jobs: CI_TRIGGER: ${{ github.event_name }} CI_BRANCH: ${{ github.ref }} - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-32 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # 64-bit Linux build with gcc and run tests. - x86-64: - runs-on: ubuntu-20.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install multilib for non-cross-compiling Linux build. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} + - name: Setup tmate session + if: ${{ failure() }} + uses: mxschmitt/action-tmate@v3 - name: Send failure mail to dynamorio-devs if: failure() && github.ref == 'refs/heads/master' @@ -186,142 +128,7 @@ jobs: on ${{github.event_name}} at ${{github.ref}} body: | Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-64 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # Ubuntu22 64-bit Linux build with gcc and run tests. - # XXX: A matrix could combine this with the 20.04 but our auto-cancel - # step cancels the 2nd job so we need to solve that first. - x86-64-ubuntu22: - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install multilib for non-cross-compiling Linux build. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 64_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-64-ubuntu22 - Repository: ${{github.repository}} - Branch ref: ${{github.ref}} - SHA: ${{github.sha}} - Triggering actor: ${{github.actor}} - Triggering event: ${{github.event_name}} - Run Id: ${{github.run_id}} - See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} - to: dynamorio-devs@googlegroups.com - from: Github Action CI - - # Ubuntu22 64-bit Linux build with gcc and run tests. - # XXX: A matrix could combine this with the 20.04 but our auto-cancel - # step cancels the 2nd job so we need to solve that first. - x86-32-ubuntu22: - runs-on: ubuntu-22.04 - steps: - - uses: actions/checkout@v2 - with: - submodules: true - - # Cancel any prior runs for a PR (but do not cancel master branch runs). - - uses: n1hility/cancel-previous-runs@v2 - with: - token: ${{ secrets.GITHUB_TOKEN }} - if: ${{ github.event_name == 'pull_request' }} - - - run: git fetch --no-tags --depth=1 origin master - - # Install multilib for non-cross-compiling Linux build. - - name: Create Build Environment - run: | - sudo apt update - sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ - liblz4-dev g++-multilib libunwind-dev - sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' - apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 - mkdir ../extract - for i in *.deb; do dpkg-deb -x $i ../extract; done - sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ - sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ - echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope - - # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). - - name: Setup newer cmake - uses: jwlawson/actions-setup-cmake@v1.8 - with: - cmake-version: '3.19.7' - - - name: Run Suite - working-directory: ${{ github.workspace }} - run: ./suite/runsuite_wrapper.pl automated_ci 32_only - env: - DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no - CI_TRIGGER: ${{ github.event_name }} - CI_BRANCH: ${{ github.ref }} - - - name: Send failure mail to dynamorio-devs - if: failure() && github.ref == 'refs/heads/master' - uses: dawidd6/action-send-mail@v2 - with: - server_address: smtp.gmail.com - server_port: 465 - username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} - password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} - subject: | - [${{github.repository}}] ${{github.workflow}} FAILED - on ${{github.event_name}} at ${{github.ref}} - body: | - Github Actions CI workflow run FAILED! - Workflow: ${{github.workflow}}/x86-32-ubuntu22 + Workflow: ${{github.workflow}}/x86-32 Repository: ${{github.repository}} Branch ref: ${{github.ref}} SHA: ${{github.sha}} diff --git a/suite/runsuite.cmake b/suite/runsuite.cmake index 56e12a8aaa2..2af38db31de 100644 --- a/suite/runsuite.cmake +++ b/suite/runsuite.cmake @@ -93,6 +93,7 @@ if (UNIX AND NOT APPLE AND NOT ANDROID AND NOT cross_riscv64_linux_only) set(arg_debug_only ON) endif () endif () +set(extra_ctest_args INCLUDE_LABEL TMATE_DEBUG)#NOCHECK set(build_tests "BUILD_TESTS:BOOL=ON") diff --git a/suite/tests/CMakeLists.txt b/suite/tests/CMakeLists.txt index 9d63cb47626..ff7b6ed25d4 100644 --- a/suite/tests/CMakeLists.txt +++ b/suite/tests/CMakeLists.txt @@ -5895,3 +5895,4 @@ if (RISCV64) PROPERTIES LABELS RUNS_ON_QEMU) endif () endif () +set_tests_properties(code_api|client.flush PROPERTIES LABELS TMATE_DEBUG)#NOCHECK From 3a68ba3a1737aa35eba42f02f8bff4811a385778 Mon Sep 17 00:00:00 2001 From: Abhinav Anil Sharma Date: Wed, 13 Dec 2023 15:38:00 -0500 Subject: [PATCH 5/7] Revert "Use dr_fragment_app_pc with increment/decrement" This reverts commit 7c449a25d81e2a59e47ff614b79b9f588720abc6. --- suite/tests/client-interface/flush.dll.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/suite/tests/client-interface/flush.dll.c b/suite/tests/client-interface/flush.dll.c index e5abcafc6b0..abe4b9a6e0f 100644 --- a/suite/tests/client-interface/flush.dll.c +++ b/suite/tests/client-interface/flush.dll.c @@ -1,5 +1,5 @@ /* ********************************************************** - * Copyright (c) 2011-2023 Google, Inc. All rights reserved. + * Copyright (c) 2011-2021 Google, Inc. All rights reserved. * Copyright (c) 2007-2010 VMware, Inc. All rights reserved. * **********************************************************/ @@ -79,7 +79,7 @@ find(void *tag) } static void -increment(app_pc tag) +increment(void *tag) { elem_t *elem; @@ -106,7 +106,7 @@ increment(app_pc tag) } static void -decrement(app_pc tag) +decrement(void *tag) { elem_t *elem; @@ -161,14 +161,14 @@ static dr_emit_flags_t trace_event(void *drcontext, void *tag, instrlist_t *trace, bool translating) { if (!translating) - increment(dr_fragment_app_pc(tag)); + increment(tag); return DR_EMIT_DEFAULT; } static void deleted_event(void *dcontext, void *tag) { - decrement(dr_fragment_app_pc(tag)); + decrement(tag); } void @@ -246,7 +246,7 @@ bb_event(void *drcontext, void *tag, instrlist_t *bb, bool for_trace, bool trans { instr_t *instr; if (!translating) - increment(dr_fragment_app_pc(tag)); + increment(tag); /* I'm looking for a specific BB in the test .exe. I've marked * it with a couple nops. From ee1eb0559c41322967a4a88ae28d89246def3be0 Mon Sep 17 00:00:00 2001 From: Abhinav Anil Sharma Date: Wed, 24 Jan 2024 15:48:38 -0500 Subject: [PATCH 6/7] Replace displaced_pc with return_pc for the tag --- core/arch/interp.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core/arch/interp.c b/core/arch/interp.c index 48f2e0548b5..f417ea34c56 100644 --- a/core/arch/interp.c +++ b/core/arch/interp.c @@ -2750,6 +2750,11 @@ client_process_bb(dcontext_t *dcontext, build_bb_t *bb) /* DrMem#1735: pass app pc, not selfmod copy pc */ app_pc tag = bb->pretend_pc == NULL ? bb->start_pc : bb->pretend_pc; +#if defined(LINUX) && defined(X86_32) + if (DYNAMO_OPTION(hook_vsyscall) && tag == vsyscall_sysenter_displaced_pc) { + tag = vsyscall_sysenter_return_pc; + } +#endif #ifdef LINUX if (TEST(FRAG_STARTS_RSEQ_REGION, bb->flags)) { rseq_insert_start_label(dcontext, tag, bb->ilist); From 1989ac3f6a9059c172f98212aa7bd3db34bcebe2 Mon Sep 17 00:00:00 2001 From: Abhinav Anil Sharma Date: Thu, 25 Jan 2024 11:41:21 -0500 Subject: [PATCH 7/7] Revert "i#6417 x86-32 flakiness: debug client.flush" This reverts commit 21791cc23f69321598c3fca680600b73c29be8e0. --- .github/workflows/ci-aarch64-native.yml | 103 ++++ .github/workflows/ci-aarchxx.yml | 308 +++++++++++ .github/workflows/ci-clang-format.yml | 112 ++++ .github/workflows/ci-docs.yml | 155 ++++++ .github/workflows/ci-osx.yml | 111 ++++ .github/workflows/ci-package.yml | 660 ++++++++++++++++++++++++ .github/workflows/ci-riscv64.yml | 123 +++++ .github/workflows/ci-windows.yml | 253 +++++++++ .github/workflows/ci-x86.yml | 201 +++++++- suite/runsuite.cmake | 1 - suite/tests/CMakeLists.txt | 1 - 11 files changed, 2022 insertions(+), 6 deletions(-) create mode 100644 .github/workflows/ci-aarch64-native.yml create mode 100644 .github/workflows/ci-aarchxx.yml create mode 100644 .github/workflows/ci-clang-format.yml create mode 100644 .github/workflows/ci-docs.yml create mode 100644 .github/workflows/ci-osx.yml create mode 100644 .github/workflows/ci-package.yml create mode 100644 .github/workflows/ci-riscv64.yml create mode 100644 .github/workflows/ci-windows.yml diff --git a/.github/workflows/ci-aarch64-native.yml b/.github/workflows/ci-aarch64-native.yml new file mode 100644 index 00000000000..23d8913dc59 --- /dev/null +++ b/.github/workflows/ci-aarch64-native.yml @@ -0,0 +1,103 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# Copyright (c) 2023 Arm Limited All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for aarch64 Continuous Integration testing. + +name: ci-aarch64-native + +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + workflow_dispatch: + +jobs: + aarch64-native: + runs-on: [self-hosted, linux, ARM64] + steps: + - name: Check out repository code + uses: actions/checkout@v3 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - name: Cancel previous runs + uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + # We also need origin/master for pre-commit source file checks in runsuite.cmake. + # But fetching multiple branches isn't supported yet: actions/checkout#214 + # Pending PR that adds this support actions/checkout#155 + # TODO i#4549: When necessary support is available, remove/replace the + # workaround here and from every job in other Github Actions CI workflows. + - name: Fetch master + run: git fetch --no-tags --depth=1 origin master + + - name: Create build directory + run: mkdir build + + - name: Run Suite + working-directory: build + run: ../suite/runsuite_wrapper.pl travis + env: + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-32 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-aarchxx.yml b/.github/workflows/ci-aarchxx.yml new file mode 100644 index 00000000000..49bd04c479b --- /dev/null +++ b/.github/workflows/ci-aarchxx.yml @@ -0,0 +1,308 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for AArchXX Continuous Integration testing. + +name: ci-aarchxx +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # AArch64 cross-compile with gcc, with some tests run under QEMU. + # We use a more recent Ubuntu for a more recent QEMU. + aarch64-cross-compile: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu \ + qemu-user qemu-user-binfmt + sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ + zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ + liblz4-1:arm64 liblz4-dev:arm64 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ + sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/aarchxx-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # ARM cross-compile with gcc, with some tests run under QEMU. + # We use a more recent Ubuntu for a more recent QEMU. + arm-cross-compile: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf \ + qemu-user qemu-user-binfmt + sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ + zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ + liblz4-1:armhf liblz4-dev:armhf + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ + sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/aarchxx-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # Android ARM cross-compile with gcc, no tests: + android-arm-cross-compile: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Fetch and install Android NDK for Andoid cross-compile build. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake + cd /tmp + wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip + unzip -q android-ndk-r10e-linux-x86_64.zip + export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e + android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ + --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ + --install-dir=/tmp/android-gcc-arm-ndk-10e + # Manually force using ld.bfd, setting CMAKE_LINKER does not work. + ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld + ln -sf arm-linux-androideabi-ld.bfd \ + /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld + + - name: Run Suite + working-directory: ${{ github.workspace }} + env: + DYNAMORIO_CROSS_ANDROID_ONLY: yes + DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + run: ./suite/runsuite_wrapper.pl automated_ci + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/android-arm-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # AArch64 drdecode and drmemtrace on x86: + a64-on-x86: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ + liblz4-dev + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci + env: + DYNAMORIO_A64_ON_X86_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/a64-on-x86 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-clang-format.yml b/.github/workflows/ci-clang-format.yml new file mode 100644 index 00000000000..541564270b3 --- /dev/null +++ b/.github/workflows/ci-clang-format.yml @@ -0,0 +1,112 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for clang-format Continuous Integration testing. + +name: ci-clang-format +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # 64-bit Linux build with clang, no tests (runsuite.cmake disables the tests), + # install and require clang-format. + # We used to build 32-bit with clang but have decided that is not worth + # the CI resources: 64-bit hits most clang-only warnings and 64-bit + # is the primary target these days. + clang-format: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + - name: Create Build Environment + run: | + wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add - + sudo add-apt-repository 'deb http://apt.llvm.org/focal/ llvm-toolchain-focal-14 main' + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev clang-format-14 libunwind-dev + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only require_format + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + DYNAMORIO_CLANG: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/clang-format + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-docs.yml b/.github/workflows/ci-docs.yml new file mode 100644 index 00000000000..87d04fcd549 --- /dev/null +++ b/.github/workflows/ci-docs.yml @@ -0,0 +1,155 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for building doxygen docs for the web site. + +name: ci-docs +on: + # Built weekly: 10pm EST Fridays. A re-build even with no content + # changes updates timestamps on every page, increasing the repo size. + # We thus use manual builds for rare docs changes we want to deploy to + # the website and have automated builds match our weekly package builds. + schedule: + - cron: '0 3 * * FRI' + # Manual trigger using the Actions page. + workflow_dispatch: + inputs: + version: + description: 'Version number for docs (blank for cronbuild)' + required: false + default: '' + build: + description: 'Build number for docs' + required: true + default: '0' + +defaults: + run: + shell: bash + +jobs: + ########################################################################### + # Docs deployment, building on Linux. + docs: + # We use a more recent Ubuntu for better markdown support. + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + # We do shallow clones and assume DrM will update its DR at least once + # every 250 DR commits. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install needed packages. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake zlib1g-dev libsnappy-dev \ + liblz4-dev libunwind-dev + + - name: Get Version + id: version + # XXX: For now we duplicate this version number here with CMakeLists.txt. + # We should find a way to share (xref i#1565). + # We support setting the version and build for manual builds. + # We only use a non-zero build # when making multiple manual builds in one day. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Docs + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DEPLOY_DOCS: yes + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Check Out Web + uses: actions/checkout@v2 + with: + repository: DynamoRIO/dynamorio.github.io + token: ${{ secrets.DOCS_TOKEN }} + path: dynamorio.github.io + + - name: Deploy Embedded Docs + run: | + rsync -av --delete html_embed/ dynamorio.github.io/docs/ + cd dynamorio.github.io + git config --local user.name "cronbuild" + git config --local user.email "dynamorio-devs@googlegroups.com" + git add -A + git commit -m "Snapshot for cronbuild-${{ steps.version.outputs.version_number }}" + git push + env: + # We need a personal access token for write access to another repo. + GITHUB_TOKEN: ${{ secrets.DOCS_TOKEN }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/docs + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs diff --git a/.github/workflows/ci-osx.yml b/.github/workflows/ci-osx.yml new file mode 100644 index 00000000000..0bf789ee7df --- /dev/null +++ b/.github/workflows/ci-osx.yml @@ -0,0 +1,111 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for Mac OSX Continuous Integration testing. + +name: ci-osx +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # 64-bit OSX build with clang and run tests: + osx-x86-64: + runs-on: macos-11 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + - name: Create Build Environment + # XXX: We should install doxygen too but it's a different version and + # hits issues about incompatible options in the Doxyfile. + run: | + brew install nasm zlib snappy lz4 + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + # Change xcode version for current session: + # https://www.unix.com/man-page/osx/1/xcode-select/ + # https://github.community/t/selecting-an-xcode-version/16204/3 + # To find available versions, add the following as a step above: + # - run: ls -l /Applications + DEVELOPER_DIR: /Applications/Xcode_13.2.1.app/Contents/Developer + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/osx-x86-64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-package.yml b/.github/workflows/ci-package.yml new file mode 100644 index 00000000000..e93f9018675 --- /dev/null +++ b/.github/workflows/ci-package.yml @@ -0,0 +1,660 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for release packages. + +name: ci-package +on: + # Our weekly cronbuild: 9pm EST on Fridays. + schedule: + - cron: '0 2 * * SAT' + # Manual trigger using the Actions page. + workflow_dispatch: + inputs: + version: + description: 'Package version number (blank for cronbuild)' + required: false + default: '' + build: + description: 'Package build number' + required: true + default: '0' + +defaults: + run: + shell: bash + +jobs: + ########################################################################### + # Linux x86 tarball with 64-bit and 32-bit builds: + linux-x86: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + # We do shallow clones and assume DrM will update its DR at least once + # every 250 DR commits. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install multilib for non-cross-compiling Linux build. + # GA CI uses packages.microsoft.com which is missing i386 packages, and + # attempts at using apt with us.archive-ubuntu.com hit dep issues: + # so we manually install the i386 packages we need. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' + apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Get Version + id: version + # XXX: For now we duplicate this version number here with CMakeLists.txt. + # We should find a way to share (xref i#1565). + # We support setting the version and build for manual builds. + # We only use a non-zero build # when making multiple manual builds in one day. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + # We do not update the web documentation here because a newer + # Doxygen is needed but we have not yet tested our tests and + # packages built on newer Ubuntu on GA CI. + DEPLOY_DOCS: no + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload Artifacts + uses: actions/upload-artifact@v2 + with: + name: linux-tarball + path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/linux-x86 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Linux AArch64 tarball: + linux-aarch64: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-aarch64-linux-gnu + sudo add-apt-repository 'deb [arch=arm64] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:arm64 libunwind-dev:arm64 liblzma5:arm64 \ + zlib1g:arm64 zlib1g-dev:arm64 libsnappy1v5:arm64 libsnappy-dev:arm64 \ + liblz4-1:arm64 liblz4-dev:arm64 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/aarch64-linux-gnu/include/ + sudo rsync -av ../extract/lib/aarch64-linux-gnu/ /usr/aarch64-linux-gnu/lib/ + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload AArch64 + uses: actions/upload-artifact@v2 + with: + name: aarch64-tarball + path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/linux-aarch64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Linux ARM tarball (package.cmake does not support same job as AArch64): + linux-arm: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake g++-arm-linux-gnueabihf + sudo add-apt-repository 'deb [arch=armhf] http://ports.ubuntu.com/ubuntu-ports focal main' + apt download libunwind8:armhf libunwind-dev:armhf liblzma5:armhf \ + zlib1g:armhf zlib1g-dev:armhf libsnappy1v5:armhf libsnappy-dev:armhf \ + liblz4-1:armhf liblz4-dev:armhf + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/arm-linux-gnueabihf/include/ + sudo rsync -av ../extract/lib/arm-linux-gnueabihf/ /usr/arm-linux-gnueabihf/lib/ + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload ARM + uses: actions/upload-artifact@v2 + with: + name: arm-tarball + path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/linux-arm + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Android ARM tarball: + android-arm: + runs-on: ubuntu-20.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + # Fetch and install Android NDK for Andoid cross-compile build. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake + cd /tmp + wget https://dl.google.com/android/repository/android-ndk-r10e-linux-x86_64.zip + unzip -q android-ndk-r10e-linux-x86_64.zip + export ANDROID_NDK_ROOT=/tmp/android-ndk-r10e + android-ndk-r10e/build/tools/make-standalone-toolchain.sh --arch=arm \ + --toolchain=arm-linux-androideabi-4.9 --platform=android-21 \ + --install-dir=/tmp/android-gcc-arm-ndk-10e + # Manually force using ld.bfd, setting CMAKE_LINKER does not work. + ln -sf ld.bfd /tmp/android-gcc-arm-ndk-10e/arm-linux-androideabi/bin/ld + ln -sf arm-linux-androideabi-ld.bfd \ + /tmp/android-gcc-arm-ndk-10e/bin/arm-linux-androideabi-ld + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + DYNAMORIO_CROSS_ANDROID_ONLY: yes + DYNAMORIO_ANDROID_TOOLCHAIN: /tmp/android-gcc-arm-ndk-10e + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload Artifacts + uses: actions/upload-artifact@v2 + with: + name: android-tarball + path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/android-arm + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Windows .zip with 32-bit and 64-bit x86 builds: + windows: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Fetch Sources + run: | + git fetch --no-tags --depth=1 origin master + # Include Dr. Memory in packages. + git clone --depth=2 https://github.com/DynamoRIO/drmemory.git drmemory + cd drmemory && git submodule update --init --recursive --depth 250 && cd .. + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER=10.0.$((`git log -n 1 --format=%ct` / (60*60*24))) + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + + - name: Build Package + working-directory: ${{ github.workspace }} + shell: cmd + # We need to set up WiX for Dr. Memory. + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + dir "c:\Program Files (x86)\WiX Toolset"* + set PATH=C:\Program Files (x86)\WiX Toolset v3.11\bin;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja + env: + CI_TARGET: package + VERSION_NUMBER: ${{ steps.version.outputs.version_number }} + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Upload Artifacts + uses: actions/upload-artifact@v2 + with: + name: windows-zip + path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/windows + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs + + ########################################################################### + # Create release and populate with files. + # We can't have each OS job create the release because only the first + # succeeds and the others fail: there is no check in the create-release + # action to use an existing release if it already exists. + # Thus, our strategy is to share files from the build jobs with this + # single release job via artifacts. + + create_release: + needs: [linux-x86, linux-aarch64, linux-arm, android-arm, windows] + runs-on: ubuntu-20.04 + + steps: + # We need a checkout to run git log for the version. + - uses: actions/checkout@v2 + with: + submodules: true + + - name: Get Version + id: version + # XXX: See x86 job comments on sharing the default ver# with CMakeLists.txt. + run: | + if test -z "${{ github.event.inputs.version }}"; then + export VERSION_NUMBER="10.0.$((`git log -n 1 --format=%ct` / (60*60*24)))" + export PREFIX="cronbuild-" + else + export VERSION_NUMBER=${{ github.event.inputs.version }} + export PREFIX="release_" + fi + if [ "${{ github.event.inputs.build }}" -ne 0 ]; then + export VERSION_NUMBER="${VERSION_NUMBER}-${{ github.event.inputs.build }}" + fi + echo "::set-output name=version_number::${VERSION_NUMBER}" + echo "::set-output name=version_string::${PREFIX}${VERSION_NUMBER}" + + - name: Create Release + id: create_release + uses: actions/create-release@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + tag_name: ${{ steps.version.outputs.version_string }} + release_name: ${{ steps.version.outputs.version_string }} + body: | + Auto-generated periodic build. + draft: false + prerelease: false + + - name: Download Linux + uses: actions/download-artifact@v2 + with: + name: linux-tarball + - name: Upload Linux + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download AArch64 + uses: actions/download-artifact@v2 + with: + name: aarch64-tarball + - name: Upload AArch64 + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-AArch64-Linux-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download ARM + uses: actions/download-artifact@v2 + with: + name: arm-tarball + - name: Upload ARM + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-ARM-Linux-EABIHF-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download Android + uses: actions/download-artifact@v2 + with: + name: android-tarball + - name: Upload Android + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz + asset_name: DynamoRIO-ARM-Android-EABI-${{ steps.version.outputs.version_number }}.tar.gz + asset_content_type: application/x-gzip + + - name: Download Windows + uses: actions/download-artifact@v2 + with: + name: windows-zip + - name: Upload Windows + uses: actions/upload-release-asset@v1 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} + # This action doesn't seem to support a glob so we need the exact name. + asset_path: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip + asset_name: DynamoRIO-Windows-${{ steps.version.outputs.version_number }}.zip + asset_content_type: application/zip + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/create_release + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action package jobs diff --git a/.github/workflows/ci-riscv64.yml b/.github/workflows/ci-riscv64.yml new file mode 100644 index 00000000000..1029e14986d --- /dev/null +++ b/.github/workflows/ci-riscv64.yml @@ -0,0 +1,123 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for RISCV64 Continuous Integration testing. + +name: ci-riscv64 +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: bash + +jobs: + # RISCV64 cross-compile with gcc + # We use ubuntu 22.04 because the compilition here need python (3.10.x) + riscv64-cross-compile: + runs-on: ubuntu-22.04 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install cross-compiler for cross-compiling Linux build. + # Unfortunately there are no libunwind or compression cross-compile + # packages so we unpack the native versions and copy their files. + # Unfortunately, only kinetic (ubuntu 22.10) has linunwind-riscv64 packages. + # I prefer debian-ports here, it is more close to upstream. + - name: Create Build Environment + run: | + sudo apt-get update + sudo apt-get -y install doxygen vera++ cmake crossbuild-essential-riscv64 git \ + qemu-user qemu-user-binfmt + sudo add-apt-repository 'deb [trusted=yes arch=riscv64] http://deb.debian.org/debian sid main' + apt download libunwind8:riscv64 libunwind-dev:riscv64 liblzma5:riscv64 \ + zlib1g:riscv64 zlib1g-dev:riscv64 libsnappy1v5:riscv64 libsnappy-dev:riscv64 \ + liblz4-1:riscv64 liblz4-dev:riscv64 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + for i in include lib; do sudo rsync -av ../extract/usr/${i}/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/${i}/; done + sudo rsync -av ../extract/usr/include/ /usr/riscv64-linux-gnu/include/ + if test -e "../extract/lib/riscv64-linux-gnu/"; then \ + sudo rsync -av ../extract/lib/riscv64-linux-gnu/ /usr/riscv64-linux-gnu/lib/; \ + fi + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_RISCV64_LINUX_ONLY: yes + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + QEMU_LD_PREFIX: /usr/riscv64-linux-gnu/ + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/aarchxx-cross-compile + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-windows.yml b/.github/workflows/ci-windows.yml new file mode 100644 index 00000000000..d630e68bc61 --- /dev/null +++ b/.github/workflows/ci-windows.yml @@ -0,0 +1,253 @@ +# ********************************************************** +# Copyright (c) 2020-2023 Google, Inc. All rights reserved. +# ********************************************************** + +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions are met: +# +# * Redistributions of source code must retain the above copyright notice, +# this list of conditions and the following disclaimer. +# +# * Redistributions in binary form must reproduce the above copyright notice, +# this list of conditions and the following disclaimer in the documentation +# and/or other materials provided with the distribution. +# +# * Neither the name of Google, Inc. nor the names of its contributors may be +# used to endorse or promote products derived from this software without +# specific prior written permission. +# +# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL VMWARE, INC. OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +# DAMAGE. + +# Github Actions workflow for Windows Continuous Integration testing. + +# TODO i#2145: point at Qt5 for testing drgui build. + +name: ci-windows +on: + # Run on pushes to master and on pull request changes, including from a + # forked repo with no "push" trigger, while avoiding duplicate triggers. + push: + branches: + - master + pull_request: + types: [opened, reopened, synchronize] + merge_group: + + # Manual trigger using the Actions page. May remove when integration complete. + workflow_dispatch: + +defaults: + run: + shell: cmd + +jobs: + ########################################################################### + # 32-bit VS2019 and tests: + vs2019-32: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - name: Fetch Sources + run: git fetch --no-tags --depth=1 origin master + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja 32_only debug_only + env: + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/vs2019-32 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + ########################################################################### + # 64-bit VS2019 and tests: + vs2019-64: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - name: Fetch Sources + run: git fetch --no-tags --depth=1 origin master + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja 64_only debug_only + env: + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/vs2019-64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + ########################################################################### + # 32-bit and 64-bit VS2019 release builds: + vs2019-builds: + runs-on: windows-2019 + + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - name: Fetch Sources + run: git fetch --no-tags --depth=1 origin master + + - name: Download Packages + shell: powershell + run: | + md c:\projects\install + (New-Object System.Net.WebClient).DownloadFile("https://github.com/ninja-build/ninja/releases/download/v1.10.2/ninja-win.zip", "c:\projects\install\ninja.zip") + (New-Object System.Net.WebClient).DownloadFile("https://sourceforge.net/projects/doxygen/files/rel-1.8.19/doxygen-1.8.19.windows.x64.bin.zip", "c:\projects\install\doxygen.zip") + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: | + echo ------ Setting up paths ------ + 7z x c:\projects\install\ninja.zip -oc:\projects\install\ninja > nul + set PATH=c:\projects\install\ninja;%PATH% + 7z x c:\projects\install\doxygen.zip -oc:\projects\install\doxygen > nul + set PATH=c:\projects\install\doxygen;%PATH% + call "C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Auxiliary/Build/vcvars32.bat" + echo ------ Running suite ------ + echo PATH is "%PATH%" + echo Running in directory "%CD%" + perl suite/runsuite_wrapper.pl automated_ci use_ninja nontest_only + env: + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/vs2019-builds + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/.github/workflows/ci-x86.yml b/.github/workflows/ci-x86.yml index b4b8b13535d..e7e81b1de4c 100644 --- a/.github/workflows/ci-x86.yml +++ b/.github/workflows/ci-x86.yml @@ -111,10 +111,6 @@ jobs: CI_TRIGGER: ${{ github.event_name }} CI_BRANCH: ${{ github.ref }} - - name: Setup tmate session - if: ${{ failure() }} - uses: mxschmitt/action-tmate@v3 - - name: Send failure mail to dynamorio-devs if: failure() && github.ref == 'refs/heads/master' uses: dawidd6/action-send-mail@v2 @@ -138,3 +134,200 @@ jobs: See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} to: dynamorio-devs@googlegroups.com from: Github Action CI + + # 64-bit Linux build with gcc and run tests. + x86-64: + runs-on: ubuntu-20.04 + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install multilib for non-cross-compiling Linux build. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-64 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # Ubuntu22 64-bit Linux build with gcc and run tests. + # XXX: A matrix could combine this with the 20.04 but our auto-cancel + # step cancels the 2nd job so we need to solve that first. + x86-64-ubuntu22: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install multilib for non-cross-compiling Linux build. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 64_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-64-ubuntu22 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI + + # Ubuntu22 64-bit Linux build with gcc and run tests. + # XXX: A matrix could combine this with the 20.04 but our auto-cancel + # step cancels the 2nd job so we need to solve that first. + x86-32-ubuntu22: + runs-on: ubuntu-22.04 + steps: + - uses: actions/checkout@v2 + with: + submodules: true + + # Cancel any prior runs for a PR (but do not cancel master branch runs). + - uses: n1hility/cancel-previous-runs@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + if: ${{ github.event_name == 'pull_request' }} + + - run: git fetch --no-tags --depth=1 origin master + + # Install multilib for non-cross-compiling Linux build. + - name: Create Build Environment + run: | + sudo apt update + sudo apt-get -y install doxygen vera++ zlib1g-dev libsnappy-dev \ + liblz4-dev g++-multilib libunwind-dev + sudo add-apt-repository 'deb [arch=i386] http://us.archive.ubuntu.com/ubuntu focal main' + apt download libunwind8:i386 libunwind-dev:i386 liblzma5:i386 + mkdir ../extract + for i in *.deb; do dpkg-deb -x $i ../extract; done + sudo rsync -av ../extract/usr/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/lib/i386-linux-gnu/ /usr/lib/i386-linux-gnu/ + sudo rsync -av ../extract/usr/include/i386-linux-gnu/ /usr/include/ + echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope + + # Use a newer cmake to avoid 32-bit toolchain problems (i#4830). + - name: Setup newer cmake + uses: jwlawson/actions-setup-cmake@v1.8 + with: + cmake-version: '3.19.7' + + - name: Run Suite + working-directory: ${{ github.workspace }} + run: ./suite/runsuite_wrapper.pl automated_ci 32_only + env: + DYNAMORIO_CROSS_AARCHXX_LINUX_ONLY: no + CI_TRIGGER: ${{ github.event_name }} + CI_BRANCH: ${{ github.ref }} + + - name: Send failure mail to dynamorio-devs + if: failure() && github.ref == 'refs/heads/master' + uses: dawidd6/action-send-mail@v2 + with: + server_address: smtp.gmail.com + server_port: 465 + username: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_USERNAME}} + password: ${{secrets.DYNAMORIO_NOTIFICATION_EMAIL_PASSWORD}} + subject: | + [${{github.repository}}] ${{github.workflow}} FAILED + on ${{github.event_name}} at ${{github.ref}} + body: | + Github Actions CI workflow run FAILED! + Workflow: ${{github.workflow}}/x86-32-ubuntu22 + Repository: ${{github.repository}} + Branch ref: ${{github.ref}} + SHA: ${{github.sha}} + Triggering actor: ${{github.actor}} + Triggering event: ${{github.event_name}} + Run Id: ${{github.run_id}} + See more details on github.com/DynamoRIO/dynamorio/actions/runs/${{github.run_id}} + to: dynamorio-devs@googlegroups.com + from: Github Action CI diff --git a/suite/runsuite.cmake b/suite/runsuite.cmake index 2af38db31de..56e12a8aaa2 100644 --- a/suite/runsuite.cmake +++ b/suite/runsuite.cmake @@ -93,7 +93,6 @@ if (UNIX AND NOT APPLE AND NOT ANDROID AND NOT cross_riscv64_linux_only) set(arg_debug_only ON) endif () endif () -set(extra_ctest_args INCLUDE_LABEL TMATE_DEBUG)#NOCHECK set(build_tests "BUILD_TESTS:BOOL=ON") diff --git a/suite/tests/CMakeLists.txt b/suite/tests/CMakeLists.txt index ff7b6ed25d4..9d63cb47626 100644 --- a/suite/tests/CMakeLists.txt +++ b/suite/tests/CMakeLists.txt @@ -5895,4 +5895,3 @@ if (RISCV64) PROPERTIES LABELS RUNS_ON_QEMU) endif () endif () -set_tests_properties(code_api|client.flush PROPERTIES LABELS TMATE_DEBUG)#NOCHECK