mirror of
https://git.FreeBSD.org/ports.git
synced 2025-01-01 05:45:45 +00:00
Add home directory creation to pre-install script for USERS/GROUPS
Use @dirrmtry instead of @exec rmdir
This commit is contained in:
parent
7615972cf3
commit
88c3501f19
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=367023
@ -3980,7 +3980,7 @@ create-users-groups:
|
||||
echo \"Creating user '$$login' with uid '$$uid'.\" \n \
|
||||
${PW} useradd $$login -u $$uid -g $$gid $$class -c \"$$gecos\" -d $$homedir -s $$shell \n \
|
||||
else \necho \"Using existing user '$$login'.\" \nfi" >> ${_UG_OUTPUT}; \
|
||||
case $$homedir in /|/nonexistent|/var/empty) ;; *) ${ECHO_CMD} "@exec ${INSTALL} -d -g $$gid -o $$uid $$homedir" >> ${TMPPLIST};; esac; \
|
||||
case $$homedir in /|/nonexistent|/var/empty) ;; *) ${ECHO_CMD} "${INSTALL} -d -g $$gid -o $$uid $$homedir" >> ${_UG_OUTPUT};; esac; \
|
||||
done
|
||||
.endfor
|
||||
.if defined(GROUPS)
|
||||
@ -5461,7 +5461,7 @@ add-plist-info:
|
||||
.if (${PREFIX} != ${LOCALBASE} && ${PREFIX} != ${LINUXBASE} && \
|
||||
${PREFIX} != "/usr" && !defined(NO_PREFIX_RMDIR))
|
||||
add-plist-post:
|
||||
@${ECHO_CMD} "@unexec rmdir %D 2> /dev/null || true" >> ${TMPPLIST}
|
||||
@${ECHO_CMD} "@dirrmtry %D" >> ${TMPPLIST}
|
||||
.endif
|
||||
.endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user