The following issue has been SUBMITTED. ====================================================================== http://public.kitware.com/Bug/view.php?id=12886 ====================================================================== Reported By: Frank Glinka Assigned To: ====================================================================== Project: CMake Issue ID: 12886 Category: CMake Reproducibility: N/A Severity: feature Priority: normal Status: new ====================================================================== Date Submitted: 2012-01-19 06:00 EST Last Modified: 2012-01-19 06:00 EST ====================================================================== Summary: Add a manifest or main-class file to the created jar Description: Hello,
the attached patch introduces two optional options to the add_jar function: 1) CMAKE_JAVA_MANIFEST To include name : value attribute pairs from a manifest file in the created jar at META-INF/MANIFEST.MF you can set the manifest file with: set(CMAKE_JAVA_MANIFEST mymanifest.mf) add_jar(foobar foobar.java) 2) CMAKE_JAVA_EXECUTABLE To set a class as the application entry point for stand-alone applications bundled into an executable jar you can set its name with: set(CMAKE_JAVA_EXECUTABLE foo/Main) add_jar(foobar foo/Main.java) The latter one was wasn't my priority but I included it as it was easy to realize along the first patch. It is easier to use for people only wishing to create an executable jar than achieving the same by creating a manifest file. Regards, Frank P.S. The corresponding discussion for this patch on the mailing list can be found here: http://www.cmake.org/pipermail/cmake/2011-December/048015.html ====================================================================== Issue History Date Modified Username Field Change ====================================================================== 2012-01-19 06:00 Frank Glinka New Issue 2012-01-19 06:00 Frank Glinka File Added: java-manifest-executable-option.patch ====================================================================== -- Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://public.kitware.com/cgi-bin/mailman/listinfo/cmake-developers