Quick Links: Download Gideros Studio | Gideros Documentation | Gideros Development Center | Gideros community chat | DONATE
One-click Android Deployment for Gideros -NO ECLIPSE USED! — Gideros Forum

One-click Android Deployment for Gideros -NO ECLIPSE USED!

MauMauMauMau Member
edited August 2013 in General questions
Hi there, I don't know if this was already mentioned here, but I just wanted to share this with you.

After struggling around with Eclipse for a week now, unable to export my Gideros projects to my Android phone, I was near to give up and switch back to iOS development again. Then I fortunately found this simple method to build and deploy a Gideros project with literally one click only! This solution worked immediately for me. Thanks to the guys from biorythm games:

http://biorhythmgames.com/post/36099483258/one-click-android-deployment-for-gideros

This guide explains how to set up Gideros once to export a simple .bat file along with your project. After exporting the project, just double-click this bat file and all is done automatically!!!

It can be as simple! Just follow the instructions on that page and make sure that

- Your phone is set to USB debugging mode and connected properly to your PC

- Environment variable named JAVA_HOME is set on your Windows machine. Set the value of this variable to the path of the Java SDK on your PC (in my case C:\Program Files\Java\jdk1.7.0_25).



+1 -1 (+4 / -0 )Share on Facebook

Comments

  • Ah, glad you found it. Just was writing in the other post about something similar but could not find it :)
  • Glad to see people using this and finding it useful :)
  • john26john26 Maintainer
    Very useful! Removes the cognitive burden of learning Eclipse on top of everything else!
  • But what happens to all the configuration/permission stuff that goes into the Manifest file, if it bypassed ?
  • MauMauMauMau Member
    edited August 2013
    Since the method above allows to build a debug release only, I extended the original .bat file to build a final .apk as well.

    The difference between the extended .bat file and the original one are:
    - A keystore file is generated and saved in the project's dir.
    - A file named ant.properties is generated and saved in the project's dir (which contains data about the keystore generated and is required by ant when building a self-signed release)
    - Then Ant is called with the -release option instead of the -debug option.

    I also placed the extended script in Gidero's templates folder, so when I export my project I can choose wether to use the exported build.bat to build a debug version or the build_release.bat to build a release version from it.

    This works quite well, but since I am still new to this topic I wonder if you have any suggestions using this method.


    Instructions:

    Just download the attached modified build_release.bat file and place it in the same folder as the build.bat file above (Gideros\Templates\Eclipse\Android Template):

    Open it with a text editor and adjust the settings / pathes on top of the file to your needs:
    SET keytoolPath="C:\Program Files\Java\jdk1.7.0_25\bin\keytool.exe"
    SET appName=MyAppName
    SET keyPass=MyPassword
    SET storePass=MyPassword
    SET issuerData="CN=John Doe, OU=Development, O=MyCompany,L=MyCity, ST=MyState, C=US"


    When you export your Gideros project then, it also exports a build_release.bat file in your project dir now. Since you need to use different keys for your different projects, open the .bat file with a text editor before executing it and enter a desired keystore name and password that should be used with this project. Then double-click the .bat and a release .apk should be generated (located in the /bin folder of your project).

    I tested it and it worked well -but are there any disadvantages using this method? Or could we even more simplify this process?



    zip
    zip
    build_release_bat.zip
    2K

    Likes: Fiam, bali001

    +1 -1 (+2 / -0 )Share on Facebook
  • Eclipse is stuck at importing a Project, The xx M of 147M changes sometimes ..but have been waiting for 30 mins now ( my pc is not that slow ).
    Would like to have another option as to work with eclipse , as its the worst IDE i'v seen

    Likes: OZApps

    +1 -1 (+1 / -0 )Share on Facebook
  • @sparc, I agree with you, subjection to using Eclipse is criminal. It would be nice if there would be a workflow/batch file build in Gideros that eliminates the need to tinkering with Eclipse.

    @ar2rsawseen, isn't Android Studio also a custom version of Eclipse
    twitter: @ozapps | http://www.oz-apps.com | http://howto.oz-apps.com | http://reviewme.oz-apps.com
    Author of Learn Lua for iOS Game Development from Apress ( http://www.apress.com/9781430246626 )
    Cool Vizify Profile at https://www.vizify.com/oz-apps
  • i got an error :

    [mergemanifest] Manifest merger disabled. Using project manifest only.
    [echo] Handling aidl files...
    [aidl] Found 1 AIDL files.
    [aidl] Compiling 1 AIDL files.
    [echo] ----------
    [echo] Handling RenderScript files...
    [echo] ----------
    [echo] Handling Resources...
    [aapt] Generating resource IDs...
    [aapt] C:\Users\Asus\Documents\Visual Studio 2010\Projects\giderosman\giderosman\bin\Debug\2x\ElementalClash\bin\AndroidManifest.xml:2: error: No resource identifier found for attribute 'installLocation' in package 'android'
    [aapt] C:\Users\Asus\Documents\Visual Studio 2010\Projects\giderosman\giderosman\bin\Debug\2x\ElementalClash\bin\AndroidManifest.xml:14: error: No resource identifier found for attribute 'xlargeScreens' in package 'android'
    [aapt] C:\Users\Asus\Documents\Visual Studio 2010\Projects\giderosman\giderosman\bin\Debug\2x\ElementalClash\bin\AndroidManifest.xml:20: error: Error: String types not allowed (at 'configChanges' with value 'keyboard|keyboardHidden|orientation|screenSize').

    anyone knows why?
  • @bysreg it seems either you need to upgrade your Android SDK or select higher target
  • @ar2rsawseen, i have already installed android4.3(api 18),
    by higher target, do you mean the targetsdkversion? i had it set to 18, which is default from gideros latest version, right?
  • I have not used this deployment system so I don't know how it goes here, but the error is the same if I would try to build the project with Android SDK <= 4.0
    :)
  • jiaullah123jiaullah123 Member
    edited November 2013
    @speedy.techno, This is really attractive. I have also got the benefit to have such a nice experience.
  • Hello,

    This is great is this possible to work on a Linux system that is running wine?

    Thanks a lot.
  • i am trying to get it to work on the MAC....

    REAL programmers type copy con filename.exe
    ---------------------------------------
  • @MuaMua, when I used your build_release code, it keeps saying,"The system can not find the path specified," even though this path does exist. I put in the correct number, too (5 for me) and it still doesn't work. Any idea why this is happening?
  • Daimyo21Daimyo21 Member
    edited January 2015
    @MuaMua, when I used your build_release code, it keeps saying,"The system can not find the path specified," even though this path does exist. I put in the correct number, too (5 for me) and it still doesn't work. Any idea why this is happening?

    I just tried too, same issue. Im using Android studio, what are you using Zizanyman?


    Fixed using eclipse and android SDK (not android studio) on my other PC: it was saying it was missing the tools.jar file in "C:\Program Files\Java\jre1.8.0_31\lib" (or x86 if u are using 32bit)

    So I took the tools.jar out of "C:\Program Files\Java\jdk1.8.0_31\lib" and put it in "C:\Program Files\Java\jre1.8.0_31\lib" and it built successfully to the phone.
Sign In or Register to comment.