File tree Expand file tree Collapse file tree 2 files changed +11
-8
lines changed Expand file tree Collapse file tree 2 files changed +11
-8
lines changed Original file line number Diff line number Diff line change @@ -132,21 +132,19 @@ endif()
132
132
133
133
option (INSTALL_PRIVATE_HEADERS "installs private headers in the same location as the public ones" OFF )
134
134
135
- find_package (BlocksRuntime QUIET )
136
- if (NOT BlocksRuntime_FOUND )
135
+ if (NOT CMAKE_SYSTEM_NAME STREQUAL Darwin )
137
136
set (BlocksRuntime_INCLUDE_DIR ${PROJECT_SOURCE_DIR} /src/BlocksRuntime )
138
137
139
138
add_library (BlocksRuntime
140
- STATIC
141
- ${PROJECT_SOURCE_DIR} /src/BlocksRuntime/data.c
142
- ${PROJECT_SOURCE_DIR} /src/BlocksRuntime/runtime.c )
139
+ ${PROJECT_SOURCE_DIR} /src/BlocksRuntime/data.c
140
+ ${PROJECT_SOURCE_DIR} /src/BlocksRuntime/runtime.c )
143
141
set_target_properties (BlocksRuntime
144
142
PROPERTIES
145
143
POSITION_INDEPENDENT_CODE TRUE )
146
144
if (HAVE_OBJC AND CMAKE_DL_LIBS )
147
- set_target_properties (BlocksRuntime
148
- PROPERTIES
149
- INTERFACE_LINK_LIBRARIES ${CMAKE_DL_LIBS} )
145
+ target_link_libraries (BlocksRuntime
146
+ PUBLIC
147
+ ${CMAKE_DL_LIBS} )
150
148
endif ()
151
149
152
150
add_library (BlocksRuntime::BlocksRuntime ALIAS BlocksRuntime )
@@ -161,6 +159,10 @@ if(NOT BlocksRuntime_FOUND)
161
159
DESTINATION
162
160
"${INSTALL_BLOCK_HEADERS_DIR} " )
163
161
endif ()
162
+ install (TARGETS
163
+ BlocksRuntime
164
+ DESTINATION
165
+ ${INSTALL_TARGET_DIR} )
164
166
endif ()
165
167
166
168
check_symbol_exists (__GNU_LIBRARY__ "features.h" _GNU_SOURCE )
Original file line number Diff line number Diff line change @@ -2,6 +2,7 @@ module Dispatch {
2
2
requires blocks
3
3
export *
4
4
link "dispatch"
5
+ link "BlocksRuntime"
5
6
}
6
7
7
8
module DispatchIntrospection [system] [extern_c] {
You can’t perform that action at this time.
0 commit comments