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

Use non-ABI jars for kotlin compilation. #41

Merged
merged 4 commits into from
Nov 16, 2017
Merged

Use non-ABI jars for kotlin compilation. #41

merged 4 commits into from
Nov 16, 2017

Conversation

pcj
Copy link
Contributor

@pcj pcj commented Nov 15, 2017

Also adds two new kotlin_compile attributes:

  1. verbose: for printing debugging info
  2. args: for passing arbitrary args to compilation

Adds new test from @jmmk re: tornadofx

Fixes #40

Adds two new kotlin_compile attributes:
1. verbose: for printing debugging info
2. args: for passing arbitrary args to compilation

Adds new test from @jmmk re: tornadofx
@pcj
Copy link
Contributor Author

pcj commented Nov 15, 2017

@jmmk can you take a look at this PR and try it on your end?

git_repository(
    name = "org_pubref_rules_kotlin",
    remote = "https://github.com/pubref/rules_kotlin.git",
    commit = "4f780394cb3d4f1bb18b72179c1b2865e533c9bf", 
)

@pcj
Copy link
Contributor Author

pcj commented Nov 15, 2017

@iirina Can you check this? For kotlin compilation we need to assemble a list of jars to pass to kotlinc. I think I should probably be using the set of transitive full jars, is full_compile_jars the transitive set?

@jmmk
Copy link

jmmk commented Nov 15, 2017

@pcj Confirmed that using rules_kotlin on commit 4f780394cb3d4f1bb18b72179c1b2865e533c9bf (and adding "-jvm-target", "1.8", to compile_args) builds the tornadofx example.


However, I tested Jackson Kotlin module and it still failed. See gist here: https://gist.github.com/jmmk/842fac837b7af8ebefde85e476f9002d

@pcj
Copy link
Contributor Author

pcj commented Nov 15, 2017

Took a look at the gist and added a comment.

Slightly less naive attempt at excluding kotlin stdlib jars.
@pcj
Copy link
Contributor Author

pcj commented Nov 16, 2017

OK, I can't remember exactly why I was removing kotlin-stdlib.jar and kotlin-reflect.jar from classpath... Some experiment perhaps that I failed to remove.

@jmmk
Copy link

jmmk commented Nov 16, 2017

@pcj the Jackson example works after the latest commit

Drop support for bazel < 0.7.0 (now uses JavaInfo provider)
@pcj pcj merged commit 90ff07b into master Nov 16, 2017
@iirina
Copy link

iirina commented Nov 20, 2017

@pcj

For kotlin compilation we need to assemble a list of jars to pass to kotlinc. I think I should probably be using the set of transitive full jars, is full_compile_jars the transitive set?

full_compile_jars only gives you the direct jars, not the ones collected transitively. The transitive ones are not exposed right now on the provider, but they can be exposed easily if you need them.

@pcj
Copy link
Contributor Author

pcj commented Dec 8, 2017

@iirina Yes we do need the transitive jars exposed. See #47

@iirina
Copy link

iirina commented Dec 13, 2017

Can you open a GH issue on bazel and assign it to me please?

@pcj
Copy link
Contributor Author

pcj commented Dec 14, 2017

I created the issue bazelbuild/bazel#4297 (but do not have permission to make assignments).

Thanks!

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

Successfully merging this pull request may close these issues.

3 participants