I have no idea how to build an apk. Is it is using gradlew.bat? #1258
Replies: 31 comments 28 replies
|
do you read: https://github.com/axmolengine/axmol/blob/dev/docs/DevSetup.md Just goto root of axmol, then run follow powershell script, will build HelloCpp apk for you, it will auto setup android sdk, ndk, jdk, ninja for you
|
|
hi, |
|
does the cmdlines package download succeed?
获取Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: rudiHammad ***@***.***>
Sent: Sunday, July 9, 2023 5:22:03 PM
To: axmolengine/axmol ***@***.***>
Cc: Deal(一线灵) ***@***.***>; Comment ***@***.***>
Subject: Re: [axmolengine/axmol] I have no idea how to build an apk. Is it is using gradlew.bat? (Discussion #1258)
hi,
yes I read it but I was on a previous axmol version that didn't have the build.ps1 file.
I have updated and I am following the guide now. The problem that I am getting is that when I run that command I get the error: Install cmdlinetools version: 7.0 fail
I am googling to see what that is
―
Reply to this email directly, view it on GitHub<#1258 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABVHOJ3EUNPRK4AESENG2KTXPJZ3XANCNFSM6AAAAAA2DC7IRM>.
You are receiving this because you commented.Message ID: ***@***.***>
|
|
plus, I just checked my environment vasriables and I have the variable NDK_ROOT as C:\Program Files\cocos2d_dependencies\android-ndk-r23b-windows\android-ndk-r23b |
|
the ndk folder doesn't exist in sdk_root, will fix it later
获取Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: rudiHammad ***@***.***>
Sent: Sunday, July 9, 2023 5:42:40 PM
To: axmolengine/axmol ***@***.***>
Cc: Deal(一线灵) ***@***.***>; Comment ***@***.***>
Subject: Re: [axmolengine/axmol] I have no idea how to build an apk. Is it is using gradlew.bat? (Discussion #1258)
plus, I just checked my environment vasriables and I have the variable NDK_ROOT as C:\Program Files\cocos2d_dependencies\android-ndk-r23b-windows\android-ndk-r23b
So I guess that having cocos2dx installed is messing some of my variables
―
Reply to this email directly, view it on GitHub<#1258 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABVHOJ3XHLZLL33VVX6GMBTXPJ4JBANCNFSM6AAAAAA2DC7IRM>.
You are receiving this because you commented.Message ID: ***@***.***>
|
|
you can create a empty folder ndk in your sdk_root
获取Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: rudiHammad ***@***.***>
Sent: Sunday, July 9, 2023 6:39:01 PM
To: axmolengine/axmol ***@***.***>
Cc: Deal(一线灵) ***@***.***>; Comment ***@***.***>
Subject: Re: [axmolengine/axmol] I have no idea how to build an apk. Is it is using gradlew.bat? (Discussion #1258)
okey. So it has nothing to do with the error?
because I believe it is setup correctly
[aaa]<https://user-images.githubusercontent.com/25636976/252140067-bec2cf99-f28a-4aad-8e02-a3662535a9a1.JPG>
―
Reply to this email directly, view it on GitHub<#1258 (reply in thread)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABVHOJYYEKDHDMVFAFFHACTXPKC4LANCNFSM6AAAAAA2DC7IRM>.
You are receiving this because you commented.Message ID: ***@***.***>
|
|
hmmm...I tried that. No luck. |
|
I tried to build on windows in case it was easier with pwsh .\build.ps1 -p winuwp but more errors;
I think I am about to give up and swtich to unity. I can't investe time in an engine if I can't deploy to windows, or android. It is probably me, but I think I have all in order and I still keep getting errors. Anyway, it is quite discouraging because Axmol is pretty awesome but I think I need to be sure that I won't have problems deploying my games in the future. |
|
for uwp, do you install uwp workflow for visual studio 2022?
获取Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: rudiHammad ***@***.***>
Sent: Sunday, July 9, 2023 8:21:15 PM
To: axmolengine/axmol ***@***.***>
Cc: Deal(一线灵) ***@***.***>; Comment ***@***.***>
Subject: Re: [axmolengine/axmol] I have no idea how to build an apk. Is it is using gradlew.bat? (Discussion #1258)
I tried to build on windows in case it was easier with pwsh .\build.ps1 -p winuwp but more errors;
MSBuild version 17.5.0+6f08c67f3 for .NET Framework
MSBUILD : error MSB1009: Project file does not exist.
Switch: HelloCpp.vcxproj```
I think I am about to give up and swtich to unity. I can't investe time in an engine if I can't deploy to windows, or android. It is probably me, but I think I have all in order and I still keep getting errors. Anyway, it is quite discouraging because Axmol is pretty awesome but I think I need to be sure that I won't have problems deploying my games in the future.
―
Reply to this email directly, view it on GitHub<#1258 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABVHOJ2V4JLVMDE3MPQK7JTXPKO3XANCNFSM6AAAAAA2DC7IRM>.
You are receiving this because you commented.Message ID: ***@***.***>
|
|
D:__GIT\axmol>pwsh ./build.ps1 -p android -a arm64 d D:__GIT\axmol\templates\cpp-template-default\proj.android build1k: proj_dir=D:__GIT\axmol, prefix=D:__GIT\axmol\tools\external |
|
After some manual "downloads" it works here also. (pwsh .\build.ps1 -p android -a arm64) |
why not start with a new folder (without spaces in the path) ? |
|
Have you run |
|
@halx99 |
|
|
|
And got this errror :
|
|
What about nsis for windows, engine itself not provide package to one image support, and vcredist required on machine which visual studio(version should match with your build machine) not installed.
获取Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: rudiHammad ***@***.***>
Sent: Monday, July 10, 2023 9:08:22 PM
To: axmolengine/axmol ***@***.***>
Cc: Deal(一线灵) ***@***.***>; Mention ***@***.***>
Subject: Re: [axmolengine/axmol] I have no idea how to build an apk. Is it is using gradlew.bat? (Discussion #1258)
hey guys,
so I was able to send the .exe file demo to some friends to test. All I did is copy relase folder that created visual studio, send it as it is.
[Capture]<https://user-images.githubusercontent.com/25636976/252347523-240eb000-f1f0-4ad4-a1f6-7421f559c50c.JPG>
And all they had to do is execute the .exe and it worked.
I have never published any game, I am very new to this, so can you explain how do you deploy a game in itch or steam.
I am not talking about having to register, download steam sdk for achievements and stuff... I am not there yet.
I am asking about the very basic. Would it be as easy as uploading the files from the folder in the image above?
―
Reply to this email directly, view it on GitHub<#1258 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABVHOJYPCN3CHLV65CP2XNLXPP5ENANCNFSM6AAAAAA2DC7IRM>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
|
Finally! it is all working! Those where my mistakes.
One thing that I don't understand though is that if I run this: |
-- Selecting Windows SDK version 10.0.22621.0 to target Windows 10.0.19045.
CMake Error: Could not find cmake module file: CMakeDetermineGameCompiler.cmake
CMake Error: Could not find cmake module file: D:/dev/projects/Example Game/build/CMakeFiles/3.27.0-rc3/CMakeGameCompiler.cmake
CMake Error at CMakeLists.txt:30 (project):
No CMAKE_Game_COMPILER could be found.
CMake Error: Could not find cmake module file: CMakeGameInformation.cmake
-- Configuring incomplete, errors occurred! |
Okey, I did some google reasearch and ask chat gpt on how to do that. What I got is that after download VC_redist.x64.exe, which is my arch, I have to create the following script, which I named vcredistInstaller.nsi and it goes like this |
|
and vs console have command |
|
Sorry man, I give up. I am just getting drops of information with every reply and I have to spend hours googling what it means. First it was learning what nsis was, then learning what "vcredist install in your nsis install setup script" means, which is learning what a .nsi file, how to create one and running from the nsis. Now I have to figure how what "vs console have command dumpbin /dependents xxx.exe to help check exe or dll dependencies" means. I am having a lot of trouble following up with just drops of information. It is probably me. Thanks for all you help anyways. R |
|
it's ok, sorry the win32 package not part of axmol, axmol still a framework, not with full rich game develop tool. but I can confirm axmol should more easy to deploy win32 target than original cocos2dx, brcause all prebuilts dll is matched vcredist version aka msvc14.36. |
|
A easy way is copy all vcredist dlls to target bin directory, this can be done powershell build script in the future.
获取Outlook for Android<https://aka.ms/AAb9ysg>
…________________________________
From: rudiHammad ***@***.***>
Sent: Tuesday, July 11, 2023 11:12:08 PM
To: axmolengine/axmol ***@***.***>
Cc: Deal(一线灵) ***@***.***>; Mention ***@***.***>
Subject: Re: [axmolengine/axmol] I have no idea how to build an apk. Is it is using gradlew.bat? (Discussion #1258)
Sorry man, I give up. I am just getting drops of information with every reply and I have to spend hours googling what it means. First it was learning what nsis was, then learning what "vcredist install in your nsis install setup script" means, which is learning what a .nsi file, how to create one and running from the nsis. Now I have to figure how what "vs console have command dumpbin /dependents xxx.exe to help check exe or dll dependencies" means.
I am having a lot of trouble following up with just drops of information. It is probably me. Thanks for all you help anyways.
R
―
Reply to this email directly, view it on GitHub<#1258 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ABVHOJZPRBVNWWLT2I5JCYDXPVUMRANCNFSM6AAAAAA2DC7IRM>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
|
I got the same problem as you, you see there are C++ runtime redistributebles that have to be installed on the system https://learn.microsoft.com/en-us/cpp/windows/latest-supported-vc-redist?view=msvc-170, the way you are publishing your game is indeed correct, but unfortunately these programs need to be installed on the user's machine so you need to provide vcredist, there is a game called geometry dash that suffers from this problem and also unreal engine games too, you just need to google vcredist c++ x64 and download all execs for all dates (2008, 2013, 2017, and so on) that way the missing dlls are present in the system, you could add a folder to your game called, |
|
ahhh, thanks a lot. I am gonna try that. I really don't what to go to Unity XD. I am sure it is cool, but I prefer to stay in C++ and axmol. I think that a guide for dummies (like my self apparently) would bring more people. |
|
ok, done. Here is the discord link |



Uh oh!
There was an error while loading. Please reload this page.
hi,
I spent a couple of ours googling, and searching in forums how to build an apk to test the game on my android. I am just using axmol defaults projects to keep it simple. I did manage to see the error outputs I was getting, first it was that I need java 11. I installed last java (version 20 i think) and that solved that error. So I assume it is java 11 or higher.
Then I got a Ninja not found in Path, so after some reasearch I fixed that error by downloading ninja.exe and put it in the PATH environment. So finally I run gradlew.bat in the folder proj.android and I said that It build successfully in 1 second..
soooooo....what just happened? Is gradlew.bat suppose to build the apk without the need of setting android studio? If it built the .apk where is it?! XD. I searched all the axmol project but didn't find any apk.
I am sure that is pretty basic but can someone point me if what I am doing has nothing to do with building an .apk?
thanks
All reactions