diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..6e0e882 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,50 @@ +name: CI Wheel building test + +on: + pull_request: + branches: [main, develop] + push: + branches: [main, develop, ci_build] + +jobs: + build_linux: + runs-on: $${{ matrix.os }} + strategy: + matrix: + python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"] + os: ["ubuntu-latest", "ubuntu-24.04-arm"] + + steps: + - uses: actions/checkout@v4 + - name: set up python ${{ matrix.python-version }} + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} + - name: Install ubuntu dependencies + run: | + sudo apt-get update + sudo apt-get install -y build-essential cmake libhdf5-dev libtiff-dev + - name: Configure Cmake and build + run: | + cmake -D mcnptools.python_install=User . + cmake --build . --config Release + - name: Test C++ side + run: ctest --build-config Release + - name: build wheel + run: | + cd python + pip install build + python -m build . + - name: test install wheel + run: pip install python/dist/*.whl + - name: Upload build artifacts + uses: actions/upload-artifact@v4 + with: + name: wheel-linux-$${{ matrix.os }}-${{ matrix.python-version }} + path: python/dist/*.whl + - name: Upload Source tar bal + uses: actions/upload-artifact@v4 + if: ${{ matrix.python-version == '3.12'}} + with: + name: linux_source + path: python/dist/*.gz diff --git a/.gitignore b/.gitignore index 00bdb77..94b4d66 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,40 @@ *~ *.bak *.sw? + +# cmake artifacts +CMakeCache.txt +CMakeFiles/ +CTestTestfile.cmake +*.tcl +Makefile +*.cmake +*.a +*.so +*.unix + +# testing artifacts +Testing/ +git-submodule-packages/ +lib/ +libmcnptools/tests/ +*.vts + + +# python build artifacts +python/build +python/dist +python/setup.py +python/setup.py_configure +python/mcnptools.egg-info + +# Build executables +libmcnptools/include/mcnptools/MCNPTools_Config.hpp +utils/l3d2vtk/l3d2vtk +utils/l3dcoarsen/l3dcoarsen +utils/l3dinfo/l3dinfo +utils/l3dscale/l3dscale +utils/mctal2rad/mctal2rad +utils/mergemctals/mergemctals +utils/mergemeshtals/mergemeshtals +utils/meshtal2vtk/meshtal2vtk