From 5fd83771641d15c418f747bd343ba6738d3875f7 Mon Sep 17 00:00:00 2001 From: Cameron Katri Date: Sun, 9 May 2021 14:20:58 -0400 Subject: Import macOS userland adv_cmds-176 basic_cmds-55 bootstrap_cmds-116.100.1 developer_cmds-66 diskdev_cmds-667.40.1 doc_cmds-53.60.1 file_cmds-321.40.3 mail_cmds-35 misc_cmds-34 network_cmds-606.40.1 patch_cmds-17 remote_cmds-63 shell_cmds-216.60.1 system_cmds-880.60.2 text_cmds-106 --- diskdev_cmds/APPLE_LICENSE | 367 +++ diskdev_cmds/dev_mkdb.tproj/dev_mkdb.8 | 81 + diskdev_cmds/dev_mkdb.tproj/dev_mkdb.c | 202 ++ .../diskdev_cmds.xcodeproj/project.pbxproj | 2411 ++++++++++++++++++++ .../project.xcworkspace/contents.xcworkspacedata | 7 + .../xcshareddata/WorkspaceSettings.xcsettings | 8 + .../xcshareddata/xcschemes/All_MacOSX.xcscheme | 61 + .../xcshareddata/xcschemes/All_iOS.xcscheme | 61 + .../xcshareddata/xcschemes/Common.xcscheme | 61 + .../xcshareddata/xcschemes/dev_mkdb.xcscheme | 88 + .../xcshareddata/xcschemes/edquota.xcscheme | 88 + .../xcshareddata/xcschemes/fdisk.xcscheme | 88 + .../xcshareddata/xcschemes/fsck.xcscheme | 88 + .../xcshareddata/xcschemes/fstyp.xcscheme | 88 + .../xcshareddata/xcschemes/fstyp_msdos.xcscheme | 88 + .../xcshareddata/xcschemes/fstyp_ntfs.xcscheme | 88 + .../xcshareddata/xcschemes/fstyp_udf.xcscheme | 88 + .../xcshareddata/xcschemes/fuser.xcscheme | 88 + .../xcshareddata/xcschemes/libdisk.xcscheme | 61 + .../xcshareddata/xcschemes/mount.xcscheme | 88 + .../xcshareddata/xcschemes/mount_devfs.xcscheme | 88 + .../xcshareddata/xcschemes/mount_fdesc.xcscheme | 88 + .../xcshareddata/xcschemes/quota.xcscheme | 88 + .../xcshareddata/xcschemes/quotacheck.xcscheme | 88 + .../xcshareddata/xcschemes/quotaon.xcscheme | 88 + .../xcshareddata/xcschemes/repquota.xcscheme | 88 + .../xcshareddata/xcschemes/setclass.xcscheme | 88 + .../xcshareddata/xcschemes/umount.xcscheme | 88 + .../xcshareddata/xcschemes/vndevice.xcscheme | 88 + .../xcshareddata/xcschemes/vsdbutil.xcscheme | 88 + diskdev_cmds/disklib/dkcksum.c | 77 + diskdev_cmds/disklib/dkdisklabel.c | 193 ++ diskdev_cmds/disklib/dkopen.c | 57 + diskdev_cmds/disklib/dkopen.h | 56 + diskdev_cmds/disklib/dksecsize.c | 75 + diskdev_cmds/disklib/pathnames.h | 63 + diskdev_cmds/disklib/preen.c | 392 ++++ diskdev_cmds/disklib/vfslist.c | 112 + diskdev_cmds/edquota.tproj/edquota.8 | 184 ++ diskdev_cmds/edquota.tproj/edquota.c | 1228 ++++++++++ diskdev_cmds/edquota.tproj/pathnames.h | 61 + diskdev_cmds/edt_fstab/edt_fstab.c | 180 ++ diskdev_cmds/edt_fstab/edt_fstab.h | 47 + diskdev_cmds/fdisk.tproj/auto.c | 155 ++ diskdev_cmds/fdisk.tproj/auto.h | 31 + diskdev_cmds/fdisk.tproj/cmd.c | 507 ++++ diskdev_cmds/fdisk.tproj/cmd.h | 105 + diskdev_cmds/fdisk.tproj/disk.c | 309 +++ diskdev_cmds/fdisk.tproj/disk.h | 83 + diskdev_cmds/fdisk.tproj/fdisk.8 | 377 +++ diskdev_cmds/fdisk.tproj/fdisk.c | 289 +++ diskdev_cmds/fdisk.tproj/getrawpartition.c | 87 + diskdev_cmds/fdisk.tproj/mbr.c | 553 +++++ diskdev_cmds/fdisk.tproj/mbr.h | 114 + diskdev_cmds/fdisk.tproj/mbrcode.h | 119 + diskdev_cmds/fdisk.tproj/misc.c | 183 ++ diskdev_cmds/fdisk.tproj/misc.h | 74 + diskdev_cmds/fdisk.tproj/opendev.c | 111 + diskdev_cmds/fdisk.tproj/part.c | 425 ++++ diskdev_cmds/fdisk.tproj/part.h | 80 + diskdev_cmds/fdisk.tproj/user.c | 275 +++ diskdev_cmds/fdisk.tproj/user.h | 65 + diskdev_cmds/fdisk.tproj/util.h | 137 ++ diskdev_cmds/fsck.tproj/fsck.8 | 176 ++ diskdev_cmds/fsck.tproj/fsck.c | 1339 +++++++++++ diskdev_cmds/fsck.tproj/fsck.h | 121 + diskdev_cmds/fstyp.tproj/fstyp.8 | 41 + diskdev_cmds/fstyp.tproj/fstyp.c | 167 ++ diskdev_cmds/fstyp.tproj/fstyp_msdos.8 | 41 + diskdev_cmds/fstyp.tproj/fstyp_msdos.c | 213 ++ diskdev_cmds/fstyp.tproj/fstyp_ntfs.8 | 41 + diskdev_cmds/fstyp.tproj/fstyp_ntfs.c | 206 ++ diskdev_cmds/fstyp.tproj/fstyp_udf.8 | 40 + diskdev_cmds/fstyp.tproj/fstyp_udf.c | 306 +++ diskdev_cmds/fuser.tproj/fuser.1 | 200 ++ diskdev_cmds/fuser.tproj/fuser.pl | 92 + diskdev_cmds/mount.tproj/fstab.5 | 222 ++ diskdev_cmds/mount.tproj/mount.8 | 293 +++ diskdev_cmds/mount.tproj/mount.c | 1696 ++++++++++++++ diskdev_cmds/mount.tproj/mount.entitlements | 12 + diskdev_cmds/mount.tproj/pathnames.h | 63 + diskdev_cmds/mount_devfs.tproj/mount_devfs.c | 117 + diskdev_cmds/mount_fdesc.tproj/mount_fdesc.8 | 171 ++ diskdev_cmds/mount_fdesc.tproj/mount_fdesc.c | 128 ++ diskdev_cmds/mount_flags_dir/mount_flags.c | 88 + diskdev_cmds/mount_flags_dir/mount_flags.h | 66 + diskdev_cmds/quota.tproj/quota.1 | 137 ++ diskdev_cmds/quota.tproj/quota.c | 858 +++++++ diskdev_cmds/quotacheck.tproj/hfs_quotacheck.c | 169 ++ diskdev_cmds/quotacheck.tproj/quotacheck.8 | 156 ++ diskdev_cmds/quotacheck.tproj/quotacheck.c | 972 ++++++++ diskdev_cmds/quotacheck.tproj/quotacheck.h | 87 + diskdev_cmds/quotaon.tproj/quotaon.8 | 159 ++ diskdev_cmds/quotaon.tproj/quotaon.c | 400 ++++ diskdev_cmds/repquota.tproj/repquota.8 | 109 + diskdev_cmds/repquota.tproj/repquota.c | 630 +++++ diskdev_cmds/setclass.tproj/setclass.8 | 46 + diskdev_cmds/setclass.tproj/setclass.c | 153 ++ diskdev_cmds/umount.tproj/umount.8 | 133 ++ diskdev_cmds/umount.tproj/umount.c | 655 ++++++ diskdev_cmds/vndevice.tproj/vndevice.c | 134 ++ .../vsdbutil.tproj/com.apple.vsdbutil.plist | 21 + diskdev_cmds/vsdbutil.tproj/vsdbutil.8 | 49 + diskdev_cmds/vsdbutil.tproj/vsdbutil_main.c | 1213 ++++++++++ 104 files changed, 23804 insertions(+) create mode 100644 diskdev_cmds/APPLE_LICENSE create mode 100644 diskdev_cmds/dev_mkdb.tproj/dev_mkdb.8 create mode 100644 diskdev_cmds/dev_mkdb.tproj/dev_mkdb.c create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/project.pbxproj create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/contents.xcworkspacedata create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_MacOSX.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_iOS.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/Common.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/dev_mkdb.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/edquota.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fdisk.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fsck.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_msdos.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_ntfs.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_udf.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fuser.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/libdisk.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_devfs.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_fdesc.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quota.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotacheck.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotaon.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/repquota.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/setclass.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/umount.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vndevice.xcscheme create mode 100644 diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vsdbutil.xcscheme create mode 100644 diskdev_cmds/disklib/dkcksum.c create mode 100644 diskdev_cmds/disklib/dkdisklabel.c create mode 100644 diskdev_cmds/disklib/dkopen.c create mode 100644 diskdev_cmds/disklib/dkopen.h create mode 100644 diskdev_cmds/disklib/dksecsize.c create mode 100644 diskdev_cmds/disklib/pathnames.h create mode 100644 diskdev_cmds/disklib/preen.c create mode 100644 diskdev_cmds/disklib/vfslist.c create mode 100644 diskdev_cmds/edquota.tproj/edquota.8 create mode 100644 diskdev_cmds/edquota.tproj/edquota.c create mode 100644 diskdev_cmds/edquota.tproj/pathnames.h create mode 100644 diskdev_cmds/edt_fstab/edt_fstab.c create mode 100644 diskdev_cmds/edt_fstab/edt_fstab.h create mode 100644 diskdev_cmds/fdisk.tproj/auto.c create mode 100644 diskdev_cmds/fdisk.tproj/auto.h create mode 100644 diskdev_cmds/fdisk.tproj/cmd.c create mode 100644 diskdev_cmds/fdisk.tproj/cmd.h create mode 100644 diskdev_cmds/fdisk.tproj/disk.c create mode 100644 diskdev_cmds/fdisk.tproj/disk.h create mode 100644 diskdev_cmds/fdisk.tproj/fdisk.8 create mode 100644 diskdev_cmds/fdisk.tproj/fdisk.c create mode 100644 diskdev_cmds/fdisk.tproj/getrawpartition.c create mode 100644 diskdev_cmds/fdisk.tproj/mbr.c create mode 100644 diskdev_cmds/fdisk.tproj/mbr.h create mode 100644 diskdev_cmds/fdisk.tproj/mbrcode.h create mode 100644 diskdev_cmds/fdisk.tproj/misc.c create mode 100644 diskdev_cmds/fdisk.tproj/misc.h create mode 100644 diskdev_cmds/fdisk.tproj/opendev.c create mode 100644 diskdev_cmds/fdisk.tproj/part.c create mode 100644 diskdev_cmds/fdisk.tproj/part.h create mode 100644 diskdev_cmds/fdisk.tproj/user.c create mode 100644 diskdev_cmds/fdisk.tproj/user.h create mode 100644 diskdev_cmds/fdisk.tproj/util.h create mode 100644 diskdev_cmds/fsck.tproj/fsck.8 create mode 100644 diskdev_cmds/fsck.tproj/fsck.c create mode 100644 diskdev_cmds/fsck.tproj/fsck.h create mode 100644 diskdev_cmds/fstyp.tproj/fstyp.8 create mode 100644 diskdev_cmds/fstyp.tproj/fstyp.c create mode 100644 diskdev_cmds/fstyp.tproj/fstyp_msdos.8 create mode 100644 diskdev_cmds/fstyp.tproj/fstyp_msdos.c create mode 100644 diskdev_cmds/fstyp.tproj/fstyp_ntfs.8 create mode 100644 diskdev_cmds/fstyp.tproj/fstyp_ntfs.c create mode 100644 diskdev_cmds/fstyp.tproj/fstyp_udf.8 create mode 100644 diskdev_cmds/fstyp.tproj/fstyp_udf.c create mode 100644 diskdev_cmds/fuser.tproj/fuser.1 create mode 100755 diskdev_cmds/fuser.tproj/fuser.pl create mode 100644 diskdev_cmds/mount.tproj/fstab.5 create mode 100644 diskdev_cmds/mount.tproj/mount.8 create mode 100644 diskdev_cmds/mount.tproj/mount.c create mode 100644 diskdev_cmds/mount.tproj/mount.entitlements create mode 100644 diskdev_cmds/mount.tproj/pathnames.h create mode 100644 diskdev_cmds/mount_devfs.tproj/mount_devfs.c create mode 100644 diskdev_cmds/mount_fdesc.tproj/mount_fdesc.8 create mode 100644 diskdev_cmds/mount_fdesc.tproj/mount_fdesc.c create mode 100644 diskdev_cmds/mount_flags_dir/mount_flags.c create mode 100644 diskdev_cmds/mount_flags_dir/mount_flags.h create mode 100644 diskdev_cmds/quota.tproj/quota.1 create mode 100644 diskdev_cmds/quota.tproj/quota.c create mode 100644 diskdev_cmds/quotacheck.tproj/hfs_quotacheck.c create mode 100644 diskdev_cmds/quotacheck.tproj/quotacheck.8 create mode 100644 diskdev_cmds/quotacheck.tproj/quotacheck.c create mode 100644 diskdev_cmds/quotacheck.tproj/quotacheck.h create mode 100644 diskdev_cmds/quotaon.tproj/quotaon.8 create mode 100644 diskdev_cmds/quotaon.tproj/quotaon.c create mode 100644 diskdev_cmds/repquota.tproj/repquota.8 create mode 100644 diskdev_cmds/repquota.tproj/repquota.c create mode 100644 diskdev_cmds/setclass.tproj/setclass.8 create mode 100644 diskdev_cmds/setclass.tproj/setclass.c create mode 100644 diskdev_cmds/umount.tproj/umount.8 create mode 100644 diskdev_cmds/umount.tproj/umount.c create mode 100644 diskdev_cmds/vndevice.tproj/vndevice.c create mode 100644 diskdev_cmds/vsdbutil.tproj/com.apple.vsdbutil.plist create mode 100644 diskdev_cmds/vsdbutil.tproj/vsdbutil.8 create mode 100644 diskdev_cmds/vsdbutil.tproj/vsdbutil_main.c (limited to 'diskdev_cmds') diff --git a/diskdev_cmds/APPLE_LICENSE b/diskdev_cmds/APPLE_LICENSE new file mode 100644 index 0000000..fe81a60 --- /dev/null +++ b/diskdev_cmds/APPLE_LICENSE @@ -0,0 +1,367 @@ +APPLE PUBLIC SOURCE LICENSE +Version 2.0 - August 6, 2003 + +Please read this License carefully before downloading this software. +By downloading or using this software, you are agreeing to be bound by +the terms of this License. If you do not or cannot agree to the terms +of this License, please do not download or use the software. + +1. General; Definitions. This License applies to any program or other +work which Apple Computer, Inc. ("Apple") makes publicly available and +which contains a notice placed by Apple identifying such program or +work as "Original Code" and stating that it is subject to the terms of +this Apple Public Source License version 2.0 ("License"). As used in +this License: + +1.1 "Applicable Patent Rights" mean: (a) in the case where Apple is +the grantor of rights, (i) claims of patents that are now or hereafter +acquired, owned by or assigned to Apple and (ii) that cover subject +matter contained in the Original Code, but only to the extent +necessary to use, reproduce and/or distribute the Original Code +without infringement; and (b) in the case where You are the grantor of +rights, (i) claims of patents that are now or hereafter acquired, +owned by or assigned to You and (ii) that cover subject matter in Your +Modifications, taken alone or in combination with Original Code. + +1.2 "Contributor" means any person or entity that creates or +contributes to the creation of Modifications. + +1.3 "Covered Code" means the Original Code, Modifications, the +combination of Original Code and any Modifications, and/or any +respective portions thereof. + +1.4 "Externally Deploy" means: (a) to sublicense, distribute or +otherwise make Covered Code available, directly or indirectly, to +anyone other than You; and/or (b) to use Covered Code, alone or as +part of a Larger Work, in any way to provide a service, including but +not limited to delivery of content, through electronic communication +with a client other than You. + +1.5 "Larger Work" means a work which combines Covered Code or portions +thereof with code not governed by the terms of this License. + +1.6 "Modifications" mean any addition to, deletion from, and/or change +to, the substance and/or structure of the Original Code, any previous +Modifications, the combination of Original Code and any previous +Modifications, and/or any respective portions thereof. When code is +released as a series of files, a Modification is: (a) any addition to +or deletion from the contents of a file containing Covered Code; +and/or (b) any new file or other representation of computer program +statements that contains any part of Covered Code. + +1.7 "Original Code" means (a) the Source Code of a program or other +work as originally made available by Apple under this License, +including the Source Code of any updates or upgrades to such programs +or works made available by Apple under this License, and that has been +expressly identified by Apple as such in the header file(s) of such +work; and (b) the object code compiled from such Source Code and +originally made available by Apple under this License. + +1.8 "Source Code" means the human readable form of a program or other +work that is suitable for making modifications to it, including all +modules it contains, plus any associated interface definition files, +scripts used to control compilation and installation of an executable +(object code). + +1.9 "You" or "Your" means an individual or a legal entity exercising +rights under this License. For legal entities, "You" or "Your" +includes any entity which controls, is controlled by, or is under +common control with, You, where "control" means (a) the power, direct +or indirect, to cause the direction or management of such entity, +whether by contract or otherwise, or (b) ownership of fifty percent +(50%) or more of the outstanding shares or beneficial ownership of +such entity. + +2. Permitted Uses; Conditions & Restrictions. Subject to the terms +and conditions of this License, Apple hereby grants You, effective on +the date You accept this License and download the Original Code, a +world-wide, royalty-free, non-exclusive license, to the extent of +Apple's Applicable Patent Rights and copyrights covering the Original +Code, to do the following: + +2.1 Unmodified Code. You may use, reproduce, display, perform, +internally distribute within Your organization, and Externally Deploy +verbatim, unmodified copies of the Original Code, for commercial or +non-commercial purposes, provided that in each instance: + +(a) You must retain and reproduce in all copies of Original Code the +copyright and other proprietary notices and disclaimers of Apple as +they appear in the Original Code, and keep intact all notices in the +Original Code that refer to this License; and + +(b) You must include a copy of this License with every copy of Source +Code of Covered Code and documentation You distribute or Externally +Deploy, and You may not offer or impose any terms on such Source Code +that alter or restrict this License or the recipients' rights +hereunder, except as permitted under Section 6. + +2.2 Modified Code. You may modify Covered Code and use, reproduce, +display, perform, internally distribute within Your organization, and +Externally Deploy Your Modifications and Covered Code, for commercial +or non-commercial purposes, provided that in each instance You also +meet all of these conditions: + +(a) You must satisfy all the conditions of Section 2.1 with respect to +the Source Code of the Covered Code; + +(b) You must duplicate, to the extent it does not already exist, the +notice in Exhibit A in each file of the Source Code of all Your +Modifications, and cause the modified files to carry prominent notices +stating that You changed the files and the date of any change; and + +(c) If You Externally Deploy Your Modifications, You must make +Source Code of all Your Externally Deployed Modifications either +available to those to whom You have Externally Deployed Your +Modifications, or publicly available. Source Code of Your Externally +Deployed Modifications must be released under the terms set forth in +this License, including the license grants set forth in Section 3 +below, for as long as you Externally Deploy the Covered Code or twelve +(12) months from the date of initial External Deployment, whichever is +longer. You should preferably distribute the Source Code of Your +Externally Deployed Modifications electronically (e.g. download from a +web site). + +2.3 Distribution of Executable Versions. In addition, if You +Externally Deploy Covered Code (Original Code and/or Modifications) in +object code, executable form only, You must include a prominent +notice, in the code itself as well as in related documentation, +stating that Source Code of the Covered Code is available under the +terms of this License with information on how and where to obtain such +Source Code. + +2.4 Third Party Rights. You expressly acknowledge and agree that +although Apple and each Contributor grants the licenses to their +respective portions of the Covered Code set forth herein, no +assurances are provided by Apple or any Contributor that the Covered +Code does not infringe the patent or other intellectual property +rights of any other entity. Apple and each Contributor disclaim any +liability to You for claims brought by any other entity based on +infringement of intellectual property rights or otherwise. As a +condition to exercising the rights and licenses granted hereunder, You +hereby assume sole responsibility to secure any other intellectual +property rights needed, if any. For example, if a third party patent +license is required to allow You to distribute the Covered Code, it is +Your responsibility to acquire that license before distributing the +Covered Code. + +3. Your Grants. In consideration of, and as a condition to, the +licenses granted to You under this License, You hereby grant to any +person or entity receiving or distributing Covered Code under this +License a non-exclusive, royalty-free, perpetual, irrevocable license, +under Your Applicable Patent Rights and other intellectual property +rights (other than patent) owned or controlled by You, to use, +reproduce, display, perform, modify, sublicense, distribute and +Externally Deploy Your Modifications of the same scope and extent as +Apple's licenses under Sections 2.1 and 2.2 above. + +4. Larger Works. You may create a Larger Work by combining Covered +Code with other code not governed by the terms of this License and +distribute the Larger Work as a single product. In each such instance, +You must make sure the requirements of this License are fulfilled for +the Covered Code or any portion thereof. + +5. Limitations on Patent License. Except as expressly stated in +Section 2, no other patent rights, express or implied, are granted by +Apple herein. Modifications and/or Larger Works may require additional +patent licenses from Apple which Apple may grant in its sole +discretion. + +6. Additional Terms. You may choose to offer, and to charge a fee for, +warranty, support, indemnity or liability obligations and/or other +rights consistent with the scope of the license granted herein +("Additional Terms") to one or more recipients of Covered Code. +However, You may do so only on Your own behalf and as Your sole +responsibility, and not on behalf of Apple or any Contributor. You +must obtain the recipient's agreement that any such Additional Terms +are offered by You alone, and You hereby agree to indemnify, defend +and hold Apple and every Contributor harmless for any liability +incurred by or claims asserted against Apple or such Contributor by +reason of any such Additional Terms. + +7. Versions of the License. Apple may publish revised and/or new +versions of this License from time to time. Each version will be given +a distinguishing version number. Once Original Code has been published +under a particular version of this License, You may continue to use it +under the terms of that version. You may also choose to use such +Original Code under the terms of any subsequent version of this +License published by Apple. No one other than Apple has the right to +modify the terms applicable to Covered Code created under this +License. + +8. NO WARRANTY OR SUPPORT. The Covered Code may contain in whole or in +part pre-release, untested, or not fully tested works. The Covered +Code may contain errors that could cause failures or loss of data, and +may be incomplete or contain inaccuracies. You expressly acknowledge +and agree that use of the Covered Code, or any portion thereof, is at +Your sole and entire risk. THE COVERED CODE IS PROVIDED "AS IS" AND +WITHOUT WARRANTY, UPGRADES OR SUPPORT OF ANY KIND AND APPLE AND +APPLE'S LICENSOR(S) (COLLECTIVELY REFERRED TO AS "APPLE" FOR THE +PURPOSES OF SECTIONS 8 AND 9) AND ALL CONTRIBUTORS EXPRESSLY DISCLAIM +ALL WARRANTIES AND/OR CONDITIONS, EXPRESS OR IMPLIED, INCLUDING, BUT +NOT LIMITED TO, THE IMPLIED WARRANTIES AND/OR CONDITIONS OF +MERCHANTABILITY, OF SATISFACTORY QUALITY, OF FITNESS FOR A PARTICULAR +PURPOSE, OF ACCURACY, OF QUIET ENJOYMENT, AND NONINFRINGEMENT OF THIRD +PARTY RIGHTS. APPLE AND EACH CONTRIBUTOR DOES NOT WARRANT AGAINST +INTERFERENCE WITH YOUR ENJOYMENT OF THE COVERED CODE, THAT THE +FUNCTIONS CONTAINED IN THE COVERED CODE WILL MEET YOUR REQUIREMENTS, +THAT THE OPERATION OF THE COVERED CODE WILL BE UNINTERRUPTED OR +ERROR-FREE, OR THAT DEFECTS IN THE COVERED CODE WILL BE CORRECTED. NO +ORAL OR WRITTEN INFORMATION OR ADVICE GIVEN BY APPLE, AN APPLE +AUTHORIZED REPRESENTATIVE OR ANY CONTRIBUTOR SHALL CREATE A WARRANTY. +You acknowledge that the Covered Code is not intended for use in the +operation of nuclear facilities, aircraft navigation, communication +systems, or air traffic control machines in which case the failure of +the Covered Code could lead to death, personal injury, or severe +physical or environmental damage. + +9. LIMITATION OF LIABILITY. TO THE EXTENT NOT PROHIBITED BY LAW, IN NO +EVENT SHALL APPLE OR ANY CONTRIBUTOR BE LIABLE FOR ANY INCIDENTAL, +SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES ARISING OUT OF OR RELATING +TO THIS LICENSE OR YOUR USE OR INABILITY TO USE THE COVERED CODE, OR +ANY PORTION THEREOF, WHETHER UNDER A THEORY OF CONTRACT, WARRANTY, +TORT (INCLUDING NEGLIGENCE), PRODUCTS LIABILITY OR OTHERWISE, EVEN IF +APPLE OR SUCH CONTRIBUTOR HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH +DAMAGES AND NOTWITHSTANDING THE FAILURE OF ESSENTIAL PURPOSE OF ANY +REMEDY. SOME JURISDICTIONS DO NOT ALLOW THE LIMITATION OF LIABILITY OF +INCIDENTAL OR CONSEQUENTIAL DAMAGES, SO THIS LIMITATION MAY NOT APPLY +TO YOU. In no event shall Apple's total liability to You for all +damages (other than as may be required by applicable law) under this +License exceed the amount of fifty dollars ($50.00). + +10. Trademarks. This License does not grant any rights to use the +trademarks or trade names "Apple", "Apple Computer", "Mac", "Mac OS", +"QuickTime", "QuickTime Streaming Server" or any other trademarks, +service marks, logos or trade names belonging to Apple (collectively +"Apple Marks") or to any trademark, service mark, logo or trade name +belonging to any Contributor. You agree not to use any Apple Marks in +or as part of the name of products derived from the Original Code or +to endorse or promote products derived from the Original Code other +than as expressly permitted by and in strict compliance at all times +with Apple's third party trademark usage guidelines which are posted +at http://www.apple.com/legal/guidelinesfor3rdparties.html. + +11. Ownership. Subject to the licenses granted under this License, +each Contributor retains all rights, title and interest in and to any +Modifications made by such Contributor. Apple retains all rights, +title and interest in and to the Original Code and any Modifications +made by or on behalf of Apple ("Apple Modifications"), and such Apple +Modifications will not be automatically subject to this License. Apple +may, at its sole discretion, choose to license such Apple +Modifications under this License, or on different terms from those +contained in this License or may choose not to license them at all. + +12. Termination. + +12.1 Termination. This License and the rights granted hereunder will +terminate: + +(a) automatically without notice from Apple if You fail to comply with +any term(s) of this License and fail to cure such breach within 30 +days of becoming aware of such breach; + +(b) immediately in the event of the circumstances described in Section +13.5(b); or + +(c) automatically without notice from Apple if You, at any time during +the term of this License, commence an action for patent infringement +against Apple; provided that Apple did not first commence +an action for patent infringement against You in that instance. + +12.2 Effect of Termination. Upon termination, You agree to immediately +stop any further use, reproduction, modification, sublicensing and +distribution of the Covered Code. All sublicenses to the Covered Code +which have been properly granted prior to termination shall survive +any termination of this License. Provisions which, by their nature, +should remain in effect beyond the termination of this License shall +survive, including but not limited to Sections 3, 5, 8, 9, 10, 11, +12.2 and 13. No party will be liable to any other for compensation, +indemnity or damages of any sort solely as a result of terminating +this License in accordance with its terms, and termination of this +License will be without prejudice to any other right or remedy of +any party. + +13. Miscellaneous. + +13.1 Government End Users. The Covered Code is a "commercial item" as +defined in FAR 2.101. Government software and technical data rights in +the Covered Code include only those rights customarily provided to the +public as defined in this License. This customary commercial license +in technical data and software is provided in accordance with FAR +12.211 (Technical Data) and 12.212 (Computer Software) and, for +Department of Defense purchases, DFAR 252.227-7015 (Technical Data -- +Commercial Items) and 227.7202-3 (Rights in Commercial Computer +Software or Computer Software Documentation). Accordingly, all U.S. +Government End Users acquire Covered Code with only those rights set +forth herein. + +13.2 Relationship of Parties. This License will not be construed as +creating an agency, partnership, joint venture or any other form of +legal association between or among You, Apple or any Contributor, and +You will not represent to the contrary, whether expressly, by +implication, appearance or otherwise. + +13.3 Independent Development. Nothing in this License will impair +Apple's right to acquire, license, develop, have others develop for +it, market and/or distribute technology or products that perform the +same or similar functions as, or otherwise compete with, +Modifications, Larger Works, technology or products that You may +develop, produce, market or distribute. + +13.4 Waiver; Construction. Failure by Apple or any Contributor to +enforce any provision of this License will not be deemed a waiver of +future enforcement of that or any other provision. Any law or +regulation which provides that the language of a contract shall be +construed against the drafter will not apply to this License. + +13.5 Severability. (a) If for any reason a court of competent +jurisdiction finds any provision of this License, or portion thereof, +to be unenforceable, that provision of the License will be enforced to +the maximum extent permissible so as to effect the economic benefits +and intent of the parties, and the remainder of this License will +continue in full force and effect. (b) Notwithstanding the foregoing, +if applicable law prohibits or restricts You from fully and/or +specifically complying with Sections 2 and/or 3 or prevents the +enforceability of either of those Sections, this License will +immediately terminate and You must immediately discontinue any use of +the Covered Code and destroy all copies of it that are in your +possession or control. + +13.6 Dispute Resolution. Any litigation or other dispute resolution +between You and Apple relating to this License shall take place in the +Northern District of California, and You and Apple hereby consent to +the personal jurisdiction of, and venue in, the state and federal +courts within that District with respect to this License. The +application of the United Nations Convention on Contracts for the +International Sale of Goods is expressly excluded. + +13.7 Entire Agreement; Governing Law. This License constitutes the +entire agreement between the parties with respect to the subject +matter hereof. This License shall be governed by the laws of the +United States and the State of California, except that body of +California law concerning conflicts of law. + +Where You are located in the province of Quebec, Canada, the following +clause applies: The parties hereby confirm that they have requested +that this License and all related documents be drafted in English. Les +parties ont exige que le present contrat et tous les documents +connexes soient rediges en anglais. + +EXHIBIT A. + +"Portions Copyright (c) 1999-2003 Apple Computer, Inc. All Rights +Reserved. + +This file contains Original Code and/or Modifications of Original Code +as defined in and that are subject to the Apple Public Source License +Version 2.0 (the 'License'). You may not use this file except in +compliance with the License. Please obtain a copy of the License at +http://www.opensource.apple.com/apsl/ and read it before using this +file. + +The Original Code and all software distributed under the License are +distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER +EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, +INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. +Please see the License for the specific language governing rights and +limitations under the License." diff --git a/diskdev_cmds/dev_mkdb.tproj/dev_mkdb.8 b/diskdev_cmds/dev_mkdb.tproj/dev_mkdb.8 new file mode 100644 index 0000000..9369b2b --- /dev/null +++ b/diskdev_cmds/dev_mkdb.tproj/dev_mkdb.8 @@ -0,0 +1,81 @@ +.\" Copyright (c) 1990, 1993 +.\" The Regents of the University of California. 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. +.\" 3. All advertising materials mentioning features or use of this software +.\" must display the following acknowledgement: +.\" This product includes software developed by the University of +.\" California, Berkeley and its contributors. +.\" 4. Neither the name of the University nor the names of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. +.\" +.\" @(#)dev_mkdb.8 8.1 (Berkeley) 6/6/93 +.\" +.Dd June 6, 1993 +.Os +.Dt DEV_MKDB 8 +.Sh NAME +.Nm dev_mkdb +.Nd create +.Pa /dev +database +.Sh SYNOPSIS +.Nm dev_mkdb +.Sh DESCRIPTION +The +.Nm dev_mkdb +command creates a +.Xr db 3 +hash access method database in +.Dq Pa /var/run/dev.db +which contains the names of all of the character and block special +files in the +.Dq Pa /dev +directory, using the file type and the +.Fa st_rdev +field as the key. +.Pp +Keys are a structure containing a mode_t followed by a dev_t, +with any padding zero'd out. +The former is the type of the file (st_mode & S_IFMT), +the latter is the st_rdev field. +.Sh FILES +.Bl -tag -width /var/run/dev.db -compact +.It Pa /dev +Device directory. +.It Pa /var/run/dev.db +Database file. +.El +.Sh SEE ALSO +.Xr ps 1 , +.Xr stat 2 , +.Xr db 3 , +.Xr devname 3 , +.Xr kvm_nlist 3 , +.Xr ttyname 3 , +.Xr kvm_mkdb 8 +.Sh HISTORY +The +.Nm dev_mkdb +command appeared in +.Bx 4.4 . diff --git a/diskdev_cmds/dev_mkdb.tproj/dev_mkdb.c b/diskdev_cmds/dev_mkdb.tproj/dev_mkdb.c new file mode 100644 index 0000000..82c7429 --- /dev/null +++ b/diskdev_cmds/dev_mkdb.tproj/dev_mkdb.c @@ -0,0 +1,202 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/*- + * Copyright (c) 1990, 1993 + * The Regents of the University of California. 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. + */ + +/****** +static char copyright[] = +"@(#) Copyright (c) 1990, 1993\n\ + The Regents of the University of California. All rights reserved.\n"; +******/ + +/****** +static char sccsid[] = "@(#)dev_mkdb.c 8.1 (Berkeley) 6/6/93"; +******/ + +#include +#include + +#include +#undef DIRBLKSIZ +#include +#include +#include +#include +#include +#include +#include +#include +#include + +void err __P((const char *, ...)); +void usage __P((void)); + +int +main(argc, argv) + int argc; + char *argv[]; +{ + register DIR *dirp; + register struct dirent *dp; + struct stat sb; + struct { + mode_t type; + dev_t dev; + } bkey; + DB *db; + DBT data, key; + int ch; + u_char buf[MAXNAMLEN + 1]; + char dbtmp[MAXPATHLEN + 1], dbname[MAXPATHLEN + 1]; + + while ((ch = getopt(argc, argv, "")) != EOF) + switch((char)ch) { + case '?': + default: + usage(); + } + argc -= optind; + argv += optind; + + if (argc > 0) + usage(); + + if (chdir(_PATH_DEV)) + err("%s: %s", _PATH_DEV, strerror(errno)); + + dirp = opendir("."); + + (void)snprintf(dbtmp, sizeof(dbtmp), "%sdev.tmp", _PATH_VARRUN); + (void)snprintf(dbname, sizeof(dbtmp), "%sdev.db", _PATH_VARRUN); + db = dbopen(dbtmp, O_CREAT|O_EXLOCK|O_RDWR|O_TRUNC, + S_IRUSR|S_IWUSR|S_IRGRP|S_IROTH, DB_HASH, NULL); + if (db == NULL) + err("%s: %s", dbtmp, strerror(errno)); + + /* + * Keys are a mode_t followed by a dev_t. The former is the type of + * the file (mode & S_IFMT), the latter is the st_rdev field. Note + * that the structure may contain padding, so we have to clear it + * out here. + */ + bzero(&bkey, sizeof(bkey)); + key.data = &bkey; + key.size = sizeof(bkey); + data.data = buf; + while ((dp = readdir(dirp))) { + if (lstat(dp->d_name, &sb)) { + (void)fprintf(stderr, + "dev_mkdb: %s: %s\n", dp->d_name, strerror(errno)); + continue; + } + + /* Create the key. */ + if (S_ISCHR(sb.st_mode)) + bkey.type = S_IFCHR; + else if (S_ISBLK(sb.st_mode)) + bkey.type = S_IFBLK; + else + continue; + bkey.dev = sb.st_rdev; + + /* + * Create the data; nul terminate the name so caller doesn't + * have to. + */ + bcopy(dp->d_name, buf, dp->d_namlen); + buf[dp->d_namlen] = '\0'; + data.size = dp->d_namlen + 1; + if ((db->put)(db, &key, &data, 0)) + err("dbput %s: %s\n", dbtmp, strerror(errno)); + } + (void)(db->close)(db); + if (rename(dbtmp, dbname)) + err("rename %s to %s: %s", dbtmp, dbname, strerror(errno)); + exit(0); +} + +void +usage() +{ + (void)fprintf(stderr, "usage: dev_mkdb\n"); + exit(1); +} + +#if __STDC__ +#include +#else +#include +#endif + +void +#if __STDC__ +err(const char *fmt, ...) +#else +err(fmt, va_alist) + char *fmt; + va_dcl +#endif +{ + va_list ap; +#if __STDC__ + va_start(ap, fmt); +#else + va_start(ap); +#endif + (void)fprintf(stderr, "dev_mkdb: "); + (void)vfprintf(stderr, fmt, ap); + va_end(ap); + (void)fprintf(stderr, "\n"); + exit(1); + /* NOTREACHED */ +} diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/project.pbxproj b/diskdev_cmds/diskdev_cmds.xcodeproj/project.pbxproj new file mode 100644 index 0000000..ff896ee --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/project.pbxproj @@ -0,0 +1,2411 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 46; + objects = { + +/* Begin PBXAggregateTarget section */ + 4D55934F153CE4CC009F2584 /* Common */ = { + isa = PBXAggregateTarget; + buildConfigurationList = 4D559350153CE4CC009F2584 /* Build configuration list for PBXAggregateTarget "Common" */; + buildPhases = ( + ); + dependencies = ( + 4D559357153CE4EA009F2584 /* PBXTargetDependency */, + 4D559472153DC87B009F2584 /* PBXTargetDependency */, + 4D559359153CE4EC009F2584 /* PBXTargetDependency */, + 4D55935B153CE4ED009F2584 /* PBXTargetDependency */, + 4D559498153DC9E8009F2584 /* PBXTargetDependency */, + 4D5594A7153DCA04009F2584 /* PBXTargetDependency */, + 4D5594B9153DCA5E009F2584 /* PBXTargetDependency */, + 4D5594DF153DCC73009F2584 /* PBXTargetDependency */, + 4D559373153CE5F8009F2584 /* PBXTargetDependency */, + 4D559426153DC38F009F2584 /* PBXTargetDependency */, + 4D55943A153DC4C0009F2584 /* PBXTargetDependency */, + 4D55939C153CE83A009F2584 /* PBXTargetDependency */, + 4D559415153DC282009F2584 /* PBXTargetDependency */, + 071077D92488A09C003B97C7 /* PBXTargetDependency */, + ); + name = Common; + productName = All; + }; + 4D559440153DC57D009F2584 /* All_MacOSX */ = { + isa = PBXAggregateTarget; + buildConfigurationList = 4D559441153DC57D009F2584 /* Build configuration list for PBXAggregateTarget "All_MacOSX" */; + buildPhases = ( + ); + dependencies = ( + 4D559447153DC597009F2584 /* PBXTargetDependency */, + B12C9C9222A7CDE300B9F497 /* PBXTargetDependency */, + B12C9C9422A7CDE300B9F497 /* PBXTargetDependency */, + B12C9C9622A7CDE300B9F497 /* PBXTargetDependency */, + B12C9C9822A7CDE300B9F497 /* PBXTargetDependency */, + B12C9C9A22A7CDE300B9F497 /* PBXTargetDependency */, + B12C9C9C22A7CDE300B9F497 /* PBXTargetDependency */, + 07747AA21DA8511D00ACE020 /* PBXTargetDependency */, + 4D55945C153DC665009F2584 /* PBXTargetDependency */, + ); + name = All_MacOSX; + productName = All_MacOSX; + }; + 4D559443153DC587009F2584 /* All_iOS */ = { + isa = PBXAggregateTarget; + buildConfigurationList = 4D559444153DC587009F2584 /* Build configuration list for PBXAggregateTarget "All_iOS" */; + buildPhases = ( + ); + dependencies = ( + 4D559449153DC599009F2584 /* PBXTargetDependency */, + ); + name = All_iOS; + productName = All_iOS; + }; + 4D559514153DE116009F2584 /* quotaoff */ = { + isa = PBXAggregateTarget; + buildConfigurationList = 4D559515153DE116009F2584 /* Build configuration list for PBXAggregateTarget "quotaoff" */; + buildPhases = ( + 4D55951B153DE1EF009F2584 /* ShellScript */, + ); + dependencies = ( + 4D55951A153DE1CB009F2584 /* PBXTargetDependency */, + ); + name = quotaoff; + productName = quotaoff; + }; +/* End PBXAggregateTarget section */ + +/* Begin PBXBuildFile section */ + 072AAAA62167CE8F004ED4E2 /* mount_flags.c in Sources */ = {isa = PBXBuildFile; fileRef = 072AAAA42167CE8E004ED4E2 /* mount_flags.c */; }; + 078B970D2190682600674625 /* mount_flags.c in Sources */ = {isa = PBXBuildFile; fileRef = 072AAAA42167CE8E004ED4E2 /* mount_flags.c */; }; + 07CE4C1821906BB800BF11C0 /* mount.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55936C153CE58E009F2584 /* mount.c */; }; + 1A9041022091EE830061D05A /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041012091EE830061D05A /* IOKit.framework */; }; + 1A9041042091EE910061D05A /* APFS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041032091EE910061D05A /* APFS.framework */; }; + 1A9041062091EE980061D05A /* CoreFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041052091EE980061D05A /* CoreFoundation.framework */; }; + 4D07DD57153CA9DC002B57CB /* dkcksum.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D07DD4D153CA9DC002B57CB /* dkcksum.c */; }; + 4D07DD58153CA9DC002B57CB /* dkdisklabel.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D07DD4E153CA9DC002B57CB /* dkdisklabel.c */; }; + 4D07DD59153CA9DC002B57CB /* dkopen.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D07DD4F153CA9DC002B57CB /* dkopen.c */; }; + 4D07DD5A153CA9DC002B57CB /* dkopen.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D07DD50153CA9DC002B57CB /* dkopen.h */; }; + 4D07DD5B153CA9DC002B57CB /* dksecsize.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D07DD51153CA9DC002B57CB /* dksecsize.c */; }; + 4D07DD5E153CA9DC002B57CB /* pathnames.h in Headers */ = {isa = PBXBuildFile; fileRef = 4D07DD54153CA9DC002B57CB /* pathnames.h */; }; + 4D07DD5F153CA9DC002B57CB /* preen.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D07DD55153CA9DC002B57CB /* preen.c */; }; + 4D07DD60153CA9DC002B57CB /* vfslist.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D07DD56153CA9DC002B57CB /* vfslist.c */; }; + 4D559332153CE1D9009F2584 /* auto.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55931E153CE1D9009F2584 /* auto.c */; }; + 4D559333153CE1D9009F2584 /* cmd.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559320153CE1D9009F2584 /* cmd.c */; }; + 4D559334153CE1D9009F2584 /* disk.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559322153CE1D9009F2584 /* disk.c */; }; + 4D559335153CE1D9009F2584 /* fdisk.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559325153CE1D9009F2584 /* fdisk.c */; }; + 4D559336153CE1D9009F2584 /* getrawpartition.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559326153CE1D9009F2584 /* getrawpartition.c */; }; + 4D559337153CE1D9009F2584 /* mbr.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559327153CE1D9009F2584 /* mbr.c */; }; + 4D559338153CE1D9009F2584 /* misc.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55932A153CE1D9009F2584 /* misc.c */; }; + 4D559339153CE1D9009F2584 /* opendev.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55932C153CE1D9009F2584 /* opendev.c */; }; + 4D55933A153CE1D9009F2584 /* part.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55932D153CE1D9009F2584 /* part.c */; }; + 4D55933B153CE1D9009F2584 /* user.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55932F153CE1D9009F2584 /* user.c */; }; + 4D55933C153CE242009F2584 /* fdisk.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D559324153CE1D9009F2584 /* fdisk.8 */; }; + 4D55934D153CE44E009F2584 /* fsck.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55934B153CE44E009F2584 /* fsck.c */; }; + 4D55934E153CE4B1009F2584 /* fsck.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D55934A153CE44E009F2584 /* fsck.8 */; }; + 4D55936F153CE5D6009F2584 /* fstab.5 in Copy man5 */ = {isa = PBXBuildFile; fileRef = 4D559369153CE58E009F2584 /* fstab.5 */; }; + 4D559371153CE5EA009F2584 /* mount.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D55936B153CE58E009F2584 /* mount.8 */; }; + 4D559389153CE794009F2584 /* libdisk.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4D07DD49153CA9A0002B57CB /* libdisk.a */; }; + 4D559399153CE826009F2584 /* umount.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559398153CE826009F2584 /* umount.c */; }; + 4D55939A153CE82E009F2584 /* umount.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D559397153CE826009F2584 /* umount.8 */; }; + 4D55939D153CE8AF009F2584 /* libdisk.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4D07DD49153CA9A0002B57CB /* libdisk.a */; }; + 4D5593B2153CEABD009F2584 /* edquota.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5593B0153CEABD009F2584 /* edquota.c */; }; + 4D5593C4153CEB9A009F2584 /* quota.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5593C3153CEB9A009F2584 /* quota.c */; }; + 4D5593C5153CEBB4009F2584 /* edquota.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D5593AF153CEABD009F2584 /* edquota.8 */; }; + 4D5593C6153CEBC3009F2584 /* quota.1 in Copy man1 */ = {isa = PBXBuildFile; fileRef = 4D5593C2153CEB9A009F2584 /* quota.1 */; }; + 4D5593DC153CED51009F2584 /* hfs_quotacheck.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5593D8153CED51009F2584 /* hfs_quotacheck.c */; }; + 4D5593DD153CED51009F2584 /* quotacheck.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5593DA153CED51009F2584 /* quotacheck.c */; }; + 4D5593DE153CED6A009F2584 /* quotacheck.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D5593D9153CED51009F2584 /* quotacheck.8 */; }; + 4D5593DF153CED8D009F2584 /* libdisk.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 4D07DD49153CA9A0002B57CB /* libdisk.a */; }; + 4D5593EF153CEE66009F2584 /* quotaon.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5593EE153CEE66009F2584 /* quotaon.c */; }; + 4D5593F0153CEE74009F2584 /* quotaon.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D5593ED153CEE66009F2584 /* quotaon.8 */; }; + 4D559403153DC13D009F2584 /* repquota.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559402153DC13D009F2584 /* repquota.c */; }; + 4D559404153DC150009F2584 /* repquota.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D559401153DC13D009F2584 /* repquota.8 */; }; + 4D559417153DC2AB009F2584 /* vndevice.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559416153DC2AB009F2584 /* vndevice.c */; }; + 4D559428153DC3A6009F2584 /* mount_devfs.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559427153DC3A6009F2584 /* mount_devfs.c */; }; + 4D55942B153DC427009F2584 /* libutil.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 4D55942A153DC420009F2584 /* libutil.dylib */; }; + 4D55943D153DC4DE009F2584 /* mount_fdesc.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55943C153DC4DE009F2584 /* mount_fdesc.c */; }; + 4D55943E153DC4E9009F2584 /* mount_fdesc.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D55943B153DC4DE009F2584 /* mount_fdesc.8 */; }; + 4D55943F153DC534009F2584 /* libutil.dylib in Frameworks */ = {isa = PBXBuildFile; fileRef = 4D55942A153DC420009F2584 /* libutil.dylib */; }; + 4D55945A153DC650009F2584 /* vsdbutil_main.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559458153DC650009F2584 /* vsdbutil_main.c */; }; + 4D55945D153DC728009F2584 /* vsdbutil.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D559459153DC650009F2584 /* vsdbutil.8 */; }; + 4D55945F153DC735009F2584 /* com.apple.vsdbutil.plist in Copy com.apple.vsdbutil.plist */ = {isa = PBXBuildFile; fileRef = 4D559457153DC650009F2584 /* com.apple.vsdbutil.plist */; }; + 4D55946F153DC839009F2584 /* dev_mkdb.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D55946E153DC839009F2584 /* dev_mkdb.c */; }; + 4D559470153DC84E009F2584 /* dev_mkdb.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D55946D153DC839009F2584 /* dev_mkdb.8 */; }; + 4D559482153DC912009F2584 /* fstyp.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559481153DC912009F2584 /* fstyp.c */; }; + 4D559483153DC92D009F2584 /* fstyp.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D559480153DC912009F2584 /* fstyp.8 */; }; + 4D559495153DC9AE009F2584 /* fstyp_msdos.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D559494153DC9AE009F2584 /* fstyp_msdos.c */; }; + 4D559496153DC9BC009F2584 /* fstyp_msdos.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D559493153DC9AE009F2584 /* fstyp_msdos.8 */; }; + 4D5594AA153DCA19009F2584 /* fstyp_ntfs.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5594A9153DCA19009F2584 /* fstyp_ntfs.c */; }; + 4D5594BC153DCA74009F2584 /* fstyp_udf.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5594BB153DCA74009F2584 /* fstyp_udf.c */; }; + 4D5594BD153DCA85009F2584 /* fstyp_udf.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D5594BA153DCA74009F2584 /* fstyp_udf.8 */; }; + 4D5594CD153DCB72009F2584 /* setclass.c in Sources */ = {isa = PBXBuildFile; fileRef = 4D5594CC153DCB72009F2584 /* setclass.c */; }; + 4D5594CE153DCB82009F2584 /* setclass.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D5594CB153DCB72009F2584 /* setclass.8 */; }; + 4D5594E2153DCCAC009F2584 /* fuser.1 in Copy man1 */ = {isa = PBXBuildFile; fileRef = 4D5594E0153DCC92009F2584 /* fuser.1 */; }; + 4D5594E6153DCFFB009F2584 /* fstyp_ntfs.8 in Copy man8 */ = {isa = PBXBuildFile; fileRef = 4D5594A8153DCA19009F2584 /* fstyp_ntfs.8 */; }; + 785314FF227120BD00B25661 /* MediaKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 785314FE227120BD00B25661 /* MediaKit.framework */; }; + B19B239C21C8DF660001F35C /* edt_fstab.c in Sources */ = {isa = PBXBuildFile; fileRef = B19B239A21C8DEF90001F35C /* edt_fstab.c */; }; + B19B239D21C8DF6E0001F35C /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041012091EE830061D05A /* IOKit.framework */; }; + B19B239E21C8DF740001F35C /* APFS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041032091EE910061D05A /* APFS.framework */; }; + B19B239F21C8DF7B0001F35C /* CoreFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041052091EE980061D05A /* CoreFoundation.framework */; }; + B19B23A021C8DFA40001F35C /* edt_fstab.c in Sources */ = {isa = PBXBuildFile; fileRef = B19B239A21C8DEF90001F35C /* edt_fstab.c */; }; + B19B23A221C8DFC30001F35C /* edt_fstab.c in Sources */ = {isa = PBXBuildFile; fileRef = B19B239A21C8DEF90001F35C /* edt_fstab.c */; }; + B19B23A321C8DFCF0001F35C /* APFS.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041032091EE910061D05A /* APFS.framework */; }; + B19B23A421C8DFD50001F35C /* IOKit.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041012091EE830061D05A /* IOKit.framework */; }; + B19B23A521C8DFE10001F35C /* CoreFoundation.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 1A9041052091EE980061D05A /* CoreFoundation.framework */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 071077D82488A09C003B97C7 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5594C1153DCAFC009F2584; + remoteInfo = setclass; + }; + 07747AA11DA8511D00ACE020 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D559476153DC8FC009F2584; + remoteInfo = fstyp; + }; + 4D559356153CE4EA009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D07DD48153CA9A0002B57CB; + remoteInfo = libdisk; + }; + 4D559358153CE4EC009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D559314153CE198009F2584; + remoteInfo = fdisk; + }; + 4D55935A153CE4ED009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D559340153CE41E009F2584; + remoteInfo = fsck; + }; + 4D559372153CE5F8009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55935F153CE561009F2584; + remoteInfo = mount; + }; + 4D55939B153CE83A009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55938D153CE7FD009F2584; + remoteInfo = umount; + }; + 4D55939E153CE8B6009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D07DD48153CA9A0002B57CB; + remoteInfo = libdisk; + }; + 4D5593A0153CE8BC009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D07DD48153CA9A0002B57CB; + remoteInfo = libdisk; + }; + 4D559414153DC282009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55940A153DC27A009F2584; + remoteInfo = vndevice; + }; + 4D559425153DC38F009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55941B153DC383009F2584; + remoteInfo = mount_devfs; + }; + 4D559439153DC4C0009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55942F153DC49A009F2584; + remoteInfo = mount_fdesc; + }; + 4D559446153DC597009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55934F153CE4CC009F2584; + remoteInfo = Common; + }; + 4D559448153DC599009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55934F153CE4CC009F2584; + remoteInfo = Common; + }; + 4D55945B153DC665009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55944D153DC634009F2584; + remoteInfo = vsdbutil; + }; + 4D559471153DC87B009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D559463153DC808009F2584; + remoteInfo = dev_mkdb; + }; + 4D559497153DC9E8009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D559489153DC98D009F2584; + remoteInfo = fstyp_msdos; + }; + 4D5594A6153DCA04009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D55949C153DC9FB009F2584; + remoteInfo = fstyp_ntfs; + }; + 4D5594B8153DCA5E009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5594AE153DCA53009F2584; + remoteInfo = fstyp_udf; + }; + 4D5594DE153DCC73009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5594D4153DCC66009F2584; + remoteInfo = fuser; + }; + 4D559519153DE1CB009F2584 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5593E3153CEE4A009F2584; + remoteInfo = quotaon; + }; + B12C9C9122A7CDE300B9F497 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5593A5153CEA90009F2584; + remoteInfo = edquota; + }; + B12C9C9322A7CDE300B9F497 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5593B8153CEB7E009F2584; + remoteInfo = quota; + }; + B12C9C9522A7CDE300B9F497 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5593CC153CED29009F2584; + remoteInfo = quotacheck; + }; + B12C9C9722A7CDE300B9F497 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5593E3153CEE4A009F2584; + remoteInfo = quotaon; + }; + B12C9C9922A7CDE300B9F497 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D559514153DE116009F2584; + remoteInfo = quotaoff; + }; + B12C9C9B22A7CDE300B9F497 /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 4D07DD2B153CA616002B57CB /* Project object */; + proxyType = 1; + remoteGlobalIDString = 4D5593F7153DC0DE009F2584; + remoteInfo = repquota; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXCopyFilesBuildPhase section */ + 4D559313153CE198009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D55933C153CE242009F2584 /* fdisk.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55933F153CE41E009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D55934E153CE4B1009F2584 /* fsck.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55935E153CE561009F2584 /* Copy man5 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man5/; + dstSubfolderSpec = 0; + files = ( + 4D55936F153CE5D6009F2584 /* fstab.5 in Copy man5 */, + ); + name = "Copy man5"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D559370153CE5DC009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 8; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D559371153CE5EA009F2584 /* mount.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55938C153CE7FD009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D55939A153CE82E009F2584 /* umount.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5593A4153CEA90009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D5593C5153CEBB4009F2584 /* edquota.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5593B7153CEB7E009F2584 /* Copy man1 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man1/; + dstSubfolderSpec = 0; + files = ( + 4D5593C6153CEBC3009F2584 /* quota.1 in Copy man1 */, + ); + name = "Copy man1"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5593CB153CED29009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D5593DE153CED6A009F2584 /* quotacheck.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5593E2153CEE4A009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D5593F0153CEE74009F2584 /* quotaon.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5593F6153DC0DE009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D559404153DC150009F2584 /* repquota.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D559409153DC27A009F2584 /* Copy man1 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man1/; + dstSubfolderSpec = 0; + files = ( + ); + name = "Copy man1"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55941A153DC383009F2584 /* CopyFiles */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man1/; + dstSubfolderSpec = 0; + files = ( + ); + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55942E153DC49A009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D55943E153DC4E9009F2584 /* mount_fdesc.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55944C153DC634009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D55945D153DC728009F2584 /* vsdbutil.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55945E153DC730009F2584 /* Copy com.apple.vsdbutil.plist */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 8; + dstPath = /System/Library/LaunchDaemons; + dstSubfolderSpec = 0; + files = ( + 4D55945F153DC735009F2584 /* com.apple.vsdbutil.plist in Copy com.apple.vsdbutil.plist */, + ); + name = "Copy com.apple.vsdbutil.plist"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D559462153DC808009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D559470153DC84E009F2584 /* dev_mkdb.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D559475153DC8FC009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D559483153DC92D009F2584 /* fstyp.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D559488153DC98D009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D559496153DC9BC009F2584 /* fstyp_msdos.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D55949B153DC9FB009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D5594E6153DCFFB009F2584 /* fstyp_ntfs.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5594AD153DCA53009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D5594BD153DCA85009F2584 /* fstyp_udf.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5594C0153DCAFC009F2584 /* Copy man8 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/local/share/man/man8/; + dstSubfolderSpec = 0; + files = ( + 4D5594CE153DCB82009F2584 /* setclass.8 in Copy man8 */, + ); + name = "Copy man8"; + runOnlyForDeploymentPostprocessing = 1; + }; + 4D5594D3153DCC66009F2584 /* Copy man1 */ = { + isa = PBXCopyFilesBuildPhase; + buildActionMask = 2147483647; + dstPath = /usr/share/man/man1/; + dstSubfolderSpec = 0; + files = ( + 4D5594E2153DCCAC009F2584 /* fuser.1 in Copy man1 */, + ); + name = "Copy man1"; + runOnlyForDeploymentPostprocessing = 1; + }; +/* End PBXCopyFilesBuildPhase section */ + +/* Begin PBXFileReference section */ + 072AAAA42167CE8E004ED4E2 /* mount_flags.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = mount_flags.c; sourceTree = ""; }; + 072AAAA52167CE8E004ED4E2 /* mount_flags.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = mount_flags.h; sourceTree = ""; }; + 07AF95B12323281D001E9266 /* System.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = System.framework; path = System/Library/Frameworks/System.framework; sourceTree = SDKROOT; }; + 07AF95B323232837001E9266 /* Kernel.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Kernel.framework; path = System/Library/Frameworks/Kernel.framework; sourceTree = SDKROOT; }; + 1A9041012091EE830061D05A /* IOKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = IOKit.framework; path = System/Library/Frameworks/IOKit.framework; sourceTree = SDKROOT; }; + 1A9041032091EE910061D05A /* APFS.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = APFS.framework; path = System/Library/PrivateFrameworks/APFS.framework; sourceTree = SDKROOT; }; + 1A9041052091EE980061D05A /* CoreFoundation.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = CoreFoundation.framework; path = System/Library/Frameworks/CoreFoundation.framework; sourceTree = SDKROOT; }; + 4D07DD49153CA9A0002B57CB /* libdisk.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libdisk.a; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D07DD4D153CA9DC002B57CB /* dkcksum.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = dkcksum.c; path = disklib/dkcksum.c; sourceTree = ""; }; + 4D07DD4E153CA9DC002B57CB /* dkdisklabel.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = dkdisklabel.c; path = disklib/dkdisklabel.c; sourceTree = ""; }; + 4D07DD4F153CA9DC002B57CB /* dkopen.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = dkopen.c; path = disklib/dkopen.c; sourceTree = ""; }; + 4D07DD50153CA9DC002B57CB /* dkopen.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = dkopen.h; path = disklib/dkopen.h; sourceTree = ""; }; + 4D07DD51153CA9DC002B57CB /* dksecsize.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = dksecsize.c; path = disklib/dksecsize.c; sourceTree = ""; }; + 4D07DD54153CA9DC002B57CB /* pathnames.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = pathnames.h; path = disklib/pathnames.h; sourceTree = ""; }; + 4D07DD55153CA9DC002B57CB /* preen.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = preen.c; path = disklib/preen.c; sourceTree = ""; }; + 4D07DD56153CA9DC002B57CB /* vfslist.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = vfslist.c; path = disklib/vfslist.c; sourceTree = ""; }; + 4D559315153CE198009F2584 /* fdisk */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fdisk; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D55931E153CE1D9009F2584 /* auto.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = auto.c; path = fdisk.tproj/auto.c; sourceTree = SOURCE_ROOT; }; + 4D55931F153CE1D9009F2584 /* auto.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = auto.h; path = fdisk.tproj/auto.h; sourceTree = SOURCE_ROOT; }; + 4D559320153CE1D9009F2584 /* cmd.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = cmd.c; path = fdisk.tproj/cmd.c; sourceTree = SOURCE_ROOT; }; + 4D559321153CE1D9009F2584 /* cmd.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = cmd.h; path = fdisk.tproj/cmd.h; sourceTree = SOURCE_ROOT; }; + 4D559322153CE1D9009F2584 /* disk.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = disk.c; path = fdisk.tproj/disk.c; sourceTree = SOURCE_ROOT; }; + 4D559323153CE1D9009F2584 /* disk.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = disk.h; path = fdisk.tproj/disk.h; sourceTree = SOURCE_ROOT; }; + 4D559324153CE1D9009F2584 /* fdisk.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = fdisk.8; path = fdisk.tproj/fdisk.8; sourceTree = SOURCE_ROOT; }; + 4D559325153CE1D9009F2584 /* fdisk.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fdisk.c; path = fdisk.tproj/fdisk.c; sourceTree = SOURCE_ROOT; }; + 4D559326153CE1D9009F2584 /* getrawpartition.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = getrawpartition.c; path = fdisk.tproj/getrawpartition.c; sourceTree = SOURCE_ROOT; }; + 4D559327153CE1D9009F2584 /* mbr.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = mbr.c; path = fdisk.tproj/mbr.c; sourceTree = SOURCE_ROOT; }; + 4D559328153CE1D9009F2584 /* mbr.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = mbr.h; path = fdisk.tproj/mbr.h; sourceTree = SOURCE_ROOT; }; + 4D559329153CE1D9009F2584 /* mbrcode.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = mbrcode.h; path = fdisk.tproj/mbrcode.h; sourceTree = SOURCE_ROOT; }; + 4D55932A153CE1D9009F2584 /* misc.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = misc.c; path = fdisk.tproj/misc.c; sourceTree = SOURCE_ROOT; }; + 4D55932B153CE1D9009F2584 /* misc.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = misc.h; path = fdisk.tproj/misc.h; sourceTree = SOURCE_ROOT; }; + 4D55932C153CE1D9009F2584 /* opendev.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = opendev.c; path = fdisk.tproj/opendev.c; sourceTree = SOURCE_ROOT; }; + 4D55932D153CE1D9009F2584 /* part.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = part.c; path = fdisk.tproj/part.c; sourceTree = SOURCE_ROOT; }; + 4D55932E153CE1D9009F2584 /* part.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = part.h; path = fdisk.tproj/part.h; sourceTree = SOURCE_ROOT; }; + 4D55932F153CE1D9009F2584 /* user.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = user.c; path = fdisk.tproj/user.c; sourceTree = SOURCE_ROOT; }; + 4D559330153CE1D9009F2584 /* user.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = user.h; path = fdisk.tproj/user.h; sourceTree = SOURCE_ROOT; }; + 4D559331153CE1D9009F2584 /* util.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = util.h; path = fdisk.tproj/util.h; sourceTree = SOURCE_ROOT; }; + 4D559341153CE41E009F2584 /* fsck */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fsck; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D55934A153CE44E009F2584 /* fsck.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = fsck.8; path = fsck.tproj/fsck.8; sourceTree = SOURCE_ROOT; }; + 4D55934B153CE44E009F2584 /* fsck.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fsck.c; path = fsck.tproj/fsck.c; sourceTree = SOURCE_ROOT; }; + 4D55934C153CE44E009F2584 /* fsck.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = fsck.h; path = fsck.tproj/fsck.h; sourceTree = SOURCE_ROOT; }; + 4D559360153CE561009F2584 /* mount */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = mount; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559369153CE58E009F2584 /* fstab.5 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = fstab.5; path = mount.tproj/fstab.5; sourceTree = SOURCE_ROOT; }; + 4D55936B153CE58E009F2584 /* mount.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = mount.8; path = mount.tproj/mount.8; sourceTree = SOURCE_ROOT; }; + 4D55936C153CE58E009F2584 /* mount.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = mount.c; path = mount.tproj/mount.c; sourceTree = SOURCE_ROOT; }; + 4D55936D153CE58E009F2584 /* pathnames.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = pathnames.h; path = mount.tproj/pathnames.h; sourceTree = SOURCE_ROOT; }; + 4D55938E153CE7FD009F2584 /* umount */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = umount; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559397153CE826009F2584 /* umount.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = umount.8; path = umount.tproj/umount.8; sourceTree = SOURCE_ROOT; }; + 4D559398153CE826009F2584 /* umount.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = umount.c; path = umount.tproj/umount.c; sourceTree = SOURCE_ROOT; }; + 4D5593A6153CEA90009F2584 /* edquota */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = edquota; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5593AF153CEABD009F2584 /* edquota.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = edquota.8; path = edquota.tproj/edquota.8; sourceTree = SOURCE_ROOT; }; + 4D5593B0153CEABD009F2584 /* edquota.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = edquota.c; path = edquota.tproj/edquota.c; sourceTree = SOURCE_ROOT; }; + 4D5593B1153CEABD009F2584 /* pathnames.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = pathnames.h; path = edquota.tproj/pathnames.h; sourceTree = SOURCE_ROOT; }; + 4D5593B9153CEB7E009F2584 /* quota */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = quota; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5593C2153CEB9A009F2584 /* quota.1 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.man; name = quota.1; path = quota.tproj/quota.1; sourceTree = SOURCE_ROOT; }; + 4D5593C3153CEB9A009F2584 /* quota.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = quota.c; path = quota.tproj/quota.c; sourceTree = SOURCE_ROOT; }; + 4D5593CD153CED29009F2584 /* quotacheck */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = quotacheck; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5593D8153CED51009F2584 /* hfs_quotacheck.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = hfs_quotacheck.c; path = quotacheck.tproj/hfs_quotacheck.c; sourceTree = SOURCE_ROOT; }; + 4D5593D9153CED51009F2584 /* quotacheck.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = quotacheck.8; path = quotacheck.tproj/quotacheck.8; sourceTree = SOURCE_ROOT; }; + 4D5593DA153CED51009F2584 /* quotacheck.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = quotacheck.c; path = quotacheck.tproj/quotacheck.c; sourceTree = SOURCE_ROOT; }; + 4D5593DB153CED51009F2584 /* quotacheck.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = quotacheck.h; path = quotacheck.tproj/quotacheck.h; sourceTree = SOURCE_ROOT; }; + 4D5593E4153CEE4A009F2584 /* quotaon */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = quotaon; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5593ED153CEE66009F2584 /* quotaon.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = quotaon.8; path = quotaon.tproj/quotaon.8; sourceTree = SOURCE_ROOT; }; + 4D5593EE153CEE66009F2584 /* quotaon.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = quotaon.c; path = quotaon.tproj/quotaon.c; sourceTree = SOURCE_ROOT; }; + 4D5593F8153DC0DE009F2584 /* repquota */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = repquota; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559401153DC13D009F2584 /* repquota.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = repquota.8; path = repquota.tproj/repquota.8; sourceTree = SOURCE_ROOT; }; + 4D559402153DC13D009F2584 /* repquota.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = repquota.c; path = repquota.tproj/repquota.c; sourceTree = SOURCE_ROOT; }; + 4D55940B153DC27A009F2584 /* vndevice */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = vndevice; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559416153DC2AB009F2584 /* vndevice.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = vndevice.c; path = vndevice.tproj/vndevice.c; sourceTree = SOURCE_ROOT; }; + 4D55941C153DC383009F2584 /* mount_devfs */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = mount_devfs; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559427153DC3A6009F2584 /* mount_devfs.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = mount_devfs.c; path = mount_devfs.tproj/mount_devfs.c; sourceTree = SOURCE_ROOT; }; + 4D55942A153DC420009F2584 /* libutil.dylib */ = {isa = PBXFileReference; lastKnownFileType = "compiled.mach-o.dylib"; name = libutil.dylib; path = usr/lib/libutil.dylib; sourceTree = SDKROOT; }; + 4D559430153DC49A009F2584 /* mount_fdesc */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = mount_fdesc; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D55943B153DC4DE009F2584 /* mount_fdesc.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = mount_fdesc.8; path = mount_fdesc.tproj/mount_fdesc.8; sourceTree = SOURCE_ROOT; }; + 4D55943C153DC4DE009F2584 /* mount_fdesc.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = mount_fdesc.c; path = mount_fdesc.tproj/mount_fdesc.c; sourceTree = SOURCE_ROOT; }; + 4D55944E153DC634009F2584 /* vsdbutil */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = vsdbutil; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559457153DC650009F2584 /* com.apple.vsdbutil.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = com.apple.vsdbutil.plist; path = vsdbutil.tproj/com.apple.vsdbutil.plist; sourceTree = SOURCE_ROOT; }; + 4D559458153DC650009F2584 /* vsdbutil_main.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = vsdbutil_main.c; path = vsdbutil.tproj/vsdbutil_main.c; sourceTree = SOURCE_ROOT; }; + 4D559459153DC650009F2584 /* vsdbutil.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = vsdbutil.8; path = vsdbutil.tproj/vsdbutil.8; sourceTree = SOURCE_ROOT; }; + 4D559464153DC808009F2584 /* dev_mkdb */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = dev_mkdb; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D55946D153DC839009F2584 /* dev_mkdb.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = dev_mkdb.8; path = dev_mkdb.tproj/dev_mkdb.8; sourceTree = SOURCE_ROOT; }; + 4D55946E153DC839009F2584 /* dev_mkdb.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = dev_mkdb.c; path = dev_mkdb.tproj/dev_mkdb.c; sourceTree = SOURCE_ROOT; }; + 4D559477153DC8FC009F2584 /* fstyp */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fstyp; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559480153DC912009F2584 /* fstyp.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = fstyp.8; path = fstyp.tproj/fstyp.8; sourceTree = SOURCE_ROOT; }; + 4D559481153DC912009F2584 /* fstyp.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fstyp.c; path = fstyp.tproj/fstyp.c; sourceTree = SOURCE_ROOT; }; + 4D55948A153DC98D009F2584 /* fstyp_msdos */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fstyp_msdos; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D559493153DC9AE009F2584 /* fstyp_msdos.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = fstyp_msdos.8; path = fstyp.tproj/fstyp_msdos.8; sourceTree = SOURCE_ROOT; }; + 4D559494153DC9AE009F2584 /* fstyp_msdos.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fstyp_msdos.c; path = fstyp.tproj/fstyp_msdos.c; sourceTree = SOURCE_ROOT; }; + 4D55949D153DC9FB009F2584 /* fstyp_ntfs */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fstyp_ntfs; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5594A8153DCA19009F2584 /* fstyp_ntfs.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = fstyp_ntfs.8; path = fstyp.tproj/fstyp_ntfs.8; sourceTree = SOURCE_ROOT; }; + 4D5594A9153DCA19009F2584 /* fstyp_ntfs.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fstyp_ntfs.c; path = fstyp.tproj/fstyp_ntfs.c; sourceTree = SOURCE_ROOT; }; + 4D5594AF153DCA53009F2584 /* fstyp_udf */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fstyp_udf; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5594BA153DCA74009F2584 /* fstyp_udf.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = fstyp_udf.8; path = fstyp.tproj/fstyp_udf.8; sourceTree = SOURCE_ROOT; }; + 4D5594BB153DCA74009F2584 /* fstyp_udf.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = fstyp_udf.c; path = fstyp.tproj/fstyp_udf.c; sourceTree = SOURCE_ROOT; }; + 4D5594C2153DCAFC009F2584 /* setclass */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = setclass; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5594CB153DCB72009F2584 /* setclass.8 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = setclass.8; path = setclass.tproj/setclass.8; sourceTree = SOURCE_ROOT; }; + 4D5594CC153DCB72009F2584 /* setclass.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; name = setclass.c; path = setclass.tproj/setclass.c; sourceTree = SOURCE_ROOT; }; + 4D5594D5153DCC66009F2584 /* fuser */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.executable"; includeInIndex = 0; path = fuser; sourceTree = BUILT_PRODUCTS_DIR; }; + 4D5594E0153DCC92009F2584 /* fuser.1 */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.man; name = fuser.1; path = fuser.tproj/fuser.1; sourceTree = SOURCE_ROOT; }; + 4D5594E1153DCC92009F2584 /* fuser.pl */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.perl; name = fuser.pl; path = fuser.tproj/fuser.pl; sourceTree = SOURCE_ROOT; }; + 785314FE227120BD00B25661 /* MediaKit.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = MediaKit.framework; path = System/Library/PrivateFrameworks/MediaKit.framework; sourceTree = SDKROOT; }; + 785315012277BEA700B25661 /* mount.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; name = mount.entitlements; path = mount.tproj/mount.entitlements; sourceTree = SOURCE_ROOT; }; + B19B239A21C8DEF90001F35C /* edt_fstab.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = edt_fstab.c; sourceTree = ""; }; + B19B239B21C8DEFA0001F35C /* edt_fstab.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = edt_fstab.h; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 4D07DD46153CA9A0002B57CB /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559312153CE198009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55933E153CE41E009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + B19B239F21C8DF7B0001F35C /* CoreFoundation.framework in Frameworks */, + B19B239E21C8DF740001F35C /* APFS.framework in Frameworks */, + B19B239D21C8DF6E0001F35C /* IOKit.framework in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55935D153CE561009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 785314FF227120BD00B25661 /* MediaKit.framework in Frameworks */, + 1A9041062091EE980061D05A /* CoreFoundation.framework in Frameworks */, + 1A9041042091EE910061D05A /* APFS.framework in Frameworks */, + 1A9041022091EE830061D05A /* IOKit.framework in Frameworks */, + 4D559389153CE794009F2584 /* libdisk.a in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55938B153CE7FD009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + B19B23A521C8DFE10001F35C /* CoreFoundation.framework in Frameworks */, + B19B23A421C8DFD50001F35C /* IOKit.framework in Frameworks */, + B19B23A321C8DFCF0001F35C /* APFS.framework in Frameworks */, + 4D55939D153CE8AF009F2584 /* libdisk.a in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593A3153CEA90009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593B6153CEB7E009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593CA153CED29009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5593DF153CED8D009F2584 /* libdisk.a in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593E1153CEE4A009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593F5153DC0DE009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559408153DC27A009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559419153DC383009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D55942B153DC427009F2584 /* libutil.dylib in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55942D153DC49A009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D55943F153DC534009F2584 /* libutil.dylib in Frameworks */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55944B153DC634009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559461153DC808009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559474153DC8FC009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559487153DC98D009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55949A153DC9FB009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5594AC153DCA53009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5594BF153DCAFC009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5594D2153DCC66009F2584 /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 072AAAA32167CD68004ED4E2 /* mount_flags_dir */ = { + isa = PBXGroup; + children = ( + 072AAAA42167CE8E004ED4E2 /* mount_flags.c */, + 072AAAA52167CE8E004ED4E2 /* mount_flags.h */, + ); + path = mount_flags_dir; + sourceTree = ""; + }; + 1A9041002091EE820061D05A /* Frameworks */ = { + isa = PBXGroup; + children = ( + 07AF95B323232837001E9266 /* Kernel.framework */, + 07AF95B12323281D001E9266 /* System.framework */, + 785314FE227120BD00B25661 /* MediaKit.framework */, + 1A9041052091EE980061D05A /* CoreFoundation.framework */, + 1A9041032091EE910061D05A /* APFS.framework */, + 1A9041012091EE830061D05A /* IOKit.framework */, + ); + name = Frameworks; + sourceTree = ""; + }; + 4D07DD29153CA616002B57CB = { + isa = PBXGroup; + children = ( + B1DF3D3D21C27FE00099F594 /* edt_fstab */, + 072AAAA32167CD68004ED4E2 /* mount_flags_dir */, + 4D559466153DC808009F2584 /* dev_mkdb */, + 4D07DD4C153CA9C4002B57CB /* disklib */, + 4D5593A8153CEA90009F2584 /* edquota */, + 4D559317153CE199009F2584 /* fdisk */, + 4D559343153CE41E009F2584 /* fsck */, + 4D559479153DC8FC009F2584 /* fstyp */, + 4D55948C153DC98D009F2584 /* fstyp_msdos */, + 4D55949F153DC9FB009F2584 /* fstyp_ntfs */, + 4D5594B1153DCA53009F2584 /* fstyp_udf */, + 4D5594D7153DCC66009F2584 /* fuser */, + 4D559362153CE561009F2584 /* mount */, + 4D55941E153DC384009F2584 /* mount_devfs */, + 4D559432153DC49A009F2584 /* mount_fdesc */, + 4D5593BB153CEB7E009F2584 /* quota */, + 4D5593CF153CED29009F2584 /* quotacheck */, + 4D5593E6153CEE4A009F2584 /* quotaon */, + 4D5593FA153DC0DE009F2584 /* repquota */, + 4D5594C4153DCAFC009F2584 /* setclass */, + 4D559390153CE7FD009F2584 /* umount */, + 4D55940D153DC27A009F2584 /* vndevice */, + 4D559450153DC634009F2584 /* vsdbutil */, + 4D559429153DC3F3009F2584 /* Libraries */, + 4D07DD35153CA616002B57CB /* Products */, + 1A9041002091EE820061D05A /* Frameworks */, + ); + sourceTree = ""; + }; + 4D07DD35153CA616002B57CB /* Products */ = { + isa = PBXGroup; + children = ( + 4D07DD49153CA9A0002B57CB /* libdisk.a */, + 4D559315153CE198009F2584 /* fdisk */, + 4D559341153CE41E009F2584 /* fsck */, + 4D559360153CE561009F2584 /* mount */, + 4D55938E153CE7FD009F2584 /* umount */, + 4D5593A6153CEA90009F2584 /* edquota */, + 4D5593B9153CEB7E009F2584 /* quota */, + 4D5593CD153CED29009F2584 /* quotacheck */, + 4D5593E4153CEE4A009F2584 /* quotaon */, + 4D5593F8153DC0DE009F2584 /* repquota */, + 4D55940B153DC27A009F2584 /* vndevice */, + 4D55941C153DC383009F2584 /* mount_devfs */, + 4D559430153DC49A009F2584 /* mount_fdesc */, + 4D55944E153DC634009F2584 /* vsdbutil */, + 4D559464153DC808009F2584 /* dev_mkdb */, + 4D559477153DC8FC009F2584 /* fstyp */, + 4D55948A153DC98D009F2584 /* fstyp_msdos */, + 4D55949D153DC9FB009F2584 /* fstyp_ntfs */, + 4D5594AF153DCA53009F2584 /* fstyp_udf */, + 4D5594C2153DCAFC009F2584 /* setclass */, + 4D5594D5153DCC66009F2584 /* fuser */, + ); + name = Products; + sourceTree = ""; + }; + 4D07DD4C153CA9C4002B57CB /* disklib */ = { + isa = PBXGroup; + children = ( + 4D07DD50153CA9DC002B57CB /* dkopen.h */, + 4D07DD54153CA9DC002B57CB /* pathnames.h */, + 4D07DD4D153CA9DC002B57CB /* dkcksum.c */, + 4D07DD4E153CA9DC002B57CB /* dkdisklabel.c */, + 4D07DD4F153CA9DC002B57CB /* dkopen.c */, + 4D07DD51153CA9DC002B57CB /* dksecsize.c */, + 4D07DD55153CA9DC002B57CB /* preen.c */, + 4D07DD56153CA9DC002B57CB /* vfslist.c */, + ); + name = disklib; + sourceTree = ""; + }; + 4D559317153CE199009F2584 /* fdisk */ = { + isa = PBXGroup; + children = ( + 4D55931F153CE1D9009F2584 /* auto.h */, + 4D559321153CE1D9009F2584 /* cmd.h */, + 4D559323153CE1D9009F2584 /* disk.h */, + 4D559328153CE1D9009F2584 /* mbr.h */, + 4D559329153CE1D9009F2584 /* mbrcode.h */, + 4D55932B153CE1D9009F2584 /* misc.h */, + 4D55932E153CE1D9009F2584 /* part.h */, + 4D559330153CE1D9009F2584 /* user.h */, + 4D559331153CE1D9009F2584 /* util.h */, + 4D55931E153CE1D9009F2584 /* auto.c */, + 4D559320153CE1D9009F2584 /* cmd.c */, + 4D559322153CE1D9009F2584 /* disk.c */, + 4D559325153CE1D9009F2584 /* fdisk.c */, + 4D559326153CE1D9009F2584 /* getrawpartition.c */, + 4D559327153CE1D9009F2584 /* mbr.c */, + 4D55932A153CE1D9009F2584 /* misc.c */, + 4D55932C153CE1D9009F2584 /* opendev.c */, + 4D55932D153CE1D9009F2584 /* part.c */, + 4D55932F153CE1D9009F2584 /* user.c */, + 4D559324153CE1D9009F2584 /* fdisk.8 */, + ); + path = fdisk; + sourceTree = ""; + }; + 4D559343153CE41E009F2584 /* fsck */ = { + isa = PBXGroup; + children = ( + 4D55934C153CE44E009F2584 /* fsck.h */, + 4D55934B153CE44E009F2584 /* fsck.c */, + 4D55934A153CE44E009F2584 /* fsck.8 */, + ); + path = fsck; + sourceTree = ""; + }; + 4D559362153CE561009F2584 /* mount */ = { + isa = PBXGroup; + children = ( + 4D55936D153CE58E009F2584 /* pathnames.h */, + 4D55936C153CE58E009F2584 /* mount.c */, + 4D55936B153CE58E009F2584 /* mount.8 */, + 4D559369153CE58E009F2584 /* fstab.5 */, + 785315012277BEA700B25661 /* mount.entitlements */, + ); + path = mount; + sourceTree = ""; + }; + 4D559390153CE7FD009F2584 /* umount */ = { + isa = PBXGroup; + children = ( + 4D559398153CE826009F2584 /* umount.c */, + 4D559397153CE826009F2584 /* umount.8 */, + ); + path = umount; + sourceTree = ""; + }; + 4D5593A8153CEA90009F2584 /* edquota */ = { + isa = PBXGroup; + children = ( + 4D5593B1153CEABD009F2584 /* pathnames.h */, + 4D5593B0153CEABD009F2584 /* edquota.c */, + 4D5593AF153CEABD009F2584 /* edquota.8 */, + ); + path = edquota; + sourceTree = ""; + }; + 4D5593BB153CEB7E009F2584 /* quota */ = { + isa = PBXGroup; + children = ( + 4D5593C2153CEB9A009F2584 /* quota.1 */, + 4D5593C3153CEB9A009F2584 /* quota.c */, + ); + path = quota; + sourceTree = ""; + }; + 4D5593CF153CED29009F2584 /* quotacheck */ = { + isa = PBXGroup; + children = ( + 4D5593DB153CED51009F2584 /* quotacheck.h */, + 4D5593D8153CED51009F2584 /* hfs_quotacheck.c */, + 4D5593DA153CED51009F2584 /* quotacheck.c */, + 4D5593D9153CED51009F2584 /* quotacheck.8 */, + ); + path = quotacheck; + sourceTree = ""; + }; + 4D5593E6153CEE4A009F2584 /* quotaon */ = { + isa = PBXGroup; + children = ( + 4D5593EE153CEE66009F2584 /* quotaon.c */, + 4D5593ED153CEE66009F2584 /* quotaon.8 */, + ); + path = quotaon; + sourceTree = ""; + }; + 4D5593FA153DC0DE009F2584 /* repquota */ = { + isa = PBXGroup; + children = ( + 4D559402153DC13D009F2584 /* repquota.c */, + 4D559401153DC13D009F2584 /* repquota.8 */, + ); + path = repquota; + sourceTree = ""; + }; + 4D55940D153DC27A009F2584 /* vndevice */ = { + isa = PBXGroup; + children = ( + 4D559416153DC2AB009F2584 /* vndevice.c */, + ); + path = vndevice; + sourceTree = ""; + }; + 4D55941E153DC384009F2584 /* mount_devfs */ = { + isa = PBXGroup; + children = ( + 4D559427153DC3A6009F2584 /* mount_devfs.c */, + ); + path = mount_devfs; + sourceTree = ""; + }; + 4D559429153DC3F3009F2584 /* Libraries */ = { + isa = PBXGroup; + children = ( + 4D55942A153DC420009F2584 /* libutil.dylib */, + ); + name = Libraries; + sourceTree = ""; + }; + 4D559432153DC49A009F2584 /* mount_fdesc */ = { + isa = PBXGroup; + children = ( + 4D55943B153DC4DE009F2584 /* mount_fdesc.8 */, + 4D55943C153DC4DE009F2584 /* mount_fdesc.c */, + ); + path = mount_fdesc; + sourceTree = ""; + }; + 4D559450153DC634009F2584 /* vsdbutil */ = { + isa = PBXGroup; + children = ( + 4D559458153DC650009F2584 /* vsdbutil_main.c */, + 4D559457153DC650009F2584 /* com.apple.vsdbutil.plist */, + 4D559459153DC650009F2584 /* vsdbutil.8 */, + ); + path = vsdbutil; + sourceTree = ""; + }; + 4D559466153DC808009F2584 /* dev_mkdb */ = { + isa = PBXGroup; + children = ( + 4D55946D153DC839009F2584 /* dev_mkdb.8 */, + 4D55946E153DC839009F2584 /* dev_mkdb.c */, + ); + path = dev_mkdb; + sourceTree = ""; + }; + 4D559479153DC8FC009F2584 /* fstyp */ = { + isa = PBXGroup; + children = ( + 4D559480153DC912009F2584 /* fstyp.8 */, + 4D559481153DC912009F2584 /* fstyp.c */, + ); + path = fstyp; + sourceTree = ""; + }; + 4D55948C153DC98D009F2584 /* fstyp_msdos */ = { + isa = PBXGroup; + children = ( + 4D559493153DC9AE009F2584 /* fstyp_msdos.8 */, + 4D559494153DC9AE009F2584 /* fstyp_msdos.c */, + ); + path = fstyp_msdos; + sourceTree = ""; + }; + 4D55949F153DC9FB009F2584 /* fstyp_ntfs */ = { + isa = PBXGroup; + children = ( + 4D5594A8153DCA19009F2584 /* fstyp_ntfs.8 */, + 4D5594A9153DCA19009F2584 /* fstyp_ntfs.c */, + ); + path = fstyp_ntfs; + sourceTree = ""; + }; + 4D5594B1153DCA53009F2584 /* fstyp_udf */ = { + isa = PBXGroup; + children = ( + 4D5594BA153DCA74009F2584 /* fstyp_udf.8 */, + 4D5594BB153DCA74009F2584 /* fstyp_udf.c */, + ); + path = fstyp_udf; + sourceTree = ""; + }; + 4D5594C4153DCAFC009F2584 /* setclass */ = { + isa = PBXGroup; + children = ( + 4D5594CB153DCB72009F2584 /* setclass.8 */, + 4D5594CC153DCB72009F2584 /* setclass.c */, + ); + path = setclass; + sourceTree = ""; + }; + 4D5594D7153DCC66009F2584 /* fuser */ = { + isa = PBXGroup; + children = ( + 4D5594E0153DCC92009F2584 /* fuser.1 */, + 4D5594E1153DCC92009F2584 /* fuser.pl */, + ); + path = fuser; + sourceTree = ""; + }; + B1DF3D3D21C27FE00099F594 /* edt_fstab */ = { + isa = PBXGroup; + children = ( + B19B239A21C8DEF90001F35C /* edt_fstab.c */, + B19B239B21C8DEFA0001F35C /* edt_fstab.h */, + ); + path = edt_fstab; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXHeadersBuildPhase section */ + 4D07DD47153CA9A0002B57CB /* Headers */ = { + isa = PBXHeadersBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D07DD5A153CA9DC002B57CB /* dkopen.h in Headers */, + 4D07DD5E153CA9DC002B57CB /* pathnames.h in Headers */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXHeadersBuildPhase section */ + +/* Begin PBXNativeTarget section */ + 4D07DD48153CA9A0002B57CB /* libdisk */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D07DD4A153CA9A0002B57CB /* Build configuration list for PBXNativeTarget "libdisk" */; + buildPhases = ( + 4D07DD45153CA9A0002B57CB /* Sources */, + 4D07DD46153CA9A0002B57CB /* Frameworks */, + 4D07DD47153CA9A0002B57CB /* Headers */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = libdisk; + productName = disklib; + productReference = 4D07DD49153CA9A0002B57CB /* libdisk.a */; + productType = "com.apple.product-type.library.static"; + }; + 4D559314153CE198009F2584 /* fdisk */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D55931C153CE199009F2584 /* Build configuration list for PBXNativeTarget "fdisk" */; + buildPhases = ( + 4D559311153CE198009F2584 /* Sources */, + 4D559312153CE198009F2584 /* Frameworks */, + 4D559313153CE198009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = fdisk; + productName = fdisk; + productReference = 4D559315153CE198009F2584 /* fdisk */; + productType = "com.apple.product-type.tool"; + }; + 4D559340153CE41E009F2584 /* fsck */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559348153CE41E009F2584 /* Build configuration list for PBXNativeTarget "fsck" */; + buildPhases = ( + 4D55933D153CE41E009F2584 /* Sources */, + 4D55933E153CE41E009F2584 /* Frameworks */, + 4D55933F153CE41E009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = fsck; + productName = fsck; + productReference = 4D559341153CE41E009F2584 /* fsck */; + productType = "com.apple.product-type.tool"; + }; + 4D55935F153CE561009F2584 /* mount */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559367153CE561009F2584 /* Build configuration list for PBXNativeTarget "mount" */; + buildPhases = ( + 4D55935C153CE561009F2584 /* Sources */, + 4D55935D153CE561009F2584 /* Frameworks */, + 4D55935E153CE561009F2584 /* Copy man5 */, + 4D559370153CE5DC009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + 4D5593A1153CE8BC009F2584 /* PBXTargetDependency */, + ); + name = mount; + productName = mount; + productReference = 4D559360153CE561009F2584 /* mount */; + productType = "com.apple.product-type.tool"; + }; + 4D55938D153CE7FD009F2584 /* umount */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559395153CE7FE009F2584 /* Build configuration list for PBXNativeTarget "umount" */; + buildPhases = ( + 4D55938A153CE7FD009F2584 /* Sources */, + 4D55938B153CE7FD009F2584 /* Frameworks */, + 4D55938C153CE7FD009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + 4D55939F153CE8B6009F2584 /* PBXTargetDependency */, + ); + name = umount; + productName = umount; + productReference = 4D55938E153CE7FD009F2584 /* umount */; + productType = "com.apple.product-type.tool"; + }; + 4D5593A5153CEA90009F2584 /* edquota */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5593AD153CEA90009F2584 /* Build configuration list for PBXNativeTarget "edquota" */; + buildPhases = ( + 4D5593A2153CEA90009F2584 /* Sources */, + 4D5593A3153CEA90009F2584 /* Frameworks */, + 4D5593A4153CEA90009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = edquota; + productName = edquota; + productReference = 4D5593A6153CEA90009F2584 /* edquota */; + productType = "com.apple.product-type.tool"; + }; + 4D5593B8153CEB7E009F2584 /* quota */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5593C0153CEB7E009F2584 /* Build configuration list for PBXNativeTarget "quota" */; + buildPhases = ( + 4D5593B5153CEB7E009F2584 /* Sources */, + 4D5593B6153CEB7E009F2584 /* Frameworks */, + 4D5593B7153CEB7E009F2584 /* Copy man1 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = quota; + productName = quota; + productReference = 4D5593B9153CEB7E009F2584 /* quota */; + productType = "com.apple.product-type.tool"; + }; + 4D5593CC153CED29009F2584 /* quotacheck */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5593D4153CED29009F2584 /* Build configuration list for PBXNativeTarget "quotacheck" */; + buildPhases = ( + 4D5593C9153CED29009F2584 /* Sources */, + 4D5593CA153CED29009F2584 /* Frameworks */, + 4D5593CB153CED29009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = quotacheck; + productName = quotacheck; + productReference = 4D5593CD153CED29009F2584 /* quotacheck */; + productType = "com.apple.product-type.tool"; + }; + 4D5593E3153CEE4A009F2584 /* quotaon */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5593EB153CEE4A009F2584 /* Build configuration list for PBXNativeTarget "quotaon" */; + buildPhases = ( + 4D5593E0153CEE4A009F2584 /* Sources */, + 4D5593E1153CEE4A009F2584 /* Frameworks */, + 4D5593E2153CEE4A009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = quotaon; + productName = quotaon; + productReference = 4D5593E4153CEE4A009F2584 /* quotaon */; + productType = "com.apple.product-type.tool"; + }; + 4D5593F7153DC0DE009F2584 /* repquota */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5593FF153DC0DE009F2584 /* Build configuration list for PBXNativeTarget "repquota" */; + buildPhases = ( + 4D5593F4153DC0DE009F2584 /* Sources */, + 4D5593F5153DC0DE009F2584 /* Frameworks */, + 4D5593F6153DC0DE009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = repquota; + productName = repquota; + productReference = 4D5593F8153DC0DE009F2584 /* repquota */; + productType = "com.apple.product-type.tool"; + }; + 4D55940A153DC27A009F2584 /* vndevice */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559412153DC27A009F2584 /* Build configuration list for PBXNativeTarget "vndevice" */; + buildPhases = ( + 4D559407153DC27A009F2584 /* Sources */, + 4D559408153DC27A009F2584 /* Frameworks */, + 4D559409153DC27A009F2584 /* Copy man1 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = vndevice; + productName = vndevice; + productReference = 4D55940B153DC27A009F2584 /* vndevice */; + productType = "com.apple.product-type.tool"; + }; + 4D55941B153DC383009F2584 /* mount_devfs */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559423153DC384009F2584 /* Build configuration list for PBXNativeTarget "mount_devfs" */; + buildPhases = ( + 4D559418153DC383009F2584 /* Sources */, + 4D559419153DC383009F2584 /* Frameworks */, + 4D55941A153DC383009F2584 /* CopyFiles */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = mount_devfs; + productName = mount_devfs; + productReference = 4D55941C153DC383009F2584 /* mount_devfs */; + productType = "com.apple.product-type.tool"; + }; + 4D55942F153DC49A009F2584 /* mount_fdesc */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559437153DC49A009F2584 /* Build configuration list for PBXNativeTarget "mount_fdesc" */; + buildPhases = ( + 4D55942C153DC49A009F2584 /* Sources */, + 4D55942D153DC49A009F2584 /* Frameworks */, + 4D55942E153DC49A009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = mount_fdesc; + productName = mount_fdesc; + productReference = 4D559430153DC49A009F2584 /* mount_fdesc */; + productType = "com.apple.product-type.tool"; + }; + 4D55944D153DC634009F2584 /* vsdbutil */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559455153DC634009F2584 /* Build configuration list for PBXNativeTarget "vsdbutil" */; + buildPhases = ( + 4D55944A153DC634009F2584 /* Sources */, + 4D55944B153DC634009F2584 /* Frameworks */, + 4D55944C153DC634009F2584 /* Copy man8 */, + 4D55945E153DC730009F2584 /* Copy com.apple.vsdbutil.plist */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = vsdbutil; + productName = vsdbutil; + productReference = 4D55944E153DC634009F2584 /* vsdbutil */; + productType = "com.apple.product-type.tool"; + }; + 4D559463153DC808009F2584 /* dev_mkdb */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D55946B153DC808009F2584 /* Build configuration list for PBXNativeTarget "dev_mkdb" */; + buildPhases = ( + 4D559460153DC808009F2584 /* Sources */, + 4D559461153DC808009F2584 /* Frameworks */, + 4D559462153DC808009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = dev_mkdb; + productName = dev_mkdb; + productReference = 4D559464153DC808009F2584 /* dev_mkdb */; + productType = "com.apple.product-type.tool"; + }; + 4D559476153DC8FC009F2584 /* fstyp */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D55947E153DC8FC009F2584 /* Build configuration list for PBXNativeTarget "fstyp" */; + buildPhases = ( + 4D559473153DC8FC009F2584 /* Sources */, + 4D559474153DC8FC009F2584 /* Frameworks */, + 4D559475153DC8FC009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = fstyp; + productName = fstyp; + productReference = 4D559477153DC8FC009F2584 /* fstyp */; + productType = "com.apple.product-type.tool"; + }; + 4D559489153DC98D009F2584 /* fstyp_msdos */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D559491153DC98D009F2584 /* Build configuration list for PBXNativeTarget "fstyp_msdos" */; + buildPhases = ( + 4D559486153DC98D009F2584 /* Sources */, + 4D559487153DC98D009F2584 /* Frameworks */, + 4D559488153DC98D009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = fstyp_msdos; + productName = fstyp_msdos; + productReference = 4D55948A153DC98D009F2584 /* fstyp_msdos */; + productType = "com.apple.product-type.tool"; + }; + 4D55949C153DC9FB009F2584 /* fstyp_ntfs */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5594A4153DC9FB009F2584 /* Build configuration list for PBXNativeTarget "fstyp_ntfs" */; + buildPhases = ( + 4D559499153DC9FB009F2584 /* Sources */, + 4D55949A153DC9FB009F2584 /* Frameworks */, + 4D55949B153DC9FB009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = fstyp_ntfs; + productName = fstyp_ntfs; + productReference = 4D55949D153DC9FB009F2584 /* fstyp_ntfs */; + productType = "com.apple.product-type.tool"; + }; + 4D5594AE153DCA53009F2584 /* fstyp_udf */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5594B6153DCA53009F2584 /* Build configuration list for PBXNativeTarget "fstyp_udf" */; + buildPhases = ( + 4D5594AB153DCA53009F2584 /* Sources */, + 4D5594AC153DCA53009F2584 /* Frameworks */, + 4D5594AD153DCA53009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = fstyp_udf; + productName = fstyp_udf; + productReference = 4D5594AF153DCA53009F2584 /* fstyp_udf */; + productType = "com.apple.product-type.tool"; + }; + 4D5594C1153DCAFC009F2584 /* setclass */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5594C9153DCAFC009F2584 /* Build configuration list for PBXNativeTarget "setclass" */; + buildPhases = ( + 4D5594BE153DCAFC009F2584 /* Sources */, + 4D5594BF153DCAFC009F2584 /* Frameworks */, + 4D5594C0153DCAFC009F2584 /* Copy man8 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = setclass; + productName = setclass; + productReference = 4D5594C2153DCAFC009F2584 /* setclass */; + productType = "com.apple.product-type.tool"; + }; + 4D5594D4153DCC66009F2584 /* fuser */ = { + isa = PBXNativeTarget; + buildConfigurationList = 4D5594DC153DCC66009F2584 /* Build configuration list for PBXNativeTarget "fuser" */; + buildPhases = ( + 4D5594D1153DCC66009F2584 /* Sources */, + 4D5594D2153DCC66009F2584 /* Frameworks */, + 4D5594E4153DCCD3009F2584 /* Copy fuser */, + 4D5594D3153DCC66009F2584 /* Copy man1 */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = fuser; + productName = fuser; + productReference = 4D5594D5153DCC66009F2584 /* fuser */; + productType = "com.apple.product-type.tool"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 4D07DD2B153CA616002B57CB /* Project object */ = { + isa = PBXProject; + attributes = { + LastUpgradeCheck = 0440; + ORGANIZATIONNAME = "Apple Inc."; + }; + buildConfigurationList = 4D07DD2E153CA616002B57CB /* Build configuration list for PBXProject "diskdev_cmds" */; + compatibilityVersion = "Xcode 3.2"; + developmentRegion = English; + hasScannedForEncodings = 0; + knownRegions = ( + English, + en, + ); + mainGroup = 4D07DD29153CA616002B57CB; + productRefGroup = 4D07DD35153CA616002B57CB /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 4D559440153DC57D009F2584 /* All_MacOSX */, + 4D559443153DC587009F2584 /* All_iOS */, + 4D55934F153CE4CC009F2584 /* Common */, + 4D07DD48153CA9A0002B57CB /* libdisk */, + 4D559463153DC808009F2584 /* dev_mkdb */, + 4D5593A5153CEA90009F2584 /* edquota */, + 4D559314153CE198009F2584 /* fdisk */, + 4D559340153CE41E009F2584 /* fsck */, + 4D559476153DC8FC009F2584 /* fstyp */, + 4D559489153DC98D009F2584 /* fstyp_msdos */, + 4D55949C153DC9FB009F2584 /* fstyp_ntfs */, + 4D5594AE153DCA53009F2584 /* fstyp_udf */, + 4D5594D4153DCC66009F2584 /* fuser */, + 4D55935F153CE561009F2584 /* mount */, + 4D55941B153DC383009F2584 /* mount_devfs */, + 4D55942F153DC49A009F2584 /* mount_fdesc */, + 4D5593B8153CEB7E009F2584 /* quota */, + 4D5593CC153CED29009F2584 /* quotacheck */, + 4D5593E3153CEE4A009F2584 /* quotaon */, + 4D559514153DE116009F2584 /* quotaoff */, + 4D5593F7153DC0DE009F2584 /* repquota */, + 4D5594C1153DCAFC009F2584 /* setclass */, + 4D55938D153CE7FD009F2584 /* umount */, + 4D55940A153DC27A009F2584 /* vndevice */, + 4D55944D153DC634009F2584 /* vsdbutil */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXShellScriptBuildPhase section */ + 4D5594E4153DCCD3009F2584 /* Copy fuser */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 8; + files = ( + ); + inputPaths = ( + "$(SRCROOT)/fuser.tproj/fuser.pl", + ); + name = "Copy fuser"; + outputPaths = ( + "$(DSTROOT)$(INSTALL_PATH)/fuser", + ); + runOnlyForDeploymentPostprocessing = 1; + shellPath = /bin/sh; + shellScript = "set -x\nset -e\n\ncp ${SCRIPT_INPUT_FILE_0} ${SCRIPT_OUTPUT_FILE_0}\nchmod 555 ${SCRIPT_OUTPUT_FILE_0}\n"; + showEnvVarsInLog = 0; + }; + 4D55951B153DE1EF009F2584 /* ShellScript */ = { + isa = PBXShellScriptBuildPhase; + buildActionMask = 8; + files = ( + ); + inputPaths = ( + "$(DSTROOT)/usr/sbin/quotaon", + "$(DSTROOT)/usr/share/man/man8/quotaon.8", + ); + outputPaths = ( + "$(DSTROOT)/usr/sbin/quotaoff", + "$(DSTROOT)/usr/share/man/man8/quotaoff.8", + ); + runOnlyForDeploymentPostprocessing = 1; + shellPath = /bin/sh; + shellScript = "set -x\nset -e\n\nln -fhv \"${SCRIPT_INPUT_FILE_0}\" \"${SCRIPT_OUTPUT_FILE_0}\"\nmkdir -p \"${DSTROOT}/usr/share/man/man8\"\nln -fhv \"${SCRIPT_INPUT_FILE_1}\" \"${SCRIPT_OUTPUT_FILE_1}\"\n"; + showEnvVarsInLog = 0; + }; +/* End PBXShellScriptBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 4D07DD45153CA9A0002B57CB /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D07DD57153CA9DC002B57CB /* dkcksum.c in Sources */, + 4D07DD5B153CA9DC002B57CB /* dksecsize.c in Sources */, + 4D07DD5F153CA9DC002B57CB /* preen.c in Sources */, + 4D07DD60153CA9DC002B57CB /* vfslist.c in Sources */, + 4D07DD58153CA9DC002B57CB /* dkdisklabel.c in Sources */, + 4D07DD59153CA9DC002B57CB /* dkopen.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559311153CE198009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D559333153CE1D9009F2584 /* cmd.c in Sources */, + 4D559334153CE1D9009F2584 /* disk.c in Sources */, + 4D559335153CE1D9009F2584 /* fdisk.c in Sources */, + 4D559336153CE1D9009F2584 /* getrawpartition.c in Sources */, + 4D559337153CE1D9009F2584 /* mbr.c in Sources */, + 4D559338153CE1D9009F2584 /* misc.c in Sources */, + 4D559339153CE1D9009F2584 /* opendev.c in Sources */, + 4D55933A153CE1D9009F2584 /* part.c in Sources */, + 4D55933B153CE1D9009F2584 /* user.c in Sources */, + 4D559332153CE1D9009F2584 /* auto.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55933D153CE41E009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + B19B239C21C8DF660001F35C /* edt_fstab.c in Sources */, + 4D55934D153CE44E009F2584 /* fsck.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55935C153CE561009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + B19B23A021C8DFA40001F35C /* edt_fstab.c in Sources */, + 07CE4C1821906BB800BF11C0 /* mount.c in Sources */, + 072AAAA62167CE8F004ED4E2 /* mount_flags.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55938A153CE7FD009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + B19B23A221C8DFC30001F35C /* edt_fstab.c in Sources */, + 4D559399153CE826009F2584 /* umount.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593A2153CEA90009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5593B2153CEABD009F2584 /* edquota.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593B5153CEB7E009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5593C4153CEB9A009F2584 /* quota.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593C9153CED29009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5593DD153CED51009F2584 /* quotacheck.c in Sources */, + 4D5593DC153CED51009F2584 /* hfs_quotacheck.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593E0153CEE4A009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5593EF153CEE66009F2584 /* quotaon.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5593F4153DC0DE009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D559403153DC13D009F2584 /* repquota.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559407153DC27A009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D559417153DC2AB009F2584 /* vndevice.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559418153DC383009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D559428153DC3A6009F2584 /* mount_devfs.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55942C153DC49A009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D55943D153DC4DE009F2584 /* mount_fdesc.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D55944A153DC634009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 078B970D2190682600674625 /* mount_flags.c in Sources */, + 4D55945A153DC650009F2584 /* vsdbutil_main.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559460153DC808009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D55946F153DC839009F2584 /* dev_mkdb.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559473153DC8FC009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D559482153DC912009F2584 /* fstyp.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559486153DC98D009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D559495153DC9AE009F2584 /* fstyp_msdos.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D559499153DC9FB009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5594AA153DCA19009F2584 /* fstyp_ntfs.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5594AB153DCA53009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5594BC153DCA74009F2584 /* fstyp_udf.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5594BE153DCAFC009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 4D5594CD153DCB72009F2584 /* setclass.c in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 4D5594D1153DCC66009F2584 /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 071077D92488A09C003B97C7 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5594C1153DCAFC009F2584 /* setclass */; + targetProxy = 071077D82488A09C003B97C7 /* PBXContainerItemProxy */; + }; + 07747AA21DA8511D00ACE020 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D559476153DC8FC009F2584 /* fstyp */; + targetProxy = 07747AA11DA8511D00ACE020 /* PBXContainerItemProxy */; + }; + 4D559357153CE4EA009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D07DD48153CA9A0002B57CB /* libdisk */; + targetProxy = 4D559356153CE4EA009F2584 /* PBXContainerItemProxy */; + }; + 4D559359153CE4EC009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D559314153CE198009F2584 /* fdisk */; + targetProxy = 4D559358153CE4EC009F2584 /* PBXContainerItemProxy */; + }; + 4D55935B153CE4ED009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D559340153CE41E009F2584 /* fsck */; + targetProxy = 4D55935A153CE4ED009F2584 /* PBXContainerItemProxy */; + }; + 4D559373153CE5F8009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55935F153CE561009F2584 /* mount */; + targetProxy = 4D559372153CE5F8009F2584 /* PBXContainerItemProxy */; + }; + 4D55939C153CE83A009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55938D153CE7FD009F2584 /* umount */; + targetProxy = 4D55939B153CE83A009F2584 /* PBXContainerItemProxy */; + }; + 4D55939F153CE8B6009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D07DD48153CA9A0002B57CB /* libdisk */; + targetProxy = 4D55939E153CE8B6009F2584 /* PBXContainerItemProxy */; + }; + 4D5593A1153CE8BC009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D07DD48153CA9A0002B57CB /* libdisk */; + targetProxy = 4D5593A0153CE8BC009F2584 /* PBXContainerItemProxy */; + }; + 4D559415153DC282009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55940A153DC27A009F2584 /* vndevice */; + targetProxy = 4D559414153DC282009F2584 /* PBXContainerItemProxy */; + }; + 4D559426153DC38F009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55941B153DC383009F2584 /* mount_devfs */; + targetProxy = 4D559425153DC38F009F2584 /* PBXContainerItemProxy */; + }; + 4D55943A153DC4C0009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55942F153DC49A009F2584 /* mount_fdesc */; + targetProxy = 4D559439153DC4C0009F2584 /* PBXContainerItemProxy */; + }; + 4D559447153DC597009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55934F153CE4CC009F2584 /* Common */; + targetProxy = 4D559446153DC597009F2584 /* PBXContainerItemProxy */; + }; + 4D559449153DC599009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55934F153CE4CC009F2584 /* Common */; + targetProxy = 4D559448153DC599009F2584 /* PBXContainerItemProxy */; + }; + 4D55945C153DC665009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55944D153DC634009F2584 /* vsdbutil */; + targetProxy = 4D55945B153DC665009F2584 /* PBXContainerItemProxy */; + }; + 4D559472153DC87B009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D559463153DC808009F2584 /* dev_mkdb */; + targetProxy = 4D559471153DC87B009F2584 /* PBXContainerItemProxy */; + }; + 4D559498153DC9E8009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D559489153DC98D009F2584 /* fstyp_msdos */; + targetProxy = 4D559497153DC9E8009F2584 /* PBXContainerItemProxy */; + }; + 4D5594A7153DCA04009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D55949C153DC9FB009F2584 /* fstyp_ntfs */; + targetProxy = 4D5594A6153DCA04009F2584 /* PBXContainerItemProxy */; + }; + 4D5594B9153DCA5E009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5594AE153DCA53009F2584 /* fstyp_udf */; + targetProxy = 4D5594B8153DCA5E009F2584 /* PBXContainerItemProxy */; + }; + 4D5594DF153DCC73009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5594D4153DCC66009F2584 /* fuser */; + targetProxy = 4D5594DE153DCC73009F2584 /* PBXContainerItemProxy */; + }; + 4D55951A153DE1CB009F2584 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5593E3153CEE4A009F2584 /* quotaon */; + targetProxy = 4D559519153DE1CB009F2584 /* PBXContainerItemProxy */; + }; + B12C9C9222A7CDE300B9F497 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5593A5153CEA90009F2584 /* edquota */; + targetProxy = B12C9C9122A7CDE300B9F497 /* PBXContainerItemProxy */; + }; + B12C9C9422A7CDE300B9F497 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5593B8153CEB7E009F2584 /* quota */; + targetProxy = B12C9C9322A7CDE300B9F497 /* PBXContainerItemProxy */; + }; + B12C9C9622A7CDE300B9F497 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5593CC153CED29009F2584 /* quotacheck */; + targetProxy = B12C9C9522A7CDE300B9F497 /* PBXContainerItemProxy */; + }; + B12C9C9822A7CDE300B9F497 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5593E3153CEE4A009F2584 /* quotaon */; + targetProxy = B12C9C9722A7CDE300B9F497 /* PBXContainerItemProxy */; + }; + B12C9C9A22A7CDE300B9F497 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D559514153DE116009F2584 /* quotaoff */; + targetProxy = B12C9C9922A7CDE300B9F497 /* PBXContainerItemProxy */; + }; + B12C9C9C22A7CDE300B9F497 /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 4D5593F7153DC0DE009F2584 /* repquota */; + targetProxy = B12C9C9B22A7CDE300B9F497 /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 4D07DD3D153CA616002B57CB /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + ARCHS = "$(ARCHS_STANDARD_64_BIT)"; + DEAD_CODE_STRIPPING = YES; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + INSTALL_MODE_FLAG = "ugo-w,a+rX"; + OTHER_CFLAGS = ""; + SDKROOT = macosx.internal; + SUPPORTED_PLATFORMS = "macosx iphoneos"; + WARNING_CFLAGS = "-Wall"; + }; + name = Release; + }; + 4D07DD4B153CA9A0002B57CB /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + EXECUTABLE_PREFIX = lib; + HEADER_SEARCH_PATHS = /System/Library/Frameworks/System.framework/PrivateHeaders; + PRODUCT_NAME = disk; + SKIP_INSTALL = YES; + }; + name = Release; + }; + 4D55931D153CE199009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + HEADER_SEARCH_PATHS = /System/Library/Frameworks/System.framework/PrivateHeaders; + INSTALL_PATH = /usr/sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559349153CE41E009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + SYSTEM_FRAMEWORK_SEARCH_PATHS = "$(inherited) $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks"; + }; + name = Release; + }; + 4D559351153CE4CC009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559368153CE561009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + CODE_SIGN_ENTITLEMENTS = mount.tproj/mount.entitlements; + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + SYSTEM_FRAMEWORK_SEARCH_PATHS = "$(inherited) $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/Frameworks"; + }; + name = Release; + }; + 4D559396153CE7FE009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + SYSTEM_FRAMEWORK_SEARCH_PATHS = "$(inherited) $(SDKROOT)$(SYSTEM_LIBRARY_DIR)/PrivateFrameworks"; + }; + name = Release; + }; + 4D5593AE153CEA90009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /usr/sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D5593C1153CEB7E009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_MODE_FLAG = 04555; + INSTALL_PATH = /usr/bin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D5593D5153CED29009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D5593EC153CEE4A009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /usr/sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559400153DC0DE009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /usr/sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559413153DC27A009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /usr/libexec; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559424153DC384009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559438153DC49A009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559442153DC57D009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + OTHER_CFLAGS = ""; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559445153DC587009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559456153DC634009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /usr/sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D55946C153DC808009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /usr/sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D55947F153DC8FC009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559492153DC98D009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D5594A5153DC9FB009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D5594B7153DCA53009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /sbin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D5594CA153DCAFC009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D5594DD153DCC66009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + INSTALL_PATH = /usr/bin; + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; + 4D559516153DE116009F2584 /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + PRODUCT_NAME = "$(TARGET_NAME)"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 4D07DD2E153CA616002B57CB /* Build configuration list for PBXProject "diskdev_cmds" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D07DD3D153CA616002B57CB /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D07DD4A153CA9A0002B57CB /* Build configuration list for PBXNativeTarget "libdisk" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D07DD4B153CA9A0002B57CB /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D55931C153CE199009F2584 /* Build configuration list for PBXNativeTarget "fdisk" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D55931D153CE199009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559348153CE41E009F2584 /* Build configuration list for PBXNativeTarget "fsck" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559349153CE41E009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559350153CE4CC009F2584 /* Build configuration list for PBXAggregateTarget "Common" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559351153CE4CC009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559367153CE561009F2584 /* Build configuration list for PBXNativeTarget "mount" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559368153CE561009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559395153CE7FE009F2584 /* Build configuration list for PBXNativeTarget "umount" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559396153CE7FE009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5593AD153CEA90009F2584 /* Build configuration list for PBXNativeTarget "edquota" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5593AE153CEA90009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5593C0153CEB7E009F2584 /* Build configuration list for PBXNativeTarget "quota" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5593C1153CEB7E009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5593D4153CED29009F2584 /* Build configuration list for PBXNativeTarget "quotacheck" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5593D5153CED29009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5593EB153CEE4A009F2584 /* Build configuration list for PBXNativeTarget "quotaon" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5593EC153CEE4A009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5593FF153DC0DE009F2584 /* Build configuration list for PBXNativeTarget "repquota" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559400153DC0DE009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559412153DC27A009F2584 /* Build configuration list for PBXNativeTarget "vndevice" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559413153DC27A009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559423153DC384009F2584 /* Build configuration list for PBXNativeTarget "mount_devfs" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559424153DC384009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559437153DC49A009F2584 /* Build configuration list for PBXNativeTarget "mount_fdesc" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559438153DC49A009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559441153DC57D009F2584 /* Build configuration list for PBXAggregateTarget "All_MacOSX" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559442153DC57D009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559444153DC587009F2584 /* Build configuration list for PBXAggregateTarget "All_iOS" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559445153DC587009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559455153DC634009F2584 /* Build configuration list for PBXNativeTarget "vsdbutil" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559456153DC634009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D55946B153DC808009F2584 /* Build configuration list for PBXNativeTarget "dev_mkdb" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D55946C153DC808009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D55947E153DC8FC009F2584 /* Build configuration list for PBXNativeTarget "fstyp" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D55947F153DC8FC009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559491153DC98D009F2584 /* Build configuration list for PBXNativeTarget "fstyp_msdos" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559492153DC98D009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5594A4153DC9FB009F2584 /* Build configuration list for PBXNativeTarget "fstyp_ntfs" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5594A5153DC9FB009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5594B6153DCA53009F2584 /* Build configuration list for PBXNativeTarget "fstyp_udf" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5594B7153DCA53009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5594C9153DCAFC009F2584 /* Build configuration list for PBXNativeTarget "setclass" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5594CA153DCAFC009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D5594DC153DCC66009F2584 /* Build configuration list for PBXNativeTarget "fuser" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D5594DD153DCC66009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 4D559515153DE116009F2584 /* Build configuration list for PBXAggregateTarget "quotaoff" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 4D559516153DE116009F2584 /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 4D07DD2B153CA616002B57CB /* Project object */; +} diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..e0c148d --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings b/diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings new file mode 100644 index 0000000..08de0be --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings @@ -0,0 +1,8 @@ + + + + + IDEWorkspaceSharedSettings_AutocreateContextsIfNeeded + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_MacOSX.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_MacOSX.xcscheme new file mode 100644 index 0000000..844c24e --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_MacOSX.xcscheme @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_iOS.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_iOS.xcscheme new file mode 100644 index 0000000..1b41173 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/All_iOS.xcscheme @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/Common.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/Common.xcscheme new file mode 100644 index 0000000..d077a0a --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/Common.xcscheme @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/dev_mkdb.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/dev_mkdb.xcscheme new file mode 100644 index 0000000..da3f116 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/dev_mkdb.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/edquota.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/edquota.xcscheme new file mode 100644 index 0000000..aac4a1c --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/edquota.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fdisk.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fdisk.xcscheme new file mode 100644 index 0000000..23af6d2 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fdisk.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fsck.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fsck.xcscheme new file mode 100644 index 0000000..5405e97 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fsck.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp.xcscheme new file mode 100644 index 0000000..7e5ae37 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_msdos.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_msdos.xcscheme new file mode 100644 index 0000000..7135b78 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_msdos.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_ntfs.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_ntfs.xcscheme new file mode 100644 index 0000000..144c15c --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_ntfs.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_udf.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_udf.xcscheme new file mode 100644 index 0000000..8cb1245 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fstyp_udf.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fuser.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fuser.xcscheme new file mode 100644 index 0000000..db85539 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/fuser.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/libdisk.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/libdisk.xcscheme new file mode 100644 index 0000000..0f60716 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/libdisk.xcscheme @@ -0,0 +1,61 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount.xcscheme new file mode 100644 index 0000000..6a53cec --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_devfs.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_devfs.xcscheme new file mode 100644 index 0000000..246cbba --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_devfs.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_fdesc.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_fdesc.xcscheme new file mode 100644 index 0000000..dad5f9a --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/mount_fdesc.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quota.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quota.xcscheme new file mode 100644 index 0000000..df303b9 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quota.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotacheck.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotacheck.xcscheme new file mode 100644 index 0000000..48bf0e6 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotacheck.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotaon.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotaon.xcscheme new file mode 100644 index 0000000..1a5fcda --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/quotaon.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/repquota.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/repquota.xcscheme new file mode 100644 index 0000000..75149cf --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/repquota.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/setclass.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/setclass.xcscheme new file mode 100644 index 0000000..b249cf1 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/setclass.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/umount.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/umount.xcscheme new file mode 100644 index 0000000..51ffb5d --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/umount.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vndevice.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vndevice.xcscheme new file mode 100644 index 0000000..5bb5059 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vndevice.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vsdbutil.xcscheme b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vsdbutil.xcscheme new file mode 100644 index 0000000..6e7d1c4 --- /dev/null +++ b/diskdev_cmds/diskdev_cmds.xcodeproj/xcshareddata/xcschemes/vsdbutil.xcscheme @@ -0,0 +1,88 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/diskdev_cmds/disklib/dkcksum.c b/diskdev_cmds/disklib/dkcksum.c new file mode 100644 index 0000000..e275cb2 --- /dev/null +++ b/diskdev_cmds/disklib/dkcksum.c @@ -0,0 +1,77 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/*- + * Copyright (c) 1991, 1993 + * The Regents of the University of California. 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. + */ + + +#include + +#if defined (linux) && defined (__powerpc__) +#define __ppc__ +#endif + +#include + +u_short +dkcksum(lp) + register struct disklabel *lp; +{ + register u_short *start, *end; + register u_short sum = 0; + + start = (u_short *)lp; + end = (u_short *)&lp->d_partitions[lp->d_npartitions]; + while (start < end) + sum ^= *start++; + return (sum); +} diff --git a/diskdev_cmds/disklib/dkdisklabel.c b/diskdev_cmds/disklib/dkdisklabel.c new file mode 100644 index 0000000..3fffce5 --- /dev/null +++ b/diskdev_cmds/disklib/dkdisklabel.c @@ -0,0 +1,193 @@ +/* Copyright 1999 Apple Computer, Inc. + * + * Generate a bsd disk label routine. + * Input: open file descriptor to the device node, and + * pointer to a disk label structure to fill in + * Return: errno status + * + * HISTORY + * + * 24 Feb 1999 D. Markarian at Apple + * Created. + */ + +#include /* memset */ +#include /* sys/disklabel.h */ +#include /* NBPG */ + +#include /* DKIOCGETBLOCKSIZE ioctl */ + +#include /* struct disklabel */ + +u_short dkcksum __P((register struct disklabel *lp)); +int dkdisklabelregenerate __P((int fd, struct disklabel * lp, int newblksize)); + +/* + * The following two constants set the default block and fragment sizes. + * Both constants must be a power of 2 and meet the following constraints: + * MINBSIZE <= GENBLKSIZE <= MAXBSIZE + * sectorsize <= GENFRAGSIZE <= GENBLKSIZE + * GENBLKSIZE / GENFRAGSIZE <= 8 + */ +#define GENFRAGSIZE 1024 +#define GENBLKSIZE NBPG /* 4096 */ + +/* + * Cylinder groups may have up to many cylinders. The actual + * number used depends upon how much information can be stored + * on a single cylinder. The default is to use 16 cylinders + * per group. + */ +#define GENCPG 16 + +/* + * Interleave is physical sector interleave, set up by the + * formatter or controller when formatting. When interleaving is + * in use, logically adjacent sectors are not physically + * contiguous, but instead are separated by some number of + * sectors. It is specified as the ratio of physical sectors + * traversed per logical sector. Thus an interleave of 1:1 + * implies contiguous layout, while 2:1 implies that logical + * sector 0 is separated by one sector from logical sector 1. + */ +#define GENINTERLEAVE 1 + +/* + * Rotational speed; # of data sectors per track. + */ +#define GENRPM 3600 +#define GENNSECTORS 32 + +int dkdisklabel(int fd, struct disklabel * lp) +{ + return dkdisklabelregenerate(fd, lp, 0); +} + +int dkdisklabelregenerate(int fd, struct disklabel * lp, int newblksize) +{ + /* + * Generate a bsd-style disk label for the specified device node. + */ + + int blksize; + int error; + int index; + int64_t numblks; + + /* obtain the size of the media (in blocks) */ + if ( (error = ioctl(fd, DKIOCGETBLOCKCOUNT, &numblks)) < 0 ) + return(error); + + /* obtain the block size of the media */ + if ( (error = ioctl(fd, DKIOCGETBLOCKSIZE, &blksize)) < 0 ) + return(error); + + /* adjust the size of the media with newblksize should it be specified */ + if (newblksize) + { + numblks = ((numblks * blksize) / newblksize); + blksize = newblksize; + } + + /* + * clear the disk label structure and then fill in the appropriate fields; + * we comment out lines that are initializations to zero with //, since it + * is redundant work + */ + memset(lp, 0, sizeof(struct disklabel)); + + lp->d_magic = DISKMAGIC; /* the magic number */ +// lp->d_type = 0; /* drive type */ +// lp->d_subtype = 0; /* controller/d_type specific */ +// lp->d_typename[0] = 0; /* type name, e.g. "eagle" */ + /* + * d_packname contains the pack identifier and is returned when + * the disklabel is read off the disk or in-core copy. + * d_boot0 and d_boot1 are the (optional) names of the + * primary (block 0) and secondary (block 1-15) bootstraps + * as found in /usr/mdec. These are returned when using + * getdiskbyname(3) to retrieve the values from /etc/disktab. + */ +// lp->d_packname[0] = 0; /* pack identifier */ + + /* disk geometry: */ + lp->d_secsize = blksize; /* # of bytes per sector */ + lp->d_nsectors = GENNSECTORS; /* # of data sectors per track */ + /* # of tracks per cylinder */ + if (numblks < 8*32*1024) /* <=528.4 MB */ + lp->d_ntracks = 16; + else if (numblks < 16*32*1024) /* <=1.057 GB */ + lp->d_ntracks = 32; + else if (numblks < 32*32*1024) /* <=2.114 GB */ + lp->d_ntracks = 54; + else if (numblks < 64*32*1024) /* <=4.228 GB */ + lp->d_ntracks = 128; + else /* > 4.228 GB */ + lp->d_ntracks = 255; + /* # of data cylinders per unit */ + lp->d_ncylinders = numblks / lp->d_ntracks / lp->d_nsectors; + /* # of data sectors per cylinder */ + lp->d_secpercyl = lp->d_nsectors * lp->d_ntracks; + lp->d_secperunit = numblks; /* # of data sectors per unit */ + /* + * Spares (bad sector replacements) below are not counted in + * d_nsectors or d_secpercyl. Spare sectors are assumed to + * be physical sectors which occupy space at the end of each + * track and/or cylinder. + */ +// lp->d_sparespertrack = 0; /* # of spare sectors per track */ +// lp->d_sparespercyl = 0; /* # of data sectors per unit */ + /* + * Alternate cylinders include maintenance, replacement, configuration + * description areas, etc. + */ +// lp->d_acylinders = 0; /* # of alt. cylinders per unit */ + + /* hardware characteristics: */ + /* + * d_interleave, d_trackskew and d_cylskew describe perturbations + * in the media format used to compensate for a slow controller. + * Interleave is physical sector interleave, set up by the + * formatter or controller when formatting. When interleaving is + * in use, logically adjacent sectors are not physically + * contiguous, but instead are separated by some number of + * sectors. It is specified as the ratio of physical sectors + * traversed per logical sector. Thus an interleave of 1:1 + * implies contiguous layout, while 2:1 implies that logical + * sector 0 is separated by one sector from logical sector 1. + * d_trackskew is the offset of sector 0 on track N relative to + * sector 0 on track N-1 on the same cylinder. Finally, d_cylskew + * is the offset of sector 0 on cylinder N relative to sector 0 + * on cylinder N-1. + */ + lp->d_rpm = GENRPM; /* rotational speed */ + lp->d_interleave = GENINTERLEAVE; /* hardware sector interleave */ +// lp->d_trackskew = 0; /* sector 0 skew, per track */ +// lp->d_cylskew = 0; /* sector 0 skew, per cylinder */ +// lp->d_headswitch = 0; /* head switch time, usec */ +// lp->d_trkseek = 0; /* track-to-track seek, usec */ +// lp->d_flags = 0; /* generic flags */ +// lp->d_drivedata[0-4] = 0; /* drive-type specific information */ +// lp->d_spare[0-4] = 0; /* reserved for future use */ + lp->d_magic2 = DISKMAGIC; /* the magic number (again) */ +// lp->d_checksum = 0; /* xor of data incl. partitions */ + + /* filesystem and partition information: */ + lp->d_npartitions = MAXPARTITIONS; /* number of partitions */ + + for (index = 0; index < MAXPARTITIONS; index++) + { + struct partition * pp = &(lp->d_partitions[index]); + pp->p_size = numblks; /* number of sectors */ +// pp->p_offset = 0; /* starting sector */ + pp->p_fsize = MAX(GENFRAGSIZE, blksize); /* fs fragment size */ + pp->p_fstype = FS_BSDFFS; /* fs type */ + pp->p_frag = MIN(8, GENBLKSIZE / pp->p_fsize);/* fs fragments/block */ + pp->p_cpg = GENCPG; /* fs cylinders/group */ + } + + /* compute a checksum on the resulting structure */ + lp->d_checksum = dkcksum(lp); + + return 0; /* success */ +} diff --git a/diskdev_cmds/disklib/dkopen.c b/diskdev_cmds/disklib/dkopen.c new file mode 100644 index 0000000..7a94561 --- /dev/null +++ b/diskdev_cmds/disklib/dkopen.c @@ -0,0 +1,57 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ + +#include "dkopen.h" + +#include +#include +#include +#include + +int dkopen (const char *path, int flags, int mode) +{ +#if defined (linux) + return (open64 (path, flags, mode)); +#elif defined (__APPLE__) + return (open (path, flags, mode)); +#endif +} + +int dkclose (int filedes) +{ +#if defined (linux) + return (close (filedes)); +#elif defined (__APPLE__) + return (close (filedes)); +#endif +} + +off64_t dklseek (int filedes, off64_t offset, int whence) +{ +#if defined (linux) + return (lseek64 (filedes, offset, whence)); +#elif defined (__APPLE__) + return (lseek (filedes, offset, whence)); +#endif +} + diff --git a/diskdev_cmds/disklib/dkopen.h b/diskdev_cmds/disklib/dkopen.h new file mode 100644 index 0000000..eb0bdeb --- /dev/null +++ b/diskdev_cmds/disklib/dkopen.h @@ -0,0 +1,56 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ + +/* + * File I/O stubs + * + * Linux and other OSs may use open64, lseek64 instead of defaulting off_t to + * 64-bits like OSX does. This file provides cover functions to always perform + * 64-bit file I/O. + */ + +#ifndef _DKOPEN_H_ +#define _DKOPEN_H_ + +/* Must predefine the large file flags before including sys/types.h */ +#if defined (linux) +#define _LARGEFILE_SOURCE +#define _LARGEFILE64_SOURCE +#elif defined (__APPLE__) +#else +#error Platform not recognized +#endif + +#include + +/* Typedef off64_t for platforms that don't have it declared */ +#if defined (__APPLE__) && !defined (linux) +typedef u_int64_t off64_t; +#endif + +int dkopen (const char *path, int flags, int mode); +int dkclose (int filedes); + +off64_t dklseek (int fileds, off64_t offset, int whence); + +#endif diff --git a/diskdev_cmds/disklib/dksecsize.c b/diskdev_cmds/disklib/dksecsize.c new file mode 100644 index 0000000..0cfad82 --- /dev/null +++ b/diskdev_cmds/disklib/dksecsize.c @@ -0,0 +1,75 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/* Copyright 1998 Apple Computer, Inc. + * + * Get disk label's sector size routine. + * Input: pointer to a block device string ie: "/dev/disk1s1" + * Return: sector size from the disk label + * + * HISTORY + * + * 27 May 1998 K. Crippes at Apple + * Rhapsody version created. + * 18 Feb 1999 D. Markarian at Apple + * DKIOCGLABEL deprecated; using DKIOCBLKSIZE instead, which now returns + * the appropriate size for ufs partitions created with wierd block sizes. + */ + +#include +#include +#include +#include +#include +#include +#include + +char *blockcheck __P((char *)); + +long dksecsize (dev) + char *dev; +{ + int fd; /* file descriptor for reading device label */ + char *cdev; + int devblklen; + extern int errno; + + /* Convert block device into a character device string */ + if ((cdev = blockcheck(dev))) { + if ((fd = open(cdev, O_RDONLY)) < 0) { + fprintf(stderr, "Can't open %s, %s\n", cdev, strerror(errno)); + return (0); + } + } + else + return (0); + + if (ioctl(fd, DKIOCGETBLOCKSIZE, &devblklen) < 0) { + (void)close(fd); + return (0); + } + else { + (void)close(fd); + return (devblklen); + } +} + diff --git a/diskdev_cmds/disklib/pathnames.h b/diskdev_cmds/disklib/pathnames.h new file mode 100644 index 0000000..59cd945 --- /dev/null +++ b/diskdev_cmds/disklib/pathnames.h @@ -0,0 +1,63 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/* + * Copyright (c) 1989, 1993 + * The Regents of the University of California. 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. + * + * @(#)pathnames.h 8.1 (Berkeley) 6/5/93 + */ + +#include + +#define _PATH_DTMP "/etc/dtmp" +#define _PATH_DUMPDATES "/etc/dumpdates" +#define _PATH_LOCK "/tmp/dumplockXXXXXX" +#define _PATH_RMT "rmt" diff --git a/diskdev_cmds/disklib/preen.c b/diskdev_cmds/disklib/preen.c new file mode 100644 index 0000000..f7128e0 --- /dev/null +++ b/diskdev_cmds/disklib/preen.c @@ -0,0 +1,392 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/* + * Copyright (c) 1990, 1993 + * The Regents of the University of California. 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. + */ + +#include +#include +#include + +#include +#include +#include + +#include +#include +#include +#include + +#if TARGET_OS_OSX +struct part { + struct part *next; /* forward link of partitions on disk */ + char *name; /* device name */ + char *fsname; /* mounted filesystem name */ + long auxdata; /* auxillary data for application */ +} *badlist, **badnext = &badlist; + +struct disk { + char *name; /* disk base name */ + struct disk *next; /* forward link for list of disks */ + struct part *part; /* head of list of partitions on disk */ + int pid; /* If != 0, pid of proc working on */ +} *disks; + +int nrun, ndisks; +char hotroot; + +static void addpart (char *name, char *fsname, long auxdata); +static struct disk *finddisk (char *name); +static char *rawname (char *name); +static int startdisk (struct disk *dk, + int (*checkit)(char *, char *, long, int)); +static char *unrawname (char *name); +char* blockcheck (char *name); + +int +checkfstab(preen, maxrun, docheck, chkit) + int preen; + int maxrun; + int (*docheck)(struct fstab *); + int (*chkit)(char *, char *, long, int); +{ + register struct fstab *fsp; + register struct disk *dk, *nextdisk; + register struct part *pt; + int ret, pid, retcode, passno, sumstatus, status; + long auxdata; + char *name; + + sumstatus = 0; + for (passno = 1; passno <= 2; passno++) { + if (setfsent() == 0) { + fprintf(stderr, "Can't open checklist file: %s\n", + _PATH_FSTAB); + return (8); + } + while ((fsp = getfsent()) != 0) { + if ((auxdata = (*docheck)(fsp)) == 0) + continue; + if (preen == 0 || + (passno == 1 && fsp->fs_passno == 1)) { + if ((name = blockcheck(fsp->fs_spec)) != 0) { + if ((sumstatus = (*chkit)(name, + fsp->fs_file, auxdata, 0)) != 0) + return (sumstatus); + } else if (preen) + return (8); + } else if (passno == 2 && fsp->fs_passno > 1) { + if ((name = blockcheck(fsp->fs_spec)) == NULL) { + fprintf(stderr, "BAD DISK NAME %s\n", + fsp->fs_spec); + sumstatus |= 8; + continue; + } + addpart(name, fsp->fs_file, auxdata); + } + } + if (preen == 0) + return (0); + } + if (preen) { + if (maxrun == 0) + maxrun = ndisks; + if (maxrun > ndisks) + maxrun = ndisks; + nextdisk = disks; + for (passno = 0; passno < maxrun; ++passno) { + while ((ret = startdisk(nextdisk, chkit)) && nrun > 0) + sleep(10); + if (ret) + return (ret); + nextdisk = nextdisk->next; + } + while ((pid = wait(&status)) != -1) { + for (dk = disks; dk; dk = dk->next) + if (dk->pid == pid) + break; + if (dk == 0) { + printf("Unknown pid %d\n", pid); + continue; + } + if (WIFEXITED(status)) + retcode = WEXITSTATUS(status); + else + retcode = 0; + if (WIFSIGNALED(status)) { + printf("%s (%s): EXITED WITH SIGNAL %d\n", + dk->part->name, dk->part->fsname, + WTERMSIG(status)); + retcode = 8; + } + if (retcode != 0) { + sumstatus |= retcode; + *badnext = dk->part; + badnext = &dk->part->next; + dk->part = dk->part->next; + *badnext = NULL; + } else + dk->part = dk->part->next; + dk->pid = 0; + nrun--; + if (dk->part == NULL) + ndisks--; + + if (nextdisk == NULL) { + if (dk->part) { + while ((ret = startdisk(dk, chkit)) && + nrun > 0) + sleep(10); + if (ret) + return (ret); + } + } else if (nrun < maxrun && nrun < ndisks) { + for ( ;; ) { + if ((nextdisk = nextdisk->next) == NULL) + nextdisk = disks; + if (nextdisk->part != NULL && + nextdisk->pid == 0) + break; + } + while ((ret = startdisk(nextdisk, chkit)) && + nrun > 0) + sleep(10); + if (ret) + return (ret); + } + } + } + if (sumstatus) { + if (badlist == 0) + return (sumstatus); + fprintf(stderr, "THE FOLLOWING FILE SYSTEM%s HAD AN %s\n\t", + badlist->next ? "S" : "", "UNEXPECTED INCONSISTENCY:"); + for (pt = badlist; pt; pt = pt->next) + fprintf(stderr, "%s (%s)%s", pt->name, pt->fsname, + pt->next ? ", " : "\n"); + return (sumstatus); + } + (void)endfsent(); + return (0); +} + +static struct disk * +finddisk(name) + char *name; +{ + register struct disk *dk, **dkp; + register char *p; + size_t len; + + for (len = strlen(name), p = name + len - 1; p >= name; --p) + if (isdigit(*p)) { + len = p - name + 1; + break; + } + + for (dk = disks, dkp = &disks; dk; dkp = &dk->next, dk = dk->next) { + if (strncmp(dk->name, name, len) == 0 && + dk->name[len] == 0) + return (dk); + } + if ((*dkp = (struct disk *)malloc(sizeof(struct disk))) == NULL) { + fprintf(stderr, "out of memory"); + exit (8); + } + dk = *dkp; + if ((dk->name = malloc(len + 1)) == NULL) { + fprintf(stderr, "out of memory"); + exit (8); + } + (void)strncpy(dk->name, name, len); + dk->name[len] = '\0'; + dk->part = NULL; + dk->next = NULL; + dk->pid = 0; + ndisks++; + return (dk); +} + +static void +addpart(name, fsname, auxdata) + char *name, *fsname; + long auxdata; +{ + struct disk *dk = finddisk(name); + register struct part *pt, **ppt = &dk->part; + + for (pt = dk->part; pt; ppt = &pt->next, pt = pt->next) + if (strcmp(pt->name, name) == 0) { + printf("%s in fstab more than once!\n", name); + return; + } + if ((*ppt = (struct part *)malloc(sizeof(struct part))) == NULL) { + fprintf(stderr, "out of memory"); + exit (8); + } + pt = *ppt; + if ((pt->name = strdup(name)) == NULL) { + fprintf(stderr, "out of memory"); + exit (8); + } + if ((pt->fsname = strdup(fsname)) == NULL) { + fprintf(stderr, "out of memory"); + exit (8); + } + pt->next = NULL; + pt->auxdata = auxdata; +} + +static int +startdisk(dk, checkit) + register struct disk *dk; + int (*checkit)(char *, char *, long, int); +{ + register struct part *pt = dk->part; + + dk->pid = fork(); + if (dk->pid < 0) { + perror("fork"); + return (8); + } + if (dk->pid == 0) + exit((*checkit)(pt->name, pt->fsname, pt->auxdata, 1)); + nrun++; + return (0); +} + +char * +blockcheck(char* origname) { + struct stat stslash, stblock, stchar; + char *newname, *raw; + int retried = 0; + + hotroot = 0; + if (stat("/", &stslash) < 0) { + perror("/"); + printf("Can't stat root\n"); + return (origname); + } + newname = origname; +retry: + if (stat(newname, &stblock) < 0) { + perror(newname); + printf("Can't stat %s\n", newname); + return (origname); + } + if ((stblock.st_mode & S_IFMT) == S_IFBLK) { + if (stslash.st_dev == stblock.st_rdev) + hotroot++; + raw = rawname(newname); + if (stat(raw, &stchar) < 0) { + perror(raw); + printf("Can't stat %s\n", raw); + return (origname); + } + if ((stchar.st_mode & S_IFMT) == S_IFCHR) { + return (raw); + } else { + printf("%s is not a character device\n", raw); + return (origname); + } + } else if ((stblock.st_mode & S_IFMT) == S_IFCHR && !retried) { + newname = unrawname(newname); + retried++; + goto retry; + } + /* + * Not a block or character device, just return name and + * let the user decide whether to use it. + */ + return (origname); +} + +static char * +unrawname(name) + char *name; +{ + char *dp; + struct stat stb; + size_t dp_len; + + if ((dp = strrchr(name, '/')) == 0) + return (name); + if (stat(name, &stb) < 0) + return (name); + if ((stb.st_mode & S_IFMT) != S_IFCHR) + return (name); + if (dp[1] != 'r') + return (name); + dp_len = strlen(&dp[2]) + 1; + (void)memmove(&dp[1], &dp[2], dp_len); + return (name); +} + +static char * +rawname(name) + char *name; +{ + static char rawbuf[32]; + char *dp; + + if ((dp = strrchr(name, '/')) == 0) + return (0); + *dp = 0; + (void)strncpy(rawbuf, name, sizeof(rawbuf)); + *dp = '/'; + (void)strlcat(rawbuf, "/r", sizeof(rawbuf)); + (void)strlcat(rawbuf, &dp[1], sizeof(rawbuf)); + return (rawbuf); +} + +#endif /* TARGET_OS_OSX */ + diff --git a/diskdev_cmds/disklib/vfslist.c b/diskdev_cmds/disklib/vfslist.c new file mode 100644 index 0000000..6ecafcd --- /dev/null +++ b/diskdev_cmds/disklib/vfslist.c @@ -0,0 +1,112 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/*- + * Copyright (c) 1995 + * The Regents of the University of California. 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. + */ + + +#include +#include +#include +#include + +int checkvfsname __P((const char *, const char **)); +const char **makevfslist __P((char *)); +static int skipvfs; + +int +checkvfsname(vfsname, vfslist) + const char *vfsname; + const char **vfslist; +{ + + if (vfslist == NULL) + return (0); + while (*vfslist != NULL) { + if (strcmp(vfsname, *vfslist) == 0) + return (skipvfs); + ++vfslist; + } + return (!skipvfs); +} + +const char ** +makevfslist(fslist) + char *fslist; +{ + const char **av; + int i; + char *nextcp; + + if (fslist == NULL) + return (NULL); + if (fslist[0] == 'n' && fslist[1] == 'o') { + fslist += 2; + skipvfs = 1; + } + for (i = 0, nextcp = fslist; *nextcp; nextcp++) + if (*nextcp == ',') + i++; + if ((av = malloc((size_t)(i + 2) * sizeof(char *))) == NULL) { + warn(NULL); + return (NULL); + } + nextcp = fslist; + i = 0; + av[i++] = nextcp; + while ((nextcp = strchr(nextcp, ',')) != NULL) { + *nextcp++ = '\0'; + av[i++] = nextcp; + } + av[i++] = NULL; + return (av); +} diff --git a/diskdev_cmds/edquota.tproj/edquota.8 b/diskdev_cmds/edquota.tproj/edquota.8 new file mode 100644 index 0000000..fd52b56 --- /dev/null +++ b/diskdev_cmds/edquota.tproj/edquota.8 @@ -0,0 +1,184 @@ +.\" Copyright (c) 1983, 1990, 1993, 2002 +.\" The Regents of the University of California. All rights reserved. +.\" +.\" This code is derived from software contributed to Berkeley by +.\" Robert Elz at The University of Melbourne. +.\" +.\" 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. +.\" 3. All advertising materials mentioning features or use of this software +.\" must display the following acknowledgement: +.\" This product includes software developed by the University of +.\" California, Berkeley and its contributors. +.\" 4. Neither the name of the University nor the names of its contributors +.\" may be used to endorse or promote products derived from this software +.\" without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. +.\" +.\" @(#)edquota.8 8.2 (Berkeley) 4/27/95 +.\" +.Dd "March 28, 2002" +.Dt EDQUOTA 8 +.Os +.Sh NAME +.Nm edquota +.Nd edit user quotas +.Sh SYNOPSIS +.Nm edquota +.Op Fl u +.Op Fl p Ar proto-username +.Ar username ... +.Nm edquota +.Fl g +.Op Fl p Ar proto-groupname +.Ar groupname ... +.Nm edquota +.Fl t +.Op Fl u +.Nm edquota +.Fl t +.Fl g +.Sh DESCRIPTION +.Nm Edquota +is a quota editor. +By default, or if the +.Fl u +flag is specified, +one or more users may be specified on the command line. +For each user a temporary file is created +with an ASCII representation of the current +disk quotas for that user. +The list of filesystems with user quotas is determined by +scanning the mounted filesystems for a +.Pa .quota.ops.user +file located at its root. +An editor is invoked on the ASCII file. +The editor invoked is +.Xr vi 1 +unless the environment variable +.Ev EDITOR +specifies otherwise. +.Pp +The quotas may then be modified, new quotas added, etc. +Setting a quota to zero indicates that no quota should be imposed. +Setting a hard limit to one indicates that no allocations should +be permitted. +Setting a soft limit to one with a hard limit of zero +indicates that allocations should be permitted on +only a temporary basis (see +.Fl t +below). +The current usage information in the file is for informational purposes; +only the hard and soft limits can be changed. +.Pp +On leaving the editor, +.Nm edquota +reads the temporary file and modifies the binary +quota files to reflect the changes made. +The binary quota file, +.Pa .quota.user +is stored at the root of the filesystem. +The default filename and root location for the user +quotas cannot be overridden. +.Pp +If the +.Fl p +flag is specified, +.Nm edquota +will duplicate the quotas of the prototypical user +specified for each user specified. +This is the normal mechanism used to +initialize quotas for groups of users. +.Pp +If the +.Fl g +flag is specified, +.Nm edquota +is invoked to edit the quotas of +one or more groups specified on the command line. +The list of filesystems with group quotas is determined by +scanning the mounted filesystems for a +.Pa .quota.ops.group +file located at its root. +Similarly, the binary quota file, +.Pa .quota.group +is stored at the root of the filesystem. +The default filename and root location for group +quotas cannot be overridden. +The +.Fl p +flag can be specified in conjunction with +the +.Fl g +flag to specify a prototypical group +to be duplicated among the listed set of groups. +.Pp +Users are permitted to exceed their soft limits +for a grace period that may be specified per filesystem. +Once the grace period has expired, +the soft limit is enforced as a hard limit. +The default grace period for a filesystem is specified in +.Pa /usr/include/sys/quota.h . +The +.Fl t +flag can be used to change the grace period. +By default, or when invoked with the +.Fl u +flag, the grace period is set for each filesystem with a +.Pa .quota.ops.user +file located at its root. +When invoked with the +.Fl g +flag, the grace period is +set for each filesystem with a +.Pa .quota.ops.group +file located at its root. +The grace period may be specified in days, hours, minutes, or seconds. +Setting a grace period to zero indicates that the default +grace period should be imposed. +Setting a grace period to one second indicates that no +grace period should be granted. +.Pp +Only the super-user may edit quotas. +.Sh FILES +Each of the following quota files is located at the root of the +mounted filesystem. The mount option files are empty files +whose existence indicates that quotas are to be enabled +for that filesystem. The binary data files will be +created by edquota, if they don't already exist. +.Pp +.Bl -tag -width .quota.ops.group -compact +.It Pa .quota.user +data file containing user quotas +.It Pa .quota.group +data file containing group quotas +.It Pa .quota.ops.user +mount option file used to enable user quotas +.It Pa .quota.ops.group +mount option file used to enable group quotas +.El +.Sh SEE ALSO +.Xr quota 1 , +.Xr quotactl 2 , +.Xr quotacheck 8 , +.Xr quotaon 8 , +.Xr repquota 8 +.Sh DIAGNOSTICS +Various messages about inaccessible files; self-explanatory. diff --git a/diskdev_cmds/edquota.tproj/edquota.c b/diskdev_cmds/edquota.tproj/edquota.c new file mode 100644 index 0000000..6dad1cb --- /dev/null +++ b/diskdev_cmds/edquota.tproj/edquota.c @@ -0,0 +1,1228 @@ +/* + * Copyright (c) 2002-2005 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/* + * Copyright (c) 1980, 1990, 1993 + * The Regents of the University of California. All rights reserved. + * + * This code is derived from software contributed to Berkeley by + * Robert Elz at The University of Melbourne. + * + * 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. + */ + +#include + +#ifndef lint +__unused static char copyright[] = +"@(#) Copyright (c) 1980, 1990, 1993\n\ + The Regents of the University of California. All rights reserved.\n"; +#endif /* not lint */ + +#ifndef lint +__unused static char sccsid[] = "@(#)edquota.c 8.3 (Berkeley) 4/27/95"; +#endif /* not lint */ + +/* + * Disk quota editor. + */ +#include +#include +#include +#ifdef __APPLE__ +#include +#endif /* __APPLE__ */ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include "pathnames.h" + +#ifdef __APPLE__ +#include +#endif /* __APPLE__ */ + +char *qfname = QUOTAFILENAME; +char *qfextension[] = INITQFNAMES; +char *quotagroup = QUOTAGROUP; +char tmpfil[] = _PATH_TMP; + +#ifdef __APPLE__ +u_int32_t quotamagic[MAXQUOTAS] = INITQMAGICS; +#endif /* __APPLE__ */ + +struct quotause { + struct quotause *next; + long flags; + struct dqblk dqblk; + char fsname[MAXPATHLEN + 1]; + char qfname[1]; /* actually longer */ +} *getprivs(); +#define FOUND 0x01 + +int alldigits __P((char *)); +int cvtatos __P((time_t, char *, time_t *)); +int editit __P((char *)); +void freeprivs __P((struct quotause *)); +int getentry __P((char *, int)); +int hasquota __P((struct statfs *, int, char **)); +void putprivs __P((uid_t, int, struct quotause *)); +int readprivs __P((struct quotause *, int)); +int readtimes __P((struct quotause *, int)); +void usage __P((void)); +int writeprivs __P((struct quotause *, int, char *, int)); +int writetimes __P((struct quotause *, int, int)); + +#ifdef __APPLE__ +int qfinit(int, struct statfs *, int); +int qflookup(int, uid_t, int, struct dqblk *); +int qfupdate(int, uid_t, int, struct dqblk *); +#endif /* __APPLE__ */ + + +int +main(argc, argv) + register char **argv; + int argc; +{ + register struct quotause *qup, *protoprivs, *curprivs; + extern char *optarg; + extern int optind; + register uid_t id, protoid; + register int quotatype, tmpfd; + char *protoname = NULL, ch; + int tflag = 0, pflag = 0; + + if (argc < 2) + usage(); + if (getuid()) { + fprintf(stderr, "edquota: permission denied\n"); + exit(1); + } + quotatype = USRQUOTA; + + while ((ch = getopt(argc, argv, "ugtp:")) != EOF) { + switch(ch) { + case 'p': + protoname = optarg; + pflag++; + break; + case 'g': + quotatype = GRPQUOTA; + break; + case 'u': + quotatype = USRQUOTA; + break; + case 't': + tflag++; + break; + default: + usage(); + } + } + argc -= optind; + argv += optind; + if (pflag) { + if ((protoid = getentry(protoname, quotatype)) == -1) + exit(1); + protoprivs = getprivs(protoid, quotatype); +#ifdef __APPLE__ + if (protoprivs == (struct quotause *) NULL) + exit(0); +#endif /* __APPLE__ */ + for (qup = protoprivs; qup; qup = qup->next) { + qup->dqblk.dqb_btime = 0; + qup->dqblk.dqb_itime = 0; + } + while (argc-- > 0) { + if ((id = getentry(*argv++, quotatype)) == -1) + continue; + /* + * Set the ID in each disk quota block to match + * the ID it's supposed to go with. + */ + for (qup = protoprivs; qup; qup = qup->next) { + qup->dqblk.dqb_id = id; + } + putprivs(id, quotatype, protoprivs); + } + exit(0); + } + tmpfd = mkstemp(tmpfil); + fchown(tmpfd, getuid(), getgid()); + if (tflag) { + protoprivs = getprivs(0, quotatype); +#ifdef __APPLE__ + if (protoprivs == (struct quotause *) NULL) + exit(0); +#endif /* __APPLE__ */ + if (writetimes(protoprivs, tmpfd, quotatype) == 0) + exit(1); + if (editit(tmpfil)) { + /* + * Re-open tmpfil to be editor independent. + */ + close(tmpfd); + tmpfd = open(tmpfil, O_RDWR, 0); + if (tmpfd < 0) { + freeprivs(protoprivs); + unlink(tmpfil); + exit(1); + } + if (readtimes(protoprivs, tmpfd)) + putprivs(0, quotatype, protoprivs); + } + freeprivs(protoprivs); + exit(0); + } + for ( ; argc > 0; argc--, argv++) { + if ((id = getentry(*argv, quotatype)) == -1) + continue; + curprivs = getprivs(id, quotatype); +#ifdef __APPLE__ + if (curprivs == (struct quotause *) NULL) + exit(0); +#endif /* __APPLE__ */ + + + if (writeprivs(curprivs, tmpfd, *argv, quotatype) == 0) { + freeprivs(curprivs); + continue; + } + if (editit(tmpfil)) { + /* + * Re-open tmpfil to be editor independent. + */ + close(tmpfd); + tmpfd = open(tmpfil, O_RDWR, 0); + if (tmpfd < 0) { + freeprivs(curprivs); + unlink(tmpfil); + exit(1); + } + if (readprivs(curprivs, tmpfd)) + putprivs(id, quotatype, curprivs); + } + freeprivs(curprivs); + } + close(tmpfd); + unlink(tmpfil); + exit(0); +} + +void +usage() +{ + fprintf(stderr, "%s%s%s%s", + "Usage: edquota [-u] [-p username] username ...\n", + "\tedquota -g [-p groupname] groupname ...\n", + "\tedquota [-u] -t\n", "\tedquota -g -t\n"); +#ifdef __APPLE__ + fprintf(stderr, "\nQuota file editing triggers only on filesystems with a\n"); + fprintf(stderr, "%s.%s or %s.%s file located at its root.\n", + QUOTAOPSNAME, qfextension[USRQUOTA], + QUOTAOPSNAME, qfextension[GRPQUOTA]); +#endif /* __APPLE__ */ + exit(1); +} + +/* + * This routine converts a name for a particular quota type to + * an identifier. This routine must agree with the kernel routine + * getinoquota as to the interpretation of quota types. + */ +int +getentry(name, quotatype) + char *name; + int quotatype; +{ + struct passwd *pw; + struct group *gr; + + if (alldigits(name)) + return (atoi(name)); + switch(quotatype) { + case USRQUOTA: + if ((pw = getpwnam(name)) != NULL) + return (pw->pw_uid); + fprintf(stderr, "%s: no such user\n", name); + break; + case GRPQUOTA: + if ((gr = getgrnam(name))) + return (gr->gr_gid); + fprintf(stderr, "%s: no such group\n", name); + break; + default: + fprintf(stderr, "%d: unknown quota type\n", quotatype); + break; + } + sleep(1); + return (-1); +} + +/* + * Collect the requested quota information. + */ +#ifdef __APPLE__ +struct quotause * +getprivs(id, quotatype) + register uid_t id; + int quotatype; +{ + struct statfs *fst; + register struct quotause *qup, *quptail; + struct quotause *quphead; + int qcmd, fd; + size_t qupsize; + char *qfpathname; + size_t qfpathname_len; + static int warned = 0; + int nfst, i; + extern int errno; + + + quptail = quphead = (struct quotause *)0; + qcmd = QCMD(Q_GETQUOTA, quotatype); + + nfst = getmntinfo(&fst, MNT_WAIT); + if (nfst==0) { + fprintf(stderr, "edquota: no mounted filesystems\n"); + exit(1); + } + + for (i=0; idqblk) != 0) { + if (errno == ENOTSUP && !warned) { + warned++; + fprintf(stderr, "Warning: %s\n", + "Quotas are not compiled into this kernel"); + sleep(3); + } + if ((fd = open(qfpathname, O_RDONLY)) < 0) { + fd = open(qfpathname, O_RDWR|O_CREAT, 0640); + if (fd < 0 && errno != ENOENT) { + perror(qfpathname); + free(qup); + continue; + } + fprintf(stderr, "Creating quota file %s\n", + qfpathname); + sleep(3); + (void) fchown(fd, getuid(), + getentry(quotagroup, GRPQUOTA)); + (void) fchmod(fd, 0640); + if (qfinit(fd, &fst[i], quotatype)) { + perror(qfpathname); + close(fd); + free(qup); + continue; + } + } + if (qflookup(fd, id, quotatype, &qup->dqblk) != 0) { + fprintf(stderr, "edquota: lookup error in "); + perror(qfpathname); + close(fd); + free(qup); + continue; + } + close(fd); + } + strlcpy(qup->qfname, qfpathname, qfpathname_len); // malloc'd size is correct for this + strlcpy(qup->fsname, fst[i].f_mntonname, sizeof(qup->fsname)); + + if (quphead == NULL) + quphead = qup; + else + quptail->next = qup; + quptail = qup; + qup->next = 0; + } + return (quphead); +} +#else +struct quotause * +getprivs(id, quotatype) + register long id; + int quotatype; +{ + register struct fstab *fs; + register struct quotause *qup, *quptail; + struct quotause *quphead; + int qcmd, fd; + size_t qupsize; + char *qfpathname; + size_t qfpathname_len; + static int warned = 0; + extern int errno; + + setfsent(); + quphead = (struct quotause *)0; + qcmd = QCMD(Q_GETQUOTA, quotatype); + while (fs = getfsent()) { + if (!hasquota(fs, quotatype, &qfpathname)) + continue; + qfpathname_len = strlen(qfpathname); + qupsize = sizeof(*qup) + qfpathname_len; + if ((qup = (struct quotause *)malloc(qupsize)) == NULL) { + fprintf(stderr, "edquota: out of memory\n"); + exit(2); + } + if (quotactl(fs->fs_file, qcmd, id, &qup->dqblk) != 0) { + if (errno == ENOTSUP && !warned) { + warned++; + fprintf(stderr, "Warning: %s\n", + "Quotas are not compiled into this kernel"); + sleep(3); + } + if ((fd = open(qfpathname, O_RDONLY)) < 0) { + fd = open(qfpathname, O_RDWR|O_CREAT, 0640); + if (fd < 0 && errno != ENOENT) { + perror(qfpathname); + free(qup); + continue; + } + fprintf(stderr, "Creating quota file %s\n", + qfpathname); + sleep(3); + (void) fchown(fd, getuid(), + getentry(quotagroup, GRPQUOTA)); + (void) fchmod(fd, 0640); + } + lseek(fd, (off_t)(id * sizeof(struct dqblk)), L_SET); + switch (read(fd, &qup->dqblk, sizeof(struct dqblk))) { + case 0: /* EOF */ + /* + * Convert implicit 0 quota (EOF) + * into an explicit one (zero'ed dqblk) + */ + bzero((caddr_t)&qup->dqblk, + sizeof(struct dqblk)); + break; + + case sizeof(struct dqblk): /* OK */ + break; + + default: /* ERROR */ + fprintf(stderr, "edquota: read error in "); + perror(qfpathname); + close(fd); + free(qup); + continue; + } + close(fd); + } + strlcpy(qup->qfname, qfpathname, qfpathname_len); // malloc'd size is correct for this + strlcpy(qup->fsname, fs->fs_file, sizeof(qup->fsname)); + + if (quphead == NULL) + quphead = qup; + else + quptail->next = qup; + quptail = qup; + qup->next = 0; + } + endfsent(); + return (quphead); +} +#endif /* __APPLE */ + +#ifdef __APPLE__ +#define ONEGIGABYTE (1024*1024*1024) +/* + * Initialize a new quota file. + */ +int +qfinit(fd, fst, type) + int fd; + struct statfs *fst; + int type; +{ + struct dqfilehdr dqhdr = {0}; + u_int64_t fs_size; + int64_t max = 0; + + /* + * Calculate the size of the hash table from the size of + * the file system. Note that the open addressing hashing + * used by the quota file assumes that this table will not + * be more than 90% full. + */ + fs_size = (u_int64_t)fst->f_blocks * (u_int64_t)fst->f_bsize; + + if (type == USRQUOTA) { + max = QF_USERS_PER_GB * (fs_size / ONEGIGABYTE); + + if (max < QF_MIN_USERS) + max = QF_MIN_USERS; + else if (max > QF_MAX_USERS) + max = QF_MAX_USERS; + } else if (type == GRPQUOTA) { + max = QF_GROUPS_PER_GB * (fs_size / ONEGIGABYTE); + + if (max < QF_MIN_GROUPS) + max = QF_MIN_GROUPS; + else if (max > QF_MAX_GROUPS) + max = QF_MAX_GROUPS; + } + /* Round up to a power of 2 */ + if (max && !powerof2(max)) { + int64_t x = max; + max = 4; + while (x>>1 != 1) { + x = x >> 1; + max = max << 1; + } + } + + (void) ftruncate(fd, (off_t)((max + 1) * sizeof(struct dqblk))); + dqhdr.dqh_magic = OSSwapHostToBigInt32(quotamagic[type]); + dqhdr.dqh_version = OSSwapHostToBigConstInt32(QF_VERSION); + dqhdr.dqh_maxentries = OSSwapHostToBigInt32((int32_t)max); + dqhdr.dqh_btime = OSSwapHostToBigConstInt32(MAX_DQ_TIME); + dqhdr.dqh_itime = OSSwapHostToBigConstInt32(MAX_IQ_TIME); + memmove(dqhdr.dqh_string, QF_STRING_TAG, strlen(QF_STRING_TAG)); + (void) lseek(fd, 0, L_SET); + (void) write(fd, &dqhdr, sizeof(dqhdr)); + + return (0); +} + +/* + * Lookup an entry in a quota file. + */ +int +qflookup(fd, id, type, dqbp) + int fd; + uid_t id; + int type; + struct dqblk *dqbp; +{ + struct dqfilehdr dqhdr; + int i, skip, last, m; + int mask; + + bzero(dqbp, sizeof(struct dqblk)); + + if (id == 0) + return (0); + + lseek(fd, 0, L_SET); + if (read(fd, &dqhdr, sizeof(struct dqfilehdr)) != sizeof(struct dqfilehdr)) + return (-1); + + /* Sanity check the quota file header. */ + if ((OSSwapBigToHostInt32(dqhdr.dqh_magic) != quotamagic[type]) || + (OSSwapBigToHostInt32(dqhdr.dqh_version) > 1) || + (!powerof2(OSSwapBigToHostInt32(dqhdr.dqh_maxentries)))) { + fprintf(stderr, "quota: invalid quota file header\n"); + return (-1); + } + + m = OSSwapBigToHostInt32(dqhdr.dqh_maxentries); + mask = m - 1; + i = dqhash1(id, dqhashshift(m), mask); + skip = dqhash2(id, mask); + + for (last = (i + (m-1) * skip) & mask; + i != last; + i = (i + skip) & mask) { + lseek(fd, dqoffset(i), L_SET); + if (read(fd, dqbp, sizeof(struct dqblk)) < sizeof(struct dqblk)) + return (-1); + /* + * Stop when an empty entry is found + * or we encounter a matching id. + */ + if (dqbp->dqb_id == 0 || OSSwapBigToHostInt32(dqbp->dqb_id) == id) + break; + } + /* Put data in host native byte order. */ + dqbp->dqb_bhardlimit = OSSwapBigToHostInt64(dqbp->dqb_bhardlimit); + dqbp->dqb_bsoftlimit = OSSwapBigToHostInt64(dqbp->dqb_bsoftlimit); + dqbp->dqb_curbytes = OSSwapBigToHostInt64(dqbp->dqb_curbytes); + dqbp->dqb_ihardlimit = OSSwapBigToHostInt32(dqbp->dqb_ihardlimit); + dqbp->dqb_isoftlimit = OSSwapBigToHostInt32(dqbp->dqb_isoftlimit); + dqbp->dqb_curinodes = OSSwapBigToHostInt32(dqbp->dqb_curinodes); + dqbp->dqb_btime = OSSwapBigToHostInt32(dqbp->dqb_btime); + dqbp->dqb_itime = OSSwapBigToHostInt32(dqbp->dqb_itime); + dqbp->dqb_id = OSSwapBigToHostInt32(dqbp->dqb_id); + + return (0); +} +#endif /* __APPLE */ + + +/* + * Store the requested quota information. + */ +void +putprivs(id, quotatype, quplist) + uid_t id; + int quotatype; + struct quotause *quplist; +{ + register struct quotause *qup; + int qcmd, fd; + + qcmd = QCMD(Q_SETQUOTA, quotatype); + for (qup = quplist; qup; qup = qup->next) { + if (quotactl(qup->fsname, qcmd, id, (char *)&qup->dqblk) == 0) + continue; +#ifdef __APPLE__ + if ((fd = open(qup->qfname, O_RDWR)) < 0) { + perror(qup->qfname); + } else { + if (qfupdate(fd, id, quotatype, &qup->dqblk) != 0) { + fprintf(stderr, "edquota: "); + perror(qup->qfname); + } +#else + if ((fd = open(qup->qfname, O_WRONLY)) < 0) { + perror(qup->qfname); + } else { + lseek(fd, + (off_t)(id * (long)sizeof (struct dqblk)), L_SET); + if (write(fd, &qup->dqblk, sizeof (struct dqblk)) != + sizeof (struct dqblk)) { + fprintf(stderr, "edquota: "); + perror(qup->qfname); + } +#endif /* __APPLE */ + close(fd); + } + } +} + +#ifdef __APPLE__ +/* + * Update an entry in a quota file. + */ +int +qfupdate(fd, id, type, dqbp) + int fd; + uid_t id; + int type; + struct dqblk *dqbp; +{ + struct dqblk dqbuf; + struct dqfilehdr dqhdr; + int i, skip, last, m; + unsigned int mask; + + if (id == 0) + return (0); + + lseek(fd, 0, L_SET); + if (read(fd, &dqhdr, sizeof(struct dqfilehdr)) != sizeof(struct dqfilehdr)) + return (-1); + + /* Sanity check the quota file header. */ + if ((OSSwapBigToHostInt32(dqhdr.dqh_magic) != quotamagic[type]) || + (OSSwapBigToHostInt32(dqhdr.dqh_version) > QF_VERSION) || + (!powerof2(OSSwapBigToHostInt32(dqhdr.dqh_maxentries)))) { + fprintf(stderr, "quota: invalid quota file header\n"); + return (EINVAL); + } + + m = OSSwapBigToHostInt32(dqhdr.dqh_maxentries); + mask = m - 1; + i = dqhash1(id, dqhashshift(m), mask); + skip = dqhash2(id, mask); + + for (last = (i + (m-1) * skip) & mask; + i != last; + i = (i + skip) & mask) { + lseek(fd, dqoffset(i), L_SET); + if (read(fd, &dqbuf, sizeof(struct dqblk)) < sizeof(struct dqblk)) + return (-1); + /* + * Stop when an empty entry is found + * or we encounter a matching id. + */ + if (dqbuf.dqb_id == 0 || OSSwapBigToHostInt32(dqbuf.dqb_id) == id) { + /* Convert buffer to big endian before writing. */ + struct dqblk tblk; + + tblk.dqb_bhardlimit = OSSwapHostToBigInt64(dqbp->dqb_bhardlimit); + tblk.dqb_bsoftlimit = OSSwapHostToBigInt64(dqbp->dqb_bsoftlimit); + tblk.dqb_curbytes = OSSwapHostToBigInt64(dqbp->dqb_curbytes); + tblk.dqb_ihardlimit = OSSwapHostToBigInt32(dqbp->dqb_ihardlimit); + tblk.dqb_isoftlimit = OSSwapHostToBigInt32(dqbp->dqb_isoftlimit); + tblk.dqb_curinodes = OSSwapHostToBigInt32(dqbp->dqb_curinodes); + tblk.dqb_btime = OSSwapHostToBigInt32((int)dqbp->dqb_btime); + tblk.dqb_itime = OSSwapHostToBigInt32((int)dqbp->dqb_itime); + tblk.dqb_id = OSSwapHostToBigInt32(id); + + lseek(fd, dqoffset(i), L_SET); + if (write(fd, &tblk, sizeof (struct dqblk)) != + sizeof (struct dqblk)) { + return (-1); + } + return (0); + } + } + errno = ENOSPC; + return (-1); +} +#endif /* __APPLE__ */ + +/* + * Take a list of priviledges and get it edited. + */ +int +editit(tmpfile) + char *tmpfile; +{ + int omask; + int pid, stat; + extern char *getenv(); + + omask = sigblock(sigmask(SIGINT)|sigmask(SIGQUIT)|sigmask(SIGHUP)); + top: + if ((pid = fork()) < 0) { + extern int errno; + + if (errno == EPROCLIM) { + fprintf(stderr, "You have too many processes\n"); + return(0); + } + if (errno == EAGAIN) { + sleep(1); + goto top; + } + perror("fork"); + return (0); + } + if (pid == 0) { + register char *ed; + struct passwd *pwd = getpwuid(getuid()); + gid_t newgid = getgid(); + + setgid(newgid); + if (pwd) initgroups(pwd->pw_name, newgid); + setuid(getuid()); + sigsetmask(omask); + + if ((ed = getenv("EDITOR")) == (char *)0) + ed = _PATH_VI; + execlp(ed, ed, tmpfile, NULL); + perror(ed); + exit(1); + } + waitpid(pid, &stat, 0); + sigsetmask(omask); + if (!WIFEXITED(stat) || WEXITSTATUS(stat) != 0) + return (0); + return (1); +} + +/* + * Convert a quotause list to an ASCII file. + */ +int +writeprivs(quplist, outfd, name, quotatype) + struct quotause *quplist; + int outfd; + char *name; + int quotatype; +{ + register struct quotause *qup; + FILE *fd; + + ftruncate(outfd, 0); + lseek(outfd, 0, L_SET); + if ((fd = fdopen(dup(outfd), "w")) == NULL) { + fprintf(stderr, "edquota: "); + perror(tmpfil); + exit(1); + } + fprintf(fd, "Quotas for %s %s:\n", qfextension[quotatype], name); + for (qup = quplist; qup; qup = qup->next) { +#ifdef __APPLE__ + fprintf(fd, "%s: %s %qd, limits (soft = %qd, hard = %qd)\n", + qup->fsname, "1K blocks in use:", + qup->dqblk.dqb_curbytes / 1024, + qup->dqblk.dqb_bsoftlimit / 1024, + qup->dqblk.dqb_bhardlimit / 1024); +#else + fprintf(fd, "%s: %s %d, limits (soft = %d, hard = %d)\n", + qup->fsname, "blocks in use:", + dbtob(qup->dqblk.dqb_curblocks) / 1024, + dbtob(qup->dqblk.dqb_bsoftlimit) / 1024, + dbtob(qup->dqblk.dqb_bhardlimit) / 1024); +#endif /* __APPLE__ */ + + fprintf(fd, "%s %d, limits (soft = %d, hard = %d)\n", + "\tinodes in use:", qup->dqblk.dqb_curinodes, + qup->dqblk.dqb_isoftlimit, qup->dqblk.dqb_ihardlimit); + } + fclose(fd); + return (1); +} + +/* + * Merge changes to an ASCII file into a quotause list. + */ +int +readprivs(quplist, infd) + struct quotause *quplist; + int infd; +{ + register struct quotause *qup; + FILE *fd; + int cnt; + register char *cp; + struct dqblk dqblk; + char fsp[BUFSIZ], line1[BUFSIZ], line2[BUFSIZ]; + + lseek(infd, 0, L_SET); + fd = fdopen(dup(infd), "r"); + if (fd == NULL) { + fprintf(stderr, "Can't re-read temp file!!\n"); + return (0); + } + /* + * Discard title line, then read pairs of lines to process. + */ + (void) fgets(line1, sizeof (line1), fd); + while (fgets(line1, sizeof (line1), fd) != NULL && + fgets(line2, sizeof (line2), fd) != NULL) { + cp = strstr(line1, ": 1K blocks in use:"); + if (cp == NULL) { + fprintf(stderr, "%s: bad format for line\n", line1); + return 0; + } + /* Copy up to the template text */ + strlcpy(fsp, line1, cp - line1 + 1); + /* And point cp right after it. */ + cp = line1 + strlen(fsp) + 1; +#ifdef __APPLE__ + /* We expect input to be in 1K blocks */ + cnt = sscanf(cp, + " 1K blocks in use: %qd, limits (soft = %qd, hard = %qd)", + &dqblk.dqb_curbytes, &dqblk.dqb_bsoftlimit, + &dqblk.dqb_bhardlimit); + if (cnt != 3) { + fprintf(stderr, "%s:%s: bad format\n", fsp, cp); + return (0); + } + + /* convert default 1K blocks to byte count */ + dqblk.dqb_curbytes = dqblk.dqb_curbytes * 1024; + dqblk.dqb_bsoftlimit = dqblk.dqb_bsoftlimit * 1024; + dqblk.dqb_bhardlimit = dqblk.dqb_bhardlimit * 1024; +#else + cnt = sscanf(cp, + " blocks in use: %d, limits (soft = %d, hard = %d)", + &dqblk.dqb_curblocks, &dqblk.dqb_bsoftlimit, + &dqblk.dqb_bhardlimit); + if (cnt != 3) { + fprintf(stderr, "%s:%s: bad format\n", fsp, cp); + return (0); + } + dqblk.dqb_curblocks = btodb(dqblk.dqb_curblocks * 1024); + dqblk.dqb_bsoftlimit = btodb(dqblk.dqb_bsoftlimit * 1024); + dqblk.dqb_bhardlimit = btodb(dqblk.dqb_bhardlimit * 1024); +#endif /* __APPLE__ */ + + if ((cp = strtok(line2, "\n")) == NULL) { + fprintf(stderr, "%s: %s: bad format\n", fsp, line2); + return (0); + } + cnt = sscanf(cp, + "\tinodes in use: %d, limits (soft = %d, hard = %d)", + &dqblk.dqb_curinodes, &dqblk.dqb_isoftlimit, + &dqblk.dqb_ihardlimit); + if (cnt != 3) { + fprintf(stderr, "%s: %s: bad format\n", fsp, line2); + return (0); + } + for (qup = quplist; qup; qup = qup->next) { + if (strcmp(fsp, qup->fsname)) + continue; + /* + * Cause time limit to be reset when the quota + * is next used if previously had no soft limit + * or were under it, but now have a soft limit + * and are over it. + */ +#ifdef __APPLE__ + if (dqblk.dqb_bsoftlimit && + qup->dqblk.dqb_curbytes >= dqblk.dqb_bsoftlimit && + (qup->dqblk.dqb_bsoftlimit == 0 || + qup->dqblk.dqb_curbytes < + qup->dqblk.dqb_bsoftlimit)) + qup->dqblk.dqb_btime = 0; +#else + if (dqblk.dqb_bsoftlimit && + qup->dqblk.dqb_curblocks >= dqblk.dqb_bsoftlimit && + (qup->dqblk.dqb_bsoftlimit == 0 || + qup->dqblk.dqb_curblocks < + qup->dqblk.dqb_bsoftlimit)) + qup->dqblk.dqb_btime = 0; +#endif /* __APPLE__ */ + if (dqblk.dqb_isoftlimit && + qup->dqblk.dqb_curinodes >= dqblk.dqb_isoftlimit && + (qup->dqblk.dqb_isoftlimit == 0 || + qup->dqblk.dqb_curinodes < + qup->dqblk.dqb_isoftlimit)) + qup->dqblk.dqb_itime = 0; + qup->dqblk.dqb_bsoftlimit = dqblk.dqb_bsoftlimit; + qup->dqblk.dqb_bhardlimit = dqblk.dqb_bhardlimit; + qup->dqblk.dqb_isoftlimit = dqblk.dqb_isoftlimit; + qup->dqblk.dqb_ihardlimit = dqblk.dqb_ihardlimit; + qup->flags |= FOUND; +#ifdef __APPLE__ + if (dqblk.dqb_curbytes == qup->dqblk.dqb_curbytes && + dqblk.dqb_curinodes == qup->dqblk.dqb_curinodes) + break; +#else + if (dqblk.dqb_curblocks == qup->dqblk.dqb_curblocks && + dqblk.dqb_curinodes == qup->dqblk.dqb_curinodes) + break; +#endif /* __APPLE__ */ + fprintf(stderr, + "%s: cannot change current allocation\n", fsp); + break; + } + } + fclose(fd); + /* + * Disable quotas for any filesystems that have not been found. + */ + for (qup = quplist; qup; qup = qup->next) { + if (qup->flags & FOUND) { + qup->flags &= ~FOUND; + continue; + } + qup->dqblk.dqb_bsoftlimit = 0; + qup->dqblk.dqb_bhardlimit = 0; + qup->dqblk.dqb_isoftlimit = 0; + qup->dqblk.dqb_ihardlimit = 0; + } + return (1); +} + +/* + * Convert a quotause list to an ASCII file of grace times. + */ +int +writetimes(quplist, outfd, quotatype) + struct quotause *quplist; + int outfd; + int quotatype; +{ + register struct quotause *qup; + char *cvtstoa(); + FILE *fd; + + ftruncate(outfd, 0); + lseek(outfd, 0, L_SET); + if ((fd = fdopen(dup(outfd), "w")) == NULL) { + fprintf(stderr, "edquota: "); + perror(tmpfil); + exit(1); + } + fprintf(fd, "Time units may be: days, hours, minutes, or seconds\n"); + fprintf(fd, "Grace period before enforcing soft limits for %ss:\n", + qfextension[quotatype]); + for (qup = quplist; qup; qup = qup->next) { + fprintf(fd, "%s: block grace period: %s, ", + qup->fsname, cvtstoa(qup->dqblk.dqb_btime)); + fprintf(fd, "file grace period: %s\n", + cvtstoa(qup->dqblk.dqb_itime)); + } + fclose(fd); + return (1); +} + +/* + * Merge changes of grace times in an ASCII file into a quotause list. + */ +int +readtimes(quplist, infd) + struct quotause *quplist; + int infd; +{ + register struct quotause *qup; + FILE *fd; + int cnt; + register char *cp; + time_t itime, btime, iseconds, bseconds; + char *fsp, bunits[10], iunits[10], line1[BUFSIZ]; + + lseek(infd, 0, L_SET); + fd = fdopen(dup(infd), "r"); + if (fd == NULL) { + fprintf(stderr, "Can't re-read temp file!!\n"); + return (0); + } + /* + * Discard two title lines, then read lines to process. + */ + (void) fgets(line1, sizeof (line1), fd); + (void) fgets(line1, sizeof (line1), fd); + while (fgets(line1, sizeof (line1), fd) != NULL) { + if ((fsp = strtok(line1, " \t:")) == NULL) { + fprintf(stderr, "%s: bad format\n", line1); + return (0); + } + if ((cp = strtok((char *)0, "\n")) == NULL) { + fprintf(stderr, "%s: %s: bad format\n", fsp, + &fsp[strlen(fsp) + 1]); + return (0); + } + cnt = sscanf(cp, + " block grace period: %ld %s file grace period: %ld %s", + &btime, bunits, &itime, iunits); + if (cnt != 4) { + fprintf(stderr, "%s:%s: bad format\n", fsp, cp); + return (0); + } + if (cvtatos(btime, bunits, &bseconds) == 0) + return (0); + if (cvtatos(itime, iunits, &iseconds) == 0) + return (0); + for (qup = quplist; qup; qup = qup->next) { + if (strcmp(fsp, qup->fsname)) + continue; + qup->dqblk.dqb_btime = (uint32_t) bseconds; + qup->dqblk.dqb_itime = (uint32_t) iseconds; + qup->flags |= FOUND; + break; + } + } + fclose(fd); + /* + * reset default grace periods for any filesystems + * that have not been found. + */ + for (qup = quplist; qup; qup = qup->next) { + if (qup->flags & FOUND) { + qup->flags &= ~FOUND; + continue; + } + qup->dqblk.dqb_btime = 0; + qup->dqblk.dqb_itime = 0; + } + return (1); +} + +/* + * Convert seconds to ASCII times. + */ +char * +cvtstoa(time) + time_t time; +{ + static char buf[20]; + + if (time % (24 * 60 * 60) == 0) { + time /= 24 * 60 * 60; + snprintf(buf, sizeof(buf), "%d day%s", (int)time, time == 1 ? "" : "s"); + } else if (time % (60 * 60) == 0) { + time /= 60 * 60; + snprintf(buf, sizeof(buf), "%d hour%s", (int)time, time == 1 ? "" : "s"); + } else if (time % 60 == 0) { + time /= 60; + snprintf(buf, sizeof(buf), "%d minute%s", (int)time, time == 1 ? "" : "s"); + } else + snprintf(buf, sizeof(buf), "%d second%s", (int)time, time == 1 ? "" : "s"); + return (buf); +} + +/* + * Convert ASCII input times to seconds. + */ +int +cvtatos(time, units, seconds) + time_t time; + char *units; + time_t *seconds; +{ + + if (bcmp(units, "second", 6) == 0) + *seconds = time; + else if (bcmp(units, "minute", 6) == 0) + *seconds = time * 60; + else if (bcmp(units, "hour", 4) == 0) + *seconds = time * 60 * 60; + else if (bcmp(units, "day", 3) == 0) + *seconds = time * 24 * 60 * 60; + else { + printf("%s: bad units, specify %s\n", units, + "days, hours, minutes, or seconds"); + return (0); + } + return (1); +} + +/* + * Free a list of quotause structures. + */ +void +freeprivs(quplist) + struct quotause *quplist; +{ + register struct quotause *qup, *nextqup; + + for (qup = quplist; qup; qup = nextqup) { + nextqup = qup->next; + free(qup); + } +} + +/* + * Check whether a string is completely composed of digits. + */ +int +alldigits(s) + register char *s; +{ + register int c; + + c = *s++; + do { + if (!isdigit(c)) + return (0); + } while ((c = *s++)); + return (1); +} + +/* + * Check to see if a particular quota is to be enabled. + */ +#ifdef __APPLE__ +int +hasquota(fst, type, qfnamep) + register struct statfs *fst; + int type; + char **qfnamep; +{ + struct stat sb; + static char initname, usrname[100], grpname[100]; + static char buf[BUFSIZ]; + + if (!initname) { + snprintf(usrname, sizeof(usrname), "%s%s", qfextension[USRQUOTA], qfname); + snprintf(grpname, sizeof(grpname), "%s%s", qfextension[GRPQUOTA], qfname); + initname = 1; + } + + /* + We only support the default path to the + on disk quota files. + */ + + (void)snprintf(buf, sizeof(buf), "%s/%s.%s", fst->f_mntonname, + QUOTAOPSNAME, qfextension[type] ); + if (stat(buf, &sb) != 0) { + /* There appears to be no mount option file */ + return(0); + } + + (void) snprintf(buf, sizeof(buf), "%s/%s.%s", fst->f_mntonname, qfname, qfextension[type]); + *qfnamep = buf; + return (1); +} +#else +hasquota(fs, type, qfnamep) + register struct fstab *fs; + int type; + char **qfnamep; +{ + register char *opt; + char *cp, *index(), *strtok(); + static char initname, usrname[100], grpname[100]; + static char buf[BUFSIZ]; + + if (!initname) { + snprintf(usrname, sizeof(usrname), "%s%s", qfextension[USRQUOTA], qfname); + snprintf(grpname, sizeof(grpname), "%s%s", qfextension[GRPQUOTA], qfname); + initname = 1; + } + strlcpy(buf, fs->fs_mntops, sizeof(buf)); + for (opt = strtok(buf, ","); opt; opt = strtok(NULL, ",")) { + if (cp = index(opt, '=')) + *cp++ = '\0'; + if (type == USRQUOTA && strcmp(opt, usrname) == 0) + break; + if (type == GRPQUOTA && strcmp(opt, grpname) == 0) + break; + } + if (!opt) + return (0); + if (cp) { + *qfnamep = cp; + return (1); + } + (void) snprintf(buf, sizeof(buf), "%s/%s.%s", fs->fs_file, qfname, qfextension[type]); + *qfnamep = buf; + return (1); +} +#endif /* __APPLE */ diff --git a/diskdev_cmds/edquota.tproj/pathnames.h b/diskdev_cmds/edquota.tproj/pathnames.h new file mode 100644 index 0000000..f1aef1c --- /dev/null +++ b/diskdev_cmds/edquota.tproj/pathnames.h @@ -0,0 +1,61 @@ +/* + * Copyright (c) 1999 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ +/* + * Copyright (c) 1989, 1993 + * The Regents of the University of California. 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the University of + * California, Berkeley and its contributors. + * 4. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``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 REGENTS OR CONTRIBUTORS 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. + * + * @(#)pathnames.h 8.1 (Berkeley) 6/6/93 + */ + +#include + +#undef _PATH_TMP +#define _PATH_TMP "/tmp/EdP.aXXXXX" diff --git a/diskdev_cmds/edt_fstab/edt_fstab.c b/diskdev_cmds/edt_fstab/edt_fstab.c new file mode 100644 index 0000000..42a53fe --- /dev/null +++ b/diskdev_cmds/edt_fstab/edt_fstab.c @@ -0,0 +1,180 @@ +/* + * Copyright (c) 2018-2020 Apple Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ + +// edt_fstab.c +// +// Created on 12/11/2018. +// + +#include + +#include "edt_fstab.h" + +#if (TARGET_OS_IPHONE && !TARGET_OS_SIMULATOR) + +/* Some APFS specific goop */ +#include +#include +#include +#include +#include +#include + +char boot_container[EDTVolumePropertySize] = {}; +char data_volume[EDTVolumePropertySize] = {}; + +static uint32_t edt_os_environment = EDT_OS_ENV_MAIN; + +const char * +get_boot_container(uint32_t *os_envp) +{ + kern_return_t err; + CFMutableDictionaryRef fs_info = NULL; + CFStringRef container = NULL; + CFDataRef os_env = NULL; + + // already got the boot container + if (strnlen(boot_container, sizeof(boot_container)) > 0) { + *os_envp = edt_os_environment; + return boot_container; + } + + fs_info = IORegistryEntryFromPath(kIOMasterPortDefault, kEDTFilesystemEntry); + if (fs_info == IO_OBJECT_NULL) { + fprintf(stderr, "failed to get filesystem info\n"); + return NULL; + } + + // lookup the OS environment being booted, assumes main OS upon failure + os_env = IORegistryEntryCreateCFProperty(fs_info, kEDTOSEnvironment, kCFAllocatorDefault, 0); + if (os_env) { + CFDataGetBytes(os_env, CFRangeMake(0, CFDataGetLength(os_env)), (UInt8*)(&edt_os_environment)); + CFRelease(os_env); + } + IOObjectRelease(fs_info); + *os_envp = edt_os_environment; + + // lookup the boot container + err = APFSContainerGetBootDevice(&container); + if (!err) { + strcpy(boot_container, _PATH_DEV); + CFStringGetCString(container, + boot_container + strlen(_PATH_DEV), + EDTVolumePropertySize - strlen(_PATH_DEV), + kCFStringEncodingUTF8); + CFRelease(container); + return boot_container; + } else { + // just a warning if not booting the main OS (rdar://48693021) + fprintf(stderr, "%sfailed to get boot device - %s\n", + (edt_os_environment == EDT_OS_ENV_MAIN) ? "" : "warning: ", + strerror(err_get_code(err))); + return NULL; + } +} + +const char * +get_data_volume(void) +{ + const char *container = NULL; + CFMutableArrayRef matches = NULL; + OSStatus status; + + // already got the data volume + if (strnlen(data_volume, sizeof(data_volume)) > 0) { + return data_volume; + } + + // get the boot container + if (strlen(boot_container) > 0) { + container = boot_container; + } else { + uint32_t os_env; + container = get_boot_container(&os_env); + } + if (!container) { + return NULL; + } + + // lookup the data volume + status = APFSVolumeRoleFind(container, APFS_VOL_ROLE_DATA, &matches); + if (status) { + // just a warning if not booting the main OS + fprintf(stderr, "%sfailed to lookup data volume - %s\n", + (edt_os_environment == EDT_OS_ENV_MAIN) ? "" : "warning: ", + strerror(err_get_code(status))); + return NULL; + } else if (CFArrayGetCount(matches) > 1) { + fprintf(stderr, "found multiple data volumes\n"); + CFRelease(matches); + return NULL; + } else { + CFStringGetCString(CFArrayGetValueAtIndex(matches, 0), + data_volume, + EDTVolumePropertySize, + kCFStringEncodingUTF8); + CFRelease(matches); + return data_volume; + } +} + +int +get_boot_manifest_hash(char *boot_manifest_hash, size_t boot_manifest_hash_len) +{ + kern_return_t err = 0; + io_registry_entry_t chosen; + CFDataRef bm_hash = NULL; + size_t bm_hash_size; + uint8_t bm_hash_buf[EDTVolumePropertyMaxSize] = {}; + const char *hexmap = "0123456789ABCDEF"; + + chosen = IORegistryEntryFromPath(kIOMasterPortDefault, kIODeviceTreePlane ":/chosen"); + if (chosen == IO_OBJECT_NULL) { + fprintf(stderr, "failed to get chosen info\n"); + return ENOENT; + } + + bm_hash = IORegistryEntryCreateCFProperty(chosen, CFSTR("boot-manifest-hash"), kCFAllocatorDefault, 0); + if (!bm_hash) { + fprintf(stderr, "failed to get boot-manifest-hash\n"); + IOObjectRelease(chosen); + return ENOENT; + } else { + bm_hash_size = CFDataGetLength(bm_hash); + CFDataGetBytes(bm_hash, CFRangeMake(0, bm_hash_size), bm_hash_buf); + + if (boot_manifest_hash_len < (bm_hash_size * 2 + 1)) { + err = EINVAL; + } else { + // hexdump the hash into input buffer + for (size_t i = 0; i < (2 * bm_hash_size); i++) + *boot_manifest_hash++ = hexmap[(bm_hash_buf[i / 2] >> ((i % 2) ? 0 : 4)) & 0xf]; + *boot_manifest_hash = '\0'; + } + CFRelease(bm_hash); + IOObjectRelease(chosen); + } + + return err; +} +#endif /* (TARGET_OS_IPHONE && !TARGET_OS_SIMULATOR) */ diff --git a/diskdev_cmds/edt_fstab/edt_fstab.h b/diskdev_cmds/edt_fstab/edt_fstab.h new file mode 100644 index 0000000..1fd4926 --- /dev/null +++ b/diskdev_cmds/edt_fstab/edt_fstab.h @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2018-2020 Apple Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ + +// edt_fstab.h +// +// Created on 12/11/2018. +// + +#ifndef edt_fstab_h +#define edt_fstab_h + +#include + +#if (TARGET_OS_IPHONE && !TARGET_OS_SIMULATOR) +#define RAMDISK_FS_SPEC "ramdisk" + +/* + * get_boot_container, get_data_volume - return the bsd name of the requested + * device upon success. Null otherwise. + */ +const char *get_boot_container(uint32_t *os_env); +const char *get_data_volume(void); + +int get_boot_manifest_hash(char *boot_manifest_hash, size_t boot_manifest_hash_len); +#endif + +#endif /* edt_fstab_h */ diff --git a/diskdev_cmds/fdisk.tproj/auto.c b/diskdev_cmds/fdisk.tproj/auto.c new file mode 100644 index 0000000..155f7ab --- /dev/null +++ b/diskdev_cmds/fdisk.tproj/auto.c @@ -0,0 +1,155 @@ +/* + * Copyright (c) 2002 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ + +/* + * Auto partitioning code. + */ + +#include +#include +#include +#include +#include +#include +#include "disk.h" +#include "mbr.h" +#include "auto.h" + +int AUTO_boothfs __P((disk_t *, mbr_t *)); +int AUTO_hfs __P((disk_t *, mbr_t *)); +int AUTO_dos __P((disk_t *, mbr_t *)); +int AUTO_raid __P((disk_t *, mbr_t *)); + +/* The default style is the first one in the list */ +struct _auto_style { + char *style_name; + int (*style_fn)(disk_t *, mbr_t *); + char *description; +} style_fns[] = { + {"boothfs", AUTO_boothfs, "8Mb boot plus HFS+ root partition"}, + {"hfs", AUTO_hfs, "Entire disk as one HFS+ partition"}, + {"dos", AUTO_dos, "Entire disk as one DOS partition"}, + {"raid", AUTO_raid, "Entire disk as one 0xAC partition"}, + {0,0} +}; + +void +AUTO_print_styles(FILE *f) +{ + struct _auto_style *fp; + int i; + + for (i=0, fp = &style_fns[0]; fp->style_name != NULL; i++, fp++) { + fprintf(f, " %-10s %s%s\n", fp->style_name, fp->description, (i==0) ? " (default)" : ""); + } +} + + +int +AUTO_init(disk_t *disk, char *style, mbr_t *mbr) +{ + struct _auto_style *fp; + + for (fp = &style_fns[0]; fp->style_name != NULL; fp++) { + /* If style is NULL, use the first (default) style */ + if (style == NULL || strcasecmp(style, fp->style_name) == 0) { + return (*fp->style_fn)(disk, mbr); + } + } + warnx("No such auto-partition style %s", style); + return AUTO_ERR; +} + + +static int +use_whole_disk(disk_t *disk, unsigned char id, mbr_t *mbr) +{ + MBR_clear(mbr); + mbr->part[0].id = id; + mbr->part[0].bs = 63; + mbr->part[0].ns = disk->real->size - 63; + PRT_fix_CHS(disk, &mbr->part[0], 0); + return AUTO_OK; +} + +/* DOS style: one partition for the whole disk */ +int +AUTO_dos(disk_t *disk, mbr_t *mbr) +{ + int cc; + cc = use_whole_disk(disk, 0x0C, mbr); + if (cc == AUTO_OK) { + mbr->part[0].flag = DOSACTIVE; + } + return cc; +} + +/* HFS style: one partition for the whole disk */ +int +AUTO_hfs(disk_t *disk, mbr_t *mbr) +{ + int cc; + cc = use_whole_disk(disk, 0xAF, mbr); + if (cc == AUTO_OK) { + mbr->part[0].flag = DOSACTIVE; + } + return cc; +} + +/* One boot partition, one HFS+ root partition */ +int +AUTO_boothfs (disk_t *disk, mbr_t *mbr) +{ + /* Check disk size. */ + if (disk->real->size < 16 * 2048) { + errx(1, "Disk size must be greater than 16Mb"); + return AUTO_ERR; + } + + MBR_clear(mbr); + + /* 8MB boot partition */ + mbr->part[0].id = 0xAB; + mbr->part[0].bs = 63; + mbr->part[0].ns = 8 * 1024 * 2; + mbr->part[0].flag = DOSACTIVE; + PRT_fix_CHS(disk, &mbr->part[0], 0); + + /* Rest of the disk for rooting */ + mbr->part[1].id = 0xAF; + mbr->part[1].bs = (mbr->part[0].bs + mbr->part[0].ns); + mbr->part[1].ns = disk->real->size - mbr->part[0].ns - 63; + PRT_fix_CHS(disk, &mbr->part[1], 1); + + return AUTO_OK; +} + + + +/* RAID style: one 0xAC partition for the whole disk */ +int +AUTO_raid(disk_t *disk, mbr_t *mbr) +{ + return use_whole_disk(disk, 0xAC, mbr); +} + diff --git a/diskdev_cmds/fdisk.tproj/auto.h b/diskdev_cmds/fdisk.tproj/auto.h new file mode 100644 index 0000000..c9259d4 --- /dev/null +++ b/diskdev_cmds/fdisk.tproj/auto.h @@ -0,0 +1,31 @@ +/* + * Copyright (c) 2002 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ + +#include "mbr.h" + +/* Prototypes */ +void AUTO_print_styles __P((FILE *)); +int AUTO_init __P((disk_t *, char *, mbr_t *)); + +#define AUTO_OK 0 +#define AUTO_ERR -1 diff --git a/diskdev_cmds/fdisk.tproj/cmd.c b/diskdev_cmds/fdisk.tproj/cmd.c new file mode 100644 index 0000000..41cee77 --- /dev/null +++ b/diskdev_cmds/fdisk.tproj/cmd.c @@ -0,0 +1,507 @@ +/* + * Copyright (c) 2002-2005 Apple Computer, Inc. All rights reserved. + * + * @APPLE_LICENSE_HEADER_START@ + * + * This file contains Original Code and/or Modifications of Original Code + * as defined in and that are subject to the Apple Public Source License + * Version 2.0 (the 'License'). You may not use this file except in + * compliance with the License. Please obtain a copy of the License at + * http://www.opensource.apple.com/apsl/ and read it before using this + * file. + * + * The Original Code and all software distributed under the License are + * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER + * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, + * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT. + * Please see the License for the specific language governing rights and + * limitations under the License. + * + * @APPLE_LICENSE_HEADER_END@ + */ + + +/* + * 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. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by Tobias Weingartner. + * 4. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission. + * + * 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. + */ + +#include +#include +#include +#include +#include +#include +#include +#include "disk.h" +#include "misc.h" +#include "user.h" +#include "part.h" +#include "cmd.h" +#include "auto.h" +#define MAX(a, b) ((a) >= (b) ? (a) : (b)) + +int +Xerase(cmd, disk, mbr, tt, offset) + cmd_t *cmd; + disk_t *disk; + mbr_t *mbr; + mbr_t *tt; + int offset; +{ + bzero(mbr->part, sizeof(mbr->part)); + mbr->signature = MBR_SIGNATURE; + return (CMD_DIRTY); +} + +int +Xreinit(cmd, disk, mbr, tt, offset) + cmd_t *cmd; + disk_t *disk; + mbr_t *mbr; + mbr_t *tt; + int offset; +{ + /* Copy template MBR */ + MBR_make(tt); + MBR_parse(disk, offset, 0, mbr); + + MBR_init(disk, mbr); + + /* Tell em we did something */ + printf("In memory copy is initialized to:\n"); + printf("Offset: %d\t", offset); + MBR_print(mbr); + printf("Use 'write' to update disk.\n"); + + return (CMD_DIRTY); +} + +int +Xauto(cmd, disk, mbr, tt, offset) + cmd_t *cmd; + disk_t *disk; + mbr_t *mbr; + mbr_t *tt; + int offset; +{ + if (cmd->args[0] == '\0') { + printf("usage: auto