Skip to content
This repository was archived by the owner on Jul 31, 2024. It is now read-only.

Automatic build with GitHub Actions#5

Merged
neobenedict merged 17 commits into
rayshift:masterfrom
segfault-bilibili:20230624-fix-build-issues
Aug 10, 2023
Merged

Automatic build with GitHub Actions#5
neobenedict merged 17 commits into
rayshift:masterfrom
segfault-bilibili:20230624-fix-build-issues

Conversation

@segfault-bilibili

@segfault-bilibili segfault-bilibili commented Jun 24, 2023

Copy link
Copy Markdown
Contributor

Note (after merge) : this reverts #4 in 7305f36


Initial Setup

  1. base64 -w0 < release_signing_key.keystore
  2. Add the base64-encoded keystore file as a Repository secret named KEYSTORE_BASE64 to repo action settings
  3. Add the keystore password (without the pass: prefix) as KS_PASS (and add KEY_PASS and KS_KEY_ALIAS as well if needed)
  4. Enable actions

Usage

It automatically build on new official game release, and then do a prerelease.

To do a manual production-ready release:

  1. Change ci_versions/src_apk.sh and push the change to master or dev branch to trigger a rebuild from new version of source APK
  2. Add a tag like git tag -s -m "release description" v123 and push it to trigger a release (add a -prerelease suffix to do a prerelease)

@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch 7 times, most recently from bdb8ffc to 0168cdc Compare June 24, 2023 15:32
@segfault-bilibili segfault-bilibili marked this pull request as ready for review June 24, 2023 15:45
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch 3 times, most recently from c3e4aef to 5930d33 Compare June 25, 2023 00:04
@segfault-bilibili segfault-bilibili marked this pull request as draft June 25, 2023 02:30
@segfault-bilibili

segfault-bilibili commented Jun 25, 2023

Copy link
Copy Markdown
Contributor Author

f9d5aee doesn't extract armv7 libs correctly. fixing that.

mv "${BASEDIR}/build/armv7/app/lib/armeabi-v7a/*" "${BASEDIR}/build/app/lib/armeabi-v7a/"

the wildcard * should not be quoted.
fixed

@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch from 5930d33 to bacad24 Compare June 25, 2023 02:52
@segfault-bilibili segfault-bilibili marked this pull request as ready for review June 25, 2023 02:52
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch from bacad24 to afdd394 Compare June 25, 2023 03:09
@segfault-bilibili segfault-bilibili marked this pull request as draft June 25, 2023 03:22
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch 3 times, most recently from e270170 to cefc524 Compare June 25, 2023 05:19
@segfault-bilibili segfault-bilibili marked this pull request as ready for review June 25, 2023 05:34
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch from cefc524 to 7d913b8 Compare June 25, 2023 05:54
@segfault-bilibili

Copy link
Copy Markdown
Contributor Author

I plan to remove nodejs dependency and fix Dobby for armeabi-v7a instead @neobenedict

1.update dobby to latest:
original commit hash: b0176de574104726bb68dff3b77ee666300fc338
plus compilation error fix

2.update untp to include plistlib fix
1. define RS_SUCCESS in MagiaClient.cpp,
which was deleted in Dobby f4643b8d14d7cc94516b446ca77d952d0b986d50

2. fix dobby not being statically linked
let build.sh exit on error
let build.bat fail if signing fails
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch 2 times, most recently from 512e27c to ff367de Compare July 6, 2023 11:18
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch 3 times, most recently from df35a19 to c9241b6 Compare July 7, 2023 16:46
@segfault-bilibili segfault-bilibili marked this pull request as draft July 7, 2023 16:51
@segfault-bilibili segfault-bilibili marked this pull request as ready for review July 7, 2023 17:12
@segfault-bilibili

Copy link
Copy Markdown
Contributor Author

logcat | grep MagiaHook

07-08 01:23:58.075  5178  5178 I MagiaHook: Starting MagiaHook.
07-08 01:23:58.077  5178  5210 I MagiaHook: Library location: /data/app/io.kamihama.magiatranslate.experiment-1/lib/arm64/libmadomagi_native.so
07-08 01:23:58.077  5178  5210 I MagiaHook: Base address: 0x4000000
07-08 01:23:58.099  5178  5210 I MagiaHook: Successfully hooked UrlConfig::resource.
07-08 01:23:58.104  5178  5210 I MagiaHook: Successfully hooked SceneLayerManager::createSceneLayer.
07-08 01:23:58.108  5178  5210 I MagiaHook: Successfully hooked http2::Http2Session::setMaxConnectionNum.
07-08 01:23:58.117  5178  5210 I MagiaHook: Successfully hooked criNcv_GetHardwareSamplingRate_ANDROID.
07-08 01:23:58.122  5178  5210 I MagiaHook: Successfully hooked criNcv_SetHardwareSamplingRate_ANDROID.
07-08 01:23:58.128  5178  5210 I MagiaHook: Successfully hooked cocos2d::Node::setPosition.
07-08 01:23:58.140  5178  5210 I MagiaHook: Successfully hooked cocos2d::Label::setMaxLineWidth.
07-08 01:23:58.142  5178  5210 I MagiaHook: Successfully hooked cocos2d::Label::setDimensions.
07-08 01:23:58.152  5178  5210 I MagiaHook: Successfully hooked LbUtility::getViewPosition.
07-08 01:23:58.158  5178  5210 I MagiaHook: Successfully hooked cocos2d::Label::createWithTTF.
07-08 01:23:58.172  5178  5210 I MagiaHook: Exiting hook thread.
07-08 01:23:58.695  5178  5203 I MagiaHook: set cached hardware sample rate to 44100
07-08 01:23:58.704  5178  5203 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:23:58.704  5178  5203 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:23:58.706  5178  5203 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:23:58.706  5178  5203 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:23:58.706  5178  5203 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:23:58.706  5178  5203 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:23:59.393  5178  5203 I MagiaHook: Scene layer changed to: StartupSceneLayer
07-08 01:23:59.393  5178  5203 I MagiaHook: Scene layer changed to: TapSceneLayer
07-08 01:24:03.960  5178  5203 I MagiaHook: Scene layer changed to: WebSceneLayer
07-08 01:24:05.080  5178  5203 I MagiaHook: Scene layer changed to: TapSceneLayer
07-08 01:24:05.132  5178  5203 I MagiaHook: Scene layer changed to: LoadingSceneLayer
07-08 01:24:06.474  5178  5203 I MagiaHook: Scene layer changed to: TapSceneLayer
07-08 01:24:07.232  5178  5203 I MagiaHook: Scene layer changed to: TopSceneLayer

07-08 01:04:14.025  6637  6637 I MagiaHook: Starting MagiaHook.
07-08 01:04:14.026  6637  6676 I MagiaHook: Library location: /data/app/io.kamihama.magiatranslate.experiment-ZkSKdJRAUeSLBmdFrFdO9A==/lib/arm/libmadomagi_native.so
07-08 01:04:14.027  6637  6676 I MagiaHook: Base address: 0x31d0000
07-08 01:04:14.058  6637  6676 I MagiaHook: Successfully hooked UrlConfig::resource.
07-08 01:04:14.067  6637  6676 I MagiaHook: Successfully hooked SceneLayerManager::createSceneLayer.
07-08 01:04:14.079  6637  6676 I MagiaHook: Successfully hooked http2::Http2Session::setMaxConnectionNum.
07-08 01:04:14.089  6637  6676 I MagiaHook: Successfully hooked criNcv_GetHardwareSamplingRate_ANDROID.
07-08 01:04:14.101  6637  6676 I MagiaHook: Successfully hooked criNcv_SetHardwareSamplingRate_ANDROID.
07-08 01:04:14.107  6637  6676 I MagiaHook: Successfully hooked cocos2d::Node::setPosition.
07-08 01:04:14.109  6637  6676 I MagiaHook: Successfully hooked cocos2d::Label::setMaxLineWidth.
07-08 01:04:14.110  6637  6676 I MagiaHook: Successfully hooked cocos2d::Label::setDimensions.
07-08 01:04:14.111  6637  6676 I MagiaHook: Successfully hooked LbUtility::getViewPosition.
07-08 01:04:14.112  6637  6676 I MagiaHook: Successfully hooked cocos2d::Label::createWithTTF.
07-08 01:04:14.115  6637  6676 I MagiaHook: Exiting hook thread.
07-08 01:04:14.767  6637  6667 I MagiaHook: set cached hardware sample rate to 44100
07-08 01:04:14.774  6637  6667 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:04:14.780  6637  6667 I MagiaHook: using hardware sample rate: 48000 (orig: 44100)
07-08 01:04:15.397  6637  6667 I MagiaHook: Scene layer changed to: StartupSceneLayer
07-08 01:04:15.398  6637  6667 I MagiaHook: Scene layer changed to: TapSceneLayer
07-08 01:04:19.427  6637  6667 I MagiaHook: Scene layer changed to: WebSceneLayer
07-08 01:04:20.437  6637  6667 I MagiaHook: Scene layer changed to: TapSceneLayer
07-08 01:04:20.467  6637  6667 I MagiaHook: Scene layer changed to: LoadingSceneLayer
07-08 01:04:21.855  6637  6667 I MagiaHook: Scene layer changed to: TapSceneLayer
07-08 01:04:22.727  6637  6667 I MagiaHook: Scene layer changed to: TopSceneLayer

@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch 2 times, most recently from ff7da0a to e35ac3e Compare July 9, 2023 09:18
@segfault-bilibili

Copy link
Copy Markdown
Contributor Author

Actually this commit does not achieve true "automatic" build yet. I think this could be done with another action yml which runs regularly with schedule trigger, checking the ready.txt on rikaren.

@segfault-bilibili

segfault-bilibili commented Jul 11, 2023

Copy link
Copy Markdown
Contributor Author

@neobenedict you may merge this first, and then I will submit another PR to periodically check new version & truly automate building afterwards.

@segfault-bilibili

Copy link
Copy Markdown
Contributor Author

It's probably better to avoid relying on rikaren as well. However this obviously requires some more work. A google account also seems to be required.

fix Dobby so that we can implement audiofix in MagiaHook again
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch 2 times, most recently from 7305f36 to 9b8fa60 Compare July 18, 2023 11:05
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch from 9b8fa60 to 7305f36 Compare August 10, 2023 01:32
@segfault-bilibili

Copy link
Copy Markdown
Contributor Author

okay now it really automatically builds

@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch from ae85e54 to 11cc9a8 Compare August 10, 2023 17:33
@segfault-bilibili segfault-bilibili force-pushed the 20230624-fix-build-issues branch from 11cc9a8 to 364d286 Compare August 10, 2023 18:00
@neobenedict neobenedict merged commit 2e4f815 into rayshift:master Aug 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants