Build failed. Check the console window for errors.

Hi, I have been playing with the trial version Corona (ver 2011.288 (2011.1.20)) for a few weeks now, and would like to build a project to test on my Android device.

I start by opening the project and select File -> Build.

On the build for Android screen, I enter a name for the package, e.g. com.abcd.appname where abcd is my name, but I dont actually own a web domain. Does that matter?

I select Target OS Compatibility to be Android 2.2

Keystore is set to C:\Program Files\Ansca\Corona Simulator\Resources\debug.keystore

Key Alias combo, selected androiddebugkey

and Save To Folder as C:\Users\abcd\Desktop\Android Deployment

I enter password of ‘android’ when prompted and then click the Build button.

Connecting to server… message gets to about a quarter of the progress bar and then a message ‘Build failed. Check the console window for errors.’ is displayed.

The Corona Simulator window does not show any errors.

I have tried to do this many times but get the same result every time.

Any help would be appreciated.

Thanks in advance

Sai

[import]uid: 39797 topic_id: 7886 reply_id: 307886[/import]

Hi,

There is another thread about that issue somewhere, that you may want to check.

My experience of this issue is either the case of the files included in the project that should exactly match the require commands or (figured that out yesterday) the name of some sound ressources (I had a break.wav file that was making the Android build fail).

HTH,

Phil
PS : below is a raw perl script (works both on Mac and windows) I run in a project folder to check for the case issue :

[code]
#!/usr/bin/perl -w

@files = ;
$i=0;
foreach $file (@files) {
if ($file =~ /.lua/)
{
($file2,$dumb) = split(/./,$file);
}
else
{
$file2 = $file;
}
$filename[$i] = $file2;
$i = $i +1;
}
$dumb = $dumb;

@luafiles = ;
foreach $luafile (@luafiles) {
$nomFicIn=$luafile;
open(FICIN,$nomFicIn) || die “Can’t open “$nomFicIn” for reading \n”;
foreach $ligne (){
for ($j=0; $j {
if ( $ligne =~ m/"$filename[$j]"/i)
{
if ( $ligne =~ m/$filename[$j]/)
{
}
else
{
print $luafile . “\n”;
print “–”.$ligne." }
}
}
}
close(FICIN);
}
[/code] [import]uid: 27424 topic_id: 7886 reply_id: 28104[/import]

Hi Phil

Thank you for your reply.

I have updated the files name referenced in main.lua to be the same case but still it does not build.

However I tried to build a sample program from Corona and it built successfully. Therefore there is nothing wrong with the build process.

I will start again from the beginning and slowly add the code in to see where the build process fails.

I am using png files in an Images folder and mp3s in a Media folder, does that matter or does all files need to live in the same folder?

Thanks

Sai [import]uid: 39797 topic_id: 7886 reply_id: 28184[/import]

Whenever it did not build for me … it was that I had two files named the same:

test.wav
test.mp3
test.ogg

You cannot have media files named the same or it will not build.

Just a thought to check. [import]uid: 10965 topic_id: 7886 reply_id: 28192[/import]

Hi

It’s definitely something to do with the mp3 files in my Media folder because as soon as I put either one of the mp3s in that folder it does not build. Yes they are named different.

I may need to convert them to another format to see if that helps.

Thanks

Sai [import]uid: 39797 topic_id: 7886 reply_id: 28194[/import]

No, not another format — this makes more sense.

The current build has not fixed that you can not put files in sub-folders

Move the MP3 files into root folder and try to build

All files need to be in root folder ( I know this is inconvenient for organization ) but Ansca is aware of this as a current Android build issue and they hopefully will have fixed soon

[import]uid: 10965 topic_id: 7886 reply_id: 28195[/import]

Try renaming all soundfiles like this

test_wav.wav
test_mp3.mp3
test_ogg.ogg [import]uid: 9577 topic_id: 7886 reply_id: 28242[/import]

OK, thanks for all the replies.

I have made some progress, i.e. I can build now that I have taken all the .png files into the root folder. However as soon as I put a mp3 file in the root folder the build would still fail.

:frowning:

Also it does the same after I converted the mp3s into .wav files.

Strange thing is that it does build if I copy a .wav or mp3 file from a sample project!!!

Update: At last, it builds.

I changed my file name, e.g. from TestFile.mp3 to TestFile.mp2 and Corona seems to be happy with that.

I should now be able to try it on my Android device. Phew [import]uid: 39797 topic_id: 7886 reply_id: 28306[/import]