[Spice-devel,[PATCH,spice-common] 2/2] Add check for openssl

Submitted by Eduardo Lima (Etrunko) on March 28, 2016, 9 p.m.

Details

Message ID 1459198828-7986-3-git-send-email-etrunko@redhat.com
State New
Headers show

Not browsing as part of any series.

Patch hide | download patch | download mbox

diff --git a/configure.ac b/configure.ac
index bfdf869..1064bd6 100644
--- a/configure.ac
+++ b/configure.ac
@@ -38,9 +38,10 @@  SPICE_CHECK_CELT051
 SPICE_CHECK_GLIB2(2.38)
 SPICE_CHECK_OPUS
 SPICE_CHECK_OPENGL
+SPICE_CHECK_OPENSSL
 
-SPICE_COMMON_CFLAGS='$(PIXMAN_CFLAGS) $(SMARTCARD_CFLAGS) $(CELT051_CFLAGS) $(GLIB2_CFLAGS) $(OPUS_CFLAGS) $(GL_CFLAGS)'
-SPICE_COMMON_LIBS='$(PIXMAN_LIBS) $(CELT051_LIBS) $(GLIB2_LIBS) $(OPUS_LIBS) $(GL_LIBS)'
+SPICE_COMMON_CFLAGS='$(PIXMAN_CFLAGS) $(SMARTCARD_CFLAGS) $(CELT051_CFLAGS) $(GLIB2_CFLAGS) $(OPUS_CFLAGS) $(GL_CFLAGS) $(OPENSSL_CFLAGS)'
+SPICE_COMMON_LIBS='$(PIXMAN_LIBS) $(CELT051_LIBS) $(GLIB2_LIBS) $(OPUS_LIBS) $(GL_LIBS) $(OPENSSL_LIBS)'
 AC_SUBST(SPICE_COMMON_CFLAGS)
 AC_SUBST(SPICE_COMMON_LIBS)
 
diff --git a/m4/spice-deps.m4 b/m4/spice-deps.m4
index ecae80a..fe70900 100644
--- a/m4/spice-deps.m4
+++ b/m4/spice-deps.m4
@@ -302,3 +302,12 @@  AC_DEFUN([SPICE_CHECK_SASL], [
       fi
     fi
 ])
+
+# SPICE_CHECK_OPENSSL
+# -----------------
+# Check for the availability of openssl. If found, it will return the flags to
+# use in the OPENSSL_CFLAGS and OPENSSL_LIBS variables.
+#------------------
+AC_DEFUN([SPICE_CHECK_OPENSSL], [
+    PKG_CHECK_MODULES(OPENSSL, openssl)
+])

Comments

On Mon, Mar 28, 2016 at 06:00:28PM -0300, Eduardo Lima (Etrunko) wrote:
> From: "Eduardo Lima (Etrunko)" <etrunko@redhat.com>
> 
> It is required to compile ssl-verify.[ch].

Makes sense. Any idea why it could be built without issues so far? Did
you hit some compilation problems which led to this patch?

Acked-by: Christophe Fergeau <cfergeau@redhat.com>

Christophe
On 03/29/2016 05:24 AM, Christophe Fergeau wrote:
> On Mon, Mar 28, 2016 at 06:00:28PM -0300, Eduardo Lima (Etrunko) wrote:
>> From: "Eduardo Lima (Etrunko)" <etrunko@redhat.com>
>>
>> It is required to compile ssl-verify.[ch].
> 
> Makes sense. Any idea why it could be built without issues so far? Did
> you hit some compilation problems which led to this patch?
> 

Yes, the build failed when I tried building spice-common alone in a
fresh RHEL7 install.
On Tue, Mar 29, 2016 at 10:24:53AM +0200, Christophe Fergeau wrote:
> On Mon, Mar 28, 2016 at 06:00:28PM -0300, Eduardo Lima (Etrunko) wrote:
> > From: "Eduardo Lima (Etrunko)" <etrunko@redhat.com>
> > 
> > It is required to compile ssl-verify.[ch].
> 
> Makes sense. Any idea why it could be built without issues so far? Did
> you hit some compilation problems which led to this patch?
> 
> Acked-by: Christophe Fergeau <cfergeau@redhat.com>

I've pushed this now.

Christophe