Skip to content

Commit d54fa03

Browse files
committed
Merge remote-tracking branch 'origin/main'
2 parents 3c294dd + 86e508f commit d54fa03

21 files changed

+512
-419
lines changed

.github/workflows/build.yml

Lines changed: 47 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ on:
1010

1111
jobs:
1212
Build:
13-
if: "!contains(github.event.pull_request.labels.*.name, 'docs-only')"
13+
if: ${{ !contains(github.event.pull_request.labels.*.name, 'docs-only') }}
1414
runs-on: ${{ matrix.os }}
1515
strategy:
1616
matrix:
@@ -24,3 +24,49 @@ jobs:
2424
use_conda: true
2525
check_import: true
2626
python: ${{ matrix.python }}
27+
28+
build_wheels:
29+
name: Test wheel building on ${{ matrix.platform }}
30+
runs-on: ${{ matrix.os }}
31+
strategy:
32+
fail-fast: false
33+
matrix:
34+
include:
35+
- os: ubuntu-latest
36+
platform: manylinux
37+
- os: macos-latest
38+
platform: mac
39+
- os: windows-latest
40+
platform: windows
41+
42+
steps:
43+
- uses: actions/checkout@v4
44+
with:
45+
fetch-depth: 0
46+
47+
- name: Install cibuildwheel
48+
run: pipx install cibuildwheel==2.23.1
49+
50+
- name: Build wheels
51+
run: cibuildwheel --output-dir wheelhouse .
52+
53+
- uses: actions/upload-artifact@v4
54+
with:
55+
name: wheels-${{ matrix.platform }}
56+
path: wheelhouse/*.whl
57+
58+
build_sdist:
59+
name: Test source distribution
60+
runs-on: ubuntu-latest
61+
steps:
62+
- uses: actions/checkout@v4
63+
with:
64+
fetch-depth: 0
65+
66+
- name: Build SDist
67+
run: pipx run build --sdist
68+
69+
- uses: actions/upload-artifact@v4
70+
with:
71+
name: sdist
72+
path: dist/*.tar.gz

.gitignore

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,3 +149,10 @@ scripts/
149149
ext/**
150150
external/
151151
**/external/
152+
153+
# ------------------------------------------------------------------------------
154+
# cibuildwheel
155+
# ------------------------------------------------------------------------------
156+
157+
wheelhouse
158+
wheelhouse/**

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1010
### Added
1111

1212
* Added MeshSolver class.
13+
* Added documentation for cibuildwheel.
1314

1415
### Changed
1516

1617
* Fix circular Solver import.
18+
* Fix build.yml to match release.yml.
19+
* Fix license files.
1720

1821
### Removed
1922

CMakeLists.txt

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,19 @@ option(ENABLE_PRECOMPILED_HEADERS "Enable precompiled headers" ON)
1414
option(FAST_COMPILE "Optimize for faster compilation (-O0) vs execution (-O3)" OFF)
1515
option(USE_OPENMP "Enable OpenMP support for parallel processing" OFF)
1616

17-
# Apply optimization flags
17+
# Apply optimization flags in a cross-platform way
1818
if(FAST_COMPILE)
19-
add_compile_options(-O0)
19+
if(MSVC)
20+
add_compile_options(/Od) # Disable optimization (MSVC)
21+
else()
22+
add_compile_options(-O0) # Disable optimization (GCC/Clang)
23+
endif()
2024
else()
21-
add_compile_options(-O3)
25+
if(MSVC)
26+
add_compile_options(/O2) # Optimize for speed (MSVC)
27+
else()
28+
add_compile_options(-O3) # Optimize for speed (GCC/Clang)
29+
endif()
2230
endif()
2331

2432
# ==============================================================================

0 commit comments

Comments
 (0)