diff options
author | shattered <shattered@pkgsrc.org> | 2012-08-29 18:11:28 +0000 |
---|---|---|
committer | shattered <shattered@pkgsrc.org> | 2012-08-29 18:11:28 +0000 |
commit | 070887756b49f46c6130616a92ec45e63fc1384f (patch) | |
tree | 359beaebbacec5c95b824d26214a967d51b30d56 /emulators | |
parent | 07c53d91c40f177f7cc05aab291c87822c4d094a (diff) | |
download | pkgsrc-070887756b49f46c6130616a92ec45e63fc1384f.tar.gz |
PR/45921 -- handle the new (post-2007) way SIOCGIFCONF works.
XXX rewrite this to use getifaddrs()
Diffstat (limited to 'emulators')
-rw-r--r-- | emulators/tme/Makefile | 6 | ||||
-rw-r--r-- | emulators/tme/distinfo | 3 | ||||
-rw-r--r-- | emulators/tme/patches/patch-host_bsd_bsd-bpf.c | 30 |
3 files changed, 34 insertions, 5 deletions
diff --git a/emulators/tme/Makefile b/emulators/tme/Makefile index f8290803152..6a804c56688 100644 --- a/emulators/tme/Makefile +++ b/emulators/tme/Makefile @@ -1,14 +1,12 @@ -# $NetBSD: Makefile,v 1.28 2012/03/03 00:13:03 wiz Exp $ +# $NetBSD: Makefile,v 1.29 2012/08/29 18:11:28 shattered Exp $ # DISTNAME= tme-0.8 -PKGREVISION= 8 +PKGREVISION= 9 CATEGORIES= emulators MASTER_SITES= http://csail.mit.edu/~fredette/tme/ MAINTAINER= skrll@NetBSD.org -# Please do not assign PR's for this package to skrll. -# Instead, assign them to the package author, fredette. PKG_DESTDIR_SUPPORT= user-destdir diff --git a/emulators/tme/distinfo b/emulators/tme/distinfo index 044d5392fd7..13f8421369c 100644 --- a/emulators/tme/distinfo +++ b/emulators/tme/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.13 2012/01/21 04:41:44 tsutsui Exp $ +$NetBSD: distinfo,v 1.14 2012/08/29 18:11:28 shattered Exp $ SHA1 (tme-0.8.tar.gz) = dd4f3421c20ceed548c5328a21dbb26e80f46b9c RMD160 (tme-0.8.tar.gz) = 6bd505c5fa7810d37f436883383c4ba655df2ded @@ -9,4 +9,5 @@ SHA1 (patch-ac) = ba581f10ec54b056564a7a84a5833f2d854b55df SHA1 (patch-ad) = e90986262fe9d883ae64fe01dfb4ae07bde6a916 SHA1 (patch-ae) = cfcea636744991c6eef84ea34ca78d40eb01c086 SHA1 (patch-af) = cd3ffe52d4d75d05394ca74c3f69052bfdc41989 +SHA1 (patch-host_bsd_bsd-bpf.c) = 02a94a141da7d1790969deb8624d3a219d3e64ed SHA1 (patch-ic_ieee754_ieee754-misc-auto.sh) = afeb7452ef64bcae71e4dbae21881cff12cb9d4f diff --git a/emulators/tme/patches/patch-host_bsd_bsd-bpf.c b/emulators/tme/patches/patch-host_bsd_bsd-bpf.c new file mode 100644 index 00000000000..0ec6402ecf8 --- /dev/null +++ b/emulators/tme/patches/patch-host_bsd_bsd-bpf.c @@ -0,0 +1,30 @@ +$NetBSD: patch-host_bsd_bsd-bpf.c,v 1.1 2012/08/29 18:11:29 shattered Exp $ + +--- host/bsd/bsd-if.c.orig 2003-10-16 02:48:23.000000000 +0000 ++++ host/bsd/bsd-if.c 2012-07-07 12:24:22.000000000 +0000 +@@ -71,14 +72,15 @@ + + /* this macro helps us size a struct ifreq: */ + #ifdef HAVE_SOCKADDR_SA_LEN +-#define SIZEOF_IFREQ(ifr) (sizeof(ifr->ifr_name) + ifr->ifr_addr.sa_len) ++#define SIZEOF_IFREQ(ifr) \ ++( sizeof(ifr->ifr_name) + (ifr->ifr_addr.sa_len > sizeof(ifr->ifr_ifru) ? ifr->ifr_addr.sa_len : sizeof(ifr->ifr_ifru)) ) + #else /* !HAVE_SOCKADDR_SA_LEN */ + #define SIZEOF_IFREQ(ifr) (sizeof(ifr->ifr_name) + sizeof(struct sockaddr)) + #endif /* !HAVE_SOCKADDR_SA_LEN */ + + /* this finds a network interface: */ + int + tme_bsd_if_find(const char *ifr_name_user, struct ifreq **_ifreq, tme_uint8_t **_if_addr, unsigned int *_if_addr_size) + { + int saved_errno; + int dummy_fd; +@@ -175,7 +192,7 @@ + if (ifr_user == NULL + && (ifr_name_user != NULL + ? !strncmp(ifr->ifr_name, ifr_name_user, sizeof(ifr->ifr_name)) +- : !(ifr->ifr_flags & IFF_LOOPBACK))) { ++ : !(saved_flags & IFF_LOOPBACK))) { + ifr_user = ifr; + } + } |