Tuesday, May 19, 2009

How to attach an external jar without wrapping it

Netbeans Platform creators recommend wrapping all external JARs into dedicated module. I don't want to. I just want to include it in my module. The way to do it (described here) is to put all needed jars in release/modules/ext folder and adding some extra XML to project.xml
<class-path-extension>
<runtime-relative-path>ext/hexedit.jar</runtime-relative-path>
<binary-origin>release/modules/ext/hexedit.jar</binary-origin>
</class-path-extension>

Repeat this section for every jar put in ...ext folder.
Immediately you should see them in Libraries folder of you Project's view.

1 comment:

  1. Hi, good post. I have been wondering about this issue,so thanks for posting.

    ReplyDelete