summaryrefslogtreecommitdiff
path: root/devel/pth
diff options
context:
space:
mode:
authorwiz <wiz@pkgsrc.org>2007-02-18 11:40:09 +0000
committerwiz <wiz@pkgsrc.org>2007-02-18 11:40:09 +0000
commitcdb2653a2f854a64d25099b44ad1114fa6fda28e (patch)
tree54b5c1fdd4a643628e6bc5eb48f4e555a92b84a5 /devel/pth
parent2145bb9e2e346d10ca34f40d7ec3718b34243394 (diff)
downloadpkgsrc-cdb2653a2f854a64d25099b44ad1114fa6fda28e.tar.gz
Update to 2.0.7:
Changes between 2.0.6 and 2.0.7 (22-Nov-2005 to 08-Jun-2006) *) Let AC_CHECK_PTH use "pth-config --libs --all" instead of just "pth-config --libs" to allow it to work under platforms like Solaris where additional libraries are required. [Ralf S. Engelschall] Changes between 2.0.5 and 2.0.6 (05-Oct-2005 to 22-Nov-2005) *) Add a missing "break" in pth_attr.c:pth_attr_ctrl(). [Stefan Schippers <stefan@schippers.it>] *) Return an error if pth_kill() is called before pth_init(). [Martin Kraemer <Martin.Kraemer@Fujitsu-Siemens.com>] Changes between 2.0.3 and 2.0.4 (03-Dec-2004 to 18-Feb-2005) *) Fix internal determination of maximum number in a size_t in the string formatter engine. [Ralf S. Engelschall] *) Add quotes around function names for AC_DEFUN in pth.m4 to avoid warnings about "underquoted definitions". [Stephane Loeuillet <stephane.loeuillet@cegetel.net>] *) Do not insist on writing to the source directory on "make install" in order to more closely follow GNU standards. [Bruno Haible <bruno@clisp.org>] *) Remove "*.bak" and "*~" files under "make distclean" instead of "make clean". [Bruno Haible <bruno@clisp.org>] Changes between 2.0.2 and 2.0.3 (12-Sep-2004 to 03-Dec-2004) *) Resurrect the old "make striptease" command by fixing the configure run-time in the stripped down source tree and fixing the list of source files. [Ralf S. Engelschall] *) The pth_uctx_save() and pth_uctx_restore() API functions unfortunately were broken by design because they are C _functions_. This leads to one more deadly nesting on the run-time stack which effectively caused the pth_mctx_restore() in pth_uctx_restore() to return to the end of pth_uctx_save() but then the control flow unfortunately returns to the pth_uctx_restore() caller instead of the pth_uctx_save() caller because the call to pth_uctx_restore() had already overwritten the run-time stack position where the original return address for the pth_uctx_save() call was stored. The only workaround would be to #define pth_uctx_save() and pth_uctx_restore() as C _macros_, but this then would require that lots of the GNU Pth internals from pth_mctx.c would have to be exported in the GNU Pth API (which in turn is not acceptable). So, the only consequence is to remove the two functions again from the GNU Pth API. [Ralf S. Engelschall, Stefan Brantschen <sbr@acm.org>] *) Enhance internal pth_mctx_save() if getcontext(3) is used for the machine context saving by better emulating the setjmp(3) style return code semantics. [Ralf S. Engelschall] *) Do not break in pth_msgport_find() if a message port was created with a NULL name. [Ralf S. Engelschall] *) Better error checking in pth_key_xxx() functions. [Ralf S. Engelschall] *) Added PTH_CTRL_FAVOURNEW control which allows the user to disable the favouring of new threads on scheduling to get more strict priority based scheduling behavior. [Ralf S. Engelschall, Vinu V <Vinu_V@mindtree.com>] Changes between 2.0.1 and 2.0.2 (13-Jul-2004 to 12-Sep-2004) *) Added hard syscall wrappers for send(2) and recv(2). [NetBSD pkgsrc patches] *) Internally handle errors returned from pth_event() in order to pass them upstream to the caller in pth_high.c functions. [Ralf S. Engelschall, NetBSD pkgsrc patches] *) Fix syscall wrapper for sendto(2). [NetBSD pkgsrc patches] *) Use "(char *)NULL" instead of plain "NULL" in last argument to execl(2) to avoid GCC 3.5's "warning: missing sentinel in function call". [Ralf S. Engelschall] *) Workaround Autoconf/m4 problems in pth.m4 by using "m4_define" instead of just "define" and no using m4_undefine at all. [Dr. Andreas Mueller <afm@othello.ch>] *) Avoid side-effects by defining _XOPEN_SOURCE only temporarily for inclusion of <poll.h> instead of permanently. [Graham Nash <gnash@ncube.com>] *) Workaround GCC 2.x and 3.5 (3.4 worked fine) macro parsing behaviour by using a pre-declared function pointer type "typedef int (*pth_event_func_t)(void *);" instead of using an inlined "int (*)(void *)". [Ralf S. Engelschall, Robert Anderson <RWA@sbcglobal.net>] *) Fixed prototype for pthread_attr_setschedparam(3) from to use a "const struct sched_param *" argument. [Rafael Ávila de Espíndola <rafael.espindola@ic.unicamp.br>] Changes between 2.0.0 and 2.0.1 (17-Feb-2003 to 13-Jul-2004) *) Fix handling/casting of "int (*)(void *)" callback functions. [Ralf S. Engelschall] *) Resolve symbol conflict in pth_string.c between pow10/round and GCC builtins. [Ralf S. Engelschall] *) Use GCC 3.3 option "-fno-strict-aliasing" (if available) under Autoconf option "--enable-debug" because mainly pth_mctx.c contains important and correct pointer casting constructs which are not acceptable in "strict aliasing" for GCC. [Ralf S. Engelschall] *) Fixed implementation so that --enable-pthread now correctly implies --enable-syscall-soft. [Steve Alstrin <Steve.Alstrin@NetIQ.com>, Ralf S. Engelschall] *) Replace some 0 by more politically correct NULL in pth_string.c [Ralf S. Engelschall]
Diffstat (limited to 'devel/pth')
-rw-r--r--devel/pth/Makefile5
-rw-r--r--devel/pth/distinfo20
-rw-r--r--devel/pth/patches/patch-ab18
-rw-r--r--devel/pth/patches/patch-ac20
-rw-r--r--devel/pth/patches/patch-ad75
-rw-r--r--devel/pth/patches/patch-ae10
-rw-r--r--devel/pth/patches/patch-af17
-rw-r--r--devel/pth/patches/patch-ag6
8 files changed, 55 insertions, 116 deletions
diff --git a/devel/pth/Makefile b/devel/pth/Makefile
index 59758054a55..5e74b2396d6 100644
--- a/devel/pth/Makefile
+++ b/devel/pth/Makefile
@@ -1,8 +1,7 @@
-# $NetBSD: Makefile,v 1.68 2006/03/04 21:29:26 jlam Exp $
+# $NetBSD: Makefile,v 1.69 2007/02/18 11:40:09 wiz Exp $
#
-DISTNAME= pth-2.0.0
-PKGREVISION= 2
+DISTNAME= pth-2.0.7
CATEGORIES= devel
MASTER_SITES= ${MASTER_SITE_GNU:=pth/}
diff --git a/devel/pth/distinfo b/devel/pth/distinfo
index de78ce86514..66758b4187b 100644
--- a/devel/pth/distinfo
+++ b/devel/pth/distinfo
@@ -1,12 +1,12 @@
-$NetBSD: distinfo,v 1.14 2005/02/23 22:24:31 agc Exp $
+$NetBSD: distinfo,v 1.15 2007/02/18 11:40:10 wiz Exp $
-SHA1 (pth-2.0.0.tar.gz) = 91b7593e5435604090c3974a8584478877194533
-RMD160 (pth-2.0.0.tar.gz) = 315dbaa1639d18011cf3cfb50a3790e8325d501e
-Size (pth-2.0.0.tar.gz) = 536605 bytes
-SHA1 (patch-ab) = d320382a2b9e77ea7b370b3f2078df26c960ff65
-SHA1 (patch-ac) = 44ce534ede37844cf783982df7d1248f19d2c48f
-SHA1 (patch-ad) = 18bb009f47e525467b5a665e02c3e7af2a47dbeb
-SHA1 (patch-ae) = 018d915157250da6b10ac7a5d51a82d5564744fe
-SHA1 (patch-af) = 52389585d900f39e83b3535ada2d32081552a918
-SHA1 (patch-ag) = 44108eddea2a672572646534a53dd0828b704108
+SHA1 (pth-2.0.7.tar.gz) = 9a71915c89ff2414de69fe104ae1016d513afeee
+RMD160 (pth-2.0.7.tar.gz) = 80bc66777ba20d9648b7aaf3f58d593be6416910
+Size (pth-2.0.7.tar.gz) = 652640 bytes
+SHA1 (patch-ab) = 8495e25d31dadc9f0b56e48950eecf3e895a9f30
+SHA1 (patch-ac) = 1da404fb28ebf9cf012988ffa5f21a18e5c92983
+SHA1 (patch-ad) = e93bd19c9f66e78d5d91dcb9dd3096bdc5d5b092
+SHA1 (patch-ae) = 97e9546ce894a100b889dfacbd19e6c1cc1de87f
+SHA1 (patch-af) = 13aba228b9e8d8bedeac4018073c4fa5b3652caf
+SHA1 (patch-ag) = 66ba441a4efc85af4ef498d846d7ebc1115f3dcc
SHA1 (patch-aj) = f155cac115446efce191b859d92900d1ea3bc44b
diff --git a/devel/pth/patches/patch-ab b/devel/pth/patches/patch-ab
index a2f8e9d71e6..5aac0d3fa19 100644
--- a/devel/pth/patches/patch-ab
+++ b/devel/pth/patches/patch-ab
@@ -1,17 +1,17 @@
-$NetBSD: patch-ab,v 1.15 2003/05/02 11:49:48 wiz Exp $
+$NetBSD: patch-ab,v 1.16 2007/02/18 11:40:10 wiz Exp $
---- configure.orig Mon Feb 17 10:53:15 2003
+--- configure.orig 2006-06-08 18:14:48.000000000 +0000
+++ configure
-@@ -543,7 +543,7 @@ ac_includes_default="\
+@@ -539,7 +539,7 @@ ac_includes_default="\
# include <unistd.h>
#endif"
--ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS srcdir_prefix PTH_VERSION_STR PTH_VERSION_HEX PLATFORM CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP SET_MAKE build build_cpu build_vendor build_os host host_cpu host_vendor host_os LN_S ECHO RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP EGREP LIBTOOL AR PTH_FDSETSIZE PTH_FAKE_POLL PTH_FAKE_RWV EXTRA_INCLUDE_SYS_SELECT_H FALLBACK_SIG_ATOMIC_T FALLBACK_PID_T FALLBACK_SIZE_T FALLBACK_SSIZE_T FALLBACK_OFF_T FALLBACK_SOCKLEN_T FALLBACK_NFDS_T PTH_STACK_GROWTH pth_skaddr_makecontext pth_sksize_makecontext pth_skaddr_sigaltstack pth_sksize_sigaltstack pth_skaddr_sigstack pth_sksize_sigstack pth_sigjmpbuf pth_sigsetjmp pth_siglongjmp PTH_MCTX_ID PTH_SYSCALL_SOFT PTH_SYSCALL_HARD BATCH TARGET_ALL PTHREAD_O LIBPTHREAD_A LIBPTHREAD_LA PTHREAD_CONFIG_1 PTHREAD_3 INSTALL_PTHREAD UNINSTALL_PTHREAD TEST_PTHREAD PTH_EXT_SFIO LIBOBJS LTLIBOBJS'
-+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS srcdir_prefix PTH_VERSION_STR PTH_VERSION_HEX PLATFORM CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP SET_MAKE build build_cpu build_vendor build_os host host_cpu host_vendor host_os LN_S ECHO RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP EGREP LIBTOOL AR PTH_FDSETSIZE PTH_FAKE_POLL PTH_FAKE_RWV EXTRA_INCLUDE_SYS_SELECT_H EXTRA_INCLUDE_SYS_RESOURCE_H FALLBACK_SIG_ATOMIC_T FALLBACK_PID_T FALLBACK_SIZE_T FALLBACK_SSIZE_T FALLBACK_OFF_T FALLBACK_SOCKLEN_T FALLBACK_NFDS_T PTH_STACK_GROWTH pth_skaddr_makecontext pth_sksize_makecontext pth_skaddr_sigaltstack pth_sksize_sigaltstack pth_skaddr_sigstack pth_sksize_sigstack pth_sigjmpbuf pth_sigsetjmp pth_siglongjmp PTH_MCTX_ID PTH_SYSCALL_SOFT PTH_SYSCALL_HARD BATCH TARGET_ALL PTHREAD_O LIBPTHREAD_A LIBPTHREAD_LA PTHREAD_CONFIG_1 PTHREAD_3 INSTALL_PTHREAD UNINSTALL_PTHREAD TEST_PTHREAD PTH_EXT_SFIO LIBOBJS LTLIBOBJS'
+-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS srcdir_prefix PTH_VERSION_STR PTH_VERSION_HEX PLATFORM CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP SET_MAKE build build_cpu build_vendor build_os host host_cpu host_vendor host_os LN_S ECHO AR ac_ct_AR RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP CXX CXXFLAGS ac_ct_CXX CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL PTH_FDSETSIZE PTH_FAKE_POLL PTH_FAKE_RWV EXTRA_INCLUDE_SYS_SELECT_H FALLBACK_SIG_ATOMIC_T FALLBACK_PID_T FALLBACK_SIZE_T FALLBACK_SSIZE_T FALLBACK_OFF_T FALLBACK_SOCKLEN_T FALLBACK_NFDS_T PTH_STACK_GROWTH pth_skaddr_makecontext pth_sksize_makecontext pth_skaddr_sigaltstack pth_sksize_sigaltstack pth_skaddr_sigstack pth_sksize_sigstack pth_sigjmpbuf pth_sigsetjmp pth_siglongjmp PTH_MCTX_ID PTH_SYSCALL_SOFT PTH_SYSCALL_HARD BATCH TARGET_ALL PTHREAD_O LIBPTHREAD_A LIBPTHREAD_LA PTHREAD_CONFIG_1 PTHREAD_3 INSTALL_PTHREAD UNINSTALL_PTHREAD TEST_PTHREAD PTH_EXT_SFIO LIBOBJS LTLIBOBJS'
++ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS srcdir_prefix PTH_VERSION_STR PTH_VERSION_HEX PLATFORM CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT CPP EGREP SET_MAKE build build_cpu build_vendor build_os host host_cpu host_vendor host_os LN_S ECHO AR ac_ct_AR RANLIB ac_ct_RANLIB STRIP ac_ct_STRIP CXX CXXFLAGS ac_ct_CXX CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL PTH_FDSETSIZE PTH_FAKE_POLL PTH_FAKE_RWV EXTRA_INCLUDE_SYS_SELECT_H EXTRA_INCLUDE_SYS_RESOURCE_H FALLBACK_SIG_ATOMIC_T FALLBACK_PID_T FALLBACK_SIZE_T FALLBACK_SSIZE_T FALLBACK_OFF_T FALLBACK_SOCKLEN_T FALLBACK_NFDS_T PTH_STACK_GROWTH pth_skaddr_makecontext pth_sksize_makecontext pth_skaddr_sigaltstack pth_sksize_sigaltstack pth_skaddr_sigstack pth_sksize_sigstack pth_sigjmpbuf pth_sigsetjmp pth_siglongjmp PTH_MCTX_ID PTH_SYSCALL_SOFT PTH_SYSCALL_HARD BATCH TARGET_ALL PTHREAD_O LIBPTHREAD_A LIBPTHREAD_LA PTHREAD_CONFIG_1 PTHREAD_3 INSTALL_PTHREAD UNINSTALL_PTHREAD TEST_PTHREAD PTH_EXT_SFIO LIBOBJS LTLIBOBJS'
ac_subst_files=''
# Initialize some variables set by options.
-@@ -9334,8 +9334,7 @@ done
+@@ -20268,8 +20268,7 @@ done
@@ -21,7 +21,7 @@ $NetBSD: patch-ab,v 1.15 2003/05/02 11:49:48 wiz Exp $
do
as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
if eval "test \"\${$as_ac_Header+set}\" = set"; then
-@@ -9820,6 +9819,154 @@ if test ".$ac_cv_header_sys_select_h" !=
+@@ -20800,6 +20799,154 @@ if test ".$ac_cv_header_sys_select_h" !=
fi
@@ -176,7 +176,7 @@ $NetBSD: patch-ab,v 1.15 2003/05/02 11:49:48 wiz Exp $
echo "$as_me:$LINENO: checking for typedef sig_atomic_t" >&5
echo $ECHO_N "checking for typedef sig_atomic_t... $ECHO_C" >&6
if test "${ac_cv_typedef_sig_atomic_t+set}" = set; then
-@@ -13682,6 +13829,7 @@ fi
+@@ -24898,6 +25045,7 @@ fi
@@ -184,7 +184,7 @@ $NetBSD: patch-ab,v 1.15 2003/05/02 11:49:48 wiz Exp $
# Check whether --with-ex or --without-ex was given.
if test "${with_ex+set}" = set; then
withval="$with_ex"
-@@ -15264,6 +15412,7 @@ s,@PTH_FDSETSIZE@,$PTH_FDSETSIZE,;t t
+@@ -26543,6 +26691,7 @@ s,@PTH_FDSETSIZE@,$PTH_FDSETSIZE,;t t
s,@PTH_FAKE_POLL@,$PTH_FAKE_POLL,;t t
s,@PTH_FAKE_RWV@,$PTH_FAKE_RWV,;t t
s,@EXTRA_INCLUDE_SYS_SELECT_H@,$EXTRA_INCLUDE_SYS_SELECT_H,;t t
diff --git a/devel/pth/patches/patch-ac b/devel/pth/patches/patch-ac
index 706968ad195..e0493a84f4d 100644
--- a/devel/pth/patches/patch-ac
+++ b/devel/pth/patches/patch-ac
@@ -1,8 +1,8 @@
-$NetBSD: patch-ac,v 1.5 2003/05/02 11:49:48 wiz Exp $
+$NetBSD: patch-ac,v 1.6 2007/02/18 11:40:10 wiz Exp $
---- pth_high.c.orig Wed Jan 1 15:45:06 2003
+--- pth_high.c.orig 2006-06-08 17:54:03.000000000 +0000
+++ pth_high.c
-@@ -180,6 +180,35 @@ int pth_sigwait_ev(const sigset_t *set,
+@@ -184,6 +184,35 @@ int pth_sigwait_ev(const sigset_t *set,
return 0;
}
@@ -38,7 +38,7 @@ $NetBSD: patch-ac,v 1.5 2003/05/02 11:49:48 wiz Exp $
/* Pth variant of waitpid(2) */
pid_t pth_waitpid(pid_t wpid, int *status, int options)
{
-@@ -330,9 +359,9 @@ int pth_select_ev(int nfd, fd_set *rfds,
+@@ -334,9 +363,9 @@ int pth_select_ev(int nfd, fd_set *rfds,
}
}
/* POSIX.1-2001/SUSv3 compliance */
@@ -51,7 +51,7 @@ $NetBSD: patch-ac,v 1.5 2003/05/02 11:49:48 wiz Exp $
return 0;
}
-@@ -345,17 +374,17 @@ int pth_select_ev(int nfd, fd_set *rfds,
+@@ -349,17 +378,17 @@ int pth_select_ev(int nfd, fd_set *rfds,
delay.tv_usec = 0;
rtmp = NULL;
if (rfds != NULL) {
@@ -72,7 +72,7 @@ $NetBSD: patch-ac,v 1.5 2003/05/02 11:49:48 wiz Exp $
etmp = &espare;
}
while ((rc = pth_sc(select)(nfd, rtmp, wtmp, etmp, &delay)) < 0
-@@ -370,11 +399,11 @@ int pth_select_ev(int nfd, fd_set *rfds,
+@@ -374,11 +403,11 @@ int pth_select_ev(int nfd, fd_set *rfds,
&& pth_time_cmp(timeout, PTH_TIME_ZERO) == 0)) {
/* pass-through immediate success */
if (rfds != NULL)
@@ -87,7 +87,7 @@ $NetBSD: patch-ac,v 1.5 2003/05/02 11:49:48 wiz Exp $
return rc;
}
-@@ -407,9 +436,9 @@ int pth_select_ev(int nfd, fd_set *rfds,
+@@ -411,9 +440,9 @@ int pth_select_ev(int nfd, fd_set *rfds,
&& pth_event_status(ev_timeout) == PTH_STATUS_OCCURRED) {
selected = TRUE;
/* POSIX.1-2001/SUSv3 compliance */
@@ -100,10 +100,10 @@ $NetBSD: patch-ac,v 1.5 2003/05/02 11:49:48 wiz Exp $
rc = 0;
}
if (ev_extra != NULL && !selected)
-@@ -620,6 +649,13 @@ int pth_connect_ev(int s, const struct s
+@@ -624,6 +653,13 @@ int pth_connect_ev(int s, const struct s
/* if it is still on progress wait until socket is really writeable */
if (rv == -1 && errno == EINPROGRESS && fdmode != PTH_FDMODE_NONBLOCK) {
- ev = pth_event(PTH_EVENT_FD|PTH_UNTIL_FD_WRITEABLE|PTH_MODE_STATIC, &ev_key, s);
+ if ((ev = pth_event(PTH_EVENT_FD|PTH_UNTIL_FD_WRITEABLE|PTH_MODE_STATIC, &ev_key, s)) == NULL)
+ /*
+ * This will fail if the fd is > FD_SETSIZE so pass the error back to the
+ * caller.
@@ -111,6 +111,6 @@ $NetBSD: patch-ac,v 1.5 2003/05/02 11:49:48 wiz Exp $
+ if (ev == NULL) {
+ return pth_error(-1, errno);
+ }
+ return pth_error(-1, errno);
if (ev_extra != NULL)
pth_event_concat(ev, ev_extra, NULL);
- pth_wait(ev);
diff --git a/devel/pth/patches/patch-ad b/devel/pth/patches/patch-ad
index 1e36d9de8fe..ef4a4646cb4 100644
--- a/devel/pth/patches/patch-ad
+++ b/devel/pth/patches/patch-ad
@@ -1,6 +1,6 @@
-$NetBSD: patch-ad,v 1.5 2004/04/19 12:16:08 skrll Exp $
+$NetBSD: patch-ad,v 1.6 2007/02/18 11:40:10 wiz Exp $
---- pth_syscall.c.orig Wed Jan 1 15:45:06 2003
+--- pth_syscall.c.orig 2006-06-08 17:54:03.000000000 +0000
+++ pth_syscall.c
@@ -57,6 +57,7 @@
#define sendto __pth_sys_sendto
@@ -54,73 +54,10 @@ $NetBSD: patch-ad,v 1.5 2004/04/19 12:16:08 skrll Exp $
#else
else PTH_SYSCALL_ERROR(-1, ENOSYS, "waitpid");
#endif
-@@ -651,6 +661,52 @@ intern ssize_t pth_sc_recvfrom(int fd, v
+@@ -721,5 +731,27 @@ intern ssize_t pth_sc_sendto(int fd, con
#endif
}
-+ssize_t recv(int, void *, size_t, int);
-+ssize_t recv(int fd, void *buf, size_t nbytes, int flags)
-+{
-+ /* external entry point for application */
-+ pth_implicit_init();
-+ return pth_recv(fd, buf, nbytes, flags);
-+}
-+intern ssize_t pth_sc_recv(int fd, void *buf, size_t nbytes, int flags)
-+{
-+ /* internal exit point for Pth */
-+ if (pth_syscall_fct_tab[PTH_SCF_recv].addr != NULL)
-+ return ((ssize_t (*)(int, void *, size_t, int))
-+ pth_syscall_fct_tab[PTH_SCF_recv].addr)
-+ (fd, buf, nbytes, flags);
-+#if defined(HAVE_SYSCALL) && defined(SYS_recv)
-+ else return (ssize_t)syscall(SYS_recv, fd, buf, nbytes, flags);
-+#elif defined(HAVE_SYSCALL) && defined(SYS_recvfrom)
-+ else return (ssize_t)syscall(SYS_recvfrom, fd, buf, nbytes, flags, (struct sockaddr *) NULL, (socklen_t *) NULL);
-+#else
-+ else PTH_SYSCALL_ERROR(-1, ENOSYS, "recv");
-+#endif
-+}
-+
-+ssize_t send(int, void *, size_t, int);
-+ssize_t send(int fd, void *buf, size_t nbytes, int flags)
-+{
-+ /* external entry point for application */
-+ pth_implicit_init();
-+ return pth_send(fd, buf, nbytes, flags);
-+}
-+intern ssize_t pth_sc_send(int fd, void *buf, size_t nbytes, int flags)
-+{
-+ /* internal exit point for Pth */
-+ if (pth_syscall_fct_tab[PTH_SCF_send].addr != NULL)
-+ return ((ssize_t (*)(int, void *, size_t, int))
-+ pth_syscall_fct_tab[PTH_SCF_send].addr)
-+ (fd, buf, nbytes, flags);
-+#if defined(HAVE_SYSCALL) && defined(SYS_send)
-+ else return (ssize_t)syscall(SYS_send, fd, buf, nbytes, flags);
-+#elif defined(HAVE_SYSCALL) && defined(SYS_sendto)
-+ else return (ssize_t)syscall(SYS_sendto, fd, buf, nbytes, flags, (struct sockaddr *) NULL, NULL);
-+#else
-+ else PTH_SYSCALL_ERROR(-1, ENOSYS, "send");
-+#endif
-+}
-+
- /* ==== Pth hard syscall wrapper for sendto(2) ==== */
- ssize_t sendto(int, const void *, size_t, int, const struct sockaddr *, socklen_t);
- ssize_t sendto(int fd, const void *buf, size_t nbytes, int flags, const struct sockaddr *to, socklen_t tolen)
-@@ -664,12 +720,34 @@ intern ssize_t pth_sc_sendto(int fd, con
- /* internal exit point for Pth */
- if (pth_syscall_fct_tab[PTH_SCF_sendto].addr != NULL)
- return ((ssize_t (*)(int, const void *, size_t, int, const struct sockaddr *, socklen_t))
-- pth_syscall_fct_tab[PTH_SCF_recvfrom].addr)
-+ pth_syscall_fct_tab[PTH_SCF_sendto].addr)
- (fd, buf, nbytes, flags, to, tolen);
- #if defined(HAVE_SYSCALL) && defined(SYS_sendto)
- else return (ssize_t)syscall(SYS_sendto, fd, buf, nbytes, flags, to, tolen);
- #else
- else PTH_SYSCALL_ERROR(-1, ENOSYS, "sendto");
-+#endif
-+}
-+
+/* ==== Pth hard syscall wrapper for wait4(2) ==== */
+pid_t wait4(pid_t, int *, int, struct rusage *);
+pid_t wait4(pid_t wpid, int *status, int options, struct rusage *rusage)
@@ -140,6 +77,8 @@ $NetBSD: patch-ad,v 1.5 2004/04/19 12:16:08 skrll Exp $
+ else return (pid_t)syscall(SYS_wait4, wpid, status, options, rusage);
+#else
+ else PTH_SYSCALL_ERROR(-1, ENOSYS, "wait4");
- #endif
- }
++#endif
++}
++
+ #endif /* PTH_SYSCALL_HARD */
diff --git a/devel/pth/patches/patch-ae b/devel/pth/patches/patch-ae
index e95a5dcaf62..96bbea9ae86 100644
--- a/devel/pth/patches/patch-ae
+++ b/devel/pth/patches/patch-ae
@@ -1,8 +1,8 @@
-$NetBSD: patch-ae,v 1.3 2003/05/02 11:49:48 wiz Exp $
+$NetBSD: patch-ae,v 1.4 2007/02/18 11:40:10 wiz Exp $
---- configure.ac.orig Wed Jan 1 15:45:06 2003
+--- configure.ac.orig 2006-06-08 17:54:01.000000000 +0000
+++ configure.ac
-@@ -190,7 +190,7 @@ dnl # check for various other functions
+@@ -191,7 +191,7 @@ dnl # check for various other functions
AC_CHECK_FUNCS(usleep strerror)
dnl # check for various other headers which we might need
@@ -11,7 +11,7 @@ $NetBSD: patch-ae,v 1.3 2003/05/02 11:49:48 wiz Exp $
dnl # at least the test programs need some socket stuff
AC_CHECK_LIB(nsl, gethostname)
-@@ -208,6 +208,15 @@ if test ".$ac_cv_header_sys_select_h" !=
+@@ -209,6 +209,15 @@ if test ".$ac_cv_header_sys_select_h" !=
fi
AC_SUBST(EXTRA_INCLUDE_SYS_SELECT_H)
@@ -27,7 +27,7 @@ $NetBSD: patch-ae,v 1.3 2003/05/02 11:49:48 wiz Exp $
dnl # check whether we've to define sig_atomic_t
AC_CHECK_TYPEDEF(sig_atomic_t, signal.h)
FALLBACK_SIG_ATOMIC_T="typedef int sig_atomic_t;"
-@@ -618,6 +627,7 @@ fi
+@@ -620,6 +629,7 @@ fi
AC_SUBST(PTHREAD_O)
AC_SUBST(LIBPTHREAD_A)
AC_SUBST(LIBPTHREAD_LA)
diff --git a/devel/pth/patches/patch-af b/devel/pth/patches/patch-af
index 22d9907313c..d812aed0b15 100644
--- a/devel/pth/patches/patch-af
+++ b/devel/pth/patches/patch-af
@@ -1,6 +1,6 @@
-$NetBSD: patch-af,v 1.3 2003/05/02 11:49:48 wiz Exp $
+$NetBSD: patch-af,v 1.4 2007/02/18 11:40:10 wiz Exp $
---- pth.h.in.orig Wed Jan 1 15:45:06 2003
+--- pth.h.in.orig 2006-06-08 17:54:02.000000000 +0000
+++ pth.h.in
@@ -45,6 +45,7 @@
#include <sys/socket.h> /* for sockaddr */
@@ -10,22 +10,23 @@ $NetBSD: patch-af,v 1.3 2003/05/02 11:49:48 wiz Exp $
/* fallbacks for essential typedefs */
#ifndef _PTHREAD_PRIVATE
-@@ -338,7 +339,6 @@ enum {
- #define PTH_FAKE_POLL @PTH_FAKE_POLL@
+@@ -340,7 +341,6 @@ enum {
#if !(PTH_FAKE_POLL)
/* use vendor poll(2) environment */
+ #ifndef _XOPEN_SOURCE
-#define _XOPEN_SOURCE
+ #define _XOPEN_SOURCE_set
+ #endif
#include <poll.h>
- #ifndef POLLRDNORM
- #define POLLRDNORM POLLIN
-@@ -544,7 +544,10 @@ extern ssize_t pth_sendto(int, co
+@@ -550,8 +550,11 @@ extern ssize_t pth_sendto(int, co
extern ssize_t pth_pread(int, void *, size_t, off_t);
extern ssize_t pth_pwrite(int, const void *, size_t, off_t);
+ /* additional replacement functions */
+extern pid_t pth_wait4(pid_t, int *, int, struct rusage *);
END_DECLARATION
-+
++
/* soft system call mapping support */
#if PTH_SYSCALL_SOFT && !defined(_PTH_PRIVATE)
+ #define fork pth_fork
diff --git a/devel/pth/patches/patch-ag b/devel/pth/patches/patch-ag
index deecc666127..a36b83ce1fe 100644
--- a/devel/pth/patches/patch-ag
+++ b/devel/pth/patches/patch-ag
@@ -1,6 +1,6 @@
-$NetBSD: patch-ag,v 1.5 2003/05/02 11:49:48 wiz Exp $
+$NetBSD: patch-ag,v 1.6 2007/02/18 11:40:10 wiz Exp $
---- pth_lib.c.orig Wed Jan 1 15:45:06 2003
+--- pth_lib.c.orig 2006-06-08 17:54:03.000000000 +0000
+++ pth_lib.c
@@ -37,10 +37,11 @@ long pth_version(void)
@@ -69,7 +69,7 @@ $NetBSD: patch-ag,v 1.5 2003/05/02 11:49:48 wiz Exp $
/* kill the package internals */
int pth_kill(void)
{
-@@ -144,6 +158,7 @@ int pth_kill(void)
+@@ -146,6 +160,7 @@ int pth_kill(void)
pth_thread_cleanup(pth_main);
pth_scheduler_kill();
pth_initialized = FALSE;