Bug 198781

Summary: [PATCH] devel/ice: Make EGD conditional/Fix build with LibreSSL
Product: Ports & Packages Reporter: Bernard Spil <brnrd>
Component: Individual Port(s)Assignee: Michael Gmelin <grembo>
Status: Closed DUPLICATE    
Severity: Affects Some People CC: freebsd, grembo
Priority: --- Keywords: needs-patch, patch
Version: LatestFlags: grembo: maintainer-feedback-
Hardware: Any   
OS: Any   
Description Flags
svn diff for devel/ice
koobs: maintainer-approval? (freebsd)
Poudriere build log for devel/ice none

Description Bernard Spil freebsd_committer 2015-03-21 19:50:16 UTC
Created attachment 154639 [details]
svn diff for devel/ice

devel/ice requires RAND_egd which makes building fail with LibreSSL which has removed EGD. FreeBSD does not require EGD at all, /dev/random has been available since FreeBSD 4.2.

Adds some missing include/opensslv.h as well as build failed due to OPENSSL_VERSION defined
Comment 1 Bernard Spil freebsd_committer 2015-03-21 19:50:46 UTC
Created attachment 154640 [details]
Poudriere build log for devel/ice
Comment 2 Michael Gmelin freebsd_committer 2015-03-23 11:07:25 UTC
Thank you for providing the patch.

I'll look into it shortly and commit it.
Comment 3 Michael Gmelin freebsd_committer 2015-03-23 15:05:38 UTC
Using the patch and libressl, Ice unit tests fail (you can also see this in the poudriere output you attached yourself). It works with openssl from ports, but the resulting libraries link against system OpenSSL. So the port (and potentially its slaves) need more work done to support WITH_OPENSSL_PORT=yes properly. Unit test output:

*** running tests 49/86 in /wrkdirs/usr/ports/devel/ice/work/Ice-3.5.1/cpp/test/IceSSL/configuration
*** configuration: Default 
*** test started: 03/21/15 19:29:24
starting server... ok
starting client... ok
testing manual initialization... -! 03/21/15 19:29:24.229 warning: connection exception:
   TcpTransceiver.cpp:284: Ice::ConnectionLostException:
   connection lost: recv() returned zero
   local address =
   remote address =
AllTests.cpp:235: assertion `false' failed
unexpected exit status: expected: 0, got -6
('test in /wrkdirs/usr/ports/devel/ice/work/Ice-3.5.1/cpp/test/IceSSL/configuration failed with exit status', 256)

As it turns out, the unit test python scripts have an issue introduced upstream that prevent the build from failing. I'll fix this shortly and also report it upstream, so that a failed unit test will actually result in a failed build.
Comment 4 Kubilay Kocak freebsd_committer freebsd_triage 2015-03-24 00:11:47 UTC
Maintainer is committer, assign
Comment 5 Bernard Spil freebsd_committer 2015-04-11 11:48:00 UTC
Hi Michael,

No I had no intention of fixing the fall-out caused by this. I can put it on my list but since I'm not a user of devel/ice it will take me a while to get to it.
Please check https://wiki.freebsd.org/LibreSSL for a list I'm working on (and OpenSSL as well)
Comment 6 Michael Gmelin freebsd_committer 2015-05-03 21:24:41 UTC
According to https://wiki.freebsd.org/LibreSSL this is on your list. If you agree I can apply those patches and close this bug, but you need to understand that it's not fixing the issue. As builds will still fail I don't see a lot of harm in this though, so I might just do this anyway so it's off your list.

I will work on this myself in the next couple of months. I have enough production code to make sure that whatever I come up with works reliably.
Comment 7 Michael Gmelin freebsd_committer 2015-06-27 09:11:47 UTC
As this patch doesn't do what it proposes and upstream just released a major release, I'll close this for now.

Please reopen if you have a comprehensive patch that not only builds, but also allows running the resulting executables (e.g. unit tests).
Comment 8 Bernard Spil freebsd_committer 2015-06-27 17:49:15 UTC
Hi Michael,

Patch needs rework anyway. LibreSSL now defines OPENSSL_NO_EGD just like other missing features. Will get back on this topic!
Comment 9 Michael Gmelin freebsd_committer 2015-09-16 23:34:43 UTC

*** This bug has been marked as a duplicate of bug 203163 ***