Skip to content
Snippets Groups Projects
  1. Jun 18, 2019
  2. Jun 14, 2019
    • Stewart Miles's avatar
      Do not update asset GUIDs unless the target filename changes. · 725a90ea
      Stewart Miles authored
      Developers tend to move the plugin around in their project. However,
      the Google.VersionHandler.dll asset GUID was changing with each release
      resulting in the DLL failing to load if multiple versions are present in
      the project. This patch fixes this issue by only generating new GUIDs
      for files that are renamed in the plugin.
      
      Bug: 127793909
      Change-Id: I4569e467f3f0c1f96722a280d62af5916344af3e
      725a90ea
    • Stewart Miles's avatar
      Disabled version locking of com.android.support:multidex · 67ade6c9
      Stewart Miles authored
      com.android.support:multidex does not use the same versioning scheme
      as other legacy Android support libraries so it should not be
      version locked.
      
      Bug: 135276990
      Fixed #234
      
      Change-Id: Idf567388cec68fca022022d14819df56a576254b
      67ade6c9
    • Stewart Miles's avatar
      Added Jetifier to download_artifacts.gradle · d0b1eb33
      Stewart Miles authored
      Added Jetifier support to the Gradle artifact downloader script.
      download_artifacts.gradle can now substitute direct and transitive
      dependencies on the legacy support libraries to Jetpack and rewrite
      references to the legacy support libraries in all downloaded libraries.
      
      This adds unit and integration tests for this functionality but does not
      yet connect this to the Android Resolver Unity plugin.
      
      https://github.com/googlesamples/unity-jar-resolver/issues/145
      Bug: 113575309
      Change-Id: Ibb92e43751425ebfd7cedfae62d275099860aaaa
      d0b1eb33
  3. Jun 13, 2019
  4. Jun 12, 2019
  5. Jun 07, 2019
    • Stewart Miles's avatar
      Version 1.2.116 · 2fff2285
      Stewart Miles authored
      * Android Resolver: Fixed resolution of Android dependencies without version
        specifiers.
      * Android Resolver: Fixed Maven repo not found warning in Android Resolver.
      * Android Resolver: Fixed Android Player directory not found exception in
        Unity 2019.x when the Android Player isn't installed.
      
      Change-Id: Idd553b1920975797ae9ffe97c8792b6fd7e2c5a9
      v1.2.116
      2fff2285
    • Stewart Miles's avatar
      Convert path separators for Windows command line paths. · dee1639d
      Stewart Miles authored
      Executing commands with POSIX paths fail on Windows, this
      modifies the CommandLine module to converts path separators for the
      tool (not the tool's arguments).
      
      https://github.com/firebase/quickstart-unity/issues/379
      
      Bug: 134758901
      Change-Id: If591a21ab2c02f5e0005a10d554f4fbbf1dae799
      dee1639d
    • Stewart Miles's avatar
      Fixed resolution of Android dependencies without version specifiers. · 8e0dd4d6
      Stewart Miles authored
      Android Resolver's artifact downloader script was failing if a
      dependency in the graph did not specify a version for an artifact.
      This commit makes it possible to handle empty version specifications
      in dependencies.
      
      In addition, this adds more information to conflicting package log
      messages and eliminates the creation of copy tasks for output
      files that already exist.
      
      Fixes #227
      Bug: 134571587
      
      Change-Id: I81d52d40c2447b6a6bfba68621fbd4b254570850
      8e0dd4d6
    • Stewart Miles's avatar
      Fixed Maven repo not found warning in Android Resolver. · a1ce88b4
      Stewart Miles authored
      It was printing out "Repo directory %s not found" rather than
      including the missing directory name in the message.
      
      Change-Id: I5777450ffd1aaa6be8bdb5cefe73d0edc3b32430
      a1ce88b4
  6. Jun 06, 2019
    • Stewart Miles's avatar
      Only poll build properties for auto-resolution with Android build target. · cc09f55d
      Stewart Miles authored
      Unity 2019.x throws an exception when
      BuildPipeline.GetPlaybackEngineDirectory() is called and the Android player
      isn't installed.  The Android build target can't be selected if it's not
      installed, so we shouldn't be polling the build system if the build target
      isn't Android.  This patch disables build system property polling on assembly
      load if the build target isn't Android.
      
      Fixes #220
      Bug: 134665717
      
      Change-Id: I147e51a9c7740d2e21fdd376abd7e6b2e7cdc7dc
      cc09f55d
  7. May 31, 2019
    • Stewart Miles's avatar
      Version 1.2.115 · 7feb88da
      Stewart Miles authored
      * Android Resolver: Fixed exception due to Unity 2019.3.0a4 removing
        x86 from the set of supported ABIs.
      
      Change-Id: I8a8f3fd91083b7c20fe66b48dc53c19eb5d73f0e
      v1.2.115
      7feb88da
    • Stewart Miles's avatar
      More gracefully handle removal of supported ABIs. · 8766298c
      Stewart Miles authored
      Unity 2019.3.0a4 removes support for x86_64 builds, removing the enum
      value UnityEditor.AndroidArchitecture.  This results in an exception
      being thrown during resolution.
      
      Bug: 134137796
      Fixes #224
      
      Change-Id: I210c05d1f4bc9aa521b9ed61ed13159e504dac42
      8766298c
  8. May 28, 2019
    • Stewart Miles's avatar
      Version 1.2.114 · 321017d0
      Stewart Miles authored
      * Android Resolver: Added support for ABI stripping when using
        mainTemplate.gradle. This only works with AARs stored in repos
        on the local filesystem.
      
      Change-Id: I2e1f00d09e365ab3204767010931530ac3ef985a
      v1.2.114
      321017d0
    • Stewart Miles's avatar
      Added support for ABI stripping in AARs pulled in from local repos. · 45202c58
      Stewart Miles authored
      This will does not support removing libraries for unused ABIs in
      AARs fetched from remote repos when using Android Gradle plugin
      2.x.x.
      
      Also, fixed handling moved maven repos in the project.
      
      Bug: 133528579
      Change-Id: I7a6fd807a03c0de7393fa6ce0f116817b9252794
      45202c58
  9. May 24, 2019
    • Ryan Meier's avatar
      Changing RunOnMainThread to public. · cea8035e
      Ryan Meier authored
      Change-Id: Ib83668dcec58429df602d0acc27d0a46283e9f10
      cea8035e
    • Stewart Miles's avatar
      Exposed RunOnMainThread from VersionHandlerImpl. · a7bd4a07
      Stewart Miles authored
      VersionHandlerImpl.RunOnMainThread() is pretty handy for editor
      plugins so this exposes it.
      
      Bug: 133495435
      Change-Id: I8c5f38bf5f53efb53bf4071fdcc264105d1fcccc
      a7bd4a07
    • Stewart Miles's avatar
      Version 1.2.113 · 7795294f
      Stewart Miles authored
      * Android Resolver: If local repos are moved, the plugin will search the
        project for matching directories in an attempt to correct the error.
      * Version Handler: Files can be now targeted to multiple build targets
        using multiple "gvh_" asset labels.
      * Android Resolver: "implementation" or "compile" are now added correctly
        to mainTemplate.gradle in Unity versions prior to 2019.
      
      Bug: 112525947
      Bug: 133243196
      Bug: 131903659
      Change-Id: I63de34783612d12cee4031033c0693ab3be289e5
      v1.2.113
      7795294f
    • Stewart Miles's avatar
      More gracefully handle Maven repos being moved in a project. · 2d167d85
      Stewart Miles authored
      Some developers move plugins around in the project breaking local
      maven repo paths.  This commit falls back to searching for local
      maven repos if the directory isn't found, warning the user of the
      file referencing the broken directory link along with the new
      path.
      
      Bug: 112525947
      Change-Id: Ibfc2bc231904ccf93919edd9b5c78d0814e3d28b
      2d167d85
    • Stewart Miles's avatar
      Added compatible way to get the AndroidPlayer directory. · 1001c153
      Stewart Miles authored
      BuildPipeline.GetPlaybackEngineDirectory() was added in Unity 2019
      to get the playback engine directory.  The Android playback engine
      directory is required to determine the version of Gradle shipped
      with the plugin so this does not work in Unity < 2019.
      
      This patch adds a compatible but slower way to retrieve the
      AndroidPlayer directory which also fixes the generation of Gradle
      dependency inclusion statements in Unity < 2019
      
      Fixes #213
      Bug: 133243196
      Change-Id: I455ec6de28900a31ea414bd1ff657404e611b0fb
      1001c153
  10. May 23, 2019
  11. May 22, 2019
    • Stewart Miles's avatar
      Version 1.2.112 · b97a80b3
      Stewart Miles authored
      * Android Resolver: Added option to disable addition of dependencies to
        mainTemplate.gradle.
        See `Assets > Play Services Resolver > Android Resolver > Settings`.
      * Android Resolver: Made paths to local maven repositories in
        mainTemplate.gradle relative to the Unity project when a project is not
        being exported.
      * Android Resolver: Fixed builds with mainTemplate.gradle integration in
        Unity 2019.
      * Android Resolver: Changed dependency inclusion in mainTemplate.gradle to
        use "implementation" or "compile" depending upon the version of Gradle
        included with Unity.
      * Android Resolver: Gracefully handled exceptions if the console encoding
        can't be modified.
      * Android Resolver: Now gracefully fails if the AndroidPlayer directory
        can't be found.
      
      Change-Id: Ib9db961c1b41eddf817b9e1827da9206c01ca6ef
      v1.2.112
      b97a80b3
    • Stewart Miles's avatar
      Version 1.2.112 · 17b49b6a
      Stewart Miles authored
      * Android Resolver: Added option to disable addition of dependencies to
        mainTemplate.gradle.
        See `Assets > Play Services Resolver > Android Resolver > Settings`.
      * Android Resolver: Made paths to local maven repositories in
        mainTemplate.gradle relative to the Unity project when a project is not
        being exported.
      * Android Resolver: Fixed builds with mainTemplate.gradle integration in
        Unity 2019.
      * Android Resolver: Changed dependency inclusion in mainTemplate.gradle to
        use "implementation" or "compile" depending upon the version of Gradle
        included with Unity.
      * Android Resolver: Gracefully handled exceptions if the console encoding
        can't be modified.
      * Android Resolver: Now gracefully fails if the AndroidPlayer directory
        can't be found.
      
      Bug: 127302270
      Bug: 132915636
      Bug: 133232328
      Bug: 133243196
      Bug: 133247696
      Bug: 133261012
      Bug: 133275965
      Change-Id: If3f91d1d2f094fb117f9c35b53e86c287c598702
      17b49b6a
    • Stewart Miles's avatar
      Fixed Gradle template builds in Unity 2019 · 90e73703
      Stewart Miles authored
      Unity 2019 changes the developer's Android project to a library when built by
      Gradle.  The application project is now a launcher which includes this library.
      However, when the application is built it doesn't include the repositories of
      the developer's library project causing any repos added by the Android Resolver
      to be ignored.  This commit fixes the issue by adding all Android Resolver
      specified repositories to all top level Gradle projects.
      
      In addition, this commit adds support for relative repo paths in
      mainTemplate.gradle.
      
      Bug: 133275965
      Bug: 133261012
      Change-Id: I863640bada62bd671bb68ebb1469490dba280311
      90e73703
    • Stewart Miles's avatar
      Patch mainTemplate.gradle using "implementation" when supported. · aac43698
      Stewart Miles authored
      This commit detects Gradle version redistributed by the Unity
      and either includes dependencies using the "compile" statement or
      "implementation" depending upon what is supported.
      
      Fixes #213
      
      Bug: 133243196
      Change-Id: I5d6940b1c432196fe92e2df7163d676af1b05745
      aac43698
  12. May 21, 2019
    • Stewart Miles's avatar
      Handle exceptions when trying to restore console encoding. · 7789bc77
      Stewart Miles authored
      In some cases the console encoding can't be set
      see c5335e2c .  In some versions
      of Unity / Mono even setting a console encoding to it's current
      value (i.e should do nothing) will throw an exception.  This
      patch handles exceptions when trying restore console encoding.
      
      Fixed #214
      Bug: 127302270
      
      Change-Id: I5869ddf00999a93f02a81343c18d2a5c68e5d599
      7789bc77
    • Stewart Miles's avatar
      Fixed mainTemplate.gradle patching with library templates. · 9819c37a
      Stewart Miles authored
      Unity 2019 uses the 'com.android.library' plugin rather than
      'com.android.application' which breaks the injection of maven repos
      for referenced artifacts.  This commit fixes the issue by injecting
      repos after either plugin statement is present in a gradle file.
      
      Bug: 133247696
      Change-Id: Ieda7c8c65a3eaecfdfefcd63655b086e0ec2a136
      9819c37a
    • Stewart Miles's avatar
      Added Android Resolver option to disable mainTemplate.gradle patching. · a61a3c3d
      Stewart Miles authored
      Some users want to use the old way of including dependencies when a
      mainTemplate.gradle file is included in their Unity project.  This adds
      an settings option to disable patching mainTemplate.gradle on
      resolution.
      
      Fixes #210
      
      Bug: 132915636
      Change-Id: Id75158333fdb4ad6a9ac97f11465458637968da9
      a61a3c3d
    • Stewart Miles's avatar
      Worked around missing AndroidPlayer directory. · 562d0a7d
      Stewart Miles authored
      In some cases developers have imported the Android resolver into
      a Unity project where the install doesn't have an Android player
      installed causing AndroidPlaybackEngineDirectory to continually
      report an error.
      
      Fixed #220
      
      Bug: 133232328
      Change-Id: I9f4a5973ec9e061bf50422e203c09d8fe7943ea3
      562d0a7d
  13. May 09, 2019