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

[FEATURE] C++ version specification at the package level #121

Open
oraqlle opened this issue Apr 24, 2022 · 0 comments
Open

[FEATURE] C++ version specification at the package level #121

oraqlle opened this issue Apr 24, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@oraqlle
Copy link

oraqlle commented Apr 24, 2022

I had the curious idea that I wanted to play out. BPT resembles a lot of the structure I've seen using cargo for Rust. That being said, their is a feature of cargo that I think would make BPT really stand out and would be useful for all kinds of builds and it has to do with the language standard used by the compiler.

To my knowledge, crates in cargo have to have a year label for which version of Rust to use (2018, 2021 ... etc.). What this allows is that crates are compiled separately as much as they can until they are linked together, allowing packages on different versions of the language to work together because at a certain point, the object code (or whatever the intimidate files contain during compilation of a Rust project) is all the same and the version of the language doesn't matter then.

I was curious if this would be possible with a tool such as BPT where individual packages could specify the version of the C++ standard it uses and compile it to a point where the versions between packages and your project doesn't matter.

If it could be done, I think it would be super useful, particular with projects that have a lot of legacy code that is hard to change but want to adopt modern versions of C++ for new extensions of a package.

I do not know how this could work and includes but make the process troublesome and I know specific and customized toolchains can be used to configure a build (at least in the alpha.6 version of BPT (DDS) I'm using) but this could be a automated way to do so. It might only be possible with C++20 modules but who knows. Just some food for thought.

@oraqlle oraqlle added the enhancement New feature or request label Apr 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant