From: kn Date: Sun, 23 Jul 2023 23:21:19 +0000 (+0000) Subject: use SMALL to save a shave mfs and tmpfs bits in install media X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=6f87656abf262433be6a0e21f8069e72ec4dac2d;p=openbsd use SMALL to save a shave mfs and tmpfs bits in install media RAMDISK* has MFS and TMPFS disabled, so the installer can't use them. OK deraadt --- diff --git a/distrib/special/mount/Makefile b/distrib/special/mount/Makefile index ef62add6dc8..05cc7cc9453 100644 --- a/distrib/special/mount/Makefile +++ b/distrib/special/mount/Makefile @@ -1,7 +1,8 @@ -# $OpenBSD: Makefile,v 1.1 2014/12/23 17:16:02 deraadt Exp $ +# $OpenBSD: Makefile,v 1.2 2023/07/23 23:21:19 kn Exp $ PROG= mount SRCS= mount.c +COPTS+= -DSMALL DPADD= ${LIBUTIL} LDADD= -lutil MAN= mount.8 diff --git a/sbin/mount/mount.c b/sbin/mount/mount.c index b9805191148..eaff190b572 100644 --- a/sbin/mount/mount.c +++ b/sbin/mount/mount.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mount.c,v 1.76 2022/12/04 23:50:46 cheloha Exp $ */ +/* $OpenBSD: mount.c,v 1.77 2023/07/23 23:21:19 kn Exp $ */ /* $NetBSD: mount.c,v 1.24 1995/11/18 03:34:29 cgd Exp $ */ /* @@ -565,6 +565,7 @@ prmount(struct statfs *sf) (void)printf(", %s=%d", "acdirmax", nfs_args->acdirmax); } +#ifndef SMALL } else if (strcmp(sf->f_fstypename, MOUNT_MFS) == 0) { int headerlen; long blocksize; @@ -573,6 +574,7 @@ prmount(struct statfs *sf) header = getbsize(&headerlen, &blocksize); (void)printf("%s%s=%lu %s", !f++ ? " (" : ", ", "size", sf->mount_info.mfs_args.size / blocksize, header); +#endif /* SMALL */ } else if (strcmp(sf->f_fstypename, MOUNT_MSDOS) == 0) { struct msdosfs_args *msdosfs_args = &sf->mount_info.msdosfs_args; @@ -597,6 +599,7 @@ prmount(struct statfs *sf) (void)printf("%s%s", !f++ ? " (" : ", ", "gens"); if (iso_args->flags & ISOFSMNT_EXTATT) (void)printf("%s%s", !f++ ? " (" : ", ", "extatt"); +#ifndef SMALL } else if (strcmp(sf->f_fstypename, MOUNT_TMPFS) == 0) { struct tmpfs_args *tmpfs_args = &sf->mount_info.tmpfs_args; @@ -612,6 +615,7 @@ prmount(struct statfs *sf) if (verbose || tmpfs_args->ta_nodes_max) (void)printf("%s%s=%lu", !f++ ? " (" : ", ", "inodes", (unsigned long)tmpfs_args->ta_nodes_max); +#endif /* SMALL */ } (void)printf(f ? ")\n" : "\n"); }