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

Enable Source Link for MavenReference #54

Open
wasabii opened this issue Feb 15, 2024 · 2 comments
Open

Enable Source Link for MavenReference #54

wasabii opened this issue Feb 15, 2024 · 2 comments

Comments

@wasabii
Copy link
Collaborator

wasabii commented Feb 15, 2024

Should build on ikvmnet/ikvm#490

We feed source information derived from Maven into IkvmReference. Maven companion source files may be available for packages. Or there may be other standard Maven ways to point to the original repository.

@Martin1994
Copy link

I think we either need to embed sources, or ask for a new input parameter containing git commit information.

Source Link is a reference to a URL on HTTP. Maven provides sources with source jars so there is no direct URL to each individual source files. Maven also does not provide commit information AFAIK so we can't infer a GitHub source content URL either.

@wasabii
Copy link
Collaborator Author

wasabii commented Feb 26, 2024

SourceLink actually provides a number of different possibilities: https://github.com/dotnet/designs/blob/62d47b661537ed94fcbfe4909e11b5168ef669ef/accepted/2020/diagnostics/source-link.md

The /sourcelink: compiler flag will embed a JSON configuration file in the PDB.

So, for that one, we'd need to add a new flag to ikvmc which does the same.

And then there are two flows for running ikvmc as part of the build process:

  1. IKVM.NET.Sdk, the SDK tooling that builds IKVM.Java itself, and which users can use to make Java-language projects.
  2. IkvmReference

The first should capitalize on the existing SourceLink support in the mIcrosoft.net.sdk. But support converted/merged Archives as well as raw Java files. The second needs to be thought through.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants