diff options
author | joerg <joerg@pkgsrc.org> | 2006-12-15 19:11:48 +0000 |
---|---|---|
committer | joerg <joerg@pkgsrc.org> | 2006-12-15 19:11:48 +0000 |
commit | 6359a506b8ffad1ede4a450ccc06ca36c360514a (patch) | |
tree | ae9be7e296936a1e189833617832d25cf0683b7a /x11 | |
parent | e0965eb84d1bb2684ac3ef068aafaf2e6e3b4ec7 (diff) | |
download | pkgsrc-6359a506b8ffad1ede4a450ccc06ca36c360514a.tar.gz |
Just include limits.h in Xos_r.h, don't play with _POSIX_SOURCE.
For example, configure plays dirty with that.
Fix a type in the MTSAFE_PWAPI section and the configure test for
NETDBAPI (from David Sainty).
Assume that readdir_r follows POSIX semantics if configure detected it
and we have no reason to believe so otherwise. Most importantly, use it
when _POSIX_REENTRANT_FUNCTIONS is not defined.
Bump revision.
Diffstat (limited to 'x11')
-rw-r--r-- | x11/xproto/Makefile | 3 | ||||
-rw-r--r-- | x11/xproto/distinfo | 8 | ||||
-rw-r--r-- | x11/xproto/patches/patch-aa | 55 | ||||
-rw-r--r-- | x11/xproto/patches/patch-ab | 4 | ||||
-rw-r--r-- | x11/xproto/patches/patch-ac | 4 |
5 files changed, 54 insertions, 20 deletions
diff --git a/x11/xproto/Makefile b/x11/xproto/Makefile index 44f0c7cdfc8..8c0eafbd3df 100644 --- a/x11/xproto/Makefile +++ b/x11/xproto/Makefile @@ -1,7 +1,8 @@ -# $NetBSD: Makefile,v 1.4 2006/11/03 17:03:04 joerg Exp $ +# $NetBSD: Makefile,v 1.5 2006/12/15 19:11:48 joerg Exp $ # DISTNAME= xproto-7.0.9 +PKGREVISION= 1 CATEGORIES= x11 devel MASTER_SITES= http://xorg.freedesktop.org/releases/individual/proto/ EXTRACT_SUFX= .tar.bz2 diff --git a/x11/xproto/distinfo b/x11/xproto/distinfo index cfffc5d6751..e0366ad75b1 100644 --- a/x11/xproto/distinfo +++ b/x11/xproto/distinfo @@ -1,8 +1,8 @@ -$NetBSD: distinfo,v 1.3 2006/11/03 17:03:04 joerg Exp $ +$NetBSD: distinfo,v 1.4 2006/12/15 19:11:48 joerg Exp $ SHA1 (xproto-7.0.9.tar.bz2) = 89f62bd846654377706446ec63b98050ce268f86 RMD160 (xproto-7.0.9.tar.bz2) = 158260d12444514ace88d385160bf284e70f54d3 Size (xproto-7.0.9.tar.bz2) = 141941 bytes -SHA1 (patch-aa) = 48f8206f8da09c7cd15cab57a2057b74a43e8c77 -SHA1 (patch-ab) = 2a6972b8fb362359414508cba6c109e459decd91 -SHA1 (patch-ac) = 2bcfa0ab2bf4823e26f4c13255c940106801a96b +SHA1 (patch-aa) = def584959de949811007090f65c83f3ebbe21a67 +SHA1 (patch-ab) = c1ab51ee280b41f17f7780b880ae6cb70c0e4150 +SHA1 (patch-ac) = f53e93c62711b7c12c525b1267951b63c8783875 diff --git a/x11/xproto/patches/patch-aa b/x11/xproto/patches/patch-aa index 6c7e6ade0df..d560ee759cb 100644 --- a/x11/xproto/patches/patch-aa +++ b/x11/xproto/patches/patch-aa @@ -1,8 +1,23 @@ -$NetBSD: patch-aa,v 1.1 2006/11/03 17:03:04 joerg Exp $ +$NetBSD: patch-aa,v 1.2 2006/12/15 19:11:48 joerg Exp $ ---- Xos_r.h.in.orig 2006-11-02 08:15:48.000000000 +0000 +--- Xos_r.h.in.orig 2006-09-20 17:59:42.000000000 +0000 +++ Xos_r.h.in -@@ -188,6 +188,13 @@ extern void XtProcessUnlock( +@@ -76,13 +76,7 @@ in this Software without prior written a + # include <X11/Xfuncs.h> + + # ifndef X_NOT_POSIX +-# ifdef _POSIX_SOURCE +-# include <limits.h> +-# else +-# define _POSIX_SOURCE +-# include <limits.h> +-# undef _POSIX_SOURCE +-# endif ++# include <limits.h> + # ifndef LINE_MAX + # define X_LINE_MAX 2048 + # else +@@ -188,6 +182,13 @@ extern void XtProcessUnlock( # endif # endif @@ -16,16 +31,16 @@ $NetBSD: patch-aa,v 1.1 2006/11/03 17:03:04 joerg Exp $ #endif /* !defined WIN32 */ /* -@@ -226,7 +233,7 @@ extern void XtProcessUnlock( +@@ -226,7 +227,7 @@ extern void XtProcessUnlock( #if defined(X_INCLUDE_PWD_H) && !defined(_XOS_INCLUDED_PWD_H) # include <pwd.h> -# if defined(XUSE_MTSAFE_API) || defined(XUSE_MTSAFE_PWDAPI) -+# if defined(_XOS_MTSAFE_PWAPI) ++# if defined(_XOS_R_H_MTSAFE_PWAPI) # define XOS_USE_MTSAFE_PWDAPI 1 # endif #endif -@@ -410,7 +417,7 @@ typedef int _Xgetpwret; +@@ -410,7 +411,7 @@ typedef int _Xgetpwret; #if defined(X_INCLUDE_NETDB_H) && !defined(_XOS_INCLUDED_NETDB_H) \ && !defined(WIN32) # include <netdb.h> @@ -34,7 +49,7 @@ $NetBSD: patch-aa,v 1.1 2006/11/03 17:03:04 joerg Exp $ # define XOS_USE_MTSAFE_NETDBAPI 1 # endif #endif -@@ -573,7 +580,7 @@ typedef int _Xgetservbynameparams; /* du +@@ -573,7 +574,7 @@ typedef int _Xgetservbynameparams; /* du # define dirent direct # endif # endif @@ -43,7 +58,25 @@ $NetBSD: patch-aa,v 1.1 2006/11/03 17:03:04 joerg Exp $ # define XOS_USE_MTSAFE_DIRENTAPI 1 # endif #endif -@@ -691,7 +698,7 @@ extern int _Preaddir_r(DIR *, struct dir +@@ -656,15 +657,8 @@ extern int _Preaddir_r(DIR *, struct dir + /* Pre-POSIX API, returns non-NULL on success. */ + # define _XReaddir(d,p) (readdir_r((d), &(p).dir_entry)) + # else +-/* We have no idea what is going on. Fake it all using process locks. */ +-# define _XReaddir(d,p) \ +- ( (_Xos_processLock), \ +- (((p).result = readdir((d))) ? \ +- (memcpy(&((p).dir_entry), (p).result, (p).result->d_reclen), \ +- ((p).result = &(p).dir_entry), 0) : \ +- 0), \ +- (_Xos_processUnlock), \ +- (p).result ) ++# define _XReaddir(d,p) \ ++ (readdir_r((d), &((p).dir_entry), &((p).result)) ? NULL : (p).result) + # endif + #endif /* X_INCLUDE_DIRENT_H */ + +@@ -691,7 +685,7 @@ extern int _Preaddir_r(DIR *, struct dir #if defined(X_INCLUDE_UNISTD_H) && !defined(_XOS_INCLUDED_UNISTD_H) /* <unistd.h> already included by <X11/Xos.h> */ @@ -52,7 +85,7 @@ $NetBSD: patch-aa,v 1.1 2006/11/03 17:03:04 joerg Exp $ # define XOS_USE_MTSAFE_UNISTDAPI 1 # endif #endif -@@ -831,7 +838,7 @@ typedef struct { +@@ -831,7 +825,7 @@ typedef struct { #if defined(X_INCLUDE_STRING_H) && !defined(_XOS_INCLUDED_STRING_H) /* <string.h> has already been included by <X11/Xos.h> */ @@ -61,7 +94,7 @@ $NetBSD: patch-aa,v 1.1 2006/11/03 17:03:04 joerg Exp $ # define XOS_USE_MTSAFE_STRINGAPI 1 # endif #endif -@@ -883,7 +890,7 @@ typedef char * _Xstrtokparams; +@@ -883,7 +877,7 @@ typedef char * _Xstrtokparams; #if defined(X_INCLUDE_TIME_H) && !defined(_XOS_INCLUDED_TIME_H) # include <time.h> @@ -70,7 +103,7 @@ $NetBSD: patch-aa,v 1.1 2006/11/03 17:03:04 joerg Exp $ # define XOS_USE_MTSAFE_TIMEAPI 1 # endif #endif -@@ -1046,7 +1053,7 @@ typedef struct tm _Xltimeparams; +@@ -1046,7 +1040,7 @@ typedef struct tm _Xltimeparams; #if defined(X_INCLUDE_GRP_H) && !defined(_XOS_INCLUDED_GRP_H) # include <grp.h> diff --git a/x11/xproto/patches/patch-ab b/x11/xproto/patches/patch-ab index 835962b6956..8008f217304 100644 --- a/x11/xproto/patches/patch-ab +++ b/x11/xproto/patches/patch-ab @@ -1,4 +1,4 @@ -$NetBSD: patch-ab,v 1.1 2006/11/03 17:03:04 joerg Exp $ +$NetBSD: patch-ab,v 1.2 2006/12/15 19:11:48 joerg Exp $ --- configure.ac.orig 2006-11-02 08:17:10.000000000 +0000 +++ configure.ac @@ -18,7 +18,7 @@ $NetBSD: patch-ab,v 1.1 2006/11/03 17:03:04 joerg Exp $ +AC_CHECK_FUNC(readdir_r, [AC_DEFINE(_XOS_R_H_MTSAFE_DIRENTAPI,[],[Assume has readdir_r and friends from dirent.h])],) +AC_CHECK_FUNC(getgrgid_r, [AC_DEFINE(_XOS_R_H_MTSAFE_GRPAPI,[],[Assume has getgrgid_r and friends from grp.h])],) +AC_CHECK_FUNC(getpwuid_r, [AC_DEFINE(_XOS_R_H_MTSAFE_PWDAPI,[],[Assume has getpwuid_r and friends from pwd.h])],) -+AC_CHECK_FUNC(gethostbyname_r, [AC_DEFINE(_XOS_R_H_MTSAFE_NETBDAPI,[],[Assume has gethostbyname_r and friends from netdb.h])],) ++AC_CHECK_FUNC(gethostbyname_r, [AC_DEFINE(_XOS_R_H_MTSAFE_NETDBAPI,[],[Assume has gethostbyname_r and friends from netdb.h])],) +AC_CHECK_FUNC(strtok_r, [AC_DEFINE(_XOS_R_H_MTSAFE_STRINGAPI,[],[Assume has strtok_r from string.h])],) +AC_CHECK_FUNC(gmtime_r, [AC_DEFINE(_XOS_R_H_MTSAFE_TIMEAPI,[],[Assume has gmtime_r and friends from time.h])],) +AC_CHECK_FUNC(ttyname_r, [AC_DEFINE(_XOS_R_H_MTSAFE_UNISTDAPI,[],[Assume has ttyname_r and friends from unistd.h])],) diff --git a/x11/xproto/patches/patch-ac b/x11/xproto/patches/patch-ac index 780a530ce0b..e84b99e71e2 100644 --- a/x11/xproto/patches/patch-ac +++ b/x11/xproto/patches/patch-ac @@ -1,4 +1,4 @@ -$NetBSD: patch-ac,v 1.1 2006/11/03 17:03:04 joerg Exp $ +$NetBSD: patch-ac,v 1.2 2006/12/15 19:11:48 joerg Exp $ --- configure.orig 2006-11-02 08:19:09.000000000 +0000 +++ configure @@ -431,7 +431,7 @@ $NetBSD: patch-ac,v 1.1 2006/11/03 17:03:04 joerg Exp $ +if test $ac_cv_func_gethostbyname_r = yes; then + +cat >>confdefs.h <<\_ACEOF -+#define _XOS_R_H_MTSAFE_NETBDAPI ++#define _XOS_R_H_MTSAFE_NETDBAPI +_ACEOF + +fi |