summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--devel/tevent016/Makefile75
-rw-r--r--devel/tevent016/distinfo3
-rw-r--r--devel/tevent016/files/patch-buildtools_wafsamba_samba__autoconf.py35
-rw-r--r--devel/tevent016/files/patch-buildtools_wafsamba_samba__install.py11
-rw-r--r--devel/tevent016/files/patch-buildtools_wafsamba_wscript15
-rw-r--r--devel/tevent016/files/patch-lib_replace_wscript11
-rw-r--r--devel/tevent016/files/patch-wscript11
-rw-r--r--devel/tevent016/pkg-descr6
-rw-r--r--devel/tevent016/pkg-plist7
9 files changed, 174 insertions, 0 deletions
diff --git a/devel/tevent016/Makefile b/devel/tevent016/Makefile
new file mode 100644
index 000000000000..0ab8dec78ce6
--- /dev/null
+++ b/devel/tevent016/Makefile
@@ -0,0 +1,75 @@
+PORTNAME= tevent
+DISTVERSION= 0.15.0
+PORTEPOCH= 0
+CATEGORIES= devel
+MASTER_SITES= SAMBA
+
+MAINTAINER= samba@FreeBSD.org
+COMMENT= Talloc based event loop library
+WWW= https://tevent.samba.org/
+
+LICENSE= LGPL3
+
+BUILD_DEPENDS= talloc>=2.3.4:devel/talloc
+RUN_DEPENDS= talloc>=2.3.4:devel/talloc
+
+USES= compiler pkgconfig shebangfix waf
+USE_LDCONFIG= yes
+SHEBANG_GLOB= *.py
+WAF_CMD= buildtools/bin/waf
+CONFIGURE_LOG= bin/config.log
+
+PKGCONFIGDIR?= ${PREFIX}/libdata/pkgconfig
+PLIST_SUB= PKGCONFIGDIR=${PKGCONFIGDIR:S;^${PREFIX}/;;}
+
+CONFIGURE_ARGS= --disable-rpath \
+ --disable-rpath-install \
+ --bundled-libraries=!talloc,cmocka \
+ --builtin-libraries=replace \
+ --without-gettext
+CONFIGURE_ENV= PYTHONHASHSEED=1
+MAKE_ENV= PYTHONHASHSEED=1
+
+MANPAGES_DESC= Build and install manpages (requires textproc/docbook-xsl)
+
+OPTIONS_DEFINE= DEBUG MANPAGES PYTHON
+OPTIONS_DEFAULT= PYTHON
+OPTIONS_SUB= yes
+
+DEBUG_CFLAGS= -g -ggdb3 -O0
+DEBUG_CONFIGURE_ON= --verbose --enable-debug
+DEBUG_MAKE_ARGS= --verbose
+
+PYTHON_USES= gettext-runtime python
+PYTHON_USE= python=py3kplist
+PYTHON_USES_OFF= python:build,test
+PYTHON_CONFIGURE_OFF= --disable-python
+
+MANPAGES_CONFIGURE_ENV_OFF= XSLTPROC="true"
+MANPAGES_BUILD_DEPENDS= ${LOCALBASE}/share/xsl/docbook/manpages/docbook.xsl:textproc/docbook-xsl \
+ xsltproc:textproc/libxslt
+# No fancy color error messages
+CFLAGS+= ${CFLAGS_${CHOSEN_COMPILER_TYPE}}
+CFLAGS_clang= -fno-color-diagnostics
+CONFIGURE_ENV+= NOCOLOR=yes
+MAKE_ENV+= NOCOLOR=yes
+# Some symbols in tevent's linker version scripts are not defined, but since the
+# scripts are generated dynamically, suppress errors with lld >= 17 due to these
+# undefined symbols.
+LDFLAGS+= -Wl,--undefined-version
+
+post-patch:
+ @${REINPLACE_CMD} -e 's|%%PKGCONFIGDIR%%|${PKGCONFIGDIR}|g' \
+ ${BUILD_WRKSRC}/wscript
+
+post-install:
+ ${RM} ${STAGEDIR}${PREFIX}/lib/tevent/libcmocka-tevent.so
+ ${RM} ${STAGEDIR}${PREFIX}/lib/tevent/libpytalloc-util.cpython-${PYTHON_SUFFIX}-tevent.so
+ ${RMDIR} ${STAGEDIR}${PREFIX}/lib/tevent
+ ${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/libtevent.so
+
+post-install-PYTHON-on:
+ ${STRIP_CMD} ${STAGEDIR}${PYTHONPREFIX_SITELIBDIR}/_tevent*.so
+ ${PYTHON_CMD} -m compileall -d ${PYTHON_SITELIBDIR} ${STAGEDIR}${PYTHON_SITELIBDIR}
+
+.include <bsd.port.mk>
diff --git a/devel/tevent016/distinfo b/devel/tevent016/distinfo
new file mode 100644
index 000000000000..56e4d3c17266
--- /dev/null
+++ b/devel/tevent016/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1722344186
+SHA256 (tevent-0.15.0.tar.gz) = 662a9f277281bcf506b6bc0a0baa03e44a62229516ee34bcc703a0b82aa46905
+SIZE (tevent-0.15.0.tar.gz) = 884634
diff --git a/devel/tevent016/files/patch-buildtools_wafsamba_samba__autoconf.py b/devel/tevent016/files/patch-buildtools_wafsamba_samba__autoconf.py
new file mode 100644
index 000000000000..c5db6dc61150
--- /dev/null
+++ b/devel/tevent016/files/patch-buildtools_wafsamba_samba__autoconf.py
@@ -0,0 +1,35 @@
+--- buildtools/wafsamba/samba_autoconf.py.orig 2019-09-04 15:42:16 UTC
++++ buildtools/wafsamba/samba_autoconf.py
+@@ -573,7 +573,7 @@ def library_flags(self, libs):
+
+
+ @conf
+-def CHECK_LIB(conf, libs, mandatory=False, empty_decl=True, set_target=True, shlib=False):
++def CHECK_LIB(conf, libs, mandatory=False, empty_decl=True, set_target=True, shlib=False, msg=None):
+ '''check if a set of libraries exist as system libraries
+
+ returns the sublist of libs that do exist as a syslib or []
+@@ -593,11 +593,14 @@ int foo()
+ ret.append(lib)
+ continue
+
++ if msg is None:
++ msg = 'Checking for library %s' % lib
++
+ (ccflags, ldflags, cpppath) = library_flags(conf, lib)
+ if shlib:
+- res = conf.check(features='c cshlib', fragment=fragment, lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False)
++ res = conf.check(features='c cshlib', fragment=fragment, lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False, msg=msg)
+ else:
+- res = conf.check(lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False)
++ res = conf.check(lib=lib, uselib_store=lib, cflags=ccflags, ldflags=ldflags, uselib=lib.upper(), mandatory=False, msg=msg)
+
+ if not res:
+ if mandatory:
+@@ -949,5 +952,5 @@ def SAMBA_CHECK_UNDEFINED_SYMBOL_FLAGS(conf):
+ conf.env.undefined_ldflags = conf.ADD_LDFLAGS('-Wl,-no-undefined', testflags=True)
+
+ if (conf.env.undefined_ignore_ldflags == [] and
+- conf.CHECK_LDFLAGS(['-undefined', 'dynamic_lookup'])):
++ conf.CHECK_LDFLAGS(['-undefined', 'dynamic_lookup'] + conf.env.WERROR_CFLAGS)):
+ conf.env.undefined_ignore_ldflags = ['-undefined', 'dynamic_lookup']
diff --git a/devel/tevent016/files/patch-buildtools_wafsamba_samba__install.py b/devel/tevent016/files/patch-buildtools_wafsamba_samba__install.py
new file mode 100644
index 000000000000..5a85a034aea7
--- /dev/null
+++ b/devel/tevent016/files/patch-buildtools_wafsamba_samba__install.py
@@ -0,0 +1,11 @@
+--- buildtools/wafsamba/samba_install.py.orig 2019-03-21 10:12:32 UTC
++++ buildtools/wafsamba/samba_install.py
+@@ -115,7 +115,7 @@ def install_library(self):
+ inst_name = bld.make_libname(t.target)
+ elif self.vnum:
+ vnum_base = self.vnum.split('.')[0]
+- install_name = bld.make_libname(target_name, version=self.vnum)
++ install_name = bld.make_libname(target_name, version=vnum_base)
+ install_link = bld.make_libname(target_name, version=vnum_base)
+ inst_name = bld.make_libname(t.target)
+ if not self.private_library or not t.env.SONAME_ST:
diff --git a/devel/tevent016/files/patch-buildtools_wafsamba_wscript b/devel/tevent016/files/patch-buildtools_wafsamba_wscript
new file mode 100644
index 000000000000..3d4b6a56e345
--- /dev/null
+++ b/devel/tevent016/files/patch-buildtools_wafsamba_wscript
@@ -0,0 +1,15 @@
+--- buildtools/wafsamba/wscript.orig 2019-03-21 10:12:32 UTC
++++ buildtools/wafsamba/wscript
+@@ -82,10 +82,10 @@ def options(opt):
+
+ opt.add_option('--with-libiconv',
+ help='additional directory to search for libiconv',
+- action='store', dest='iconv_open', default='/usr/local',
++ action='store', dest='iconv_open', default=None,
+ match = ['Checking for library iconv', 'Checking for iconv_open', 'Checking for header iconv.h'])
+ opt.add_option('--without-gettext',
+- help=("Disable use of gettext"),
++ help=("disable use of gettext"),
+ action="store_true", dest='disable_gettext', default=False)
+
+ gr = opt.option_group('developer options')
diff --git a/devel/tevent016/files/patch-lib_replace_wscript b/devel/tevent016/files/patch-lib_replace_wscript
new file mode 100644
index 000000000000..d476cec47cfb
--- /dev/null
+++ b/devel/tevent016/files/patch-lib_replace_wscript
@@ -0,0 +1,11 @@
+--- lib/replace/wscript.orig 2019-03-21 10:12:32 UTC
++++ lib/replace/wscript
+@@ -119,7 +119,7 @@ def configure(conf):
+ conf.CHECK_HEADERS('sys/atomic.h stdatomic.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')
+
+ if conf.CHECK_CFLAGS('-Wno-unused-function'):
diff --git a/devel/tevent016/files/patch-wscript b/devel/tevent016/files/patch-wscript
new file mode 100644
index 000000000000..b17d04a3f874
--- /dev/null
+++ b/devel/tevent016/files/patch-wscript
@@ -0,0 +1,11 @@
+--- wscript.orig 2017-07-22 22:25:22 UTC
++++ wscript
+@@ -88,7 +88,7 @@ def build(bld):
+ SRC += ' tevent_port.c'
+
+ if bld.env.standalone_tevent:
+- bld.env.PKGCONFIGDIR = '${LIBDIR}/pkgconfig'
++ bld.env.PKGCONFIGDIR = '%%PKGCONFIGDIR%%'
+ private_library = False
+ else:
+ private_library = True
diff --git a/devel/tevent016/pkg-descr b/devel/tevent016/pkg-descr
new file mode 100644
index 000000000000..0b31d18127a1
--- /dev/null
+++ b/devel/tevent016/pkg-descr
@@ -0,0 +1,6 @@
+tevent is a simple library that can handle the main event loop for an
+application. It supports three kinds of events: timed events, file
+descriptors becoming readable or writable and signals.
+
+Talloc is used for memory management, both internally and for private
+data provided by users of the library.
diff --git a/devel/tevent016/pkg-plist b/devel/tevent016/pkg-plist
new file mode 100644
index 000000000000..bf60cf03f8ed
--- /dev/null
+++ b/devel/tevent016/pkg-plist
@@ -0,0 +1,7 @@
+include/tevent.h
+lib/libtevent.so
+lib/libtevent.so.0
+%%PYTHON%%%%PYTHON_SITELIBDIR%%/__pycache__/tevent.cpython-%%PYTHON_SUFFIX%%.pyc
+%%PYTHON%%%%PYTHON_SITELIBDIR%%/_tevent%%PYTHON_EXT_SUFFIX%%.so
+%%PYTHON%%%%PYTHON_SITELIBDIR%%/tevent.py
+%%PKGCONFIGDIR%%/tevent.pc