Juanchi Android Build x64 (Step-By-Step)

User avatar
runs
Member
 
Posts: 1130
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy

Juanchi Android Build x64 (Step-By-Step)

by runs » Wed Jan 02, 2019 22:34

In Linux

Notes:

- It is assumed that the minetest folder is in /opt/
- Change the /home/your_name/ for your own user

1. Download a clean Minetest with the patch for Android x64 included.
Warning: The official Minetest still do not support this method so use this above source code instead.

1.1 Do some fixes:

In src/porting_android.cpp, line 209:

Code: Select all
path_user    = path_storage + DIR_DELIM + "Android" + DIR_DELIM + "data" + DIR_DELIM + "net.minetest.minetest";
   path_share   = path_storage + DIR_DELIM + "Android" + DIR_DELIM + "data" + DIR_DELIM + "net.minetest.minetest";


In build/android/app/src/main/java/net/minetest/minetest/UnzipService.java, line 103:

Code: Select all
String baseDir = Environment.getExternalStorageDirectory().getAbsolutePath(); String location = baseDir + "/Android/data/net.minetest.minetest/";


2. Install the Android SDK.

3. Install the licenses:

a. Go to /home/your_name/Android/Sdk/tools/bin

b. Run in terminal:

Code: Select all
yes | ./sdkmanager --licenses


4. Run Android Studio:

Code: Select all
./android-studio/bin/studio.sh


5. Open the project in Android Studio:

/opt/minetest/build/android/

6. Await to the dependencies downloaded.

7. In /minetest/build/android/ run:

./gradlew assemblerelease

7. Sign the apk:

Code: Select all
/home/your_name/Android/Sdk/build-tools/29.0.2/zipalign -v 4 /opt/minetest/build/android/app/build/outputs/apk/release/app-arm64-v8a-release-unsigned.apk /opt/minetest/build/android/app/build/outputs/apk/release/minetest.apk


Code: Select all
 jarsigner -verbose -digestalg SHA1 -sigalg MD5withRSA -keystore /opt/minetest/build/android/app/build/outputs/apk/release/my.keystore /opt/minetest/build/android/app/build/outputs/apk/release/minetest.apk Minetest


Futhermore

To customize your app:

[*]To change the game to be included in your apk:

Edit /opt/minetest/build/android/app/build.gradle and change:
Code: Select all
def gameToCopy = "minetest_game"


[*]To change the internal name of your apk:

Edit /opt/minetest/build/android/app/src/main/AndroidManifest.xml and change (the following line is repeated in 2 lines):

Code: Select all
android:label="Minetest"


[*]To change the application ID of your apk:

Edit /opt/minetest/build/android/app/build.gradle and change:

Code: Select all
applicationId 'net.minetest.minetest'


[*]To change the version of your apk:

Edit /opt/minetest/build/android/build.gradle and change:

Code: Select all
project.ext.set("versionMajor", 1) // Version Major
project.ext.set("versionMinor", 0) // Version Minor
project.ext.set("versionPatch", 2) // Version Patch
project.ext.set("versionCode", 3) // Android Version Code


[*]Change the icon launcher:

Replace /opt/minetest/build/android/app/src/main/res/mipmap/ic_launcher.png
Last edited by runs on Fri Jan 10, 2020 21:26, edited 20 times in total.
 

User avatar
TumeniNodes
Member
 
Posts: 2836
Joined: Fri Feb 26, 2016 19:49
Location: in the dark recesses of the mind
GitHub: TumeniNodes
IRC: tumeninodes
In-game: TumeniNodes

Re: Bogart Android Build

by TumeniNodes » Thu Jan 03, 2019 01:09

Don't worry 'bout it... I hit the beech all the time xD

0_0
Ich mag keine grünen Eier und Schinken, ich mag sie nicht Sam I Am
 

User avatar
runs
Member
 
Posts: 1130
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy

Re: Bogart Android Build

by runs » Thu Jan 03, 2019 23:07

I have a bug. I change the language to 'es' but nothing changes.

Any tip to solve this?
 

User avatar
runs
Member
 
Posts: 1130
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy
 

User avatar
runs
Member
 
Posts: 1130
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy

Re: Bogart Android Build

by runs » Fri Jan 04, 2019 01:23

I tried also to use the mod 'intlib' and in Android the server crashes on init.
 

DeepMiner
New member
 
Posts: 4
Joined: Wed May 16, 2018 02:56

Re: Bogart Android Build

by DeepMiner » Tue Nov 05, 2019 11:41

Sorry if this is repeated but Apk no longer available on your original site try https://uploadshit.com
 

cHyper-0815OL
Member
 
Posts: 38
Joined: Fri Sep 13, 2019 17:40
Location: Austria
GitHub: cHyper-0815OL
In-game: cHyper cHyper-0815OL

Re: Bogart Android Build

by cHyper-0815OL » Thu Nov 07, 2019 12:46

DeepMiner wrote:Sorry if this is repeated but Apk no longer available on your original site try https://uploadshit.com


https://runs.itch.io/bogart-game
 

User avatar
runs
Member
 
Posts: 1130
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy
 

User avatar
runs
Member
 
Posts: 1130
Joined: Sat Oct 27, 2018 08:32
GitHub: runsy

Re: Juanchi Android Build x64 (Step-By-Step)

by runs » Fri Jan 10, 2020 21:16

Update of the tutorial:
- Step 1.1: Make some changes in code in order to the games loaded and better game resources location.
 


Return to Builds



Who is online

Users browsing this forum: No registered users and 1 guest