stephencelis / SQLite.swift

A type-safe, Swift-language layer over SQLite3.
MIT License
9.57k stars 1.54k forks source link

Swift Compiler Error when project depend SQLite.swift and sqlite3_flutter_libs #1251

Open tbfungeek opened 3 months ago

tbfungeek commented 3 months ago

Issues are used to track bugs and feature requests.

Swift Compiler Error when project depend SQLite.swift and sqlite3_flutter_libs

Compiler Error as follows: Could not build the precompiled application for the device. Swift Compiler Error (Xcode): Redefinition of 'sqlite3_file' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:728:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_io_methods' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:834:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_vfs' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:1464:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_mem_methods' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:1764:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_module' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:7287:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_index_info' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:7431:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_index_constraint' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:7434:9

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_index_orderby' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:7441:9

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_index_constraint_usage' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:7446:9

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_vtab' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:7609:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_vtab_cursor' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:7633:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_mutex_methods' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:8130:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_pcache_page' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:8902:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_pcache_methods2' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:9067:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_pcache_methods' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:9090:7

Swift Compiler Error (Xcode): Redefinition of 'sqlite3_snapshot' /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:10464:15

Swift Compiler Error (Xcode): Typedef redefinition with different types ('struct (unnamed struct at /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:10465:16)' vs 'struct sqlite3_snapshot') /Users/ios/.jenkins/workspace/CardoryTest_iOS/build/ios/Debug-iphoneos/sqlite3/sqlite3.framework/Headers/sqlite3.h:10466:2

Swift Compiler Error (Xcode): Could not build Objective-C module 'SQLite3'

Uncategorized (Xcode): Command SwiftCompile failed with a nonzero exit code

Need help or have a general question? Ask on Stack Overflow (tag sqlite.swift).

Build Information

Podfile.lock as follows: PODS:

DEPENDENCIES:

SPEC REPOS: http://git.flatincbr.com:3000/tools-ios/cocoapod-repo.git:

EXTERNAL SOURCES: card_video_edit: :path: ".symlinks/plugins/card_video_edit/ios" connectivity_plus: :path: ".symlinks/plugins/connectivity_plus/ios" FLHttpManager: :commit: 499d134cfc :git: http://git.flatincbr.com:3000/tools-ios/FLNetwork.git FLRemoteConfig: :commit: 7a0ce2131d :git: https://git.flatincbr.com/tools-ios/FLRemoteConfig.git FLStatistic: :commit: 0cbbc2153a :git: https://git.flatincbr.com/tools-ios/FLStatistic.git Flutter: :path: Flutter flutter_email_sender: :path: ".symlinks/plugins/flutter_email_sender/ios" flutter_inappwebview_ios: :path: ".symlinks/plugins/flutter_inappwebview_ios/ios" flutter_native_splash: :path: ".symlinks/plugins/flutter_native_splash/ios" fluttertoast: :path: ".symlinks/plugins/fluttertoast/ios" image_gallery_saver: :path: ".symlinks/plugins/image_gallery_saver/ios" image_picker_ios: :path: ".symlinks/plugins/image_picker_ios/ios" in_app_purchase_storekit: :path: ".symlinks/plugins/in_app_purchase_storekit/darwin" ISNKit: :commit: 348e7055b1 :git: http://git.flatincbr.com:3000/tools-ios/ISNKit.git keyboard_utils: :path: ".symlinks/plugins/keyboard_utils/ios" lecle_social_share: :path: ".symlinks/plugins/lecle_social_share/ios" path_provider_foundation: :path: ".symlinks/plugins/path_provider_foundation/darwin" share_plus: :path: ".symlinks/plugins/share_plus/ios" shared_preferences_foundation: :path: ".symlinks/plugins/shared_preferences_foundation/darwin" sqflite: :path: ".symlinks/plugins/sqflite/darwin" sqlite3_flutter_libs: :path: ".symlinks/plugins/sqlite3_flutter_libs/ios" url_launcher_ios: :path: ".symlinks/plugins/url_launcher_ios/ios" video_player_avfoundation: :path: ".symlinks/plugins/video_player_avfoundation/darwin"

CHECKOUT OPTIONS: FLHttpManager: :commit: 499d134cfc :git: http://git.flatincbr.com:3000/tools-ios/FLNetwork.git FLRemoteConfig: :commit: 7a0ce2131d :git: https://git.flatincbr.com/tools-ios/FLRemoteConfig.git FLStatistic: :commit: 0cbbc2153a :git: https://git.flatincbr.com/tools-ios/FLStatistic.git ISNKit: :commit: 348e7055b1 :git: http://git.flatincbr.com:3000/tools-ios/ISNKit.git

SPEC CHECKSUMS: Alamofire: 3ca42e259043ee0dc5c0cdd76c4bc568b8e42af7 Apple-Cocoapod-KochavaCore: 60f450b08045e75905ddf8796525c1c9fe26339b Apple-Cocoapod-KochavaTracker: 5413fabff949ebcd8e4e1807d61721f375fbe11d AppsFlyerFramework: 5e4b385a27dc6179e132b1617f76809412eb2f88 BSText: fde17ab2d7b591745f73a408de0eeed063009b6a card_video_edit: c649b15b931086b35d0dade3a7bc74eccd54f155 CocoaLumberjack: f8d89a516e7710fdb2e9b8f1560b16ec6040eef0 connectivity_plus: bf0076dd84a130856aa636df1c71ccaff908fa1d CryptoSwift: a0799ee936271bd2253a006f1e4523df21845000 FBAEMKit: af2972f39bb0f3f7c45998f435b007833c32ffb2 FBSDKCoreKit: 19e2e18b3be578d7a51fed8fdd8c152bef0b9511 FBSDKCoreKit_Basics: dd9826ce3c9fd9f8cdf8dbbd0ef0a53e6c0c9e7e FBSDKShareKit: de5c291ad414ec07048ab09bae1b1b74b3ed92fe FLActivation: b9a840972195c70199c75412d5afbd7a508239d0 FLHttpManager: 878c0f8a14d2d37633799eb60d58f8e0c7fbb410 FLRemoteConfig: e20777b435a53eba682b7d20e96d7c6e75144280 FLStatistic: 60862475702614bcca4d0f0faeb0e178114df067 Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7 flutter_email_sender: 02d7443217d8c41483223627972bfdc09f74276b flutter_inappwebview_ios: 97215cf7d4677db55df76782dbd2930c5e1c1ea0 flutter_native_splash: 52501b97d1c0a5f898d687f1646226c1f93c56ef fluttertoast: 31b00dabfa7fb7bacd9e7dbee580d7a2ff4bf265 image_gallery_saver: cb43cc43141711190510e92c460eb1655cd343cb image_picker_ios: 99dfe1854b4fa34d0364e74a78448a0151025425 in_app_purchase_storekit: 0e4b3c2e43ba1e1281f4f46dd71b0593ce529892 ISNKit: ac1e7d636664604d863081f33764d99f515170df ISNLogger: 64a9dc6b5312a4113e0df615e1d5156162a353a7 keyboard_utils: ab24bc711be9e91a5937c20489056b8dd650fecc KeychainSwift: a06190cf933ad46b1e0abc3d77d29c06331715c7 lecle_social_share: 1eaf0a1944a236420863d9c5b201f3ac5a5d35c9 OrderedSet: aaeb196f7fef5a9edf55d89760da9176ad40b93c path_provider_foundation: 3784922295ac71e43754bd15e0653ccfd36a147c ReachabilitySwift: 985039c6f7b23a1da463388634119492ff86c825 share_plus: c3fef564749587fc939ef86ffb283ceac0baf9f5 shared_preferences_foundation: b4c3b4cddf1c21f02770737f147a3f5da9d39695 sqflite: 673a0e54cc04b7d6dba8d24fb8095b31c3a99eec SQLite.swift: 2992550ebf3c5b268bf4352603e3df87d2a4ed72 sqlite3: 73b7fc691fdc43277614250e04d183740cb15078 sqlite3_flutter_libs: aeb4d37509853dfa79d9b59386a2dac5dd079428 SwiftyStoreKit: 6b9c08810269f030586dac1fae8e75871a82e84a TikTokOpenSDK: dc1199ba9c6d7815aee0eaca6ec80ad13f7d9c1f Toast: ec33c32b8688982cecc6348adeae667c1b9938da TwitterCore: 8cbc9ad34d91c63a0035ea05bfbfc0d7ca72a28c TwitterKit5: 64095dfefcf39be2355711ef27112d55e340d90e url_launcher_ios: 6116280ddcfe98ab8820085d8d76ae7449447586 video_player_avfoundation: 02011213dab73ae3687df27ce441fbbcc82b5579 YYImage: 1e1b62a9997399593e4b9c4ecfbbabbf1d3f3b54

PODFILE CHECKSUM: 6b685b6354c4c9159f50199f27aee641d4d1dfa1

COCOAPODS: 1.13.0

It has nothing to do with the XCode version. My XCode version is Version 15.2 (15C500b)

I use CocoaPods 1.13.0

tbfungeek commented 3 months ago

The same issue here https://github.com/simolus3/sqlite3.dart/issues/208