libevent: update for stx 5.0 71/8271/1
authorJackie Huang <jackie.huang@windriver.com>
Tue, 22 Jun 2021 08:19:56 +0000 (16:19 +0800)
committerJackie Huang <jackie.huang@windriver.com>
Thu, 12 May 2022 13:45:00 +0000 (21:45 +0800)
* inherit stx-metadata to help apply updated patches
  from stx 'integ' repo

* remove the local copy of stx patches

Issue-ID: INF-215

Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
Change-Id: I3c998fde3a73903faf802a074ea82c6b58d1dd64

meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/disable_tests.patch [deleted file]
meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/libevent-ipv6-client-socket.patch [deleted file]
meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/obsolete_automake_macros.patch [deleted file]
meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent_2.0.21.bb

diff --git a/meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/disable_tests.patch b/meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/disable_tests.patch
deleted file mode 100644 (file)
index 5d2c690..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Inappropriate [disable feature]
-
-Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
-diff -Nurd libevent-2.0.21-stable/test/Makefile.am libevent-2.0.21-stable/test/Makefile.am
---- libevent-2.0.21-stable/test/Makefile.am    2012-05-31 07:08:19.000000000 +0300
-+++ libevent-2.0.21-stable/test/Makefile.am    2013-02-08 02:06:20.227475872 +0200
-@@ -19,8 +19,6 @@
- EXTRA_PROGRAMS = regress
- noinst_HEADERS = tinytest.h tinytest_macros.h regress.h tinytest_local.h
-
--TESTS = $(top_srcdir)/test/test.sh
--
- BUILT_SOURCES =
- if BUILD_REGRESS
- BUILT_SOURCES += regress.gen.c regress.gen.h
diff --git a/meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/libevent-ipv6-client-socket.patch b/meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/libevent-ipv6-client-socket.patch
deleted file mode 100644 (file)
index 7115f30..0000000
+++ /dev/null
@@ -1,60 +0,0 @@
-Upstream-Status: Inappropriate [1]
-
-[1] ported from libevent-2.0.21-4.el7.tis.2.src.rpm
-
-Signed-off-by: Jackie Huang <jackie.huang@windriver.com>
----
- http.c |   25 ++++++++++++++++++-------
- 1 file changed, 18 insertions(+), 7 deletions(-)
-
---- a/http.c
-+++ b/http.c
-@@ -1325,6 +1325,9 @@ evhttp_error_cb(struct bufferevent *bufe
-       struct evhttp_connection *evcon = arg;
-       struct evhttp_request *req = TAILQ_FIRST(&evcon->requests);
-
-+      if (evcon->fd == -1)
-+              evcon->fd = bufferevent_getfd(bufev);
-+
-       switch (evcon->state) {
-       case EVCON_CONNECTING:
-               if (what & BEV_EVENT_TIMEOUT) {
-@@ -1390,6 +1393,9 @@ evhttp_connection_cb(struct bufferevent
-       int error;
-       ev_socklen_t errsz = sizeof(error);
-
-+      if (evcon->fd == -1)
-+              evcon->fd = bufferevent_getfd(bufev);
-+
-       if (!(what & BEV_EVENT_CONNECTED)) {
-               /* some operating systems return ECONNREFUSED immediately
-                * when connecting to a local address.  the cleanup is going
-@@ -2189,16 +2195,21 @@ evhttp_connection_connect(struct evhttp_
-       EVUTIL_ASSERT(!(evcon->flags & EVHTTP_CON_INCOMING));
-       evcon->flags |= EVHTTP_CON_OUTGOING;
-
--      evcon->fd = bind_socket(
--              evcon->bind_address, evcon->bind_port, 0 /*reuse*/);
--      if (evcon->fd == -1) {
--              event_debug(("%s: failed to bind to \"%s\"",
--                      __func__, evcon->bind_address));
--              return (-1);
-+      if (evcon->bind_address || evcon->bind_port) {
-+              evcon->fd = bind_socket(
-+                      evcon->bind_address, evcon->bind_port, 0 /*reuse*/);
-+              if (evcon->fd == -1) {
-+                      event_debug(("%s: failed to bind to \"%s\"",
-+                              __func__, evcon->bind_address));
-+                      return (-1);
-+              }
-+
-+              bufferevent_setfd(evcon->bufev, evcon->fd);
-+      } else {
-+              bufferevent_setfd(evcon->bufev, -1);
-       }
-
-       /* Set up a callback for successful connection setup */
--      bufferevent_setfd(evcon->bufev, evcon->fd);
-       bufferevent_setcb(evcon->bufev,
-           NULL /* evhttp_read_cb */,
-           NULL /* evhttp_write_cb */,
diff --git a/meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/obsolete_automake_macros.patch b/meta-starlingx/meta-stx-integ/recipes-support/libevent/libevent/obsolete_automake_macros.patch
deleted file mode 100644 (file)
index b559232..0000000
+++ /dev/null
@@ -1,15 +0,0 @@
-Upstream-Status: Submitted [https://sourceforge.net/tracker/?func=detail&aid=3603774&group_id=50884&atid=461322]
-
-Signed-off-by: Marko Lindqvist <cazfi74@gmail.com>
-diff -Nurd libevent-2.0.21-stable/configure.in libevent-2.0.21-stable/configure.in
---- libevent-2.0.21-stable/configure.in        2012-11-18 08:34:13.000000000 +0200
-+++ libevent-2.0.21-stable/configure.in        2013-02-08 02:03:58.403476183 +0200
-@@ -12,7 +12,7 @@
- AC_CONFIG_MACRO_DIR([m4])
-
- AM_INIT_AUTOMAKE(libevent,2.0.21-stable)
--AM_CONFIG_HEADER(config.h)
-+AC_CONFIG_HEADERS(config.h)
- AC_DEFINE(NUMERIC_VERSION, 0x02001500, [Numeric representation of the version])
-
- dnl Initialize prefix.
index 332e12d..fb1a13d 100644 (file)
@@ -6,10 +6,18 @@ SECTION = "libs"
 LICENSE = "BSD"
 LIC_FILES_CHKSUM = "file://LICENSE;md5=45c5316ff684bcfe2f9f86d8b1279559"
 
+inherit stx-metadata
+
+STX_REPO = "integ"
+STX_SUBPATH = "base/libevent/files"
+
 SRC_URI = " \
     https://github.com/downloads/libevent/libevent/${BP}-stable.tar.gz \
     file://libevent-obsolete_automake_macros.patch \
     file://libevent-disable_tests.patch \
+"
+
+SRC_URI_STX = " \
     file://libevent-ipv6-client-socket.patch \
 "