Android N requires the IDE to being running with Java 1.8 or later

Source: Internet
Author: User

Android Studio requires two jdk:ide JDK and project JDK:

The former is the JDK that the IDE uses to run itself.

The latter is used to compile Java code

Project JDK
    • You can see the changes through file-> other settings-> default project structure

    • If the item compilesdkversion >= 21, it should be set to JAVA7 or 8

    • This configuration can also be set in Local.properties

IDE JDK
    • When Mac OSX runs the IDE, the system automatically selects the JDK based on the jvmversion configuration in Android Studio.app/contents/info.plist.

The problem is that the Android N version of the layout editor requires IDE jdk1.8 and the above versions to display properly

It is important to note that you do not modify Info.plish, which destroys the IDE signature and affects patch updates.

Mac can be opened in this way

$ export STUDIO_JDK=/LIBRARY/JAVA/JAVAVIRTUALMACHINES/JDK1. 8  /applications/android\ Studio.app

Normal use of Android N version of the layout editor but the problem is here again.

On Mac systems, the default IDE JDK is 1.6. This is mainly because fonts have antialiasing on the jdk1.6, while 1.7 and 1.8 do not. Using jkd1.8: Using jkd1.6:

And there are some other questions I won't go into.

All in all, if you're like me. Use Mac OSX to use 2.1.2 's Android studio first, and then lower the version of the layout editor.

If you have to study, go check it out. Portal (FQ required)

Android N requires the IDE to being running with Java 1.8 or later

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.