Skip to content
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

support vc runtime static linkage #472

Merged
merged 5 commits into from
Jun 20, 2023
Merged

support vc runtime static linkage #472

merged 5 commits into from
Jun 20, 2023

Conversation

wenbingl
Copy link
Member

No description provided.

@wenbingl wenbingl marked this pull request as ready for review June 14, 2023 18:19
@wenbingl wenbingl requested a review from a team as a code owner June 14, 2023 18:19
@wenbingl wenbingl requested a review from snnn June 14, 2023 18:19

steps:
- script: |
call .\build.bat -DOCOS_ENABLE_CTEST=ON -DCMAKE_MSVC_RUNTIME_LIBRARY="MultiThreaded$<$<CONFIG:Debug>:Debug>"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the argument string seems not to be easily used, any better idea?

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one could use a cmake option ... ;D

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that could be a solution, but I noticed what protobuf did the same thing actually brought us some trouble to add some extra code to switch the flag back and forth, especially when ort-extensions was used as cmake sub-directory for another project.

DCMAKE_MSVC_RUNTIME_LIBRARY is documented feature from cmake and it's kind of a standard that we should follow.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we could perhaps add a magic string to replace "MultiThreaded$<$CONFIG:Debug:Debug>" so it is simple for the user when passing the parameter for DCMAKE_MSVC_RUNTIME_LIBRARY to build.bat - and then we can parse it in the YAML file.

@wenbingl
Copy link
Member Author

Merge this fixing firstly, and any further improvement are welcomed.

@wenbingl wenbingl merged commit a6012b3 into main Jun 20, 2023
@wenbingl wenbingl deleted the vcstat branch June 20, 2023 23:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants