Created attachment 183207 [details] libmdf.shar libmdf is the Millistream Data Feed API library with which developers can connect to the Millistream Market Data system and subscribe to streaming realtime or delayed market data such as stocks, indices, currencies, bonds, derivatives and news services. WWW: https://millistream.com
Created attachment 183208 [details] Poudriere log Attached the Poudriere log
Thank you Henrik. Initial review looks clean You may want to consider adding 'finance' as a secondary category
Ah, never realised that there where such a category. Will add and upload new shar in a moment.
Created attachment 183210 [details] libmdf.shar Added 'finance' to categories
Testing/QA'ing on i386
Created attachment 183212 [details] Poudriere i386 log Attached a log from poudriere on a i386 jail
./configure fails to detect OpenSSL (in FreeBSD base), given it uses PKG_CHECK_MODULES and FreeBSD does not provide a .pc file for openssl: ================================= checking for OPENSSL... no configure: error: Package requirements (openssl) were not met: Package 'openssl', required by 'virtual:world', not found Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a non-standard prefix. Alternatively, you may set the environment variables OPENSSL_CFLAGS and OPENSSL_LIBS to avoid the need to call pkg-config. ================================= Further since the test environment used DEFAULT_VERSIONS+=ssl=openssl in /usr/local/etc/poudriere.d/make.conf, 'openssl' meaning 'openssl port', poudriere installs the port and the error is not observed. This is corrected by using the following in the port Makefile: CONFIGURE_ENV+= OPENSSL_CFLAGS=${OPENSSLINC} \ OPENSSL_LIBS=${OPENSSLLIB} OPENSSL{INC,LIB} are provided by Mk/Uses/ssl.mk I have applied this to my working copy, there's no need to update the attachment/patch
A commit references this bug: Author: koobs Date: Sun Jun 4 16:49:21 UTC 2017 New revision: 442570 URL: https://svnweb.freebsd.org/changeset/ports/442570 Log: [NEW PORT] net/libmdf: Millistream Data Feed API library libmdf is the Millistream Data Feed API library with which developers can connect to the Millistream Market Data system and subscribe to streaming realtime or delayed market data such as stocks, indices, currencies, bonds, derivatives and news services. WWW: https://millistream.com PR: 219777 Submitted by: Henrik Holst <henrik.holst millistream com> Changes: head/net/Makefile head/net/libmdf/ head/net/libmdf/Makefile head/net/libmdf/distinfo head/net/libmdf/pkg-descr head/net/libmdf/pkg-plist
Committed with changes: - Add configure environment variables to prevent pkg-config from being run, causing non-detection of OpenSSL in base, and configure error. - Group, sort and space separate sections - Sort USES Thank you Henrik
Hmm, something went wrong. It's now not linked with libcrypto.so anymore so there are tons of undefined references to OpenSSL functions when you try to link with the library. Looking at why this happens.
Created attachment 183218 [details] patch to net/libmdf/Makefile Found the problem. The pkgconfig part in automake relies on pkgconfig to supply "-lcrypto" which of course OPENSSL_LIBS doesn't. I don't know if there is a cleaner better way to handle it than what I did by adding "LDFLAGS+=-lcrypto", but now it links atleast.
@Henrik, I can add -lcrypto to the existing OPENSSL_LIBS (./configure) environment variable in the port, to be "OPENSSL_LIBS=${OPENSSLLIB} -lcrypto", or I can use LDFLAGS, or another variable at your direction. It may be worth testing the former to see if there are any side effects or other issues. All else being equal I understand separation of LDFLAGS and LIBS is "a good thing" TM (using -lfoo in the latter), but the implementation of ./configure or the PKG_CHECK_MODULES m4 module may already be prescriptive or specific in this regard.
I've just tested with "OPENSSL_LIBS=${OPENSSLLIB} -lcrypto" and it works fine, I tested it yesterday but forgot to add the "" so it didn't work leading me to the LDFLAGS solution. Since you propose to use OPENSSL_LIBS I reckon that this is the cleaner way (I'm quite new to FreeBSD) and since it does work, I say that we go with that one. Just noticed why this whole ssl thing begun in the first place, not knowing FreeBSD I thought that openssl-devel was the package that contained headers since that is how it works on most Linux distributions (where there is a -dev package to libraries) so I installed that and that package seams to have installed a pkg-config profile for OpenSSL. Many thanks for your patience with this newcomer :)
(In reply to Henrik Holst from comment #13) For a newbie you did an exceptional job on your submission and issue report, so thank you. And yep, foo-devel in (current) FreeBSD parlance is just a defacto nnaming convention for the 'development version' of a corresponding "foo" port. I don't know the history, but I would guess it was not called '-dev' specifically to avoid confusing it with 'development' subpackages on other operating systems. There will come a time where FreeBSD has 'subpackages' that are more programmatically created across the board (say -debug packages providing only debug symbols), though there are quite a few existing examples where software has been split into multiple ports/packages already (libx264/x264 is one).
A commit references this bug: Author: koobs Date: Tue Jun 6 05:50:50 UTC 2017 New revision: 442742 URL: https://svnweb.freebsd.org/changeset/ports/442742 Log: net/libmdf: Add missing openssl library argument The build relies on pkg-config to supply "-lcrypto" but we're using OPENSSL_CFLAGS and OPENSSL_LIBS (not pkg-config), to enable libmdf to find openssl in base, which does not provide an openssl.pc file. The previous commit neglected to explicitly include the library to link with (-lcrypto), resulting in undefined references to OpenSSL functions when attempting to link with the libmdf library. PR: 219777 Reported by: Henrik Holst <henrik.holst millistream com> Changes: head/net/libmdf/Makefile
Committed, thank you for the report Henrik.