pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/net/tnftp corrected a typo in libnetbsd/usleep.c which...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/47c126152dc6
branches:  trunk
changeset: 511154:47c126152dc6
user:      schwarz <schwarz%pkgsrc.org@localhost>
date:      Mon Apr 10 13:26:15 2006 +0000

description:
corrected a typo in libnetbsd/usleep.c which probably surfaces only on some
older OSes
added a hack to support IRIX 5
(modifications done directly to the files instead of adding patch files to
make them being used during bootstrapping as well; approved by reed)

diffstat:

 net/tnftp/files/libnetbsd/usleep.c |   2 +-
 net/tnftp/files/tnftp.h            |   8 ++++++++
 net/tnftp/hacks.mk                 |  10 ++++++++++
 3 files changed, 19 insertions(+), 1 deletions(-)

diffs (46 lines):

diff -r d4e0602fe906 -r 47c126152dc6 net/tnftp/files/libnetbsd/usleep.c
--- a/net/tnftp/files/libnetbsd/usleep.c        Mon Apr 10 12:56:04 2006 +0000
+++ b/net/tnftp/files/libnetbsd/usleep.c        Mon Apr 10 13:26:15 2006 +0000
@@ -42,7 +42,7 @@
 usleep(unsigned int usec)
 {
 #if HAVE_POLL
-       return (poll(NULL, 0, usec / 1000);
+       return (poll(NULL, 0, usec / 1000));
 #elif HAVE_SELECT
        struct timeval tv;
 
diff -r d4e0602fe906 -r 47c126152dc6 net/tnftp/files/tnftp.h
--- a/net/tnftp/files/tnftp.h   Mon Apr 10 12:56:04 2006 +0000
+++ b/net/tnftp/files/tnftp.h   Mon Apr 10 13:26:15 2006 +0000
@@ -179,8 +179,16 @@
 #endif
 
 #if ! HAVE_SOCKLEN_T
+#ifdef __sgi
+typedef int socklen_t;
+#else
 typedef unsigned int socklen_t;
 #endif
+#endif
+
+#ifdef UINT32_T /* needed for example on IRIX 5 */
+typedef unsigned UINT32_T uint32_t;
+#endif
 
 #if HAVE_AF_INET6 && HAVE_SOCKADDR_IN6 && HAVE_NS_IN6ADDRSZ
 # define INET6
diff -r d4e0602fe906 -r 47c126152dc6 net/tnftp/hacks.mk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/net/tnftp/hacks.mk        Mon Apr 10 13:26:15 2006 +0000
@@ -0,0 +1,10 @@
+# $NetBSD: hacks.mk,v 1.1 2006/04/10 13:26:15 schwarz Exp $
+
+### [ Mon Apr 10 14:23:26 CDT 2006 : schwarz ]
+### Define type to use for uint32_t on platforms that do not have it
+### (cf. tnftp.h)
+###
+.if !empty(LOWER_OPSYS:Mirix5*)
+PKG_HACKS+=    uint32_t
+CPPFLAGS+=     -DUINT32_T=int
+.endif



Home | Main Index | Thread Index | Old Index