summaryrefslogtreecommitdiff
path: root/xmake/plugins/project/xcode2/get_xcode_info.lua
diff options
context:
space:
mode:
authorJX-Master <[email protected]>2025-06-27 12:00:04 +0800
committerJX-Master <[email protected]>2025-06-27 12:00:04 +0800
commit5659468ff81b1c80576a03a88b0402483b436172 (patch)
treefde8b02014548b262cfe83b3daaf7664589ff357 /xmake/plugins/project/xcode2/get_xcode_info.lua
parent8b48aee3110ea81162a66c6909ec07de24ba3e90 (diff)
Fix product name issue.
Add SDKROOT build settings.
Diffstat (limited to 'xmake/plugins/project/xcode2/get_xcode_info.lua')
-rw-r--r--xmake/plugins/project/xcode2/get_xcode_info.lua9
1 files changed, 8 insertions, 1 deletions
diff --git a/xmake/plugins/project/xcode2/get_xcode_info.lua b/xmake/plugins/project/xcode2/get_xcode_info.lua
index d95834998..05fe21895 100644
--- a/xmake/plugins/project/xcode2/get_xcode_info.lua
+++ b/xmake/plugins/project/xcode2/get_xcode_info.lua
@@ -80,8 +80,15 @@ function _add_XCBuildConfiguration(xcinfo, mode, target)
end
if is_app_bundle then
obj.buildSettings.GENERATE_INFOPLIST_FILE = true
- obj.buildSettings.PRODUCT_NAME = "$(TARGET_NAME)"
+ obj.buildSettings.PRODUCT_NAME = "\"$(TARGET_NAME)\""
end
+ else
+ -- This is for root project.
+ obj.buildSettings.SUPPORTED_PLATFORMS = "\"macosx iphoneos\""
+ obj.buildSettings.SDKROOT = "macosx"
+ obj.buildSettings["\"SDKROOT[sdk=macosx*]\""] = "macosx"
+ obj.buildSettings["\"SDKROOT[sdk=iphoneos]\""] = "iphoneos"
+
end
local uuid = xcinfo:gen_uuid()
xcinfo.sections.XCBuildConfiguration = xcinfo.sections.XCBuildConfiguration or {}