2021-01-08 12:56:04 -05:00
|
|
|
# Add include folders to the library and targets that consume it
|
|
|
|
# the SYSTEM keyword suppresses warnings for users of the library
|
|
|
|
#
|
|
|
|
# By adding this directory as an include directory the user gets a
|
|
|
|
# namespace effect.
|
|
|
|
#
|
|
|
|
# IE:
|
|
|
|
# #include <gsl/gsl>
|
2022-10-18 14:05:09 -04:00
|
|
|
if(PROJECT_IS_TOP_LEVEL)
|
|
|
|
target_include_directories(GSL INTERFACE $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>)
|
2021-01-08 12:56:04 -05:00
|
|
|
else()
|
2022-10-18 14:05:09 -04:00
|
|
|
target_include_directories(GSL SYSTEM INTERFACE $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>)
|
2021-01-08 12:56:04 -05:00
|
|
|
endif()
|