-# $OpenBSD: Makefile,v 1.33 2014/07/24 19:21:48 miod Exp $
+# $OpenBSD: Makefile,v 1.34 2014/12/23 17:16:00 deraadt Exp $
SUBDIR= libstubs \
- arch date dd dhclient dmesg ed eeprom ftp grep gzip ifconfig init \
- installboot kbd less md5 more mt newfs pax ping restore \
- sed sysctl signify ztsscale umount
+ arch bioctl cat chmod cp date dd df dhclient disklabel dmesg ed \
+ eeprom expr fdisk fsck fsck_ext2fs fsck_ffs fsck_msdos ftp grep \
+ gzip hostname ifconfig init installboot kbd ksh less ln ls md5 \
+ mkdir mknod mkuboot more mount mount_cd9660 mount_ext2fs \
+ mount_ffs mount_msdos mount_nfs mount_udf mt mv newfs newfs_ext2fs \
+ newfs_msdos pax pdisk ping ping6 reboot restore rm route sed \
+ signify sleep stty sync sysctl umount ztsscale
install:
.include <bsd.subdir.mk>
+
+
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:01 deraadt Exp $
+
+PROG= bioctl
+SRCS= bioctl.c
+
+LDADD= -lutil
+DPADD= ${LIBUTIL}
+
+CDIAGFLAGS= -Wall
+CDIAGFLAGS+= -Wpointer-arith
+CDIAGFLAGS+= -Wno-uninitialized
+CDIAGFLAGS+= -Wstrict-prototypes
+CDIAGFLAGS+= -Wmissing-prototypes
+CDIAGFLAGS+= -Wunused
+CDIAGFLAGS+= -Wsign-compare
+CDIAGFLAGS+= -Wshadow
+
+MAN= bioctl.8
+
+.PATH: ${.CURDIR}/../../../sbin/bioctl
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:01 deraadt Exp $
+
+PROG= cat
+
+.PATH: ${.CURDIR}/../../../bin/cat
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:01 deraadt Exp $
+
+PROG= chmod
+CFLAGS+=-DSUPPORT_DOT
+MAN= chmod.1 chgrp.1 chown.8 chflags.1
+LINKS= ${BINDIR}/chmod ${BINDIR}/chgrp \
+ ${BINDIR}/chmod /sbin/chown
+
+# XXX compatibility
+afterinstall:
+ (cd ${DESTDIR}/usr/sbin; \
+ ln -sf ../../sbin/chown .; \
+ ln -sf ../../bin/chgrp .)
+ (cd ${DESTDIR}/usr/bin; \
+ ln -sf ../../bin/chmod chflags)
+
+
+.PATH: ${.CURDIR}/../../../bin/chmod
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= cp
+SRCS= cp.c utils.c
+
+.PATH: ${.CURDIR}/../../../bin/cp
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= df
+SRCS= df.c ffs_df.c ext2fs_df.c
+LDADD= -lutil
+DPADD= ${LIBUTIL}
+
+.PATH: ${.CURDIR}/../../../bin/df
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= disklabel
+SRCS= disklabel.c dkcksum.c editor.c manual.c
+DPADD= ${LIBUTIL}
+LDADD= -lutil
+MAN= disklabel.8 disklabel.5
+
+CLEANFILES += disklabel.cat8 manual.c
+
+.include <bsd.own.mk>
+
+.ifdef NOMAN
+manual.c:
+ (echo 'const unsigned char manpage[] = {'; \
+ echo 'no manual' | gzip -9c | hexdump -ve '"0x" 1/1 "%02x,"'; \
+ echo '};'; echo 'const int manpage_sz = sizeof(manpage);') > manual.c
+.else
+disklabel.cat8: disklabel.8
+ mandoc -Tascii ${.ALLSRC} > ${.TARGET}
+
+manual.c: disklabel.cat8
+ (echo 'const unsigned char manpage[] = {'; \
+ cat disklabel.cat8 | gzip -9c | hexdump -ve '"0x" 1/1 "%02x,"'; \
+ echo '};'; echo 'const int manpage_sz = sizeof(manpage);') > manual.c
+.endif
+
+.if (${MACHINE} == "alpha")
+CFLAGS+= -DSEEALSO="\"fdisk(8), installboot(8)\""
+.endif
+
+.if (${MACHINE} == "amd64") || (${MACHINE} == "i386")
+CFLAGS+= -DSEEALSO="\"fdisk(8), installboot(8)\""
+.endif
+
+.if (${MACHINE} == "armish") || (${MACHINE} == "loongson")
+CFLAGS+= -DSEEALSO="\"fdisk(8)\""
+.endif
+
+.if (${MACHINE} == "hppa") || (${MACHINE} == "hppa64") || (${MACHINE} == "vax")
+CFLAGS+= -DNUMBOOT=1
+.endif
+
+.if (${MACHINE} == "landisk")
+CFLAGS+= -DNUMBOOT=1
+CFLAGS+= -DSEEALSO="\"fdisk(8)\""
+.endif
+
+.if (${MACHINE} == "macppc" || ${MACHINE} == "socppc")
+CFLAGS+= -DSEEALSO="\"fdisk(8), pdisk(8)\""
+.endif
+
+.if (${MACHINE} == "solbourne") || (${MACHINE} == "sparc") || \
+ (${MACHINE} == "sparc64")
+CFLAGS+= -DSEEALSO="\"installboot(8)\"" -DSUN_CYLCHECK -DSUN_AAT0
+.endif
+
+.if (${MACHINE} == "zaurus")
+CFLAGS+= -DSEEALSO="\"fdisk(8)\""
+.endif
+
+.ifdef NOPIC
+CFLAGS+= -DSTATICLINKING
+.endif
+
+.PATH: ${.CURDIR}/../../../sbin/disklabel
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= expr
+SRCS= expr.c
+
+.PATH: ${.CURDIR}/../../../bin/expr
+.include <bsd.prog.mk>
--- /dev/null
+#
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+#
+# Copyright (c) 1997 Tobias Weingartner
+# All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+# OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+# IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+# THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+#
+
+PROG= fdisk
+SRCS= fdisk.c user.c misc.c disk.c mbr.c part.c cmd.c manual.c
+DPADD= ${LIBUTIL}
+LDADD= -lutil
+CLEANFILES += fdisk.cat8 manual.c
+
+.include <bsd.own.mk>
+
+.ifdef NOMAN
+manual.c:
+ (echo 'const unsigned char manpage[] = {'; \
+ echo 'no manual' | gzip -9c | hexdump -ve '"0x" 1/1 "%02x,"'; \
+ echo '};'; echo 'const int manpage_sz = sizeof(manpage);') > manual.c
+.else
+fdisk.cat8: fdisk.8
+ mandoc -Tascii ${.ALLSRC} > ${.TARGET}
+
+manual.c: fdisk.cat8
+ (echo 'const unsigned char manpage[] = {'; \
+ cat fdisk.cat8 | gzip -9c | hexdump -ve '"0x" 1/1 "%02x,"'; \
+ echo '};'; echo 'const int manpage_sz = sizeof(manpage);') > manual.c
+.endif
+
+MAN= fdisk.8
+
+.if ${MACHINE} == "amd64" || ${MACHINE} == "i386" || \
+ ${MACHINE} == "landisk" || ${MACHINE} == "loongson" || \
+ ${MACHINE} == "macppc" || ${MACHINE} == "socppc"
+CFLAGS += -DHAS_MBR
+.endif
+
+# XXX gross
+.if ${MACHINE_ARCH} == "sh"
+CFLAGS += -fno-builtin-memcpy
+.endif
+
+.PATH: ${.CURDIR}/../../../sbin/fdisk
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= fsck
+SRCS= fsck.c fsutil.c preen.c
+MAN= fsck.8
+DPADD= ${LIBUTIL}
+LDADD= -lutil
+
+.PATH: ${.CURDIR}/../../../sbin/fsck
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= fsck_ext2fs
+MAN= fsck_ext2fs.8
+SRCS= dir.c inode.c main.c pass1.c pass1b.c pass2.c pass3.c pass4.c \
+ pass5.c fsutil.c setup.c utilities.c ext2fs_bswap.c
+CFLAGS+= -I${.CURDIR}/../../../sbin/fsck
+
+.PATH: ${.CURDIR}/../../../sbin/fsck_ext2fs
+.PATH: ${.CURDIR}/../../../sbin/fsck
+.PATH: ${.CURDIR}/../../../sys/ufs/ext2fs
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= fsck_ffs
+MAN= fsck_ffs.8
+SRCS= dir.c inode.c main.c pass1.c pass1b.c pass2.c pass3.c pass4.c \
+ pass5.c fsutil.c setup.c utilities.c ffs_subr.c ffs_tables.c
+CFLAGS+= -I${.CURDIR}/../../../sbin/fsck
+DPADD+= ${LIBUTIL}
+LDADD+= -lutil
+
+.PATH: ${.CURDIR}/../../../sbin/fsck_ffs
+.PATH: ${.CURDIR}/../../../sbin/fsck
+.PATH: ${.CURDIR}/../../../sys/ufs/ffs
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= fsck_msdos
+MAN= fsck_msdos.8
+SRCS= main.c check.c boot.c fat.c dir.c fsutil.c
+.PATH: ${.CURDIR}/../../../sbin/fsck
+CFLAGS+= -I${.CURDIR}/../../../sbin/fsck
+DPADD+= ${LIBUTIL}
+LDADD+= -lutil
+
+.PATH: ${.CURDIR}/../../../sbin/fsck_msdos
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= hostname
+
+.PATH: ${.CURDIR}/../../../bin/hostname
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= ksh
+SRCS= alloc.c c_ksh.c c_sh.c c_test.c c_ulimit.c edit.c emacs.c eval.c \
+ exec.c expr.c history.c io.c jobs.c lex.c mail.c main.c mknod.c \
+ misc.c path.c shf.c syn.c table.c trap.c tree.c tty.c var.c \
+ version.c vi.c
+
+DEFS= -Wall
+CFLAGS+=${DEFS} -I. -I${.CURDIR}/../../../bin/ksh -I${.CURDIR}/../../../lib/libc/gen
+MAN= ksh.1 sh.1
+
+LINKS= ${BINDIR}/ksh ${BINDIR}/rksh
+LINKS+= ${BINDIR}/ksh ${BINDIR}/sh
+MLINKS= ksh.1 rksh.1
+
+.PATH: ${.CURDIR}/../../../bin/ksh
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= ln
+MAN= ln.1 symlink.7
+
+.PATH: ${.CURDIR}/../../../bin/ln
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= ls
+SRCS= cmp.c ls.c main.c print.c util.c
+DPADD= ${LIBUTIL}
+LDADD= -lutil
+
+.PATH: ${.CURDIR}/../../../bin/ls
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mkdir
+
+.PATH: ${.CURDIR}/../../../bin/mkdir
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mknod
+MAN= mknod.8 mkfifo.1
+LINKS= ${BINDIR}/mknod ${BINDIR}/mkfifo
+
+.PATH: ${.CURDIR}/../../../sbin/mknod
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mount
+SRCS= mount.c
+DPADD= ${LIBUTIL}
+LDADD= -lutil
+MAN= mount.8
+
+.PATH: ${.CURDIR}/../../../sbin/mount
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mount_cd9660
+SRCS= mount_cd9660.c getmntopts.c
+MAN= mount_cd9660.8
+
+MOUNT= ${.CURDIR}/../../../sbin/mount
+CFLAGS+= -I${MOUNT}
+.PATH: ${MOUNT}
+
+.PATH: ${.CURDIR}/../../../sbin/mount_cd9660
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mount_ext2fs
+SRCS= mount_ext2fs.c getmntopts.c
+MAN= mount_ext2fs.8
+
+MOUNT= ${.CURDIR}/../../../sbin/mount
+CFLAGS+= -I${MOUNT}
+.PATH: ${MOUNT}
+
+.PATH: ${.CURDIR}/../../../sbin/mount_ext2fs
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mount_ffs
+SRCS= mount_ffs.c getmntopts.c
+MAN= mount_ffs.8
+
+MOUNT= ${.CURDIR}/../../../sbin/mount
+CFLAGS+= -I${MOUNT}
+.PATH: ${MOUNT}
+
+.PATH: ${.CURDIR}/../../../sbin/mount_ffs
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mount_msdos
+SRCS= mount_msdos.c getmntopts.c
+MAN= mount_msdos.8
+
+MOUNT= ${.CURDIR}/../../../sbin/mount
+CFLAGS+= -I${MOUNT}
+.PATH: ${MOUNT}
+
+.PATH: ${.CURDIR}/../../../sbin/mount_msdos
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mount_nfs
+SRCS= mount_nfs.c getmntopts.c
+MAN= mount_nfs.8
+
+MOUNT= ${.CURDIR}/../../../sbin/mount
+CFLAGS+= -DNFS -I${MOUNT}
+.PATH: ${MOUNT}
+
+.PATH: ${.CURDIR}/../../../sbin/mount_nfs
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mount_udf
+SRCS= mount_udf.c getmntopts.c
+MAN= mount_udf.8
+
+MOUNT= ${.CURDIR}/../../../sbin/mount
+CFLAGS+= -I${MOUNT}
+.PATH: ${MOUNT}
+
+.PATH: ${.CURDIR}/../../../sbin/mount_udf
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+PROG= mv
+
+DPADD+= ${LIBUTIL}
+LDADD+= -lutil
+
+.PATH: ${.CURDIR}/../../../bin/mv
+.include <bsd.prog.mk>
-# $OpenBSD: Makefile,v 1.2 2009/10/28 07:36:49 deraadt Exp $
+# $OpenBSD: Makefile,v 1.3 2014/12/23 17:16:02 deraadt Exp $
PROG= newfs
SRCS= dkcksum.c getmntopts.c newfs.c mkfs.c
CFLAGS+= -I${.CURDIR}/../../../sbin/mount
-.PATH: ${.CURDIR}/../../../sbin/newfs
-.PATH: ${.CURDIR}/../../../sbin/mount
-.PATH: ${.CURDIR}/../../../sbin/disklabel
LDADD+= -lutil
DPADD+= ${LIBUTIL}
+.PATH: ${.CURDIR}/../../../sbin/newfs
+.PATH: ${.CURDIR}/../../../sbin/mount
+.PATH: ${.CURDIR}/../../../sbin/disklabel
.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+PROG= newfs_ext2fs
+SRCS= newfs_ext2fs.c mke2fs.c ext2fs_bswap.c
+MAN= newfs_ext2fs.8
+
+.PATH: ${.CURDIR}/../../../sys/ufs/ext2fs
+DPADD+= ${LIBUTIL}
+LDADD+= -lutil
+
+.PATH: ${.CURDIR}/../../../sbin/newfs_ext2fs
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+# $FreeBSD: src/sbin/newfs_msdos/Makefile,v 1.2 1999/08/28 00:13:52 peter Exp $
+
+PROG= newfs_msdos
+MAN= newfs_msdos.8
+DPADD= ${LIBUTIL}
+LDADD= -lutil
+
+.PATH: ${.CURDIR}/../../../sbin/newfs_msdos
+.include <bsd.prog.mk>
--- /dev/null
+# $Id: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $
+
+.if ${MACHINE} == "macppc"
+PROG= pdisk
+LDADD= -lutil
+DPADD= ${LIBUTIL}
+CFLAGS+=-Wall
+
+SRCS= bitfield.c convert.c deblock_media.c dump.c errors.c \
+ file_media.c hfs_misc.c io.c media.c partition_map.c pathname.c \
+ pdisk.c util.c validate.c
+
+.else
+NOPROG=yes
+.endif
+
+MAN= pdisk.8
+MANSUBDIR=macppc
+
+.PATH: ${.CURDIR}/../../../sbin/pdisk
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:03 deraadt Exp $
+
+PROG= ping6
+
+CFLAGS+= -Wall
+CFLAGS+= -Wstrict-prototypes -Wmissing-prototypes
+CFLAGS+= -Wmissing-declarations
+CFLAGS+= -Wshadow -Wpointer-arith -Wcast-qual
+
+MAN= ping6.8
+
+LDADD= -lm
+DPADD= ${LIBM}
+
+BINOWN= root
+BINGRP= bin
+BINMODE=4555
+
+.PATH: ${.CURDIR}/../../../sbin/ping6
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:03 deraadt Exp $
+
+PROG= reboot
+DPADD= ${LIBUTIL}
+LDADD= -lutil
+MAN= reboot.8
+MLINKS= reboot.8 halt.8
+LINKS= ${BINDIR}/reboot ${BINDIR}/halt
+
+.PATH: ${.CURDIR}/../../../sbin/reboot
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:03 deraadt Exp $
+
+PROG= rm
+
+.PATH: ${.CURDIR}/../../../bin/rm
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:03 deraadt Exp $
+
+PROG= route
+MAN= route.8
+SRCS= route.c show.c
+
+CFLAGS+= -Wall
+
+route.o .depend lint tags: keywords.h
+
+.PATH: ${.CURDIR}/../../../sbin/route
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:03 deraadt Exp $
+
+PROG= sleep
+
+.PATH: ${.CURDIR}/../../../bin/sleep
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:03 deraadt Exp $
+
+PROG= stty
+SRCS= cchar.c gfmt.c key.c modes.c print.c stty.c
+
+.PATH: ${.CURDIR}/../../../bin/stty
+.include <bsd.prog.mk>
--- /dev/null
+# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:03 deraadt Exp $
+
+PROG= sync
+MAN= sync.8
+
+.PATH: ${.CURDIR}/../../../bin/sync
+.include <bsd.prog.mk>