title: Reducing size of JRE in JavaFx bundle
body: <p>I created a JavaFX application, For it I bundled it <strong>As a self-contained standalone application, using a private copy of Java Runtime</strong>.</p>
  
  <p>But this became my application's size of 166MB, in which 146 Mb size is for jre.</p>
  
  <p>How can I reduce the size of my application or can say size of bundle Runtime JRE?</p>
  
  <p>I read <a href="http://www.oracle.com/technetwork/java/javase/jre-7-readme-430162.html" rel="noreferrer">somewhere</a> that some files are optional in jre, So I tried to run my application after removing those files but unable to run the application.</p>
  
  <p>So how can I remove the unused files/folders/modules from the Runtime JRE for my application ?</p>
  
  <p>It is <a href="http://docs.oracle.com/javafx/2/deployment/self-contained-packaging.htm" rel="noreferrer">said</a> that </p>
  
  <blockquote>
    <p>Only a subset of Java Runtime is included by default. Some optional
    and rarely used files are excluded to reduce the package size, such as
    all executables. If you need something that is not included by
    default, then you need to copy it in as a post-processing step.</p>
  </blockquote>
  
  <p>So by default it is not adding all the files in jre, in that case my application is not running. Application.jar is working fine as it is using system jar.
  So I add all the reamaining files in post-processing step.</p>
  
  <p>Thanks</p>