Skip to content

Commit

Permalink
devel/libevent-devel: new port had been copied from `devel/libevent'
Browse files Browse the repository at this point in the history
Current stable release is nearly three years old and lacks a number
of new features and performance improvements.

A fortnight ago, upstream had tagged pre-release 2.2.1-alpha, which
this port offers to early adopters.
  • Loading branch information
Alexey Dokuchaev authored and Alexey Dokuchaev committed Jun 5, 2023
1 parent d4fa0e3 commit ae7f77b
Show file tree
Hide file tree
Showing 6 changed files with 154 additions and 0 deletions.
1 change: 1 addition & 0 deletions devel/Makefile
Expand Up @@ -1222,6 +1222,7 @@
SUBDIR += libevdev
SUBDIR += libevdevplus
SUBDIR += libevent
SUBDIR += libevent-devel
SUBDIR += libevt
SUBDIR += libevtx
SUBDIR += libewf
Expand Down
38 changes: 38 additions & 0 deletions devel/libevent-devel/Makefile
@@ -0,0 +1,38 @@
PORTNAME= libevent
DISTVERSION= 2.2.1
DISTVERSIONSUFFIX= -alpha-dev
CATEGORIES= devel
MASTER_SITES= https://github.com/${PORTNAME}/${PORTNAME}/releases/download/release-${DISTVERSION}${DISTVERSIONSUFFIX}/
PKGNAMESUFFIX= -devel

MAINTAINER= kbowling@FreeBSD.org
COMMENT= API for executing callback functions on events or timeouts
WWW= https://libevent.org/

LICENSE= BSD3CLAUSE
LICENSE_FILE= ${WRKSRC}/LICENSE

USES= cpe libtool pathfix pkgconfig python:env shebangfix
SHEBANG_FILES= event_rpcgen.py
GNU_CONFIGURE= yes
CPE_VENDOR= libevent_project
INSTALL_TARGET= install-strip
TEST_TARGET= check
USE_LDCONFIG= yes

CONFLICTS_INSTALL= ${PORTNAME}

OPTIONS_DEFINE= OPENSSL THREADS MBEDTLS
OPTIONS_DEFAULT= OPENSSL THREADS
OPTIONS_SUB= yes

MBEDTLS_LIB_DEPENDS= libmbedtls.so:security/mbedtls
MBEDTLS_USES= localbase:ldflags
MBEDTLS_CONFIGURE_OFF= --disable-mbedtls

OPENSSL_USES= ssl
OPENSSL_CONFIGURE_OFF= --disable-openssl

THREADS_CONFIGURE_OFF= --disable-thread-support

.include <bsd.port.mk>
3 changes: 3 additions & 0 deletions devel/libevent-devel/distinfo
@@ -0,0 +1,3 @@
TIMESTAMP = 1684653125
SHA256 (libevent-2.2.1-alpha-dev.tar.gz) = 36d0726e570fc2ee61a0a27cfb6bf2799e14a28d030a7473a7a2411f7533d359
SIZE (libevent-2.2.1-alpha-dev.tar.gz) = 1166550
32 changes: 32 additions & 0 deletions devel/libevent-devel/files/patch-test_test.sh
@@ -0,0 +1,32 @@
regress runs multiple tests, don't silence it completely.
https://github.com/libevent/libevent/pull/446
--- test/test.sh.orig 2017-01-25 23:37:15 UTC
+++ test/test.sh
@@ -99,10 +99,10 @@ run_tests () {
fi
test -x $TEST_DIR/regress || return
- announce_n " regress: "
+ announce " regress: [multiple tests]"
if test "$TEST_OUTPUT_FILE" = "/dev/null" ;
then
- $TEST_DIR/regress --quiet $REGRESS_ARGS
+ $TEST_DIR/regress $REGRESS_ARGS
else
$TEST_DIR/regress $REGRESS_ARGS >>"$TEST_OUTPUT_FILE"
fi
@@ -114,10 +114,10 @@ run_tests () {
FAILED=yes
fi
- announce_n " regress_debug: "
+ announce " regress_debug: [multiple tests]"
if test "$TEST_OUTPUT_FILE" = "/dev/null" ;
then
- EVENT_DEBUG_MODE=1 $TEST_DIR/regress --quiet $REGRESS_ARGS
+ EVENT_DEBUG_MODE=1 $TEST_DIR/regress $REGRESS_ARGS
else
EVENT_DEBUG_MODE=1 $TEST_DIR/regress $REGRESS_ARGS >>"$TEST_OUTPUT_FILE"
fi
16 changes: 16 additions & 0 deletions devel/libevent-devel/pkg-descr
@@ -0,0 +1,16 @@
The libevent API provides a mechanism to execute a callback function when
a specific event occurs on a file descriptor or after a timeout has been
reached. Furthermore, libevent also support callbacks due to signals or
regular timeouts.

libevent is meant to replace the event loop found in event driven network
servers. An application just needs to call event_dispatch() and then add
or remove events dynamically without having to change the event loop.

Currently, libevent supports /dev/poll, kqueue(2), event ports, select(2),
poll(2) and epoll(4). The internal event mechanism is completely independent
of the exposed event API, and a simple update of libevent can provide new
functionality without having to redesign the applications. As a result,
Libevent allows for portable application development and provides the most
scalable event notification mechanism available on an operating system.
Libevent can also be used for multi-threaded applications.
64 changes: 64 additions & 0 deletions devel/libevent-devel/pkg-plist
@@ -0,0 +1,64 @@
bin/event_rpcgen.py
include/evdns.h
include/event.h
include/event2/buffer.h
include/event2/buffer_compat.h
include/event2/bufferevent.h
include/event2/bufferevent_compat.h
%%OPENSSL%%include/event2/bufferevent_ssl.h
include/event2/bufferevent_struct.h
include/event2/dns.h
include/event2/dns_compat.h
include/event2/dns_struct.h
include/event2/event-config.h
include/event2/event.h
include/event2/event_compat.h
include/event2/event_struct.h
include/event2/http.h
include/event2/http_compat.h
include/event2/http_struct.h
include/event2/keyvalq_struct.h
include/event2/listener.h
include/event2/rpc.h
include/event2/rpc_compat.h
include/event2/rpc_struct.h
include/event2/tag.h
include/event2/tag_compat.h
include/event2/thread.h
include/event2/util.h
include/event2/visibility.h
include/event2/watch.h
include/event2/ws.h
include/evhttp.h
include/evrpc.h
include/evutil.h
lib/libevent-2.2.so.1
lib/libevent-2.2.so.1.0.0
lib/libevent.a
lib/libevent.so
lib/libevent_core-2.2.so.1
lib/libevent_core-2.2.so.1.0.0
lib/libevent_core.a
lib/libevent_core.so
lib/libevent_extra-2.2.so.1
lib/libevent_extra-2.2.so.1.0.0
lib/libevent_extra.a
lib/libevent_extra.so
%%MBEDTLS%%lib/libevent_mbedtls-2.2.so.1
%%MBEDTLS%%lib/libevent_mbedtls-2.2.so.1.0.0
%%MBEDTLS%%lib/libevent_mbedtls.a
%%MBEDTLS%%lib/libevent_mbedtls.so
%%OPENSSL%%lib/libevent_openssl-2.2.so.1
%%OPENSSL%%lib/libevent_openssl-2.2.so.1.0.0
%%OPENSSL%%lib/libevent_openssl.a
%%OPENSSL%%lib/libevent_openssl.so
%%THREADS%%lib/libevent_pthreads-2.2.so.1
%%THREADS%%lib/libevent_pthreads-2.2.so.1.0.0
%%THREADS%%lib/libevent_pthreads.a
%%THREADS%%lib/libevent_pthreads.so
libdata/pkgconfig/libevent.pc
libdata/pkgconfig/libevent_core.pc
libdata/pkgconfig/libevent_extra.pc
%%MBEDTLS%%libdata/pkgconfig/libevent_mbedtls.pc
%%OPENSSL%%libdata/pkgconfig/libevent_openssl.pc
%%THREADS%%libdata/pkgconfig/libevent_pthreads.pc

0 comments on commit ae7f77b

Please sign in to comment.