diff --git a/.github/workflows/build_wheels.yml b/.github/workflows/build_wheels.yml index 43dc6e26..0b587263 100644 --- a/.github/workflows/build_wheels.yml +++ b/.github/workflows/build_wheels.yml @@ -72,7 +72,7 @@ jobs: matrix: os: - ubuntu-latest - - windows-2019 + - windows-2022 - macos-13 # Uses x64 - macos-14 # Uses Apple Silicon @@ -89,6 +89,24 @@ jobs: core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || ''); core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || ''); + - name: Setup msbuild on Windows + if: runner.os == 'Windows' + uses: microsoft/setup-msbuild@v2 + + - name: Setup ninja on Windows + if: runner.os == 'Windows' + uses: ashutoshvarma/setup-ninja@v1.1 + + - name: Enable developer command prompt + if: runner.os == 'Windows' + uses: ilammy/msvc-dev-cmd@v1 + + - name: install pkgconfig on windows + if: runner.os == 'Windows' + shell: bash + run: | + choco install pkgconfiglite + - name: Install build deps on MacOs if: runner.os == 'macOs' run: brew install autoconf automake libtool m4 ninja @@ -98,18 +116,19 @@ jobs: env: MACOSX_DEPLOYMENT_TARGET: 11.0.0 GITHUB_TOK: "${{ secrets.GITHUB_TOKEN }}" + CMAKE_GENERATOR: "Ninja" - uses: actions/upload-artifact@v4 with: name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }} path: ./wheelhouse/*.whl - - publish: + runs-on: ubuntu-latest needs: [ build_wheels, build_sdist ] if: ${{ github.event_name == 'push' }} + steps: - name: Setup Python uses: actions/setup-python@v5 diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 9926140b..7c415641 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -79,11 +79,6 @@ jobs: core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || ''); core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || ''); - - name: use ninja - shell: bash - run: | - echo "CMAKE_GENERATOR=Ninja" >> $GITHUB_ENV - - name: Setup msbuild on Windows if: runner.os == 'Windows' uses: microsoft/setup-msbuild@v2 @@ -127,6 +122,7 @@ jobs: CMAKE_TOOLCHAIN_FILE: ${{ github.workspace }}/tools/vcpkg/scripts/buildsystems/vcpkg.cmake MACOSX_DEPLOYMENT_TARGET: 11.0.0 VCPKG_FORCE_SYSTEM_BINARIES: 1 + CMAKE_GENERATOR: "Ninja" - name: Build # Build your program with the given configuration diff --git a/CMakeLists.txt b/CMakeLists.txt index 1e92c84d..33156818 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -211,6 +211,30 @@ add_subdirectory(streams) if (ROUGHPY_BUILD_PYLIB) add_subdirectory(roughpy) + + + install(TARGETS RoughPy_PyModule + RUNTIME DESTINATION roughpy + LIBRARY + DESTINATION roughpy + NAMELINK_SKIP + ARCHIVE DESTINATION ${SKBUILD_NULL_DIR} + COMPONENT Development + EXCLUDE_FROM_ALL + INCLUDES DESTINATION ${SKBUILD_NULL_DIR} + COMPONENT Development + FRAMEWORK DESTINATION roughpy + EXCLUDE_FROM_ALL + ) + + install(DIRECTORY roughpy + DESTINATION . + FILES_MATCHING + PATTERN "py.typed" + PATTERN "*.py" + PATTERN "*.pyi" + PATTERN "src/*" EXCLUDE) + endif () @@ -225,6 +249,7 @@ install(TARGETS RoughPy_Scalars RoughPy_Algebra RoughPy_Streams + Libalgebra_lite EXPORT RoughPy_EXPORTS RUNTIME DESTINATION roughpy LIBRARY diff --git a/roughpy/CMakeLists.txt b/roughpy/CMakeLists.txt index c7f5348e..446966bb 100644 --- a/roughpy/CMakeLists.txt +++ b/roughpy/CMakeLists.txt @@ -198,29 +198,6 @@ configure_file(version.py.in ${CMAKE_CURRENT_LIST_DIR}/version.py @ONLY) -install(TARGETS RoughPy_PyModule - RUNTIME DESTINATION roughpy - LIBRARY - DESTINATION roughpy - NAMELINK_SKIP - ARCHIVE DESTINATION ${SKBUILD_NULL_DIR} - COMPONENT Development - EXCLUDE_FROM_ALL - INCLUDES DESTINATION ${SKBUILD_NULL_DIR} - COMPONENT Development - FRAMEWORK DESTINATION roughpy - EXCLUDE_FROM_ALL -) - -install(FILES roughpy/py.typed DESTINATION roughpy) -install(DIRECTORY roughpy - DESTINATION . - FILES_MATCHING - PATTERN "*.py" - PATTERN "*.pyi" - PATTERN "src/*" EXCLUDE) - - diff --git a/tools/ci/before-all-common.sh b/tools/ci/before-all-common.sh index db544edd..e49acdd9 100644 --- a/tools/ci/before-all-common.sh +++ b/tools/ci/before-all-common.sh @@ -27,40 +27,8 @@ # USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # -echo $OSTYPE -if [[ "$OSTYPE" == "linux-gnu"* ]]; then - yum install -y curl zip unzip tar gmp-devel - # manylinux doesn't have mono, we'll have to install it - rpmkeys --import "http://keyserver.ubuntu.com/pks/lookup?op=get&search=0x3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF" - su -c 'curl https://download.mono-project.com/repo/centos7-stable.repo | tee /etc/yum.repos.d/mono-centos7-stable.repo' - yum install -y mono-complete - MONO_EXE=mono -elif [[ "$OSTYPE" == "darwin"* ]]; then - brew install libomp - MONO_EXE=mono -elif [[ "$OSTYPE" == "msys"* ]]; then - MONO_EXE="" -else - exit 1 -fi +git clone https://github.com/Microsoft/vcpkg.git tools/vcpkg +bash tools/vcpkg/bootstrap-vcpkg.sh -disableMetrics -git clone https://github.com/Microsoft/vcpkg.git -bash vcpkg/bootstrap-vcpkg.sh -disableMetrics - -vcpkg_root=./vcpkg - -#if [ -n "$GITHUB_TOK" ]; then -# # If the token is defined, set up binary caching -# $MONO_EXE `$vcpkg_root/vcpkg fetch nuget | tail -n 1` \ -# sources add \ -# -source "https://nuget.pkg.github.com/datasig-ac-uk/index.json" \ -# -storepasswordincleartext \ -# -name "GitHub" \ -# -username "datasig-ac-uk" \ -# -password "$GITHUB_TOK" -# $MONO_EXE `$vcpkg_root/vcpkg fetch nuget | tail -n 1` \ -# setapikey "$GITHUB_TOK" \ -# -source "https://nuget.pkg.github.com/datasig-ac-uk/index.json" -#fi diff --git a/vcpkg.json b/vcpkg.json index ac3f00c3..32b57f5e 100644 --- a/vcpkg.json +++ b/vcpkg.json @@ -49,9 +49,6 @@ }, { "name" : "opencl", "version>=" : "v2024.05.08" - }, { - "name" : "boost-stacktrace", - "version>=" : "1.83.0" }, { "name" : "range-v3", "version>=" : "0.12.0#4"