Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support LLVM 16 #13181

Merged
merged 25 commits into from
May 12, 2023
Merged
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 21 additions & 19 deletions .github/workflows/llvm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,39 +15,41 @@ jobs:
strategy:
fail-fast: false
matrix:
llvm_version: ["13.0.0", "14.0.0", "15.0.6"]
include:
- llvm_version: "13.0.0"
llvm_ubuntu_version: "20.04"
- llvm_version: "14.0.0"
llvm_ubuntu_version: "18.04"
- llvm_version: "15.0.6"
llvm_ubuntu_version: "18.04"
Comment on lines +22 to +24
Copy link
Member

@beta-ziliani beta-ziliani May 11, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are these in 18.04? Don't they work in 20.04? 18.04 is close to EOL

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's the version number that comes with the LLVM download, our base image is now always 22.04

- llvm_version: "16.0.3"
force_version: true
ubuntu_version: "22.04"
llvm_ubuntu_version: "22.04"
name: "LLVM ${{ matrix.llvm_version }}"
steps:
- name: Checkout Crystal source
uses: actions/checkout@v3

- name: Cache LLVM and Clang
- name: Cache LLVM
id: cache-llvm
uses: actions/cache@v3
with:
path: |
C:/Program Files/LLVM
./llvm
path: ./llvm
key: llvm-${{ matrix.llvm_version }}
if: "${{ !env.ACT }}"

- uses: KyleMayes/install-llvm-action@13d5d77cbf0bd7e35cb02a8f9ed4bb85bed3393b # v1.8.0
with:
version: "${{ matrix.llvm_version }}"
force-version: "${{ matrix.force_version }}"
ubuntu-version: "${{ matrix.ubuntu_version }}"
cached: ${{ steps.cache-llvm.outputs.cache-hit }}

- name: Install dependencies
run: sudo apt-get install -y libtinfo5
- name: Install LLVM ${{ matrix.llvm_version }}
run: |
mkdir -p llvm
curl -L "https://github.com/llvm/llvm-project/releases/download/llvmorg-${{ matrix.llvm_version }}/clang+llvm-${{ matrix.llvm_version }}-x86_64-linux-gnu-ubuntu-${{ matrix.llvm_ubuntu_version }}.tar.xz" > llvm.tar.xz
tar x --xz -C llvm --strip-components=1 -f llvm.tar.xz
if: steps.cache-llvm.outputs.cache-hit != 'true'

- name: Set LLVM_CONFIG
# LLVM_PATH is set by install-llvm-action
run: echo "LLVM_CONFIG=$LLVM_PATH/bin/llvm-config" >> $GITHUB_ENV
- name: Set up LLVM
run: |
sudo apt-get install -y libtinfo5
echo "PATH=$(pwd)/llvm/bin:$PATH" >> $GITHUB_ENV
echo "LLVM_CONFIG=$(pwd)/llvm/bin/llvm-config" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=$(pwd)/llvm/lib:$LD_LIBRARY_PATH" >> $GITHUB_ENV

- name: Install Crystal
uses: crystal-lang/install-crystal@v1
Expand Down