build: Add support for CMake builds#89
Conversation
|
Hi, The cmake install method installs far more header files than the linux install - at present the linux install only adds sufficient for using the c-api based library. There is also no uninstall option within the cmake solution In short, what you have provided may be sufficient for build into a larger project - adding cmake to the library should also allow a standalone build that produces the same results as the existing build. Regards Mike |
|
I've added an update on top of your original patch. Please look at and see if your requirements are still met. I do not think this is yet tested enough for the main upstream branch so may have to miss the next release. Mike |
Thanks for the feedback, Mike! I have just pushed a new commit that addresses your points regarding restricted header installation and the addition of the uninstall target. I have verified that these changes work on macOS, Linux, and Windows. Can you please clarify where exactly you pushed an update on top of my patch, as I was not able to find it in the PR commits or branches? |
|
@mikel-armbb when is the upcoming release planned? |
|
My updates are in an rc branch - ocsd-main-1.8.2-rc1 |
1) Add a root CMakeLists.txt file to provide cross-platform build support, making it easier to link against OpenCSD in large external projects. 2) Generate native CMake package files using OpenCSDConfig.cmake.in template.
|
I've moved the cmake development onto ocsd-main-1.8.3-rc1 which will be pushed shortly. I didn't want to delay a decoder fix which is to go out as 1.8.2. |
Thanks @mikel-armbb. Could you please incorporate the latest version of my changes into the |
|
The second patch does not apply cleanly to ocsd-main-1.8.3-rc1 |
CMake linux build updated to match the existing makefiles full project build by default. CMake windows build updated to ensure full windows build works. Option to build only the static libs retained. Added docs to explain CMake use. Added python helper script to drive cmake tools on each platform for ease of testing CMake builds. Signed-off-by: Mike Leach <mike.leach@arm.com>
In the python test script ensure that only options after '--' are passed through to the trc_pkt_lister program. Unknown options before this will now result in a error and the script will fail Signed-off-by: Mike Leach <mike.leach@arm.com>
Signed-off-by: Mike Leach <mike.leach@arm.com>
6ec9b72 to
9338a17
Compare
I've resolved the merge conflicts. Could you please try again? |
9338a17 to
a5006b5
Compare
1) Restrict installed headers to match the Makefile, ensuring only sufficient headers for using the C-API are installed. 2) Add an uninstall target to allow removing installed files. 3) Resolve parallel build race conditions and target link failures.
a5006b5 to
c1e1d7d
Compare
Add a root CMakeLists.txt file to provide cross-platform build support, making it easier to link against OpenCSD in large external projects.
Generate native CMake package files using OpenCSDConfig.cmake.in template.