mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 17:59:20 -04:00
Unbreak the build on FreeBSD 9 after r426647.
SOCK_CLOEXEC was introduced in FreeBSD 10, so define it to 0 on FreeBSD 9 (the code already handles this case). Xapian 1.4 has a safesyssocket.h that does the same thing. PR: 214699 Approved by: portmgr (antoine)
This commit is contained in:
parent
a35c3a7d46
commit
3dae42992f
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=426759
2 changed files with 24 additions and 1 deletions
|
@ -28,9 +28,16 @@ PORTDOCS= *
|
|||
|
||||
SSE2_CONFIGURE_ENABLE= sse
|
||||
|
||||
.include <bsd.port.pre.mk>
|
||||
|
||||
# FreeBSD 9 does not have SOCK_CLOEXEC.
|
||||
.if ${OPSYS} == FreeBSD && ${OSVERSION} < 1000000
|
||||
EXTRA_PATCHES= ${FILESDIR}/extrapatch-backends_flint__lock.cc
|
||||
.endif
|
||||
|
||||
post-install:
|
||||
.for file in copydatabase delve quest
|
||||
${INSTALL_PROGRAM} ${WRKSRC}/examples/.libs/${file} ${STAGEDIR}${PREFIX}/bin/xapian-${file}
|
||||
.endfor
|
||||
|
||||
.include <bsd.port.mk>
|
||||
.include <bsd.port.post.mk>
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
FreeBSD 9 does not have SOCK_CLOEXEC. Define it to 0, as the code already deals
|
||||
with it.
|
||||
Xapian 1.4 has a safesyssocket.h that takes care of this.
|
||||
--- backends/flint_lock.cc.orig 2016-09-16 01:59:15 UTC
|
||||
+++ backends/flint_lock.cc
|
||||
@@ -59,6 +59,10 @@ using namespace std;
|
||||
# endif
|
||||
#endif
|
||||
|
||||
+#ifndef SOCK_CLOEXEC
|
||||
+#define SOCK_CLOEXEC 0
|
||||
+#endif
|
||||
+
|
||||
FlintLock::reason
|
||||
FlintLock::lock(bool exclusive, string & explanation) {
|
||||
// Currently we only support exclusive locks.
|
Loading…
Add table
Reference in a new issue