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

iOS debug builds failing when compiling AESCrypt.cpp #1468

Closed
TechWilk opened this issue Jan 3, 2025 · 17 comments
Closed

iOS debug builds failing when compiling AESCrypt.cpp #1468

TechWilk opened this issue Jan 3, 2025 · 17 comments

Comments

@TechWilk
Copy link

TechWilk commented Jan 3, 2025

Note:

Having upgraded from MMKV Core 1.3.9 to 1.3.12 I can no longer build my project. AESCrypt.cpp won't compile.

The version of MMKV

MMKV Core 1.3.12 LTS

The platform of MMKV

iOS

The installation of MMKV

Cocoapods

What's the issue?

Compile AESCrypt.cpp (arm64) fails to build

image

@how2fft
Copy link

how2fft commented Jan 4, 2025

same builds failing

lingol added a commit that referenced this issue Jan 6, 2025
@lingol
Copy link
Collaborator

lingol commented Jan 6, 2025

It's fixed in the 1.3.x_lts branch.
The next version with this fix won't come out soon because v1.3.12 has just been released. You can redirect your Podfile's source to this branch if you are in a hurry.

@efstathiosntonas
Copy link

efstathiosntonas commented Jan 10, 2025

@lingol you can't be serious, right? Critical bug that breaks everything and you won't ship 1.3.13 because........ 1.3.12 is just released? Seriously?

@lingol
Copy link
Collaborator

lingol commented Jan 10, 2025

  1. First of all, it's only an error on debug build.

  2. Secondly, there's a hot-fix solution to modify your Podfile to the lts branch.

  3. And finally, it's only on the LTS version and it's mainly for the Android platform with 32-bit support, iOS platform could just upgrade to v2.0+.

So no, it's not a critical bug to fix in a hurry.

@lingol
Copy link
Collaborator

lingol commented Jan 10, 2025

Here's the hot-fix solution to modify the Podfile to redirect to the lts branch.

target 'YourTarget' do
  # pod 'MMKV', '~> 1.3.12'
  pod 'MMKV', :git => 'https://github.com/Tencent/MMKV.git', :branch => '1.3.x_lts'
end

@paulschreiber
Copy link

@lingol how can Expo users specify a branch in app.config.ts?

@lingol
Copy link
Collaborator

lingol commented Jan 11, 2025

@paulschreiber I'm not familiar with that. Tried asking ChatGPT and get a looks like working solution. You can try AI too.

Here's my prompt:

In podfile we can do this: pod 'MMKV', :git => 'https://github.com/Tencent/MMKV.git', :branch => '1.3.x_lts', how to do the same in expo?

@trcoffman
Copy link

We fixed our expo builds by just using 1.3.9

ammarahm-ed/react-native-mmkv-storage#372 (comment)

@trcoffman
Copy link

trcoffman commented Jan 11, 2025

It's fixed in the 1.3.x_lts branch.
The next version with this fix won't come out soon because v1.3.12 has just been released. You can redirect your Podfile's source to this branch if you are in a hurry.

Not releasing a fix because you just did a release makes no sense. Why not just publish 1.3.13 with this fix?!

@lingol
Copy link
Collaborator

lingol commented Jan 12, 2025

Just out of curiosity, if this is such a pain in the ass, why don't you guys just upgrade to v2.0+?

@trcoffman
Copy link

trcoffman commented Jan 12, 2025

Just out of curiosity, if this is such a pain in the ass, why don't you guys just upgrade to v2.0+?

Because it's an indirect dependency in their apps via react-native-mmkv-storage. People don't want to fork that library just because there is an unreleased fix in MMKV that's already been written and is just waiting to be released.

I've already worked around this but you will save the world many hours of wasted labor by releasing this fix.

@lingol
Copy link
Collaborator

lingol commented Jan 12, 2025

Thanks for the info. @trcoffman

@lingol
Copy link
Collaborator

lingol commented Jan 13, 2025

With these background info, I will publish an update as soon as possible. Sorry for any inconvenience.

@lingol
Copy link
Collaborator

lingol commented Jan 13, 2025

MMKV for iOS v1.3.13 is live.

@lingol lingol closed this as completed Jan 13, 2025
@trcoffman
Copy link

@lingol Thank you very much! Your hard work on MMKV is much appreciated.

@nateshmbhat
Copy link

nateshmbhat commented Jan 21, 2025

@lingol can u also release a flutter version with this fix please ?

@lingol
Copy link
Collaborator

lingol commented Jan 21, 2025

@nateshmbhat The mmkv plugin for flutter adopted the federated plugin framework. In iOS it is the mmkv_iOS plugin that implements the ffi functionality. And it depends the MMKV pod by ">=1.3.9, <2.0". So it is already fixed. All you need to do is upgrade your pod, like pod update.

https://github.com/Tencent/MMKV/blob/1.3.x_lts/flutter/mmkv_ios/ios/mmkv_ios.podspec#L23

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

7 participants