예제 #1
0
        private static string GetAapt2Path()
        {
            var newestBuildToolsVersion = AndroidBuildTools.GetNewestBuildToolsVersion();
            var newestBuildToolsPath    = Path.Combine(AndroidBuildTools.GetBuildToolsPath(), newestBuildToolsVersion);

            return(Path.Combine(newestBuildToolsPath, "aapt2"));
        }
        private static string GetApkSignerJarPath()
        {
            var newestBuildToolsVersion = AndroidBuildTools.GetNewestBuildToolsVersion();

            if (newestBuildToolsVersion == null)
            {
                return(null);
            }

            var newestBuildToolsPath = Path.Combine(AndroidBuildTools.GetBuildToolsPath(), newestBuildToolsVersion);
            var apkSignerJarPath     = Path.Combine(newestBuildToolsPath, "lib/apksigner.jar");

            if (File.Exists(apkSignerJarPath))
            {
                return(apkSignerJarPath);
            }

            Debug.LogErrorFormat("Failed to locate apksigner.jar at path: {0}", apkSignerJarPath);
            return(null);
        }