Sunday, August 20, 2017

Re: has anyone tried building a gwt application using buck ?


On Sunday, August 20, 2017 at 6:19:47 AM UTC+2, Debasish Padhy wrote:
any  advantages vs. troubles summary ?

any links to guides for setting up ?

Even though this is not documented on buckbuild.com, Buck has built-in support for GWT with the gwt_binary rule.
You can find an example in the integration tests: https://github.com/facebook/buck/blob/v2017.05.31.01/test/com/facebook/buck/gwt/testdata/gwt_binary/BUCK.fixture
And the rule arguments and their default value in the code: https://github.com/facebook/buck/blob/v2017.05.31.01/src/com/facebook/buck/gwt/GwtBinaryDescription.java, that is:
  • deps needs to list gwt-dev (and all its transitive dependencies, if downloaded from Central with a remote_file rule and a "mvn:" URL; in the test they use a fat-jar gwt-dev.jar, from the GWT SDK, that's directly checked into the repo, you could also achieve something similar with a remote_file with type='exploded_zip' and simple genrule()s that 'cp $(location …) $OUT').
  • module_deps lists java_library rules, and should transitively enclose gwt-user.
  • modules is a list of GWT module names to compile, as you would pass them as arguments to the GWT compiler.
  • local_workers defaults to 2
  • style defaults to 'OBF'
  • strict defaults to False (I recommend setting it to True)

Gerrit was built with Buck for a few years (they now switched to Bazel, though maintenance branches might still be using Buck).
I'm not sure they used Buck's built-in GWT support though, as they started using Buck before it gained support for GWT.

I never actually used Buck, so can't comment about the pros and cons. Apparently there's no support for running SuperDevMode so you'd have to configure it separately, and most probably outside of Buck)

--
You received this message because you are subscribed to the Google Groups "GWT Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscribe@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at https://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment