Another round of CMake improvements#8
Open
adriaandegroot wants to merge 9 commits intofredldotme:masterfrom
Open
Another round of CMake improvements#8adriaandegroot wants to merge 9 commits intofredldotme:masterfrom
adriaandegroot wants to merge 9 commits intofredldotme:masterfrom
Conversation
It should be possible to build a specific (Qt5 or 6) version of the library in the presence of both, without automatically finding both. There's CMake machinery for this already (CMAKE_DISABLE_FIND_PACKAGE_*) but that is hard-to-find and sometimes difficult to spell.
This avoids confusing cmake-time errors from subdirectories that can't use Qt facilities then.
Don't install all headers, though (as previously with CMake), leave private and unnecessary ones out.
When building as part of QWebdav, we need a different way to get the library alias (preferring Qt6).
CMake-based build places them in /usr/include/qt6/qwebdav-qt6/ QMake-based build places them in /usr/include/x86_64-linux-gnu/qt6/qwebdav-qt6 This may also be a triple (on the part of qmake) to help support multiple architectures binaries packaged and installed on the same host. Tweaking it is outside the scope of this MR.
Author
|
Note: This is a MR in-progress. There's still some tricksy bits with getting the right headers in the right places from the resulting |
Owner
|
Let me know when this is ready. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This massages the CMake files again, so that they do install one copy of the headers per Qt version. The reason to do this is Linux distro's that ship separate
-devpackages which also ship multiple copies of this library that are compiled for different Qt versions (e.g. qwebdavlib-qt5 and qwebdavlib-qt6). There are two separate-devpackages, which depend on the respective library packages. Those obviously can't install headers to the same location, so just do the thing upstream, even if it feels like "this is just duplicating files on the target system".OTOH, why would you want a Qt5 version of this anymore.