[oe] [PATCH] opencl-headers: Initial recipe for OpenCL headers

Ankit Navik ankit.tarot at gmail.com
Tue Oct 16 04:40:11 UTC 2018


Hi Ross,
On Tue, Oct 16, 2018 at 12:37 AM Burton, Ross <ross.burton at intel.com> wrote:
>
> On Mon, 15 Oct 2018 at 20:01, Denys Dmytriyenko <denis at denix.org> wrote:
> > > > > > > > > > +do_install () {
> > > > > > > > > > +     install -d ${D}${includedir}/CL/
> > > > > > > > > > +     for f in ${S}/CL/*.h; do
> > > > > > > > > > +             install -m 0644 $f ${D}${includedir}/CL/
> > > > > >
> > > > > > Single file install? Not very optimized...
> > > >
> > > > > Its not a single file, Installing all the header files.
> > > >
> > > > It's a single file install in a for loop, hence my comment about being
> > > > unoptimal. Why not use "cp *.h"?
> > >
> > >  I agree its suboptimal use here. May be
> > >
> > > install [OPTION]... -t DIRECTORY SOURCE
> > >
> > > could be tamed to make it better.
> > > however cp messes the file permissions up if not used with right opts.
> > > So I would not prefer it unless used with right
> > > options to respect the file perms. Install does it correctly,
> >
> > Agree, cp would require passing correct options, but there are plenty of
> > examples alreay.
>
> If we're bikeshedding a micro-optimisation then surely this is optimal:
>
>   install -m 0644 -D -t ${D}${includedir}/CL ${S}/CL/*.h
>
> That combines the mkdir and cp in one command.
Thank you for your suggestion, but this one line command still throws
error of No such file or directory.
Following line will solve:
install -d ${D}${includedir}/CL/
install -m 0644 -t ${D}${includedir}/CL ${S}/CL/*.h

I'll send this patch in v3.

Regards, Ankit
>
> Ross
> --
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel at lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-devel



More information about the Openembedded-devel mailing list