search for: cargo

Displaying 20 results from an estimated 193 matches for "cargo".

2020 Jun 17
2
Re: nbdkit rust plugin: copyright notices, Cargo workspace, and macro hygiene
...@redhat.com> wrote: > I pushed 2 & 3, thanks. > > But ... > > > From 9fa3e443467e3c06761ec54241327e8daf8701ca Mon Sep 17 00:00:00 2001 > > From: Alan Somers <asomers@gmail.com> > > Date: Mon, 15 Jun 2020 16:59:53 -0600 > > Subject: [PATCH 1/3] Add a Cargo.toml file to the top-level directory > > > > This is necessary for other Rust projects to depend on unrelesed > > versions of the nbdkit crate. > > --- > > Cargo.toml | 2 ++ > > 1 file changed, 2 insertions(+) > > create mode 100644 Cargo.toml > >...
2020 Jun 16
4
nbdkit rust plugin: copyright notices, Cargo workspace, and macro hygiene
2019 Jul 05
3
Re: [PATCH] Add Rust bindings
> Have you decided whether we need to commit the generated files > (Cargo.toml, Cargo.lock)? It looks like in this series those files > are still included and not added to .gitignore. I'm sorry I forgot adding Cargo.lock to .gitignore. I'll add it to .gitignore. However, I think Cargo.toml should be staged. This is because this is a file managed by hands. It...
2020 Jun 17
0
Re: nbdkit rust plugin: copyright notices, Cargo workspace, and macro hygiene
...ed 2 & 3, thanks. > > > > But ... > > > > > From 9fa3e443467e3c06761ec54241327e8daf8701ca Mon Sep 17 00:00:00 2001 > > > From: Alan Somers <asomers@gmail.com> > > > Date: Mon, 15 Jun 2020 16:59:53 -0600 > > > Subject: [PATCH 1/3] Add a Cargo.toml file to the top-level directory > > > > > > This is necessary for other Rust projects to depend on unrelesed > > > versions of the nbdkit crate. > > > --- > > > Cargo.toml | 2 ++ > > > 1 file changed, 2 insertions(+) > > > creat...
2019 Jul 06
3
Re: [PATCH] Add Rust bindings
On Fri, Jul 05, 2019 at 08:37:20AM +0100, Richard W.M. Jones wrote: >On Fri, Jul 05, 2019 at 01:28:12PM +0900, Hiroyuki Katsura wrote: >> > Have you decided whether we need to commit the generated files >> > (Cargo.toml, Cargo.lock)? It looks like in this series those files >> > are still included and not added to .gitignore. >> >> I'm sorry I forgot adding Cargo.lock to .gitignore. I'll add it to >> .gitignore. However, I think Cargo.toml should be staged. This is because...
2019 Jun 27
2
Re: [PATCH 3/9] Rust bindings: Add 4 bindings tests
On Thu, Jun 27, 2019 at 05:06:04PM +0900, Hiroyuki Katsura wrote: > From: Hiroyuki_Katsura <hiroyuki.katsura.0513@gmail.com> > > --- > generator/rust.ml | 13 ++++++++--- > run.in | 9 ++++++++ > rust/Cargo.lock | 6 +++++ > rust/Cargo.toml | 4 +--- > rust/tests/010_load.rs | 24 +++++++++++++++++++ > rust/tests/020_create.rs | 24 +++++++++++++++++++ > rust/tests/030_create_flags.rs | 30 ++++++++++++++++++++++++ > rust/test...
2019 Jun 27
1
Re: [PATCH 3/9] Rust bindings: Add 4 bindings tests
On Thu, Jun 27, 2019 at 06:27:05PM +0900, Hiroyuki Katsura wrote: > > I guess this is a stray debug message? > > Yes. I'm sorry... > > > we did *not* check them into git. > > Really? Does it mean that every time you build the library, Cargo.toml is > generated? That's how it has worked in nbdkit. Whether it's right or not I don't know. Normally we wouldn't check generated files into git. > > The actual test parts of this patch are fine, but you need to spend a > > bit of time with ‘git rebase -i’ to...
2020 Jun 17
0
Re: nbdkit rust plugin: copyright notices, Cargo workspace, and macro hygiene
I pushed 2 & 3, thanks. But ... > From 9fa3e443467e3c06761ec54241327e8daf8701ca Mon Sep 17 00:00:00 2001 > From: Alan Somers <asomers@gmail.com> > Date: Mon, 15 Jun 2020 16:59:53 -0600 > Subject: [PATCH 1/3] Add a Cargo.toml file to the top-level directory > > This is necessary for other Rust projects to depend on unrelesed > versions of the nbdkit crate. > --- > Cargo.toml | 2 ++ > 1 file changed, 2 insertions(+) > create mode 100644 Cargo.toml > > diff --git a/Cargo.toml b/Cargo.t...
2019 Aug 31
1
[PATCH libnbd] Add bindings for Rust language
Still not working, but I took the latest patch and: - rebased it against libnbd 1.0 - fixed it so it handles new args and cbargs The generator now runs without warnings. This patch doesn't handle optargs at all. In C these are converted to non-optional parameter. Rust doesn't (AFAIK) have optional or labelled arguments unfortunately. Rich.
2019 Jul 07
2
[libnbd PATCH] RFC: Add bindings for Rust language
...is generated is also not nice, I wish there was more code actually written in some files and not generated by the generator (as much hard-coded static strings as possible), maybe similarly to the states.c, I don't know. It follows the convention of `-sys` packages: https://doc.rust-lang.org/cargo/reference/build-scripts.html#a-sys-packages But that's about it, I hadn't really had much more time to do anything, I had only limited free time during the weekend to push this as far as possible and I got stuck couple of times. But I think the hardest parts are solved and Also up for di...
2019 Jun 27
0
Re: [PATCH 3/9] Rust bindings: Add 4 bindings tests
> I guess this is a stray debug message? Yes. I'm sorry... > we did *not* check them into git. Really? Does it mean that every time you build the library, Cargo.toml is generated? > The actual test parts of this patch are fine, but you need to spend a > bit of time with ‘git rebase -i’ to move parts of patch 3 into patch 2. Does this mean that the followings should be moved to patch 2? generator/rust.ml | 13 ++++++++--- run.in...
2019 Aug 11
0
[PATCH 2/2] Rust bindings: Make it able to publish this crate
I added - data required to publish this crate to `crates.io`. - README.md which contains the details of how to publish this crate. --- rust/Cargo.toml.in | 5 ++++- rust/README.md | 42 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 rust/README.md diff --git a/rust/Cargo.toml.in b/rust/Cargo.toml.in index b61e3ec7f..d217a530e 100644 --- a/rust/Cargo.toml.in +++ b/rust/Car...
2019 Aug 11
5
[PATCH 1/2] Rust bindings: Add long description
`cargo doc` will generate docs with long descriptions. I did not add the settings of outputting these docs to `/website`. This is because - by publishing this crate to crates.io, users can see the docs in `docs.rs` like `https://docs.rs/guestfs/<version>/guestfs/`. It is easy to hold multiple do...
2019 Feb 08
3
[PATCH nbdkit] Add support for writing plugins in Rust.
This adds very rough support for writing nbdkit plugins in Rust. This is not very idiomatic -- essentially we're handling the direct C calls from nbdkit in Rust. We have to use ‘unsafe’ in a few places because there's no way to tell the Rust code that nbdkit satisfies guarantees (eg. around thread safety, always returning leaked pointers back to the close function, always doing bounds
2019 Feb 08
1
Re: [PATCH nbdkit] Add support for writing plugins in Rust.
...ocaml" != "xno"],[ > AM_CONDITIONAL([HAVE_OCAML],[test "x$OCAMLOPT" != "xno" && > test "x$ocaml_link_shared" = "xyes"]) > > +dnl For developing plugins in Rust, optional. > +AC_CHECK_PROG([CARGO],[cargo],[cargo],[no]) > +AC_ARG_ENABLE([rust], > + [AS_HELP_STRING([--disable-rust], [disable Rust plugin])], > + [], > + [enable_rust=yes]) > +AM_CONDITIONAL([HAVE_RUST], > + [test "x$CARGO" != "xno" && test "x$enable_ruby&...
2019 Jul 03
1
Re: [PATCH 01/12] Rust bindings: Add Rust bindings
...or/bindtests.ml | 3 +++ > generator/bindtests.mli | 1 + > generator/main.ml | 5 +++++ > generator/rust.ml | 34 ++++++++++++++++++++++++++++++++++ > generator/rust.mli | 19 +++++++++++++++++++ > m4/guestfs-rust.m4 | 30 ++++++++++++++++++++++++++++++ > rust/Cargo.toml | 6 ++++++ > rust/Makefile.am | 29 +++++++++++++++++++++++++++++ > rust/src/.gitkeep | 0 > rust/tests/.gitkeep | 0 > 13 files changed, 137 insertions(+) > create mode 100644 generator/rust.ml > create mode 100644 generator/rust.mli > create mode...
2019 Jun 27
0
[PATCH 3/9] Rust bindings: Add 4 bindings tests
From: Hiroyuki_Katsura <hiroyuki.katsura.0513@gmail.com> --- generator/rust.ml | 13 ++++++++--- run.in | 9 ++++++++ rust/Cargo.lock | 6 +++++ rust/Cargo.toml | 4 +--- rust/tests/010_load.rs | 24 +++++++++++++++++++ rust/tests/020_create.rs | 24 +++++++++++++++++++ rust/tests/030_create_flags.rs | 30 ++++++++++++++++++++++++ rust/tests/040_create_multiple.rs...
2023 Aug 20
1
[libnbd PATCH v8 04/10] rust: Make it possible to run examples with a URI
...ons(+), 9 deletions(-) diff --git a/rust/examples/fetch-first-sector.rs b/rust/examples/fetch-first-sector.rs index 9efb47a..b035ccb 100644 --- a/rust/examples/fetch-first-sector.rs +++ b/rust/examples/fetch-first-sector.rs @@ -7,6 +7,9 @@ //! //! nbdkit -U - floppy . \ //! --run 'cargo run --example fetch-first-sector -- $unixsocket' +//! Or with a URI: +//! nbdkit -U - floppy . \ +//! --run 'cargo run --example fetch-first-sector -- $uri' //! //! The nbdkit floppy plugin creates an MBR disk so the //! first sector is the partition table. @@ -21,11 +24,15...
2019 Feb 08
0
[PATCH nbdkit] Add support for writing plugins in Rust.
--- .gitignore | 3 + README | 4 +- TODO | 13 +++ configure.ac | 12 +++ docs/nbdkit-plugin.pod | 6 +- docs/nbdkit.pod | 1 + plugins/rust/Cargo.toml.in | 14 +++ plugins/rust/Makefile.am | 65 ++++++++++++ plugins/rust/examples/ramdisk.rs | 119 +++++++++++++++++++++ plugins/rust/nbdkit-rust-plugin.pod | 99 ++++++++++++++++++ plugins/rust/src/lib.rs | 155 ++++++++++++++++++++++++++++ 11 files changed...
2020 Jun 17
2
Re: nbdkit rust plugin: copyright notices, Cargo workspace, and macro hygiene
...ichard W.M. Jones wrote: > I pushed 2 & 3, thanks. > > But ... > >> From 9fa3e443467e3c06761ec54241327e8daf8701ca Mon Sep 17 00:00:00 2001 >> From: Alan Somers <asomers@gmail.com> >> Date: Mon, 15 Jun 2020 16:59:53 -0600 >> Subject: [PATCH 1/3] Add a Cargo.toml file to the top-level directory >> >> This is necessary for other Rust projects to depend on unrelesed unreleased >> versions of the nbdkit crate. As a meta-comment, it's easier to review patches sent inline, one patch per email, rather than multiple patches as opaque...