Skip to contentSkip to conversation

openflow: add libcrypto to static openflow library

PATCH Superseded Joe MacDonald 1 participant 2 messages Mar 13, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 openflow: add libcrypto to static openflow library

An update in OpenSSL removed the -lcrypto from libssl's pkg-config options. The old behaviour always linked it with -lssl, so revert to that for now.

---

There's a number of ways to do this, I think this is the least-invasive solution. That said, the upstream openflow reference implementation has seen no activity in about three years so I'm thinking very soon I'll remove the _git recipe entirely in favour of a more up-to-date (with respect to the specifications) version, so I also didn't want invest too much into fixing the build issues (this should actually be solved by ensuring the library buildng gcc commands get -static passed to them, but that turns out to be kind of a mess) with this recipe.

-J.

 meta-networking/recipes-protocols/openflow/openflow.inc | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)
meta-networking/recipes-protocols/openflow/openflow.inc +6 -3
index 1a226f8..7a1e478 100644
@@ -15,14 +15,17 @@ SRC_URI = "git://gitosis.stanford.edu/openflow.git;protocol=git"
 
 DEPENDS = "virtual/libc"
 
-EXTRA_OECONF += "KARCH=${TARGET_ARCH}"
-
 PACKAGECONFIG ??= "openssl"
 PACKAGECONFIG[openssl] = "--enable-ssl,--disable-ssl, openssl, libssl"
 
+EXTRA_OECONF += " \
+                 KARCH=${TARGET_ARCH} \
+                 ${@base_contains('PACKAGECONFIG', 'openssl', 'SSL_LIBS="-lssl -lcrypto"', '', d)} \
+                "
+
 S = "${WORKDIR}/git"
 
-inherit autotools-brokensep
+#inherit autotools-brokensep
 
 do_configure() {
     ./boot.sh
Signature · 1 line
1.9.1
#1 lore raw

PATCH v2 1/1 openflow: add libcrypto to static openflow library

An update in OpenSSL removed the -lcrypto from libssl's pkg-config options. The old behaviour always linked it with -lssl, so revert to that for now.

---

Oops, v1 included one lingering bit of damage where I was also trying to correct the B != S failures, that shouldn't be there. Openflow is still broken if you attempt to build outside of the source tree.

 meta-networking/recipes-protocols/openflow/openflow.inc | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
meta-networking/recipes-protocols/openflow/openflow.inc +5 -2
index 1a226f8..75d8ab8 100644
@@ -15,11 +15,14 @@ SRC_URI = "git://gitosis.stanford.edu/openflow.git;protocol=git"
 
 DEPENDS = "virtual/libc"
 
-EXTRA_OECONF += "KARCH=${TARGET_ARCH}"
-
 PACKAGECONFIG ??= "openssl"
 PACKAGECONFIG[openssl] = "--enable-ssl,--disable-ssl, openssl, libssl"
 
+EXTRA_OECONF += " \
+                 KARCH=${TARGET_ARCH} \
+                 ${@base_contains('PACKAGECONFIG', 'openssl', 'SSL_LIBS="-lssl -lcrypto"', '', d)} \
+                "
+
 S = "${WORKDIR}/git"
 
 inherit autotools-brokensep
Signature · 1 line
1.9.1