Implement CMake interface library, install rules#21
Open
craftablescience wants to merge 2 commits intoiOrange:mainfrom
Open
Implement CMake interface library, install rules#21craftablescience wants to merge 2 commits intoiOrange:mainfrom
craftablescience wants to merge 2 commits intoiOrange:mainfrom
Conversation
Owner
|
Hi! |
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 PR adds an installable interface library to the existing CMake script. You can try it by running:
After running this command, bcdec will be accessible from other CMake projects using
find_package(bcdec).Test code and the bcdec header were split for convenience of writing the installer, and because some projects want to add the folder containing the bcdec header to include directory list but ship with their own copy of
stb_image_write. No install rules are created for the test executable currently, let me know if that is desired.The CMake version being bumped to 3.21 was necessary for
PROJECT_IS_TOP_LEVEL, let me know if this is too high and I can lower it (but it will look less clean). 3.8 was already giving me warnings about deprecation on CMake 3.31, so this should be for the best for future compatibility regardless.