[HSP3Dishメモ]デバッグ用のapkを作成する
「 HSP3Dish helper ver1.74」から実行します。
この画面で「ビルド」を押せばOKですが、私はテンプレ的に先に「クリーン」をしてます。
「クリーン」→「ビルド」
※クリーン C:\android\pokemon\obj\local*.* Buildfile: C:\android\pokemon\build.xml -check-env: [checkenv] Android SDK Tools Revision 25.2.5 [checkenv] Installed at C:\android\android-sdk\sdk -setup: [echo] Project Name: pokemon [gettype] Project Type: Application -pre-clean: clean: [delete] Deleting directory C:\android\pokemon\bin [delete] Deleting directory C:\android\pokemon\gen [getlibpath] Library dependencies: [getlibpath] No Libraries [subant] No sub-builds to iterate on BUILD SUCCESSFUL Total time: 2 seconds
次は「ビルド」のログ(長いので飛ばしてください。
HSP script preprocessor ver3.6beta3 / onion software 1997-2020(c) Use file [hspdef.as] Use file [dish_enhance.as] HSP code generator ver3.6beta3 / onion software 1997-2020(c) Code size (598) String data size (62) param size (0) Vars (7) Labels (6) Modules (0) Libs (0) Plugins (2) No error detected. (total 846 bytes) use HSP3Dish mode. [armeabi-v7a] Compile++ thumb: pokemon <= hspsource.cpp jni/hsp3embed/hspsource.cpp:38:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ jni/hsp3embed/hspsource.cpp:51:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("C:\android\pokemon\assets"); ^ jni/hsp3embed/hspsource.cpp:60:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("bgd"); PushFuncEnd(); PushFuncEnd(); PushInt(20); ^ jni/hsp3embed/hspsource.cpp:62:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("%02d"); ^ jni/hsp3embed/hspsource.cpp:63:41: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushIntfunc(259,2); CalcAddI(); PushStr(".jpg"); CalcAddI(); ^ jni/hsp3embed/hspsource.cpp:67:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("button.png"); ^ jni/hsp3embed/hspsource.cpp:152:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr(""); ^ jni/hsp3embed/hspsource.cpp:187:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ 8 warnings generated. [armeabi-v7a] Compile++ thumb: pokemon <= main.cpp jni/main.cpp:175:39: warning: format specifies type 'unsigned int' but the argument has type 'ANativeWindow ' [-Wformat] LOGI("**CMD_INIT_WINDOW(%x)",engine->app->window); ^^ ^^^^^^^^^^^^^^^^^^^ ../hsplib36b3/appengine.h:16:83: note: expanded from macro 'LOGI' define LOGI(…) ((void)_android_log_print(ANDROID_LOG_INFO, "native-activity", _VA_ARGS_)) ^^^^^^^^^^^ 1 warning generated. [armeabi-v7a] SharedLibrary : libpokemon.so [armeabi-v7a] Install : libpokemon.so => libs/armeabi-v7a/libpokemon.so [arm64-v8a] Compile++ : pokemon <= hspsource.cpp jni/hsp3embed/hspsource.cpp:38:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ jni/hsp3embed/hspsource.cpp:51:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("C:\android\pokemon\assets"); ^ jni/hsp3embed/hspsource.cpp:60:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("bgd"); PushFuncEnd(); PushFuncEnd(); PushInt(20); ^ jni/hsp3embed/hspsource.cpp:62:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("%02d"); ^ jni/hsp3embed/hspsource.cpp:63:41: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushIntfunc(259,2); CalcAddI(); PushStr(".jpg"); CalcAddI(); ^ jni/hsp3embed/hspsource.cpp:67:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("button.png"); ^ jni/hsp3embed/hspsource.cpp:152:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr(""); ^ jni/hsp3embed/hspsource.cpp:187:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ 8 warnings generated. [arm64-v8a] Compile++ : pokemon <= main.cpp jni/main.cpp:175:39: warning: format specifies type 'unsigned int' but the argument has type 'ANativeWindow ' [-Wformat] LOGI("**CMD_INIT_WINDOW(%x)",engine->app->window); ^^ ^^^^^^^^^^^^^^^^^^^ ../hsplib36b3/appengine.h:16:83: note: expanded from macro 'LOGI' define LOGI(…) ((void)_android_log_print(ANDROID_LOG_INFO, "native-activity", _VA_ARGS_)) ^^^^^^^^^^^ 1 warning generated. [arm64-v8a] SharedLibrary : libpokemon.so [arm64-v8a] Install : libpokemon.so => libs/arm64-v8a/libpokemon.so [x86] Compile++ : pokemon <= hspsource.cpp jni/hsp3embed/hspsource.cpp:38:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ jni/hsp3embed/hspsource.cpp:51:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("C:\android\pokemon\assets"); ^ jni/hsp3embed/hspsource.cpp:60:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("bgd"); PushFuncEnd(); PushFuncEnd(); PushInt(20); ^ jni/hsp3embed/hspsource.cpp:62:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("%02d"); ^ jni/hsp3embed/hspsource.cpp:63:41: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushIntfunc(259,2); CalcAddI(); PushStr(".jpg"); CalcAddI(); ^ jni/hsp3embed/hspsource.cpp:67:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("button.png"); ^ jni/hsp3embed/hspsource.cpp:152:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr(""); ^ jni/hsp3embed/hspsource.cpp:187:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ 8 warnings generated. [x86] Compile++ : pokemon <= main.cpp jni/main.cpp:175:39: warning: format specifies type 'unsigned int' but the argument has type 'ANativeWindow ' [-Wformat] LOGI("**CMD_INIT_WINDOW(%x)",engine->app->window); ^^ ^^^^^^^^^^^^^^^^^^^ ../hsplib36b3/appengine.h:16:83: note: expanded from macro 'LOGI' define LOGI(…) ((void)_android_log_print(ANDROID_LOG_INFO, "native-activity", _VA_ARGS_)) ^^^^^^^^^^^ 1 warning generated. [x86] SharedLibrary : libpokemon.so [x86] Install : libpokemon.so => libs/x86/libpokemon.so [x86_64] Compile++ : pokemon <= hspsource.cpp jni/hsp3embed/hspsource.cpp:38:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ jni/hsp3embed/hspsource.cpp:51:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("C:\android\pokemon\assets"); ^ jni/hsp3embed/hspsource.cpp:60:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("bgd"); PushFuncEnd(); PushFuncEnd(); PushInt(20); ^ jni/hsp3embed/hspsource.cpp:62:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("%02d"); ^ jni/hsp3embed/hspsource.cpp:63:41: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushIntfunc(259,2); CalcAddI(); PushStr(".jpg"); CalcAddI(); ^ jni/hsp3embed/hspsource.cpp:67:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("button.png"); ^ jni/hsp3embed/hspsource.cpp:152:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr(""); ^ jni/hsp3embed/hspsource.cpp:187:10: warning: ISO C++11 does not allow conversion from string literal to 'char *' [-Wwritable-strings] PushStr("AdMob"); ^ 8 warnings generated. [x86_64] Compile++ : pokemon <= main.cpp jni/main.cpp:175:39: warning: format specifies type 'unsigned int' but the argument has type 'ANativeWindow ' [-Wformat] LOGI("**CMD_INIT_WINDOW(%x)",engine->app->window); ^^ ^^^^^^^^^^^^^^^^^^^ ../hsplib36b3/appengine.h:16:83: note: expanded from macro 'LOGI' define LOGI(…) ((void)_android_log_print(ANDROID_LOG_INFO, "native-activity", _VA_ARGS_)) ^^^^^^^^^^^ 1 warning generated. [x86_64] SharedLibrary : libpokemon.so [x86_64] Install : libpokemon.so => libs/x86_64/libpokemon.so Buildfile: C:\android\pokemon\build.xml -set-mode-check: -set-debug-files: -check-env: [checkenv] Android SDK Tools Revision 25.2.5 [checkenv] Installed at C:\android\android-sdk\sdk -setup: [echo] Project Name: pokemon [gettype] Project Type: Application -set-debug-mode: -debug-obfuscation-check: -pre-build: -build-setup: [getbuildtools] Using latest Build Tools: 29.0.3 [echo] Resolving Build Target for pokemon… [gettarget] Project Target: Android 10 [gettarget] API level: 29 [echo] ---------- [echo] Creating output directories if needed… [mkdir] Created dir: C:\android\pokemon\bin [mkdir] Created dir: C:\android\pokemon\bin\res [mkdir] Created dir: C:\android\pokemon\bin\rsObj [mkdir] Created dir: C:\android\pokemon\bin\rsLibs [mkdir] Created dir: C:\android\pokemon\gen [mkdir] Created dir: C:\android\pokemon\bin\classes [mkdir] Created dir: C:\android\pokemon\bin\dexedLibs [echo] ---------- [echo] Resolving Dependencies for pokemon… [dependency] Library dependencies: [dependency] No Libraries [dependency] [dependency] ------------------ [echo] ---------- [echo] Building Libraries with 'debug'… [subant] No sub-builds to iterate on -code-gen: [mergemanifest] Merging AndroidManifest files into one. [mergemanifest] Manifest merger disabled. Using project manifest only. [echo] Handling aidl files… [aidl] No AIDL files to compile. [echo] ---------- [echo] Handling RenderScript files… [echo] ---------- [echo] Handling Resources… [aapt] Generating resource IDs… [echo] ---------- [echo] Handling BuildConfig class… [buildconfig] Generating BuildConfig class. -pre-compile: -compile: [javac] Compiling 4 source files to C:\android\pokemon\bin\classes [javac] 警告: [options] ソース値1.5は廃止されていて、今後のリリースで削除される予定です [javac] 警告: [options] ターゲット値1.5は廃止されていて、今後のリリースで削除される予定です [javac] 警告: [options] 廃止されたオプションについての警告を表示しないようにするには、-Xlint:オプションを使用します。 [javac] 注意:C:\android\pokemon\src\tv\hsp\HspActivity.javaは非推奨のAPIを使用またはオーバーライドしています。 [javac] 注意:詳細は、-Xlint:deprecationオプションを指定して再コンパイルしてください。 [javac] 警告3個 -post-compile: -obfuscate: -dex: [dex] input: C:\android\pokemon\bin\classes [dex] input: C:\android\pokemon\libs\android-support-compat.jar [dex] input: C:\android\pokemon\libs\google-play-services-clearcut.jar [dex] input: C:\android\pokemon\libs\google-play-services-base.jar [dex] input: C:\android\pokemon\libs\org.apache.http.legacy.jar [dex] input: C:\android\pokemon\libs\google-play-services-gass.jar [dex] input: C:\android\pokemon\libs\android-support-v4.jar [dex] input: C:\android\pokemon\libs\android-support-core-utils.jar [dex] input: C:\android\pokemon\libs\google-play-services-ads.jar [dex] input: C:\android\pokemon\libs\android-support-annotations.jar [dex] input: C:\android\pokemon\libs\google-firebase-common.jar [dex] input: C:\android\pokemon\libs\google-firebase-iid.jar [dex] input: C:\android\pokemon\libs\google-play-services-basement.jar [dex] input: C:\android\pokemon\libs\android-support-core-ui.jar [dex] input: C:\android\pokemon\libs\android-support-media-compat.jar [dex] input: C:\android\pokemon\libs\google-play-services-ads-lite.jar [dex] input: C:\android\pokemon\libs\google-play-services-tasks.jar [dex] input: C:\android\pokemon\libs\android-support-fragment.jar [dex] Pre-Dexing C:\android\pokemon\libs\android-support-compat.jar -> android-support-compat-8abe0fa43b6b29804d8a525f2bc7d37a.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-play-services-clearcut.jar -> google-play-services-clearcut-e59ce6533c35999afd04ab61b79a34a3.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-play-services-base.jar -> google-play-services-base-f575e797a3733edfe82ae4a7717c0afd.jar [dex] Pre-Dexing C:\android\pokemon\libs\org.apache.http.legacy.jar -> org.apache.http.legacy-3ea502af9bdf3fa51530a8da36b6dda3.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-play-services-gass.jar -> google-play-services-gass-eafd2de9e97199b4a137ffc01d5a0c35.jar [dex] Pre-Dexing C:\android\pokemon\libs\android-support-v4.jar -> android-support-v4-71ddb929cd1d86e9dadbdd77938ad7fa.jar [dex] Pre-Dexing C:\android\pokemon\libs\android-support-core-utils.jar -> android-support-core-utils-ee7257077a7b671aa3bda7ea4fb38db6.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-play-services-ads.jar -> google-play-services-ads-6dfc33b3fc5545e0869478080eaf4513.jar [dex] Pre-Dexing C:\android\pokemon\libs\android-support-annotations.jar -> android-support-annotations-c0cc9b2b60354477c81a9484f1097d6d.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-firebase-common.jar -> google-firebase-common-b7f3b4ec38631ab1f2c9251d19951c3d.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-firebase-iid.jar -> google-firebase-iid-970148b3e88ff49a9f4e21cb8db26c6f.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-play-services-basement.jar -> google-play-services-basement-37885d8991d936c6c773fe09c6127978.jar [dex] Pre-Dexing C:\android\pokemon\libs\android-support-core-ui.jar -> android-support-core-ui-272dcf5320a51e6cb86fdee41e8e2e4c.jar [dex] Pre-Dexing C:\android\pokemon\libs\android-support-media-compat.jar -> android-support-media-compat-0467f0a648884f14415587d40d1e74dc.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-play-services-ads-lite.jar -> google-play-services-ads-lite-3c662e363bf56c06be58a218729340d3.jar [dex] Pre-Dexing C:\android\pokemon\libs\google-play-services-tasks.jar -> google-play-services-tasks-714afbeb6a376688c45c5b54621a39ef.jar [dex] Pre-Dexing C:\android\pokemon\libs\android-support-fragment.jar -> android-support-fragment-32877338b1b57bca99c4496e44c04197.jar [dex] Converting compiled files and external libraries into C:\android\pokemon\bin\classes.dex… [dx] Merged dex #1 (22 defs/19.0KiB) [dx] Merged dex #2 (47 defs/8.6KiB) [dx] Merged dex #3 (687 defs/596.9KiB) [dx] Merged dex #4 (138 defs/248.2KiB) [dx] Merged dex #5 (70 defs/99.0KiB) [dx] Merged dex #6 (66 defs/158.0KiB) [dx] Merged dex #7 (214 defs/212.9KiB) [dx] Merged dex #8 (1 defs/0.7KiB) [dx] Merged dex #9 (17 defs/20.1KiB) [dx] Merged dex #10 (17 defs/36.0KiB) [dx] Merged dex #11 (785 defs/1007.5KiB) [dx] Merged dex #12 (382 defs/281.4KiB) [dx] Merged dex #13 (314 defs/281.1KiB) [dx] Merged dex #14 (318 defs/318.6KiB) [dx] Merged dex #15 (32 defs/41.2KiB) [dx] Merged dex #16 (10 defs/9.4KiB) [dx] Merged dex #17 (29 defs/20.9KiB) [dx] Merged dex #18 (420 defs/241.9KiB) [dx] Result is 3569 defs/4298.4KiB. Took 1.8s -crunch: [crunch] Crunching PNG Files in source dir: C:\android\pokemon\res [crunch] To destination dir: C:\android\pokemon\bin\res [crunch] Processing image to cache: C:\android\pokemon\res\drawable-hdpi\ic_launcher.png => C:\android\pokemon\bin\res\drawable-hdpi\ic_launcher.png [crunch] (processed image to cache entry C:\android\pokemon\bin\res\drawable-hdpi\ic_launcher.png: 76% size of source) [crunch] Processing image to cache: C:\android\pokemon\res\drawable-ldpi\ic_launcher.png => C:\android\pokemon\bin\res\drawable-ldpi\ic_launcher.png [crunch] (processed image to cache entry C:\android\pokemon\bin\res\drawable-ldpi\ic_launcher.png: 0% size of source) [crunch] Processing image to cache: C:\android\pokemon\res\drawable-mdpi\ic_launcher.png => C:\android\pokemon\bin\res\drawable-mdpi\ic_launcher.png [crunch] (processed image to cache entry C:\android\pokemon\bin\res\drawable-mdpi\ic_launcher.png: 80% size of source) [crunch] Processing image to cache: C:\android\pokemon\res\drawable-xhdpi\ic_launcher.png => C:\android\pokemon\bin\res\drawable-xhdpi\ic_launcher.png [crunch] (processed image to cache entry C:\android\pokemon\bin\res\drawable-xhdpi\ic_launcher.png: 69% size of source) [crunch] Crunched 4 PNG files to update cache -package-resources: [aapt] Creating full resource package… -package: [apkbuilder] Current build type is different than previous build: forced apkbuilder run. [apkbuilder] Creating pokemon-debug-unaligned.apk and signing it with a debug key… -post-package: -do-debug: [zipalign] Running zip align on final apk… [echo] Debug Package: C:\android\pokemon\bin\pokemon-debug.apk [propertyfile] Creating new property file: C:\android\pokemon\bin\build.prop [propertyfile] Updating property file: C:\android\pokemon\bin\build.prop [propertyfile] Updating property file: C:\android\pokemon\bin\build.prop [propertyfile] Updating property file: C:\android\pokemon\bin\build.prop -post-build: debug: BUILD SUCCESSFUL Total time: 1 minute 47 seconds
途中、ものすごく怪しいエラーっぽいものがありますが、とりあえず「BUILD SUCCESSFUL」となっているので、OKとします(していいのかは置いといて)
「C:\android\pokemon\bin\pokemon-debug.apk」があればOKです。
これをインストールしてみましょう。