Re: maven build with android API 11 failed, Cann't find symbol
Well you are sort of right. Let me clarify. 1. yes.. Google/Android does not publish to Maven Central (although imho they should) 2. the android4maven project, led by Robert Manning, and myself got the android jar and some others into Maven central. This is done off the Android Open Source Project and google allowed us to push into their namespace (this is the class skeleton stuff - the android jar in the SDK does not have any implementations) http://sourceforge.net/projects/android4maven/ 3. since Android 3.0 (api level 11) and beyond are not in AOSP these are not in central, same applies for the compatibility package, maps and others 4. My Maven Android SDK Deployer can install the android.jar, maps.jar and the compatibilty jar files into your local maven repo or into a local repository server so you can use it in a team easily. This allows you to develop with any API published in the SDK including Android 3.0 and up and the compatibility package https://github.com/mosabua/maven-android-sdk-deployer 5. All this and more is discussed on the Maven Android mailing list.. https://groups.google.com/forum/#!forum/maven-android-developers https://groups.google.com/forum/#%21forum/maven-android-developers Hope that clarifies things a bit. manfred On 11-09-19 07:53 AM, Guillaume Polet wrote: OK, I guess this is the main issue then. From what I understand: * Android guys do not publish their jars to a public Maven repo * If the version used in your dependencies matches the ones used by the Android team, then 2.2= API Level 8. If you want API Level 11, you need version 3.0 (http://developer.android.com/sdk/android-3.0.html) * There are some cool dudes who create jars with Class skeletons and empty method stubs to reproduce all the class names and method signatures so that you can compile your project. Unfortunately, the latests jars have not been created and/or published yet. * There is another guy (who just replied you) who has created a project just for the purpose of deploying the jars from the Android SDK to your local Maven repository: https://github.com/mosabua/maven-android-sdk-deployer. Read this for how to use this tool: https://github.com/mosabua/maven-android-sdk-deployer/blob/master/README.markdown Cheers, Guillaume Le 19/09/2011 16:23, darakok a écrit : I think you're right. My dependency references Android 2.2. dependency groupIdandroid/groupId artifactIdandroid/artifactId version2.2_r2/version scopeprovided/scope /dependency Thanks for your help. darakok -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4819154.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
maven build with android API 11 failed, Cann't find symbol
I use maven to build my android project. It was working fine until I make use of method exclusively available to API 11 and above. In the pom file, I do change the android build version to 11. So presume I have set the right android jar for maven build to succeed. But it turns out to be completely the opposite. Because exactly the one method that I just added failed during the build. Maven complains Cannot find symbol: MenuItem.getActionView So do you have any idea what is the problem? Thanks dara kok -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4818232.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven build with android API 11 failed, Cann't find symbol
Not much information here, but I guess that when you say 11 you mean that this is the target level. From what it looks like, it seems that android API jars for that version are not available. See also this: http://stackoverflow.com/questions/5253029/why-arent-the-android-sdk-jars-in-any-maven-repository Regarding the message you are mentionning, it just says that the method getActionView cannot be found on the class MenuItem (but the message is quite clear and comes from the java compiler), meaning that Maven is not using the new version you expect. As to why this is the case, without the pom and settings or more information, it is impossible to help you more. Regards, Guillaume Le 19/09/2011 10:35, darakok a écrit : I use maven to build my android project. It was working fine until I make use of method exclusively available to API 11 and above. In the pom file, I do change the android build version to 11. So presume I have set the right android jar for maven build to succeed. But it turns out to be completely the opposite. Because exactly the one method that I just added failed during the build. Maven complains Cannot find symbol: MenuItem.getActionView So do you have any idea what is the problem? Thanks dara kok -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4818232.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven build with android API 11 failed, Cann't find symbol
This is part of my POM file where i specify the version of Android API jar file to compile with. plugin groupIdcom.jayway.maven.plugins.android.generation2/groupId artifactIdmaven-android-plugin/artifactId version2.9.0-beta-5/version configuration sdk platform8/platform /sdk deleteConflictingFilestrue/deleteConflictingFiles resourceDirectory${project.build.directory}/filtered-resources /resourceDirectory /configuration extensionstrue/extensions /plugin I'm sure the correct Android jar file is used to compile my project because it shows the jar file path in the console just before the error comes up. Interestingly, that same jar file is reference in my project in eclipse and Eclipse recognize the method that I have problem with when building with maven. -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4818946.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven build with android API 11 failed, Cann't find symbol
Find my answers in your e-mail: Le 19/09/2011 15:20, darakok a écrit : This is part of my POM file where i specify the version of Android API jar file to compile with. plugin groupIdcom.jayway.maven.plugins.android.generation2/groupId artifactIdmaven-android-plugin/artifactId version2.9.0-beta-5/version configuration sdk platform8/platform /sdk deleteConflictingFilestrue/deleteConflictingFiles resourceDirectory${project.build.directory}/filtered-resources /resourceDirectory /configuration extensionstrue/extensions /plugin Ok, so If you change here to 11, it does not modify the classpath of the maven compiler plugin. It simply informs thet maven android plugin that you are targetting the level 11. The jar used by the maven compiler is defined in your dependencies. I'm sure the correct Android jar file is used to compile my project because it shows the jar file path in the console just before the error comes up. Interestingly, that same jar file is reference in my project in eclipse and Eclipse recognize the method that I have problem with when building with maven. Can't really know what's going on here since you have not posted your dependencies and since we don't know where Maven resolves your artifacts (if you installed the jars manually, you can put whatever version you want and therefore have an the wrong jar). Eclipse is of no use here because you can easily add jars through other means (add a jar, add a library container, etc...). Actually, if you have such external (to Maven) dependency , you should remove it because they are not portable from one IDE to another and mainly because this will not be reflected in your Maven build (probably indicates why you are having some issues in your build now). -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4818946.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org Cheers, Guillaume - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven build with android API 11 failed, Cann't find symbol
I think you're right. My dependency references Android 2.2. dependency groupIdandroid/groupId artifactIdandroid/artifactId version2.2_r2/version scopeprovided/scope /dependency Thanks for your help. darakok -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4819154.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven build with android API 11 failed, Cann't find symbol
Use my Maven Android SDK Deployed you can find on github and add a dependency as documented in the readers. The version should be 11_r1 on the dependency... Manfred darakok mrpc.cambo...@gmail.com wrote: This is part of my POM file where i specify the version of Android API jar file to compile with. plugin groupIdcom.jayway.maven.plugins.android.generation2/groupId artifactIdmaven-android-plugin/artifactId version2.9.0-beta-5/version configuration sdk platform8/platform /sdk deleteConflictingFilestrue/deleteConflictingFiles resourceDirectory${project.build.directory}/filtered-resources /resourceDirectory /configuration extensionstrue/extensions /plugin I'm sure the correct Android jar file is used to compile my project because it shows the jar file path in the console just before the error comes up. Interestingly, that same jar file is reference in my project in eclipse and Eclipse recognize the method that I have problem with when building with maven. -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4818946.html Sent from the Maven - Users mailing list archive at Nabble.com. _ To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven build with android API 11 failed, Cann't find symbol
OK, I guess this is the main issue then. From what I understand: * Android guys do not publish their jars to a public Maven repo * If the version used in your dependencies matches the ones used by the Android team, then 2.2= API Level 8. If you want API Level 11, you need version 3.0 (http://developer.android.com/sdk/android-3.0.html) * There are some cool dudes who create jars with Class skeletons and empty method stubs to reproduce all the class names and method signatures so that you can compile your project. Unfortunately, the latests jars have not been created and/or published yet. * There is another guy (who just replied you) who has created a project just for the purpose of deploying the jars from the Android SDK to your local Maven repository: https://github.com/mosabua/maven-android-sdk-deployer. Read this for how to use this tool: https://github.com/mosabua/maven-android-sdk-deployer/blob/master/README.markdown Cheers, Guillaume Le 19/09/2011 16:23, darakok a écrit : I think you're right. My dependency references Android 2.2. dependency groupIdandroid/groupId artifactIdandroid/artifactId version2.2_r2/version scopeprovided/scope /dependency Thanks for your help. darakok -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4819154.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: maven build with android API 11 failed, Cann't find symbol
Thanks a lot. -- View this message in context: http://maven.40175.n5.nabble.com/maven-build-with-android-API-11-failed-Cann-t-find-symbol-tp4818232p4819252.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org