| @@ -1,39 +1,41 @@ | | | @@ -1,39 +1,41 @@ |
1 | # $NetBSD: sets.subr,v 1.94 2009/12/02 14:13:12 uebayasi Exp $ | | 1 | # $NetBSD: sets.subr,v 1.95 2009/12/02 14:28:24 uebayasi Exp $ |
2 | # | | 2 | # |
3 | | | 3 | |
4 | # | | 4 | # |
5 | # The following variables contain defaults for sets.subr functions and callers: | | 5 | # The following variables contain defaults for sets.subr functions and callers: |
6 | # setsdir path to src/distrib/sets | | 6 | # setsdir path to src/distrib/sets |
7 | # nlists list of base sets | | 7 | # nlists list of base sets |
8 | # xlists list of x11 sets | | 8 | # xlists list of x11 sets |
9 | # extlists list of extsrc sets | | 9 | # extlists list of extsrc sets |
10 | # obsolete controls if obsolete files are selected instead | | 10 | # obsolete controls if obsolete files are selected instead |
11 | # module if != "no", enable MODULE sets | | 11 | # module if != "no", enable MODULE sets |
12 | # shlib shared library format (a.out, elf, or "") | | 12 | # shlib shared library format (a.out, elf, or "") |
13 | # stlib static library format (a.out, elf) | | 13 | # stlib static library format (a.out, elf) |
14 | # | | 14 | # |
15 | # The following <bsd.own.mk> variables are exported to the environment: | | 15 | # The following <bsd.own.mk> variables are exported to the environment: |
16 | # MACHINE | | 16 | # MACHINE |
17 | # MACHINE_ARCH | | 17 | # MACHINE_ARCH |
18 | # MACHINE_CPU | | 18 | # MACHINE_CPU |
19 | # HAVE_BINUTILS | | 19 | # HAVE_BINUTILS |
20 | # HAVE_GCC | | 20 | # HAVE_GCC |
21 | # HAVE_GDB | | 21 | # HAVE_GDB |
22 | # TOOLCHAIN_MISSING | | 22 | # TOOLCHAIN_MISSING |
23 | # OBJECT_FMT | | 23 | # OBJECT_FMT |
24 | # as well as: | | 24 | # as well as: |
25 | # | | 25 | # |
26 | MKVARS="\ | | 26 | |
| | | 27 | # XXX don't hardcode |
| | | 28 | MKEXTRAVARS="\ |
27 | USE_INET6 \ | | 29 | USE_INET6 \ |
28 | USE_KERBEROS \ | | 30 | USE_KERBEROS \ |
29 | USE_LDAP \ | | 31 | USE_LDAP \ |
30 | USE_YP \ | | 32 | USE_YP \ |
31 | NETBSDSRCDIR \ | | 33 | NETBSDSRCDIR \ |
32 | MAKEVERBOSE \ | | 34 | MAKEVERBOSE \ |
33 | " | | 35 | " |
34 | # | | 36 | # |
35 | # The following variables refer to tools that are used when building sets: | | 37 | # The following variables refer to tools that are used when building sets: |
36 | # | | 38 | # |
37 | : ${AWK:=awk} | | 39 | : ${AWK:=awk} |
38 | : ${CKSUM:=cksum} | | 40 | : ${CKSUM:=cksum} |
39 | : ${COMM:=comm} | | 41 | : ${COMM:=comm} |
| @@ -131,33 +133,33 @@ MKMANPAGES=no | | | @@ -131,33 +133,33 @@ MKMANPAGES=no |
131 | MKMANPAGES=yes | | 133 | MKMANPAGES=yes |
132 | .endif | | 134 | .endif |
133 | .if \${MKX11} != "no" | | 135 | .if \${MKX11} != "no" |
134 | . if \${X11FLAVOUR} == "Xorg" | | 136 | . if \${X11FLAVOUR} == "Xorg" |
135 | MKXORG:=yes | | 137 | MKXORG:=yes |
136 | MKX11:=no | | 138 | MKX11:=no |
137 | . else | | 139 | . else |
138 | MKXORG:=no | | 140 | MKXORG:=no |
139 | . endif | | 141 | . endif |
140 | .endif | | 142 | .endif |
141 | all: | | 143 | all: |
142 | .for i in MACHINE MACHINE_ARCH MACHINE_CPU \ | | 144 | .for i in MACHINE MACHINE_ARCH MACHINE_CPU \ |
143 | HAVE_BINUTILS HAVE_GCC HAVE_GDB OBJECT_FMT TOOLCHAIN_MISSING \ | | 145 | HAVE_BINUTILS HAVE_GCC HAVE_GDB OBJECT_FMT TOOLCHAIN_MISSING \ |
144 | \${_MKVARS.yes} \${_MKVARS.no} | | 146 | ${MKEXTRAVARS} \${_MKVARS.yes} \${_MKVARS.no} |
145 | @echo "export \$i=\${\$i}" | | 147 | @echo "export \$i=\${\$i}" |
146 | .endfor | | 148 | .endfor |
147 | | | 149 | |
148 | EOMAKE | | 150 | EOMAKE |
149 | ); do | | 151 | ); do |
150 | # echo 1>&2 "DEBUG: read $x" | | 152 | echo 1>&2 "DEBUG: read $x" |
151 | eval $x | | 153 | eval $x |
152 | done | | 154 | done |
153 | IFS=$oIFS | | 155 | IFS=$oIFS |
154 | | | 156 | |
155 | setsdir=${0%/*} | | 157 | setsdir=${0%/*} |
156 | obsolete=0 | | 158 | obsolete=0 |
157 | module=yes | | 159 | module=yes |
158 | if [ "${MKKMOD}" = "no" ]; then | | 160 | if [ "${MKKMOD}" = "no" ]; then |
159 | module=no # MODULEs are off. | | 161 | module=no # MODULEs are off. |
160 | elif [ "${MACHINE}" = "evbppc" ]; then | | 162 | elif [ "${MACHINE}" = "evbppc" ]; then |
161 | module=no # Turn off MODULEs for some ports. | | 163 | module=no # Turn off MODULEs for some ports. |
162 | fi | | 164 | fi |
163 | # Determine lib type. Do this first so stlib also gets set. | | 165 | # Determine lib type. Do this first so stlib also gets set. |
| @@ -185,27 +187,27 @@ extlists="extbase extcomp extetc" | | | @@ -185,27 +187,27 @@ extlists="extbase extcomp extetc" |
185 | OSRELEASE=`${HOST_SH} ${NETBSDSRCDIR}/sys/conf/osrelease.sh` | | 187 | OSRELEASE=`${HOST_SH} ${NETBSDSRCDIR}/sys/conf/osrelease.sh` |
186 | MODULEDIR="stand/${MACHINE}/${OSRELEASE}/modules" | | 188 | MODULEDIR="stand/${MACHINE}/${OSRELEASE}/modules" |
187 | SUBST="s#@MODULEDIR@#${MODULEDIR}#g" | | 189 | SUBST="s#@MODULEDIR@#${MODULEDIR}#g" |
188 | SUBST="${SUBST};s#@OSRELEASE@#${OSRELEASE}#g" | | 190 | SUBST="${SUBST};s#@OSRELEASE@#${OSRELEASE}#g" |
189 | SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g" | | 191 | SUBST="${SUBST};s#@MACHINE@#${MACHINE}#g" |
190 | | | 192 | |
191 | # | | 193 | # |
192 | # list_set_files setfile [...] | | 194 | # list_set_files setfile [...] |
193 | # | | 195 | # |
194 | # Produce a packing list for setfile(s). | | 196 | # Produce a packing list for setfile(s). |
195 | # In each file, a record consists of a path and a System Package name, | | 197 | # In each file, a record consists of a path and a System Package name, |
196 | # separated by whitespace. E.g., | | 198 | # separated by whitespace. E.g., |
197 | # | | 199 | # |
198 | # # $NetBSD: sets.subr,v 1.94 2009/12/02 14:13:12 uebayasi Exp $ | | 200 | # # $NetBSD: sets.subr,v 1.95 2009/12/02 14:28:24 uebayasi Exp $ |
199 | # . base-sys-root [keyword[,...]] | | 201 | # . base-sys-root [keyword[,...]] |
200 | # ./altroot base-sys-root | | 202 | # ./altroot base-sys-root |
201 | # ./bin base-sys-root | | 203 | # ./bin base-sys-root |
202 | # ./bin/[ base-util-root | | 204 | # ./bin/[ base-util-root |
203 | # ./bin/cat base-util-root | | 205 | # ./bin/cat base-util-root |
204 | # [...] | | 206 | # [...] |
205 | # | | 207 | # |
206 | # A # in the first column marks a comment. | | 208 | # A # in the first column marks a comment. |
207 | # | | 209 | # |
208 | # If ${obsolete} != 0, only entries with an "obsolete" keyword will | | 210 | # If ${obsolete} != 0, only entries with an "obsolete" keyword will |
209 | # be printed. All other keywords must be present. | | 211 | # be printed. All other keywords must be present. |
210 | # | | 212 | # |
211 | # The third field is an optional comma separated list of keywords to | | 213 | # The third field is an optional comma separated list of keywords to |