Makefile revision 13132
1# from: @(#)Makefile 5.11 (Berkeley) 5/21/91 2# $Id: Makefile,v 1.128 1995/12/02 21:02:02 peter Exp $ 3 4# disktab may be wrong -- hcx9 is a tahoe, but gets its own. 5# -rw-r--r-- 6BINOWN= root 7BINGRP= wheel 8BIN1= aliases csh.cshrc csh.login csh.logout dm.conf \ 9 ftpusers gettytab group hosts host.conf hosts.equiv hosts.lpd \ 10 inetd.conf login.access motd modems netstart \ 11 networks phones pccard.conf printcap profile protocols \ 12 rc rc.local rc.serial etc.${MACHINE}/rc.${MACHINE} \ 13 remote security services sysconfig shells \ 14 syslog.conf ttys etc.${MACHINE}/disktab rpc make.conf \ 15 ${.CURDIR}/../gnu/usr.bin/man/manpath/manpath.config \ 16 ${.CURDIR}/../usr.bin/mail/misc/mail.rc 17 18# -rw-rw-rw- 19BIN2= motd 20 21# -rwxr-xr-x root.wheel, for the new cron root.wheel 22BIN3= daily weekly monthly 23 24CLEANFILES+= *.c *.o *.lo 25CLEANFILES+= filesystem filesystem.cache filesystem.mk 26CLEANFILES+= kcopy kcopy.cache kcopy.mk 27 28MAKEDEVS= (cd ${MOUNT}/dev; \ 29 sh ${DESTDIR}/dev/MAKEDEV std; \ 30 rm -rf fd; \ 31 sh ${DESTDIR}/dev/MAKEDEV fd0 fd1; \ 32 rm -rf fd0?* rfd0?* fd1?* rfd1?*; \ 33 sh ${DESTDIR}/dev/MAKEDEV wd0 wd1 sd0 sd1 cd0 mcd0 mcd1; \ 34 rm -rf *wd[01][ijklm] rmcd*) 35 36NEWFS= newfs -b 4096 -c 80 -f 512 -m 0 -o space -u 0 -t 0 37ZIPNSPLIT= gzip --no-name -9 -c | split -b 240640 - 38 39MTREE= BSD.local.dist BSD.root.dist BSD.usr.dist BSD.var.dist 40NAMEDB= PROTO.localhost.rev named.boot named.root make-localhost 41PPPCNF= ppp.conf.filter.sample ppp.conf.iij ppp.conf.sample \ 42 ppp.linkup.sample ppp.secret.sample 43PCS= pcs750.bin 44WCS1= wcs fppwcs poc poc1 poc2 fppoc 45WCS2= fpevent fppwcs fppwcs_dual hdcwcs load_diags start_fpp wcs wcs_dual 46 47# Special top level files for FreeBSD 48COPYRIGHT= COPYRIGHT 49FREEBSD= 50FREEBSD+= ${COPYRIGHT} 51# 52# Floppy drive name, mount point, type and parameters for building Floppies 53FLOPPY?= fd0 54MOUNT?= /mnt 55FLOPPY_TYPE?= fd1440 56FLOPPY_BS?= 18b 57FLOPPY_TRACKS?= 160 58# 59MDEC= usr/mdec/bootfd usr/mdec/fdboot 60MDEC+= usr/mdec/bootsd usr/mdec/sdboot 61MDEC+= usr/mdec/bootwd usr/mdec/wdboot 62# 63KC_DIRS= bin dev mnt sbin etc 64KC_FILES= ${COPYRIGHT} 65KC_LINKS= bin/[ bin/cp bin/echo bin/sh bin/test 66KC_LINKS+= sbin/fsck sbin/halt sbin/init 67KC_LINKS+= sbin/mount sbin/mount_cd9660 68KC_LINKS+= sbin/umount 69# 70CD_DIRS= etc usr 71# 72FILESYSTEM_DIRS= bin dev etc mnt proc sbin usr usr/bin usr/mdec usr/sbin 73FILESYSTEM_TREES= dev 74FILESYSTEM_FILES= ${COPYRIGHT} 75FILESYSTEM_FILES+= dev/MAKEDEV 76FILESYSTEM_FILES+= etc/group 77FILESYSTEM_FILES+= etc/master.passwd etc/passwd etc/pwd.db 78FILESYSTEM_FILES+= ${MDEC} 79FILESYSTEM_LINKS= bin/[ bin/expr bin/ls bin/mkdir bin/rm 80FILESYSTEM_LINKS+= bin/sh bin/sync bin/test 81FILESYSTEM_LINKS+= sbin/disklabel sbin/fdisk sbin/halt sbin/init 82FILESYSTEM_LINKS+= sbin/mount 83FILESYSTEM_LINKS+= sbin/newfs 84FILESYSTEM_LINKS+= sbin/umount 85FILESYSTEM_LINKS+= usr/bin/cpio 86FILESYSTEM_LINKS+= usr/bin/gunzip usr/bin/gzcat usr/bin/gzip usr/bin/zcat 87FILESYSTEM_LINKS+= usr/sbin/bad144 88FILESYSTEM_CPIO= .profile 89FILESYSTEM_CPIO+= root/.profile 90FILESYSTEM_CPIO+= bin/[ 91FILESYSTEM_CPIO+= bin/chmod bin/cat bin/cp bin/df bin/expr bin/ls 92FILESYSTEM_CPIO+= bin/ln bin/mkdir bin/mv bin/rm bin/sync 93FILESYSTEM_CPIO+= bin/test 94FILESYSTEM_CPIO+= etc/spwd.db 95FILESYSTEM_CPIO+= sbin/disklabel sbin/fdisk sbin/halt sbin/init 96FILESYSTEM_CPIO+= sbin/mount 97FILESYSTEM_CPIO+= sbin/newfs 98FILESYSTEM_CPIO+= sbin/umount 99FILESYSTEM_CPIO_DIRS= root 100 101CPIO_FILES= ${COPYRIGHT} 102CPIO_CPIO= bin/dd bin/ps bin/pwd bin/stty 103CPIO_CPIO+= etc/protocols etc/remote etc/services 104CPIO_CPIO+= etc/termcap 105CPIO_CPIO+= sbin/dmesg 106CPIO_CPIO+= sbin/ifconfig sbin/fsck sbin/mknod sbin/mount_cd9660 107CPIO_CPIO+= sbin/mount_procfs 108CPIO_CPIO+= sbin/reboot sbin/route sbin/slattach 109CPIO_CPIO+= usr/bin/awk usr/bin/chgrp usr/bin/cpio usr/bin/ex usr/bin/ftp 110CPIO_CPIO+= usr/bin/gunzip usr/bin/gzcat usr/bin/gzip 111CPIO_CPIO+= usr/bin/more usr/bin/tar usr/bin/tip 112CPIO_CPIO+= usr/bin/vi usr/bin/view usr/bin/zcat 113CPIO_CPIO+= usr/lib/libc.so.* 114CPIO_CPIO+= usr/lib/libcurses.so.* 115CPIO_CPIO+= usr/lib/libgcc.so.* 116CPIO_CPIO+= usr/lib/libm.so.* 117CPIO_CPIO+= usr/lib/libtermcap.so.* 118CPIO_CPIO+= usr/lib/libutil.so.* 119CPIO_CPIO+= usr/libexec/ld.so 120CPIO_CPIO+= usr/sbin/bad144 usr/sbin/chown 121CPIO_CPIO+= usr/share/misc/termcap 122CPIO_CPIO_DIRS= tmp usr/lib usr/libexec usr/share usr/share/misc 123CPIO_CPIO_DIRS+= var var/tmp var/run var/spool var/spool/lock 124 125SCRYPT_LIB= lib/libcrypt 126DESCRYPT_LIB= secure/lib/libcrypt 127CRYPT_SRCS= bin/ed bin/rcp 128CRYPT_SRCS+= sbin/init 129.if !defined(NOCRYPT) 130CRYPT_SRCS+= secure 131.endif 132CRYPT_DIRS= bin sbin usr usr/bin usr/lib 133 134# Compatibility stuff, remove those links 135LATIN1LINKS = \ 136 da_DK de_AT de_CH de_DE en_AU en_CA en_GB en_US es_ES fi_FI \ 137 fr_BE fr_CA fr_CH fr_FR is_IS it_CH it_IT nl_BE nl_NL no_NO \ 138 pt_PT sv_SE 139 140all depend etc install lint: 141 142scrypt: 143 rm -f ${LIBCRYPT}; 144 (cd ${.CURDIR}/../${SCRYPT_LIB}; \ 145 ${MAKE} cleandir obj depend all install) 146 for i in ${CRYPT_SRCS}; do \ 147 cd ${.CURDIR}/../$$i; \ 148 ${MAKE} cleandir obj depend all; \ 149 done 150 151descrypt: 152 rm -f ${LIBCRYPT}; 153 (cd ${.CURDIR}/../${DESCRYPT_LIB}; \ 154 ${MAKE} cleandir obj depend all install) 155 for i in ${CRYPT_SRCS}; do \ 156 cd ${.CURDIR}/../$$i; \ 157 ${MAKE} cleandir obj depend all; \ 158 done 159 160distribute: 161 cd ${.CURDIR} ; ${MAKE} distribution DESTDIR=${DISTDIR}/bin 162 163distribution: 164 (cd ${.CURDIR}; \ 165 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 ${BIN1} ${DESTDIR}/etc; \ 166 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 666 ${BIN2} ${DESTDIR}/etc; \ 167 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 ${BIN3} ${DESTDIR}/etc; \ 168 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 crontab ${DESTDIR}/etc; \ 169 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 /dev/null \ 170 ${DESTDIR}/var/cron/log; \ 171 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 600 \ 172 master.passwd ${DESTDIR}/etc; \ 173 pwd_mkdb -p -d ${DESTDIR}/etc ${DESTDIR}/etc/master.passwd; \ 174 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 555 \ 175 MAKEDEV.local etc.${MACHINE}/MAKEDEV ${DESTDIR}/dev ) 176 (cd ${DESTDIR}/dev; sh MAKEDEV all) ; 177 (cd ${.CURDIR}/root; \ 178 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.fvwmrc \ 179 ${DESTDIR}/root/.fvwmrc; \ 180 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.Xdefaults \ 181 ${DESTDIR}/root/.Xdefaults; \ 182 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.xsession \ 183 ${DESTDIR}/root/.xsession; \ 184 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.cshrc \ 185 ${DESTDIR}/root/.cshrc; \ 186 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.klogin \ 187 ${DESTDIR}/root/.klogin; \ 188 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.login \ 189 ${DESTDIR}/root/.login; \ 190 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 dot.profile \ 191 ${DESTDIR}/root/.profile; \ 192 rm -f ${DESTDIR}/.cshrc ${DESTDIR}/.profile; \ 193 ln ${DESTDIR}/root/.cshrc ${DESTDIR}/.cshrc; \ 194 ln ${DESTDIR}/root/.profile ${DESTDIR}/.profile) 195 cd ${.CURDIR}/mtree; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 \ 196 ${MTREE} ${DESTDIR}/etc/mtree 197 cd ${.CURDIR}/namedb; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \ 198 ${NAMEDB} ${DESTDIR}/etc/namedb 199 cd ${.CURDIR}/ppp; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 \ 200 ${PPPCNF} ${DESTDIR}/etc/ppp 201 ${INSTALL} -c -o ${BINOWN} -g operator -m 664 /dev/null \ 202 ${DESTDIR}/etc/dumpdates 203 ${INSTALL} -c -o nobody -g ${BINGRP} -m 664 /dev/null \ 204 ${DESTDIR}/var/db/locate.database 205 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \ 206 ${DESTDIR}/var/log/lpd-errs 207 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \ 208 ${DESTDIR}/var/log/maillog 209 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \ 210 ${DESTDIR}/var/log/lastlog 211 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \ 212 ${DESTDIR}/var/log/messages 213 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \ 214 ${DESTDIR}/var/log/wtmp 215 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 /dev/null \ 216 ${DESTDIR}/var/run/utmp 217 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 664 ${.CURDIR}/minfree \ 218 ${DESTDIR}/var/crash 219 (cd ${.CURDIR}/../usr.sbin/sendmail/src; \ 220 ${MAKE} obj; \ 221 ${MAKE} all; \ 222 ${MAKE} install; \ 223 cd ../cf/cf; \ 224 ${MAKE} obj; \ 225 ${MAKE} freebsd.cf; \ 226 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 644 obj/freebsd.cf \ 227 ${DESTDIR}/etc/sendmail.cf) 228 (cd ${.CURDIR}/..; \ 229 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 444 ${FREEBSD} \ 230 ${DESTDIR}/) 231 (cd ${.CURDIR}/../share/man; ${MAKE} makedb; ) 232 233crunch: 234 crunchgen ${.CURDIR}/../usr.sbin/crunch/examples/kcopy.conf 235 ${MAKE} -f kcopy.mk objs exe 236 crunchgen ${.CURDIR}/../usr.sbin/crunch/examples/filesystem.conf 237 ${MAKE} -f filesystem.mk objs exe 238 239extract: 240 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 555 \ 241 ${.CURDIR}/etc.i386/EXTRACT_bin.sh \ 242 ${RELEASEDIR}/tarballs/bin/EXTRACT.sh 243 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 555 \ 244 ${.CURDIR}/etc.i386/EXTRACT_src.sh \ 245 ${RELEASEDIR}/tarballs/bin/EXTRACT.sh 246 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 555 \ 247 ${.CURDIR}/etc.i386/EXTRACT_secr.sh \ 248 ${RELEASEDIR}/tarballs/bin/EXTRACT.sh 249 250hcx9-distribution: 251 (cd ${.CURDIR}/etc.tahoe; ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} \ 252 -m 444 ${WCS2} ${DESTDIR}/) 253 254kcopy-kernels: ${.CURDIR}/../sys/i386/conf/GENERIC 255 (cd ${.CURDIR}/../sys/compile; rm -rf GENERIC) 256 (cd ${.CURDIR}/../sys/i386/conf; config GENERIC) 257 (cd ${.CURDIR}/../sys/compile/GENERIC; ${MAKE} depend; ${MAKE} all; \ 258 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 kernel \ 259 ${DESTDIR}/kernel.GENERIC) 260 261kcopy-floppy: 262 echo y | fdformat ${FLOPPY} 263 disklabel -w -r -B -b ${DESTDIR}/usr/mdec/fdboot \ 264 -s ${DESTDIR}/usr/mdec/bootfd ${FLOPPY} ${FLOPPY_TYPE} 265 ${NEWFS} -i 8192 r${FLOPPY} ${FLOPPY_TYPE} 266 mount /dev/${FLOPPY} ${MOUNT} 267 chown ${BINOWN}.${BINGRP} ${MOUNT}/. 268 chmod 755 ${MOUNT}/. 269 (cd ${DESTDIR}/; \ 270 ls -d ${KC_DIRS} | cpio -pdamuv ${MOUNT}) 271 ${MAKEDEVS} 272 (cd ${DESTDIR}/; \ 273 ls ${KC_FILES} | cpio -pdamuv ${MOUNT}) 274 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 275 ${.CURDIR}/etc.i386/kc.profile ${MOUNT}/etc/rc 276 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 277 kcopy ${MOUNT}/bin/kcopy 278 (cd ${MOUNT}/; \ 279 for i in ${KC_LINKS}; do \ 280 ln bin/kcopy $$i; \ 281 done) 282 283kcopy.flp: 284 (cd ${.CURDIR}; ${MAKE} kcopy-floppy) 285 (cd ${.CURDIR}/../sys/compile/GENERIC; \ 286 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 kernel ${MOUNT}/) 287 df -ik ${MOUNT} 288 # XXX umount is returning 1 for some reason :-( 289 -umount /dev/${FLOPPY} 290 fsck /dev/r${FLOPPY} 291 dd if=/dev/r${FLOPPY} of=${RELEASEDIR}/floppies/kcopy.flp \ 292 bs=${FLOPPY_BS} count=${FLOPPY_TRACKS} 293 gzip --no-name -9 -c ${RELEASEDIR}/floppies/kcopy.flp \ 294 >${RELEASEDIR}/floppies/kcopy.flp.gz & 295 296cdins-floppy: 297 (cd ${.CURDIR}; ${MAKE} kcopy-floppy) 298 (cd ${DESTDIR}/; \ 299 ls -d ${CD_DIRS} | cpio -pdamuv ${MOUNT}) 300 (cd ${MOUNT}/usr; \ 301 ln -s /cdrom/filesys/usr/libexec libexec; \ 302 ln -s /cdrom/filesys/usr/lib lib) 303 mkdir ${MOUNT}/cdrom 304 chown ${BINOWN}.${BINGRP} ${MOUNT}/cdrom 305 chmod 755 ${MOUNT}/cdrom 306 #${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 307 # ${.CURDIR}/etc.i386/cdinst1.profile ${MOUNT}/.profile 308 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 309 ${.CURDIR}/etc.i386/cdinst1.install ${MOUNT}/install 310 ln ${MOUNT}/install ${MOUNT}/etc/rc 311 312cdins.flp: 313 (cd ${.CURDIR}; ${MAKE} kcopy-floppy) 314 (cd ${.CURDIR}/../sys/compile/GENERIC; \ 315 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 kernel ${MOUNT}/) 316 df -ik ${MOUNT} 317 # XXX umount is returning 1 for some reason :-( 318 -umount /dev/${FLOPPY} 319 fsck /dev/r${FLOPPY} 320 dd if=/dev/r${FLOPPY} of=${RELEASEDIR}/floppies/cdins.flp \ 321 bs=${FLOPPY_BS} count=${FLOPPY_TRACKS} 322 gzip --no-name -9 -c ${RELEASEDIR}/floppies/cdins.flp \ 323 >${RELEASEDIR}/floppies/cdins.flp.gz & 324 325filesyst.flp: 326 echo y | fdformat ${FLOPPY} 327 disklabel -w -r -B -b ${DESTDIR}/usr/mdec/fdboot \ 328 -s ${DESTDIR}/usr/mdec/bootfd ${FLOPPY} ${FLOPPY_TYPE} 329 ${NEWFS} -i 10240 r${FLOPPY} ${FLOPPY_TYPE} 330 mount /dev/${FLOPPY} ${MOUNT} 331 chown ${BINOWN}.${BINGRP} ${MOUNT}/. 332 chmod 755 ${MOUNT}/. 333 (cd ${DESTDIR}/; \ 334 ls -d ${FILESYSTEM_DIRS} | cpio -pdamuv ${MOUNT}) 335 ${MAKEDEVS} 336 (cd ${DESTDIR}/; \ 337 ls ${FILESYSTEM_FILES} | cpio -pdamuv ${MOUNT}; \ 338 (find ${FILESYSTEM_CPIO}; ls -d ${FILESYSTEM_CPIO_DIRS}) | \ 339 cpio -H newc --block-size=16 -oav | \ 340 gzip -9 >${MOUNT}/inst1.cpio.gz) 341 #${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 342 # ${.CURDIR}/etc.i386/inst1.profile ${MOUNT}/.profile 343 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 344 ${.CURDIR}/etc.i386/inst1.install ${MOUNT}/install 345 ln ${MOUNT}/install ${MOUNT}/etc/rc 346 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 347 filesystem ${MOUNT}/bin/filesystem 348 (cd ${MOUNT}/; \ 349 for i in ${FILESYSTEM_LINKS}; do \ 350 ln bin/filesystem $$i; \ 351 done) 352 (cd ${MOUNT}/; \ 353 ls ${FILESYSTEM_FILES} >/tmp/filelist; \ 354 ls ${FILESYSTEM_LINKS} >>/tmp/filelist; \ 355 ls -d ${FILESYSTEM_DIRS} >>/tmp/filelist; \ 356 find ${FILESYSTEM_TREES} >>/tmp/filelist; \ 357 sort -u -r /tmp/filelist >filelist; \ 358 rm /tmp/filelist) 359 df -ik ${MOUNT} 360 # XXX umount is returning 1 for some reason :-( 361 -umount /dev/${FLOPPY} 362 fsck /dev/r${FLOPPY} 363 dd if=/dev/r${FLOPPY} of=${RELEASEDIR}/floppies/filesyst.flp \ 364 bs=${FLOPPY_BS} count=${FLOPPY_TRACKS} 365 gzip --no-name -9 -c ${RELEASEDIR}/floppies/filesyst.flp \ 366 >${RELEASEDIR}/floppies/filesyst.flp.gz & 367 368cpio.flp: 369 echo y | fdformat ${FLOPPY} 370 disklabel -w -r -B -b ${DESTDIR}/usr/mdec/fdboot \ 371 -s ${DESTDIR}/usr/mdec/bootfd ${FLOPPY} ${FLOPPY_TYPE} 372 ${NEWFS} -i 65536 r${FLOPPY} ${FLOPPY_TYPE} 373 mount /dev/${FLOPPY} ${MOUNT} 374 chown ${BINOWN}.${BINGRP} ${MOUNT}/. 375 chmod 755 ${MOUNT}/. 376 (cd ${DESTDIR}/; \ 377 ls ${CPIO_FILES} | cpio -pdamuv ${MOUNT}) 378 # 379 # XXX This ugliness is because the default termcap file is simply too 380 # big and we don't need such a hugh one for the initial installation, 381 # yet we want the symlink in /etc to point to the right place so we 382 # need to install the smaller one in the same location. 383 # 384 mv ${DESTDIR}/usr/share/misc/termcap ${DESTDIR}/usr/share/misc/otermcap 385 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 386 ${.CURDIR}/termcap.small ${DESTDIR}/usr/share/misc/termcap 387 (cd ${DESTDIR}/; \ 388 (find ${CPIO_CPIO}; ls -d ${CPIO_CPIO_DIRS}) | \ 389 cpio -H newc --block-size=16 -oav | \ 390 gzip -9 >${MOUNT}/inst2.cpio.gz) 391 # XXX cpio is done, put everything back in shape for the bindist. 392 mv ${DESTDIR}/usr/share/misc/otermcap ${DESTDIR}/usr/share/misc/termcap 393 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 394 ${.CURDIR}/etc.i386/cpio.rc ${MOUNT}/rc 395 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 396 ${.CURDIR}/etc.i386/cpio.install ${MOUNT}/install 397 ${INSTALL} -c -o ${BINOWN} -g ${BINGRP} -m 755 \ 398 ${.CURDIR}/etc.i386/cpio.magic ${MOUNT}/magic 399 df -ik ${MOUNT} 400 # XXX umount is returning 1 for some reason :-( 401 -umount /dev/${FLOPPY} 402 fsck /dev/r${FLOPPY} 403 dd if=/dev/r${FLOPPY} of=${RELEASEDIR}/floppies/cpio.flp \ 404 bs=${FLOPPY_BS} count=${FLOPPY_TRACKS} 405 gzip --no-name -9 -c ${RELEASEDIR}/floppies/cpio.flp \ 406 >${RELEASEDIR}/floppies/cpio.flp.gz & 407 408bin-tarball: 409 (cd ${DESTDIR}; \ 410 mkdir -p ${RELEASEDIR}/tarballs/bin; \ 411 tar cf - . | \ 412 ${ZIPNSPLIT} ${RELEASEDIR}/tarballs/bin/bin.) 413 414des-tarball: 415 rm -rf ${RELEASEDIR}/tmpdes 416 mkdir ${RELEASEDIR}/tmpdes 417 for i in ${CRYPT_DIRS}; do \ 418 cd ${RELEASEDIR}/tmpdes; \ 419 mkdir $$i; \ 420 chown ${BINOWN}.${GRPOWN} $$i; \ 421 chmod 755 $$i; \ 422 done 423 # This is ugly, it force installs a /usr/lib/libcrypt.a so 424 # that the other makes will be built with des. 425 # 426 (set -x ; cd ${.CURDIR}/../${DESCRYPT_LIB}; \ 427 NOCRYPT=; \ 428 unset NOCRYPT; \ 429 DESTDIR=; export DESTDIR; \ 430 ${MAKE} cleandir obj depend all install; \ 431 NOMAN=noman; export NOMAN; \ 432 DESTDIR=${RELEASEDIR}/tmpdes; export DESTDIR; \ 433 ${MAKE} cleandir obj depend all install) 434 for i in ${CRYPT_SRCS}; do \ 435 NOCRYPT=; \ 436 unset NOCRYPT; \ 437 DESTDIR=${RELEASEDIR}/tmpdes; export DESTDIR; \ 438 NOMAN=noman; export NOMAN; \ 439 cd ${.CURDIR}/../$$i; \ 440 ${MAKE} cleandir obj depend all install; \ 441 done 442 (cd ${RELEASEDIR}/tmpdes; \ 443 tar cf - . | \ 444 ${ZIPNSPLIT} ${RELEASEDIR}/tarballs/des/des_tgz.) 445 rm -rf ${RELEASEDIR}/tmpdes 446 447distrib-dirs: 448 mtree -deU -f ${.CURDIR}/mtree/BSD.root.dist -p ${DESTDIR}/ 449 mtree -deU -f ${.CURDIR}/mtree/BSD.var.dist -p ${DESTDIR}/var 450# Compatibility stuff, remove obsoleted links, if exists 451 if [ -d ${DESTDIR}/usr/share/locale ] ; \ 452 then \ 453 cd ${DESTDIR}/usr/share/locale; \ 454 for l in ${LATIN1LINKS} ; do \ 455 if [ -h $$l.ISO_8859-1 ]; then \ 456 rm $$l.ISO_8859-1; \ 457 fi ; \ 458 done; \ 459 fi 460 mtree -deU -f ${.CURDIR}/mtree/BSD.usr.dist -p ${DESTDIR}/usr 461 mtree -deU -f ${.CURDIR}/mtree/BSD.include.dist \ 462 -p ${DESTDIR}/usr/include 463.if defined(MAKE_LOCAL) 464 mtree -deU -f ${.CURDIR}/mtree/BSD.local.dist -p ${DESTDIR}/usr/local 465.endif 466 cd ${DESTDIR}/; rm -f ${DESTDIR}/sys; ln -s usr/src/sys sys 467 cd ${DESTDIR}/usr/share/locale; \ 468 set - `cat ${.CURDIR}/locale.alias`; \ 469 while [ $$# -gt 0 ] ; \ 470 do \ 471 rm -rf "$$1"; \ 472 ln -s "$$2" "$$1"; \ 473 shift; shift; \ 474 done 475 cd ${DESTDIR}/usr/share/nls; \ 476 set - `cat ${.CURDIR}/locale.alias`; \ 477 while [ $$# -gt 0 ] ; \ 478 do \ 479 rm -rf "$$1"; \ 480 ln -s "$$2" "$$1"; \ 481 shift; shift; \ 482 done; \ 483 rm -rf POSIX; \ 484 ln -s C POSIX 485.if defined(MAKE_LOCAL) 486 cd ${DESTDIR}/usr/local/share/nls; \ 487 set - `cat ${.CURDIR}/locale.alias`; \ 488 while [ $$# -gt 0 ] ; \ 489 do \ 490 rm -rf "$$1"; \ 491 ln -s "$$2" "$$1"; \ 492 shift; shift; \ 493 done; \ 494 rm -rf POSIX; \ 495 ln -s C POSIX 496.endif 497 498floppies: kcopy.flp filesyst.flp cpio.flp cdins.flp 499 500release: release-dirs distribution crunch extract kcopy-kernels \ 501 floppies bin-tarball des-tarball clean 502 503release-dirs: 504 chflags -R noschg ${RELEASEDIR}/ 505 rm -rf ${RELEASEDIR}/* 506 mtree -d -U -f ${.CURDIR}/mtree/BSD.release.dist -p ${RELEASEDIR} 507 508.include <bsd.prog.mk> 509