Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Sat 25 Oct 2014, 07:37
All times are UTC - 4
 Forum index » House Training » Users ( For the regulars ) » Usuarios de habla Hispana
instalar libreoffice 3.5.2
Moderators: rarsa
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
Page 1 of 1 Posts_count  
Author Message
sagagal

Joined: 25 Apr 2012
Posts: 8

PostPosted: Sun 29 Apr 2012, 03:02    Post_subject:  instalar libreoffice 3.5.2
Sub_title: instalar libreoffice 3.5.2 desde 3.3.1
 

¡ Hola amig@s!

Tengo instalado Libre Office 3.3.1 en Puppy Lucid 5.2.8. He descargado la versión 3.5.2 de Office. Siguiendo las instrucciones de instalación, he ejecutado dpkg -i *.deb desde el directorio DEBS pero me aparece este mensaje:
dpkg: package libobasis3.5-en-us-math depends on libobasis3.5-en-US, which is not installed or flagged to be installed
Con lo que no he podido seguir la instalación.

¿Alguien me puede echar una manita para realizar esta instalación?
Back to top
View user's profile Send_private_message 
josejp2424

Joined: 01 Aug 2010
Posts: 221

PostPosted: Mon 30 Apr 2012, 10:45    Post_subject:  

este script te descarga e instala libreoffice. ya esta disponible en los ultimo puppy 5.28.

dale enter y listo. yo descargue la 3.5.2
http://dl.dropbox.com/u/36940871/get_libreoffice[/url]
Back to top
View user's profile Send_private_message Visit_website 
sagagal

Joined: 25 Apr 2012
Posts: 8

PostPosted: Tue 01 May 2012, 04:52    Post_subject:  

¡¡ Gracias jose por tu respuesta !!

Soy novatiiiisiimo en linux, y más concretamente, en Puppy. Embarassed Por lo tanto, te explico lo que he hecho:

Al abrir tu enlace, me aparece una página con el código de un fichero, que supongo es el script que me comentabas. He copiado y pegado todo el código en el editor de Puppy y lo he guardado con la extensión sh. Después, en consola, y desde el directorio donde está el script, lo he intentado compilar asi:
shc -f get_libreoffice.sh
pero me sale el siguiente error:
sh: cc: command not found
No se si la estoy liando más de lo normal. No entendí bien, cuando tu dices: "Dale enter y listo.." ¿a qué te refieres?

Bueno, espero seguir recibiendo tu ayuda.

¡¡ Saludos !!
Back to top
View user's profile Send_private_message 
josejp2424

Joined: 01 Aug 2010
Posts: 221

PostPosted: Tue 01 May 2012, 11:02    Post_subject:  

no hace lo siguiente. con boton derecho mouse te saldra una vetana , anda a nuevo- elegui script. una ves que lo creaste. abrilo en modo texto (botn derecho abir como texto).
borra lo que contenga y pega esto como esta.


Code:
#!/bin/bash -a
#       This program is free software; you can redistribute it and/or modify
#       it under the terms of the GNU General Public License as published by
#       the Free Software Foundation; either version 2 of the License, or
#       (at your option) any later version.
#       
#       This program is distributed in the hope that it will be useful,
#       but WITHOUT ANY WARRANTY; without even the implied warranty of
#       MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#       GNU General Public License for more details.
#       
#       SEE /usr/share/doc/legal/
#       
#       01micko@gmail.com
#0.1 20110317 first version
#0.2 20110318 withdraw support for usb installs, bugfixes from Lobster
#0.3 20110319 update for gtkdialog-splash, relaxed some code, added bootmanager pop up
#0.4 20110319 fix size check function, check if Libre or Open office is installed and prompt to uninstall. 0.4.1 bugfix detecting if office installed
#0.5 20110321 make sfs in a term on screen to show progress, add download check, fix fg issues. Add welcome screen. Add testing repo option.
#0.6 20110406 add error check if testing version doesn't exist
#0.7 20110607 fix for new versions
#0.8 20110911 add support for FD64 and LHP64 TODO, fix gettext
#0.9 20110917 fixed bug with extra packs, fix gettext, added "_Extra" appended to name if extras are chosen
#0.10 20110918 take 2 fixing extras bug, en-US bug

MYPATH=$0
MYNAME=$(basename "$0")     
VERSION=0.10
export TEXTDOMAIN=get_libreoffice
export OUTPUT_CHARSET=UTF-8
#eval_gettext() {
#  local myMESSAGE=$(gettext "$1")
#  eval echo \"$myMESSAGE\"
#}
TITLE="Get LibreOffice"
DESCRIPTION=$(gettext "download libreoffice and make sfs")
LONG_TITLE="$TITLE $DESCRIPTION $VERSION"

#Welcome message
TXT1=$(gettext "Welcome to the LibreOffice Installer \n\nThis will download the Deb files from the LibreOffice server, \nas well as your locale files (optional), unpack them and \nconvert them to the Puppy Squash File System (sfs). This is \nover 150MB download and can take a long time on a slow \nconnection. The conversion to sfs can take a long time on \nslow machines. \n\nDo you want to continue?")
YESLABEL=$(gettext "Yes")
Xdialog --title "$LONG_TITLE" --ok-label "$YESLABEL" --yesno "$TXT1" 0 0 0
RETVAL1="$?"
case $RETVAL1 in
0) echo ok ;;
1) exit ;;
255) exit ;;
esac
#choose stable or testing
TXT2=$(gettext "Please choose whether you want the latest stable or the testing version")
TXT2a=$(gettext "Please note that testing version is not always updated, recommend stable")
OKLABEL=$(gettext "Stable")
NOLABEL=$(gettext "Testing")
Xdialog --title "LibreOffice" --ok-label "$OKLABEL" --cancel-label "$NOLABEL" --yesno "$TXT2 \n$TXT2a" 0 0 0
RETVAL2="$?"
case $RETVAL2 in
0) STABILITY="stable" ;;
1) STABILITY="testing" ;;
255) exit ;;
esac
#set -x
#set check boxes
CHKBOX0=true #> /tmp/libre_check
CHKBOX1=true #>> /tmp/libre_check
#[ "`echo $LANG`|head -c5`" = "en_US" ] && CHKBOX1=false||CHKBOX1=true #insurance
#get pupmode
. /etc/rc.d/PUPSTATE
INFOMSG1=$(gettext "Please wait a moment")
gtkdialog-splash  -close never -icon /usr/share/pixmaps/throbber.gif -bg green -text "$INFOMSG1" &
sleep 1
#check if we have libreoffice or openoffice installed and if so abort
if [ -x /opt/libreoffice/program/soffice ];then
 ALERTMSGa=$(gettext "You already have an installation of LibreOffice. Please unload it from the Bootmanager or if a full install, uninstall with PPM before you proceed to install this version of LibreOffice")
 killall yaf-splash && gtkdialog-splash -icon gtk-dialog-warning -deco "Libreoffice Download" -bg thistle -close never -text "$ALERTMSGa"
 exit
 elif [ -x /opt/openoffice.org3/program/soffice ];then
 ALERTMSGb=$(gettext "You have an installation of OpenOffice. Please unload it from the Bootmanager or if a full install, uninstall with PPM before you proceed to install LibreOffice")
 killall yaf-splash && gtkdialog-splash -icon gtk-dialog-warning -deco "Libreoffice Download" -bg thistle -close never -text "$ALERTMSGb"
 exit
fi
#checkbox state for locale
USELANG=`echo $LANG|head -c5`
#sort out localisation
case $USELANG in
en_GB|en_AU|en_DK|en_NZ|en_HK|en_IN|en_SG|en_IE)
LANGUAGE="en-GB" ;;
en_ZA)
LANGUAGE="en-ZA" ;;
en_US)
LANGUAGE="en-US" ;;
ca_ES|ca_IT|ca_FR|ca_AD)
Xdialog -yesno "¿Requereixen Valenciana?" 0 0 0  #*special case for libreoffice
 case $? in
 0)LANGUAGE="ca-XV" ;;
 1)LANGUAGE="ca" ;;
 255)LANGUAGE="ca" ;;
 esac ;;
be_BY)
LANGUAGE="be-BY" ;;
pa_IN)
LANGUAGE="pa-IN" ;;
pt_BR)
LANGUAGE="pt-BR" ;;
mai_I)
LANGUAGE="mai-IN" ;;
sa_IN)
LANGUAGE="sa-IN" ;;
zh_CN|ah_SG|zh_HK)
LANGUAGE="zh-CN" ;;
zh_TW)
LANGUAGE="zh-TW" ;;
*)LANGUAGE=`echo $LANG|cut -d '_' -f1` ;; #will get libre locale code, mostly first 2 letters of locale code
esac
#special case for chkbox1
CBLANG="$LANGUAGE"
#disable langpack checkbox for US
echo $LANGUAGE
if [ "$LANGUAGE" = "en-US" ];then
 STATE="disabled"
 CHKBOX1=false
 else
 STATE="enabled"
fi

#size check function
SFSSIZEEXPANDED=750000 #approx size needed to expand libreoffice and recompress in KB
HOMESAVE=`echo $PUPSAVE|cut -d ',' -f1`
sizecheck(){ #Check if we have space to convert the libo debs to an sfs
   #only supports fast partitions
   case $PUPMODE in
   12|6)FREESIZEAVAIL=`df -k|grep $HOMESAVE|awk '{print $4}'`
   ERRMSG1=$(gettext "Sorry, you don't have the space to construct a libreoffice sfs")
   if [[ $FREESIZEAVAIL -lt $SFSSIZEEXPANDED ]];then killall yaf-splash && Xdialog --timeout 5 -msgbox "$ERRMSG1" 0 0 0
   exit
   fi
   BASEDIR="/initrd$PUP_HOME"
   ;;
   2|3)FREESIZEAVAIL=`df -k |  grep '/dev/root' | tr -s ' '| cut -f4 -d ' '`
   ERRMSG2=$(gettext "Sorry, you don't have the space to install libreoffice")
   if [[ $FREESIZEAVAIL -lt $SFSSIZEEXPANDED ]];then killall yaf-splash && Xdialog --timeout 5 -msgbox "$ERRMSG2" 0 0 0
   exit
   fi
   BASEDIR="/"
   ;;
   *)ERRMSG2c=$(gettext "USB and DVD installs are unsupported, Sorry")
   killall yaf-splash && Xdialog --timeout 5 -msgbox "$ERRMSG2c" 0 0 0
   exit
   ;;
   esac
}

sizecheck

#size check passed so we create working dirs
[ -d $BASEDIR/libre_download ] && rm -rf $BASEDIR/libre_download #in case we had previous failure
mkdir $BASEDIR/libre_download
DLDIR="$BASEDIR/libre_download"   
#probe server
#Interesting note that this server does not like being probed too much. The idea was to put more rigorous code
#in here but it resulted in too many "download failed" messages
####http://download.documentfoundation.org/libreoffice/ base uri
#get the database (current version, lanpack info, helpack info)
#ARCH="x86" #edit this if you have 64 bit arch, no doesn't work
GETARCH="`uname -m`"
case $GETARCH in
i486|i586|i686) ARCH="x86" ; DIRARCH="x86" ;;
*) ARCH="x86-64" ; DIRARCH="x86_64" ;;
esac
LIBO_URI="http://download.documentfoundation.org/libreoffice/$STABILITY"     #eg /3.3.1/deb/x86/"
CNT=0
until [ -f /tmp/index.html ] || [ $CNT = 5 ]; do
 wget -t0 -T5 -4 -q -P /tmp ${LIBO_URI}
 sleep 0.5
 CNT=`expr $CNT + 1`
 done
#LIBO_VER_DIR=`grep "/icons/folder.gif"  /tmp/index.html|cut -d '>' -f7|cut -d '/' -f1`
#ok, this is the danger with an app like this. The server has changed format of the pages!
#get version
#LIBO_VER_DIR=`grep [0-9] /tmp/index.html|grep '\.'|grep -v "html"|head -n1|cut -d '>' -f6|cut -d '/' -f1`
LIBO_VER_DIR=`grep [0-9] /tmp/index.html|grep '\.'|grep -v "html"|head -n2|cut -d '>' -f6|cut -d '/' -f1`
if [ "`echo $LIBO_VER_DIR|cut -d ' ' -f2`" != "" ];then
   LIBOVER1=`echo $LIBO_VER_DIR|cut -d ' ' -f1`
   LIBOVER2=`echo $LIBO_VER_DIR|cut -d ' ' -f2`
   Xdialog --title "choose version" --ok-label "$LIBOVER1" --cancel-label "$LIBOVER2" --yesno "There are 2 versions available, \nchoose the one you want" 0 0 0
   case $? in
   0)LIBO_VER_DIR="$LIBOVER1"
   gtkdialog-splash -bg green -timeout 2 -text "$LIBOVER1 chosen" ;;
   *)LIBO_VER_DIR="$LIBOVER2"
   gtkdialog-splash -bg green -timeout 2 -text "$LIBOVER2 chosen" ;;
   esac
    else
   LIBO_VER_DIR="`echo $LIBO_VER_DIR|head -n1`"
fi
if [ "`echo $LIBO_VER_DIR|grep '\-'`" != "" ];then LIBO_VER=`echo "$LIBO_VER_DIR"|sed 's/\-//'`
 else LIBO_VER="$LIBO_VER_DIR"
fi
rm -f /tmp/index.html
#echo $LIBO_VER_DIR > /tmp/libo_version
BADMSG1=$(gettext "Unable to get the version information. If you selected the testing version then it is likely that the testing version is unavailable. Try the stable version.")
BADMSG2=$(gettext "Unable to get the version information. It is possible that the LibreOffice servers are too busy, please try again later.")
if [ "$STABILITY" = "testing" ];then
  if [ "$LIBO_VER_DIR" = "" ];then 
   killall yaf-splash && gtkdialog-splash -close box -icon gtk-dialog-error -bg hotpink -text "$BADMSG1"
   exit
  fi
 else
  if [ "$LIBO_VER_DIR" = "" ];then
   killall yaf-splash && gtkdialog-splash -close box -icon gtk-dialog-error -bg hotpink -text "$BADMSG2"
   exit
  fi
fi
#get database info
CNT=0
until [ -f /tmp/index.html ] || [ $CNT = 5 ]; do
 wget -t0 -T5 -4 -q -P /tmp ${LIBO_URI}/${LIBO_VER_DIR}/deb/${DIRARCH}/
 sleep 0.5
 CNT=`expr $CNT + 1`
 done
grep LibO /tmp/index.html|cut -d '=' -f3|cut -d '"' -f2|grep gz$ |grep -v "install" > /tmp/office_online_database_extrapacks
#grep LibO /tmp/index.html|cut -d '>' -f6|cut -d '=' -f2|grep gz\"$ |grep -v "install" > /tmp/office_online_database_extrapacks #why am I doing this?
#LIBO_EN_US=`grep LibO /tmp/index.html|cut -d '>' -f6|cut -d '=' -f2|grep "install-deb_en-US.tar.gz\"$" |grep -v "^\"LibO-SDK"|sed -e 's/\"//g'`
LIBO_EN_US=`grep LibO /tmp/index.html|cut -d '=' -f3|cut -d '"' -f2|grep gz$ |grep "install-deb_en-US.tar.gz$" |grep -v SDK`
rm -f /tmp/index.html
echo $LIBO_EN_US
ERRMSG3=$(gettext "ABORTING")
ERRMSG4=$(gettext "failed to get package info")
[ "$LIBO_EN_US" = "" ]&& killall yaf-splash && gtkdialog-splash -close box -icon gtk-dialog-error -bg red -text "**********$ERRMSG3************ $ERRMSG4" && exit

rm -f /tmp/libre_extras
#for extras fn
function chooser(){
   echo $EXTCHOICE >> /tmp/libre_extras
}
#extras function for extra languages
extras(){
   DLG7=$(gettext "Here you can chose to add some extra help and language packs. Don't add too many, as if the download breaks you will have to start again")
   DLG8=$(gettext "Choose your extras")
   DLG9=$(gettext "Check extras")
   DLG10=$(gettext "Start again")
   echo "#extras" > /tmp/libre_extras
   export EXTRAS="<window title=\"LibreOffice $DLG6\">
    <vbox>
     <hbox homogeneous=\"true\">
      <text><label>$DLG7</label></text>
     </hbox>
     <hbox height-request=\"400\">
      <tree>
        <label>$DLG8</label>
        <variable>EXTCHOICE</variable>
        <input>cat /tmp/office_online_database_extrapacks</input>
        <action signal=\"button-release-event\">chooser</action>
       </tree>
      </hbox>
      <hbox>
       <button>
        <input file stock=\"gtk-ok\"></input>
        <label>OK</label>
        <action>getlibre &</action>
        <action>exit:getlibre</action>
       </button>
       <button>
        <input file stock=\"gtk-dialog-question\"></input>
        <label>$DLG9</label>
        <action>xmessage -c -file /tmp/libre_extras</action>
       </button>
       <button>
        <input file stock=\"gtk-clear\"></input>
        <label>$DLG10</label>
        <action>rm -f /tmp/libre_extras</action>
       </button>
       <button cancel></button>
      </hbox>
     </vbox>
    </window>"
    gtkdialog3 -p EXTRAS
    unset EXTRAS
}

#download function (called from gui)
getlibre(){
   echo $CHKBOX0
   echo $CHKBOX1
   if [[ $CHKBOX0 = false && $CHKBOX1 = false ]];then LANGUAGE="en-US"
   fi
   sleep 1
   #. /tmp/libre_check
   #download error text
   ERRDLD=$(gettext "Failed to download $THISPKG. Please try again later")
   #get helppack
   HELPPACKURI="LibO_"${LIBO_VER}"_Linux_${ARCH}_helppack-deb_"
   if [ "$CHKBOX0" = "true" ];then
    TITLE1=$(gettext "Help files")
    HELPPACK="${HELPPACKURI}${LANGUAGE}.tar.gz"
    echo "rxvt -background yellow -foreground black -title \"$TITLE1\" -geometry 80x10  -e wget -t0 --waitretry=5 -4 -P $DLDIR -c ${LIBO_URI}/${LIBO_VER_DIR}/deb/${DIRARCH}/$HELPPACK" > /tmp/getlibre_help
    . /tmp/getlibre_help
    #test if we got it
    if [ ! -f $DLDIR/$HELPPACK ];then
     THISPKG=$HELPPACK
     gtkdialog-splash -bg hotpink -icon gtk-dialog-error -timeout 6 -text "$ERRDLD"
     exit
     rm -f /tmp/getlibre_help
    fi
     rm -f /tmp/getlibre_help
   fi
   #get langpack #en_US disabled
   LANGPACKURI="LibO_"${LIBO_VER}"_Linux_${ARCH}_langpack-deb_"
   if [ "$CHKBOX1" = "true" ];then
    TITLE2=$(gettext "Locale files")
    LANGPACK="${LANGPACKURI}${CBLANG}.tar.gz"
    echo "rxvt -background lightblue -foreground black -title \"$TITLE2\" -geometry 80x10  -e wget -t0 --waitretry=5 -4 -P $DLDIR -c ${LIBO_URI}/${LIBO_VER_DIR}/deb/${DIRARCH}/$LANGPACK" > /tmp/getlibre_lang
    . /tmp/getlibre_lang
    #test if we got it
    if [ ! -f $DLDIR/$LANGPACK ];then
     THISPKG=$LANGPACK
     gtkdialog-splash -bg hotpink -icon gtk-dialog-error -timeout 6 -text "$ERRDLD"
     rm -f /tmp/getlibre_lang
     LANGUAGE=$CBLANG
     exit
    fi
     #rm -f /tmp/getlibre_lang
   fi
   TITLE3=$(gettext "Downloading LibreOffice")
   echo "rxvt -background lightgreen -foreground black -title \"$TITLE3\" -geometry 80x10  -e wget -t0 --waitretry=5 -4 -P $DLDIR -c ${LIBO_URI}/${LIBO_VER_DIR}/deb/${DIRARCH}/$LIBO_EN_US" > /tmp/getlibre
    . /tmp/getlibre
    if [ ! -f $DLDIR/$LIBO_EN_US ];then
    THISPKG=$LIBO_EN_US
    gtkdialog-splash -bg hotpink -icon gtk-dialog-error -timeout 6 -text "$ERRDLD"
    rm -f /tmp/getlibre
    exit
   fi
   rm -f /tmp/getlibre
   #grab extras if chosen
   if [ -f /tmp/libre_extras ];then
    echo "ok" > /tmp/libre_xtra_for_naming
    TITLE4=$(gettext "Downloading extra packs")
     #LIST=`grep -v '#' /tmp/libre_extras`
      #X=1
      #for L in $LIST
      #do echo "rxvt -background black -foreground white -title \"$TITLE4 $X\" -geometry 80x10  -e wget -t0 --waitretry=5 -4 -P $DLDIR -c ${LIBO_URI}/${LIBO_VER_DIR}/deb/${DIRARCH}/$L" > /tmp/getlibre_extras
        #. /tmp/getlibre_extras
        #X=`expr $X + 1`
         #if [ ! -f $DLDIR/$L ];then
          #break
         #THISPKG=$L
         #gtkdialog-splash -bg hotpink -icon gtk-dialog-error -timeout 6 -text "$ERRDLD"
         #rm -f /tmp/getlibre_extras
         #exit
         #else continue 
        #fi
       #rm -f /tmp/getlibre_extras
      #done #changed 110917
      grep -v '#' /tmp/libre_extras|\
      while read LINE;
       do
        echo "rxvt -background black -foreground white -title \"$TITLE4\" -geometry 80x10  -e wget -t0 --waitretry=5 -4 -P $DLDIR -c ${LIBO_URI}/${LIBO_VER_DIR}/deb/${DIRARCH}/$LINE" > /tmp/getlibre_extra_packs
        . /tmp/getlibre_extra_packs
        if [ $? -ne 0 ];then gtkdialog-splash -bg hotpink -icon gtk-dialog-error -timeout 6 -text "$ERRDLD" && break
          else continue
        fi
      done
    fi
    ######at this stage we got everything.... unpack
    INFOMSG2a=$(gettext "Please wait while")
    INFOMSG2b=$(gettext "is unpacked and repacked into an sfs")
    gtkdialog-splash -close never -icon /usr/share/pixmaps/throbber.gif -bg yellow -text "$INFOMSG2a $LIBO_EN_US $INFOMSG2b" &
    sleep 1
    #kill `ps| grep  MAIN_DLG|grep -v "grep"|awk '{print $1}'`
    cd $DLDIR
    sleep 5
   #extract tarballs
   for I in *
    do tar -xzf $I
    rm -f $I #remove tarballs
   done
   
   sync
    sleep 1 #extracted names of dirs are not the same as name of tarball :|
    LIBO_PKGDIR=`ls -l|grep ^d| grep install|awk '{print $8}'`
    LIBO_HELPDIR=`ls -l |grep ^d| grep helppack|awk '{print $8}'`
    echo $LIBO_HELPDIR
   for h in $LIBO_HELPDIR
    do mv -f ./$h/DEBS/* $LIBO_PKGDIR/DEBS
    done
   LIBO_LANGDIR=`ls -l |grep ^d| grep langpack|awk '{print $8}'`
   for l in $LIBO_LANGDIR
    do mv -f ./$l/DEBS/* $LIBO_PKGDIR/DEBS
    done
   sync
   #[ "$LIBO_HELPDIR" != "" ] && mv -f ./$LIBO_HELPDIR/DEBS/* $LIBO_PKGDIR/DEBS
   #[ "$LIBO_LANGDIR" != "" ] && mv -f ./$LIBO_LANGDIR/DEBS/* $LIBO_PKGDIR/DEBS
   cd $LIBO_PKGDIR
   cd DEBS
   echo `pwd` #debug
   mv -f ./desktop-integration/* ./
   rm -rf ./desktop-integration
   mkdir workdir
   DIR="workdir"
   #unpack debs
       LIST=`ls|grep deb$`
      for i in $LIST;do
      ONEBINARYPKG=$i
      PKGNAME="`basename $ONEBINARYPKG .deb`" #ex: bash_3.2-4ububtu1_i386
      dpkg-deb -x $ONEBINARYPKG $DIR/
      if [ $? -ne 0 ];then
      echo "ERROR: failed to unpack $PKGNAME"
      continue
      fi
      done
    #fixup DOTdesktop files for puppy
   cd `pwd`/workdir/opt/libreoffice*/share/xdg
   rm -f javafilter.desktop
   rm -f qstart.desktop
   DESKLIST=`ls|grep desktop$`
   for j in $DESKLIST
    do
    #fix icon
    ICON=`grep -w Icon $j|cut -d '=' -f2`
    NEWICON="/usr/share/icons/hicolor/48x48/apps/${ICON}.png"
     sed -i "1,5s%$ICON%$NEWICON%" $j
     #fix category
     CATEGORY=`grep -w Categories $j|cut -d '=' -f2`
     [[ "$j" = "startcenter.desktop" || "$j" = "printeradmin.desktop" || "$j" = "writer.desktop" ]]&& NEWCATEGORY='WordProcessor;GNOME;GTK;X-Red-Hat-Base;'
     [[ "$j" = "base.desktop" || "$j" = "math.desktop" || "$j" = "calc.desktop" ]]&& NEWCATEGORY='Office;Database;Spreadsheet;Science;Math;GNOME;GTK;'
     [[ "$j" = "draw.desktop" || "$j" = "impress.desktop" ]]&& NEWCATEGORY='RasterGraphics'
     sed -i "s|Categories=$CATEGORY|Categories=$NEWCATEGORY|" $j
     #fix exec #changed 20110607
     LIBOminorver=`echo $LIBO_VER|cut -d '.' -f2` #ex if 3.4.0 is 4
     if [ $LIBOminorver -lt 4 ];then
     EXEC=`grep -w Exec $j|cut -d '=' -f2`
     EXECEXACT=`echo $EXEC|cut -d '-' -f2|cut -d ' ' -f1`
     [ "$j" = "startcenter.desktop" ]&& EXECEXACT=office
     [ "$j" = "printeradmin.desktop" ]&& EXECEXACT=padmin
     NEWEXEC="/opt/libreoffice${DIRVER}/program/s${EXECEXACT}"
     sed -i "s|Exec=$EXEC|Exec=$NEWEXEC|" $j
      else
     sed -i "s|%U||" $j
     fi
     #now say 50 Hail Mary's
    done #!
    LANGLIB="_${LANGUAGE}"
    [ "$DIRARCH" = "x86_64" ]&& LANGLIB="_64_${LANGUAGE}"
   
    killall yaf-splash
    INFOMSG3=$(gettext "Now creating")
    #using throbber in gtkdialog-splash, required a hack 20110319
    #gtkdialog-splash -close never -bg lightgreen -icon /usr/share/pixmaps/throbber.gif -text "$INFOMSG3 LibreOffice-${LIBO_VER}${LANGLIB}.sfs" &
   cd ../
   cd ../
   cd ../
   cd ../
   cd ../
   sync
   #get installed size
   #INSTALLEDSIZE=`du -s -k workdir|awk '{print $1}'`
   #echo $INSTALLEDSIZE > /tmp/libre_installed_size
   #remove invalid symlinks
   rm -f ./workdir/usr/share/applications/libreoffice-javafilter.desktop
   #woohoo, time for the business end
   #############perhaps later fork the full install here
   #make the sfs #now in a fancy terminal
   echo ${LANGLIB}
   
   if [ -f /tmp/libre_xtra_for_naming ];then EXTRA="_Extra"
    else EXTRA=""
   fi
   rm -f /tmp/libre_xtra_for_naming
   echo "rxvt -bg darkgreen -fg yellow -geometry 80x10 -title \"$INFOMSG3 LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs\" -e mksquashfs workdir LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs" > /tmp/get_libre_sfs
   . /tmp/get_libre_sfs
   rm -f /tmp/get_libre_sfs
   sleep 1
   sync
   #sanity check
   INFOMESSAGE4a=$(gettext "Sorry, constructing")
   INFOMESSAGE4b=$(gettext "has failed")
   #check it made ok
   if [ ! -f LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs ];then
    gtkdialog-splash -timeout 5 -close box -icon gtk-dialog-warning -bg red -text "$INFOMESSAGE4a LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs $INFOMESSAGE4b" && exit
   cd $BASEDIR
   rm -rf $DLDIR #remove on failure
   fi
   #doublecheck
   SFSSIZE=`stat -c %s LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs`
   if [[ $SFSSIZE -lt 140000000 ]];then
   #there is no way to calculate exact size (that I know of) of sfs before construction.
   #140000000 assumes that "we got this far, surely we'll make it now!"
    gtkdialog-splash -timeout 5 -close box -icon gtk-dialog-warning -bg red -text "$INFOMESSAGE4a LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs $INFOMESSAGE4b" && exit
   cd $BASEDIR
   rm -rf $DLDIR #remove on failure
   fi
   #ok above 2 checks ok we announce success
   INFOMESSAGE5a=$(gettext "Success")
   INFOMESSAGE5b=$(gettext "has been created")
    gtkdialog-splash -timeout 5 -close box -bg green -icon gtk-apply -text "$INFOMESSAGE5a ... LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs $INFOMESSAGE5b"
   #move to /mnt/home or '/'
   mv -f LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs $BASEDIR
   sync
   cd $HOME
   #cleanup
   rm -rf $DLDIR
   sync
   #loading options
   if [ -x /usr/sbin/sfs_load ];then
    sfs_load LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs #use shino's sfs_load first if there
    exit
   fi
   if [ -x /usr/sbin/sfs_installation.sh ];then
    sfs_installation.sh $BASEDIR/LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs #use my sfs_installation if there
    exit
    #neither there then use traditional method
    else
     if [[ $PUPMODE = 2 ]];then
       killall yaf-splash && gtkdialog-splash -timeout 5 -close box -bg -icon gtk-dialog-info lightgreen -text "you must now unpack the sfs to install, this will be addressed soon"
      else
       INFOMSG6a=$(gettext "You can now load")
       INFOMSG6b=$(gettext "from the Bootmanager Utility")
       killall yaf-splash && gtkdialog-splash -timeout 5 -close box -bg -icon gtk-dialog-info lightgreen -text "$INFOMSG6a  LibreOffice-${LIBO_VER}${LANGLIB}${EXTRA}.sfs $INFOMSG6b"
       #pop up bootmanager
       bootmanager extrasfs quiet
     fi
    exit
   fi
   
}

#kill splash
killall yaf-splash
#GUI
#. /tmp/libre_check
DLG1=$(gettext "Welcome to the Libre Office Installer")
DLG2=$(gettext "needs to be downloaded anyway. You can choose to download the help files and your language pack")
DLG3=$(gettext "Current locale:")
DLG4=$(gettext "Help file")
DLG5=$(gettext "Language pack")
DLG6=$(gettext "Extras")
export MAIN_DLG="<window title=\"$TITLE $VERSION\">
 <vbox>
   <pixmap>
    <input file>/usr/share/pixmaps/libreoffice-main.png</input>
   </pixmap>
  <hbox homogeneous=\"true\">
   <text><label>$DLG1</label></text>
  </hbox>
  <hbox homogeneous=\"true\">
   <text use-markup=\"true\"><label>\"<b>$LIBO_EN_US</b>\"</label></text>
  </hbox>
  <hbox homogeneous=\"true\">
   <text><label>$DLG2</label></text>
  </hbox>
  <hbox homogeneous=\"true\">
   <text use-markup=\"true\"><label>\"<b>$DLG3 $LANG</b>\"</label></text>
  </hbox>
   <checkbox>
    <label>$DLG4</label>
    <variable>CHKBOX0</variable>
    <default>$CHKBOX0</default>
   </checkbox>
   <checkbox>
    <label>$DLG5 $LANGUAGE</label>
    <variable>CHKBOX1</variable>
    <default>$CHKBOX1</default>
    <visible>$STATE</visible>
   </checkbox>
  <hbox>
   <button>
    <input file stock=\"gtk-ok\"></input>
    <label>OK</label>
    <action>getlibre &</action>
    <action>export $CHKBOX0</action>
    <action>export $CHKBOX1</action>
    <action>exit:getlibre</action>
   </button>
   <button>
    <input file stock=\"gtk-add\"></input>
    <label>$DLG6</label>
    <action>extras &</action>
    <action>export $CHKBOX0</action>
    <action>export $CHKBOX1</action>
    <action>exit:extra</action>
   </button>
   <button cancel></button>
  </hbox>
 </vbox>
</window>"
gtkdialog3 -p MAIN_DLG


unset MAIN_DLG
 
#END




.pone guardar. dale click con el mouse y listo.

mi blog.

http://www.puppylinuxjosejp2424.com/
Back to top
View user's profile Send_private_message Visit_website 
sagagal

Joined: 25 Apr 2012
Posts: 8

PostPosted: Tue 08 May 2012, 10:58    Post_subject:  

¡Hola Josejp !

Después de varios intentos, tengo instalada la versión Puppy Night 5.2.8 en un USB. Al ejecutar tu script, me dice el siguiente mensaje:

USB and DVD installs are unsupported, Sorry !!

¿Qulere esto decir que este script no funciona para instalaciones de puppy en USB, como es mi caso ? ¿Se puede modificar el script para que corra en un pendrive USB ?

¡¡¡ Saludos !!!!

P.D.- Tienes un blog muyyy interesante Wink
Back to top
View user's profile Send_private_message 
Display_posts:   Sort by:   
Page 1 of 1 Posts_count  
Post_new_topic   Reply_to_topic View_previous_topic :: View_next_topic
 Forum index » House Training » Users ( For the regulars ) » Usuarios de habla Hispana
Jump to:  

Rules_post_cannot
Rules_reply_cannot
Rules_edit_cannot
Rules_delete_cannot
Rules_vote_cannot
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.1472s ][ Queries: 12 (0.0042s) ][ GZIP on ]