Skip to content

Update java-interop and android-tools submodule mentions #9023

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

Merged
merged 5 commits into from
Jun 14, 2024
Merged
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
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/04-binding-a-java-library.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ body:
- type: markdown
attributes:
value: |
Documentation for how to troubleshoot issues with binding projects, as well as common issues and how to solve them, is available [here](https://github.com/xamarin/java.interop/wiki/Troubleshooting-Android-Bindings-Issues).
Documentation for how to troubleshoot issues with binding projects, as well as common issues and how to solve them, is available [here](https://github.com/dotnet/java-interop/wiki/Troubleshooting-Android-Bindings-Issues).

If you get stuck troubleshooting an issue, please make sure to add as much detail as you can, preferably with a reproduction if possible. This will help us diagnose the issue faster and thus resolve it quicker.
- type: dropdown
Expand Down
4 changes: 2 additions & 2 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
branch = main
[submodule "external/Java.Interop"]
path = external/Java.Interop
url = https://github.com/xamarin/java.interop.git
url = https://github.com/dotnet/java-interop
branch = main
[submodule "external/libunwind"]
path = external/libunwind
Expand All @@ -28,7 +28,7 @@
branch = master
[submodule "external/xamarin-android-tools"]
path = external/xamarin-android-tools
url = https://github.com/xamarin/xamarin-android-tools
url = https://github.com/dotnet/android-tools
branch = main
[submodule "external/xxHash"]
path = external/xxHash
Expand Down
2 changes: 1 addition & 1 deletion Documentation/release-notes/5945.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#### Bindings projects

- [GitHub Issue #835](https://github.com/xamarin/java.interop/issues/835):
- [GitHub Issue #835](https://github.com/dotnet/java-interop/issues/835):
Don't throw an `IndexOutOfRangeException` if a Java type ends with `.` or `$`.

- [GitHub Issue #5821](https://github.com/xamarin/xamarin-android/issues/5921)
Expand Down
21 changes: 10 additions & 11 deletions Documentation/release-notes/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ items.
Changes for One .NET should have neither label for now because they are not yet
user-facing.

PRs that bump Java.Interop, xamarin-android-tools, or monodroid generally don't
PRs that bump Java.Interop, android-tools, or monodroid generally don't
need to be labeled, but Mono bumps that include changes that could affect
Android users should be labeled.

Expand Down Expand Up @@ -123,7 +123,7 @@ Examples:
```markdown
### Build and deployment performance

- [Java.Interop GitHub PR 596](https://github.com/xamarin/java.interop/pull/596):
- [Java.Interop GitHub PR 596](https://github.com/dotnet/java-interop/pull/596):
Use `File.Exists()` instead of `DirectoryGetFile()` in a few places. This
reduced the time for the `LinkAssembliesNoShrink` task from about 710
milliseconds to about 430 milliseconds for a small test Xamarin.Forms app on
Expand Down Expand Up @@ -191,19 +191,19 @@ Example showing multiple release notes sections for a Java.Interop bump:
```markdown
### Build and deployment performance

- [Java.Interop GitHub PR 440](https://github.com/xamarin/java.interop/pull/440),
[Java.Interop GitHub PR 441](https://github.com/xamarin/java.interop/pull/441),
[Java.Interop GitHub PR 442](https://github.com/xamarin/java.interop/pull/442),
[Java.Interop GitHub PR 448](https://github.com/xamarin/java.interop/pull/448),
[Java.Interop GitHub PR 449](https://github.com/xamarin/java.interop/pull/449),
[Java.Interop GitHub PR 452](https://github.com/xamarin/java.interop/pull/452):
- [Java.Interop GitHub PR 440](https://github.com/dotnet/java-interop/pull/440),
[Java.Interop GitHub PR 441](https://github.com/dotnet/java-interop/pull/441),
[Java.Interop GitHub PR 442](https://github.com/dotnet/java-interop/pull/442),
[Java.Interop GitHub PR 448](https://github.com/dotnet/java-interop/pull/448),
[Java.Interop GitHub PR 449](https://github.com/dotnet/java-interop/pull/449),
[Java.Interop GitHub PR 452](https://github.com/dotnet/java-interop/pull/452):
Optimize several of the build steps for bindings projects. For a large
binding like _Mono.Android.dll_ itself, this reduced the total build time in a
test environment by about 50 seconds.

#### Bindings projects

- [Java.Interop GitHub PR 458](https://github.com/xamarin/java.interop/pull/458):
- [Java.Interop GitHub PR 458](https://github.com/dotnet/java-interop/pull/458):
Bindings projects did not yet automatically generate event handlers for Java
listener interfaces where the _add_ or _set_ method of the interface took two
arguments instead of just one.
Expand Down Expand Up @@ -381,8 +381,7 @@ added to `Documentation/release-notes/images/`.

(For versions before 11.2, the milestone had a slightly different format.)

Complete this step for xamarin-android, Java.Interop, and
xamarin-android-tools.
Complete this step for xamarin-android, Java.Interop, and android-tools.

See also the [_How to make bulk changes on pull requests and issues_][bulk-change]
section for tips on how to complete this step.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ class JavaInterop_External_Dependencies_Group : ThirdPartyNoticeGroup

class JavaInterop_xamarin_Java_Interop_TPN : ThirdPartyNotice
{
static readonly Uri url = new Uri ("https://github.com/xamarin/Java.Interop/");
static readonly Uri url = new Uri ("https://github.com/dotnet/java-interop/");
static readonly string licenseFile = Path.Combine (Configurables.Paths.ExternalJavaInteropDir, "LICENSE");

public override string LicenseFile => licenseFile;
public override string Name => "xamarin/Java.Interop";
public override string Name => "dotnet/java-interop";
public override Uri SourceUrl => url;
public override string LicenseText => String.Empty;
}
Expand Down Expand Up @@ -70,7 +70,7 @@ POSSIBILITY OF SUCH DAMAGE.
";
}

// via: https://github.com/xamarin/java.interop/blob/b588ef502d8d3b4c32e0ad731115e1b71fd56b5c/tools/java-source-utils/build.gradle#L33-L34
// via: https://github.com/dotnet/java-interop/blob/b588ef502d8d3b4c32e0ad731115e1b71fd56b5c/tools/java-source-utils/build.gradle#L33-L34
class JavaInterop_javaparser_javaparser_TPN : ThirdPartyNotice
{
static readonly Uri url = new Uri ("https://github.com/javaparser/javaparser/");
Expand Down
2 changes: 1 addition & 1 deletion src/Mono.Android/Mono.Android.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<ImplicitlyExpandDesignTimeFacades>false</ImplicitlyExpandDesignTimeFacades>
<JavaCallableWrapperAfterTargets>CoreBuild</JavaCallableWrapperAfterTargets>
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
<!-- @(Compile) ordering matters! See https://github.com/xamarin/java.interop/commit/d7dfa0bb7b03261d5eceb51ac22cd33aa15fa865 -->
<!-- @(Compile) ordering matters! See https://github.com/dotnet/java-interop/commit/d7dfa0bb7b03261d5eceb51ac22cd33aa15fa865 -->
<EnableDefaultCompileItems>false</EnableDefaultCompileItems>
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
<Nullable>enable</Nullable>
Expand Down
2 changes: 1 addition & 1 deletion src/Mono.Android/metadata
Original file line number Diff line number Diff line change
Expand Up @@ -1693,7 +1693,7 @@

<!-- If you try to implement ICursor in API-30+, we generate an invalid invoker for this method due to the
generic parameters. Since this is a default method we can just remove it until that bug is fixed.
https://github.com/xamarin/java.interop/issues/699 -->
https://github.com/dotnet/java-interop/issues/699 -->
<remove-node api-since="30" path="/api/package[@name='android.database']/interface[@name='Cursor']/method[@name='setNotificationUris' and count(parameter)=2 and parameter[1][@type='android.content.ContentResolver'] and parameter[2][@type='java.util.List&lt;android.net.Uri&gt;']]" />
<remove-node api-since="30" path="/api/package[@name='android.database']/interface[@name='Cursor']/method[@name='getNotificationUris']" />

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -333,7 +333,7 @@ public static bool TryGetMarshalMethod (this MethodDefinition method, string nat
return false;
}

// Keep in sync with: https://github.com/xamarin/java.interop/blob/8ccb8374d242490d8d1b032f2c8ca7a813fd40f3/src/Java.Interop.Export/Java.Interop/MarshalMemberBuilder.cs#L405-L421
// Keep in sync with: https://github.com/dotnet/java-interop/blob/8ccb8374d242490d8d1b032f2c8ca7a813fd40f3/src/Java.Interop.Export/Java.Interop/MarshalMemberBuilder.cs#L405-L421
public static string GetMarshalMethodName (string name, string signature)
{
if (name == null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ protected string CreateFauxJavaSdkDirectory (string path, string javaVersion, ou
return javaPath;
}

// https://github.com/xamarin/xamarin-android-tools/blob/683f37508b56c76c24b3287a5687743438625341/tests/Xamarin.Android.Tools.AndroidSdk-Tests/JdkInfoTests.cs#L60-L100
// https://github.com/dotnet/android-tools/blob/683f37508b56c76c24b3287a5687743438625341/tests/Xamarin.Android.Tools.AndroidSdk-Tests/JdkInfoTests.cs#L60-L100
void CreateFauxJdk (string dir, string releaseVersion, string releaseBuildNumber, string javaVersion, string[] extraPrefix)
{
Directory.CreateDirectory (dir);
Expand Down Expand Up @@ -321,7 +321,7 @@ void CreateFauxJdk (string dir, string releaseVersion, string releaseBuildNumber
CreateShellScript (Path.Combine (jre, "jvm.dll"), "");
}

// https://github.com/xamarin/xamarin-android-tools/blob/683f37508b56c76c24b3287a5687743438625341/tests/Xamarin.Android.Tools.AndroidSdk-Tests/JdkInfoTests.cs#L108-L132
// https://github.com/dotnet/android-tools/blob/683f37508b56c76c24b3287a5687743438625341/tests/Xamarin.Android.Tools.AndroidSdk-Tests/JdkInfoTests.cs#L108-L132
void CreateShellScript (string path, string contents)
{
if (IsWindows && string.Compare (Path.GetExtension (path), ".dll", StringComparison.OrdinalIgnoreCase) != 0)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!-- Android Sdk Tool versions are sourced from this file. This is maintained in the xamarin-android-tools repo. -->
<!-- Android Sdk Tool versions are sourced from this file. This is maintained in the android-tools repo. -->
<Import Project="$(MSBuildThisFileDirectory)\Xamarin.Android.Tools.Versions.props" />
<PropertyGroup>
<_JavaInteropReferences>Java.Interop;System.Runtime</_JavaInteropReferences>
Expand Down
2 changes: 1 addition & 1 deletion src/native/monodroid/internal-pinvoke-api.cc
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ monodroid_dylib_mono_free ([[maybe_unused]] void *mono_imports)

/*
this function is used from JavaInterop and should be treated as public API
https://github.com/xamarin/java.interop/blob/master/src/java-interop/java-interop-gc-bridge-mono.c#L266
https://github.com/dotnet/java-interop/blob/master/src/java-interop/java-interop-gc-bridge-mono.c#L266

it should also accept libmono_path = nullptr parameter
*/
Expand Down
2 changes: 1 addition & 1 deletion src/native/monodroid/pinvoke-override-api.cc
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ monodroid_dylib_mono_free ([[maybe_unused]] void *mono_imports)

/*
this function is used from JavaInterop and should be treated as public API
https://github.com/xamarin/java.interop/blob/master/src/java-interop/java-interop-gc-bridge-mono.c#L266
https://github.com/dotnet/java-interop/blob/master/src/java-interop/java-interop-gc-bridge-mono.c#L266

it should also accept libmono_path = nullptr parameter
*/
Expand Down