]> git.saurik.com Git - apple/xnu.git/blob - EXTERNAL_HEADERS/AvailabilityMacros.h
25587d84939ba924afa0ce21a9c1c775cb29b122
[apple/xnu.git] / EXTERNAL_HEADERS / AvailabilityMacros.h
1 /*
2 * Copyright (c) 2001-2010 by Apple Inc.. All rights reserved.
3 *
4 * @APPLE_LICENSE_HEADER_START@
5 *
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. Please obtain a copy of the License at
10 * http://www.opensource.apple.com/apsl/ and read it before using this
11 * file.
12 *
13 * The Original Code and all software distributed under the License are
14 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
15 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
16 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
17 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
18 * Please see the License for the specific language governing rights and
19 * limitations under the License.
20 *
21 * @APPLE_LICENSE_HEADER_END@
22 */
23
24 /*
25 File: AvailabilityMacros.h
26
27 More Info: See TechNote 2064
28
29 Contains: Autoconfiguration of AVAILABLE_ macros for Mac OS X
30
31 This header enables a developer to specify build time
32 constraints on what Mac OS X versions the resulting
33 application will be run. There are two bounds a developer
34 can specify:
35
36 MAC_OS_X_VERSION_MIN_REQUIRED
37 MAC_OS_X_VERSION_MAX_ALLOWED
38
39 The lower bound controls which calls to OS functions will
40 be weak-importing (allowed to be unresolved at launch time).
41 The upper bound controls which OS functionality, if used,
42 will result in a compiler error because that functionality is
43 not available on on any OS is the specifed range.
44
45 For example, suppose an application is compiled with:
46
47 MAC_OS_X_VERSION_MIN_REQUIRED = MAC_OS_X_VERSION_10_2
48 MAC_OS_X_VERSION_MAX_ALLOWED = MAC_OS_X_VERSION_10_3
49
50 and an OS header contains:
51
52 extern void funcA(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER;
53 extern void funcB(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_2;
54 extern void funcC(void) AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3;
55 extern void funcD(void) AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER;
56 extern void funcE(void) AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER;
57 extern void funcF(void) AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER;
58 extern void funcG(void) AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER;
59
60 typedef long TypeA DEPRECATED_IN_MAC_OS_X_VERSION_10_0_AND_LATER;
61 typedef long TypeB DEPRECATED_IN_MAC_OS_X_VERSION_10_1_AND_LATER;
62 typedef long TypeC DEPRECATED_IN_MAC_OS_X_VERSION_10_2_AND_LATER;
63 typedef long TypeD DEPRECATED_IN_MAC_OS_X_VERSION_10_3_AND_LATER;
64 typedef long TypeE DEPRECATED_IN_MAC_OS_X_VERSION_10_4_AND_LATER;
65
66 Any application code which uses these declarations will get the following:
67
68 compile link run
69 ------- ------ -------
70 funcA: normal normal normal
71 funcB: warning normal normal
72 funcC: normal normal normal
73 funcD: normal normal normal
74 funcE: normal normal normal
75 funcF: normal weak on 10.3 normal, on 10.2 (&funcF == NULL)
76 funcG: error error n/a
77 typeA: warning
78 typeB: warning
79 typeC: warning
80 typeD: normal
81 typeE: normal
82
83
84 */
85 #ifndef __AVAILABILITYMACROS__
86 #define __AVAILABILITYMACROS__
87
88
89 /*
90 * Set up standard Mac OS X versions
91 */
92 #define MAC_OS_X_VERSION_10_0 1000
93 #define MAC_OS_X_VERSION_10_1 1010
94 #define MAC_OS_X_VERSION_10_2 1020
95 #define MAC_OS_X_VERSION_10_3 1030
96 #define MAC_OS_X_VERSION_10_4 1040
97 #define MAC_OS_X_VERSION_10_5 1050
98 #define MAC_OS_X_VERSION_10_6 1060
99 #define MAC_OS_X_VERSION_10_7 1070
100 #define MAC_OS_X_VERSION_10_8 1080
101
102 /*
103 * If min OS not specified, assume 10.1 for ppc and 10.4 for all others
104 * Note: gcc driver may set _ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED_ based on MACOSX_DEPLOYMENT_TARGET environment variable
105 */
106 #ifndef MAC_OS_X_VERSION_MIN_REQUIRED
107 #ifdef __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__
108 #if (__i386__ || __x86_64__) && (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < MAC_OS_X_VERSION_10_4)
109 #warning Building for Intel with Mac OS X Deployment Target < 10.4 is invalid.
110 #elif __ppc64__ && (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < MAC_OS_X_VERSION_10_4)
111 #warning Building for ppc64 with Mac OS X Deployment Target < 10.4 is invalid.
112 #endif
113 #define MAC_OS_X_VERSION_MIN_REQUIRED __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__
114 #else
115 #if __ppc64__ || __i386__ || __x86_64__
116 #define MAC_OS_X_VERSION_MIN_REQUIRED MAC_OS_X_VERSION_10_4
117 #else
118 #define MAC_OS_X_VERSION_MIN_REQUIRED MAC_OS_X_VERSION_10_1
119 #endif
120 #endif
121 #endif
122
123 /*
124 * if max OS not specified, assume larger of (10.8, min)
125 */
126 #ifndef MAC_OS_X_VERSION_MAX_ALLOWED
127 #if MAC_OS_X_VERSION_MIN_REQUIRED > MAC_OS_X_VERSION_10_8
128 #define MAC_OS_X_VERSION_MAX_ALLOWED MAC_OS_X_VERSION_MIN_REQUIRED
129 #else
130 #define MAC_OS_X_VERSION_MAX_ALLOWED MAC_OS_X_VERSION_10_8
131 #endif
132 #endif
133
134 /*
135 * Error on bad values
136 */
137 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_MIN_REQUIRED
138 #error MAC_OS_X_VERSION_MAX_ALLOWED must be >= MAC_OS_X_VERSION_MIN_REQUIRED
139 #endif
140 #if MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_0
141 #error MAC_OS_X_VERSION_MIN_REQUIRED must be >= MAC_OS_X_VERSION_10_0
142 #endif
143
144 /*
145 * only certain compilers support __attribute__((weak_import))
146 */
147 #if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1))) && (MAC_OS_X_VERSION_MIN_REQUIRED >= 1020)
148 #define WEAK_IMPORT_ATTRIBUTE __attribute__((weak_import))
149 #elif defined(__MWERKS__) && (__MWERKS__ >= 0x3205) && (MAC_OS_X_VERSION_MIN_REQUIRED >= 1020) && !defined(__INTEL__)
150 #define WEAK_IMPORT_ATTRIBUTE __attribute__((weak_import))
151 #else
152 #define WEAK_IMPORT_ATTRIBUTE
153 #endif
154
155 /*
156 * only certain compilers support __attribute__((deprecated))
157 */
158 #if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)))
159 #define DEPRECATED_ATTRIBUTE __attribute__((deprecated))
160 #else
161 #define DEPRECATED_ATTRIBUTE
162 #endif
163
164 /*
165 * only certain compilers support __attribute__((unavailable))
166 */
167 #if defined(__GNUC__) && ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)))
168 #define UNAVAILABLE_ATTRIBUTE __attribute__((unavailable))
169 #else
170 #define UNAVAILABLE_ATTRIBUTE
171 #endif
172
173
174 /*
175 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
176 *
177 * Used on functions introduced in Mac OS X 10.0
178 */
179 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
180
181 /*
182 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED
183 *
184 * Used on functions introduced in Mac OS X 10.0,
185 * and deprecated in Mac OS X 10.0
186 */
187 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
188
189 /*
190 * DEPRECATED_IN_MAC_OS_X_VERSION_10_0_AND_LATER
191 *
192 * Used on types deprecated in Mac OS X 10.0
193 */
194 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_0_AND_LATER DEPRECATED_ATTRIBUTE
195
196 /*
197 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
198 *
199 * Used on declarations introduced in Mac OS X 10.1
200 */
201 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_1
202 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER UNAVAILABLE_ATTRIBUTE
203 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_1
204 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER WEAK_IMPORT_ATTRIBUTE
205 #else
206 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
207 #endif
208
209 /*
210 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED
211 *
212 * Used on declarations introduced in Mac OS X 10.1,
213 * and deprecated in Mac OS X 10.1
214 */
215 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_1
216 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
217 #else
218 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
219 #endif
220
221 /*
222 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_1
223 *
224 * Used on declarations introduced in Mac OS X 10.0,
225 * but later deprecated in Mac OS X 10.1
226 */
227 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_1
228 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_1 DEPRECATED_ATTRIBUTE
229 #else
230 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_1 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
231 #endif
232
233 /*
234 * DEPRECATED_IN_MAC_OS_X_VERSION_10_1_AND_LATER
235 *
236 * Used on types deprecated in Mac OS X 10.1
237 */
238 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_1
239 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_1_AND_LATER DEPRECATED_ATTRIBUTE
240 #else
241 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_1_AND_LATER
242 #endif
243
244
245 /*
246 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
247 *
248 * Used on declarations introduced in Mac OS X 10.2
249 */
250 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_2
251 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER UNAVAILABLE_ATTRIBUTE
252 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_2
253 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER WEAK_IMPORT_ATTRIBUTE
254 #else
255 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
256 #endif
257
258 /*
259 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED
260 *
261 * Used on declarations introduced in Mac OS X 10.2,
262 * and deprecated in Mac OS X 10.2
263 */
264 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_2
265 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
266 #else
267 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
268 #endif
269
270 /*
271 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_2
272 *
273 * Used on declarations introduced in Mac OS X 10.0,
274 * but later deprecated in Mac OS X 10.2
275 */
276 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_2
277 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_2 DEPRECATED_ATTRIBUTE
278 #else
279 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_2 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
280 #endif
281
282 /*
283 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_2
284 *
285 * Used on declarations introduced in Mac OS X 10.1,
286 * but later deprecated in Mac OS X 10.2
287 */
288 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_2
289 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_2 DEPRECATED_ATTRIBUTE
290 #else
291 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_2 AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
292 #endif
293
294 /*
295 * DEPRECATED_IN_MAC_OS_X_VERSION_10_2_AND_LATER
296 *
297 * Used on types deprecated in Mac OS X 10.2
298 */
299 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_2
300 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_2_AND_LATER DEPRECATED_ATTRIBUTE
301 #else
302 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_2_AND_LATER
303 #endif
304
305
306 /*
307 * AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
308 *
309 * Used on declarations introduced in Mac OS X 10.3
310 */
311 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_3
312 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER UNAVAILABLE_ATTRIBUTE
313 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_3
314 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER WEAK_IMPORT_ATTRIBUTE
315 #else
316 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
317 #endif
318
319 /*
320 * AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED
321 *
322 * Used on declarations introduced in Mac OS X 10.3,
323 * and deprecated in Mac OS X 10.3
324 */
325 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_3
326 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
327 #else
328 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
329 #endif
330
331 /*
332 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3
333 *
334 * Used on declarations introduced in Mac OS X 10.0,
335 * but later deprecated in Mac OS X 10.3
336 */
337 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_3
338 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3 DEPRECATED_ATTRIBUTE
339 #else
340 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
341 #endif
342
343 /*
344 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3
345 *
346 * Used on declarations introduced in Mac OS X 10.1,
347 * but later deprecated in Mac OS X 10.3
348 */
349 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_3
350 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3 DEPRECATED_ATTRIBUTE
351 #else
352 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3 AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
353 #endif
354
355 /*
356 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3
357 *
358 * Used on declarations introduced in Mac OS X 10.2,
359 * but later deprecated in Mac OS X 10.3
360 */
361 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_3
362 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3 DEPRECATED_ATTRIBUTE
363 #else
364 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_3 AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
365 #endif
366
367 /*
368 * DEPRECATED_IN_MAC_OS_X_VERSION_10_3_AND_LATER
369 *
370 * Used on types deprecated in Mac OS X 10.3
371 */
372 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_3
373 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_3_AND_LATER DEPRECATED_ATTRIBUTE
374 #else
375 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_3_AND_LATER
376 #endif
377
378
379 /*
380 * AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
381 *
382 * Used on declarations introduced in Mac OS X 10.4
383 */
384 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_4
385 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER UNAVAILABLE_ATTRIBUTE
386 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_4
387 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER WEAK_IMPORT_ATTRIBUTE
388 #else
389 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
390 #endif
391
392 /*
393 * AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED
394 *
395 * Used on declarations introduced in Mac OS X 10.4,
396 * and deprecated in Mac OS X 10.4
397 */
398 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_4
399 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
400 #else
401 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
402 #endif
403
404 /*
405 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4
406 *
407 * Used on declarations introduced in Mac OS X 10.0,
408 * but later deprecated in Mac OS X 10.4
409 */
410 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_4
411 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 DEPRECATED_ATTRIBUTE
412 #else
413 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
414 #endif
415
416 /*
417 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4
418 *
419 * Used on declarations introduced in Mac OS X 10.1,
420 * but later deprecated in Mac OS X 10.4
421 */
422 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_4
423 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 DEPRECATED_ATTRIBUTE
424 #else
425 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
426 #endif
427
428 /*
429 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4
430 *
431 * Used on declarations introduced in Mac OS X 10.2,
432 * but later deprecated in Mac OS X 10.4
433 */
434 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_4
435 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 DEPRECATED_ATTRIBUTE
436 #else
437 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
438 #endif
439
440 /*
441 * AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4
442 *
443 * Used on declarations introduced in Mac OS X 10.3,
444 * but later deprecated in Mac OS X 10.4
445 */
446 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_4
447 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 DEPRECATED_ATTRIBUTE
448 #else
449 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_4 AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
450 #endif
451
452 /*
453 * DEPRECATED_IN_MAC_OS_X_VERSION_10_4_AND_LATER
454 *
455 * Used on types deprecated in Mac OS X 10.4
456 */
457 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_4
458 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_4_AND_LATER DEPRECATED_ATTRIBUTE
459 #else
460 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_4_AND_LATER
461 #endif
462
463
464 /*
465 * AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER
466 *
467 * Used on declarations introduced in Mac OS X 10.5
468 */
469 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_5
470 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER UNAVAILABLE_ATTRIBUTE
471 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_5
472 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER WEAK_IMPORT_ATTRIBUTE
473 #else
474 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER
475 #endif
476
477 /*
478 * AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED
479 *
480 * Used on declarations introduced in Mac OS X 10.5,
481 * and deprecated in Mac OS X 10.5
482 */
483 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5
484 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
485 #else
486 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER
487 #endif
488
489 /*
490 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5
491 *
492 * Used on declarations introduced in Mac OS X 10.0,
493 * but later deprecated in Mac OS X 10.5
494 */
495 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5
496 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 DEPRECATED_ATTRIBUTE
497 #else
498 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
499 #endif
500
501 /*
502 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5
503 *
504 * Used on declarations introduced in Mac OS X 10.1,
505 * but later deprecated in Mac OS X 10.5
506 */
507 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5
508 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 DEPRECATED_ATTRIBUTE
509 #else
510 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
511 #endif
512
513 /*
514 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5
515 *
516 * Used on declarations introduced in Mac OS X 10.2,
517 * but later deprecated in Mac OS X 10.5
518 */
519 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5
520 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 DEPRECATED_ATTRIBUTE
521 #else
522 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
523 #endif
524
525 /*
526 * AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5
527 *
528 * Used on declarations introduced in Mac OS X 10.3,
529 * but later deprecated in Mac OS X 10.5
530 */
531 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5
532 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 DEPRECATED_ATTRIBUTE
533 #else
534 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
535 #endif
536
537 /*
538 * AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5
539 *
540 * Used on declarations introduced in Mac OS X 10.4,
541 * but later deprecated in Mac OS X 10.5
542 */
543 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5
544 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 DEPRECATED_ATTRIBUTE
545 #else
546 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_5 AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
547 #endif
548
549 /*
550 * DEPRECATED_IN_MAC_OS_X_VERSION_10_5_AND_LATER
551 *
552 * Used on types deprecated in Mac OS X 10.5
553 */
554 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_5
555 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_5_AND_LATER DEPRECATED_ATTRIBUTE
556 #else
557 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_5_AND_LATER
558 #endif
559
560
561 /*
562 * AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER
563 *
564 * Used on declarations introduced in Mac OS X 10.6
565 */
566 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_6
567 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER UNAVAILABLE_ATTRIBUTE
568 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_6
569 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER WEAK_IMPORT_ATTRIBUTE
570 #else
571 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER
572 #endif
573
574 /*
575 * AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED
576 *
577 * Used on declarations introduced in Mac OS X 10.6,
578 * and deprecated in Mac OS X 10.6
579 */
580 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
581 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
582 #else
583 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER
584 #endif
585
586 /*
587 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6
588 *
589 * Used on declarations introduced in Mac OS X 10.0,
590 * but later deprecated in Mac OS X 10.6
591 */
592 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
593 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 DEPRECATED_ATTRIBUTE
594 #else
595 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
596 #endif
597
598 /*
599 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6
600 *
601 * Used on declarations introduced in Mac OS X 10.1,
602 * but later deprecated in Mac OS X 10.6
603 */
604 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
605 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 DEPRECATED_ATTRIBUTE
606 #else
607 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
608 #endif
609
610 /*
611 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6
612 *
613 * Used on declarations introduced in Mac OS X 10.2,
614 * but later deprecated in Mac OS X 10.6
615 */
616 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
617 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 DEPRECATED_ATTRIBUTE
618 #else
619 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
620 #endif
621
622 /*
623 * AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6
624 *
625 * Used on declarations introduced in Mac OS X 10.3,
626 * but later deprecated in Mac OS X 10.6
627 */
628 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
629 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 DEPRECATED_ATTRIBUTE
630 #else
631 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
632 #endif
633
634 /*
635 * AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6
636 *
637 * Used on declarations introduced in Mac OS X 10.4,
638 * but later deprecated in Mac OS X 10.6
639 */
640 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
641 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 DEPRECATED_ATTRIBUTE
642 #else
643 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
644 #endif
645
646 /*
647 * AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6
648 *
649 * Used on declarations introduced in Mac OS X 10.5,
650 * but later deprecated in Mac OS X 10.6
651 */
652 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
653 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 DEPRECATED_ATTRIBUTE
654 #else
655 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_6 AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER
656 #endif
657
658 /*
659 * DEPRECATED_IN_MAC_OS_X_VERSION_10_6_AND_LATER
660 *
661 * Used on types deprecated in Mac OS X 10.6
662 */
663 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_6
664 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_6_AND_LATER DEPRECATED_ATTRIBUTE
665 #else
666 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_6_AND_LATER
667 #endif
668
669
670 /*
671 * AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
672 *
673 * Used on declarations introduced in Mac OS X 10.7
674 */
675 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_7
676 #define AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER UNAVAILABLE_ATTRIBUTE
677 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_7
678 #define AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER WEAK_IMPORT_ATTRIBUTE
679 #else
680 #define AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
681 #endif
682
683 /*
684 * AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER_BUT_DEPRECATED
685 *
686 * Used on declarations introduced in Mac OS X 10.7,
687 * and deprecated in Mac OS X 10.7
688 */
689 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
690 #define AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
691 #else
692 #define AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
693 #endif
694
695 /*
696 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
697 *
698 * Used on declarations introduced in Mac OS X 10.0,
699 * but later deprecated in Mac OS X 10.7
700 */
701 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
702 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 DEPRECATED_ATTRIBUTE
703 #else
704 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
705 #endif
706
707 /*
708 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
709 *
710 * Used on declarations introduced in Mac OS X 10.1,
711 * but later deprecated in Mac OS X 10.7
712 */
713 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
714 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 DEPRECATED_ATTRIBUTE
715 #else
716 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
717 #endif
718
719 /*
720 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
721 *
722 * Used on declarations introduced in Mac OS X 10.2,
723 * but later deprecated in Mac OS X 10.7
724 */
725 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
726 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 DEPRECATED_ATTRIBUTE
727 #else
728 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
729 #endif
730
731 /*
732 * AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
733 *
734 * Used on declarations introduced in Mac OS X 10.3,
735 * but later deprecated in Mac OS X 10.7
736 */
737 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
738 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 DEPRECATED_ATTRIBUTE
739 #else
740 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
741 #endif
742
743 /*
744 * AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
745 *
746 * Used on declarations introduced in Mac OS X 10.4,
747 * but later deprecated in Mac OS X 10.7
748 */
749 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
750 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 DEPRECATED_ATTRIBUTE
751 #else
752 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
753 #endif
754
755 /*
756 * AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
757 *
758 * Used on declarations introduced in Mac OS X 10.5,
759 * but later deprecated in Mac OS X 10.7
760 */
761 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
762 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 DEPRECATED_ATTRIBUTE
763 #else
764 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER
765 #endif
766
767 /*
768 * AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7
769 *
770 * Used on declarations introduced in Mac OS X 10.6,
771 * but later deprecated in Mac OS X 10.7
772 */
773 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
774 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 DEPRECATED_ATTRIBUTE
775 #else
776 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_7 AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER
777 #endif
778
779 /*
780 * DEPRECATED_IN_MAC_OS_X_VERSION_10_7_AND_LATER
781 *
782 * Used on types deprecated in Mac OS X 10.7
783 */
784 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_7
785 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_7_AND_LATER DEPRECATED_ATTRIBUTE
786 #else
787 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_7_AND_LATER
788 #endif
789
790
791 /*
792 * AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER
793 *
794 * Used on declarations introduced in Mac OS X 10.8
795 */
796 #if MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_8
797 #define AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER UNAVAILABLE_ATTRIBUTE
798 #elif MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_8
799 #define AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER WEAK_IMPORT_ATTRIBUTE
800 #else
801 #define AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER
802 #endif
803
804 /*
805 * AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER_BUT_DEPRECATED
806 *
807 * Used on declarations introduced in Mac OS X 10.8,
808 * and deprecated in Mac OS X 10.8
809 */
810 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
811 #define AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER_BUT_DEPRECATED DEPRECATED_ATTRIBUTE
812 #else
813 #define AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER_BUT_DEPRECATED AVAILABLE_MAC_OS_X_VERSION_10_8_AND_LATER
814 #endif
815
816 /*
817 * AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
818 *
819 * Used on declarations introduced in Mac OS X 10.0,
820 * but later deprecated in Mac OS X 10.8
821 */
822 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
823 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
824 #else
825 #define AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_0_AND_LATER
826 #endif
827
828 /*
829 * AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
830 *
831 * Used on declarations introduced in Mac OS X 10.1,
832 * but later deprecated in Mac OS X 10.8
833 */
834 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
835 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
836 #else
837 #define AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_1_AND_LATER
838 #endif
839
840 /*
841 * AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
842 *
843 * Used on declarations introduced in Mac OS X 10.2,
844 * but later deprecated in Mac OS X 10.8
845 */
846 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
847 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
848 #else
849 #define AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_2_AND_LATER
850 #endif
851
852 /*
853 * AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
854 *
855 * Used on declarations introduced in Mac OS X 10.3,
856 * but later deprecated in Mac OS X 10.8
857 */
858 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
859 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
860 #else
861 #define AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_3_AND_LATER
862 #endif
863
864 /*
865 * AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
866 *
867 * Used on declarations introduced in Mac OS X 10.4,
868 * but later deprecated in Mac OS X 10.8
869 */
870 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
871 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
872 #else
873 #define AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_4_AND_LATER
874 #endif
875
876 /*
877 * AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
878 *
879 * Used on declarations introduced in Mac OS X 10.5,
880 * but later deprecated in Mac OS X 10.8
881 */
882 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
883 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
884 #else
885 #define AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_5_AND_LATER
886 #endif
887
888 /*
889 * AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
890 *
891 * Used on declarations introduced in Mac OS X 10.6,
892 * but later deprecated in Mac OS X 10.8
893 */
894 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
895 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
896 #else
897 #define AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_6_AND_LATER
898 #endif
899
900 /*
901 * AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8
902 *
903 * Used on declarations introduced in Mac OS X 10.7,
904 * but later deprecated in Mac OS X 10.8
905 */
906 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
907 #define AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 DEPRECATED_ATTRIBUTE
908 #else
909 #define AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER_BUT_DEPRECATED_IN_MAC_OS_X_VERSION_10_8 AVAILABLE_MAC_OS_X_VERSION_10_7_AND_LATER
910 #endif
911
912 /*
913 * DEPRECATED_IN_MAC_OS_X_VERSION_10_8_AND_LATER
914 *
915 * Used on types deprecated in Mac OS X 10.8
916 */
917 #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
918 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_8_AND_LATER DEPRECATED_ATTRIBUTE
919 #else
920 #define DEPRECATED_IN_MAC_OS_X_VERSION_10_8_AND_LATER
921 #endif
922
923
924
925
926 #endif /* __AVAILABILITYMACROS__ */
927
928