title: IntelliJ Idea and JNI: Making Sure DLL's Are Where They Need to be for Execution
body: <p>I am working with a third party library in a project, and it includes two .dll files and a .jar fie to provide a JNI Wrapper. The test project that the third party vendor included in the .jar file can be called using the following command:</p>
  
  <pre><code>java -cp product.jar com.company.samples.product.Test
  </code></pre>
  
  <p>This works just fine, as long as the .jar and both of the dll's are in the same directory.</p>
  
  <p>In my project I have placed the jar file and the dll's in the same directory, and then referenced the jar file as a library in IntelliJ Idea, but this causes the library to be unable to find the dll's. Is there a way that I can tell Idea where the dll's are so it can output them in the same directory as the jar file during execution?</p>