No such module found when importing SQLite in Xcode - ios

I am trying to import SQLite into an app in Xcode. The version of this app was originally developed using SQLite from the following link (not SQLite3).
https://github.com/stephencelis/SQLite.swift
The library has worked in previous iterations, but now I get an error that says "No such module SQLite" when I try to import the library at the top of the file I want to use it.
I have followed the instructions on the gitHub page and still have trouble with the library. One thing that I notice is that in the file explorer the SQLite.framework files are highlighted in red. I believe this is the source of the problem however, I don't know how to fix this.
File Picture:
Import Error:

It looks like you want to include SQLite into your ReadySetFit project? If so, what you really need to do is to follow the instructions under the "Installation" section found on the GitHub repo's main page. I'm a fan of Cocoapods (because all you'd need to do then is add a Podfile to the folder containing your ReadySetFit project), but there's also SwiftPackageManager or Carthage.
Along with the instructions in the SQLite github repo main page (or README.md), here's a tutorial on how to add a Podfile to your project.
I hope this helps!

Related

Swift iOS GoogleAPIClientForREST – Shell Script Invocation Error GTMSessionFetcher.framework: No such file or directory

I'm programming a Swift iOS app in XCode 9.2 (Dated, I know), and I've tried to integrate GoogleAPIClientForREST using Cocoapods. When you integrate GoogleAPIClientForREST (and possibly other pods, I don't know), it also downloads GTMSessionFetcher. Since the integration of the pods, the app won't run and gives this Shell Script Invocation Error:
/Users/username/Library/Developer/Xcode/DerivedData/Teachers_Assistant-aphjxihtqtmedabcymmxjlmxduzc/Build/Products/Debug-iphonesimulator/Teachers Assistant.app/Frameworks/GTMSessionFetcher.framework: No such file or directory
However, I can't open Teachers Assistant.app, as it's not a folder. GTMSessionFetcher.framework exists, but inside of the folder circled in red in the image at this link, not inside the .app file circled in blue.
I've tried the suggestions at this link, the suggestions in the question at this link, this link, this link, and this link. None of them have worked, though if you think that there was something I did wrong while trying to carry out those steps feel free to tell me.
All of my code is online at this repo, including the podfile. Thanks for the help!
Additional information: I plan on using the Google API to automate Sheets as a sort of storage information system to log attendance data and other miscellaneous information, if that helps at all.
Project's name should not contain special characters like ' or space, this could create some problems when Cocoapods try to link the libraries. I suggest you to change your project's name to TeachersAssistance (it worked for me). Here is the suggested steps:
Change project's name in the navigator. Xcode will recommend you to refractor the project, accept it:
Update podfile to point to new targets's names
Cocoapods will create a new workspace TeachersAssistance. Use it and delete the old one.
Remove Pods_Teacher__Assistance from new workspace. From now it will use Pods_TeachersAssistant.
Compile again and enjoy your project :)

Trouble with an .h import

As a beginner in ObjectiveC I need some help.
I'm working on a phonegap plugin for IOS (so, written with objective C). I use some open source code but I got an error with an .h import.
My architecture look like:
myFmk.framework/
myFmk.framework/ABCDE/myFmk.h <== in a sub folder
myFmk.framework/myFmk <=== this is a file
myPlugin.h
myPlugin.m
In myPlugin.h I have #import and in "myFmk.framework/myFmk" file I have only one line "ABCDE/".
I thought that this file do a redirection of the absolute import (with brackets) but my complier told me that "myFmk/myFmk.h" is not found.
I tried to find some documentation about this feature but I wasn't able to find its name... do you have this documentation or the feature name?
Thks.
Is the framework added using a cocoapod? If not, did you follow the instructions properly for adding it to your project? It would probably help if you posted the framework you are experiencing problems with.
If this is a framework that is added to your project properly and you are unable to import there are a few things you should check. First, go to your project settings (click on the project at the very top of your file tree in the left column) and then look for "linked libraries". See if the library is listed there. If not click the + and try to add it.
If this framework was added via cocoapods another thing to check is search your file structure for libPods.a. If it is red, I find sometimes it is helpful to delete it, close the project and run pod install again.
Also if you installed the project via cocoapods remember to open the workspace and not the old xcode project file.
I have also experienced this problem when my header search paths and other linker flag paths were wrong. Linker Flags should be $inherited if this is a cocoapod. In my projects most Header search paths are $inherited too.
If none of this is helpful please provide more information such as how this framework was added to your project and what the framework is. Also let us know if you get any error messages.

New relic iOS framework, header not found

I am using New Relic in my iOS app. In my original xcode-project things work as expected. When I check out the project from Git on another computer (or the same computer at another location), I am unable to find NewRelic.h. I get the following error when I try to build:
'NewRelicAgent/NewRelic.h' file not found
The framework is added to Git, and I use several other third party frameworks that work without problem. If I remove the New Relic import the rest of the project work as expected. In the non-functioning version that I check out, I have even tried to remove New Relic and re-add the framework, but this produces the same error.
I have searched the project for any absolute search paths, but it seems like there are none. I would like some advice on how to make xcode find the file.
This actually looks like a problem with xcode. A few users found a very simple fix that's outlined here: Why are static library headers not found?
Should be as simple as renaming the folder that contains the .xcodeproject.
I had this error when following their install instructions and imported the framework in the precompiled header. When importing it in the app delegate (which they explicitly state you should NOT do with the new version) everything works. Might be something with XCode6.1. Don't know.

UIKitExtension file not including in UI7Kit (iOS)

I am testing UI7Kit from this link.
After i download source code , i try to run it.
However the following file is not including.
#import <UIKitExtension/UIKitExtension.h>
Anyone who have experienced about UI7Kit and how can find that source code?
Out of curiosity I cloned the repository and it also gave me the error on build. So I did a google search for the class name and found this project, which you need to clone and reference in the project: https://github.com/youknowone/FoundationExtension
Edit: Upon further reading I realize what the problem is. You need to use CocoaPods to install the necessary framework I mentioned above: https://github.com/youknowone/UI7Kit#how-to-run-test-app

cant import NYXImagesKit library

I am trying to import the NYXImagesKit library in to my iOS 5.1 project but it will not show up as importable code. It cannot find the library. I have dragged the NYXImagesKit library in to the project and added the libraries. I have also added the following to my build phases:
However I still get an error saying it cannot find NYXImagesKit.h when i try to import it.
NYXImagesKit can be found from here: https://github.com/Nyx0uf/NYXImagesKit
Ive used this in a previous project so I know that it works.
screenshot of location of .h file:
header search paths:
You are not having an issue with "importing" the library proper. (I would not like to appear pedantic, but a library is linked, not imported). The issue you are having is with the header file which comes with the library.
To fix it, you should make sure to add the path to NYXImagesKit.h in your project build sentting (Search Headers Path). This can by found under Build options in your project settings.
Alternatively, an easier way is to add the NYXImagesKit.h file to your project (like any .m file). Then it will be found without the need to specify an header search path.
EDIT:
Since from what you report, everything seems ok, he only idea I can come up with is making sure that the paths are defined for your target (as opposed to the project overall); but I guess it is already like that.
Other than that, only resort is thinking that the project got corrupted somehow. You can inspect the project.pbxproj file inside your .xcodeproj document with a text editor and ensure that everything looks fine.
If everything fails, just start over with a new project.

Resources