soci icon indicating copy to clipboard operation
soci copied to clipboard

Make CMake subdirectory usage easier

Open samh opened this issue 3 years ago • 1 comments

These tweaks will allow users to use SOCI as a subdirectory with CMake the same way as if they had called find_package (targets in the SOCI:: namespace, and no additional call to target_include_directories).

Everything should be backwards-compatible - the internal non-namespace targets continue to work as they did before, and if someone used target_include_directories as before it wouldn't break anything.

I also updated the documentation and examples to reflect the simplified usage.

Please let me know if you have any comments or want me to change anything. Thanks!

samh avatar Aug 05 '22 20:08 samh

The new way to use SOCI in a subdirectory is definitely much nicer to me than the old one, thanks for improving this!

If there are no objections, I'm going to merge this in a couple of days.

Thanks again!

vadz avatar Aug 05 '22 22:08 vadz

Any news/update on this? :)

Tectu avatar Sep 14 '22 09:09 Tectu

You're right, this should have been merged already -- done now.

vadz avatar Sep 14 '22 11:09 vadz