Add TinyCC SIMD bytecode examples #27
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Fedora CRAN check | |
| # Mirrors the CRAN r-devel-linux-x86_64-fedora-gcc flavour by running | |
| # `R CMD build && R CMD check --as-cran` inside the rhub gcc16 container | |
| # (Fedora 44 + GCC 16 + the same R-devel snapshot CRAN uses). Same image | |
| # scripts/docker-cran-fedora.sh runs locally. | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| jobs: | |
| fedora-cran-check: | |
| runs-on: ubuntu-latest | |
| container: | |
| image: ghcr.io/r-hub/containers/gcc16:latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install OS dependencies | |
| run: | | |
| dnf install -y --setopt=install_weak_deps=False \ | |
| libuv-devel pandoc qpdf texlive-scheme-medium | |
| - name: Cache R library | |
| uses: actions/cache@v4 | |
| with: | |
| path: /root/R-libs | |
| key: r-libs-fedora-gcc16-${{ hashFiles('DESCRIPTION') }} | |
| restore-keys: | | |
| r-libs-fedora-gcc16- | |
| - name: Install R package dependencies | |
| run: | | |
| mkdir -p /root/R-libs | |
| echo "R_LIBS_USER=/root/R-libs" >> ~/.Renviron | |
| R -q -e ' | |
| pkgs <- c("lambda.r", "bench", "callme", "knitr", "rmarkdown", | |
| "tinytest", "treesitter.c") | |
| need <- setdiff(pkgs, | |
| rownames(installed.packages(lib.loc = "/root/R-libs"))) | |
| if (length(need)) install.packages(need, lib = "/root/R-libs", | |
| repos = "https://cloud.r-project.org") | |
| ' | |
| - name: R CMD build | |
| run: | | |
| echo "R_LIBS_USER=/root/R-libs" >> ~/.Renviron | |
| R CMD build . | |
| - name: R CMD check --as-cran | |
| run: | | |
| echo "R_LIBS_USER=/root/R-libs" >> ~/.Renviron | |
| PKG=$(ls -t Rtinycc_*.tar.gz | head -n1) | |
| R CMD check --as-cran --no-manual "$PKG" | |
| - name: Upload check artifacts on failure | |
| if: failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: fedora-cran-check-results | |
| path: | | |
| Rtinycc.Rcheck/ | |
| config.log | |
| if-no-files-found: ignore |