-
Notifications
You must be signed in to change notification settings - Fork 3
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 #7 from valboz/dev-2
Update to v4.2
- Loading branch information
Showing
21 changed files
with
249 additions
and
256 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,55 @@ | ||
name: Build | ||
|
||
on: | ||
push: | ||
paths: | ||
- '**.cpp' | ||
- '**.h' | ||
- '**.py' | ||
- '**.toml' | ||
- '**.yml' | ||
|
||
jobs: | ||
build_wheels: | ||
name: Build wheels on ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest, windows-latest, macos-13,macos-14] # was macos-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Build wheels | ||
uses: pypa/cibuildwheel@v2.22.0 | ||
env: # | ||
MACOSX_DEPLOYMENT_TARGET: "10.15" # | ||
# CIBW_SOME_OPTION: value | ||
# ... | ||
#with: | ||
# package-dir: . | ||
# output-dir: wheelhouse | ||
# config-file: "{package}/pyproject.toml | ||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }} | ||
path: ./wheelhouse/*.whl | ||
build_sdist: | ||
name: Build source distribution | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Build sdist | ||
run: pipx run build --sdist | ||
|
||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: cibw-sdist | ||
path: dist/*.tar.gz | ||
|
||
|
||
- uses: actions/upload-artifact@v4 | ||
with: | ||
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }} | ||
path: ./wheelhouse/*.whl |
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,42 @@ | ||
### C++ template | ||
# Prerequisites | ||
*.d | ||
|
||
# Compiled Object files | ||
*.slo | ||
*.lo | ||
*.o | ||
*.obj | ||
|
||
# Precompiled Headers | ||
*.gch | ||
*.pch | ||
|
||
# Compiled Dynamic libraries | ||
*.so | ||
*.dylib | ||
*.dll | ||
|
||
# Fortran module files | ||
*.mod | ||
*.smod | ||
|
||
# Compiled Static libraries | ||
*.lai | ||
*.la | ||
*.a | ||
*.lib | ||
|
||
# Executables | ||
*.exe | ||
*.out | ||
*.app | ||
|
||
### Example user template template | ||
### Example user template | ||
|
||
# IntelliJ project files | ||
.idea | ||
*.iml | ||
out | ||
gen |
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,25 @@ | ||
cmake_minimum_required(VERSION 3.19) | ||
|
||
project(VBMicrolensing LANGUAGES CXX) | ||
|
||
set(CMAKE_CXX_STANDARD 17) | ||
set(CMAKE_CXX_STANDARD_REQUIRED ON) | ||
if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") | ||
set(MINIMUM_GCC_VERSION "9.0") | ||
if(CMAKE_CXX_COMPILER_VERSION VERSION_LESS MINIMUM_GCC_VERSION) | ||
message(FATAL_ERROR "GCC must be ${MINIMUM_GCC_VERSION} or greater.") | ||
endif() | ||
endif() | ||
|
||
# Find the module development requirements (requires FindPython from 3.17 or | ||
# scikit-build-core's built-in backport) | ||
find_package(Python REQUIRED COMPONENTS Interpreter Development.Module) | ||
find_package(pybind11 CONFIG REQUIRED) | ||
|
||
# Add a library using FindPython's tooling (pybind11 also provides a helper like | ||
# this) | ||
python_add_library(VBMicrolensing MODULE VBMicrolensing/lib/python_bindings.cpp VBMicrolensing/lib/VBMicrolensingLibrary.cpp VBMicrolensing/lib/VBMicrolensingLibrary.h) | ||
target_link_libraries(VBMicrolensing PRIVATE pybind11::headers) | ||
|
||
# The install directory is the output (wheel) directory | ||
install(TARGETS VBMicrolensing DESTINATION VBMicrolensing) |
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,2 +1,2 @@ | ||
graft VBMicrolensing/lib | ||
include VBMicrolensing/data/*.* | ||
graft VBMicrolensing/data |
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 +1,8 @@ | ||
from .VBMicrolensing import VBMicrolensing | ||
from .VBMicrolensing import VBMicrolensing | ||
|
||
import inspect | ||
import os | ||
|
||
_fil_in=inspect.getfile(VBMicrolensing) | ||
VBMicrolensing.SetESPLtablefile(os.path.join(os.path.join(os.path.dirname(_fil_in), 'data'), 'ESPL.tbl')) | ||
|
Oops, something went wrong.