summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschwarz <schwarz@pkgsrc.org>2006-04-10 13:26:15 +0000
committerschwarz <schwarz@pkgsrc.org>2006-04-10 13:26:15 +0000
commit7d455417201a0c368cd39afce5cd98130adc2aca (patch)
treeaf52233d7a4426ee6d27f220aa8639b00950999f
parent8c940e96349e750496f24e6b6555cf3d0f650d71 (diff)
downloadpkgsrc-7d455417201a0c368cd39afce5cd98130adc2aca.tar.gz
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)
-rw-r--r--net/tnftp/files/libnetbsd/usleep.c2
-rw-r--r--net/tnftp/files/tnftp.h8
-rw-r--r--net/tnftp/hacks.mk10
3 files changed, 19 insertions, 1 deletions
diff --git a/net/tnftp/files/libnetbsd/usleep.c b/net/tnftp/files/libnetbsd/usleep.c
index f729e2d0506..233485a0616 100644
--- a/net/tnftp/files/libnetbsd/usleep.c
+++ b/net/tnftp/files/libnetbsd/usleep.c
@@ -42,7 +42,7 @@ int
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 --git a/net/tnftp/files/tnftp.h b/net/tnftp/files/tnftp.h
index 22df1cfd48d..3ddcd9da7e0 100644
--- a/net/tnftp/files/tnftp.h
+++ b/net/tnftp/files/tnftp.h
@@ -179,8 +179,16 @@ typedef unsigned short sa_family_t;
#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 --git a/net/tnftp/hacks.mk b/net/tnftp/hacks.mk
new file mode 100644
index 00000000000..3a3c0ad99a5
--- /dev/null
+++ b/net/tnftp/hacks.mk
@@ -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