Re: [libgpiod][PATCH V9 0/8] libgpiod: Add Rust bindings

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Nov 17, 2022 at 10:56 AM Viresh Kumar <viresh.kumar@xxxxxxxxxx> wrote:
>
> On 17-11-22, 10:06, Bartosz Golaszewski wrote:
> > > File types:
> > > - Cargo.toml
> > >
> > >   Most of these have a different style for versioning, though the workspace
> > >   specific files doesn't have a version set. I checked few other projects and
> > >   they didn't mention it as well.
> > >
> >
> > Just use regular SPDX header at the top of the file in a # comment block?
>
> Miguel ? Kent ?
>
> > > - bindings.rs
> > >
> > >   These are automatically genrated files, with bindgen. Not sure if we should
> > >   edit them to add Licensing info.
> > >
> >
> > Can we not generate them at build-time then?
>
> We can, and we do when we do "cargo build --features=generate".
>
> There are reasons to keep them merged though. It lets the users avoid generating
> them on the go, like the vhost-device [1] crate in my case. I also faced issues
> with the rust-vmm containers, where vhost-device stuff gets auto-tested, in
> enabling bindgen support and finally went back to keeping them generated in
> advance. This is also the normal practice it seems, from whatever I have seen
> from the rust-vmm community at least.
>

Do these problems you faced apply to libgpiod too? Honestly, putting
automatically generated files in the repo just feels wrong. It defeats
the whole purpose of code generation. If we can't reliably regenerate
them, then it sounds like a problem with the tools, not the library.
Maybe we don't need to worry about that just yet?

Bart

> Maybe then add the header manually to them ?
>
> --
> viresh
>
> [1] https://github.com/rust-vmm/vhost-device



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux