Original address:/HTTP blog.csdn.net/alking_sun/article/details/36624491
It's been almost 2 years since I Unity3d SDK integration, and I've met a lot of tricky SDKs, which are based on the operator's SDK.
In one of my other articles, I mentioned the workaround for moving mm to not find the file Mmiap.xml after using unity packaging.
The most obvious occurrence of this behavior is:
1. Use the IDE to run the official demo, or to do the test program yourself, it is normal to run
2. But after using Unity3d packaging, you will find that it is not working properly. In Logcat, you will find that the XXXX file is generally not found.
For example:
When integrating the Unicom SDK, an error will be raised: Java.io.filenotfoundexception:armeabi/libunicomsdk.jar
Similar to this phenomenon I have seen a lot, and then I found the reason:
The jar package that is given by the
operator includes not only the. class file, but also the assets resource file in the package.
For the certificate:
1. Move mm Mmsmsbilling1.2.3.jar Package contents.
2. Unicom SDK package content.
The workaround is also simple:
1. Extract the jar package using the decompression software
2. Copy the files that were extracted under folder/assets/to the project's assets folder.
3. Use the JAR-CVF command to package the remaining COM CN folders containing. class files into a new jar package
4. Place the new jar package under the project's Libs file.
5. Use Unity to pack it up OK