diff options
author | dwcjr <dwcjr@FreeBSD.org> | 2002-06-17 13:42:09 +0000 |
---|---|---|
committer | dwcjr <dwcjr@FreeBSD.org> | 2002-06-17 13:42:09 +0000 |
commit | fe68ecd2a2104321653788804320cf6fb49b5182 (patch) | |
tree | eb80d7533a8034f056c46e0c098e2de1de13df0d | |
parent | b315038fea440a08556d1da752e15ca22b16aed7 (diff) | |
download | FreeBSD-ports-fe68ecd2a2104321653788804320cf6fb49b5182.zip FreeBSD-ports-fe68ecd2a2104321653788804320cf6fb49b5182.tar.gz |
Fix building on -current
Approved by: maintainer
-rw-r--r-- | comms/ltmdm/Makefile | 9 | ||||
-rw-r--r-- | comms/ltmdm/files/current-fix | 88 |
2 files changed, 96 insertions, 1 deletions
diff --git a/comms/ltmdm/Makefile b/comms/ltmdm/Makefile index 9d611e3..d8c8d52 100644 --- a/comms/ltmdm/Makefile +++ b/comms/ltmdm/Makefile @@ -7,6 +7,7 @@ PORTNAME= ltmdm PORTVERSION= 1.4 +PORTREVISION= 1 CATEGORIES= comms MASTER_SITES= http://www.dons.net.au/~darius/ \ http://www.csociety.org/~will/ \ @@ -53,4 +54,10 @@ do-install: .endif @${CAT} ${PKGMESSAGE} -.include <bsd.port.mk> +.include <bsd.port.pre.mk> +.if ${OSVERSION} >= 500000 +do-patch: + @${CAT} files/current-fix | ${PATCH} +.endif + +.include <bsd.port.post.mk> diff --git a/comms/ltmdm/files/current-fix b/comms/ltmdm/files/current-fix new file mode 100644 index 0000000..749ae35 --- /dev/null +++ b/comms/ltmdm/files/current-fix @@ -0,0 +1,88 @@ +--- work/sys/dev/ltmdm/ltmdmsio.c Tue Mar 12 02:47:31 2002 ++++ work/sys/dev/ltmdm/ltmdmsio.c Tue Jun 11 04:49:45 2002 +@@ -123,12 +123,6 @@ + #define lt_enable_intr() enable_intr() + #endif + +-#if __FreeBSD_version >= 500023 /* >= 20010912 */ +-#define proc thread /* temporary hack: struct proc -> stuct thread */ +-#define suser(p) suser_td(p) +-#endif +- +- + #define LOTS_OF_EVENTS 64 /* helps separate urgent events from input */ + + #define CALLOUT_MASK 0x80 +@@ -1470,7 +1464,7 @@ + } + + static int +-sioopen(dev_t dev, int flag, int mode, struct proc *p) ++sioopen(dev_t dev, int flag, int mode, struct thread *td) + { + struct com_s *com; + int error; +@@ -1528,7 +1522,7 @@ + } + } + if (tp->t_state & TS_XCLUDE && +- suser(p)) { ++ suser(td)) { + error = EBUSY; + goto out; + } +@@ -1639,7 +1633,7 @@ + } + + static int +-sioclose(dev_t dev, int flag, int mode, struct proc *p) ++sioclose(dev_t dev, int flag, int mode, struct thread *td) + { + struct com_s *com; + int mynor; +@@ -1906,8 +1900,7 @@ + if ((modem_status ^ com->last_modem_status) & MSR_DCD) { + tc = timecounter; + count = tc->tc_get_timecount(tc); +- pps_event(&com->pps, tc, count, +- (modem_status & MSR_DCD) ? ++ pps_event(&com->pps, (modem_status & MSR_DCD) ? + PPS_CAPTUREASSERT : PPS_CAPTURECLEAR); + } + } +@@ -2053,7 +2046,7 @@ + } + + static int +-sioioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct proc *p) ++sioioctl(dev_t dev, u_long cmd, caddr_t data, int flag, struct thread *td) + { + struct com_s *com; + int error; +@@ -2084,7 +2077,7 @@ + } + switch (cmd) { + case TIOCSETA: +- error = suser(p); ++ error = suser(td); + if (error != 0) + return (error); + *ct = *(struct termios *)data; +@@ -2134,7 +2127,7 @@ + if (lt->c_ospeed != 0) + dt->c_ospeed = tp->t_ospeed; + } +- error = (*linesw[tp->t_line].l_ioctl)(tp, cmd, data, flag, p); ++ error = (*linesw[tp->t_line].l_ioctl)(tp, cmd, data, flag, td); + if (error != ENOIOCTL) + return (error); + s = splfunc(); +@@ -2175,7 +2168,7 @@ + break; + case TIOCMSDTRWAIT: + /* must be root since the wait applies to following logins */ +- error = suser(p); ++ error = suser(td); + if (error != 0) { + splx(s); + return (error); |