(Solved) How to Import IAP Sample App

SpoonThumbSpoonThumb Posts: 426Member
edited December 2012 in ODK (OUYA Developer Kit)
Hi,

Just tried to import the IAP Sample App into Eclipse, and had quite some problems. I just managed to get it to work (or at least run on the emulator), so for future reference, here is how I solved it.

I started off importing the project in the usual fashion, getting the following error along the way:

Cannot nest 'IAPSampleActivity/src/java' inside 'IapSampleActivity/src'. To enable the nesting exclude 'java/' from 'IapSampleActivty/src'
image

The project still imports, but gives the following error in console:
[2012-12-28 12:31:40 - IapSampleActivity] Android requires compiler compliance level 5.0 or 6.0. Found '1.7' instead. Please use Android Tools > Fix Project Properties.
To solve the first problem, I manually removed the java folder from the file structure (so it just goes src/tv/ouya/sample), and then edited the .classpath file to remove the '/java' part from the src path:
<classpathentry kind="src" path="src/java"/>
becomes
<classpathentry kind="src" path="src"/>

To solve the second problem, right click on the project and go to build path -> configure build path.

Remove the old reference to ouya-sdk.jar, as this points to the wrong place. Instead, add JARs, and select the ouya-sdk.jar from the libs folder:

http://www.crystallinegreen.com/wp-content/uploads/2012/12/iap_sample_import_bug_02.png

http://www.crystallinegreen.com/wp-content/uploads/2012/12/iap_sample_import_bug_03.png
Post edited by SpoonThumb on

Comments

Sign In or Register to comment.