Changeset 44119 in vbox for trunk/src/VBox/Installer/linux/install_service
- Timestamp:
- Dec 13, 2012 1:31:33 PM (12 years ago)
- svn:sync-xref-src-repo-rev:
- 82685
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Installer/linux/install_service/install_service.sh
r44094 r44119 175 175 for path in "${PREFIX}/init.d/rc.d" "${PREFIX}/init.d/" "${PREFIX}/rc.d/init.d" "${PREFIX}/rc.d"; do 176 176 if test -d "${path}"; then 177 # Check permissions for the init path. 177 178 test -w "${path}" || abort "No permission to write to \"${path}\"." 179 # And for the System V symlink directories. 178 180 for i in rc0.d rc1.d rc6.d rc.d/rc0.d rc.d/rc1.d rc.d/rc6.d; do 179 181 if test -d "${PREFIX}/${i}"; then 180 182 test -w "${PREFIX}/${i}" || 181 abort "No permission to write to \"${PREFIX}/${i}\" ".183 abort "No permission to write to \"${PREFIX}/${i}\"." 182 184 fi 183 185 done 186 # And for the OpenRC symlink directories. 187 if test -d "${PREFIX}/runlevel/"; then 188 test -w "${PREFIX}/runlevel/" || 189 abort "No permission to write to \"${PREFIX}/runlevel\"". 190 fi 184 191 found_init="true" 185 192 update="" … … 197 204 # Various known combinations of sysvinit rc directories. 198 205 for i in "${PREFIX}"/rc*.d/[KS]??"${SERVICE_NAME}" "${PREFIX}"/rc.d/rc*.d/[KS]??"${SERVICE_NAME}"; do 199 rm -f "$ i"206 rm -f "${i}" 200 207 done 201 208 # And OpenRC. 202 type rc-update > /dev/null 2>&1 && 203 rc-update del "${1}" > /dev/null 2>&1 209 test -d "${PREFIX}/runlevel/" && 210 for i in "/${PREFIX}/runlevel"/*/"${SERVICE_NAME}"; do 211 rm -f "${i}" 212 done 204 213 # Various known combinations of sysvinit rc directories. 205 214 if test -n "${ENABLE}"; then … … 219 228 done 220 229 # And OpenRC. 221 t ype rc-update > /dev/null 2>&1&&222 rc-update add "${1}" default > /dev/null 2>&1230 test -d "${PREFIX}/runlevel/default" && 231 ln -sf "${path}/${SERVICE_NAME}" "/${PREFIX}/runlevel/default/" 223 232 fi 224 233 fi
Note:
See TracChangeset
for help on using the changeset viewer.