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

Fix jvm_flag support #93

Merged
merged 2 commits into from
Sep 13, 2016
Merged

Fix jvm_flag support #93

merged 2 commits into from
Sep 13, 2016

Conversation

johnynek
Copy link
Member

bazel java binary targets have certain options:

https://github.com/bazelbuild/bazel/blob/c1b417549cf4ba719662f7562e99e807c606eae7/src/main/java/com/google/devtools/build/lib/bazel/rules/java/java_stub_template.txt

use:

# --jvm_flag=<flag>     Pass <flag> to the "java" command itself.
#                       <flag> may contain spaces. Can be used multiple times.

to set the jvm flags.

@bazel-io
Copy link
Member

Can one of the admins verify this patch?

@@ -174,7 +174,7 @@ SourceJars: {srcjars}
javac_opts=" ".join(ctx.attr.javacopts),
javac_path=ctx.file._javac.path,
java_files=",".join([f.path for f in java_srcs]),
jvm_flags=" ".join(["-J" + flag for flag in ctx.attr.jvm_flags]),
jvm_flags=" ".join(ctx.attr.jvm_flags),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you need the -J still here, these are for java

@ianoc
Copy link
Contributor

ianoc commented Sep 13, 2016

LGTM

@johnynek johnynek merged commit a314894 into master Sep 13, 2016
petemounce pushed a commit to improbable-io/rules_scala that referenced this pull request Oct 20, 2016
* upstream/master:
  use strings rather than HOST/DATA_CFG
  Add cfg attribute on executable labels
  Switch to using shorter stack traces.
  Catch throwables from type errors
  make thrift targets quieter (bazelbuild#94)
  Fix jvm_flag support (bazelbuild#93)
  Make compile timing optional, with default false
  Update README.md
  Persistent/worker scala compiler (bazelbuild#91)
  fix typo in README.md (bazelbuild#89)
  Fix for thrift rule issue that manifests with remote repos (bazelbuild#83)
  improve the deploy jar creation (bazelbuild#85)
  Use bind's for twitter scrooge so local repo's can override scrooge and thrift versions (bazelbuild#84)
@ittaiz ittaiz deleted the oscar/jvm_opts branch May 16, 2017 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants