SQLite.swift unknown type name 'NS_ASSUME_NONNULL_BEGIN' - sqlite.swift

I'm using SQLite.swift. There's an error "Unknown type name 'NS_ASSUME_NONNULL_BEGIN'" when I build the project.
What I do:
create a demo project 'SqlDemo'
under SqlDemo/, create Podfile
use_frameworks!
source 'http://git.oschina.net/akuandev/Specs.git'
pod 'SQLite.swift', git:'https://github.com/stephencelis/SQLite.swift.git'
# pod 'SQLite.swift/Cipher', git: ... # instead, for SQLCipher support
~
then 'pod install'
after that open SqlDemo.xcworkspace
build the project
this maybe a pretty simple error. I'm new to ios dev.

Related

Xcode 14 giving build error for flurry sdk

After updating to xcode 14 I'm getting build error
error build: Undefined symbol: _OBJC_CLASS_$_Flurry
error build: Undefined symbol: _OBJC_CLASS_$_FlurrySessionBuilder
I tried cleaning pods and reinstalling pods and also I tried adding libFlurry_11.2.1.a in build phases, it didn't work.
Platform target in pods is '12.1' and for flurry below command is used
pod 'Flurry-iOS-SDK/FlurrySDK', '~> 11.2.0'
I had to contact support but for me this worked:
pod 'Flurry-iOS-SDK/FlurrySDK', '~> 12.1.1'
and the "startSession" has changed to:
Flurry.startSession(apiKey: "***", sessionBuilder: FlurrySessionBuilder.init()
.build(crashReportingEnabled: true)
.build(logLevel: .all))
PS: Your "startSession" might be different. It depends on what you need.

"No such module 'Firebase'" // framework not found FirebaseUI

I previously had Firebase connected to my app with the below pods (excluding pod 'Firebase/DynamicLinks) and it was working just fine. I was using the line 'import Firebase' at the top of each view controller to import the relevant frameworks.
However, today I went to add pod 'Firebase/DynamicLinks' and when I went to run pod install, it got stuck 'analyzing dependencies'. I read through other forums on stackoverflow to fix this issue. I ended up removing cocoapods from my project and reinstalling them. I now have reinstalled the pods, but when I open Xcode I get the message 'No such module 'Firebase'. It essentially wants me to import specific Firebase modules [import FirebaseDatabase, import FirebaseAnalytics, etc.] instead of just [import Firebase]. After updating the import on all of my view controllers, there is 1 issue remaining -> 'Framework not found FirebaseUI'.
Questions
Is going from 'import Firebase' to 'import FirebaseDatabase, etc.' recommended or is this a step backwards?
How can I resolve 'Framework not found FirebaseUI'? I have the pod installed already.
Other info that may help
When running pod install, I get a warning notification: [!] [Xcodeproj] Generated duplicate UUIDs
When trying to build project, I also get: ld: warning: directory not found for option '-F/Users/[myNameHere]/Library/Developer/Xcode/DerivedData/[AppName]-dtipemvgjzrgzvephbatansalrwu/Build/Products/Debug-iphonesimulator/Firebase'
As well as: ld: warning: directory not found for option '-F/Users/[myNameHere]/Library/Developer/Xcode/DerivedData/[AppName]-dtipemvgjzrgzvephbatansalrwu/Build/Products/Debug-iphonesimulator/FirebaseUI'
My podfile
pod 'FirebaseUI'
pod 'FirebaseUI/Auth'
pod 'Firebase/Core'
pod 'Firebase/Database'
pod 'Firebase/Messaging'
pod 'Firebase/Analytics'
pod 'Firebase/Storage'
pod 'Firebase/Auth'
pod 'FirebaseUI/Google'
pod 'FirebaseUI/Facebook'
pod 'Firebase/DynamicLinks' (new)
After rereading the Firebase documentation, it turns out "You no longer need to add the iOS pod Firebase/Core. This SDK included the Firebase SDK for Google Analytics."
I ended up removing Core and the UI Cocoapods (using my own UI buttons instead) and the project now builds. I assume there may be an error installing the UI Framework with the FirebaseUI Cocoapod - idk.
Pods removed:
- pod 'Firebase/Core'
- pod 'FirebaseUI'
- pod 'FirebaseUI/Auth'
- pod 'FirebaseUI/Google'
- pod 'FirebaseUI/Facebook'

dyld: Library not loaded: #rpath/ ... Reason: image not found with a simple Hello world applicat

I am running into some trouble when trying to use SwiftCSV using CocoaPods and following the basic instructions.
After creating the simple Hello world console application for OS X from the template in XCode 7.3.1, I opened a terminal window and navigated to the project folder and issued a pod init
I then edited Podfile by adding the line below in the target section:
pod "SwiftCSV"
I then executed pod install, which completed successfully.
After loading the resulting .xcworkspace in XCode, when I run the application, I get the following error:
dyld: Library not loaded: #rpath/SwiftCSV.framework/Versions/A/SwiftCSV
Referenced from: /Users/paolomarini/Library/Developer/Xcode/DerivedData/BundleGeneratorSwift-egsxgxpdiuvqrfddzyzcxnwltulk/Build/Products/Debug/BundleGeneratorSwift
Reason: image not found
Program ended with exit code: 9
Note that I didn't specify a platform in Podfile as I can't figure out what the correct value is for OS X. The Podfile is as below:
# Uncomment this line to define a global platform for your project
# platform :ios, '9.0'
target 'BundleGeneratorSwift' do
# Comment this line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for BundleGeneratorSwift
pod "SwiftCSV"
end
Thanks,
Paolo

Xamarin iOS Framework Binding

I am trying to create a binding for the WePay Framework:
https://github.com/wepay/wepay-ios
Following are the steps that I followed.
I installed CocoaPods.
I installed ObjectiveSharpie
I run this command in terminal : $ sharpie pod init ios WePay
And I get this error: Could not install CocoaPod
here is the full error message:
** Setting up CocoaPods master repo ...
(this may take a while the first time)
Setting up CocoaPods master repo
$ /usr/bin/git pull --ff-only
From https://github.com/CocoaPods/Specs
ee36ba4..8c6767d master -> origin/master
Updating ee36ba4..8c6767d
Fast-forward
Specs/BluetoothKit/0.3.0/BluetoothKit.podspec.json | 35 ++++++++++++++++++++++
1 file changed, 35 insertions(+)
create mode 100644 Specs/BluetoothKit/0.3.0/BluetoothKit.podspec.json
Setup completed
** Searching for requested CocoaPods ...
** Working directory:
** - Writing Podfile ...
** - Installing CocoaPods ...
** (running pod install --no-integrate --no-repo-update)
[!] Unknown option: --no-integrate
Did you mean: --no-ansi?
Usage:
$ pod install
Downloads all dependencies defined in `Podfile` and creates an Xcode Pods
library project in `./Pods`.
The Xcode project file should be specified in your `Podfile` like this:
project 'path/to/XcodeProject.xcodeproj'
If no project is specified, then a search for an Xcode project will be
made. If more than one Xcode project is found, the command will raise an
error.
This will configure the project to reference the Pods static library, add
a build configuration file, and add a post build script to copy Pod
resources.
Options:
--repo-update Force running `pod repo update` before
install
--project-directory=/project/dir/ The path to the root of the project
directory
--silent Show nothing
--verbose Show more debugging information
--no-ansi Show output without ANSI codes
--help Show help banner of specified command
error: could not install CocoaPod
Well apparently the most recent CocoaPods removed the --no-integrate option that objective sharpie uses. Downgrading cocoapods to 0.39.0 should fix your issue. It worked for us.

Cocoapods error

From my Podfile: why does this work:
pod 'RestKit', :git => 'git#github.com:EATechnologies/RestKit.git', :commit => '56401aaa5b3714bbde5d2852f92c0b29e392b460'
but this does not:
pod 'RestKit', :git => 'git#github.com:EATechnologies/RestKit.git', :commit => '0831f2dc2da01731d37795a2c3bd8acb4045dda9'
When I use the latter, I get an error that looks like this:
$pod update
Updating spec repo `master'
-> Pre-downloading: 'MCSMKeychainItem'
-> Pre-downloading: 'RestKit'
[!] Failed: /usr/bin/git rev-list --max-count=1 0831f2dc2da01731d37795a2c3bd8acb4045dda9
[!] Failed: /usr/bin/git rev-list --max-count=1 0831f2dc2da01731d37795a2c3bd8acb4045dda9
[!] Cache unable to find git reference `0831f2dc2da01731d37795a2c3bd8acb4045dda9' for `git#github.com:EATechnologies/RestKit.git'.
This seems to have been fixed with Cocoapods 0.15.1.
1 - first install git (command line tool for mac)
link to download is : http://git-scm.com/download/mac
2 - then open commind line (or terminal) and type
$ sudo gem install cocoapods (you need to wait here , be patient)
3 - now you can shoot the command "pod --version" to check the version of the pod you just installed.
4 - shoot again pod search libpusher (just an example of a library, you can type any library name here instead of 'libpusher' ).
5- let it be complete , it may take some time.
6- then most imp step , create the pod file , (name can be 'podfile') in your project directory and add it to your project in Xcode.
7 - Now Here the secret is : you need to provide the path to this pod file too here , so type command:
cd /Rakesh/vidyo_demo/vidyo_phonegap/ios (eg.)
after cd command rest is the path of the pod file directory.
8- and now when you will type 'pod install ' command in terminal.
and all libraries (which are written in podfile) will get installed on your project path. just then open the project which now has a workspace file. like demo.xcworkspace (open it)
9- here is the format of pod file:
platform :ios, '7.0'
pod 'libPusher', '~> 1.4'

Resources