SpeechToTextV1 - Missing required modules SSCZLib, SSCommonCrypto - xcode

I am working on XCode 9.1 project that uses IBM Watson swift-sdk SpeechToTextV1 package. After upgrading swift-sdk to the version 0.19.0 and building XCode project the compiler error has occured: Missing required modules: 'SSCZLib', 'SSCommonCrypto' pointing to the import SpeechToTextV1 statement. swift-sdk updated via Carthage.
Cartfile content: github "watson-developer-cloud/swift-sdk".
command line update: carthage update --platform ios --no-use-binaries.
How can I include SSCZLib and SSCommonCrypto modules into XCode project?
Please help. Thanks a lot.

Use carthage update --platform iOS --no-use-binaries. It takes a while, but it works.

I'm afraid that I haven't been able to replicate the problem on my machine. I started with a new, empty Xcode project and was able to transcribe audio with the Speech to Text service.
I uploaded my app here. Can you try downloading it, adding your Speech to Text credentials, and running the app?

Please make sure that the newly compiled frameworks are the ones being used. Carthage does not place the frameworks in a custom location that is referenced in the project or workspace.

For me - in addition to building the library using --no-use-binaries flag - I also had to ensure that under my target's
Build Phases->Embed Frameworks
Build Phases->Link Binary with Libraries
SpeechToTextV1.framework is included
In addition - I found that these two files made all the difference inside the Carthage folder:
Carthage/Checkouts/ios-sdk/Source/SupportingFiles/Dependencies/Starscream/zlib/include.h
Carthage/Checkouts/ios-sdk/Source/SupportingFiles/Dependencies/Starscream/zlib/module.modulemap
I could only get this to work after my project was directly referencing the Carthage folder. Deleting either of these two files caused the error to return.

The v0.21.0 release of the Watson Swift SDK fixes this issue. You should no longer have to add a link to the zlib folder in your project settings. However, you will need to copy Starscream.framework into your application in the same way that other frameworks are copied.
The solution was to externalize the Starscream dependency. Adding Starscream as a recursive dependency for the Swift SDK allows it to build independently with its own environment. When the Starscream library is copied into your application, it should automatically include the SSCZLib and SSCommonCrypto dependencies.
We test each SDK before it's release, but this problem slipped past us. Our test machine happens to have other software that adds SSCZLib and SSCommonCrypto to the path, making it available to the Xcode build. It wasn't until we refreshed the machine with a new macOS install that we were able to replicate the problem. And with v0.21.0, that problem has been solved.
Sorry for your trouble and thank you for your patience while we tracked down the solution!

Related

Executable Not Found. xxx.app is not a valid path to an executable file

Details
Executable Not Found
Domain: DVTMachOErrorDomain
Code: 5
Recovery Suggestion: /Users/riber/Library/Developer/Xcode/DerivedData/digitalCurrency-hiyiyrokjaydkiagjimlwohehrtu/Build/Products/Debug-iphonesimulator/digitalCurrency.app is not a valid path to an executable file. Please rebuild the project to ensure that all required executables are created. Check your project settings to ensure that a valid executable will be built.
System Information
macOS Version 11.4 (Build 20F71)
Xcode 12.5 (18205) (Build 12E262)
Timestamp: 2021-06-11T16:34:20+08:00
Check if all files are available.
Targets -> Build Phases -> Compile Sources
If you see faint files, then they need to be removed or added.
Under "Build Settings" - "Architectures" check that you don't have "arm64" excluded under "Excluded architectures" for release, as all new iOS devices use this architecture.
I'm also get the same error. Let me share how I fix it.
I write cpp code on vscode.
I deleted a .cpp/.h file that I didn't need anymore a few days ago.
Everything nice and happy when I working on vscode.
".app is not a valid path" appeared when i switched back to the xcode to verification function.
I was confused.
(I don't immediately remember my delete operation a few days ago)
The key isn't the dialog showed "Executable Not Found",
Switch to "Issue Navigator" and drag to the bottom...
Now the ERROR shows up in front of U:
Finally the solution is :
TARGETS -> Select your ‘Target' -> Build Phases -> Compile Sources :
Select the ".cpp" file that had been delete, then "Remove Items" by click the second "-" button in the lower left corner.
I fixed it by adding x86_64 to VALID_ARCHS. Build Setting search "VALID_ARCHS",check the x86_64 is there or not, add and run.It worked with me .
resolve it using pod install.
as Frank said, I also use RN in my app.
I have tried clean derived data & even reboot, still happening
Check the Executable File in the Info(.plist). It should be named the same as your Product in Products
I have this issue on a react native application and I can resolve it reinstalling cocoaPods.
pod install
Inside the ios folder on your react native project.
Check if you have any other info.plist-s added to project.
I had similar issue when I added some pod sources (MKStoreKit) to the project - it had several info plists for different platforms which interfered with original one. Deleting wrong info plists solved the issue.
I have to delete the 'DerivedData' folder:
$ rm -Rf ~/Library/Developer/Xcode/DerivedData
EDIT: I've found a solution...
The problem in my case was because of project configurations and Pods. In the long life of my project the configuration files for the schemes changed and Xcode, using the new build system, did not like.
To fix it, just go to the Project -> Info tab. Under Configurations change the Based on Configuration value of the Targets and set them to None. Please note that I've changed only the Targets.
Now close Xcode and launch pod install from the Terminal.
reopen Xcode and launch your project.
Old answer:
I may have found a workaround to this issue... not a solution but a workaround.
I have to work on a not really recent project that was built using the Legacy System that, as you may know, is deprecated now.
While I was using Xcode 12 everything was fine. Then I installed the Xcode 13 GM and I upgrated the project to the new building system and I started to experience this issue. I have the same problem with any Xcode 13.x version. With the betas I had not, as far as I can remember.
The strange thing is that "sometimes" (I could not reproduce it sorry), the new build system worked... but just for a while.
The building phase succeeds but then, then the app is installed on simulator OR on a real device, I have that annoying message that we know...
This morning I may have find a solution...
In Xcode go to File -> Workspace Settings, keep the Legacy Build System and check the box "Do not show a diagnostic issue about build system deprecation"
Now the app builds and can be installed.
Honestly I don't know it is an Xcode bug or not... maybe it is.
if you are using git, there's huge chance there might be conflict in .pbxproj due to multiple people adding stuffs together. During the resolution xcode might try to recover those 'lost references' it got confused and unable to resolve the once there references. find those 'recovered references' in project explorer and remove them if they are invalid
Had the same issue. I deleted the simulators and added them again.
Please make sure that your runner isn't missing AppDelegate.swift or Runner-Bridging-Header.h file.
In my case, my AppDelegate.swift file and Runner-Bridging-Header.h files were deleted, so I copy and paste both the files in ios>Runner folder again from some other project (usually both of these files are same in all projects, just need to add the code lines for firebase configurations).

in Xcode12 beta the Swift package manager fails to load dependencies

Recently the SPM has started to give me errors. Was working before.
I'm trying to use the AlamofireImage library but xcode fails to resolve de dependency and doesn't give any good explanation.
Does anybody know why and how to make it work?
this was once happened to me, maybe you can try to go ahead to File > Swift Packages > Update to Latest Package Versions. Let's see if that works
I ran into a similar issue when I was trying to arrange the files inside the project folder, and when I put them back to their old position the problem was resolved and the app run successfully.
I found something that's not ideal, but works for now. In your main xCode project file, go under Project not Target and find Package Dependencies. After finding it, remove the SDK, and then right click on the name of your project and add a package. This time when adding Firebase, use Minor version. It should hopefully resolve and install.

framework not found FirebaseInstanceID in Xcode

Step to reproduce.
I have added all the pod frameworks into my cordova project using XCode, after added, I don't know why the frameworks are whiten as this picture.
So I start to build the project again, the first error said framework not found FirebaseInstallation, I thought the whiten framework is not valid, so I manually add the framework from my frameworks folder which is downloaded from https://firebase.google.com/docs/ios/setup#frameworks and finally become the normal yellow icon.
I rebuild the project, this time the error is framework not found FirebaseCoreDiagnostics. Therefore, I repeat step 2 to add in the framework manually and compile again.
This time the error is also framework not found but it is FirebaseInstanceID. As you can see from my Pods folder above, there is no FirebaseInstanceID framework that I can manually add into my project. I have search online, there is no single file named FirebaseInstanceID.framework exist on the internet. Where can I download it actually?
Furthermore, is it the right way to manually add in all the pod frameworks into my project to solve the error? How can solve this kind of framework not found issue in Xcode? Thanks for any comment.
FirebaseInstanceID.framework is available in several of the folders from the download https://firebase.google.com/docs/ios/setup#frameworks, including FirebaseMessaging.

how to create jabberd xmpp client in ios9 using swift2

I am following this link
https://github.com/processone/xmpp-messenger-ios
but am getting couple of errors which are as follows
1.Could not build ObjectiveC module 'XMPPFramework'
2.CocoaAsyncSocket/GCDAsyncSocket.h file not found.
I have tried out ways such as
Built Setting on your project, then setting it like
User Header Search Paths = $(SRCROOT) // recursive.
Always Search User Paths = YES
But still errors persist.
Please help
To build the project, you need to have Cocoapods installed.
Then, you can check out the latest version of the project with Xcode 7.2.1 and open Example/xmpp-messenger-ios.xcworkspace
On first build all dependencies should be properly downloaded, but you need to use workspace and not project with Cocoapods.

How do I build frameworks in Xcode?

I'm trying to use the GData framework, so I downloaded it and it came as an Xcode project so I assumed I needed to build it. So I opened it up and and clicked run and it compiled fine, but where do I go to access the .framework it created? I'm new to frameworks and have only been using xcode for a month or two so you'll have to excuse my lack of knowledge about it.
The documentation will help you
Anyway, by default the target is GDataUnitTest, just change it to GDataFramework. Once you compile it you will find the framework in the folder of the XCode Project called target.

Resources