Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

怎么解决谷歌.aab方式导致streamingAssetsPath不正确的问题呢? #20

Open
linkongchen opened this issue Oct 28, 2021 · 3 comments

Comments

@linkongchen
Copy link

//!!!! wrong streamingAssetsPath in Google aab

@noodle1983
Copy link
Owner

遍历所有打开的apk, 找到包含需要的文件夹那个,然后自己拼个路径

@linkongchen
Copy link
Author

测试多台手机,发现有一些手机有效,有一些手机无效。vivo oppo可以,华为,小米,gspace都不可以。

打开日志看了下:

成功的日志

2021-10-30 16:44:49.760 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:get_arch_abi
2021-10-30 16:44:53.231 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:use_data_dir
2021-10-30 16:44:53.231 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:use_data_dir__1
2021-10-30 16:44:53.231 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:get_bundle_id
2021-10-30 16:44:53.231 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:get_bundle_id_end
2021-10-30 16:44:53.231 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:prepare_so_lib
2021-10-30 16:44:53.231 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:copy_file
2021-10-30 16:44:53.474 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:copy_file_end
2021-10-30 16:44:53.654 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:prepare_so_lib_end
2021-10-30 16:44:53.654 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:use_data_dir__2
2021-10-30 16:44:53.654 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:get_apk_path
2021-10-30 16:44:54.064 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:get_apk_path___end
2021-10-30 16:44:54.155 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:use_data_dir__3
2021-10-30 16:44:54.155 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:use_data_dir__4
2021-10-30 16:44:54.156 2826-3101/? E/il2cpp: [76b67024f0]m_logcat_________________:use_data_dir__end

失败的日志

2021-10-30 16:56:54.508 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:get_arch_abi
2021-10-30 16:56:58.754 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:use_data_dir
2021-10-30 16:56:58.754 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:use_data_dir__1
2021-10-30 16:56:58.754 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:get_bundle_id
2021-10-30 16:56:58.754 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:get_bundle_id_end
2021-10-30 16:56:58.754 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:prepare_so_lib
2021-10-30 16:56:58.754 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:copy_file
2021-10-30 16:56:58.938 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:copy_file_end
2021-10-30 16:56:58.939 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:prepare_so_lib_end
2021-10-30 16:56:58.939 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:use_data_dir__2
2021-10-30 16:56:58.939 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:get_apk_path
2021-10-30 16:56:59.128 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:get_apk_path___end
2021-10-30 16:56:59.235 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:use_data_dir__3
2021-10-30 16:56:59.235 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:use_data_dir__4
2021-10-30 16:56:59.236 16682-16789/? E/il2cpp: [7a6ccff4f0]m_logcat_________________:use_data_dir__end
2021-10-30 16:57:05.055 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:Java_io_github_noodle1983_Boostrap_init
2021-10-30 16:57:05.055 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:bootstrap
2021-10-30 16:57:05.055 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:bootstrap
2021-10-30 16:57:05.055 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:extract_patch_info
2021-10-30 16:57:05.056 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:extract_patch_info__1
2021-10-30 16:57:05.057 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:extract_patch_info__2
2021-10-30 16:57:05.057 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:extract_patch_info__3
2021-10-30 16:57:05.057 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:pre_process_all_so_lib
2021-10-30 16:57:05.081 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:pre_process_all_so_lib_end
2021-10-30 16:57:05.081 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:extract_patch_info__4
2021-10-30 16:57:05.081 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:extract_patch_info__5
2021-10-30 16:57:05.081 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:init_hook
2021-10-30 16:57:05.081 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:bootstrap_end
2021-10-30 16:57:05.081 17614-17614/? E/il2cpp: [7b0f6e8548]m_logcat_________________:Java_io_github_noodle1983_Boostrap_init_end

失败的日志会多执行Java_io_github_noodle1983_Boostrap_init

@noodle1983
Copy link
Owner

库的代码是这个函数,我没测试环境,你试试打多点日志看看
https://github.com/noodle1983/UnityAndroidIl2cppPatchDemo-libboostrap/blob/master/bootstrap.cpp#L437

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants