[
https://issues.apache.org/jira/browse/ARROW-5135?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17662157#comment-17662157
]
Rok Mihevc commented on ARROW-5135:
-----------------------------------
This issue has been migrated to [issue
#21618|https://github.com/apache/arrow/issues/21618] on GitHub. Please see the
[migration documentation|https://github.com/apache/arrow/issues/14542] for
further details.
> [Rust] Generate flatbuffers code automatically
> ----------------------------------------------
>
> Key: ARROW-5135
> URL: https://issues.apache.org/jira/browse/ARROW-5135
> Project: Apache Arrow
> Issue Type: Improvement
> Components: Rust
> Reporter: Krisztian Szucs
> Priority: Major
> Labels: flatbuffers
>
> This depends on the following upstream flatbuffers issues:
> - https://github.com/google/flatbuffers/issues/5052
> - https://github.com/google/flatbuffers/issues/5053
> - https://github.com/google/flatbuffers/issues/5054
> Once they are resolved We should generate flatbuffers code automatically,
> as suggested by [~nevi_me]:
> {code}
> // [arrow/rust/arrow/build.rs]
> use std::path::Path;
> use flatc_rust;
> fn main() {
> flatc_rust::run(flatc_rust::Args {
> lang: "rust",
> inputs: &[
> Path::new("../../format/FIle.fbs"),
> Path::new("../../format/Message.fbs"),
> Path::new("../../format/Schema.fbs"),
> Path::new("../../format/Tensor.fbs"),
> Path::new("../../format/SparseTensor.fbs"),
> ],
> out_dir: Path::new("./src/ipc/gen/"),
> // doesn't seem to be honoured
> includes: &[Path::new("../../format/")],
> ..Default::default()
> }).expect("Unable to build flatbuffer files");
> }
> // [arrow/rust/arrow/Cargo.toml]
> [package]
> ...
> build = "build.rs"
> ...
> [build-dependencies]
> flatc-rust = "0.1"
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)