Skip to content

Commit f959e3e

Browse files
fbugnoktopley-apple
authored andcommitted
SR-2100 - Define SWIFT_LIBDIR with a default value to be used by build-script from swift
Signed-off-by: Kim Topley <[email protected]>
1 parent 92bebe9 commit f959e3e

11 files changed

+28
-27
lines changed

CMakeLists.txt

+3-2
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,8 @@ include(CheckSymbolExists)
3131
include(GNUInstallDirs)
3232
include(SwiftSupport)
3333

34-
set(INSTALL_LIBDIR "lib" CACHE PATH "Path where the libraries should be installed")
34+
set(SWIFT_LIBDIR "lib" CACHE PATH "Library folder name, defined by swift main buildscript")
35+
set(INSTALL_LIBDIR "${SWIFT_LIBDIR}" CACHE PATH "Path where the libraries should be installed")
3536
set(WITH_BLOCKS_RUNTIME "" CACHE PATH "Path to blocks runtime")
3637

3738
include(DispatchAppleOptions)
@@ -55,7 +56,7 @@ if(ENABLE_SWIFT)
5556
string(TOLOWER ${CMAKE_SYSTEM_NAME} SWIFT_OS)
5657
get_swift_host_arch(SWIFT_HOST_ARCH)
5758

58-
set(SWIFT_RUNTIME_LIBDIR ${SWIFT_TOOLCHAIN}/lib/swift/${SWIFT_OS}/${SWIFT_HOST_ARCH})
59+
set(SWIFT_RUNTIME_LIBDIR ${SWIFT_TOOLCHAIN}/${SWIFT_LIBDIR}/swift/${SWIFT_OS}/${SWIFT_HOST_ARCH})
5960

6061
add_library(swiftCore
6162
SHARED IMPORTED GLOBAL)

dispatch/source.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ DISPATCH_SOURCE_TYPE_DECL(data_or);
105105
* The mask is unused (pass zero for now).
106106
*/
107107
#define DISPATCH_SOURCE_TYPE_DATA_REPLACE (&_dispatch_source_type_data_replace)
108-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
108+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
109109
DISPATCH_SOURCE_TYPE_DECL(data_replace);
110110

111111
/*!

os/object_private.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -184,13 +184,13 @@ OS_SWIFT_UNAVAILABLE("Unavailable in Swift")
184184
void
185185
_os_object_release_internal(_os_object_t object);
186186

187-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
187+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
188188
OS_OBJECT_EXPORT OS_OBJECT_NONNULL OS_OBJECT_NOTHROW
189189
OS_SWIFT_UNAVAILABLE("Unavailable in Swift")
190190
_os_object_t
191191
_os_object_retain_internal_n(_os_object_t object, uint16_t n);
192192

193-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
193+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
194194
OS_OBJECT_EXPORT OS_OBJECT_NONNULL OS_OBJECT_NOTHROW
195195
OS_SWIFT_UNAVAILABLE("Unavailable in Swift")
196196
void

os/voucher_activity_private.h

+5-5
Original file line numberDiff line numberDiff line change
@@ -154,15 +154,15 @@ voucher_get_activity_id_and_creator(voucher_t voucher, uint64_t *creator_pid,
154154
* @result
155155
* A new voucher with an activity identifier.
156156
*/
157-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
157+
API_AVAILABLE(macos(10.12.4), ios(10.3), tvos(10.2), watchos(3.2))
158158
OS_VOUCHER_EXPORT OS_OBJECT_RETURNS_RETAINED OS_WARN_RESULT OS_NOTHROW
159159
voucher_t
160160
voucher_activity_create_with_data(firehose_tracepoint_id_t *trace_id,
161161
voucher_t base, firehose_activity_flags_t flags,
162162
const void *pubdata, size_t publen);
163163

164164
API_DEPRECATED_WITH_REPLACEMENT("voucher_activity_create_with_data",
165-
macos(10.12,10.12), ios(10.0,10.0), tvos(10.0,10.0), watchos(3.0,3.0))
165+
macos(10.12,10.12.4), ios(10.0,10.3), tvos(10.0,10.2), watchos(3.0,3.2))
166166
OS_VOUCHER_EXPORT OS_OBJECT_RETURNS_RETAINED OS_WARN_RESULT OS_NOTHROW
167167
voucher_t
168168
voucher_activity_create_with_location(firehose_tracepoint_id_t *trace_id,
@@ -183,7 +183,7 @@ voucher_activity_create_with_location(firehose_tracepoint_id_t *trace_id,
183183
* The bottom-most 8 bits of the flags will be used to generate the ID.
184184
* See firehose_activity_flags_t.
185185
*/
186-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
186+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
187187
OS_VOUCHER_EXPORT OS_NOTHROW
188188
firehose_activity_id_t
189189
voucher_activity_id_allocate(firehose_activity_flags_t flags);
@@ -264,7 +264,7 @@ voucher_activity_trace(firehose_stream_t stream,
264264
* Length of data to read from the iovec after the public data for the private
265265
* data.
266266
*/
267-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
267+
API_AVAILABLE(macos(10.12.4), ios(10.3), tvos(10.2), watchos(3.2))
268268
OS_VOUCHER_EXPORT OS_NOTHROW OS_NONNULL4
269269
firehose_tracepoint_id_t
270270
voucher_activity_trace_v(firehose_stream_t stream,
@@ -273,7 +273,7 @@ voucher_activity_trace_v(firehose_stream_t stream,
273273

274274

275275
API_DEPRECATED_WITH_REPLACEMENT("voucher_activity_trace_v",
276-
macos(10.12,10.12), ios(10.0,10.0), tvos(10.0,10.0), watchos(3.0,3.0))
276+
macos(10.12,10.12.4), ios(10.0,10.3), tvos(10.0,10.2), watchos(3.0,3.2))
277277
OS_VOUCHER_EXPORT OS_NOTHROW OS_NONNULL4 OS_NONNULL6
278278
firehose_tracepoint_id_t
279279
voucher_activity_trace_with_private_strings(firehose_stream_t stream,

os/voucher_private.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -381,7 +381,7 @@ dispatch_block_create_with_voucher_and_qos_class(dispatch_block_flags_t flags,
381381
* Deprecated, do not use, will abort process if called.
382382
*/
383383
API_DEPRECATED("removed SPI", \
384-
macos(10.11,10.12), ios(9.0,10.0), watchos(2.0,3.0), tvos(9.0,10.0))
384+
macos(10.11,10.13), ios(9.0,11.0), watchos(2.0,4.0), tvos(9.0,11.0))
385385
DISPATCH_EXPORT DISPATCH_MALLOC DISPATCH_RETURNS_RETAINED DISPATCH_WARN_RESULT
386386
DISPATCH_NOTHROW
387387
dispatch_queue_t

private/mach_private.h

+4-4
Original file line numberDiff line numberDiff line change
@@ -811,7 +811,7 @@ dispatch_mach_get_checkin_port(dispatch_mach_t channel);
811811
typedef void (*_Nonnull dispatch_mach_async_reply_callback_t)(void *context,
812812
dispatch_mach_reason_t reason, dispatch_mach_msg_t message);
813813

814-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
814+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
815815
typedef const struct dispatch_mach_xpc_hooks_s {
816816
#define DISPATCH_MACH_XPC_HOOKS_VERSION 3
817817
unsigned long version;
@@ -893,7 +893,7 @@ typedef const struct dispatch_mach_xpc_hooks_s {
893893
* @param hooks
894894
* A pointer to the channel hooks structure. This must remain valid once set.
895895
*/
896-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
896+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
897897
DISPATCH_EXPORT DISPATCH_NONNULL_ALL DISPATCH_NOTHROW
898898
void
899899
dispatch_mach_hooks_install_4libxpc(dispatch_mach_xpc_hooks_t hooks);
@@ -933,7 +933,7 @@ dispatch_mach_hooks_install_4libxpc(dispatch_mach_xpc_hooks_t hooks);
933933
* @result
934934
* The newly created dispatch mach channel.
935935
*/
936-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
936+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
937937
DISPATCH_EXPORT DISPATCH_MALLOC DISPATCH_RETURNS_RETAINED DISPATCH_WARN_RESULT
938938
DISPATCH_NONNULL4 DISPATCH_NOTHROW
939939
dispatch_mach_t
@@ -1014,7 +1014,7 @@ dispatch_mach_create_4libxpc(const char *_Nullable label,
10141014
* Out parameter to return the error from the immediate send attempt.
10151015
* If a deferred send is required, returns 0. Must not be NULL.
10161016
*/
1017-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
1017+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
10181018
DISPATCH_EXPORT DISPATCH_NONNULL1 DISPATCH_NONNULL2 DISPATCH_NONNULL5
10191019
DISPATCH_NONNULL6 DISPATCH_NOTHROW
10201020
void

private/private.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ mach_port_t
225225
_dispatch_runloop_root_queue_get_port_4CF(dispatch_queue_t queue);
226226

227227
#ifdef __BLOCKS__
228-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
228+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
229229
DISPATCH_EXPORT DISPATCH_MALLOC DISPATCH_RETURNS_RETAINED DISPATCH_WARN_RESULT
230230
DISPATCH_NOTHROW
231231
dispatch_queue_t
@@ -261,7 +261,7 @@ void (*_Nullable _dispatch_end_NSAutoReleasePool)(void *);
261261

262262
#endif /* DISPATCH_COCOA_COMPAT */
263263

264-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
264+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
265265
DISPATCH_EXPORT DISPATCH_NOTHROW
266266
void
267267
_dispatch_poll_for_events_4launchd(void);

private/queue_private.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ dispatch_queue_attr_make_with_overcommit(dispatch_queue_attr_t _Nullable attr,
133133
* @param label
134134
* The new label for the queue.
135135
*/
136-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
136+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
137137
DISPATCH_EXPORT DISPATCH_NONNULL1 DISPATCH_NOTHROW
138138
void
139139
dispatch_queue_set_label_nocopy(dispatch_queue_t queue, const char *label);

private/source_private.h

+6-6
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ DISPATCH_SOURCE_TYPE_DECL(sock);
107107
* @discussion A dispatch source that monitors events on a network channel.
108108
*/
109109
#define DISPATCH_SOURCE_TYPE_NW_CHANNEL (&_dispatch_source_type_nw_channel)
110-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0)) DISPATCH_LINUX_UNAVAILABLE()
110+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0)) DISPATCH_LINUX_UNAVAILABLE()
111111
DISPATCH_SOURCE_TYPE_DECL(nw_channel);
112112

113113
__END_DECLS
@@ -293,7 +293,7 @@ enum {
293293
enum {
294294
DISPATCH_PROC_REAP DISPATCH_ENUM_API_DEPRECATED("unsupported flag",
295295
macos(10.6,10.9), ios(4.0,7.0)) = 0x10000000,
296-
DISPATCH_PROC_EXIT_STATUS DISPATCH_ENUM_API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(2.0)) = 0x04000000,
296+
DISPATCH_PROC_EXIT_STATUS DISPATCH_ENUM_API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(2.0)) = 0x04000000,
297297
};
298298

299299
/*!
@@ -357,7 +357,7 @@ enum {
357357

358358
DISPATCH_MEMORYPRESSURE_PROC_LIMIT_CRITICAL DISPATCH_ENUM_API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0)) = 0x20,
359359

360-
DISPATCH_MEMORYPRESSURE_MSL_STATUS DISPATCH_ENUM_API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0)) = 0xf0000000,
360+
DISPATCH_MEMORYPRESSURE_MSL_STATUS DISPATCH_ENUM_API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0)) = 0xf0000000,
361361
};
362362

363363
/*!
@@ -425,7 +425,7 @@ __BEGIN_DECLS
425425
* The result of passing NULL in this parameter is undefined.
426426
*/
427427
#ifdef __BLOCKS__
428-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
428+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
429429
DISPATCH_EXPORT DISPATCH_NONNULL_ALL DISPATCH_NOTHROW
430430
void
431431
dispatch_source_set_mandatory_cancel_handler(dispatch_source_t source,
@@ -452,7 +452,7 @@ dispatch_source_set_mandatory_cancel_handler(dispatch_source_t source,
452452
* context of the dispatch source at the time the handler call is made.
453453
* The result of passing NULL in this parameter is undefined.
454454
*/
455-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
455+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
456456
DISPATCH_EXPORT DISPATCH_NONNULL_ALL DISPATCH_NOTHROW
457457
void
458458
dispatch_source_set_mandatory_cancel_handler_f(dispatch_source_t source,
@@ -583,7 +583,7 @@ typedef struct dispatch_source_extended_data_s {
583583
* the value of the size argument. If this is less than the value of the size
584584
* argument, the remaining space in data will have been populated with zeroes.
585585
*/
586-
API_AVAILABLE(macos(10.12), ios(10.0), tvos(10.0), watchos(3.0))
586+
API_AVAILABLE(macos(10.13), ios(11.0), tvos(11.0), watchos(4.0))
587587
DISPATCH_EXPORT DISPATCH_NONNULL_ALL DISPATCH_WARN_RESULT DISPATCH_PURE
588588
DISPATCH_NOTHROW
589589
size_t

src/internal.h

+2-2
Original file line numberDiff line numberDiff line change
@@ -658,7 +658,7 @@ _dispatch_fork_becomes_unsafe(void)
658658

659659

660660
#ifndef HAVE_PTHREAD_WORKQUEUE_NARROWING
661-
#if !DISPATCH_MIN_REQUIRED_OSX_AT_LEAST(109900)
661+
#if !DISPATCH_MIN_REQUIRED_OSX_AT_LEAST(101300)
662662
#define HAVE_PTHREAD_WORKQUEUE_NARROWING 0
663663
#else
664664
#define HAVE_PTHREAD_WORKQUEUE_NARROWING 1
@@ -699,7 +699,7 @@ extern bool _dispatch_memory_warn;
699699

700700

701701
#if defined(MACH_SEND_SYNC_OVERRIDE) && defined(MACH_RCV_SYNC_WAIT) && \
702-
DISPATCH_MIN_REQUIRED_OSX_AT_LEAST(109900) && \
702+
DISPATCH_MIN_REQUIRED_OSX_AT_LEAST(101300) && \
703703
!defined(DISPATCH_USE_MACH_SEND_SYNC_OVERRIDE)
704704
#define DISPATCH_USE_MACH_SEND_SYNC_OVERRIDE 1
705705
#endif

src/shims.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,7 @@ _pthread_workqueue_should_narrow(pthread_priority_t priority)
148148
#if HAVE_PTHREAD_QOS_H && __has_include(<pthread/qos_private.h>) && \
149149
defined(PTHREAD_MAX_PARALLELISM_PHYSICAL) && \
150150
DISPATCH_HAVE_HW_CONFIG_COMMPAGE && \
151-
DISPATCH_MIN_REQUIRED_OSX_AT_LEAST(109900)
151+
DISPATCH_MIN_REQUIRED_OSX_AT_LEAST(101300)
152152
#define DISPATCH_USE_PTHREAD_QOS_MAX_PARALLELISM 1
153153
#define DISPATCH_MAX_PARALLELISM_PHYSICAL PTHREAD_MAX_PARALLELISM_PHYSICAL
154154
#else

0 commit comments

Comments
 (0)