Skip to content

Commit 0378498

Browse files
authored
Merge pull request #25 from xdoardo/llvm-18
Update Windows version and use Ninja
2 parents f96db93 + 9619cd7 commit 0378498

File tree

4 files changed

+35
-20
lines changed

4 files changed

+35
-20
lines changed

.github/workflows/ci.yml

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,16 @@ jobs:
1919
os: "ubuntu-latest"
2020
# os: ['self-hosted', 'linux', 'RISCV64']
2121
- id: 'darwin-amd64'
22+
os: 'macos-13'
23+
tar_extra_args: ''
24+
- id: 'darwin-aarch64'
2225
os: 'macos-latest'
2326
tar_extra_args: ''
27+
# When unpacking an archive on Windows, the symlinks can't be
28+
# created unless the target path already exists. This causes
29+
# problems when the linked file is ordered after the link
2430
- id: 'windows-amd64'
25-
os: 'windows-2019'
31+
os: 'windows-2022'
2632
# When unpacking an archive on Windows, the symlinks can't be
2733
# created unless the target path already exists. This causes
2834
# problems when the linked file is ordered after the link
@@ -64,12 +70,11 @@ jobs:
6470
run: |
6571
brew install ninja
6672
67-
# TODO(jubianchi): Re-enable this to build on MingW
68-
# - name: Install `ninja` on Windows
69-
# if: startsWith(matrix.target.id, 'windows-')
70-
# shell: bash
71-
# run: |
72-
# choco install ninja
73+
- name: Install `ninja` on Windows
74+
if: startsWith(matrix.target.id, 'windows-')
75+
shell: bash
76+
run: |
77+
choco install ninja
7378
7479
- name: Build
7580
if: matrix.target.id != 'windows-amd64' && matrix.target.id != 'linux-aarch64' && matrix.target.id != 'linux-riscv64'
@@ -169,7 +174,7 @@ jobs:
169174
with:
170175
upload_url: ${{ steps.create_release.outputs.upload_url }}
171176
asset_path: artifacts/linux-aarch64-${{matrix.llvm_version}}/llvm.tar.xz
172-
asset_name: linux-aarch64.tar.xz
177+
asset_name: llvm-linux-aarch64.tar.xz
173178
asset_content_type: application/gzip
174179

175180
- name: Upload Release Asset Linux (RISCV64)
@@ -179,7 +184,7 @@ jobs:
179184
with:
180185
upload_url: ${{ steps.create_release.outputs.upload_url }}
181186
asset_path: artifacts/linux-riscv64-${{matrix.llvm_version}}/llvm.tar.xz
182-
asset_name: linux-riscv64.tar.xz
187+
asset_name: llvm-linux-riscv64.tar.xz
183188
asset_content_type: application/gzip
184189

185190
- name: Upload Release Asset Darwin
@@ -192,6 +197,16 @@ jobs:
192197
asset_name: llvm-darwin-amd64.tar.xz
193198
asset_content_type: application/gzip
194199

200+
- name: Upload Release Asset Darwin (aarch64)
201+
uses: actions/upload-release-asset@v1
202+
env:
203+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
204+
with:
205+
upload_url: ${{ steps.create_release.outputs.upload_url }}
206+
asset_path: artifacts/darwin-aarch64-${{matrix.llvm_version}}/llvm.tar.xz
207+
asset_name: llvm-darwin-aarch64.tar.xz
208+
asset_content_type: application/gzip
209+
195210
- name: Upload Release Asset Windows
196211
uses: actions/upload-release-asset@v1
197212
env:

README.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -52,25 +52,27 @@ assets](https://github.com/wasmerio/llvm-custom-builds/releases).
5252
<td rowspan="5">18</td>
5353
<td rowspan="3">amd64</td>
5454
<td>Darwin</td>
55-
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/darwin-amd64.tar.gz">download</a></td>
55+
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/llvm-darwin-amd64.tar.xz">download</a></td>
5656
</tr>
5757
<tr>
5858
<td>Linux</td>
59-
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/linux-amd64.tar.gz">download</a></td>
59+
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/llvm-linux-amd64.tar.xz">download</a></td>
6060
</tr>
6161
<tr>
6262
<td>Windows</td>
63-
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/windows-amd64.tar.gz">download</a></td>
63+
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/llvm-windows-amd64.tar.xz">download</a></td>
6464
</tr>
6565
<tr>
66-
<td>aarch64</td>
66+
<td rowspan="2">aarch64</td>
6767
<td>Linux</td>
68-
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/linux-aarch64.tar.gz">download</a></td>
68+
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/llvm-linux-aarch64.tar.xz">download</a></td>
69+
<td>Darwin</td>
70+
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/llvm-darwin-aarch64.tar.xz">download</a></td>
6971
</tr>
7072
<tr>
7173
<td>riscv64</td>
7274
<td>Linux</td>
73-
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/linux-riscv64.tar.gz">download</a></td>
75+
<td><a href="https://github.com/wasmerio/llvm-custom-builds/releases/download/18.x/llvm-linux-riscv64.tar.xz">download</a></td>
7476
</tr>
7577
<tr>
7678
<td rowspan="5">16</td>

build.ps1

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ if ([string]::IsNullOrEmpty($LLVM_VERSION)) {
1717

1818
# Clone the LLVM project.
1919
if (-not (Test-Path -Path "llvm-project" -PathType Container)) {
20-
git clone "$LLVM_REPO_URL" llvm-project
20+
git clone -b "release/$LLVM_VERSION" --single-branch --depth=1 "$LLVM_REPO_URL" llvm-project
2121
}
2222

2323
Set-Location llvm-project
@@ -40,15 +40,14 @@ $CROSS_COMPILE = ""
4040

4141
# Run `cmake` to configure the project.
4242
cmake `
43-
-G "Visual Studio 16 2019" `
43+
-G "Ninja" `
4444
-DCMAKE_BUILD_TYPE=MinSizeRel `
4545
-DCMAKE_INSTALL_PREFIX=destdir `
4646
-DLLVM_ENABLE_PROJECTS="clang;lld" `
4747
-DLLVM_ENABLE_TERMINFO=OFF `
4848
-DLLVM_ENABLE_ZLIB=OFF `
4949
-DLLVM_INCLUDE_DOCS=OFF `
5050
-DLLVM_INCLUDE_EXAMPLES=OFF `
51-
-DLLVM_INCLUDE_GO_TESTS=OFF `
5251
-DLLVM_INCLUDE_TESTS=OFF `
5352
-DLLVM_INCLUDE_TOOLS=ON `
5453
-DLLVM_INCLUDE_UTILS=OFF `

build.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ fi
2323
# Clone the LLVM project.
2424
if [ ! -d llvm-project ]
2525
then
26-
git clone "$LLVM_REPO_URL" llvm-project
26+
git clone -b "release/$LLVM_VERSION" --single-branch --depth=1 "$LLVM_REPO_URL" llvm-project
2727
fi
2828

2929

@@ -67,7 +67,6 @@ cmake \
6767
-DLLVM_ENABLE_ZLIB=OFF \
6868
-DLLVM_INCLUDE_DOCS=OFF \
6969
-DLLVM_INCLUDE_EXAMPLES=OFF \
70-
-DLLVM_INCLUDE_GO_TESTS=OFF \
7170
-DLLVM_INCLUDE_TESTS=OFF \
7271
-DLLVM_INCLUDE_TOOLS=ON \
7372
-DLLVM_INCLUDE_UTILS=OFF \

0 commit comments

Comments
 (0)