On Tue, Jan 17, 2017 at 04:05:16PM -0800, David Wolfskill wrote: > [The R "openssl" package didn't build under FreeBSD for me....] > ... > gcc49 -std=gnu99 -I/usr/local/lib/R/include -DNDEBUG -DLIBICONV_PLUG > -I/usr/local/include -isystem /usr/local/include -fpic -O2 -pipe > -DLIBICONV_PLUG -fstack-protector -Wl,-rpath=/usr/local/lib/gcc49 -isystem > /usr/local/include -fno-strict-aliasing -flto -c ssl.c -o ssl.o > ssl.c: In function 'R_download_cert': > ssl.c:41:21: error: 'PF_UNSPEC' undeclared (first use in this function) > hints.ai_family = PF_UNSPEC; > ^ > ssl.c:41:21: note: each undeclared identifier is reported only once for each > function it appears in > *** Error code 1 > ....
It turns out that in FreeBSD (possibly also in other BSD-derived environments), PF_UNSPEC is defined (in /usr/include/sys/socket.h), but only if "__BSD_VISIBLE" is true: g1-252(11.0-S)[3] grep -nwC 6 PF_UNSPEC /usr/include/sys/socket.h 323-#include <sys/_sockaddr_storage.h> 324- 325-#if __BSD_VISIBLE 326-/* 327- * Protocol families, same as address families for now. 328- */ 329:#define PF_UNSPEC AF_UNSPEC 330-#define PF_LOCAL AF_LOCAL 331-#define PF_UNIX PF_LOCAL /* backward compatibility */ 332-#define PF_INET AF_INET 333-#define PF_IMPLINK AF_IMPLINK 334-#define PF_PUP AF_PUP 335-#define PF_CHAOS AF_CHAOS g1-252(11.0-S)[4] And while PF_UNSPEC is referenced in the sources for the R openssl package, __BSD_VISIBLE is not: g1-252(11.0-S)[33] dirs ~/R/Rtmp4VjFtY/dhw/openssl g1-252(11.0-S)[34] grep -nrw PF_UNSPEC . ./src/ssl.c:41: hints.ai_family = PF_UNSPEC; g1-252(11.0-S)[35] grep -nrw __BSD_VISIBLE . g1-252(11.0-S)[36] And it appears that the local sources are ephemeral, so I can't readily patch those sources to see if I can get it to work (as the patched sources wouldn't be used) -- unless I miss the mark.... Any suggestions for how I might proceed? Thanks! Peace, david -- David H. Wolfskill r...@catwhisker.org How could one possibly "respect" a misogynist, racist, bullying con-man??!? See http://www.catwhisker.org/~david/publickey.gpg for my public key.
signature.asc
Description: PGP signature
______________________________________________ R-package-devel@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel