-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Makes the devcontainer use our assertion-enabled binaries. (#36)
- Loading branch information
Showing
4 changed files
with
45 additions
and
11 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,26 @@ | ||
ARG SWIFT_VERSION | ||
ARG SWIFT_VERSION=5.9 | ||
|
||
FROM swift:${SWIFT_VERSION} | ||
|
||
RUN apt-get update && \ | ||
apt-get install -y \ | ||
libllvm15 llvm-15 llvm-15-dev llvm-15-doc llvm-15-examples llvm-15-runtime | ||
ARG HYLO_LLVM_BUILD_RELEASE=2024-02-29-r2 | ||
ARG LLVM_VERSION=17.0.6 | ||
|
||
RUN ln -s /usr/bin/llvm-config-15 /usr/bin/llvm-config | ||
ENV HYLO_LLVM_DOWNLOAD_URL="https://github.com/hylo-lang/llvm-build/releases/download" | ||
|
||
RUN apt-get clean | ||
RUN apt-get update | ||
RUN apt-get install -y tar zstd libzstd1 libzstd-dev | ||
|
||
ADD ${HYLO_LLVM_DOWNLOAD_URL}/${HYLO_LLVM_BUILD_RELEASE}/llvm-${LLVM_VERSION}-x86_64-unknown-linux-gnu-Debug.tar.zst /opt | ||
RUN tar -x --zstd -f /opt/llvm-${LLVM_VERSION}-x86_64-unknown-linux-gnu-Debug.tar.zst -C /opt | ||
|
||
ADD ${HYLO_LLVM_DOWNLOAD_URL}/${HYLO_LLVM_BUILD_RELEASE}/llvm-${LLVM_VERSION}-x86_64-unknown-linux-gnu-MinSizeRel.tar.zst /opt | ||
RUN tar -x --zstd -f /opt/llvm-${LLVM_VERSION}-x86_64-unknown-linux-gnu-MinSizeRel.tar.zst -C /opt | ||
|
||
ADD ${HYLO_LLVM_DOWNLOAD_URL}/${HYLO_LLVM_BUILD_RELEASE}/llvm-${LLVM_VERSION}-aarch64-unknown-linux-gnu-Debug.tar.zst /opt | ||
RUN tar -x --zstd -f /opt/llvm-${LLVM_VERSION}-aarch64-unknown-linux-gnu-Debug.tar.zst -C /opt | ||
|
||
ADD ${HYLO_LLVM_DOWNLOAD_URL}/${HYLO_LLVM_BUILD_RELEASE}/llvm-${LLVM_VERSION}-aarch64-unknown-linux-gnu-MinSizeRel.tar.zst /opt | ||
RUN tar -x --zstd -f /opt/llvm-${LLVM_VERSION}-aarch64-unknown-linux-gnu-MinSizeRel.tar.zst -C /opt | ||
|
||
RUN rm /opt/llvm-*.tar.zst |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#!/usr/bin/env bash | ||
set -e | ||
set -o pipefail | ||
|
||
echo "Hylo LLVM build type: $HYLO_LLVM_BUILD_TYPE" | ||
echo | ||
|
||
ln -s /opt/llvm-*-$(uname -m)-*-Debug /opt/llvm-Debug | ||
ln -s /opt/llvm-*-$(uname -m)-*-MinSizeRel /opt/llvm-MinSizeRel | ||
|
||
export PATH="/opt/llvm-$HYLO_LLVM_BUILD_TYPE/bin:$PATH" | ||
./Tools/make-pkgconfig.sh /usr/local/lib/pkgconfig/llvm.pc |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -34,6 +34,8 @@ jobs: | |
|
||
- name: Build and run devcontainer task | ||
uses: devcontainers/[email protected] | ||
env: | ||
HYLO_LLVM_BUILD_TYPE: ${{ matrix.configuration == 'debug' && 'Debug' || 'MinSizeRel' }} | ||
with: | ||
runCmd: swift test --parallel -v -c ${{ matrix.configuration }} ${{ matrix.host.test-options }} | ||
|
||
|