Comments (2)
This is the config I tried for creating a hello world application in Java
java_binary(
name = "main",
main_class = "Main",
deps = [":print"],
)
java_library(
name = "print",
srcs = ["Main.java"],
)
Using the latest version of buck2 ( Downloaded from https://github.com/facebook/buck2/releases/tag/latest ) This was updated like 14 hours back.
$ ./buck2-x86_64-apple-darwin build //:main
Getting the following error
buck2-x86_64-apple-darwin build //:main
File changed: prelude//toolchains/demo.bzl
Build ID: e40e9b95-b558-4faf-a75d-00db9f8cc0ab
Jobs completed: 4. Time elapsed: 0.1s.
BUILD FAILED
Error running analysis for `root//:main (prelude//platforms:default#f6691640831d48dd)`
Caused by:
0: Error looking up configured node root//:main (prelude//platforms:default#f6691640831d48dd)
1: Error looking up configured node toolchains//:java (prelude//platforms:default#f6691640831d48dd) (prelude//platforms:default#f6691640831d48dd)
2: looking up unconfigured target node `toolchains//:java`
3: Unknown target `java` from package `toolchains//`.
Did you mean one of the 9 targets in toolchains//:BUCK?
Maybe you meant one of these similar targets?
toolchains//:cxx
toolchains//:go
toolchains//:ocaml
toolchains//:rust
I was trying to look at the examples provided for cxx and implement the same for java. cxx works great for the example provided here https://github.com/facebook/buck2/blob/main/examples/hello_world/BUCK
It looks like it has rules in prelude folder, but no toolchain wrapper for java.
Was really hoping to get some guidance / pointer to create a wrapper for java. Hoping to send out a PR to buck2 so this would help out the buck2 community.
Thanks and looking forward to get some guidance on creating a toolchain/wrapper for java.
Kind regards,
Nag
from buck2.
CC @IanChilds @cjhopman who work on our Java version internally. My latest understanding is that we don't have things working externally with Java, as the toolchain requires pieces of Buck1 that, while open sourced, are basically impossible to use open source since they require careful compilation.
I wonder if we can possibly provide a binary of the Java pieces on the toolchain in the meantime to get people to experiment with open source?
from buck2.
Related Issues (20)
- Conflicting inputs on erlang build of Opentelemetry HOT 1
- error: Variable `typing` not found HOT 2
- Excluding rules from certain platforms HOT 6
- Unable to `buck2 clean` a repo which uses `git_fetch()` on Windows
- `configured_alias` and configuration modifiers HOT 2
- review Go analysis.Pass.Module proposal
- Creating symbolic links to toolchains HOT 10
- Early-building some parts of graph HOT 7
- How to use "buck2 clean" or other commands to delete only the generated files (cache) without killing the daemon? HOT 2
- Question: how to pass dependencies that change state forward across a non-output-changing rule HOT 4
- Share work across configurations by setting working directory for actions then canonicalizing that working directory in RE HOT 5
- How to use multiple execution platforms HOT 1
- Distributed project.ignore
- How to use c/aquery to find the dependents of an anon_target HOT 3
- Trouble linking Apple Frameworks HOT 1
- documentation mentions `frecli` which doesn't seem to be available publicly HOT 1
- Adding support for new languages HOT 5
- Java rules don't appear to be usable in OSS edition of buck2 HOT 2
- Builtin prelude support for running python in a venv?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from buck2.