- Unbreak port

PR:             ports/146631
Submitted by:   Martin Kraft <a0516@marimga.de>
This commit is contained in:
Philip M. Gollucci 2010-09-09 03:02:15 +00:00
parent 0290019df2
commit aaf116f1f9
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=260811
2 changed files with 13 additions and 13 deletions

View File

@ -7,7 +7,7 @@
PORTNAME= pppload
PORTVERSION= 1.0
PORTREVISION= 6
PORTREVISION= 7
CATEGORIES= net sysutils
MASTER_SITES= ${MASTER_SITE_SUNSITE}
MASTER_SITE_SUBDIR= system/network/serial/ppp
@ -28,8 +28,4 @@ do-install:
.include <bsd.port.pre.mk>
.if ${OSVERSION} >= 800064
BROKEN= does not build
.endif
.include <bsd.port.post.mk>

View File

@ -1,6 +1,6 @@
--- PPPStats.C.orig Fri Jan 24 17:33:43 2003
+++ PPPStats.C Fri Jan 24 17:33:27 2003
@@ -19,16 +19,22 @@
--- PPPStats.C.orig 1996-09-12 04:50:13.000000000 +0200
+++ PPPStats.C 2010-05-16 12:45:39.000000000 +0200
@@ -19,16 +19,24 @@
extern "C" {
#include <stdlib.h>
@ -14,26 +14,30 @@
-#include <linux/ppp_defs.h>
+#include <sys/time.h>
+#include <net/if.h>
+#include <net/if_ppp.h>
+// 2010-05-16 Kf Replaced patched net/if_ppp.h by net/ppp_defs.h.
+// (Is linux/ppp_defs.h in the distribution.);
+#include <net/ppp_defs.h>
}
#include "PPPStats.H"
#include "Options.H"
+#include <iostream.h>
+#include <iostream>
+
+void get_command(char *);
+char command[200];
typedef struct
{
@@ -53,38 +59,44 @@
@@ -53,38 +61,46 @@
system( (const char*)options->cmd() );
}
- DclPPPInfo PPPInfo[1];
- struct ifreq ifreq;
+ DclPPPInfo PPPInfo[1];
+ struct ifpppstatsreq ifreq;
+// 2010-05-16 Kf Replaced patched struct ifpppstatsreq by the original
+// struct ifreq.
+ struct ifreq ifreq;
struct ppp_stats* PPPStat;
- struct ppp_stats LastPPPStat[1];
-
@ -96,7 +100,7 @@
unsigned int rxDelta = PPPStat->p.ppp_ibytes - _rxTotal;
unsigned int txDelta = PPPStat->p.ppp_obytes - _txTotal;
_rxTotal = PPPStat->p.ppp_ibytes;
@@ -92,4 +104,17 @@
@@ -92,4 +108,17 @@
if ( rxDelta == _rxTotal ) rxDelta = 0;
if ( txDelta == _txTotal ) txDelta = 0;
emit changeStats( rxDelta, txDelta, _rxTotal, _txTotal );