AbdurRahman Member Apr 4, 2021 #1 How to build b4a app using github VPS yaml script ? Thanks erel for making b4a cli version. What I tried ? I'm at stage of just finishing. I made IDE portable and compressed via 7zip. With batch script, I download, extract and compile apk using it. Code: Copy git clone https://github.com/graysuit/b4a_compiler.git xcopy b4a_compiler "" /h /i /c /k /e /r /y mkdir b4a 7z.exe x "b4a_compiler/b4a.7z" -ob4a -y "b4a/b4a/B4ABuilder.exe" -Task=Release -NoSign=False -Obfuscate=False -ShowWarnings=True -Optimize=True -NoClean=True -Output=anti_vm.apk What's problem ? Code: Copy D:\a\anti-vm\anti-vm\android>"b4a/b4a/B4ABuilder.exe" -Task=Release -NoSign=False -Obfuscate=False -ShowWarnings=True -Optimize=True -NoClean=True -Output=anti_vm.apk B4ABuilder v10.70 System.Exception: ini file not found. Please run B4A first. at ie.n() at ie.j(String[] A_0) at ie.m(String[] A_0) ini file not found. Please run B4A first. Error: Process completed with exit code 1. Looks like some ini file missing. It seems like ini file saved in appdata is necessary. But while opening that, its clearly states that it is specific user based. Now how do I specify it to use github environment auto-detect java.exe, sdk etc ? Please see actions: https://github.com/Back-X/anti-vm/runs/2265424912 compile.bat Back-X/anti-vm Detect virtual machine environment. Contribute to Back-X/anti-vm development by creating an account on GitHub. github.com PULL REQUEST will be also appreciated. There's also 1 more law issue. I'm not sure whether its legal to make b4a portable and distribute for compiling purpose ? Attachments github_ci_logs.zip github_ci_logs.zip 9.6 KB · Views: 574
How to build b4a app using github VPS yaml script ? Thanks erel for making b4a cli version. What I tried ? I'm at stage of just finishing. I made IDE portable and compressed via 7zip. With batch script, I download, extract and compile apk using it. Code: Copy git clone https://github.com/graysuit/b4a_compiler.git xcopy b4a_compiler "" /h /i /c /k /e /r /y mkdir b4a 7z.exe x "b4a_compiler/b4a.7z" -ob4a -y "b4a/b4a/B4ABuilder.exe" -Task=Release -NoSign=False -Obfuscate=False -ShowWarnings=True -Optimize=True -NoClean=True -Output=anti_vm.apk What's problem ? Code: Copy D:\a\anti-vm\anti-vm\android>"b4a/b4a/B4ABuilder.exe" -Task=Release -NoSign=False -Obfuscate=False -ShowWarnings=True -Optimize=True -NoClean=True -Output=anti_vm.apk B4ABuilder v10.70 System.Exception: ini file not found. Please run B4A first. at ie.n() at ie.j(String[] A_0) at ie.m(String[] A_0) ini file not found. Please run B4A first. Error: Process completed with exit code 1. Looks like some ini file missing. It seems like ini file saved in appdata is necessary. But while opening that, its clearly states that it is specific user based. Now how do I specify it to use github environment auto-detect java.exe, sdk etc ? Please see actions: https://github.com/Back-X/anti-vm/runs/2265424912 compile.bat Back-X/anti-vm Detect virtual machine environment. Contribute to Back-X/anti-vm development by creating an account on GitHub. github.com PULL REQUEST will be also appreciated. There's also 1 more law issue. I'm not sure whether its legal to make b4a portable and distribute for compiling purpose ?
Erel B4X founder Staff member Licensed User Longtime User Apr 5, 2021 #2 AbdurRahman said: There's also 1 more law issue. I'm not sure whether its legal to make b4a portable and distribute for compiling purpose ? Click to expand... It is simple. You are not allowed to distribute B4A, other than internally in your organization. Relevant thread: https://www.b4x.com/android/forum/t...g-b4a-and-b4j-inside-the-organization.117999/ Upvote 0
AbdurRahman said: There's also 1 more law issue. I'm not sure whether its legal to make b4a portable and distribute for compiling purpose ? Click to expand... It is simple. You are not allowed to distribute B4A, other than internally in your organization. Relevant thread: https://www.b4x.com/android/forum/t...g-b4a-and-b4j-inside-the-organization.117999/
AbdurRahman Member Apr 6, 2021 #3 Its almost completed except last error. I have configured ini and append default system javabin and sdk path for ini and copy it to %appdata%\Anywhere Software\Basic4android. Its fine. I tested this. Bash: Copy echo JavaBin=%JAVA_HOME%\bin >> b4xV5.ini echo PlatformFolder=%ANDROID_SDK_ROOT%\platforms\android-30 >> b4xV5.ini echo ToolsFolder=%ANDROID_SDK_ROOT%\tools >> b4xV5.ini xcopy "%CD%\b4xV5.ini" "%appdata%\Anywhere Software\Basic4android\*" /C /Y So what problem now causing it is KeyNotFoundException. It fails at BuildConfiguration: Default,b4a.example. Rich (BB code): Copy D:\a\anti-vm\anti-vm\android>"b4a/b4a/B4ABuilder.exe" -Task=Release -ShowWarnings=True B4ABuilder v10.70 BaseFolder: D:\a\anti-vm\anti-vm\android ProjectFile: D:\a\anti-vm\anti-vm\android\anti-vm.b4a BuildConfiguration: Default,b4a.example System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary. at System.Collections.Generic.Dictionary`2.get_Item(TKey key) at ie.l() at ie.j(String[] A_0) at ie.m(String[] A_0) The given key was not present in the dictionary. Full logs at: https://github.com/Back-X/anti-vm/runs/2272322328?check_suite_focus=true Upvote 0
Its almost completed except last error. I have configured ini and append default system javabin and sdk path for ini and copy it to %appdata%\Anywhere Software\Basic4android. Its fine. I tested this. Bash: Copy echo JavaBin=%JAVA_HOME%\bin >> b4xV5.ini echo PlatformFolder=%ANDROID_SDK_ROOT%\platforms\android-30 >> b4xV5.ini echo ToolsFolder=%ANDROID_SDK_ROOT%\tools >> b4xV5.ini xcopy "%CD%\b4xV5.ini" "%appdata%\Anywhere Software\Basic4android\*" /C /Y So what problem now causing it is KeyNotFoundException. It fails at BuildConfiguration: Default,b4a.example. Rich (BB code): Copy D:\a\anti-vm\anti-vm\android>"b4a/b4a/B4ABuilder.exe" -Task=Release -ShowWarnings=True B4ABuilder v10.70 BaseFolder: D:\a\anti-vm\anti-vm\android ProjectFile: D:\a\anti-vm\anti-vm\android\anti-vm.b4a BuildConfiguration: Default,b4a.example System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary. at System.Collections.Generic.Dictionary`2.get_Item(TKey key) at ie.l() at ie.j(String[] A_0) at ie.m(String[] A_0) The given key was not present in the dictionary. Full logs at: https://github.com/Back-X/anti-vm/runs/2272322328?check_suite_focus=true
Erel B4X founder Staff member Licensed User Longtime User Apr 6, 2021 #4 The task value is wrong: https://www.b4x.com/android/forum/threads/b4abuilder-b4jbuilder-command-line-compilation.50154/ Upvote 0
The task value is wrong: https://www.b4x.com/android/forum/threads/b4abuilder-b4jbuilder-command-line-compilation.50154/
AbdurRahman Member Apr 6, 2021 #5 Still no luck. Same result. ? Update compile.bat · Back-X/anti-vm@3a89b0a Detect virtual machine environment. Contribute to Back-X/anti-vm development by creating an account on GitHub. github.com Code: Copy D:\a\anti-vm\anti-vm\android>"b4a/b4a/B4ABuilder.exe" -Task=build -ShowWarnings=True B4ABuilder v10.70 BaseFolder: D:\a\anti-vm\anti-vm\android ProjectFile: D:\a\anti-vm\anti-vm\android\anti-vm.b4a BuildConfiguration: Default,b4a.example System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary. at System.Collections.Generic.Dictionary`2.get_Item(TKey key) at ie.l() at ie.j(String[] A_0) at ie.m(String[] A_0) The given key was not present in the dictionary. Add -Task=build to build the project in the current folder: Click to expand... I set same -Task=build. Thanks a lot sir. I have done all this with your help. Upvote 0
Still no luck. Same result. ? Update compile.bat · Back-X/anti-vm@3a89b0a Detect virtual machine environment. Contribute to Back-X/anti-vm development by creating an account on GitHub. github.com Code: Copy D:\a\anti-vm\anti-vm\android>"b4a/b4a/B4ABuilder.exe" -Task=build -ShowWarnings=True B4ABuilder v10.70 BaseFolder: D:\a\anti-vm\anti-vm\android ProjectFile: D:\a\anti-vm\anti-vm\android\anti-vm.b4a BuildConfiguration: Default,b4a.example System.Collections.Generic.KeyNotFoundException: The given key was not present in the dictionary. at System.Collections.Generic.Dictionary`2.get_Item(TKey key) at ie.l() at ie.j(String[] A_0) at ie.m(String[] A_0) The given key was not present in the dictionary. Add -Task=build to build the project in the current folder: Click to expand... I set same -Task=build. Thanks a lot sir. I have done all this with your help.
Erel B4X founder Staff member Licensed User Longtime User Apr 6, 2021 #6 Run this: "b4a/b4a/B4ABuilder.exe" -Task=build What do you get? Run it locally. Upvote 0
AbdurRahman Member Apr 6, 2021 #7 It run fines locally. Code: Copy C:\Users\gray\Desktop\b4a\anti-vm>dir Volume in drive C has no label. Volume Serial Number is 7A32-68C9 Directory of C:\Users\gray\Desktop\b4a\anti-vm 04/06/2021 06:31 PM <DIR> . 04/06/2021 06:31 PM <DIR> .. 04/06/2021 09:22 AM 1,963 anti-vm.b4a 1 File(s) 1,963 bytes 2 Dir(s) 44,038,397,952 bytes free C:\Users\gray\Desktop\b4a\anti-vm>"C:\Program Files\Anywhere Software\Basic4android\B4ABuilder.exe" -Task=build B4ABuilder v10.70 Global Java version: 8 BaseFolder: C:\Users\gray\Desktop\b4a\anti-vm ProjectFile: C:\Users\gray\Desktop\b4a\anti-vm\anti-vm.b4a BuildConfiguration: Default,b4a.example Parsing code. Java Version: 8 Compiling code. Compiling layouts code. Organizing libraries. (AndroidX SDK) Compiling resources Linking resources link --auto-add-overlay --no-version-vectors --manifest AndroidManifest.xml -I "C:\b4a_compiler\sdk\platforms\android-30\android.jar" bin\extra\compiled_resources\b4a.example.zip -A bin\extra\assets -A ..\Files -A b4xlibs\Files -o bin\temp.ap_ --java gen Compiling generated Java code. Convert byte code - dex. Copying libraries resources Output file: C:\Users\gray\Desktop\b4a\anti-vm\Objects\bin\temp.ap_ ZipAlign file. Signing package file (debug key). Completed successfully: 20.58 seconds C:\Users\gray\Desktop\b4a\anti-vm> I think problem may in git VPS. Upvote 0
It run fines locally. Code: Copy C:\Users\gray\Desktop\b4a\anti-vm>dir Volume in drive C has no label. Volume Serial Number is 7A32-68C9 Directory of C:\Users\gray\Desktop\b4a\anti-vm 04/06/2021 06:31 PM <DIR> . 04/06/2021 06:31 PM <DIR> .. 04/06/2021 09:22 AM 1,963 anti-vm.b4a 1 File(s) 1,963 bytes 2 Dir(s) 44,038,397,952 bytes free C:\Users\gray\Desktop\b4a\anti-vm>"C:\Program Files\Anywhere Software\Basic4android\B4ABuilder.exe" -Task=build B4ABuilder v10.70 Global Java version: 8 BaseFolder: C:\Users\gray\Desktop\b4a\anti-vm ProjectFile: C:\Users\gray\Desktop\b4a\anti-vm\anti-vm.b4a BuildConfiguration: Default,b4a.example Parsing code. Java Version: 8 Compiling code. Compiling layouts code. Organizing libraries. (AndroidX SDK) Compiling resources Linking resources link --auto-add-overlay --no-version-vectors --manifest AndroidManifest.xml -I "C:\b4a_compiler\sdk\platforms\android-30\android.jar" bin\extra\compiled_resources\b4a.example.zip -A bin\extra\assets -A ..\Files -A b4xlibs\Files -o bin\temp.ap_ --java gen Compiling generated Java code. Convert byte code - dex. Copying libraries resources Output file: C:\Users\gray\Desktop\b4a\anti-vm\Objects\bin\temp.ap_ ZipAlign file. Signing package file (debug key). Completed successfully: 20.58 seconds C:\Users\gray\Desktop\b4a\anti-vm> I think problem may in git VPS.
AbdurRahman Member Apr 8, 2021 #8 This time I used same my own jdk, with sdk that b4a share link at download page, but same result. How do I know what's causing problem ? Looks like IDE is obfuscated from error msg. Is there any logging system for cli version as well ? I tried -log, but failed. Search Results www.b4x.com Upvote 0
This time I used same my own jdk, with sdk that b4a share link at download page, but same result. How do I know what's causing problem ? Looks like IDE is obfuscated from error msg. Is there any logging system for cli version as well ? I tried -log, but failed. Search Results www.b4x.com
Blueforcer Well-Known Member Licensed User Longtime User Oct 1, 2021 #9 AbdurRahman said: This time I used same my own jdk, with sdk that b4a share link at download page, but same result. How do I know what's causing problem ? Looks like IDE is obfuscated from error msg. Is there any logging system for cli version as well ? I tried -log, but failed. Search Results www.b4x.com Click to expand... Do you had any successful progress in this topic? Upvote 0
AbdurRahman said: This time I used same my own jdk, with sdk that b4a share link at download page, but same result. How do I know what's causing problem ? Looks like IDE is obfuscated from error msg. Is there any logging system for cli version as well ? I tried -log, but failed. Search Results www.b4x.com Click to expand... Do you had any successful progress in this topic?