[RFC PATCH v1] libcamera: virtual: Install configuration file
Laurent Pinchart
laurent.pinchart at ideasonboard.com
Fri Dec 20 10:44:46 CET 2024
On Fri, Dec 20, 2024 at 09:41:11AM +0000, Barnabás Pőcze wrote:
> 2024. december 20., péntek 0:27 keltezéssel, Laurent Pinchart írta:
> > On Thu, Dec 19, 2024 at 12:37:24PM +0000, Barnabás Pőcze wrote:
> > > Install the example configuration file of the virtual pipeline
> > > handler as it serves documentation purposes, and to make the
> > > virtual pipeline handler easily usable in CI.
> > >
> > > Nonetheless, the file is installed with the ".example" suffix
> > > so that it will not be used by default, to avoid cluttering
> > > the camera lists of users whose distributions decide to
> > > enable the virtual pipeline handler.
> > >
> > > Signed-off-by: Barnabás Pőcze <pobrn at protonmail.com>
> > > ---
> > > src/libcamera/pipeline/virtual/data/meson.build | 4 ++++
> > > src/libcamera/pipeline/virtual/meson.build | 2 ++
> > > 2 files changed, 6 insertions(+)
> > > create mode 100644 src/libcamera/pipeline/virtual/data/meson.build
> > >
> > > diff --git a/src/libcamera/pipeline/virtual/data/meson.build b/src/libcamera/pipeline/virtual/data/meson.build
> > > new file mode 100644
> > > index 000000000..ce63f9a27
> > > --- /dev/null
> > > +++ b/src/libcamera/pipeline/virtual/data/meson.build
> > > @@ -0,0 +1,4 @@
> > > +install_data('virtual.yaml',
> > > + install_dir : pipeline_data_dir / 'virtual',
> > > + install_tag : 'runtime',
> > > + rename: 'virtual.yaml.example')
> >
> > I'm no specialist when it comes to file system layouts, but it seems to
> > be a common practice for example files to be installed in
> > /usr/share/doc/$pkgname/. Some software seem to use user locations
> > though. What that be a better target directory ? I'm not entirely sure
> > myself.
> > [...]
>
> I can find examples of both on my machine, and I did consider that, but during the
> implementation I came to the conclusion that this is a better choice:
>
> * the documentation directory has the libcamera version number, so it is a bit more
> inconvenient to address it in the CI;
> * it is easier and more convenient if the file is already where it is supposed to be.
>
> So my preference would be installing it into the proper configuration file directory
> with the `runtime` installation tag.
Capturing that rationale in the commit message would be nice.
Reviewed-by: Laurent Pinchart <laurent.pinchart at ideasonboard.com>
--
Regards,
Laurent Pinchart
More information about the libcamera-devel
mailing list