Skip to content

Commit

Permalink
switch to arm macos runner
Browse files Browse the repository at this point in the history
  • Loading branch information
mloubout committed Oct 1, 2024
1 parent 61797a7 commit 03820c6
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 15 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/ci-judi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,13 @@ jobs:

matrix:
version: ['1.6', '1.7', '1.8', '1.9', '1.10']
os: [ubuntu-latest, macos-13]
os: [ubuntu-latest]
arch: ['x64']

include:
- os: macos-latest
version: '1'
arch: ARM64

steps:
- name: Checkout JUDI
Expand All @@ -39,7 +45,7 @@ jobs:
uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: x64
arch: ${{ matrix.arch }}

- name: Set up Python 3.9
uses: actions/setup-python@v4
Expand Down
49 changes: 39 additions & 10 deletions .github/workflows/ci-op.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,37 +34,43 @@ jobs:
version: ['1']
omp: [2]
cc: ['gcc-11']
arch: ['x64']

include:
- os: macos-13
version: '1.6'
- os: macos-15
version: '1'
op: "ISO_OP"
omp: 1
cc: gcc-13
cc: clang
arch: ARM64

- os: macos-13
- os: macos-15
version: '1.8'
op: "ISO_OP"
omp: 1
cc: gcc-13
cc: clang
arch: ARM64

- os: macos-13
- os: macos-15
version: '1.9'
op: "ISO_OP"
omp: 1
cc: gcc-13
cc: clang
arch: ARM64

- os: ubuntu-latest
version: '1.9'
op: "VISCO_AC_OP"
omp: 2
cc: gcc-11
arch: x64

- os: ubuntu-latest
version: '1.10'
op: "ISO_OP"
omp: 2
cc: gcc-11
arch: x64

steps:
- name: Checkout JUDI
Expand All @@ -74,22 +80,45 @@ jobs:
uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: x64
arch: ${{ matrix.arch }}

- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: latest

- name: Setup clang for osx
if: runner.os == 'macOS'
run: |
brew install libomp
brew reinstall llvm
echo "PATH=$(brew --prefix llvm@18)/bin:$PATH" >> $GITHUB_ENV
echo "LD_LIBRARY_PATH=$(brew --prefix llvm@18)/lib:$LD_LIBRARY_PATH" >> $GITHUB_ENV
- name: Debug clang
if: runner.os == 'macOS'
run: |
clang -xc /dev/null -E -Wp,-v 2>&1 | sed -n 's,^ ,,p'
clang -xc /dev/null -E -Wp,-v 2>&1 | sed -n 's,^ ,,p' | xargs ls
- name: Set up Python 3.9
uses: actions/setup-python@v4
uses: actions/setup-python@v5
with:
python-version: 3.9

- name: Set julia python
run: |
echo "PYTHON=$(which python3)" >> $GITHUB_ENV
echo "PYCALL_JL_RUNTIME_PYTHON=$(which python3)" >> $GITHUB_ENV
python3 -m pip install devito[tests,extras]@git+https://github.com/devitocodes/devito.git
PYTHON=$(which python3) julia -e 'using Pkg;Pkg.add("PyCall");Pkg.build("PyCall")'
PYCALL_JL_RUNTIME_PYTHON=$(which python3) PYTHON=$(which python3) julia -e 'using Pkg;Pkg.add("PyCall");Pkg.build("PyCall")'
- name: Build JUDI
uses: julia-actions/julia-buildpkg@latest

- name: Debug numpy path
run: |
julia -e 'using PyCall; np = pyimport("numpy"); @show np."__file__"'
- name: Run tests
uses: julia-actions/julia-runtest@latest
with:
Expand Down
6 changes: 3 additions & 3 deletions deps/build.jl
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ end
pk = try
pyimport("pkg_resources")
catch e
run(PyCall.python_cmd(`-m pip install --user setuptools`))
run(PyCall.python_cmd(`-m pip install -U --user --no-cache-dir setuptools`))
pyimport("pkg_resources")
end

################## Devito ##################
# pip command
dvver = "4.8.10"
cmd = PyCall.python_cmd(`-m pip install --user devito\[extras,tests\]\>\=$(dvver)`)
cmd = PyCall.python_cmd(`-m pip install --user --no-cache-dir devito\[extras,tests\]\>\=$(dvver)`)

try
dv_ver = VersionNumber(split(pk.get_distribution("devito").version, "+")[1])
Expand All @@ -32,5 +32,5 @@ end
try
mpl = pyimport("matplotlib")
catch e
run(PyCall.python_cmd(`-m pip install --user matplotlib`))
run(PyCall.python_cmd(`-m pip install --user --no-cache-dir matplotlib`))
end

0 comments on commit 03820c6

Please sign in to comment.