diff options
author | Enji Cooper <ngie@FreeBSD.org> | 2023-05-11 05:54:51 +0000 |
---|---|---|
committer | Enji Cooper <ngie@FreeBSD.org> | 2023-08-11 07:49:02 +0000 |
commit | f05948d4e98d3abd0965a2994e9e42add6908ff3 (patch) | |
tree | 9e1cd6e92f5ca9ff1225f8e78c43b05edcb9427c | |
parent | fb055b01eb04914ea1aadc7c88090093a8481fe7 (diff) | |
download | src-f05948d4e98d.tar.gz src-f05948d4e98d.zip |
cpuset(8): move to /bin/
Summary:
This change moves /usr/bin/cpuset to /bin/cpuset so it is more readily
available on hosts where the /usr partition might not be mounted at the
time / has been mounted.
Remove some complexity from rc.subr(8) since /bin is assumed to always
be present if/when / is mounted.
MFC after: 2 weeks
MFC with: 0661f93892a2, 271d552379af
Test Plan:
- Test out rc.subr change.
- Confirm that the installation logic does what's needed.
Relnotes: yes (moving cpuset may impact strict file permissions/mode checking)
Reviewers: kevans
Subscribers: imp
Differential Revision: https://reviews.freebsd.org/D40057
-rw-r--r-- | bin/Makefile | 1 | ||||
-rw-r--r-- | bin/cpuset/Makefile (renamed from usr.bin/cpuset/Makefile) | 2 | ||||
-rw-r--r-- | bin/cpuset/Makefile.depend (renamed from usr.bin/cpuset/Makefile.depend) | 0 | ||||
-rw-r--r-- | bin/cpuset/cpuset.1 (renamed from usr.bin/cpuset/cpuset.1) | 0 | ||||
-rw-r--r-- | bin/cpuset/cpuset.c (renamed from usr.bin/cpuset/cpuset.c) | 0 | ||||
-rw-r--r-- | libexec/rc/rc.subr | 4 | ||||
-rw-r--r-- | usr.bin/Makefile | 1 |
7 files changed, 5 insertions, 3 deletions
diff --git a/bin/Makefile b/bin/Makefile index 83bf79dcb9f9..075c91394f04 100644 --- a/bin/Makefile +++ b/bin/Makefile @@ -8,6 +8,7 @@ SUBDIR= cat \ chio \ chmod \ cp \ + cpuset \ date \ dd \ df \ diff --git a/usr.bin/cpuset/Makefile b/bin/cpuset/Makefile index 74643f5e35b6..8626303bb254 100644 --- a/usr.bin/cpuset/Makefile +++ b/bin/cpuset/Makefile @@ -4,4 +4,6 @@ PROG= cpuset LIBADD= jail +SYMLINKS+= ${BINDIR}/cpuset /usr/bin/cpuset + .include <bsd.prog.mk> diff --git a/usr.bin/cpuset/Makefile.depend b/bin/cpuset/Makefile.depend index 1c40cf7442bb..1c40cf7442bb 100644 --- a/usr.bin/cpuset/Makefile.depend +++ b/bin/cpuset/Makefile.depend diff --git a/usr.bin/cpuset/cpuset.1 b/bin/cpuset/cpuset.1 index 1d0180c98991..1d0180c98991 100644 --- a/usr.bin/cpuset/cpuset.1 +++ b/bin/cpuset/cpuset.1 diff --git a/usr.bin/cpuset/cpuset.c b/bin/cpuset/cpuset.c index 43aadb33f1e0..43aadb33f1e0 100644 --- a/usr.bin/cpuset/cpuset.c +++ b/bin/cpuset/cpuset.c diff --git a/libexec/rc/rc.subr b/libexec/rc/rc.subr index 0114dd5ca5a8..bd6c6c6b7679 100644 --- a/libexec/rc/rc.subr +++ b/libexec/rc/rc.subr @@ -52,7 +52,7 @@ ID="/usr/bin/id" IDCMD="if [ -x $ID ]; then $ID -un; fi" PS="/bin/ps -ww" JID=0 -CPUSET="/usr/bin/cpuset" +CPUSET="/bin/cpuset" # rc_service provides the path to the service script that we are executing. # This is not being set here in an execution context, necessarily, so it's @@ -981,7 +981,7 @@ run_rc_command() esac _cpusetcmd= - if [ -n "$_cpuset" -a -x $CPUSET ]; then + if [ -n "$_cpuset" ]; then _cpusetcmd="$CPUSET -l $_cpuset" fi diff --git a/usr.bin/Makefile b/usr.bin/Makefile index e027eaf81f24..b4f504e0eec7 100644 --- a/usr.bin/Makefile +++ b/usr.bin/Makefile @@ -28,7 +28,6 @@ SUBDIR= alias \ column \ comm \ compress \ - cpuset \ csplit \ ctlstat \ cut \ |