Author: Paul_R Date: 2008-09-08 15:07:48 +0200 (Mon, 08 Sep 2008) New Revision: 1829
Modified: software_suite_v2/tuxware/installers/unix/trunk/Installer.sh Log: * Improved the JRE installation : Now, I check the version of the installed JRE, and install it if the version is less than 1.6 * Fixed the control center dependencies * Added the initialization scripts * Typo Modified: software_suite_v2/tuxware/installers/unix/trunk/Installer.sh =================================================================== --- software_suite_v2/tuxware/installers/unix/trunk/Installer.sh 2008-09-07 10:29:34 UTC (rev 1828) +++ software_suite_v2/tuxware/installers/unix/trunk/Installer.sh 2008-09-08 13:07:48 UTC (rev 1829) @@ -19,11 +19,12 @@ ACAP_SHARED_URL=http://www.kysoh.com/download/installers/unix32/acapela_shared_libraries PYTHON_API_URL=http://www.kysoh.com/download/installers/unix32/python_tuxisalive CONTROL_CENTER_URL=http://www.kysoh.com/download/applications/linux/control_center -JDIC_URL=https://jdic.dev.java.net/files/documents/880/98881/jdic-0.9.5-bin-cross-platform.zip VOICES_URL=http://www.kysoh.com/download/resources/tts_voices/tarball JRE_URL=http://www.kysoh.com/download/installers/unix32/jre GADGET_URL=http://www.kysoh.com/download/gadgets TOOLS_URL=http://www.kysoh.com/download/installers/unix32/misc +CC_DEP_URL=http://www.kysoh.com/download/installers/unix32/deps +INIT_URL=http://www.kysoh.com/download/installers/unix32/init FIRMWARE_DIR=/opt/tuxdroid/firmware SERVER_DIR=/opt/tuxdroid/tuxhttpserver @@ -142,8 +143,9 @@ downloadControlCenter downloadControlCenterDep downloadVoices - downloadJre + testJre createExec + installInit clearTemp } @@ -199,7 +201,7 @@ printf "Downloading server $BUSY" installFile $SERVER_URL printf "$DONE" - printf "Download shared libraries " + printf "Downloading shared libraries $BUSY" installFile $ACAP_SHARED_URL printf "$DONE" } @@ -252,11 +254,8 @@ # Download jdic ## downloadControlCenterDep () { - printf "Download Control Center dependencies $BUSY" - wget -q $JDIC_URL - unzip jdic-0.9.5-bin-cross-platform.zip>/dev/null - cp -rf jdic-0.9.5-bin-cross-platform/* $CONTROL_CENTER_DIR - rm -rf jdic* + printf "Downloading Control Center dependencies $BUSY" + installFile $CC_DEP_URL printf "$DONE" } @@ -300,25 +299,35 @@ } -downloadJre () { - java -version 2>/dev/null +testJre () { + java -version 2>version>version if [ $? != 0 ] then - printf "Downloading JRE $BUSY" - wget -q $JRE_URL/version.txt - FILE=`cat version.txt` - wget -q $JRE_URL/$FILE - printf "$DONE" - chmod +x $FILE - echo Installing JRE - echo You have to accept the license. - ./$FILE - rm $FILE - cp -r jre* /opt/ - ln -sf /opt/jre*/bin/* $BIN_DIR/ + installJre fi + VER=`cat version |grep java |cut -f 2 -d'"' |cut -f 2 -d "."` 1>/dev/null + if [ $VER -lt 6 ] + then + installJre + fi } +installJre () { + printf "Downloading JRE $BUSY" + wget -q $JRE_URL/version.txt + FILE=`cat version.txt` + wget -q $JRE_URL/$FILE + printf "$DONE" + chmod +x $FILE + echo Installing JRE + echo You have to accept the license. + ./$FILE + rm $FILE + rm version.txt + cp -r jre* /opt/ + ln -sf /opt/jre*/bin/* $BIN_DIR/ + printf "$DONE" +} ## # Create the executables files and symlinks ## @@ -342,6 +351,12 @@ printf "$DONE" } +installInit () { + printf "Installing initialization script $BUSY" + installFile $INIT_URL + printf "$DONE" +} + #------------------------------------------------------------------------------ ## # Update gadget - main function ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Tux-droid-svn mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/tux-droid-svn
