-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1 from bildhuus/fix_mixed_arch_build
Fix mixed architecture builds
- Loading branch information
Showing
4 changed files
with
125 additions
and
6 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 |
---|---|---|
@@ -0,0 +1,94 @@ | ||
name: CI | ||
|
||
# Only triggers on pushes/PRs to master | ||
on: | ||
pull_request: | ||
branches: | ||
- master | ||
push: | ||
branches: | ||
- master | ||
- github_actions | ||
|
||
jobs: | ||
test-linux: | ||
name: Unittests Linux | ||
timeout-minutes: 30 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [ubuntu-latest] | ||
dc: [dmd-latest, ldc-latest] | ||
arch: [x86_64] | ||
|
||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Install D compiler | ||
uses: dlang-community/setup-dlang@v1 | ||
with: | ||
compiler: ${{ matrix.dc }} | ||
|
||
- name: Install gcc-multilib | ||
run: | | ||
sudo apt update | ||
sudo apt install gcc-multilib -y | ||
- name: Run tests | ||
env: | ||
ARCH: ${{matrix.arch}} | ||
run: ./test.sh | ||
shell: bash | ||
test-macos: | ||
name: Unittests macOS | ||
timeout-minutes: 30 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [macOS-13] | ||
dc: [dmd-latest, ldc-latest] | ||
arch: [x86_64] | ||
|
||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Install D compiler | ||
uses: dlang-community/setup-dlang@v1 | ||
with: | ||
compiler: ${{ matrix.dc }} | ||
|
||
- name: Run tests | ||
env: | ||
ARCH: ${{matrix.arch}} | ||
run: ./test.sh | ||
shell: bash | ||
test-windows: | ||
name: Unittests Windows | ||
timeout-minutes: 30 | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: [windows-latest] | ||
dc: [dmd-latest, ldc-latest] | ||
arch: [x86_64] | ||
include: | ||
- { os: windows-latest, dc: dmd-latest, arch: x86_mscoff } | ||
|
||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- uses: ilammy/msvc-dev-cmd@v1 | ||
|
||
- name: Install D compiler | ||
uses: dlang-community/setup-dlang@v2 | ||
with: | ||
compiler: ${{ matrix.dc }} | ||
|
||
- name: Run tests | ||
env: | ||
ARCH: ${{matrix.arch}} | ||
run: ./test.sh | ||
shell: bash |
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 @@ | ||
/+ dub.sdl: | ||
dependency "sqlite3d" path="." | ||
+/ | ||
import sqlite3; | ||
|
||
void main() | ||
{ | ||
if (sqlite3_initialize() != SQLITE_OK) | ||
assert(false, "Failed to initialize sqlite3"); | ||
|
||
sqlite3_shutdown(); | ||
} |
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,5 @@ | ||
#!/bin/sh | ||
|
||
set -xe | ||
|
||
dub --single test.d -a $ARCH |