diff options
author | wollman <wollman@FreeBSD.org> | 1995-01-19 22:28:38 +0000 |
---|---|---|
committer | wollman <wollman@FreeBSD.org> | 1995-01-19 22:28:38 +0000 |
commit | 5628e49063908f93a30b4ad48e408f81c0217afc (patch) | |
tree | b1741b5e5bcdc2068c246b5e7224b50aedec591b | |
parent | ece7af0e5603381a40bcf88083647e71ec6b9cb4 (diff) | |
download | FreeBSD-src-5628e49063908f93a30b4ad48e408f81c0217afc.zip FreeBSD-src-5628e49063908f93a30b4ad48e408f81c0217afc.tar.gz |
Port to FreeBSD.
-rw-r--r-- | lib/libss/Makefile | 32 | ||||
-rw-r--r-- | lib/libss/help.c | 7 | ||||
-rw-r--r-- | lib/libss/list_rqs.c | 4 | ||||
-rw-r--r-- | lib/libss/requests.c | 4 | ||||
-rw-r--r-- | lib/libss/ss.h | 10 |
5 files changed, 53 insertions, 4 deletions
diff --git a/lib/libss/Makefile b/lib/libss/Makefile new file mode 100644 index 0000000..c0d8104 --- /dev/null +++ b/lib/libss/Makefile @@ -0,0 +1,32 @@ +# $Id$ + +LIB= ss +SRCS= ss_err.c data.c error.c execute_cmd.c help.c invocation.c list_rqs.c \ + listen.c pager.c parse.c prompt.c request_tbl.c requests.c \ + std_rqs.c +CFLAGS+= -I. -I${.CURDIR} -DPOSIX -DIN_LIBSS +CLEANFILES+= ss ss_err.c ss_err.h std_rqs.c +LDADD+= -lcom_err + +ss_err.h ss_err.c: ss_err.et + test -e ss_err.et || ln -s ${.CURDIR}/ss_err.et . + compile_et ss_err.et + +std_rqs.c: std_rqs.ct + test -e std_rqs.ct || ln -s ${.CURDIR}/std_rqs.ct . + mk_cmds std_rqs.ct + ln -s ${.CURDIR} ss + +beforeinstall: + -cd ${.CURDIR}; cmp -s ss.h ${DESTDIR}/usr/include/ss/ss.h || \ + install -c -o ${BINOWN} -g ${BINGRP} -m 444 ss.h \ + ${DESTDIR}/usr/include/ss + -cd ${.CURDIR}; cmp -s copyright.h \ + ${DESTDIR}/usr/include/ss/mit-sipb-copyright.h || \ + install -c -o ${BINOWN} -g ${BINGRP} -m 444 copyright.h \ + ${DESTDIR}/usr/include/ss/mit-sipb-copyright.h + -cd ${.OBJDIR}; cmp -s ss_err.h ${DESTDIR}/usr/include/ss/ss_err.h || \ + install -c -o ${BINOWN} -g ${BINGRP} -m 444 ss_err.h \ + ${DESTDIR}/usr/include/ss + +.include <bsd.lib.mk> diff --git a/lib/libss/help.c b/lib/libss/help.c index 376d2ea..0a8edd2 100644 --- a/lib/libss/help.c +++ b/lib/libss/help.c @@ -74,7 +74,12 @@ got_it: ss_page_stdin(); default: (void) close(fd); /* what can we do if it fails? */ - while (wait((union wait *)NULL) != child) { +#ifndef POSIX + while (wait((union wait *)NULL) != child) +#else + while (wait((int *)NULL) != child) +#endif + { /* do nothing if wrong pid */ }; } diff --git a/lib/libss/list_rqs.c b/lib/libss/list_rqs.c index 6a9a974..95fe904 100644 --- a/lib/libss/list_rqs.c +++ b/lib/libss/list_rqs.c @@ -40,7 +40,11 @@ ss_list_requests(argc, argv, sci_idx, info_ptr) #else int (*func)(); #endif +#ifdef POSIX + int waitb; +#else union wait waitb; +#endif DONT_USE(argc); DONT_USE(argv); diff --git a/lib/libss/requests.c b/lib/libss/requests.c index bfe69f1..e4143f4 100644 --- a/lib/libss/requests.c +++ b/lib/libss/requests.c @@ -3,10 +3,10 @@ * * Copyright 1987, 1988, 1989 by MIT * - * For copyright information, see mit-sipb-copyright.h. + * For copyright information, see copyright.h. */ -#include "mit-sipb-copyright.h" +#include "copyright.h" #include <stdio.h> #include "ss_internal.h" diff --git a/lib/libss/ss.h b/lib/libss/ss.h index ca3197d..a727d8e 100644 --- a/lib/libss/ss.h +++ b/lib/libss/ss.h @@ -7,8 +7,16 @@ #ifndef _ss_h #define _ss_h __FILE__ +#if 0 #include <ss/mit-sipb-copyright.h> -#include <ss/ss_err.h> +#endif +#ifndef IN_MK_CMDS +# ifdef IN_LIBSS +# include "ss_err.h" +# else +# include <ss/ss_err.h> +# endif +#endif extern int errno; |