[glib-networking/wip/nacho/openssl: 20/21] fixup! Add back CA certificate configuration



commit 5eda3c85a2b76e8dc380d1efd538ca75a1163580
Author: Ignacio Casal Quinteiro <icq gnome org>
Date:   Tue Sep 18 15:11:11 2018 +0200

    fixup! Add back CA certificate configuration

 meson.build | 36 ++++++++++++++++++------------------
 1 file changed, 18 insertions(+), 18 deletions(-)
---
diff --git a/meson.build b/meson.build
index 9b46ae3..b6cf220 100644
--- a/meson.build
+++ b/meson.build
@@ -133,28 +133,28 @@ elif cc.get_id() == 'msvc'
     openssl_dep = [libeay_dep, ssleay_dep]
   endif
 
-  if host_machine.system() != 'windows'
-    ca_certificates = get_option('ca_certificates')
-    if ca_certificates == 'no'
-      message('CA certificates disabled')
-    else
-      if ca_certificates == ''
-        detect_certificates = run_command(join_paths(meson.source_root(), 'detect_certificates.py'))
-
-        if detect_certificates.returncode() == 1
-          error('Could not find certificates. Use -Dca_certificates=path to set, or -Dca_certificates=no to 
disable it')
-        endif
-
-        ca_certificates = detect_certificates.stdout().strip()
-      endif
+  backends += ['openssl']
+endif
+
+if backends.contains('openssl') and host_machine.system() != 'windows'
+  ca_certificates = get_option('ca_certificates')
+  if ca_certificates == 'no'
+    message('CA certificates disabled')
+  else
+    if ca_certificates == ''
+      detect_certificates = run_command(join_paths(meson.source_root(), 'detect_certificates.py'))
 
-      message('CA certificates: ' + ca_certificates)
+      if detect_certificates.returncode() == 1
+        error('Could not find certificates. Use -Dca_certificates=path to set, or -Dca_certificates=no to 
disable it')
+      endif
 
-      config_h.set_quoted('GTLS_SYSTEM_CA_FILE', ca_certificates)
+      ca_certificates = detect_certificates.stdout().strip()
     endif
-  endif
 
-  backends += ['openssl']
+    message('CA certificates: ' + ca_certificates)
+
+    config_h.set_quoted('GTLS_SYSTEM_CA_FILE', ca_certificates)
+  endif
 endif
 
 if backends.length() == 0


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]