error 41 when building android source codes

1,813 views
Skip to first unread message

Qi Jia

unread,
Oct 1, 2013, 11:38:39 PM10/1/13
to android-...@googlegroups.com
Hi, all

I am trying to download and build the android source codes, but after I run the command make it always give me the error like below:
libcore/luni/src/main/java/libcore/reflect/AnnotationAccess.java:743: type parameters of <A>A cannot be determined; no unique maximal instance exists for type variable A with upper bounds A,java.lang.annotation.Annotation
        return AnnotationFactory.createAnnotation(annotationClass, members);
                                                 ^
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
1 error
make: *** [out/target/common/obj/JAVA_LIBRARIES/core_intermediates/classes-full-debug.jar] Error 41

I am using the ubuntu10.04 and I've installed the sun_jdk 1.6.0, so could anyone help me about the problem? Thanks in advance

Steve Jones

unread,
Oct 2, 2013, 1:04:38 AM10/2/13
to android-...@googlegroups.com
Well Done you've gained the sun_jdk will no longer build android achievement. 

I never bothered going into the details instead I switched to using the oracle java 6 available here http://www.webupd8.org/2012/11/oracle-sun-java-6-installer-available.html 
as an extra bonus you will probably also have to do something like this after install

sudo rm /usr/lib/jvm/java-6-sun
sudo ln -s /usr/lib/jvm/java-6-oracle /usr/lib/jvm/java-6-sun 

or 

export JAVA_HOME= /usr/lib/jvm/java-6-oracle

if JAVA_HOME is not set build/envsetup.sh will default it to  /usr/lib/jvm/java-6-sun , hence the ghetto symlink method 

Thanks
Reply all
Reply to author
Forward
0 new messages