Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't build as frameworkless target (update instructions) #407

Closed
chopson opened this issue Apr 14, 2016 · 3 comments
Closed

Can't build as frameworkless target (update instructions) #407

chopson opened this issue Apr 14, 2016 · 3 comments
Milestone

Comments

@chopson
Copy link

chopson commented Apr 14, 2016

Using Xcode 7.3 w/ Swift 2.2 to build Mac target.
Just grabbed a copy of SQLite.swift. I’m trying to use it in a command line tool. I (carefully?) followed the steps in the docs, but I get many errors - all seem to cascade from the import CSQLite statement, i.e. No such module. What am I missing?

FWIW, same target builds if I remove the SQLite source and link against the SQLite.framework.

Thanks for your help!

@t4ec
Copy link

t4ec commented Apr 25, 2016

Hi, same issue here: I've been using SQLite.swift for a while and there was no such issue before. I have just descided to update framework, grabbed fresh version from master branch and have the same problem: "No such module 'CSQLite'", I use frameworkless installation (iOS7)

@mbilovus
Copy link

mbilovus commented Apr 28, 2016

I've faced the same problem.
There is a similar problem described on the stackoverflow.
There is a comment that commenting out import CSQLite in three files Connection, Helpers, and Statement fixes the errors, but after doing this I got even more compiler errors.

I have two Xcode instances installed - one 6.2 in /Applications and another 7.3 in ~/Applications.
My project is iOS app on Swift with SQLite pod and I open it with the Xcode 7.3.
The SQLite pod has a file at project_folder/Pods/SQLite.swift/CocoaPods/iphonesimulator/module.modulemap
The file had the content

module CSQLite [system] {
    header "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/include/sqlite3.h"
    export *
}

, so it is referencing the sqlite3.h from the Xcode 6.2.
To fix this I did sudo xcode-select -switch ~/Applications/Xcode.app/ to select the active Xcode 7.3
Also I changed the content of module.modulemap to

module CSQLite [system] {
    header "/Users/<my_user_name>/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/usr/include/sqlite3.h"
    export *
}

These steps made my project compiled successfully.
Hope this will be helpful.

@jberkel jberkel added this to the 0.11.2 milestone Dec 8, 2016
@jberkel jberkel changed the title Can't build as frameless target Can't build as frameless target (update instructions) Dec 8, 2016
@jberkel jberkel changed the title Can't build as frameless target (update instructions) Can't build as frameworkless target (update instructions) Dec 8, 2016
@jberkel
Copy link
Collaborator

jberkel commented Dec 12, 2016

addressed in #560

@jberkel jberkel closed this as completed Dec 20, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants