use the default CMAKE_PLATFORM generator on make windows; switch to Ninja make make windows and cmake windows python github actions

This commit is contained in:
Laurent Perron
2022-02-24 22:35:18 +01:00
parent 5d90abeab7
commit 809deba3dc
6 changed files with 14 additions and 9 deletions

View File

@@ -11,6 +11,7 @@ jobs:
- uses: actions/setup-python@v2
with:
python-version: '3.9'
- uses: seanmiddleditch/gha-setup-ninja@master
- name: Install python3
run: python3 -m pip install --user mypy-protobuf absl-py setuptools wheel numpy pandas
- name: Install SWIG 4.0.2
@@ -25,7 +26,7 @@ jobs:
- name: Check cmake
run: cmake --version
- name: Configure
run: cmake -S. -Bbuild -G "Visual Studio 17 2022" -DCMAKE_BUILD_TYPE=Release -DBUILD_PYTHON=ON -DBUILD_CXX_SAMPLES=OFF -DBUILD_CXX_EXAMPLES=OFF
run: cmake -S. -Bbuild -G Ninja -DCMAKE_BUILD_TYPE=Release -DBUILD_PYTHON=ON -DBUILD_CXX_SAMPLES=OFF -DBUILD_CXX_EXAMPLES=OFF
- name: Build
run: cmake --build build --config Release --target ALL_BUILD -v -- /maxcpucount
- name: Test

View File

@@ -9,14 +9,15 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: ilammy/msvc-dev-cmd@v1
- uses: seanmiddleditch/gha-setup-ninja@master
- name: Check make
run: tools\make --version
- name: Check system
run: tools\make detect_port
- name: Build third party
run: tools\make third_party BUILD_PYTHON=OFF BUILD_JAVA=OFF BUILD_DOTNET=OFF
run: tools\make third_party BUILD_PYTHON=OFF BUILD_JAVA=OFF BUILD_DOTNET=OFF GENERATOR=Ninja
- name: Build C++
run: tools\make compile_libraries -j4
run: tools\make all JOBS=4
- name: Test C++
run: tools\make test_cc
- name: Install

View File

@@ -9,6 +9,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: ilammy/msvc-dev-cmd@v1
- uses: seanmiddleditch/gha-setup-ninja@master
# Install .NET SDKs
- name: Setup .NET Core 3.1
uses: actions/setup-dotnet@v1
@@ -29,7 +30,7 @@ jobs:
- name: Build third party
run: tools\make third_party BUILD_PYTHON=OFF BUILD_JAVA=OFF BUILD_DOTNET=ON
- name: Build C++ and .NET
run: tools\make compile_libraries -j4
run: tools\make all JOBS=4
- name: Test .Net
run: tools\make test_dotnet -j4
- name: Create nuget packages

View File

@@ -9,6 +9,7 @@ jobs:
steps:
- uses: actions/checkout@v2
- uses: ilammy/msvc-dev-cmd@v1
- uses: seanmiddleditch/gha-setup-ninja@master
- name: Check java
run: java -version
- name: Check make
@@ -20,7 +21,7 @@ jobs:
- name: Build third party
run: tools\make third_party BUILD_PYTHON=OFF BUILD_JAVA=ON BUILD_DOTNET=OFF
- name: Build C++ and Java
run: tools\make compile_libraries -j4
run: tools\make all JOBS=4
- name: Test Java
run: tools\make test_java -j4
- name: Create maven package

View File

@@ -10,8 +10,9 @@ jobs:
- uses: actions/checkout@v2
- uses: ilammy/msvc-dev-cmd@v1
- uses: actions/setup-python@v2
- uses: seanmiddleditch/gha-setup-ninja@master
with:
python-version: '3.9'
python-version: '3.9'
- name: Install python3
run: python3 -m pip install --user mypy-protobuf absl-py setuptools wheel numpy pandas
- name: Check make
@@ -21,9 +22,9 @@ jobs:
- name: Check Python
run: tools\make detect_python
- name: Build third party
run: tools\make third_party BUILD_PYTHON=ON BUILD_JAVA=OFF BUILD_DOTNET=OFF
run: tools\make third_party BUILD_PYTHON=ON BUILD_JAVA=OFF BUILD_DOTNET=OFF GENERATOR=Ninja
- name: Build C++ and Python
run: tools\make compile_libraries -j4
run: tools\make all JOBS=4
- name: Build Python
run: tools\make python -j4
- name: Test Python

View File

@@ -24,7 +24,7 @@ dependencies:
third_party: dependencies/ortools.sln | dependencies
THIRD_PARTY_TARGET = dependencies/ortools.sln
GENERATOR ?= "MMake Makefiles"
GENERATOR ?= $(CMAKE_PLATFORM)
dependencies/ortools.sln: | dependencies
cmake -S . -B dependencies -DBUILD_DEPS=ON \