[cmake] FindRapidJSON update to newer module standards #23851
Merged
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.
Description
Update FindRapidJSON to newer "standard" usage ive been implementing.
Motivation and context
This allows us to find an existing RapidJSON and not "rebuild" every time for platforms. Its a header only lib, so build time isnt really a factor, but it just feels better to standardise on what ive settled on for finding/assessing existing libs and internal builds.
We also remove the hardcoded spec requirement back into the root CMakeLists.txt file. Im endeavouring to have any hard version requirements listed in the one place, rather than scattered throughout a bunch of find modules. Should make it easier for outsiders to quickly see minimum dependency versions
How has this been tested?
Macos aarch64 - with and without existing rapidjson cmake config/headers
windows x64 - with and without existing rapidjson cmake config/headers
What is the effect on users?
N/A
Screenshots (if appropriate):
Types of change
Checklist: