cmake: Include include directory for subtree builds

This commit is contained in:
Hennadii Stepanov 2023-04-21 12:03:26 +01:00
parent 5431b9decd
commit 71f746c057
No known key found for this signature in database
GPG Key ID: 410108112E7EA81F

View File

@ -31,7 +31,9 @@ endif()
get_target_property(use_pic secp256k1 POSITION_INDEPENDENT_CODE)
set_target_properties(secp256k1_precomputed PROPERTIES POSITION_INDEPENDENT_CODE ${use_pic})
target_include_directories(secp256k1 PUBLIC
target_include_directories(secp256k1 INTERFACE
# Add the include path for parent projects so that they don't have to manually add it.
$<BUILD_INTERFACE:$<$<NOT:$<BOOL:${PROJECT_IS_TOP_LEVEL}>>:${PROJECT_SOURCE_DIR}/include>>
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
)
set_target_properties(secp256k1 PROPERTIES