kean / Pulse

Network logger for Apple platforms
https://pulselogger.com
MIT License
6.18k stars 294 forks source link

Question when building project with xcode-beta 16.0 #266

Closed ivan-dwijaya closed 1 week ago

ivan-dwijaya commented 1 month ago

Hi folks,

First of all, thanks for building and maintaining this project. It works really well. And, I can see the effort you guys have put in here.

However, I would like to report an issue I faced when I tried to build this project using xcode-beta 16. I was unable to build my project using carthage via this command carthage build --platform iOS --cache-builds --no-use-binaries --use-xcframeworks. There is an error message saying xcodebuild failed to found the destination, which, after looking a bit, I notice the Pulse project does not support iOS destination.

Hence, after I made a local modification, to add iOS as Supported Destination, then, the build command worked fine. As such, I would like to know, whether is it correct to add iOS as Supported Destination here? I feel like this issue kinda tied with xcodebuild tool as this does not happen in xcode 15.2.

Following is the patch for your perusal, feel free to use it in case needed. Thanks

diff --git a/Pulse.xcodeproj/project.pbxproj b/Pulse.xcodeproj/project.pbxproj
index de1126f6..afd3f1f4 100644
--- a/Pulse.xcodeproj/project.pbxproj
+++ b/Pulse.xcodeproj/project.pbxproj
@@ -2975,7 +2975,7 @@
                SUPPORTS_MACCATALYST = YES;
                SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
                SWIFT_VERSION = 5.0;
-               TARGETED_DEVICE_FAMILY = 7;
+               TARGETED_DEVICE_FAMILY = "1,2,7";
                VERSIONING_SYSTEM = "apple-generic";
                VERSION_INFO_PREFIX = "";
            };
@@ -3011,7 +3011,7 @@
                SUPPORTED_PLATFORMS = "appletvos appletvsimulator iphoneos iphonesimulator macosx watchos watchsimulator xros xrsimulator";
                SUPPORTS_MACCATALYST = YES;
                SWIFT_VERSION = 5.0;
-               TARGETED_DEVICE_FAMILY = 7;
+               TARGETED_DEVICE_FAMILY = "1,2,7";
                VERSIONING_SYSTEM = "apple-generic";
                VERSION_INFO_PREFIX = "";
            };
kean commented 1 week ago

Pusle does not officially support Carthage and the Xcode project will be removed in the upcoming versions. I would recommend switching to one of the officially supported insallation options.