profile progressbar proto pr_routes ps pwd pwdauth \
ramdisk rarpd rawspeed rcp rdate readall readclock \
readfs reboot remsync rev rget rlogin rlogind rmdir \
- rotate rsh rshd service setup shar size \
+ rotate rsh rshd sed service setup shar size \
sleep slip sort spell split srccrc stat strings strip \
stty su sum svclog swapfs swifi sync synctree sysenv \
syslogd tail talk talkd tcpd tcpdp tcpstat tee telnet \
# $NetBSD: Makefile,v 1.13 2006/06/02 19:44:48 mrg Exp $
# from: @(#)Makefile 8.1 (Berkeley) 6/6/93
-.include <bsd.own.mk>
+.include <minix.own.mk>
PROG= sed
SRCS= compile.c main.c misc.c process.c
-WARNS= 2
-.include <bsd.prog.mk>
+.include <minix.prog.mk>
#endif
#include <sys/cdefs.h>
-#ifndef lint
-__COPYRIGHT("@(#) Copyright (c) 1992, 1993\
- The Regents of the University of California. All rights reserved.");
-#endif /* not lint */
-
-#ifndef lint
-#if 0
-static char sccsid[] = "@(#)main.c 8.2 (Berkeley) 1/3/94";
-#else
-__RCSID("$NetBSD: main.c,v 1.19 2008/09/16 13:32:04 perry Exp $");
-#endif
-#endif /* not lint */
#include <sys/types.h>
{
int c, fflag;
- setprogname(*argv);
fflag = 0;
while ((c = getopt(argc, argv, "ae:f:nrE")) != -1)
switch (c) {
#endif
#include <sys/cdefs.h>
-#ifndef lint
-#if 0
-static char sccsid[] = "@(#)process.c 8.6 (Berkeley) 4/20/94";
-#else
-__RCSID("$NetBSD: process.c,v 1.37 2006/06/18 05:16:41 gdamore Exp $");
-#endif
-#endif /* not lint */
#include <sys/types.h>
#include <sys/stat.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#include <termios.h>
#include "defs.h"
#include "extern.h"
#define hs HS.space
#define hsl HS.len
-static inline int applies(struct s_command *);
+static __inline int applies(struct s_command *);
static void flush_appends(void);
static void lputs(char *);
-static inline int regexec_e(regex_t *, const char *, int, int, size_t);
+static __inline int regexec_e(regex_t *, const char *, int, int, size_t);
static void regsub(SPACE *, char *, char *);
static int substitute(struct s_command *);
* Return TRUE if the command applies to the current line. Sets the inrange
* flag to process ranges. Interprets the non-select (``!'') flag.
*/
-static inline int
+static __inline int
applies(struct s_command *cp)
{
int r;
err(FATAL, "stdout: %s", strerror(errno ? errno : EIO));
}
-static inline int
+static __inline int
regexec_e(regex_t *preg, const char *string, int eflags, int nomatch, size_t slen)
{
int eval;