mirror of
https://git.freebsd.org/ports.git
synced 2025-05-27 08:26:27 -04:00
14 lines
349 B
Bash
14 lines
349 B
Bash
#!/bin/sh
|
|
#
|
|
# c2mdoc -- Front-end which abuses the cproto parser to spit out
|
|
# mdoc(7) format prototypes for use in FreeBSD documentation.
|
|
|
|
AWKSCRIPT="%%LIBEXECDIR%%/c2mdoc.awk"
|
|
CPROTO='-P"int\tf\t(\ta\t,\tb\t)" -pq -f3'
|
|
CPROTO_BIN=cproto
|
|
export CPROTO
|
|
|
|
${CPROTO_BIN} $1 | \
|
|
grep -v '/\*.*\*/' | \
|
|
sed -e 's/[,();]//g' | \
|
|
${AWKSCRIPT}
|