react-native-image-tools
react-native-image-tools copied to clipboard
Multidex error on android
MainApplication.java:46: error: cannot find symbol
MultiDex.install(getBaseContext());
^
symbol: variable MultiDex
location: class MainApplication
This is my MainAppllication.java
file:
@Override
public void onCreate() {
super.onCreate();
MultiDex.install(getBaseContext());
AdobeCSDKFoundation.initializeCSDKFoundation(getApplicationContext());
SoLoader.init(this, /* native exopackage */ false);
}
Looks like you're missing an import.
I just removed this line MultiDex.install(getBaseContext());
and it works fine. Will I run into trouble later? I have no idea about native java code.
You app won't start if DEXing is an issue, but it's easy enough to overcome.
Il go over this again and update this thread if I manage to fix my issue in a proper way.
Did anyone resolve this issue?
Followed the install instructions and faced the same issue. As what the contributor said, an import is missing. Install.md did not include the import for the multidex so you will need to add that by yourself.
@flyandi Add this to your MainApplication.java and it will works:
import android.support.multidex.MultiDex;
Remember to also pull in Context: import android.content.Context;
for the attachBaseContext(Context base) method