Skip to content

Commit

Permalink
ci,README: improve install instructions
Browse files Browse the repository at this point in the history
  • Loading branch information
aofei committed Jun 17, 2024
1 parent ab7329d commit 7c10d18
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 10 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,10 @@ jobs:
- name: Install LLVM ${{ matrix.llvm }} and libgc-dev
if: startsWith(matrix.os, 'ubuntu')
run: |
echo 'deb http://apt.llvm.org/focal/ llvm-toolchain-focal-${{ matrix.llvm }} main' | sudo tee /etc/apt/sources.list.d/llvm.list
echo 'deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-${{ matrix.llvm }} main' | sudo tee /etc/apt/sources.list.d/llvm.list
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
sudo apt-get update
sudo apt-get install --no-install-recommends clang-${{ matrix.llvm }} llvm-${{ matrix.llvm }}-dev libgc-dev
sudo apt-get install -y --no-install-recommends llvm-${{ matrix.llvm }}-dev clang-${{ matrix.llvm }} lld-${{ matrix.llvm }} libgc-dev
echo /usr/lib/llvm-${{ matrix.llvm }}/bin >> $GITHUB_PATH
- name: Clang information
Expand Down
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -218,20 +218,20 @@ Follow these steps to generate the `llgo` command (its usage is the same as the
### on macOS

```sh
brew update # execute if needed
brew install libgc
brew install llvm@17
brew update # execute if needed
brew install llvm@17 libgc
export PATH=$(brew --prefix llvm@17)/bin:$PATH # you may want to add this to your shell RC file, e.g. ~/.zshrc
go install -v ./...
```

### on Linux
### on Linux (Debian/Ubuntu)

```sh
echo 'deb http://apt.llvm.org/focal/ llvm-toolchain-focal-17 main' | sudo tee /etc/apt/sources.list.d/llvm.list
echo 'deb http://apt.llvm.org/$(lsb_release -cs)/ llvm-toolchain-$(lsb_release -cs)-17 main' | sudo tee /etc/apt/sources.list.d/llvm.list
wget -O - https://apt.llvm.org/llvm-snapshot.gpg.key | sudo apt-key add -
sudo apt-get update # execute if needed
sudo apt-get install libgc-dev
sudo apt-get install --no-install-recommends llvm-17-dev
sudo apt-get update # execute if needed
sudo apt-get install -y --no-install-recommends llvm-17-dev clang-17 lld-17 libgc-dev
export PATH=/usr/lib/llvm-17/bin:$PATH # you may want to add this to your shell RC file, e.g. ~/.bashrc
go install -v ./...
```

Expand Down

0 comments on commit 7c10d18

Please sign in to comment.