fix: sync LookinCore mirror — Swift optimization report on SwiftPM path#30
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Updates LookinCore’s server-side app info reporting so SwiftPM/XCFramework builds correctly advertise that the Swift-aware LookinServer is enabled, preventing a false “enable Swift optimization” warning for SPM consumers.
Changes:
- Treat
SPM_LOOKIN_SERVER_ENABLEDas equivalent toLOOKIN_SERVER_SWIFT_ENABLEDwhen settingswiftEnabledInLookinServer. - Add explanatory comments documenting why both macros imply Swift support is active.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+145
to
+150
| // Report Swift optimization as enabled whenever the Swift-aware build is | ||
| // compiled in. The CocoaPods subspec path defines LOOKIN_SERVER_SWIFT_ENABLED; | ||
| // the SwiftPM / XCFramework path defines SPM_LOOKIN_SERVER_ENABLED (which in | ||
| // turn imports LookinServerSwift and activates LOOKIN_SERVER_SWIFT_ENABLED_SUCCESSFULLY | ||
| // in LKS_TraceManager). Both imply the optimization is active, matching the | ||
| // contract documented on -swiftEnabledInLookinServer ("SPM 或 Swift Subspec → 1"). |
Mirror of the canonical LookInside-Server fix: report `swiftEnabledInLookinServer = 1` when `SPM_LOOKIN_SERVER_ENABLED` is defined, so the host no longer shows a false-positive "turn on Swift optimization" notification for SwiftPM/CocoaPods consumers (which always ship the Swift-aware server binary).
33a6b18 to
0cd1ba0
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mirror of the canonical
LookinCorefix in the server package: reportswiftEnabledInLookinServer = 1when the SwiftPM / XCFramework build macroSPM_LOOKIN_SERVER_ENABLEDis defined (in addition to the legacy CocoaPodsLOOKIN_SERVER_SWIFT_ENABLED).This removes the false-positive "turn on Swift optimization" notification for SwiftPM/CocoaPods consumers, which always ship the Swift-aware server binary.
Scope is limited to
Sources/LookinCore/LookinAppInfo.mto keep this change focused.