diff options
author | Christian Rößler | 2014-04-29 16:30:58 +0200 |
---|---|---|
committer | Christian Rößler | 2014-04-29 16:30:58 +0200 |
commit | a80bfcabee6f26afbb3d4db8a8518f6e4ae99055 (patch) | |
tree | edeaa01112e0edb90a64c3ddfda0b06e8b13d14f /remote/modules/vbox | |
parent | [vmchooser] vmchooser-run_virt: Now logs executed VM command (diff) | |
download | tm-scripts-a80bfcabee6f26afbb3d4db8a8518f6e4ae99055.tar.gz tm-scripts-a80bfcabee6f26afbb3d4db8a8518f6e4ae99055.tar.xz tm-scripts-a80bfcabee6f26afbb3d4db8a8518f6e4ae99055.zip |
[vbox] Simplified script list to be patched with openslx binary path
Diffstat (limited to 'remote/modules/vbox')
-rw-r--r-- | remote/modules/vbox/module.build | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/remote/modules/vbox/module.build b/remote/modules/vbox/module.build index 5a533089..f4a8610a 100644 --- a/remote/modules/vbox/module.build +++ b/remote/modules/vbox/module.build @@ -1,11 +1,16 @@ #!/bin/bash patch_vbox_scripts() { - # patching some virtualbox utility scripts to include openslx-busybox paths. Strange sed-ing, as the added - # openslx paths need to be at the end of PATH to not impede with system binaries to not impede with system binaries + # Patching virtualbox utility scripts to include openslx-busybox binary paths. Strange sed-ing, as the openslx + # binary paths need to be at the end of PATH to not impede with system binaries. + # It seems sufficient to patch just VBox, as eg. vboxmanage, vboxheadless etc. are just links to VBox. + # If only vboxmanage, vboxheadless or such should be patched (and not the base script VBox) just use a list + # in the loop (eg. 'for i in virtualbox vboxmanage vboxheadless; do'). These links will be replaced by patched + # 'real' files. Of course it will not make sense if VBox is included in the list, then. + # Patched files will be saved with extension .original. + pinfo "Patching virtual box scripts to include openslx (busybox)-paths ..." - # vboxmanage is a link to VBox; will get unlinked. Original link will be vboxmanage.original - for i in virtualbox vboxmanage vboxheadless; do + for i in VBox; do pinfo "Patching virtual box script $i ..." SCRIPTPATH=$(grep -m 1 PATH "${MODULE_BUILD_DIR}/usr/bin/$i"|sed 's/"//g') # assume first hit is real path sed -i "-i.original" "/^PATH=/c ${SCRIPTPATH}:/opt/openslx/bin:/opt/openslx/usr/bin:/opt/openslx/sbin"\ |