diff mbox series

[meta-gnome,3/3] gvfs: use native ssh client

Message ID 20221201134148.116754-4-alex.stewart@ni.com
State Under Review
Headers show
Series gvfs: use native ssh client | expand

Commit Message

Alex Stewart Dec. 1, 2022, 1:41 p.m. UTC
When the `sftp` option is enabled in gvfs, meson tries to find a valid
`ssh` binary in the build host's PATH during do_configure. If a -native
implementation is not found, meson will try to satisfy the binary using
the build machine's hosttools directly - which is generally undesirable.

DEPEND on openssh-native, so that an ssh client implementation is always
in the PATH during configuration.

Signed-off-by: Alex Stewart <alex.stewart@ni.com>
---
 meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb | 1 +
 1 file changed, 1 insertion(+)

Comments

Mikko Rapeli Dec. 1, 2022, 1:59 p.m. UTC | #1
Hi,

On Thu, Dec 01, 2022 at 07:41:48AM -0600, Alex Stewart wrote:
> When the `sftp` option is enabled in gvfs, meson tries to find a valid
> `ssh` binary in the build host's PATH during do_configure. If a -native
> implementation is not found, meson will try to satisfy the binary using
> the build machine's hosttools directly - which is generally undesirable.
> 
> DEPEND on openssh-native, so that an ssh client implementation is always
> in the PATH during configuration.

This sounds wrong. Why doesn't meson look into the sysroot and add the
dependency to target "openssh" (or "virtual/ssh-client")?

If the path to the binary will be hard coded, then that needs to be
fixed to be the path in expected target system rootfs.

Cheers,

-Mikko

> Signed-off-by: Alex Stewart <alex.stewart@ni.com>
> ---
>  meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb b/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
> index 4c251d2f4..9e29afd48 100644
> --- a/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
> +++ b/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
> @@ -12,6 +12,7 @@ DEPENDS += "\
>      gsettings-desktop-schemas \
>      libgudev \
>      libsecret \
> +    openssh-native \
>      shadow-native \
>  "
>  
> -- 
> 2.38.1
> 

> 
> -=-=-=-=-=-=-=-=-=-=-=-
> Links: You receive all messages sent to this group.
> View/Reply Online (#99888): https://lists.openembedded.org/g/openembedded-devel/message/99888
> Mute This Topic: https://lists.openembedded.org/mt/95382229/7159507
> Group Owner: openembedded-devel+owner@lists.openembedded.org
> Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [mikko.rapeli@linaro.org]
> -=-=-=-=-=-=-=-=-=-=-=-
>
Alex Stewart Dec. 1, 2022, 2:29 p.m. UTC | #2
On 12/1/22 07:59, Mikko Rapeli wrote:
> Hi,
>
> On Thu, Dec 01, 2022 at 07:41:48AM -0600, Alex Stewart wrote:
>> When the `sftp` option is enabled in gvfs, meson tries to find a valid
>> `ssh` binary in the build host's PATH during do_configure. If a -native
>> implementation is not found, meson will try to satisfy the binary using
>> the build machine's hosttools directly - which is generally undesirable.
>>
>> DEPEND on openssh-native, so that an ssh client implementation is always
>> in the PATH during configuration.
> This sounds wrong. Why doesn't meson look into the sysroot and add the
> dependency to target "openssh" (or "virtual/ssh-client")?
>
> If the path to the binary will be hard coded, then that needs to be
> fixed to be the path in expected target system rootfs.

I guessed it might have something to do with `ssh` not being defined 
within this `meson.cross` binaries list (or maybe the .native version) 
[1]. I tried adding it, along with a DEPENDS on openssh, but that didn't 
seem to work either.

I'm not very familiar with meson configurations. If you have some 
guidance on a better design, I'd be happy to give it a shot.

[1] 
https://git.openembedded.org/openembedded-core/tree/meta/classes-recipe/meson.bbclass#n65

>
> Cheers,
>
> -Mikko
>
>> Signed-off-by: Alex Stewart <alex.stewart@ni.com>
>> ---
>>   meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb | 1 +
>>   1 file changed, 1 insertion(+)
>>
>> diff --git a/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb b/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
>> index 4c251d2f4..9e29afd48 100644
>> --- a/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
>> +++ b/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
>> @@ -12,6 +12,7 @@ DEPENDS += "\
>>       gsettings-desktop-schemas \
>>       libgudev \
>>       libsecret \
>> +    openssh-native \
>>       shadow-native \
>>   "
>>   
>> -- 
>> 2.38.1
>>
diff mbox series

Patch

diff --git a/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb b/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
index 4c251d2f4..9e29afd48 100644
--- a/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
+++ b/meta-gnome/recipes-gnome/gvfs/gvfs_1.50.2.bb
@@ -12,6 +12,7 @@  DEPENDS += "\
     gsettings-desktop-schemas \
     libgudev \
     libsecret \
+    openssh-native \
     shadow-native \
 "