简体   繁体   English

Eclipse Jar构建路径

[英]Eclipse Jar Build Path

I have looked over articles and forum posts about this; 我看过有关此的文章和论坛帖子; making a lib and adding it to your build path. 创建一个lib并将其添加到您的构建路径中。 Well, I did this exactly. 好吧,我正是这样做的。 I have a libs folder and from that, I tried to ways. 我有一个libs文件夹,从那开始,我尝试了一些方法。 I selected them, right clicked, went to build path, and added them. 我选择了它们,右键单击,创建了路径,然后添加了它们。 It moved them to a library. 它把他们搬到了图书馆。 I also tried to right click the project, go to properties, go to build path, libraries, add jar, and selected it from my libs folder. 我还尝试右键单击该项目,转到属性,转到生成路径,库,添加jar,然后从我的libs文件夹中选择它。 However, when I run it, it still doesn't find the jar, what did I do wrong here? 但是,当我运行它时,它仍然找不到罐子,我在这里做错了什么?

Step 1: Select Jar Files in Lib Folder > Right Click > Build Path > Add 步骤1:在Lib文件夹中选择Jar文件>右键单击>构建路径>添加

Step 2: Select Project > Right Click > Properties > Build Path > Libraries > Add Jars > Select and add the jars. 步骤2:选择项目>右键单击>属性>构建路径>库>添加Jars>选择并添加jars。

If the JAR files are showing up under Referenced Libraries, then Eclipse should be including them in the build path. 如果JAR文件显示在“引用的库”下,则Eclipse应该将它们包括在构建路径中。 I would make sure that 1) the JAR file has the file you think it does in it, and 2) that the JAR doesn't have any native libraries that you need (which would prevent it from working). 我将确保1)JAR文件中包含您认为包含的文件,以及2)JAR没有您需要的任何本机库(这将阻止其工作)。

try to right click the project, go to properties, go to build path. 尝试右键单击项目,转到属性,转到构建路径。

them remove the existing JRE System library 他们删除现有的JRE系统库

finaly add new lybrary, JRE System library 最后添加新的库,JRE系统库

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM