1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-24 21:01:20 +00:00

Port to __FreeBSD_version >= 500112 that now has getpw*_r() functions

that are incompatible with the older draft implementations supplied
with the OpenOffice source.

Approved by: mbr
This commit is contained in:
Don Lewis 2003-04-20 21:02:50 +00:00
parent 24494bb3f9
commit db782b35fb
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=79374
6 changed files with 108 additions and 24 deletions

View File

@ -1,6 +1,16 @@
--- ../sal/osl/unx/system.c.orig Sun Mar 17 12:34:13 2002
+++ ../sal/osl/unx/system.c Wed Apr 3 01:03:36 2002
@@ -195,6 +195,73 @@
--- ../sal/osl/unx/system.c.orig Tue Aug 20 08:49:46 2002
+++ ../sal/osl/unx/system.c Sat Apr 19 22:15:25 2003
@@ -74,7 +74,8 @@
static pthread_mutex_t getrtl_mutex = PTHREAD_MUTEX_INITIALIZER;
/* struct passwd differs on some platforms */
-#if defined NETBSD || defined MACOSX || defined FREEBSD
+#if defined NETBSD || defined MACOSX || \
+ (defined FREEBSD && (__FreeBSD_version < 500112))
#include <pwd.h>
#include <sys/types.h>
@@ -203,6 +204,73 @@
}
#endif
@ -74,7 +84,7 @@
struct tm *localtime_r(const time_t *timep, struct tm *buffer)
{
struct tm* res;
@@ -518,3 +585,50 @@
@@ -712,3 +780,50 @@
}
#endif

View File

@ -1,7 +1,10 @@
--- ../sal/osl/unx/system.h.orig Wed Jun 5 16:24:19 2002
+++ ../sal/osl/unx/system.h Sun Jan 12 15:48:03 2003
@@ -205,6 +205,13 @@
--- ../sal/osl/unx/system.h.orig Tue Aug 20 08:54:55 2002
+++ ../sal/osl/unx/system.h Sat Apr 19 22:09:15 2003
@@ -203,8 +203,16 @@
# include <dlfcn.h>
# include <sys/filio.h>
# include <sys/ioctl.h>
+# include <sys/param.h>
# include <sys/time.h>
# include <sys/uio.h>
+# include <sys/exec.h>
@ -14,7 +17,7 @@
# include <sys/un.h>
# include <netinet/tcp.h>
# define IORESOURCE_TRANSFER_BSD
@@ -216,12 +223,13 @@
@@ -216,12 +224,13 @@
# elif BYTE_ORDER == PDP_ENDIAN
# define _PDP_ENDIAN
# endif
@ -33,3 +36,18 @@
#endif
#ifdef SCO
@@ -569,12 +578,14 @@
#endif
#ifdef NO_PTHREAD_RTL
+#if !defined FREEBSD || (__FreeBSD_version < 500112)
struct passwd *getpwent_r(struct passwd *pwd, char *buffer, int buflen);
extern struct spwd *getspnam_r(const char *name, struct spwd *result,
char *buffer, int buflen);
struct tm *localtime_r(const time_t *timep, struct tm *buffer);
struct tm *gmtime_r(const time_t *timep, struct tm *buffer);
+#endif /* !defined FREEBSD || (__FreeBSD_version < 500112) */
struct hostent *gethostbyname_r(const char *name, struct hostent *result,
char *buffer, int buflen, int *h_errnop);
#endif

View File

@ -1,6 +1,16 @@
--- ../sal/osl/unx/system.c.orig Sun Mar 17 12:34:13 2002
+++ ../sal/osl/unx/system.c Wed Apr 3 01:03:36 2002
@@ -195,6 +195,73 @@
--- ../sal/osl/unx/system.c.orig Tue Aug 20 08:49:46 2002
+++ ../sal/osl/unx/system.c Sat Apr 19 22:15:25 2003
@@ -74,7 +74,8 @@
static pthread_mutex_t getrtl_mutex = PTHREAD_MUTEX_INITIALIZER;
/* struct passwd differs on some platforms */
-#if defined NETBSD || defined MACOSX || defined FREEBSD
+#if defined NETBSD || defined MACOSX || \
+ (defined FREEBSD && (__FreeBSD_version < 500112))
#include <pwd.h>
#include <sys/types.h>
@@ -203,6 +204,73 @@
}
#endif
@ -74,7 +84,7 @@
struct tm *localtime_r(const time_t *timep, struct tm *buffer)
{
struct tm* res;
@@ -518,3 +585,50 @@
@@ -712,3 +780,50 @@
}
#endif

View File

@ -1,7 +1,10 @@
--- ../sal/osl/unx/system.h.orig Wed Jun 5 16:24:19 2002
+++ ../sal/osl/unx/system.h Sun Jan 12 15:48:03 2003
@@ -205,6 +205,13 @@
--- ../sal/osl/unx/system.h.orig Tue Aug 20 08:54:55 2002
+++ ../sal/osl/unx/system.h Sat Apr 19 22:09:15 2003
@@ -203,8 +203,16 @@
# include <dlfcn.h>
# include <sys/filio.h>
# include <sys/ioctl.h>
+# include <sys/param.h>
# include <sys/time.h>
# include <sys/uio.h>
+# include <sys/exec.h>
@ -14,7 +17,7 @@
# include <sys/un.h>
# include <netinet/tcp.h>
# define IORESOURCE_TRANSFER_BSD
@@ -216,12 +223,13 @@
@@ -216,12 +224,13 @@
# elif BYTE_ORDER == PDP_ENDIAN
# define _PDP_ENDIAN
# endif
@ -33,3 +36,18 @@
#endif
#ifdef SCO
@@ -569,12 +578,14 @@
#endif
#ifdef NO_PTHREAD_RTL
+#if !defined FREEBSD || (__FreeBSD_version < 500112)
struct passwd *getpwent_r(struct passwd *pwd, char *buffer, int buflen);
extern struct spwd *getspnam_r(const char *name, struct spwd *result,
char *buffer, int buflen);
struct tm *localtime_r(const time_t *timep, struct tm *buffer);
struct tm *gmtime_r(const time_t *timep, struct tm *buffer);
+#endif /* !defined FREEBSD || (__FreeBSD_version < 500112) */
struct hostent *gethostbyname_r(const char *name, struct hostent *result,
char *buffer, int buflen, int *h_errnop);
#endif

View File

@ -1,6 +1,16 @@
--- ../sal/osl/unx/system.c.orig Sun Mar 17 12:34:13 2002
+++ ../sal/osl/unx/system.c Wed Apr 3 01:03:36 2002
@@ -195,6 +195,73 @@
--- ../sal/osl/unx/system.c.orig Tue Aug 20 08:49:46 2002
+++ ../sal/osl/unx/system.c Sat Apr 19 22:15:25 2003
@@ -74,7 +74,8 @@
static pthread_mutex_t getrtl_mutex = PTHREAD_MUTEX_INITIALIZER;
/* struct passwd differs on some platforms */
-#if defined NETBSD || defined MACOSX || defined FREEBSD
+#if defined NETBSD || defined MACOSX || \
+ (defined FREEBSD && (__FreeBSD_version < 500112))
#include <pwd.h>
#include <sys/types.h>
@@ -203,6 +204,73 @@
}
#endif
@ -74,7 +84,7 @@
struct tm *localtime_r(const time_t *timep, struct tm *buffer)
{
struct tm* res;
@@ -518,3 +585,50 @@
@@ -712,3 +780,50 @@
}
#endif

View File

@ -1,7 +1,10 @@
--- ../sal/osl/unx/system.h.orig Wed Jun 5 16:24:19 2002
+++ ../sal/osl/unx/system.h Sun Jan 12 15:48:03 2003
@@ -205,6 +205,13 @@
--- ../sal/osl/unx/system.h.orig Tue Aug 20 08:54:55 2002
+++ ../sal/osl/unx/system.h Sat Apr 19 22:09:15 2003
@@ -203,8 +203,16 @@
# include <dlfcn.h>
# include <sys/filio.h>
# include <sys/ioctl.h>
+# include <sys/param.h>
# include <sys/time.h>
# include <sys/uio.h>
+# include <sys/exec.h>
@ -14,7 +17,7 @@
# include <sys/un.h>
# include <netinet/tcp.h>
# define IORESOURCE_TRANSFER_BSD
@@ -216,12 +223,13 @@
@@ -216,12 +224,13 @@
# elif BYTE_ORDER == PDP_ENDIAN
# define _PDP_ENDIAN
# endif
@ -33,3 +36,18 @@
#endif
#ifdef SCO
@@ -569,12 +578,14 @@
#endif
#ifdef NO_PTHREAD_RTL
+#if !defined FREEBSD || (__FreeBSD_version < 500112)
struct passwd *getpwent_r(struct passwd *pwd, char *buffer, int buflen);
extern struct spwd *getspnam_r(const char *name, struct spwd *result,
char *buffer, int buflen);
struct tm *localtime_r(const time_t *timep, struct tm *buffer);
struct tm *gmtime_r(const time_t *timep, struct tm *buffer);
+#endif /* !defined FREEBSD || (__FreeBSD_version < 500112) */
struct hostent *gethostbyname_r(const char *name, struct hostent *result,
char *buffer, int buflen, int *h_errnop);
#endif