diff --git a/.gitea/workflows/build.yml b/.gitea/workflows/build.yml new file mode 100644 index 000000000000..15457cd7a9d6 --- /dev/null +++ b/.gitea/workflows/build.yml @@ -0,0 +1,57 @@ +name: Build Clang P2996 +on: + push: + branches: + - automated-release + +jobs: + build: + runs-on: self-hosted + container: + image: ubuntu:22.04 + + env: + INSTALL_PATH: ${{ github.workspace }}/install + + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Install dependencies + run: | + apt-get update + apt-get install -y \ + cmake \ + make \ + python3 \ + python3-pip \ + zlib1g-dev \ + build-essential + pip3 install PyYAML>=5.1 + + - name: Configure Clang + run: | + cmake -S llvm -B build \ + -DLLVM_ENABLE_PROJECTS='clang;clang-tools-extra' \ + -DLLVM_ENABLE_RUNTIMES='libcxx;libcxxabi;libunwind' \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_PREFIX=${INSTALL_PATH} + + - name: Build Clang + run: | + cmake --build build --parallel=4 + + - name: Install + run: | + cmake --install build --prefix ${INSTALL_PATH} + + - name: Package artifact + run: | + tar -czf clang-install.tar.gz -C ${INSTALL_PATH} . + + - name: Upload artifact + uses: actions/upload-artifact@v3 + with: + name: clang-p2996 + path: clang-p2996tar.gz +