HERE Maps Android Integration, MISSING_LIBRARIES Error

前端 未结 3 1174
臣服心动
臣服心动 2021-01-18 20:35

I followed the steps https://developer.here.com/mobile-sdks/documentation/android/topics/app-simple-android-studio.html

but I am getting error as : Cannot initializ

相关标签:
3条回答
  • 2021-01-18 21:14

    This can happen also If you have another lib with JNI in project. In that case include following code under buildType in build.gradle:

            splits {
                abi {
                    enable true
                    reset()
                    include 'armeabi-v7a'
                    universalApk false
                }
            }
    
    0 讨论(0)
  • 2021-01-18 21:15

    I believe you're looking at the wrong documentation. On this page: https://developer.here.com/documentation there are two versions of the HERE Android Mobile SDK listed, SDK for Android Starter and SDK for Android Premium. You are looking at the documentation for Starter when I think you want Premium.

    The Premium SDK has a native library component which needs to be included in the build. Try this page: https://developer.here.com/mobile-sdks/documentation/android-hybrid-plus/topics/app-simple-android-studio.html ("Add HERE SDK Libraries to Your Project" section)

    Specifically, I believe these are the sections you missed:

    • From the directory where you installed the HERE SDK, copy the contents of the HERE-sdk/libs/armeabi-v7a folder to your project's app/src/main/jniLibs/armeabi folder. You need to create the jniLibs and armeabi subfolders.

    • Within the same section in your AndroidManifest.xml file, add the following lines:

      <service android:name="com.here.android.mpa.service.MapService" android:label="HereMapService" android:process="global.Here.Map.Service.v2" android:exported="true" > <intent-filter> <action android:name="com.here.android.mpa.service.MapService" > </action> </intent-filter> </service>

    UPDATE

    As of HERE SDK version 3.3 the SDK is delivered as an Android Archive (AAR) file. Therefore, you no longer need to manually copy the native libraries as mentioned in the first bullet above. You can simply include the AAR file in your build.gradle file. e.g.:

    // Assuming you have placed the HERE-sdk.aar in a folder 'libs'
    repositories {
        flatDir {
            dirs 'libs'
        }
    }
    
    dependencies {
       ...
       compile(name: 'HERE-sdk', ext: 'aar')
       ...
    }
    
    0 讨论(0)
  • 2021-01-18 21:15

    Be sure your device meets the system requirements listed here. Specifically, be sure your device is ARM and not x86.

    I've encountered the 'MISSING_LIBRARIES' error when running HERE maps on the HP Pro Slate 10 EE G1. This tablet is x86 which is not supported by the current HERE SDK. ARM native code runs on Intel x86 using an emulator named Houdini. Explanation on that can be found here.

    Unfortunately I know this doesn't fix your issue. Yet it may help you understand why the app will not initialize the map.

    0 讨论(0)
提交回复
热议问题