![]() ![]() ![]() JDK has as its primary components a collection of programming tools, including javac, jar, and the archiver, which packages related class libraries into a single JAR file. Compilingįor compiling Weka, you would issue a command like this (in the same directory as pom.Java Development Kit 64-bit (also known as JDK) contains the software and tools that you need to compile, debug, and run applets and applications that you've written using the Java programming language. In order to make Weka, and most of its packages, available to a wider audience (e.g., other software developers), we also publish on Maven Central. Though Maven can also generate far jar files, it is not considered good practice, as it defeats Maven's automatic version resolution. It allows you to use newer versions of libraries than defined by the dependent libraries (e.g., critical bug fixes), without having to modify any jars manually. Maven handles dependencies automatically, relying on libraries (they call them artifacts) to be publicly available, e.g., on Maven Central. However, this is a nightmare, if you need to update a single library, but all you have is a single, enormous jar. Handy if you only want to have a single jar. Whereas Ant scripts quite often create a fat jar, i.e., a jar that contains not only the project's code, but also the contain of libraries the code was compiled against. For this to work, Maven enforces a strict directory structure (though you can tweak that, if you need to). With Maven, you only specify dependent libraries, a compile and a jar plugin and maybe tweak the options a bit. In Ant, you tell it where to find Java classes for compilation, what libraries to compile against, where to put the compiled ones and then how to combine them into a jar. Though its configuration file, pom.xml is written in XML as well, Maven uses a different approach to the build process. But unlike Ant, it is a more high-level tool. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
December 2022
Categories |