All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] meson: make https:// wrap source downloads work
@ 2021-11-06  9:47 Leif Middelschulte
  2021-11-06 10:07 ` [poky] " Richard Purdie
  0 siblings, 1 reply; 4+ messages in thread
From: Leif Middelschulte @ 2021-11-06  9:47 UTC (permalink / raw)
  To: poky; +Cc: Leif Middelschulte

Meson would fail to fetch wraps' sources on bare systems (i.e. docker images),
that only provide little more than the SDK.

The SDK's SSL directory was not searched, so meson would fail when it tried
to fetch sources via https, that were specified in wrap files.
Specifically `urllib` would fail:
```
<urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1129)>
```

Caution: this patch depends on the underlying C library (i.e. openssl)
to consider this environment variable.

Signed-off-by: Leif Middelschulte <Leif.Middelschulte@klsmartin.com>
---
meta/recipes-devtools/meson/meson/meson-wrapper | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/meta/recipes-devtools/meson/meson/meson-wrapper b/meta/recipes-devtools/meson/meson/meson-wrapper
index d4b5187f8d..8fafaad975 100755
--- a/meta/recipes-devtools/meson/meson/meson-wrapper
+++ b/meta/recipes-devtools/meson/meson/meson-wrapper
@@ -4,6 +4,10 @@ if [ -z "$OECORE_NATIVE_SYSROOT" ]; then
    echo "OECORE_NATIVE_SYSROOT not set; are you in a Yocto SDK environment?" >&2
fi

+if [ -z "$SSL_CERT_DIR" ]; then
+    export SSL_CERT_DIR="${OECORE_NATIVE_SYSROOT}/etc/ssl/certs/"
+fi
+
# If these are set to a cross-compile path, meson will get confused and try to
# use them as native tools. Unset them to prevent this, as all the cross-compile
# config is already in meson.cross.
-- 
2.33.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-11-07  8:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-06  9:47 [PATCH] meson: make https:// wrap source downloads work Leif Middelschulte
2021-11-06 10:07 ` [poky] " Richard Purdie
2021-11-06 10:13   ` Leif Middelschulte
2021-11-07  8:53     ` Richard Purdie

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.