[MOD-2504] Missing linker flags in appcelerator.encrypteddatabase module
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Critical |
Status | Resolved |
Resolution | Fixed |
Resolution Date | 2019-04-10T19:15:13.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | Encrypted SQLite DB |
Labels | ios |
Reporter | Ryan Aston |
Assignee | Jan Vennemann |
Created | 2019-03-24T03:46:33.000+0000 |
Updated | 2019-04-10T19:15:13.000+0000 |
Description
When attempting to build a project with the encrypted database module for the iOS simulator in the environment above the xcodebuild linker step fails. Runningappc run -p ios -l trace
shows the following error:
{noformat}
[TRACE] Undefined symbols for architecture x86_64:
[TRACE] "_inflate", referenced from:
[TRACE] _zipfileColumn in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_deflateInit2_", referenced from:
[TRACE] _zipfileDeflate in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_compressBound", referenced from:
[TRACE] _zipfileDeflate in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_deflate", referenced from:
[TRACE] _zipfileDeflate in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_inflateInit2_", referenced from:
[TRACE] _zipfileColumn in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_deflateEnd", referenced from:
[TRACE] _zipfileDeflate in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_inflateEnd", referenced from:
[TRACE] _zipfileColumn in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_crc32", referenced from:
[TRACE] _zipfileStep in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] _zipfileUpdate in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_uncompress", referenced from:
[TRACE] _uncompressFunc in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] "_compress", referenced from:
[TRACE] _compressFunc in libappcelerator.encrypteddatabase.a(sqlite3.o)
[TRACE] (maybe you meant: _sqlite3_compress_init
[TRACE] )
[TRACE] ld: symbol(s) not found for architecture x86_64
[TRACE] clang: error:
[TRACE] linker command failed with exit code 1 (use -v to see invocation)
[ERROR] ** BUILD FAILED **
[ERROR] The following build commands failed:
[ERROR] Ld /Users/ryanaston/Projects/EncDBiOSBuildBug/build/iphone/build/Products/Debug-iphonesimulator/EncDBiOSBuildBug.app/EncDBiOSBuildBug normal x86_64
[ERROR] (1 failure)
{noformat}
Researching this issue I found that adding OTHER_LDFLAGS= -lz
to the module.xcconfig file fixes the issue. If another module in the project has already set this flag it actually works fine, but when this module is alone it will not build without that flag.
This happens with both version 2.0.5 and the unofficial build of 2.0.6 we were provided for testing purposes.
Demo project here: https://drive.google.com/file/d/1SMUz7HxNPQPUj6H48Q_NOMYwhhrj7Qd8/view?usp=sharing
Attachments
File | Date | Size |
---|---|---|
Screen Shot 2019-04-07 at 4.22.33 PM.png | 2019-04-07T10:24:53.000+0000 | 34184 |