summaryrefslogtreecommitdiffstats
path: root/unix/tclUnixPort.h
diff options
context:
space:
mode:
Diffstat (limited to 'unix/tclUnixPort.h')
-rw-r--r--unix/tclUnixPort.h51
1 files changed, 16 insertions, 35 deletions
diff --git a/unix/tclUnixPort.h b/unix/tclUnixPort.h
index 421d73c..54bff49 100644
--- a/unix/tclUnixPort.h
+++ b/unix/tclUnixPort.h
@@ -130,7 +130,10 @@ MODULE_SCOPE int TclUnixSetBlockingMode(int fd, int mode);
#endif
#include <netinet/in.h> /* struct in_addr, struct sockaddr_in */
#include <arpa/inet.h> /* inet_ntoa() */
-#include <netdb.h> /* gethostbyname() */
+#include <netdb.h> /* getaddrinfo() */
+#ifdef NEED_FAKE_RFC2553
+# include "../compat/fake-rfc2553.h"
+#endif
/*
* Some platforms (e.g. SunOS) don't define FLT_MAX and FLT_MIN, so we
@@ -254,8 +257,7 @@ MODULE_SCOPE int TclUnixSetBlockingMode(int fd, int mode);
#endif
#ifdef GETTOD_NOT_DECLARED
-EXTERN int gettimeofday _ANSI_ARGS_((struct timeval *tp,
- struct timezone *tzp));
+MODULE_SCOPE int gettimeofday(struct timeval *tp, struct timezone *tzp);
#endif
/*
@@ -463,12 +465,6 @@ extern char **environ;
#endif
/*
- * There is no platform-specific panic routine for Unix in the Tcl internals.
- */
-
-#define TclpPanic ((Tcl_PanicProc *) NULL)
-
-/*
* Darwin specifc configure overrides.
*/
@@ -557,8 +553,8 @@ extern char **environ;
/*
*---------------------------------------------------------------------------
- * The following macros and declarations represent the interface between
- * generic and unix-specific parts of Tcl. Some of the macros may override
+ * The following macros and declarations represent the interface between
+ * generic and unix-specific parts of Tcl. Some of the macros may override
* functions declared in tclInt.h.
*---------------------------------------------------------------------------
*/
@@ -575,7 +571,7 @@ typedef int socklen_t;
#endif
/*
- * The following macros have trivial definitions, allowing generic code to
+ * The following macros have trivial definitions, allowing generic code to
* address platform-specific issues.
*/
@@ -598,33 +594,15 @@ typedef int socklen_t;
#define TclpExit exit
#ifdef TCL_THREADS
-EXTERN struct tm * TclpLocaltime(CONST time_t *);
-EXTERN struct tm * TclpGmtime(CONST time_t *);
-EXTERN char * TclpInetNtoa(struct in_addr);
-/* #define localtime(x) TclpLocaltime(x)
- * #define gmtime(x) TclpGmtime(x) */
# undef inet_ntoa
# define inet_ntoa(x) TclpInetNtoa(x)
-# ifdef HAVE_PTHREAD_ATTR_GET_NP
-# define TclpPthreadGetAttrs pthread_attr_get_np
-# ifdef ATTRGETNP_NOT_DECLARED
-/*
- * Assume it is in pthread_np.h if it isn't in pthread.h. [Bug 1064882]
- * We might need to revisit this in the future. :^(
- */
-# include <pthread.h>
-# include <pthread_np.h>
-# endif
-# else
-# ifdef HAVE_PTHREAD_GETATTR_NP
-# define TclpPthreadGetAttrs pthread_getattr_np
-# ifdef GETATTRNP_NOT_DECLARED
-EXTERN int pthread_getattr_np _ANSI_ARGS_((pthread_t, pthread_attr_t *));
-# endif
-# endif /* HAVE_PTHREAD_GETATTR_NP */
-# endif /* HAVE_PTHREAD_ATTR_GET_NP */
#endif /* TCL_THREADS */
+/* FIXME */
+#ifndef AF_INET6
+#define AF_INET6 10
+#endif
+
/*
* Set of MT-safe implementations of some
* known-to-be-MT-unsafe library calls.
@@ -633,6 +611,7 @@ EXTERN int pthread_getattr_np _ANSI_ARGS_((pthread_t, pthread_attr_t *));
* to the TSD data.
*/
+#include <pwd.h>
#include <grp.h>
MODULE_SCOPE struct passwd* TclpGetPwNam(const char *name);
@@ -641,5 +620,7 @@ MODULE_SCOPE struct passwd* TclpGetPwUid(uid_t uid);
MODULE_SCOPE struct group* TclpGetGrGid(gid_t gid);
MODULE_SCOPE struct hostent* TclpGetHostByName(const char *name);
MODULE_SCOPE struct hostent* TclpGetHostByAddr(const char *addr, int length, int type);
+MODULE_SCOPE Tcl_Channel TclpMakeTcpClientChannelMode(ClientData tcpSocket, int mode);
+
#endif /* _TCLUNIXPORT */