Unable to build app for testing:

The place to discuss anything and everything about running your LiveCode on Android

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Unable to build app for testing:

Post by paulsr » Sat Feb 22, 2014 9:28 am

Greetings:

In attempting to build an app to transfer it to an Android device, I am seeing the following error:

"Unable to build app for testing: could not compile application class"

It pops up immediately after the "Building Classes" message.

I can see that other people have experienced this problem, but I haven't found a solution that works for me.

I am using LC6.6(dp1) on a Mac with Mavericks. I've also tried LC6.5

I have set Minimum Android Version to 2.2. - Froyo, but have tried others.

I have a very simple app that just displays a button, and that transfers fine.

But a slightly more complex app, that is still in development, and doesn't do anything fancy (no GPS, camera, SQLite, revZip, etc.) will not build.

It works fine on a variety of AVDs.

I do not yet have a development key so I have set "Sign for development only".

I'm stuck. Anyone have any ideas? TIA...

--paul

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: Unable to build app for testing:

Post by paulsr » Sat Feb 22, 2014 11:42 am

Well, this is strange. I'm now getting the same error if I try to build for an Android Virtual Device.

So, it would seem that attempting to build for a real device has changed something somewhere.

--paul

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Unable to build app for testing:

Post by Simon » Sat Feb 22, 2014 11:55 am

Hi Paul,
Just a thought...
Check all of your code for anything that might be iOS only. Like;
mobileControlSet tControl, "fontName", true

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: Unable to build app for testing:

Post by paulsr » Sat Feb 22, 2014 12:29 pm

Simon wrote:Hi Paul,
Just a thought...
Check all of your code for anything that might be iOS only. Like;
mobileControlSet tControl, "fontName", true

Simon
Good thought Simon, but one of the apps I'm trying to build definitely does not have any "mobile" or "iphone" commands.

And, the two apps I'm trying to build both work on the AVDs.

But... am I not right in thinking the "mobile" commands work on both iOS and Android? It's only iOS-specific if it's an "iphone" command.

Also, isn't it okay to code something like...

Code: Select all

  
if the platform is "iphone" then
     iphoneUseDeviceResolution false
end if      
That shouldn't barf, should it?

Tkx,

--paul

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Unable to build app for testing:

Post by Simon » Sat Feb 22, 2014 12:54 pm

Hi Paul,
Nope, mobile... isn't all for both devices. Check out the example I gave when using native text, there are lots of "(iOS only)".
Yep, if the platform is "iphone" should be working.
Well, this is strange. I'm now getting the same error if I try to build for an Android Virtual Device.
And, the two apps I'm trying to build both work on the AVDs.
Only reason I answered was because of the earlier post.

Good to know that just the single button app works. I think that means you'll have to start stripping code out till it works again.

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

LCNeil
Livecode Staff Member
Livecode Staff Member
Posts: 1223
Joined: Wed Oct 03, 2012 4:07 pm

Re: Unable to build app for testing:

Post by LCNeil » Sat Feb 22, 2014 4:58 pm

Hi Paul,

If possible could you take a screenshot of your standalone application settings and post it here as there could be something set/named there that is causing the issue.

Kind Regards,


Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
-

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: Unable to build app for testing:

Post by paulsr » Sun Feb 23, 2014 5:47 am

Well... this is embarrassing!

Based on Neil's comment about the possibility of there being something wrong in the standalone application settings, I decided to see if there was anything different between the single-button test program which works, and the relatively simple app that doesn't.

And, I noticed I had changed the contents of the "Identifier" which by default shows as "com.yourcompany.yourapp".

Changing it back to the default solves the problem.

It seems like an odd thing to cause an error, and it seems like an odd error message, but at least I have a solution. Hopefully this will help someone else.

Thanks for all the input.

--paul

Simon
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 3901
Joined: Sat Mar 24, 2007 2:54 am

Re: Unable to build app for testing:

Post by Simon » Sun Feb 23, 2014 5:55 am

Hi Paul,
I've only seen that "-" and "&" not working there.
Was it one of those or did you find another?

Simon
I used to be a newbie but then I learned how to spell teh correctly and now I'm a noob!

paulsr
Posts: 222
Joined: Thu Jul 19, 2012 9:47 am
Contact:

Re: Unable to build app for testing:

Post by paulsr » Sun Feb 23, 2014 7:13 am

Oh! Yes, you're right Simon. I did change the Identifier to something containing a hyphen. That seems to cause the problem.

Would be nice if LC could check for this in the Standalone Application Settings screen, rather than later, throwing-up a bizarre error message at build time.

Hopefully Neil is reading this and thinking "Hmm, good idea." :-)

--paul

LCNeil
Livecode Staff Member
Livecode Staff Member
Posts: 1223
Joined: Wed Oct 03, 2012 4:07 pm

Re: Unable to build app for testing:

Post by LCNeil » Tue Feb 25, 2014 9:48 am

Hi Paul,

We always take feedback on board and I do think having more informative error dialogs would be beneficial.

I will forward your request onto our Quality Control and development teams.

Kind Regards,


Neil Roger
--
RunRev Support Team ~ http://www.runrev.com
-

Post Reply