iTwin / imodel-native

Apache License 2.0
20 stars 12 forks source link

Support c++20 #133

Closed calebmshafer closed 1 year ago

calebmshafer commented 1 year ago

Currently only support c++17 as that is the highest version we can compile with on our Linux machines, due to them being on Debian 9.

There is a BUILD_WITH_C20 environment variable that can be set to compile with it locally to fix all of the current issues.

The tasks to accomplish to support c++20;

Testing with c++20 today

If you set BUILD_WITH_C20 in the environment you can tell it to try to build with C++20. I think it will take some effort before we can move.

swbsi commented 1 year ago

@aruniverse @chuckkir @jffmarker

This is blocked until the NDK is updated to r25c.

Also, based on the results of the imodel-native-internal iOS build in my PR, it looks like we also need to update to xCode 14 to get c++20 compiler support on our Mac-based builds.

swbsi commented 1 year ago

Once the NDK is updated, these are the bsicommon changes: https://dev.azure.com/bentleycs/iModelTechnologies/_git/bsicommon-imt/pullrequest/324614

swbsi commented 1 year ago

Windows and Linux are building in my imodel-native-internal PR. We just need the mobile platforms, now.

swbsi commented 1 year ago

FYI, I verified this morning that the mac addon and the ios framework both build successfully with Xcode 14.2 on my local machine. I had previous verified that the android package built locally with the r25c NDK.

So, as soon as we get the build machines updated, we should be able to complete the C++20 PRs.