-
-
Notifications
You must be signed in to change notification settings - Fork 365
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
Improving CMakeLists.txt #96
Conversation
- Added options BUILD_EXAMPLES and BUILD_TESTING to switch examples on/off during compilationusing standard CMake variable to set the C++ Standard, independently from the compiler - Using OpenSSL only if BUILD_EXAMPLES are activated, since it's required by Boost ASIO only at runtime as dynamic library
Hi, Thanks a lot for the help. Regarding the C++ version, while crow does support C++11 at the moment (by altering some functionality), the plan was to use C++14 features if needed, reading conan-io/conan-center-index#4085 (comment) I understand the reason. @mrozigor would this change cause problems? As for the release tag, the plan is to finish #84 and #93 and release v0.3, by Monday at the absolute latest. Is that okay? or should we create an intermediate release and then another once the PRs are merged? |
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.
Looks good 👍
Hi @The-EDev |
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.
There's also some outdate CMake
https://stackoverflow.com/a/24470998/8480874
I would suggestion just removing those lines in question
Sure, but I didn't want to do massive changes all at once. |
Probably not until we use something 14 dependent ;) |
I think it a simple change (removing that one line). If you improve CMakeLists.txt, then go for it ;) |
Ok then I would do a couple of improvements |
@mrozigor @The-EDev I've upgraded the CMake, now Examples and Tests are enabled by default again, but they can be turned off ( I've added the equivalent of -Wall for MSVC (/W4) and some optimization flags, for tests and examples. The compiler flags and the dependencies are now grouped in two separated files, to have a better overview of what is required. Tell me if the PR fits your project, feel free to give me the feedbacks on that and how can I improve it. |
Hi @mrozigor thanks for the review. I've bumped Boost to version 1.64.0 since on some systems the latest versions could not be available, what do you think? |
Ok, I think that's reasonable ;) Good work. |
example_ssl won't be built if OpenSSL is not found: a status message will be shown instead
I know I'm very late to the party, but this could be a problem, we discussed it in #29, this version of crow (as far as i know) does not work with boost<1.70 |
Hello
as suggested by Conan team, I've made some changes to the CMakeLists to make it better supported by conan recipes (but also by other package managers as well), using only what's needed and enabling/disabling tests and examples.
Here's a short list of what I'm trying to change upstream:
CMAKE_CXX_STANDARD
to set the C++ Standard, independently from the compilerThe Conan recipe is going under review here: conan-io/conan-center-index#4085
If this change is merged in the master branch, I'd kindly ask you to make a new Release tag, so it can be used in the Conan recipe as well.