diff options
author | Volker Uhrig | 2008-07-01 21:29:37 +0200 |
---|---|---|
committer | Volker Uhrig | 2008-07-01 21:29:37 +0200 |
commit | 673e78f6bfaf2d0077c2d7944405aa9d6d859e66 (patch) | |
tree | 14aaba6391eb62902c2d777417d1aab3cba5876b /os-plugins/plugins | |
parent | * fixed wrong path (diff) | |
download | core-673e78f6bfaf2d0077c2d7944405aa9d6d859e66.tar.gz core-673e78f6bfaf2d0077c2d7944405aa9d6d859e66.tar.xz core-673e78f6bfaf2d0077c2d7944405aa9d6d859e66.zip |
* merge of vmpl1.0 and vmpl2.0 installation script
* renamed path root -> vmroot
* moved modules to its on place vmroot/modules
git-svn-id: http://svn.openslx.org/svn/openslx/openslx/trunk@1895 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'os-plugins/plugins')
-rw-r--r-- | os-plugins/plugins/vmware/OpenSLX/Distro/Base.pm | 8 | ||||
-rw-r--r-- | os-plugins/plugins/vmware/OpenSLX/Distro/Debian.pm | 8 | ||||
-rw-r--r-- | os-plugins/plugins/vmware/OpenSLX/Distro/Gentoo.pm | 8 | ||||
-rw-r--r-- | os-plugins/plugins/vmware/OpenSLX/Distro/Suse.pm | 8 | ||||
-rw-r--r-- | os-plugins/plugins/vmware/OpenSLX/OSPlugin/vmware.pm | 8 | ||||
-rw-r--r-- | os-plugins/plugins/vmware/files/install-vmpl.sh | 122 | ||||
-rw-r--r-- | os-plugins/plugins/vmware/files/install-vmpl1.0.sh | 53 | ||||
-rw-r--r-- | os-plugins/plugins/vmware/files/install-vmpl2.0.sh | 40 |
8 files changed, 192 insertions, 63 deletions
diff --git a/os-plugins/plugins/vmware/OpenSLX/Distro/Base.pm b/os-plugins/plugins/vmware/OpenSLX/Distro/Base.pm index 20769ca4..d453e106 100644 --- a/os-plugins/plugins/vmware/OpenSLX/Distro/Base.pm +++ b/os-plugins/plugins/vmware/OpenSLX/Distro/Base.pm @@ -73,10 +73,10 @@ sub fillRunlevelScript else # load module manuall vmware_kind_path=/opt/openslx/plugin-repo/vmware/\${vmware_kind}/ - module_src_path=\${vmware_kind_path}/root/lib/vmware/modules/source - insmod \${module_src_path}/vmblock.o - insmod \${module_src_path}/vmmon.o - insmod \${module_src_path}/vmnet.o + module_src_path=\${vmware_kind_path}/vmroot/modules + insmod \${module_src_path}/vmblock.ko + insmod \${module_src_path}/vmmon.ko + insmod \${module_src_path}/vmnet.ko fi } unload_modules() { diff --git a/os-plugins/plugins/vmware/OpenSLX/Distro/Debian.pm b/os-plugins/plugins/vmware/OpenSLX/Distro/Debian.pm index e1c7e2e4..90a5de85 100644 --- a/os-plugins/plugins/vmware/OpenSLX/Distro/Debian.pm +++ b/os-plugins/plugins/vmware/OpenSLX/Distro/Debian.pm @@ -60,10 +60,10 @@ sub fillRunlevelScript else # load module manuall vmware_kind_path=/opt/openslx/plugin-repo/vmware/\${vmware_kind}/ - module_src_path=\${vmware_kind_path}/root/lib/vmware/modules/source - insmod \${module_src_path}/vmblock.o - insmod \${module_src_path}/vmmon.o - insmod \${module_src_path}/vmnet.o + module_src_path=\${vmware_kind_path}/vmroot/modules + insmod \${module_src_path}/vmblock.ko + insmod \${module_src_path}/vmmon.ko + insmod \${module_src_path}/vmnet.ko fi } unload_modules() { diff --git a/os-plugins/plugins/vmware/OpenSLX/Distro/Gentoo.pm b/os-plugins/plugins/vmware/OpenSLX/Distro/Gentoo.pm index cac593df..f3ded970 100644 --- a/os-plugins/plugins/vmware/OpenSLX/Distro/Gentoo.pm +++ b/os-plugins/plugins/vmware/OpenSLX/Distro/Gentoo.pm @@ -56,10 +56,10 @@ sub fillRunlevelScript else # load module manuall vmware_kind_path=/opt/openslx/plugin-repo/vmware/\${vmware_kind}/ - module_src_path=\${vmware_kind_path}/root/lib/vmware/modules/source - insmod \${module_src_path}/vmblock.o - insmod \${module_src_path}/vmmon.o - insmod \${module_src_path}/vmnet.o + module_src_path=\${vmware_kind_path}/vmroot/modules + insmod \${module_src_path}/vmblock.ko + insmod \${module_src_path}/vmmon.ko + insmod \${module_src_path}/vmnet.ko fi } unload_modules() { diff --git a/os-plugins/plugins/vmware/OpenSLX/Distro/Suse.pm b/os-plugins/plugins/vmware/OpenSLX/Distro/Suse.pm index 08a64055..a6f2dc03 100644 --- a/os-plugins/plugins/vmware/OpenSLX/Distro/Suse.pm +++ b/os-plugins/plugins/vmware/OpenSLX/Distro/Suse.pm @@ -61,10 +61,10 @@ sub fillRunlevelScript else # load module manuall vmware_kind_path=/opt/openslx/plugin-repo/vmware/\${vmware_kind}/ - module_src_path=\${vmware_kind_path}/root/lib/vmware/modules/source - insmod \${module_src_path}/vmblock.o - insmod \${module_src_path}/vmmon.o - insmod \${module_src_path}/vmnet.o + module_src_path=\${vmware_kind_path}/vmroot/modules + insmod \${module_src_path}/vmblock.ko + insmod \${module_src_path}/vmmon.ko + insmod \${module_src_path}/vmnet.ko fi } unload_modules() { diff --git a/os-plugins/plugins/vmware/OpenSLX/OSPlugin/vmware.pm b/os-plugins/plugins/vmware/OpenSLX/OSPlugin/vmware.pm index 80215b72..e90abe60 100644 --- a/os-plugins/plugins/vmware/OpenSLX/OSPlugin/vmware.pm +++ b/os-plugins/plugins/vmware/OpenSLX/OSPlugin/vmware.pm @@ -455,7 +455,7 @@ sub _vmpl2Installation { ## Copy needed files # copy 'normal' needed files - my @files = qw( nvram.5.0 install-vmpl2.0.sh ); + my @files = qw( nvram.5.0 install-vmpl.sh ); foreach my $file (@files) { copyFile("$pluginFilesPath/$file", "$installationPath"); } @@ -464,7 +464,7 @@ sub _vmpl2Installation { ## ## Download and install the binarys - system("/bin/sh /opt/openslx/plugin-repo/$self->{'name'}/$kind/install-$kind.sh"); + system("/bin/sh /opt/openslx/plugin-repo/$self->{'name'}/$kind/install-vmpl.sh $kind"); ## ## Create runlevel script @@ -501,7 +501,7 @@ sub _vmpl1Installation { ## Copy needed files # copy 'normal' needed files - my @files = qw( nvram.5.0 install-vmpl1.0.sh ); + my @files = qw( nvram.5.0 install-vmpl.sh ); foreach my $file (@files) { copyFile("$pluginFilesPath/$file", "$installationPath"); } @@ -510,7 +510,7 @@ sub _vmpl1Installation { ## ## Download and install the binarys - system("/bin/sh /opt/openslx/plugin-repo/$self->{'name'}/$kind/install-$kind.sh"); + system("/bin/sh /opt/openslx/plugin-repo/$self->{'name'}/$kind/install-vmpl.sh $kind"); ## ## Create runlevel script diff --git a/os-plugins/plugins/vmware/files/install-vmpl.sh b/os-plugins/plugins/vmware/files/install-vmpl.sh new file mode 100644 index 00000000..473bb507 --- /dev/null +++ b/os-plugins/plugins/vmware/files/install-vmpl.sh @@ -0,0 +1,122 @@ +#!/bin/sh + +vmplversion="vmpl1.0" +url=http://download3.vmware.com/software/vmplayer/VMware-player-2.0.4-93057.i386.tar.gz + +echo "This script will download and install vmplayer from http://www.vmware.com/" +echo "Please go to http://vmware.com/download/player/player_reg.html" +echo "and ..." +echo " * complete this registration form" +echo " * click on \"Download Now\"" +echo " * read and decide if you want to accept the VMware master end user license agreement" +echo +echo "If you have done this and accepted the enduser licence type in yes in uppercase." +echo "This will install vmplayer on your vendor-os. If you don't agree this license" +echo "vmplayer won't be installed." +echo +read +echo + +if [ "${REPLY}" == "YES" ]; then + + echo " * Downloading vmplayer as ${vmplversion} now. This may take a while" + cd /opt/openslx/plugin-repo/vmware/${vmplversion} + wget -c ${url} + + echo " * Unpacking vmplayer" + tar xfz VMware-player-2.0.4-93057.i386.tar.gz + + # reduce some errors + echo " * deleting old files if available" + rm -rf vmroot + + echo " * copying files..." + mkdir vmroot + mkdir -p vmroot/modules + mkdir -p vmroot/lib + mv vmware-player-distrib/lib vmroot/lib/vmware + mv vmware-player-distrib/bin vmroot/ + mv vmware-player-distrib/sbin vmroot/ + mv vmware-player-distrib/doc vmroot/ + rm -rf vmware-player-distrib/ + + # I don't want to understand what vmware is doing, but without this + # step we need to have LD_LIBRARY_PATH with 53 entrys. welcome to + # library hell + echo " * fixing librarys..." + cd vmroot/lib/vmware/lib + mkdir test + mv lib* test + mv test/lib*/* . + cd ../../../.. + + echo " * Fixing file permission" + chmod 04555 vmroot/lib/vmware/bin/vmware-vmx + + echo " * fixing gdk and pango config files" + sed -i \ + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/gtk-2.0/gdk-pixbuf.loaders + sed -i \ + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/gtk-2.0/gtk.immodules + sed -i \ + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/pango/pango.modules + sed -i \ + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/pango/pangorc + sed -i \ + 's,/etc/pango/pango/,/etc/pango/,' \ + vmroot/lib/vmware/libconf/etc/pango/pangorc + + echo " * creating /etc/vmware" + mkdir -p /etc/vmware + + echo " * unpacking kernel modules" + cd vmroot/lib/vmware/modules/source + tar xf vmnet.tar + tar xf vmmon.tar + tar xf vmblock.tar + + echo " * building vmblock module" + cd vmblock-only/ + # TODO: check if /boot/vmlinuz is available if we get the kernel version this way + # perhaps we don't need a check... perhaps openslx always use + # /boot/vmlinuz + # This problem happens 3 times. see below! + # TODO: error check if build environment isn't installed... + sed -i "s%^VM_UNAME = .*%VM_UNAME = $(ls /boot/vmlinuz*|grep -v -e "^/boot/vmlinuz$$"|sed 's,/boot/vmlinuz-,,'|sort|tail -n 1)%" Makefile + make -s + cp vmblock.ko ../../../../../../modules + cp vmblock.o ../../../../../../modules + cd .. + + echo " * building vmmon module" + cd vmmon-only + sed -i "s%^VM_UNAME = .*%VM_UNAME = $(ls /boot/vmlinuz*|grep -v -e "^/boot/vmlinuz$$"|sed 's,/boot/vmlinuz-,,'|sort|tail -n 1)%" Makefile + make -s + cp vmmon.ko ../../../../../../modules + cp vmmon.o ../../../../../../modules + cd .. + + echo " * building vmnet module" + cd vmnet-only + sed -i "s%^VM_UNAME = .*%VM_UNAME = $(ls /boot/vmlinuz*|grep -v -e "^/boot/vmlinuz$$"|sed 's,/boot/vmlinuz-,,'|sort|tail -n 1)%" Makefile + make -s + cp vmnet.ko ../../../../../../modules + cp vmnet.o ../../../../../../modules + cd ../../../../../.. + + echo " * setting up EULA" + mv vmroot/doc/EULA vmroot/lib/vmware/share/EULA.txt + + # TODO: remove. just for debug reasons + #echo "Press any return to process" + #read + + echo " * finishing installation" + +else + echo "You didnt't accept the end user license. vmplayer is not installed." +fi diff --git a/os-plugins/plugins/vmware/files/install-vmpl1.0.sh b/os-plugins/plugins/vmware/files/install-vmpl1.0.sh index 01b0cd1d..6557aaf8 100644 --- a/os-plugins/plugins/vmware/files/install-vmpl1.0.sh +++ b/os-plugins/plugins/vmware/files/install-vmpl1.0.sh @@ -1,7 +1,14 @@ #!/bin/sh -vmplversion="vmpl1.0" -url=http://download3.vmware.com/software/vmplayer/VMware-player-2.0.4-93057.i386.tar.gz +if [ $1 = "vmpl1.0" ]; then + vmplversion="vmpl1.0" + url=http://download3.vmware.com/software/vmplayer/VMware-player-2.0.4-93057.i386.tar.gz + tgzfile=VMware-player-2.0.4-93057.i386.tar.gz +else if [ $1 = "vmpl2.0" ]; then + vmplversion="vmpl2.0" + url=http://download3.vmware.com/software/vmplayer/VMware-player-2.0.4-93057.i386.tar.gz + tgzfile=VMware-player-2.0.4-93057.i386.tar.gz +fi echo "This script will download and install vmplayer from http://www.vmware.com/" echo "Please go to http://vmware.com/download/player/player_reg.html" @@ -23,27 +30,27 @@ if [ "${REPLY}" == "YES" ]; then cd /opt/openslx/plugin-repo/vmware/${vmplversion} wget -c ${url} - echo " * Unpacking vmplayer" - tar xfz VMware-player-2.0.4-93057.i386.tar.gz + echo " * Unpacking vmplayer $vmpl{version}" + tar xfz ${tgzfile} # reduce some errors echo " * deleting old files if available" - rm -rf root + rm -rf vmroot echo " * copying files..." - mkdir root - mkdir -p root/lib - mv vmware-player-distrib/lib root/lib/vmware - mv vmware-player-distrib/bin root/ - mv vmware-player-distrib/sbin root/ - mv vmware-player-distrib/doc root/ + mkdir vmroot + mkdir -p vmroot/lib + mv vmware-player-distrib/lib vmroot/lib/vmware + mv vmware-player-distrib/bin vmroot/ + mv vmware-player-distrib/sbin vmroot/ + mv vmware-player-distrib/doc vmroot/ rm -rf vmware-player-distrib/ # I don't want to understand what vmware is doing, but without this # step we need to have LD_LIBRARY_PATH with 53 entrys. welcome to # library hell echo " * fixing librarys..." - cd root/lib/vmware/lib + cd vmroot/lib/vmware/lib mkdir test mv lib* test mv test/lib*/* . @@ -51,26 +58,26 @@ if [ "${REPLY}" == "YES" ]; then echo " * fixing gdk and pango config files" sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/gtk-2.0/gdk-pixbuf.loaders + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/gtk-2.0/gdk-pixbuf.loaders sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/gtk-2.0/gtk.immodules + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/gtk-2.0/gtk.immodules sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/pango/pango.modules + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/pango/pango.modules sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/pango/pangorc + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/${vmplversion}/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/pango/pangorc sed -i \ 's,/etc/pango/pango/,/etc/pango/,' \ - root/lib/vmware/libconf/etc/pango/pangorc + vmroot/lib/vmware/libconf/etc/pango/pangorc echo " * creating /etc/vmware" mkdir -p /etc/vmware echo " * unpacking kernel modules" - cd root/lib/vmware/modules/source + cd vmroot/lib/vmware/modules/source tar xf vmnet.tar tar xf vmmon.tar tar xf vmblock.tar @@ -99,7 +106,7 @@ if [ "${REPLY}" == "YES" ]; then cd ../../../../../.. echo " * setting up EULA" - mv root/doc/EULA root/lib/vmware/share/EULA.txt + mv vmroot/doc/EULA vmroot/lib/vmware/share/EULA.txt # TODO: remove. just for debug reasons #echo "Press any return to process" diff --git a/os-plugins/plugins/vmware/files/install-vmpl2.0.sh b/os-plugins/plugins/vmware/files/install-vmpl2.0.sh index 37aa2ea4..a0776ac8 100644 --- a/os-plugins/plugins/vmware/files/install-vmpl2.0.sh +++ b/os-plugins/plugins/vmware/files/install-vmpl2.0.sh @@ -25,52 +25,52 @@ if [ "${REPLY}" == "YES" ]; then #reduce some errors echo " * removeing old files" - rm -rf root + rm -rf vmroot echo " * copying files..." - mkdir root - mkdir -p root/lib - mv vmware-player-distrib/lib root/lib/vmware - mv vmware-player-distrib/bin root/ - mv vmware-player-distrib/sbin root/ - mv vmware-player-distrib/doc root/ + mkdir vmroot + mkdir -p vmroot/lib + mv vmware-player-distrib/lib vmroot/lib/vmware + mv vmware-player-distrib/bin vmroot/ + mv vmware-player-distrib/sbin vmroot/ + mv vmware-player-distrib/doc vmroot/ rm -rf vmware-player-distrib/ # I don't want to understand what vmware is doing, but without this # step we need to have LD_LIBRARY_PATH with 53 entrys. welcome to # library hell echo " * fixing librarys..." - cd root/lib/vmware/lib + cd vmroot/lib/vmware/lib mkdir test mv lib* test mv test/lib*/* . cd ../../../.. echo " * changing file permission" - chmod 04755 root/lib/vmware/bin/vmware-vmx + chmod 04555 vmroot/lib/vmware/bin/vmware-vmx echo " * fixing gdk and pango config files" sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/gtk-2.0/gdk-pixbuf.loaders + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/gtk-2.0/gdk-pixbuf.loaders sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/gtk-2.0/gtk.immodules + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/gtk-2.0/gtk.immodules sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/pango/pango.modules + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/pango/pango.modules sed -i \ - 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/root/lib/vmware/libconf,' \ - root/lib/vmware/libconf/etc/pango/pangorc + 's,/build/mts/.*/vmui/../libdir/libconf,/opt/openslx/plugin-repo/vmware/vmpl2.0/vmroot/lib/vmware/libconf,' \ + vmroot/lib/vmware/libconf/etc/pango/pangorc sed -i \ 's,/etc/pango/pango/,/etc/pango/,' \ - root/lib/vmware/libconf/etc/pango/pangorc + vmroot/lib/vmware/libconf/etc/pango/pangorc echo " * creating /etc/vmware" mkdir -p /etc/vmware echo " * unpacking kernel modules" - cd root/lib/vmware/modules/source + cd vmroot/lib/vmware/modules/source tar xf vmnet.tar tar xf vmmon.tar tar xf vmblock.tar @@ -99,7 +99,7 @@ if [ "${REPLY}" == "YES" ]; then cd ../../../../../.. echo " * setting up EULA" - mv root/doc/EULA root/lib/vmware/share/EULA.txt + mv vmroot/doc/EULA vmroot/lib/vmware/share/EULA.txt # TODO: remove. just for debug reasons #echo "Press any return to process" |