Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 20 Nov 2017 13:51:23 +0000 (UTC)
From:      "Timur I. Bakeyev" <timur@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r454560 - in head/databases/ldb13: . files
Message-ID:  <201711201351.vAKDpNWw083193@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: timur
Date: Mon Nov 20 13:51:23 2017
New Revision: 454560
URL: https://svnweb.freebsd.org/changeset/ports/454560

Log:
  In case we'd make samba48 anytime soon.

Added:
  head/databases/ldb13/
     - copied from r451579, head/databases/ldb/
  head/databases/ldb13/files/patch-buildtools__wafsamba__samba_autoconf.py   (contents, props changed)
  head/databases/ldb13/files/patch-buildtools__wafsamba__samba_python.py   (contents, props changed)
  head/databases/ldb13/files/patch-lib__replace__wscript   (contents, props changed)
Modified:
  head/databases/ldb13/Makefile
  head/databases/ldb13/distinfo
  head/databases/ldb13/files/ldb.3
  head/databases/ldb13/files/ldbadd.1
  head/databases/ldb13/files/ldbdel.1
  head/databases/ldb13/files/ldbedit.1
  head/databases/ldb13/files/ldbmodify.1
  head/databases/ldb13/files/ldbrename.1
  head/databases/ldb13/files/ldbsearch.1
  head/databases/ldb13/files/patch-wscript

Modified: head/databases/ldb13/Makefile
==============================================================================
--- head/databases/ldb/Makefile	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/Makefile	Mon Nov 20 13:51:23 2017	(r454560)
@@ -1,29 +1,44 @@
 # $FreeBSD$
 
 PORTNAME=		ldb
-PORTVERSION=		1.1.29
-PORTREVISION=		1
+PORTVERSION=		1.3.0
+PORTREVISION=		0
 PORTEPOCH=		0
 CATEGORIES=		databases
 MASTER_SITES=		SAMBA
+PKGNAMESUFFIX=		13
 
 MAINTAINER=		timur@FreeBSD.org
 COMMENT=		LDAP-like embedded database
 
 LICENSE=		GPLv3
 
-CONFLICTS=		*samba3[0-4]-3.*
+IGNORE_NONTHREAD_PYTHON=needs port lang/python${PYTHON_SUFFIX} to be build with THREADS support
 
-USES=			compiler pkgconfig python:2 waf
+BUILD_DEPENDS=		${LDB_DEPENDS}
+RUN_DEPENDS=		${LDB_DEPENDS}
+
+LDB_DEPENDS=		talloc>=2.1.10:devel/talloc \
+			tevent>=0.9.33:devel/tevent \
+			tdb>=1.3.15:databases/tdb \
+			cmocka>=1.1.1:sysutils/cmocka \
+			popt>=0:devel/popt
+
+CONFLICTS_INSTALL=	ldb-1.1.* ldb12-1.2.*
+
+USES=			compiler pkgconfig waf
 USE_LDCONFIG=		yes
 WAF_CMD=		buildtools/bin/waf
 CONFIGURE_LOG=		bin/config.log
 
 USE_OPENLDAP=		yes
-
 PKGCONFIGDIR?=		${PREFIX}/libdata/pkgconfig
 PLIST_SUB+=		PKGCONFIGDIR=${PKGCONFIGDIR:S;${PREFIX}/;;}
 
+CONFIGURE_ARGS+=	--bundled-libraries=!talloc,!tevent,!tdb,!popt,!cmocka \
+			--with-modulesdir=${PREFIX}/lib/shared-modules \
+			--with-privatelibdir=${PREFIX}/lib/ldb
+
 CONFIGURE_ARGS+=	--mandir=${MANPREFIX}/man \
 			--infodir=${PREFIX}/${INFO_PATH}/${INFO_SUBDIR} \
 			--disable-rpath \
@@ -32,37 +47,16 @@ CONFIGURE_ARGS+=	--mandir=${MANPREFIX}/man \
 OPTIONS_DEFINE=		MANPAGES
 MANPAGES_DESC=		Build and install manpages (requires textproc/docbook-xsl)
 
-BUILD_DEPENDS+=		talloc>=2.1.8:devel/talloc \
-			tevent>=0.9.31:devel/tevent \
-			tdb>=1.3.12,1:databases/tdb \
-			popt>=0:devel/popt
-RUN_DEPENDS:=		${BUILD_DEPENDS}
+.include <bsd.port.options.mk>
 
-CONFIGURE_ARGS+=	--bundled-libraries=!talloc,!tevent,!tdb,!popt \
-			--with-modulesdir=${PREFIX}/lib/shared-modules \
-			--with-privatelibdir=${PREFIX}/lib/ldb
-
-.include <bsd.port.pre.mk>
-
-.if ! ${PORT_OPTIONS:MMANPAGES}
-CONFIGURE_ENV+=		XSLTPROC="true"
-.else
-BUILD_DEPENDS+=		${LOCALBASE}/share/xsl/docbook/manpages/docbook.xsl:textproc/docbook-xsl \
-			xsltproc:textproc/libxslt
-.endif
-
-PLIST_FILES=		bin/ldbedit \
+LDB_BINS=		bin/ldbedit \
 			bin/ldbmodify \
 			bin/ldbadd \
 			bin/ldbdel \
 			bin/ldbsearch \
-			bin/ldbrename \
-			include/ldb_version.h \
-			include/ldb_handlers.h \
-			include/ldb_errors.h \
-			include/ldb.h \
-			include/ldb_module.h \
-			lib/libldb.so \
+			bin/ldbrename
+
+LDB_LIBS=		lib/libldb.so \
 			lib/libldb.so.1 \
 			lib/ldb/libldb-cmdline.so \
 			lib/shared-modules/ldb/asq.so \
@@ -73,15 +67,21 @@ PLIST_FILES=		bin/ldbedit \
 			lib/shared-modules/ldb/sample.so \
 			lib/shared-modules/ldb/server_sort.so \
 			lib/shared-modules/ldb/skel.so \
-			lib/shared-modules/ldb/tdb.so \
+			lib/shared-modules/ldb/tdb.so
+
+PLIST_FILES=		include/ldb_version.h \
+			include/ldb_handlers.h \
+			include/ldb_errors.h \
+			include/ldb.h \
+			include/ldb_module.h \
+			${LDB_BINS} \
+			${LDB_LIBS} \
 			%%PKGCONFIGDIR%%/ldb.pc
 
-# No fancy color error messages
-.if ${COMPILER_TYPE} == "clang"
-CFLAGS+=		-fno-color-diagnostics
-.endif
-CONFIGURE_ENV+=		NOCOLOR=yes
-MAKE_ENV+=		NOCOLOR=yes
+.if defined(NO_PYTHON)
+CONFIGURE_ARGS+=	--disable-python
+.else
+USES+=			python:2.7
 
 PLIST_FILES+=		include/pyldb.h \
 			lib/libpyldb-util.so \
@@ -89,7 +89,50 @@ PLIST_FILES+=		include/pyldb.h \
 			%%PYTHON_SITELIBDIR%%/ldb.so \
 			%%PYTHON_SITELIBDIR%%/_ldb_text.py \
 			%%PKGCONFIGDIR%%/pyldb-util.pc
+# XXX: This is a gross hack to make port use both Python 2.7+ and 3.3+
+# This is not officially supported, use at your own risk
+.if defined(WITH_SAMBA_PYTHON3) && ${WITH_SAMBA_PYTHON3:Mpython3\.[0-9]}
+SAMBA_PYTHON3=		${WITH_SAMBA_PYTHON3}
+SAMBA_PYTHON3_VERSION:=	${SAMBA_PYTHON3:S/^python//}
+SAMBA_PYTHON3_VER:=	${SAMBA_PYTHON3_VERSION:C/\.//}
+.if !exists(${PORTSDIR}/lang/python${SAMBA_PYTHON3_VER})
+.error			unsupported or unknown Python version ${SAMBA_PYTHON3_VERSION}
+.endif
+BUILD_DEPENDS+=		${SAMBA_PYTHON3}:lang/python${SAMBA_PYTHON3_VER}
+RUN_DEPENDS+=		${SAMBA_PYTHON3}:lang/python${SAMBA_PYTHON3_VER}
+# cpython-36m
+SAMBA_PYTHON3_SO_ABI!=	[ ! -f "${LOCALBASE}/bin/${SAMBA_PYTHON3}" ] || ${LOCALBASE}/bin/${SAMBA_PYTHON3} -c 'import sysconfig; print(sysconfig.get_config_var("SOABI") or "")' 2>/dev/null
+SAMBA_PYTHON3_SITELIBDIR=lib/python${SAMBA_PYTHON3_VERSION}/site-packages
 
+CONFIGURE_ENV+=		PYTHON3_SO_ABI_FLAG=.${SAMBA_PYTHON3_SO_ABI}
+CONFIGURE_ARGS+=	--extra-python=${LOCALBASE}/bin/${SAMBA_PYTHON3}
+
+PLIST_SUB+=		SAMBA_PYTHON3_SO_ABI=${SAMBA_PYTHON3_SO_ABI} \
+			SAMBA_PYTHON3_SITELIBDIR=${SAMBA_PYTHON3_SITELIBDIR}
+
+PLIST_FILES+=		lib/libpyldb-util.%%SAMBA_PYTHON3_SO_ABI%%.so \
+			lib/libpyldb-util.%%SAMBA_PYTHON3_SO_ABI%%.so.1 \
+			%%SAMBA_PYTHON3_SITELIBDIR%%/ldb.so \
+			%%SAMBA_PYTHON3_SITELIBDIR%%/_ldb_text.py  \
+			%%PKGCONFIGDIR%%/pyldb-util.%%SAMBA_PYTHON3_SO_ABI%%.pc
+.endif
+.endif
+
+.include <bsd.port.pre.mk>
+
+.if ! ${PORT_OPTIONS:MMANPAGES}
+CONFIGURE_ENV+=		XSLTPROC="true"
+.else
+BUILD_DEPENDS+=		${LOCALBASE}/share/xsl/docbook/manpages/docbook.xsl:textproc/docbook-xsl \
+			xsltproc:textproc/libxslt
+.endif
+# No fancy color error messages
+.if ${COMPILER_TYPE} == "clang"
+CFLAGS+=		-fno-color-diagnostics
+.endif
+CONFIGURE_ENV+=		NOCOLOR=yes
+MAKE_ENV+=		NOCOLOR=yes
+
 LDB_MAN1=		man/man1/ldbadd.1.gz \
 			man/man1/ldbdel.1.gz \
 			man/man1/ldbedit.1.gz \
@@ -101,8 +144,6 @@ LDB_MAN3=		man/man3/ldb.3.gz
 
 PLIST_FILES+=		${LDB_MAN1} ${LDB_MAN3}
 
-IGNORE_NONTHREAD_PYTHON=needs port lang/python${PYTHON_SUFFIX} to be build with THREADS support
-
 post-patch:
 			@${REINPLACE_CMD} -e 's|%%PKGCONFIGDIR%%|${PKGCONFIGDIR}|g' \
 				${BUILD_WRKSRC}/wscript
@@ -116,12 +157,23 @@ pre-configure:
 				${FALSE}; \
 			fi
 
-pre-build:
-.if ! ${PORT_OPTIONS:MMANPAGES}
+pre-build-MANPAGES-off:
 			-${MKDIR} ${BUILD_WRKSRC}/bin/default/man
-.	for man in ${LDB_MAN1} ${LDB_MAN3}
+.for man in ${LDB_MAN1} ${LDB_MAN3}
 			${INSTALL_MAN} ${FILESDIR}/`basename ${man} .gz` ${BUILD_WRKSRC}/bin/default/man
-.	endfor
+.endfor
+
+post-install:
+.for lib in ${LDB_BINS} ${LDB_LIBS}
+			${STRIP_CMD} ${STAGEDIR}${PREFIX}/${lib}
+.endfor
+.if !defined(NO_PYTHON)
+			${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libpyldb-util.so
+			${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/ldb.so
+.if defined(SAMBA_PYTHON3)
+			${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libpyldb-util.${SAMBA_PYTHON3_SO_ABI}.so
+			${STRIP_CMD} ${STAGEDIR}${PREFIX}/${SAMBA_PYTHON3_SITELIBDIR}/ldb.so
+.endif
 .endif
 
 .include <bsd.port.post.mk>

Modified: head/databases/ldb13/distinfo
==============================================================================
--- head/databases/ldb/distinfo	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/distinfo	Mon Nov 20 13:51:23 2017	(r454560)
@@ -1,3 +1,3 @@
-TIMESTAMP = 1483326847
-SHA256 (ldb-1.1.29.tar.gz) = 59d84f9a5b799f519ba7b2685bb46f5a26f1bbf05b7a144b2f5e017d01d80f97
-SIZE (ldb-1.1.29.tar.gz) = 1277551
+TIMESTAMP = 1509845308
+SHA256 (ldb-1.3.0.tar.gz) = 44b53e5a3bc45c8dc837a7e0e00a78e87911da5959ad1b026a62f5b9b4d5590d
+SIZE (ldb-1.3.0.tar.gz) = 1359144

Modified: head/databases/ldb13/files/ldb.3
==============================================================================
--- head/databases/ldb/files/ldb.3	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/ldb.3	Mon Nov 20 13:51:23 2017	(r454560)
@@ -2,12 +2,12 @@
 .\"     Title: ldb
 .\"    Author: [see the "Author" section]
 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>;
-.\"      Date: 01/02/2017
+.\"      Date: 11/05/2017
 .\"    Manual: System Administration tools
 .\"    Source: LDB 1.1
 .\"  Language: English
 .\"
-.TH "LDB" "3" "01/02/2017" "LDB 1\&.1" "System Administration tools"
+.TH "LDB" "3" "11/05/2017" "LDB 1\&.1" "System Administration tools"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -453,5 +453,5 @@ ldb is released under the GNU Lesser General Public Li
 .IP " 1." 4
 Andrew Tridgell
 .RS 4
-\%http://samba.org/~tridge/
+\%https://www.samba.org/~tridge/
 .RE

Modified: head/databases/ldb13/files/ldbadd.1
==============================================================================
--- head/databases/ldb/files/ldbadd.1	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/ldbadd.1	Mon Nov 20 13:51:23 2017	(r454560)
@@ -2,12 +2,12 @@
 .\"     Title: ldbadd
 .\"    Author: [see the "AUTHOR" section]
 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>;
-.\"      Date: 01/02/2017
+.\"      Date: 11/05/2017
 .\"    Manual: System Administration tools
 .\"    Source: LDB 1.1
 .\"  Language: English
 .\"
-.TH "LDBADD" "1" "01/02/2017" "LDB 1\&.1" "System Administration tools"
+.TH "LDBADD" "1" "11/05/2017" "LDB 1\&.1" "System Administration tools"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -74,5 +74,5 @@ This manpage was written by Jelmer Vernooij\&.
 .IP " 1." 4
 Andrew Tridgell
 .RS 4
-\%http://samba.org/~tridge/
+\%https://www.samba.org/~tridge/
 .RE

Modified: head/databases/ldb13/files/ldbdel.1
==============================================================================
--- head/databases/ldb/files/ldbdel.1	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/ldbdel.1	Mon Nov 20 13:51:23 2017	(r454560)
@@ -2,12 +2,12 @@
 .\"     Title: ldbdel
 .\"    Author: [see the "AUTHOR" section]
 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>;
-.\"      Date: 01/02/2017
+.\"      Date: 11/05/2017
 .\"    Manual: System Administration tools
 .\"    Source: LDB 1.1
 .\"  Language: English
 .\"
-.TH "LDBDEL" "1" "01/02/2017" "LDB 1\&.1" "System Administration tools"
+.TH "LDBDEL" "1" "11/05/2017" "LDB 1\&.1" "System Administration tools"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -76,5 +76,5 @@ This manpage was written by Jelmer Vernooij\&.
 .IP " 1." 4
 Andrew Tridgell
 .RS 4
-\%http://samba.org/~tridge/
+\%https://www.samba.org/~tridge/
 .RE

Modified: head/databases/ldb13/files/ldbedit.1
==============================================================================
--- head/databases/ldb/files/ldbedit.1	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/ldbedit.1	Mon Nov 20 13:51:23 2017	(r454560)
@@ -2,12 +2,12 @@
 .\"     Title: ldbedit
 .\"    Author: [see the "AUTHOR" section]
 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>;
-.\"      Date: 01/02/2017
+.\"      Date: 11/05/2017
 .\"    Manual: System Administration tools
 .\"    Source: LDB 1.1
 .\"  Language: English
 .\"
-.TH "LDBEDIT" "1" "01/02/2017" "LDB 1\&.1" "System Administration tools"
+.TH "LDBEDIT" "1" "11/05/2017" "LDB 1\&.1" "System Administration tools"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -107,5 +107,5 @@ This manpage was written by Jelmer Vernooij and update
 .IP " 1." 4
 Andrew Tridgell
 .RS 4
-\%http://samba.org/~tridge/
+\%https://www.samba.org/~tridge/
 .RE

Modified: head/databases/ldb13/files/ldbmodify.1
==============================================================================
--- head/databases/ldb/files/ldbmodify.1	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/ldbmodify.1	Mon Nov 20 13:51:23 2017	(r454560)
@@ -2,12 +2,12 @@
 .\"     Title: ldbmodify
 .\"    Author: [see the "AUTHOR" section]
 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>;
-.\"      Date: 01/02/2017
+.\"      Date: 11/05/2017
 .\"    Manual: System Administration tools
 .\"    Source: LDB 1.1
 .\"  Language: English
 .\"
-.TH "LDBMODIFY" "1" "01/02/2017" "LDB 1\&.1" "System Administration tools"
+.TH "LDBMODIFY" "1" "11/05/2017" "LDB 1\&.1" "System Administration tools"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -69,5 +69,5 @@ This manpage was written by Jelmer Vernooij\&.
 .IP " 1." 4
 Andrew Tridgell
 .RS 4
-\%http://samba.org/~tridge/
+\%https://www.samba.org/~tridge/
 .RE

Modified: head/databases/ldb13/files/ldbrename.1
==============================================================================
--- head/databases/ldb/files/ldbrename.1	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/ldbrename.1	Mon Nov 20 13:51:23 2017	(r454560)
@@ -2,12 +2,12 @@
 .\"     Title: ldbrename
 .\"    Author: [see the "AUTHOR" section]
 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>;
-.\"      Date: 01/02/2017
+.\"      Date: 11/05/2017
 .\"    Manual: System Administration tools
 .\"    Source: LDB 1.1
 .\"  Language: English
 .\"
-.TH "LDBRENAME" "1" "01/02/2017" "LDB 1\&.1" "System Administration tools"
+.TH "LDBRENAME" "1" "11/05/2017" "LDB 1\&.1" "System Administration tools"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -77,5 +77,5 @@ This manpage was written by Jelmer Vernooij\&.
 .IP " 1." 4
 Andrew Tridgell
 .RS 4
-\%http://samba.org/~tridge/
+\%https://www.samba.org/~tridge/
 .RE

Modified: head/databases/ldb13/files/ldbsearch.1
==============================================================================
--- head/databases/ldb/files/ldbsearch.1	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/ldbsearch.1	Mon Nov 20 13:51:23 2017	(r454560)
@@ -2,12 +2,12 @@
 .\"     Title: ldbsearch
 .\"    Author: [see the "AUTHOR" section]
 .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>;
-.\"      Date: 01/02/2017
+.\"      Date: 11/05/2017
 .\"    Manual: System Administration tools
 .\"    Source: LDB 1.1
 .\"  Language: English
 .\"
-.TH "LDBSEARCH" "1" "01/02/2017" "LDB 1\&.1" "System Administration tools"
+.TH "LDBSEARCH" "1" "11/05/2017" "LDB 1\&.1" "System Administration tools"
 .\" -----------------------------------------------------------------
 .\" * Define some portability stuff
 .\" -----------------------------------------------------------------
@@ -87,5 +87,5 @@ This manpage was written by Jelmer Vernooij\&.
 .IP " 1." 4
 Andrew Tridgell
 .RS 4
-\%http://samba.org/~tridge/
+\%https://www.samba.org/~tridge/
 .RE

Added: head/databases/ldb13/files/patch-buildtools__wafsamba__samba_autoconf.py
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/databases/ldb13/files/patch-buildtools__wafsamba__samba_autoconf.py	Mon Nov 20 13:51:23 2017	(r454560)
@@ -0,0 +1,11 @@
+--- buildtools/wafsamba/samba_autoconf.py.orig	2016-10-07 04:45:35 UTC
++++ buildtools/wafsamba/samba_autoconf.py
+@@ -873,7 +873,7 @@ def SAMBA_CHECK_UNDEFINED_SYMBOL_FLAGS(c
+         conf.env.undefined_ldflags = conf.ADD_LDFLAGS('-Wl,-no-undefined', testflags=True)
+ 
+     if not sys.platform.startswith("openbsd") and conf.env.undefined_ignore_ldflags == []:
+-        if conf.CHECK_LDFLAGS(['-undefined', 'dynamic_lookup']):
++        if conf.CHECK_LDFLAGS(['-undefined', 'dynamic_lookup'] + conf.env.WERROR_CFLAGS):
+             conf.env.undefined_ignore_ldflags = ['-undefined', 'dynamic_lookup']
+ 
+ @conf

Added: head/databases/ldb13/files/patch-buildtools__wafsamba__samba_python.py
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/databases/ldb13/files/patch-buildtools__wafsamba__samba_python.py	Mon Nov 20 13:51:23 2017	(r454560)
@@ -0,0 +1,36 @@
+--- buildtools/wafsamba/samba_python.py.orig	2017-04-28 08:57:26 UTC
++++ buildtools/wafsamba/samba_python.py
+@@ -76,17 +76,31 @@ def SAMBA_CHECK_PYTHON_HEADERS(conf, man
+ 
+ def _check_python_headers(conf, mandatory):
+     try:
++        from python import _get_python_variables
+         Configure.ConfigurationError
+         conf.check_python_headers(mandatory=mandatory)
++        conf.env['PYTHON_SO_ABI'] = _get_python_variables(
++            conf.env['PYTHON'],
++            ["get_config_var('SOABI') or ''"],
++            ['from distutils.sysconfig import get_config_var']
++        )[0]
+     except Configure.ConfigurationError:
+         if mandatory:
+              raise
+ 
+     if conf.env['PYTHON_VERSION'] > '3':
+-        abi_pattern = os.path.splitext(conf.env['pyext_PATTERN'])[0]
+-        conf.env['PYTHON_SO_ABI_FLAG'] = abi_pattern % ''
++        override_PYTHON3_SO_ABI_FLAG = os.getenv('PYTHON3_SO_ABI_FLAG', None)
++        if override_PYTHON3_SO_ABI_FLAG is not None:
++            conf.env['PYTHON_SO_ABI_FLAG'] = override_PYTHON3_SO_ABI_FLAG
++        if not conf.env['PYTHON_SO_ABI_FLAG']:
++            if conf.env['PYTHON_SO_ABI']:
++                conf.env['PYTHON_SO_ABI_FLAG'] = '.'+conf.env['PYTHON_SO_ABI']
++            else:
++                abi_pattern = os.path.splitext(conf.env['pyext_PATTERN'])[0]
++                conf.env['PYTHON_SO_ABI_FLAG'] = abi_pattern % ''
+     else:
+         conf.env['PYTHON_SO_ABI_FLAG'] = ''
++
+     conf.env['PYTHON_LIBNAME_SO_ABI_FLAG'] = (
+         conf.env['PYTHON_SO_ABI_FLAG'].replace('_', '-'))
+ 

Added: head/databases/ldb13/files/patch-lib__replace__wscript
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/databases/ldb13/files/patch-lib__replace__wscript	Mon Nov 20 13:51:23 2017	(r454560)
@@ -0,0 +1,11 @@
+--- lib/replace/wscript.orig	2017-08-24 11:27:53 UTC
++++ lib/replace/wscript
+@@ -81,7 +81,7 @@ def configure(conf):
+     conf.CHECK_HEADERS('sys/atomic.h')
+     conf.CHECK_HEADERS('libgen.h')
+ 
+-    if conf.CHECK_CFLAGS('-Wno-format-truncation'):
++    if conf.CHECK_CFLAGS(['-Wno-format-truncation'] + conf.env.WERROR_CFLAGS):
+         conf.define('HAVE_WNO_FORMAT_TRUNCATION', '1')
+ 
+     # Check for process set name support

Modified: head/databases/ldb13/files/patch-wscript
==============================================================================
--- head/databases/ldb/files/patch-wscript	Sun Oct  8 21:26:19 2017	(r451579)
+++ head/databases/ldb13/files/patch-wscript	Mon Nov 20 13:51:23 2017	(r454560)
@@ -1,11 +1,32 @@
---- ./wscript.orig	2013-01-27 11:51:43.000000000 +0000
-+++ ./wscript	2013-01-29 23:01:21.749877676 +0000
-@@ -106,7 +106,7 @@
+--- wscript.orig	2017-09-07 10:04:11 UTC
++++ wscript
+@@ -126,9 +126,15 @@ def build(bld):
+     bld.RECURSE('lib/tdb')
  
-     if not 'PACKAGE_VERSION' in bld.env:
-         bld.env.PACKAGE_VERSION = VERSION
--        bld.env.PKGCONFIGDIR = '${LIBDIR}/pkgconfig'
+     if bld.env.standalone_ldb:
++        if not 'PACKAGE_VERSION' in bld.env:
++            bld.env.PACKAGE_VERSION = VERSION
 +        bld.env.PKGCONFIGDIR = '%%PKGCONFIGDIR%%'
+         private_library = False
+     else:
+         private_library = True
++    # we're not currently linking against the ldap libs, but ldb.pc.in
++    # has @LDAP_LIBS@
++    bld.env.LDAP_LIBS = ''
  
-     if not bld.CONFIG_SET('USING_SYSTEM_PYLDB_UTIL'):
-         bld.SAMBA_LIBRARY('pyldb-util',
+     LDB_MAP_SRC = bld.SUBDIR('ldb_map',
+                              'ldb_map.c ldb_map_inbound.c ldb_map_outbound.c')
+@@ -149,13 +155,6 @@ def build(bld):
+     if bld.PYTHON_BUILD_IS_ENABLED():
+         if not bld.CONFIG_SET('USING_SYSTEM_PYLDB_UTIL'):
+             for env in bld.gen_python_environments(['PKGCONFIGDIR']):
+-                # we're not currently linking against the ldap libs, but ldb.pc.in
+-                # has @LDAP_LIBS@
+-                bld.env.LDAP_LIBS = ''
+-
+-                if not 'PACKAGE_VERSION' in bld.env:
+-                    bld.env.PACKAGE_VERSION = VERSION
+-                    bld.env.PKGCONFIGDIR = '${LIBDIR}/pkgconfig'
+ 
+                 name = bld.pyembed_libname('pyldb-util')
+                 bld.SAMBA_LIBRARY(name,



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201711201351.vAKDpNWw083193>