1

我有一个 ant 脚本,可以构建和部署适用于 android 的 MFP 应用程序(wlapp 和 apk)。我还将应用程序上传到 AppCenter。

问题是我无法使用 AppCenter 应用程序从 AppCenter 安装(在设备 - 华为 P6 上)apk - 它下载了应用程序但安装不成功。上传的应用程序未签名。

从 MFP Studio 运行 Android 应用程序可以正常工作。

为了使从 AppCenter 应用程序的安装正常工作,我必须执行哪些步骤?在哪里可以查看 AppCenter 的日志?

谢谢!

蚂蚁目标:

    <target name="build-android-windows" if="isWindows" description="Build the Android .apk" depends="">
    <!-- These must be set in your local.properties file in the root of the android project.
         This is sensitive information and is not checked into the repository
    <fail unless="android.store" message="Property android.store missing" />
    <fail unless="android.alias" message="Property android.alias missing" />
    <fail unless="android.store.password" message="Property android.store.password missing" />
    <fail unless="android.alias.password" message="Property android.alias.password missing" />
    -->
    <!-- use android.release_target if defined, otherwise default to 'release' -->
    <property name="android.release_target" value="release"/>

    <!-- call the project's build.xml to clean -->
    <ant antfile="${src.dir}/apps/${curBrand}/android/native/build.xml" inheritAll="false" useNativeBasedir="true" target="clean"/>

    <!-- call the project's build.xml to make a build -->
    <ant antfile="${src.dir}/apps/${curBrand}/android/native/build.xml" inheritAll="false" useNativeBasedir="true" target="${android.release_target}" />
    <!-- copy the file to build.dir -->
    <copy file="${src.dir}/apps/${curBrand}/android/native/bin/${curBrand}-${android.release_target}-unsigned.apk" tofile="${build.dir}/android/${build.apk}" overwrite="true" failonerror="true"/>

</target>
4

1 回答 1

0

正如 Vivin 在评论中建议的那样,AppCenter不是Google Play,这意味着至少从设备的角度来看,它不是“受信任的来源”,因此您可能确实需要在 Android 的选项中启用该选项。

第二个选项正如我所提到的 - 签署 .apk。当您直接从 Eclipse 构建时,它默认使用调试签名并直接进入设备。

于 2015-12-09T05:01:43.093 回答