Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change to D8 Dexer instead of DX #6

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 16 additions & 6 deletions build.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,9 @@
</fileset>
<fileset dir="lib/deps">
<include name="*.jar" />
</fileset>
<fileset dir="lib/deps">
<include name="*.aar" />
</fileset>
</classpath>
<include name="**/*.java" />
Expand Down Expand Up @@ -78,6 +81,7 @@
<unzip dest="build/externalComponents-classes/${extensionClassFolder}">
<fileset dir="build/externalComponents-classes/${extensionClassFolder}">
<include name="**/*.jar" />
<include name="**/*.aar" />
</fileset>
</unzip>
</target>
Expand Down Expand Up @@ -117,18 +121,24 @@
<path>
<fileset dir="${ExternalComponent-class.dir}" >
<include name="*.jar"/>
</fileset>
</path>
</fileset>
<fileset dir="${ExternalComponent-class.dir}" >
<include name="*.aar"/>
</fileset>
</path>
</foreach>
</target>

<target name="dexExtension" depends="">
<basename property="extensionType" file="${extension}" suffix=".jar"/>
<java jar="lib/android/dx.jar"
<java classname="com.android.tools.r8.D8"
fork="true"
failonerror="true">
<arg value="--dex"/>
<arg value="--no-strict"/>
<classpath>
<pathelement location="lib/android/d8.jar"/>
</classpath>
<!-- TODO: add min api, android.jar lib, main dex list?-->
<arg value="--release"/>
<arg value="--output"/>
<arg value="${ExternalComponent.dir}/${extensionType}/classes.jar"/>
<arg value="${ExternalComponent-class.dir}/${extensionType}.jar"/>
Expand All @@ -138,6 +148,7 @@




<!-- =====================================================================
extensions: create ${extension}.aix for each external component.
===================================================================== -->
Expand Down Expand Up @@ -187,7 +198,6 @@
<fileset dir="lib">
<include name="**/*.jar"/>
<include name="**/*.aar"/>
<exclude name="*/dx.jar"/>
</fileset>
</libraryjar>

Expand Down
Binary file modified lib/android/android.jar
Binary file not shown.
Binary file added lib/android/d8.jar
Binary file not shown.
Binary file removed lib/android/dx.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion lib/deps/.placeholder
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Any external dependencies should be placed in this directory.
This lib/deps directory is a placeholder for your lib.