All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Jose Quaresma" <quaresma.jose@gmail.com>
To: Richard Purdie <richard.purdie@linuxfoundation.org>
Cc: Alexander Kanavin <alex.kanavin@gmail.com>,
	Jate Sujjavanich <jatedev@gmail.com>,
	 OE-core <openembedded-core@lists.openembedded.org>
Subject: Re: [OE-core] [PATCH v2 2/2] iputils: Use STAGING_DIR_NATIVE for setcap detection
Date: Fri, 19 Feb 2021 11:26:06 +0000	[thread overview]
Message-ID: <CANPvuRkeiwD0ngL8Ang-v4X2iHUxU9aVK5feDGAQ3kYqST-hdA@mail.gmail.com> (raw)
In-Reply-To: <623d1b0df8dec2247f9d0c41ca8372cfb0af59e8.camel@linuxfoundation.org>

[-- Attachment #1: Type: text/plain, Size: 1731 bytes --]

Hi,

The only change needed on the recipe are:

-PACKAGECONFIG[libcap] = "-DUSE_CAP=true, -DUSE_CAP=false, libcap"
+PACKAGECONFIG[libcap] = "-DUSE_CAP=true, -DUSE_CAP=false, libcap
libcap-native"

The patch 0001-Add-support-for-setcap-in-STAGING_DIR_NATIVE.patch is not
need because
with the addition of the libcap-native the meson find_program will find
the setcap binary on the native sysroot
and will use it.


Richard Purdie <richard.purdie@linuxfoundation.org> escreveu no dia quinta,
18/02/2021 à(s) 21:44:

> On Thu, 2021-02-18 at 20:58 +0100, Alexander Kanavin wrote:
> > On Thu, 18 Feb 2021 at 20:22, Jate Sujjavanich <jatedev@gmail.com>
> wrote:
> > > +-setcap = find_program('setcap', '/usr/sbin/setcap', '/sbin/setcap',
> required : false)
> > > ++stagingdirnative = get_option('stagingdirnative')
> > > ++setcap = find_program(stagingdirnative + '/usr/sbin/setcap',
> stagingdirnative + '/sbin/setcap', required
> > > : false)
> > >
> >
> > Just remove the hardcoded paths from find_program altogether (see meson
> manual), and it will take the binary
> > from PATH env var, which is exactly how native sysroots are supposed to
> work.
>
> I'm guessing upstream does this so you can build as a normal user who
> doesn't have sbin in PATH and still use setcap during "make install".
>
> We need something upstream might accept. I suspect what we need here
> is a way to specify a specific path to the util and then fall back on
> the current approach if the feature is enabled but no path provided.
> Please do ensure that it won't look in the host's directories unless
> its enabled though.
>
> Cheers,
>
> Richard
>
>
> 
>
>

-- 
Best regards,

José Quaresma

[-- Attachment #2: Type: text/html, Size: 2849 bytes --]

  reply	other threads:[~2021-02-19 11:26 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-02-18 19:21 [PATCH v2 1/2] Revert "iputils: Fix build determinism" Jate Sujjavanich
2021-02-18 19:21 ` [PATCH v2 2/2] iputils: Use STAGING_DIR_NATIVE for setcap detection Jate Sujjavanich
2021-02-18 19:58   ` Alexander Kanavin
2021-02-18 21:44     ` Richard Purdie
2021-02-19 11:26       ` Jose Quaresma [this message]
2021-02-19 11:34         ` [OE-core] " Richard Purdie
2021-02-19 17:37           ` Jate Sujjavanich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CANPvuRkeiwD0ngL8Ang-v4X2iHUxU9aVK5feDGAQ3kYqST-hdA@mail.gmail.com \
    --to=quaresma.jose@gmail.com \
    --cc=alex.kanavin@gmail.com \
    --cc=jatedev@gmail.com \
    --cc=openembedded-core@lists.openembedded.org \
    --cc=richard.purdie@linuxfoundation.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.