Skip to content
This repository
Browse code

Pass JVM options to dx

  • Loading branch information...
commit 85b3859c03d036f855aeef48565c477930ff239c 1 parent 505668e
Zach Oakes authored alexander-yakushev committed

Showing 1 changed file with 3 additions and 2 deletions. Show diff stats Hide diff stats

  1. 5  src/leiningen/droid/build.clj
5  src/leiningen/droid/build.clj
@@ -25,11 +25,12 @@
25 25
 (defn create-dex
26 26
   "Creates a DEX file from the compiled .class files."
27 27
   [{{:keys [sdk-path out-dex-path external-classes-paths
28  
-            force-dex-optimize]} :android,
  28
+            force-dex-optimize dex-opts]} :android,
29 29
     compile-path :compile-path resource-paths :resource-paths :as project}]
30 30
   (info "Creating DEX....")
31 31
   (ensure-paths sdk-path)
32 32
   (let [dx-bin (sdk-binary sdk-path :dx)
  33
+        options (or dex-opts [])
33 34
         no-optimize (if (and (not force-dex-optimize) (dev-build? project))
34 35
                       "--no-optimize" [])
35 36
         annotations (str sdk-path "/tools/support/annotations.jar")
@@ -38,7 +39,7 @@
38 39
         existing-resource-paths (filter #(.exists (java.io.File. %))
39 40
                                         resource-paths)]
40 41
     (with-process [proc (map str
41  
-                             (flatten [dx-bin "--dex" no-optimize
  42
+                             (flatten [dx-bin options "--dex" no-optimize
42 43
                                        "--output" out-dex-path
43 44
                                        compile-path annotations deps
44 45
                                        external-paths

0 notes on commit 85b3859

Please sign in to comment.
Something went wrong with that request. Please try again.