summaryrefslogtreecommitdiffstats
path: root/cmake/SlangTarget.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake/SlangTarget.cmake')
-rw-r--r--cmake/SlangTarget.cmake7
1 files changed, 7 insertions, 0 deletions
diff --git a/cmake/SlangTarget.cmake b/cmake/SlangTarget.cmake
index 44d6c945c..cb4443d0e 100644
--- a/cmake/SlangTarget.cmake
+++ b/cmake/SlangTarget.cmake
@@ -241,6 +241,13 @@ function(slang_add_target dir type)
PUBLIC "${ARG_EXPORT_MACRO_PREFIX}_DYNAMIC"
PRIVATE "${ARG_EXPORT_MACRO_PREFIX}_DYNAMIC_EXPORT"
)
+ elseif(
+ target_type STREQUAL STATIC_LIBRARY
+ )
+ target_compile_definitions(
+ ${target}
+ PUBLIC "${ARG_EXPORT_MACRO_PREFIX}_STATIC"
+ )
endif()
endif()