Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bump CMAKE_CXX_STANDARD as 17 globally (#5612)
### Description <!-- - Describe your changes. --> - Bump CMAKE_CXX_STANDARD as 17 globally (Windows and non-Windows). - Update README.md accordingly. ### Motivation and Context <!-- - Why is this change required? What problem does it solve? --> <!-- - If it fixes an open issue, please link to the issue here. --> Currently by default onnx uses CMAKE_CXX_STANDARD 17 on Windows, but by contrast it uses CMAKE_CXX_STANDARD 14 on other platforms. It's a bit confusing. Also it blocks onnx utilizing C++ 17 features. Trying this PR to verify ONNX CI Pipelines with this update. If no one has other concern, we will target next release (possibly 1.16) to include this CMAKE_CXX_STANDARD bump. Users who build their onnx from their own are still able to specify their own CMAKE_CXX_STANDARD version. Anyone has any question/concern, feel free to chime in. Thanks! <!-- copilot:all --> ### <samp>🤖 Generated by Copilot at a1c07ad</samp> ### Summary 🧹🔄📝 <!-- 1. 🧹 - This emoji represents the simplification and cleanup of the CMake logic for setting the C++ standard version. 2. 🔄 - This emoji represents the consistency and alignment of the C++ standard version across platforms and the possibility of overriding it with a custom value. 3. 📝 - This emoji represents the documentation update in the README.md file. --> Simplify and unify the C++ standard version setting for ONNX. Update the `README.md` file accordingly. > _`CMAKE_CXX_STANDARD`_ > _Simpler and consistent now_ > _Autumn of cleanup_ ### Walkthrough * Simplify CMake logic for setting C++ standard version ([link](https://github.com/onnx/onnx/pull/5612/files?diff=unified&w=0#diff-1e7de1ae2d059d21e1dd75d5812d5a34b0222cef273b7c3a2af62eb747f9d20aL58-R59)) * Update README documentation to match CMake changes ([link](https://github.com/onnx/onnx/pull/5612/files?diff=unified&w=0#diff-b335630551682c19a781afebcf4d07bf978fb1f8ac04c6bf87428ed5106870f5L114-R114)) --------- Signed-off-by: Chun-Wei Chen <jacky82226@gmail.com> Co-authored-by: Xavier Dupré <xadupre@users.noreply.github.com> Co-authored-by: G. Ramalingam <grama@microsoft.com>
- Loading branch information