Commit Graph

20 Commits

Author SHA1 Message Date
Warner Losh
1d386b48a5 Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
2023-08-16 11:54:42 -06:00
Ben Laurie
9bde021a87 Fix clang warnings.
Note: these were actually bugs (printf with no format string).

Approved by: philip (mentor)
2011-05-18 20:52:52 +00:00
Ed Schouten
ef636796f6 ANSIfy various tools in usr.bin/.
Most of these tools properly build at WARNS=6, except for their K&R
function declarations. Fix this, so we can bump WARNS as well.
2010-01-02 10:09:20 +00:00
Xin LI
821df508e8 Revert most part of 200420 as requested, as more review and polish is
needed.
2009-12-13 03:14:06 +00:00
Xin LI
6f2d322192 Remove unneeded header includes from usr.bin/ except contributed code.
Tested with:	make universe
2009-12-11 23:35:38 +00:00
David Malone
e390e3af7c Use ANSI definitions.
Avoid using extern by declaring shared functions in header files.
Const poision.
2005-11-13 21:17:24 +00:00
Stefan Farfeleder
896cdc310c Stop generating the `register' keyword. 2005-09-02 10:32:05 +00:00
Stefan Farfeleder
15df5e2d43 Don't generate K&R C code. The -C flag is kept for backwards compatibility.
Also remove the SIG_PF macro, there is no need to cast closedown.
2005-09-02 10:23:26 +00:00
Stefan Farfeleder
ec06b5e868 Only write the dispatch table function prototypes to the header if the -h
flag was specified.  If all files are generated at once, those functions are
static and shouldn't appear in the header.

PR:		84450
Reviewed by:	alfred
2005-09-01 19:16:25 +00:00
Stefan Farfeleder
d0cc804bba - Use prototypes in headers.
- Include rpc_scan.h before rpc_util.h for the tok_kind enum.
- Nuke unused declarations.
2005-08-31 20:45:15 +00:00
Stefan Farfeleder
63f1737128 Move #ident into #if 0. 2005-05-31 20:00:29 +00:00
Philippe Charnier
75863a6dbb Removal of spaces at EOL. Add __FBSDID. New function xmalloc, xrealloc,
xstrdup. There is a crash() function that do cleaning before exiting the
program. The new functions are wrappers that make use of crash() in case
of allocation failure. warn, exit -> err.

Reviewed by:	alfred
2002-07-21 12:55:04 +00:00
Alfred Perlstein
651feb6587 WARNS=2 2002-07-14 17:55:35 +00:00
Alfred Perlstein
40ad88851b - TI-RPC is now the default again for code generation.
- As before, inetd support support is turned of per default.
  Code for inetd can be made with -I.

- Support for ``transport monitors'' and the NLSPROVIDER env
  variable is still there , even if their use is not clear in
  non TLI stream based systems like Free-/NetBSD. It can be activated
  with -P.

- There are a few corrections in rpcgen.1 and usage function to conform
  to the code. Added and documented -P

- I removed the #ifdefs checks for Free-/NetBSD since we are the only
  ones who use this code. MaxOS X may have the same limitations as
  we have, so this code will correctly build for them.

- Generate correct cflags.

Submitted by: mbr, Jean-Luc Richier <Jean-Luc.Richier@imag.fr>
PR: bin/29175, misc/27816
2002-07-14 17:54:00 +00:00
Warner Losh
d3cb5ded92 remove __P 2002-03-22 01:33:25 +00:00
Alfred Perlstein
7e440a74e8 Have rpcgen output the prototypes for the dispatch tables 2001-11-13 11:08:29 +00:00
Jordan K. Hubbard
526195ad0d General -Wall warning cleanup, part I.
Submitted-By: Kent Vander Velden <graphix@iastate.edu>
1996-07-12 19:08:36 +00:00
Bill Paul
ff49530f45 Clean up. (I hope I'm doing this right.)
Update rpcgen with the one from the TI-RPC 2.3 distribution.

Note that when built for FreeBSD, this version of rpcgen assumes
backwards compatibility mode by default. This means that it will produce
ONCRPC 4.0 compatible code unless otherwise instructed, instead of the
other way around.

One incompatibility has also been worked around: this rpcgen normally
always emits an '#include <stropts.h>' directive whether you select
backwards compatibility mode or not. We don't have STREAMS, so this
behavior has been changed: now it will only emit this line if run in TI-RPC
mode.

The 'generate output files in current directory instead of the
directory where the protocol definition file lives' hack from the
original rpcgen has been preserved.

Notable new features:

- Can be used to generate RPC servers that can be launched
  from port monitors such as inetd(5).

- Can generate ANSI C code.

- Can generate sample client and server top-level programs and
  makefiles in addition to the usual client and server stubs.

- Can generate inline XDR routines.
1995-12-13 03:31:10 +00:00
Rodney W. Grimes
7799f52a32 Remove trailing whitespace. 1995-05-30 06:41:30 +00:00
Garrett Wollman
4e115012be Move RPC stub generator program over from 1.1.5.
Submitted by:	Original work in 1.x by J. T. Conklin.
1994-08-07 18:01:39 +00:00