Skip to content

Commit

Permalink
[go] enable bytecode vtab for sqlite (#28281)
Browse files Browse the repository at this point in the history
# Why

enable the sqlite bytecode vtab feature for livestore integration

# How

originally i was thinking to add the feature as a builtin to all
expo-sqlite libs but the sqlite3.podspec is not published yet. let's add this for expo-go first. for people using
development builds, they could use a config-plugin to enable the feature.
  • Loading branch information
Kudo committed Apr 18, 2024
1 parent b5b404c commit 355469e
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 1 deletion.
3 changes: 3 additions & 0 deletions apps/expo-go/android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,6 @@ hermesEnabled=true

# Remove this workaround when upgrading to react-native@0.72.1
kotlin.jvm.target.validation.mode=warning

# Enable SQLite bytecode vtable support
expo.sqlite.customBuildFlags=-DSQLITE_ENABLE_BYTECODE_VTAB
8 changes: 8 additions & 0 deletions apps/expo-go/ios/Podfile
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,14 @@ target 'Expo Go' do
end
end

# Enable SQLite bytecode vtable support
if pod_name == 'sqlite3'
target_installation_result.native_target.build_configurations.each do |config|
config.build_settings['OTHER_CFLAGS'] ||= ['$(inherited)']
config.build_settings['OTHER_CFLAGS'] << '-DSQLITE_ENABLE_BYTECODE_VTAB=1'
end
end

if pod_name.end_with?('EXUpdates')
target_installation_result.native_target.build_configurations.each do |config|
config.build_settings['GCC_PREPROCESSOR_DEFINITIONS'] ||= ['$(inherited)']
Expand Down
2 changes: 1 addition & 1 deletion apps/expo-go/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2472,6 +2472,6 @@ SPEC CHECKSUMS:
Yoga: 86380678e6a08c6fa2215fd252543ff375d441d1
ZXingObjC: 8898711ab495761b2dbbdec76d90164a6d7e14c5

PODFILE CHECKSUM: 08d42139077d6c9a60951d31532300d7f641d419
PODFILE CHECKSUM: 8e254aedd171796e47705c1b9624bb875f85115c

COCOAPODS: 1.14.2

0 comments on commit 355469e

Please sign in to comment.