Document directory
- 1. Import the jar package in eclipse
- Ii. Conversion to Dalvik format failed with error 1
- Iii. Export the jar package from eclispe
1. Import the jar package in eclipse
The following two methods are used:
Method 1:
1. Right-click the project root directory and click Properties to enter Properties
2.
On the properties page, select Java build path, select the libraries tag, and click Add external jars.
3. Find the jar package to be added and click OK.
4. Right-click the jar and select Properties to specify the native location.
Method 2: (this method was introduced by a colleague, but in the high version of Eclipse, it failed: After the jar is imported, the project still prompts an error, so the APK cannot be compiled .)
1. copy and paste lib (including jar) to the Project
2. Right-click jar and choose add build path)
Ii. Conversion to Dalvik format failed with error 1
After the package project is imported, many Android. Jar methods cannot be used. Therefore, the original jar is deleted. On the properties page, select Java build path, select the libraries tag, click Add external jars, and re-import.
Android. jar package.
At this time, the project does not prompt that the Android. Jar method cannot be used, and the following error message is left:
Conversion to Dalvik format failed with error 1
The reason is that you cannot directly join the android library.
Solution: edit the. classpath file,
This file may contain this item: <classpathentry kind = "lib" Path = "Your specified High Version address", changed
<Classpathentry kind = "con" Path = "com. Android. Ide. Eclipse. ADT. android_framework"/>
You can.
Clean
.
Iii. Export the jar package from eclispe
Export the file directly, and then add a third-party so Library to the JAR file.
1.
Select the SRC folder
----> Right-click Export... ---> JAVA ---> jar
File ---> next --> select the path and name of JAR file --> next ---> Select Main
Class ---> finish.
2. jar is a compressed package.
, Manually add the associated so Library to the compressed package.