[oe] [PATCH 2/2] openflow: update libopenflow.m4 to use openssl instead of libssl

Saul Wold sgw at linux.intel.com
Wed Mar 18 02:54:13 UTC 2015


openssl provides both the libssl and libcrypto APIs for linkage, the 1.0.2 of
OpenSSL removed libcrypto from the libssl.pc

Signed-off-by: Saul Wold <sgw at linux.intel.com>
---
 .../recipes-protocols/openflow/openflow.inc        |  4 ++-
 .../openflow/use-openssl-instead-of-libssl.patch   | 34 ++++++++++++++++++++++
 2 files changed, 37 insertions(+), 1 deletion(-)
 create mode 100644 meta-networking/recipes-protocols/openflow/openflow/use-openssl-instead-of-libssl.patch

diff --git a/meta-networking/recipes-protocols/openflow/openflow.inc b/meta-networking/recipes-protocols/openflow/openflow.inc
index 1a226f8..7eca1d7 100644
--- a/meta-networking/recipes-protocols/openflow/openflow.inc
+++ b/meta-networking/recipes-protocols/openflow/openflow.inc
@@ -11,7 +11,9 @@ LICENSE = "GPLv2"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=e870c934e2c3d6ccf085fd7cf0a1e2e2"
 
-SRC_URI = "git://gitosis.stanford.edu/openflow.git;protocol=git"
+SRC_URI = "git://gitosis.stanford.edu/openflow.git;protocol=git \
+           file://use-openssl-instead-of-libssl.patch \
+          "
 
 DEPENDS = "virtual/libc"
 
diff --git a/meta-networking/recipes-protocols/openflow/openflow/use-openssl-instead-of-libssl.patch b/meta-networking/recipes-protocols/openflow/openflow/use-openssl-instead-of-libssl.patch
new file mode 100644
index 0000000..724855f
--- /dev/null
+++ b/meta-networking/recipes-protocols/openflow/openflow/use-openssl-instead-of-libssl.patch
@@ -0,0 +1,34 @@
+OpenSSL 1.0.2 removed -lcrypto from the libssl.pc, but the openssl.pc
+contains both. Since openflow uses both libcrypto and libssl API we
+should use openssl.pc.
+
+Signed-off-by: Saul Wold <sgw at linux.intel.com>
+
+Upstream-Status: Inappropriate [upstream obsolete]
+
+Index: git/m4/libopenflow.m4
+===================================================================
+--- git.orig/m4/libopenflow.m4
++++ git/m4/libopenflow.m4
+@@ -65,7 +65,7 @@ AC_DEFUN([OFP_CHECK_OPENSSL],
+   [AC_ARG_ENABLE(
+      [ssl],
+      [AC_HELP_STRING([--enable-ssl], 
+-                     [Enable ssl support (requires libssl)])],
++                     [Enable ssl support (requires libssl and libcrypto)])],
+      [case "${enableval}" in
+         (yes) ssl=true ;;
+         (no)  ssl=false ;;
+@@ -76,10 +76,10 @@ AC_DEFUN([OFP_CHECK_OPENSSL],
+    if test "$ssl" = true; then
+    dnl Make sure that pkg-config is installed.
+    m4_pattern_forbid([PKG_CHECK_MODULES])
+-   PKG_CHECK_MODULES([SSL], [libssl], 
++   PKG_CHECK_MODULES([SSL], [openssl], 
+      [HAVE_OPENSSL=yes],
+      [HAVE_OPENSSL=no
+-      AC_MSG_WARN([Cannot find libssl:
++      AC_MSG_WARN([Cannot find OpenSSL Libraries:
+ 
+    $SSL_PKG_ERRORS
+ 
-- 
2.1.0




More information about the Openembedded-devel mailing list