-
Notifications
You must be signed in to change notification settings - Fork 216
Improvements to CMake builds on Windows #326
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We no longer need this!
| @@ -1,4 +1,4 @@ | |||
| cmake_minimum_required(VERSION 3.16) | |||
| cmake_minimum_required(VERSION 3.21) | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TARGET_RUNTIME_DLLS is a 3.21 feature.
cpp/cmake/IceConfig.cmake
Outdated
| set(Ice_SOURCE_BUILD ON) | ||
| endif() | ||
|
|
||
| if(Ice_SOURCE_BUILD) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For other languages we are no longer supporting to use the source build.
|
|
||
| if (WIN32) | ||
| set(Ice_NUGET_NAME "zeroc.ice.v143") | ||
| set(Ice_NUGET_DIR "${CMAKE_CURRENT_LIST_DIR}/packages/${Ice_NUGET_NAME}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guessing that I can use a custom NuGet build by just installing it to this location, which would skip the install below.
cpp/cmake/IceConfig.cmake
Outdated
| list(APPEND ice_lib_path_suffixes_release "cpp/lib") | ||
| list(APPEND ice_lib_path_suffixes "cpp/lib") | ||
|
|
||
| if (Ice_ARCHITECTURE) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is Ice_ARCHITECTURE and when is it not-set?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's computed from a few values (see above).
- If
CMAKE_LIBRARY_ARCHITECTUREis set we use it. For example this is set on Ubuntu to something like "x86_64-linux-gnu" - Otherwise if not set and we're on Windows we'll set it to either x64 or Win32
It's fine if it's not set. It's a matter of checking lib vs lib/<arch>. For instance it's not set on macOS.
This PR adds several improvements for the CMake builds on Windows.
cpp/cmake/packages