Deleted Added
full compact
makeman (173400) makeman (174548)
1#!/bin/sh
2#
3# This file is in the public domain.
4
1#!/bin/sh
2#
3# This file is in the public domain.
4
5ident='$FreeBSD: head/tools/build/options/makeman 173400 2007-11-06 23:12:53Z danger $'
5ident='$FreeBSD: head/tools/build/options/makeman 174548 2007-12-12 16:39:32Z ru $'
6
7#
8# usage: show { settings | options } ...
9#
10show()
11{
12
13 mode=$1; shift

--- 30 unchanged lines hidden (view full) ---

44 ;;
45 esac
46 done
47}
48
49main()
50{
51
6
7#
8# usage: show { settings | options } ...
9#
10show()
11{
12
13 mode=$1; shift

--- 30 unchanged lines hidden (view full) ---

44 ;;
45 esac
46 done
47}
48
49main()
50{
51
52 trap 'rm -f _config _config2 _deps' exit
52 trap 'rm -f _defcfg _config _config2 _deps _deps2' exit
53 ident=${ident#$}
54 ident=${ident% $}
55 fbsdid='$'FreeBSD'$'
56 cat <<EOF
57.\" DO NOT EDIT-- this file is automatically generated.
58.\" from ${ident}
59.\" ${fbsdid}
60.Dd $(LC_TIME=C date +'%B %e, %Y')

--- 68 unchanged lines hidden (view full) ---

129Just the existence of an option will cause
130it to be honoured by
131.Xr make 1 .
132.Pp
133The following list provides a name and short description for variables
134that can be used for source builds.
135.Bl -tag -width indent
136EOF
53 ident=${ident#$}
54 ident=${ident% $}
55 fbsdid='$'FreeBSD'$'
56 cat <<EOF
57.\" DO NOT EDIT-- this file is automatically generated.
58.\" from ${ident}
59.\" ${fbsdid}
60.Dd $(LC_TIME=C date +'%B %e, %Y')

--- 68 unchanged lines hidden (view full) ---

129Just the existence of an option will cause
130it to be honoured by
131.Xr make 1 .
132.Pp
133The following list provides a name and short description for variables
134that can be used for source builds.
135.Bl -tag -width indent
136EOF
137 show settings |sort >_config
137 show settings |sort >_defcfg
138 show options |
139 while read opt; do
140 if [ -f ${opt} ]; then
141 cat <<EOF
142.It Va ${opt}
143EOF
144 sed -e's/\$\(FreeBSD: .*\) \$/from \1/' ${opt}
145 else
146 echo "no description found for ${opt}, skipping" >/dev/stderr
147 continue
148 fi
138 show options |
139 while read opt; do
140 if [ -f ${opt} ]; then
141 cat <<EOF
142.It Va ${opt}
143EOF
144 sed -e's/\$\(FreeBSD: .*\) \$/from \1/' ${opt}
145 else
146 echo "no description found for ${opt}, skipping" >/dev/stderr
147 continue
148 fi
149 show settings -D${opt} |sort >_config2
150 comm -13 _config _config2 |grep -v "^${opt}$" >_deps
149 show settings -D${opt} |sort >_config
150 comm -13 _defcfg _config |grep -v "^${opt}$" >_deps
151 if [ -s _deps ]; then
152 cat <<EOF
153When set, it also enforces the following options:
154.Pp
155.Bl -item -compact
156EOF
157 cat _deps |while read opt2; do
158 cat <<EOF
159.It
160.Va ${opt2}
161EOF
151 if [ -s _deps ]; then
152 cat <<EOF
153When set, it also enforces the following options:
154.Pp
155.Bl -item -compact
156EOF
157 cat _deps |while read opt2; do
158 cat <<EOF
159.It
160.Va ${opt2}
161EOF
162 show settings -D${opt} $(
163 echo ${opt2} |
164 sed -e's/^WITHOUT_/-DWITH_/' -e's/^WITH_/-DWITHOUT_/'
165 ) |sort >_config2
166 comm -13 _config _config2 >_deps2
167 if [ -s _deps2 ]; then
168 cat <<EOF
169(can be overridden with
170.Va $(cat _deps2) )
171EOF
172 fi
162 done
163 cat <<EOF
164.El
165EOF
166 fi
167 done
168 cat <<EOF
169.El

--- 21 unchanged lines hidden ---
173 done
174 cat <<EOF
175.El
176EOF
177 fi
178 done
179 cat <<EOF
180.El

--- 21 unchanged lines hidden ---