From f71956f75f646783a438957a0c60e142bbb8725d Mon Sep 17 00:00:00 2001 From: Aaron LI Date: Sat, 2 Jun 2018 13:09:19 +0800 Subject: [PATCH] Makefile{,.inc1}: Merge user-driven target descriptions and cleanups * Merge the descriptions to user-driven targets from Makefile.inc1 to Makefile and improve the wordings a bit. * Delete some obsolete information. * Whitespace cleanups. --- Makefile | 54 ++++++++++++++++++++++++--------------------------- Makefile.inc1 | 39 +++++++++++-------------------------- 2 files changed, 36 insertions(+), 57 deletions(-) diff --git a/Makefile b/Makefile index e60ee435c6..80c08ed7aa 100644 --- a/Makefile +++ b/Makefile @@ -5,51 +5,48 @@ # # buildworld - Rebuild *everything*, including glue to help do # upgrades. -# quickworld - Skip bootstrap, build and cross-build tool steps -# realquickworld - Skip above steps, plus depend -# crossworld - Just do the bootstrap, build, and cross-build steps +# quickworld - Skip bootstrap, build and cross-build tool steps. +# realquickworld - Skip above steps, plus depend. +# crossworld - Just do the bootstrap, build, and cross-build steps. # installworld - Install everything built by "buildworld". -# installworld-force - Install everything built by "buildworld", special case for old systems +# installworld-force - Install everything built by "buildworld"; +# special case for old systems. # world - buildworld + installworld. # buildkernel - Rebuild the kernel and the kernel-modules from scratch -# using build/bootstrap/cross tools from the last -# buildworld. -# nativekernel - Rebuild the kernel and the kernel-modules from scratch -# using native tools. -# quickkernel - rebuild the kernel quickly (build or native), and do -# not clean out the obj modules. +# using build/bootstrap/cross tools from the last +# buildworld. +# nativekernel - Rebuild the kernel and the kernel-modules from scratch +# using native tools. +# quickkernel - Rebuild the kernel quickly (build or native), and do +# not clean out the obj modules. # realquickkernel - Like quickkernel, but skips depend too. # installkernel - Install the kernel and the kernel-modules. # reinstallkernel - Reinstall the kernel and the kernel-modules. # kernel - buildkernel + installkernel. -# preupgrade - Certain upgrades may have to be done before installworld. -# installworld will complain if they have not been done. This -# target will do those upgrades... typically the addition of -# new special groups and users used by installed utilities. +# preupgrade - Do certain upgrades in /etc (typically the addition of +# new users and groups used by installed utilities) before +# the installworld. # upgrade - Upgrade the files in /etc and also setup the rest -# of the system for DragonFly. ex. two compilers +# of the system for DragonFly. ex. two compilers. # most - Build user commands, no libraries or include files. # installmost - Install user commands, no libraries or include files. -# rescue - Create rescue image in /boot -# backupworld - Copies /bin /sbin /usr/bin /usr/sbin /usr/lib +# backupworld - Copy /bin /sbin /usr/bin /usr/sbin /usr/lib # /usr/libexec to manual backup dir. -# restoreworld - Installs binaries from manual backup dir to world. -# restoreworld-auto - Installs binaries from auto-backup dir to world; +# restoreworld - Install binaries from manual backup dir to world. +# restoreworld-auto - Install binaries from auto-backup dir to world; # installworld target makes backup to auto-backup dir. # backup-auto-clean - Delete backup from auto-backup dir. # backup-clean - Delete backup from manual backup dir. # # This makefile is simple by design. The DragonFly make automatically reads -# /usr/share/mk/sys.mk unless the -m argument is specified on the +# /usr/share/mk/sys.mk unless the -m argument is specified on the # command line. By keeping this makefile simple, it doesn't matter too # much how different the installed mk files are from those in the source # tree. This makefile executes a child make process, forcing it to use # the mk files from the source tree which are supposed to DTRT. # -# The user-driven targets (as listed above) are implemented in Makefile.inc1. -# -# If you want to build your system from source be sure that /usr/obj has -# at least 800MB of diskspace available. +# Most of the user-driven targets (as listed above) are implemented in +# Makefile.inc1. The exceptions are preupgrade and upgrade. # # For individuals wanting to build from the sources currently on their # system, the simple instructions are: @@ -68,21 +65,20 @@ # 6. `make upgrade' # 7. `reboot' # -# See src/UPDATING `COMMON ITEMS' for more complete information. -# # If TARGET_ARCH=arch (e.g. x86_64) is specified you can # cross build world for other architectures using the buildworld target, # and once the world is built you can cross build a kernel using the # buildkernel target. # -# Define the user-driven targets. These are listed here in alphabetical -# order, but that's not important. +# For more information, see the build(7) manual page. # + TGTS= all all-man buildkernel quickkernel realquickkernel nativekernel \ buildworld crossworld quickworld realquickworld checkdpadd clean \ cleandepend cleandir depend everything \ hierarchy install installcheck installkernel \ - reinstallkernel installmost installworld installworld-force libraries lint maninstall \ + reinstallkernel installmost installworld installworld-force \ + libraries lint maninstall \ manlint mk most obj objlink regress rerelease tags \ rescue backupworld restoreworld restoreworld-auto \ backup-clean backup-auto-clean \ diff --git a/Makefile.inc1 b/Makefile.inc1 index 049f9d9408..1a868f3c09 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1,28 +1,13 @@ # # $FreeBSD: src/Makefile.inc1,v 1.141.2.62 2003/04/06 19:54:00 dwmalone Exp $ # +# This file defines the user-driven targets. +# +# Standard targets are documented in the makefiles in /usr/share/mk and include: +# obj depend all install clean cleandepend cleanobj +# # Build-time options are documented in make.conf(5). # -# The intended user-driven targets are: -# -# buildworld - rebuild *everything*, including glue to help do upgrades -# quickworld - skip the glue and do a depend+build on the meat -# realquickworld - skip the glue and depend stages and just build the meat -# crossworld - only build the glue (particularly the cross-build environment) -# installworld- install everything built by "buildworld" -# backupworld - copies /bin /sbin /usr/bin /usr/sbin /usr/lib /usr/libexec -# to manual backup dir -# rescue - create rescue image -# restoreworld- installs binaries from manual backup dir to world -# restoreworld-auto - installs binaries from auto-backup dir to world -# most - build user commands, no libraries or include files -# installmost - install user commands, no libraries or include files -# backup-clean - delete backup from manual backup dir -# backup-auto-clean - delete backup from auto-backup dir -# -# Standard targets (not defined here) are documented in the makefiles in -# /usr/share/mk. These include: -# obj depend all install clean cleandepend cleanobj # Put initial settings here. SUBDIR= @@ -178,13 +163,13 @@ THREAD_LIB?= thread_xu # WORLD (Cross built) Our ultimate buildworld, using only BTOOLS and # CTOOLS. # -# MACHINE_PLATFORM Platform Architecture we are building on -# MACHINE Machine Architecture (usually the same as MACHINE_ARCH) -# MACHINE_ARCH Cpu Architecture we are building on +# MACHINE_PLATFORM Platform Architecture we are building on +# MACHINE Machine Architecture (usually the same as MACHINE_ARCH) +# MACHINE_ARCH CPU Architecture we are building on # -# TARGET_PLATFORM Platform Architecture we are building for -# TARGET Machine Architecture we are building for -# TARGET_ARCH Cpu Architecture we are building for +# TARGET_PLATFORM Platform Architecture we are building for +# TARGET Machine Architecture we are building for +# TARGET_ARCH CPU Architecture we are building for # BTOOLSDEST= ${DESTDIRBASE}/btools_${MACHINE_ARCH} CTOOLSDEST= ${DESTDIRBASE}/ctools_${MACHINE_ARCH}_${TARGET_ARCH} @@ -495,8 +480,6 @@ installcheck: _iwinit # Backs up the current world if ${AUTO_BACKUP} is writable. # Installs everything compiled by a 'buildworld'. # -# Includes sleep/sync safety before running mkinitrd. - installworld: installcheck -@mkdir -p ${AUTO_BACKUP} > /dev/null 2>&1 @cd ${.CURDIR}; \ -- 2.41.0