@@ -17,22 +17,12 @@ class Exomiser < Formula
1717 def install
1818 # Install the JAR and bundled configuration/example files.
1919 libexec . install Dir [ "*" ]
20- # libexec.install "exomiser-cli-#{version}.jar"
21- bin . write_jar_script libexec /"exomiser-cli-#{ version } .jar" , "exomiser" , "--sun-misc-unsafe-memory-access=allow"
22-
23- # Create a wrapper script so users can invoke Exomiser as `exomiser`
24- # from anywhere, without needing to remember the java invocation.
25- # (bin/"exomiser").write <<~SHELL
26- #!/bin/bash
27- # Wrapper script for Exomiser CLI
28- # Memory allocation defaults to 8 GB. Override with EXOMISER_MEMORY_GB:
29- # export EXOMISER_MEMORY_GB=12
30- #JAVA_BIN="#{Formula["openjdk@21"].opt_bin}/java"
31- #MEM="${EXOMISER_MEMORY_GB:-8}"
32- #JAR="#{libexec}/exomiser-cli-#{version}.jar"
33- #exec "$JAVA_BIN" -Xmx"${MEM}g" -jar "$JAR" "$@"
34- #SHELL
35- #chmod 0755, bin/"exomiser"
20+ # Create a wrapper script using Homebrew's idiomatic method.
21+ # --sun-misc-unsafe-memory-access=allow suppresses JVM warnings from
22+ # bioinformatics libraries that use internal Java APIs.
23+ bin . write_jar_script libexec /"exomiser-cli-#{ version } .jar" , "exomiser" ,
24+ "--sun-misc-unsafe-memory-access=allow" ,
25+ "-Dspring.config.location=#{ libexec } /application.properties"
3626 end
3727
3828 def caveats
@@ -80,12 +70,11 @@ def caveats
8070 MEMORY
8171 ─────────────────────────────────────────────────────────────────────
8272
83- By default the wrapper allocates 8 GB of RAM. If your analysis fails
84- due to lack of RAM, increase this by setting:
73+ By default the JVM allocates a fraction of available system RAM.
74+ For genome-scale analyses you may need more. Set JAVA_TOOL_OPTIONS
75+ before running exomiser to override this, for example:
8576
86- export EXOMISER_MEMORY_GB=12
87-
88- before running exomiser.
77+ export JAVA_TOOL_OPTIONS="-Xmx12g"
8978
9079 ─────────────────────────────────────────────────────────────────────
9180 FURTHER INFORMATION
0 commit comments