Skip to content

Will not build on iOS 14 XCode 12 #1039

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

Closed
austenstrine opened this issue Jan 4, 2021 · 5 comments
Closed

Will not build on iOS 14 XCode 12 #1039

austenstrine opened this issue Jan 4, 2021 · 5 comments

Comments

@austenstrine
Copy link

I'm using Xcode 12.3, and affects devices on iOS 14+.
Here is the version of SQLite.swift I am using in my podfile:
pod 'SQLite.swift/SQLCipher', '~> 0.12.0'

This was working 3-4 months ago when I checked last. Now it gives me compiler errors:

SQLCipher/SQLCipher.framework/Headers/sqlite3.h:678:8: error: redefinition of 'sqlite3_file'
SQLCipher/SQLCipher.framework/Headers/sqlite3.h:777:8: error: redefinition of 'sqlite3_io_methods'
SQLCipher/SQLCipher.framework/Headers/sqlite3.h:1347:8: error: redefinition of 'sqlite3_vfs'
SQLCipher/SQLCipher.framework/Headers/sqlite3.h:1644:8: error: redefinition of 'sqlite3_mem_methods'
SQLCipher/SQLCipher.framework/Headers/sqlite3.h:6447:8: error: redefinition of 'sqlite3_module'
SQLCipher/SQLCipher.framework/Headers/sqlite3.h:6581:8: error: redefinition of 'sqlite3_index_info'
SQLCipher/SQLCipher.framework/Headers/sqlite3.h:6584:10: error: redefinition of 'sqlite3_index_constraint'
SQLCipher/SQLCipher.framework/Headers/sqlite3.h:6591:10: error: redefinition of 'sqlite3_index_orderby'
...and some 18 more of the same.

And it seems I'm not the only one to experience this issue:
https://stackoverflow.com/questions/63971403/why-does-xcode12-give-me-sqlite-compiler-error

They have identified a workaround, but I would have to abandon the SQLCipher branch, which would be a very bad idea because of what I am using the package for.

Is there any chance we could get this to a point where it can compile without wonky workarounds?

Otherwise, I will be completely screwed for relying on this package when I built it into the app I'm maintaining in April of 2020. If you're going to abandon a package, say as much so that people don't build it into their projects, and so that people who have it in their projects already can start replacing it.

@khsora34
Copy link

We did this for our project: https://stackoverflow.com/questions/64803179/how-do-i-avoid-build-errors-when-i-include-sqlcipher-pod-in-swift-project/65020426#65020426.
You have to download the SQLite.swift library and used it locally, and adding SQLCipher as an external dependency.

@ANGEL1YS
Copy link

We did this for our project: https://stackoverflow.com/questions/64803179/how-do-i-avoid-build-errors-when-i-include-sqlcipher-pod-in-swift-project/65020426#65020426.
You have to download the SQLite.swift library and used it locally, and adding SQLCipher as an external dependency.

still had same issue redefinition of bla bla bla, am i miss something ?

@khsora34
Copy link

The answer in stack overflow worked for our project, dunno any further...

@jiejueld
Copy link

jiejueld commented Feb 1, 2021

pod 'SQLCipher', '= 4.2.0'
pod 'SQLite.swift/SQLCipher', '~> 0.12.2'

and change code in 'SQLiteObjc.h'

change line26: @import SQLite3; to @import SQLCipher;

this is work for me.

xcode 12.2 mac mini m1

@nathanfallet
Copy link
Collaborator

Should be fixed by #1051 and #1053

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

5 participants