blob: b3f68ae84b8b5129f076e53d67d2560b2de94024 [file] [edit]
// Copyright (C) 2018-2025 Apple Inc. All rights reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions
// are met:
// 1. Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// 2. Redistributions in binary form must reproduce the above copyright
// notice, this list of conditions and the following disclaimer in the
// documentation and/or other materials provided with the distribution.
//
// THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
// EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
// PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
// EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
// PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
// PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
// OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
// Use the following helpers to define build settings whose value depends on the target
// macOS version in a succinct and future-proof way.
//
// Example 1: To give the SMOOTHNESS build setting the value 3 in macOS 10.12 and later and the
// value 2 in earlier versions, write:
//
// SMOOTHNESS = $(SMOOTHNESS$(WK_MACOS_1012));
// SMOOTHNESS_MACOS_BEFORE_1012 = 2;
// SMOOTHNESS_MACOS_SINCE_1012 = 3;
//
// Example 2: To define ENABLE_COLOR to ENABLE_COLOR in all platforms except macOS 10.12 and
// earlier write:
//
// ENABLE_COLOR = ENABLE_COLOR;
// ENABLE_COLOR[sdk=macosx*] = $(ENABLE_COLOR$(WK_MACOS_1013));
// ENABLE_COLOR_MACOS_SINCE_1013 = $(ENABLE_COLOR);
//
// Example 3: To give EXTRA_PATH one value before macOS 10.12, another value in macOS 10.12 and
// macOS 10.13, and a third value in macOS 10.14 and later, write:
//
// EXTRA_PATH = $(EXTRA_PATH$(WK_MACOS_1012_1014));
// EXTRA_PATH_MACOS_BEFORE_1012 = "/Library/Application Support/WebKit";
// EXTRA_PATH_MACOS_BEFORE_1014 = /System/Library/CoreServices;
// EXTRA_PATH_MACOS_SINCE_1014 = /System/Library/PrivateFrameworks;
// macOS
//
// The minimum supported macOS deployment target is 15.7. Only the macOS 26 boundary
// remains dynamic.
WK_MACOS_BEFORE_2600 = $(WK_MACOS_BEFORE_2600_$(TARGET_MAC_OS_X_VERSION_MAJOR));
WK_MACOS_BEFORE_2600_150000 = YES;
WK_MACOS_2600 = $(WK_MACOS_2600_$(WK_MACOS_BEFORE_2600));
WK_MACOS_2600_ = _MACOS_SINCE_2600;
WK_MACOS_2600_YES = _MACOS_BEFORE_2600;
WK_MACOS_1500_2600 = $(WK_MACOS_2600);
// iOS
//
// The minimum supported iOS deployment target is 26.2.
WK_IOS_26 = _IOS_SINCE_26;
// visionOS
//
// The minimum supported visionOS deployment target is 26.2.
WK_XROS_26 = _XROS_SINCE_26;