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
add cmake #22
base: master
Are you sure you want to change the base?
add cmake #22
Conversation
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.
What's the rationale of having cmake? Having two build systems here has a risk of one getting changed while other not. Could prefer having just one, but still not entirely convinced if switching these simple qmake projects has more pros than cons.
Regardless of that, the commit set isn't clean. Adds first some cmake include things, and only after that add the build system, and later doing changes back an forth, including one revert. All the cmake changes should be squashed into a single commit.
|
|
||
| # vscode | ||
| .vscode | ||
| .vscode |
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.
That's twice the same line and the comment doesn't add value if it repeats the same thing too.
| set(CMAKE_CXX_STANDARD 17) | ||
| set(CMAKE_CXX_STANDARD_REQUIRED ON) | ||
|
|
||
| find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS DBus) |
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.
Assuming this works if either or both are installed, this feels still somewhat hazy way to decide what's getting built. I could maybe expect somwhat more explicit config for choosing qt version.
| @@ -21,6 +21,10 @@ | |||
| #include <networkservice.h> | |||
| #include <QtCore> | |||
|
|
|||
| #ifndef endl | |||
| #define endl "\n" | |||
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.
We shouldn't define yet another endl. Suppose std::endl was expected used in this file.
| @@ -8,7 +8,12 @@ | |||
| */ | |||
|
|
|||
| #include "clockmodel.h" | |||
|
|
|||
| #ifdef CONNMANQT_CMAKE | |||
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.
The build system shouldn't leak into headers.
No description provided.