Autore Topic: La parola magica "Compilare" in Ubuntu server  (Letto 10439 volte)

kidy

  • Global Moderator
  • Hero Member
  • *****
  • Post: 1668
  • Kidy
    • Mostra profilo
    • E-mail
La parola magica "Compilare" in Ubuntu server
« il: Febbraio 06, 2008, 09:35:46 pm »
AIUTATEMI!!
Devo installare questo programma "wview"
Da dove comincio!!come si fa?
 :roll:
« Ultima modifica: Febbraio 09, 2008, 03:19:07 pm da DjByte »
.................\\\//..................
                / _ _ \
              (|(.)(.)|)
------.OOOo--()--oOOO.-------
Twitter: @kidysy

lukax8

  • Sr. Member
  • ****
  • Post: 636
    • MSN Messenger - lukax8@libero.it
    • Mostra profilo
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #1 il: Febbraio 06, 2008, 09:56:51 pm »
apri il file wview-User-Manual.html all'interno dell'archivio tar.gz, ci sono le istruzioni per compilare

kidy

  • Global Moderator
  • Hero Member
  • *****
  • Post: 1668
  • Kidy
    • Mostra profilo
    • E-mail
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #2 il: Febbraio 06, 2008, 10:37:16 pm »
Si ciao Luka!
Allora:qui
http://www.wviewweather.com/release-notes/wview-User-Manual.html

Credo di dover andare in Build and Install

4. Build and Install
4.1  Extract to the location [wview_bld_path] of your choosing.
         tar zxvf wview-x.y.z.tar.gz

4.2  Change directory to the wview root source directory.
         cd [wview_bld_path]

4.3  Run the configure script to create the build files for your platform.

     Note: [station_enable_str] refers to the appropriate enable string in the
           list of stations in the previous section *for your station*.

     => Possible Configuration Arguments:

     [station_enable_str] - one of:
         [none] --enable-station-vpro is default
         --enable-station-vpro
         --enable-station-wxt510
         --enable-station-sim
     
     Optional - one of:
         [none] No SQL archiving support (default)
         --enable-mysql
         --enable-pgresql

     Optional - one of:
         [none] No Wunderground/Weatherforyou support (default)
         --enable-http


     => Examples:

     [No database support (default)]
         ./configure [station_enable_str]

     [MySQL database support]
         ./configure [station_enable_str] --enable-mysql
     
     [PostgreSQL database support AND Wunderground]
         ./configure [station_enable_str] --enable-pgresql --enable-http


     => Note:

     Execute "./configure --help" to see user configurable options. Be careful
     changing any of the prefix values, this has an effect on wview
     configuration.

4.4  Build.
         make

4.5  Install.
     First become root:
         su
         [root_password]
   
     If this is a new install or you want to obtain new wview templates, images
     and config files, install binaries and create the run environment.
         make install-env
   
     Otherwise, just install new binaries.
         make install

Note: The following build targets are available:
    make                - default target builds all source
    make clean          - deletes binaries and object files
    make install        - makes "default" then installs the binaries to
                          ${prefix}/bin (usually /usr/local/bin)
    make install-env    - builds "install" then copies example config files
                          and run environment (from .../bin) to /etc/wview
                          and /var/wview respectively, preserving existing
                          data files and backing up existing configuration
                          (if any)

4.6  Configure to run at system boot (if new install).
     Select the appropriate wview run script -
     wview-x.y.z/examples/SuSE|RedHat|FreeBSD|FedoraCore (based on your OS/distro)
     
     Copy it to the proper location for your system:
         SuSE:       cp wview-x.y.z/examples/SuSE/wview /etc/init.d
         Redhat:     cp wview-x.y.z/examples/RedHat/wview /etc/rc.d/init.d
         FreeBSD:    cp wview-x.y.z/examples/FreeBSD/wview /etc/rc.d
         FedoraCore: cp wview-x.y.z/examples/FedoraCore/wview /etc/rc.d/init.d
         Debian:     cp wview-x.y.z/examples/Debian/wview /etc/init.d
   
     Make sure it is executable:
         SuSE:       chmod +x /etc/init.d/wview
         Redhat:     chmod +x /etc/rc.d/init.d/wview
         FreeBSD:    chmod +x /etc/rc.d/wview
         FedoraCore: chmod +x /etc/rc.d/init.d/wview
         Debian:     chmod +x /etc/init.d/wview
       
     Create a symbolic link in the runlevel directory you boot your server to
     (the following example is for a RedHat/Fedora/Debian that boots into runlevel 3):
         cd /etc/rc.d/rc3.d
         ln -s ../init.d/wview S98wview
   
     wview will now be started when the system is booted.
     Note: You can start/stop wview using this run script:
           /etc/rc.d/init.d/wview start   *or*
           /etc/rc.d/init.d/wview stop

     Run Script Notes:
     
     1) These are example scripts - ergo their location in the distro under the
        examples directory. Don't be afraid to edit the appropriate one for your
        system to your configuration and install location.

     2) If you specify a non-default "--prefix=xxx" to the configure script for
        wview, you will have to edit the wview start script so that all binaries
        are defined to be at "prefix/bin", otherwise, the script will not work.

     3) You should use the same "--prefix=xxx" specification when configuring
        radlib and wview. Further, this should be the default install location
        for libraries and library headers in your system - i.e., prefix/lib and
        prefix/include for libgd.a, libpng.a, libz.a and gd.h respectively. Do
        not select a non-default prefix (/usr/local) randomly.

4.7  Add radlib location to shared library cache.
     If you get errors similar to:
        /usr/local/bin/wviewd: error while loading shared libraries:
        librad.so.0: cannot open shared object file: No such file or directory
     you need to either copy the latest wview start script from the distro
     (examples//wview) to your start script location (see the
     preceeding section), or add the radlib shared library location
     (/usr/local/lib) to your shared library cache (see /etc/ld.so.conf) and run
     ldconfig.


Per? non capisco cosa devo fare!!
.................\\\//..................
                / _ _ \
              (|(.)(.)|)
------.OOOo--()--oOOO.-------
Twitter: @kidysy

lukax8

  • Sr. Member
  • ****
  • Post: 636
    • MSN Messenger - lukax8@libero.it
    • Mostra profilo
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #3 il: Febbraio 06, 2008, 10:51:52 pm »
1) scompatta l'archivio
2) entra nella directory dove hai estratto i file
3) ./configure aggiungendo l'argomento che ti interessa (io non ne ho la minima idea)
4) make
5) # make install
6) a questo punto c'? la procedura per l'avvio al boot del sistema

kidy

  • Global Moderator
  • Hero Member
  • *****
  • Post: 1668
  • Kidy
    • Mostra profilo
    • E-mail
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #4 il: Febbraio 07, 2008, 12:02:35 am »
Allora:
Qualsiasi cosa gli dico la risposta ?:
-bash: ./configure: /bin/sh^M: bad interpreter: No such file or directory
pero credo di dover fare in altro modo ,leggendo" Run the configure script to create the build files for your platform"
per? non so come si f? e dove st? guardando nella cartenna non trovo nulla.
.................\\\//..................
                / _ _ \
              (|(.)(.)|)
------.OOOo--()--oOOO.-------
Twitter: @kidysy

thedog75

  • Full Member
  • ***
  • Post: 374
    • Mostra profilo
    • p3x-989.ath.cx
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #5 il: Febbraio 07, 2008, 07:22:19 am »
Allora:
Qualsiasi cosa gli dico la risposta ?:
-bash: ./configure: /bin/sh^M: bad interpreter: No such file or directory
pero credo di dover fare in altro modo ,leggendo" Run the configure script to create the build files for your platform"
per? non so come si f? e dove st? guardando nella cartenna non trovo nulla.
Sembrerebbe che lo script di installazione voglia la schell sh invece che la bash installata di default su ubuntu.
Stasera scarico wview e poi provo a compilarlo sul mio server Gutsy, se ho qlk novit? ti faccio sapere!
Vivo la vita un quarto di GHz alla volta, non mi importa di nient'altro... Su quelle onde sono libero!!
Senza liberta' di scelta non c'e' creativita', e senza creativita' non c'e' vita. (J.T. Kirk in "Star Trek")

kidy

  • Global Moderator
  • Hero Member
  • *****
  • Post: 1668
  • Kidy
    • Mostra profilo
    • E-mail
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #6 il: Febbraio 07, 2008, 07:54:51 am »
Grazie!Dog
Sei molto gentile!Intanto provo anche io :roll:
.................\\\//..................
                / _ _ \
              (|(.)(.)|)
------.OOOo--()--oOOO.-------
Twitter: @kidysy

lukax8

  • Sr. Member
  • ****
  • Post: 636
    • MSN Messenger - lukax8@libero.it
    • Mostra profilo
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #7 il: Febbraio 07, 2008, 07:10:21 pm »
sulla versione desktop ./configure non da problemi, ho degli errori sul make. Ora non ho tempo poi controllo...

thedog75

  • Full Member
  • ***
  • Post: 374
    • Mostra profilo
    • p3x-989.ath.cx
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #8 il: Febbraio 07, 2008, 08:25:23 pm »
Allora dopo tanto penare son riuscito a far girare wview-3.4.1 su ubuntu gutsy server.
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install libpng12-dev libxpm-dev libfreetype6-dev libfontconfig1-dev
poi leggendo da /dir_installaz_wview/wview-User-Manual.html
si scaricano dai rispettivi siti libgd radlib libcurl e si installano come di consueto con
sudo ./configure && make && make install
quindi, una volta installate le dipendenze si entra in /dir_installaz_wview/ e col solito
sudo ./configure --enable-station-tipostazione && make && make install && make install-env && ldconfig
si installa il programma.
Poi poi procedere con la configurazione dei vari files in /etc/wview e a copiare /dir_installaz_wview/examples/Debian/wview in /etc/init.d/ e a cambiargli i permessi con sudo chmod 755 wview.
Alla fine si starta il demone con sudo /etc/init.d/wview start e con un bel ps xuaw | grep wview si vedono i processi in esecuzione:
thedog@gutsyS:/usr/local/wview-3.4.1# sudo ps xuaw | grep wview
root      1747  0.0  0.1   3056   540 ?        Ss   20:25   0:00 /usr/local/bin/radmrouted 1 /var/wview
root      1749  0.0  0.0   3056   284 ?        S    20:25   0:00 /usr/local/bin/radmrouted 1 /var/wview
root      1751  1.2  0.1   5648   988 ?        Ss   20:25   0:05 /usr/local/bin/wviewd
root      1752  0.0  0.0   5648   432 ?        S    20:25   0:00 /usr/local/bin/wviewd
root      1806  0.0  0.1   2972   748 pts/1    R+   20:32   0:00 grep wview

Purtroppo non ho l'hardware per provarlo, ma sia la compilazione che l'installazione funzionano!
Vivo la vita un quarto di GHz alla volta, non mi importa di nient'altro... Su quelle onde sono libero!!
Senza liberta' di scelta non c'e' creativita', e senza creativita' non c'e' vita. (J.T. Kirk in "Star Trek")

lukax8

  • Sr. Member
  • ****
  • Post: 636
    • MSN Messenger - lukax8@libero.it
    • Mostra profilo
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #9 il: Febbraio 07, 2008, 08:29:06 pm »
Finalmente un pinguino in gamba all'interno del forum!  :wink:

thedog75

  • Full Member
  • ***
  • Post: 374
    • Mostra profilo
    • p3x-989.ath.cx
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #10 il: Febbraio 07, 2008, 08:35:10 pm »
Finalmente un pinguino in gamba all'interno del forum!  :wink:
Naaa...!! troppo buono!!!  Sono solo un elettricista stufo di Bill e del suo software facile ma non LIBERO!!!
Vivo la vita un quarto di GHz alla volta, non mi importa di nient'altro... Su quelle onde sono libero!!
Senza liberta' di scelta non c'e' creativita', e senza creativita' non c'e' vita. (J.T. Kirk in "Star Trek")

kidy

  • Global Moderator
  • Hero Member
  • *****
  • Post: 1668
  • Kidy
    • Mostra profilo
    • E-mail
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #11 il: Febbraio 07, 2008, 09:12:40 pm »
Allora dopo tanto penare son riuscito a far girare wview-3.4.1 su ubuntu gutsy server.
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install libpng12-dev libxpm-dev libfreetype6-dev libfontconfig1-dev
poi leggendo da /dir_installaz_wview/wview-User-Manual.html
si scaricano dai rispettivi siti libgd radlib libcurl e si installano come di consueto con
sudo ./configure && make && make install
quindi, una volta installate le dipendenze si entra in /dir_installaz_wview/ e col solito
sudo ./configure --enable-station-tipostazione && make && make install && make install-env && ldconfig
si installa il programma.
Poi poi procedere con la configurazione dei vari files in /etc/wview e a copiare /dir_installaz_wview/examples/Debian/wview in /etc/init.d/ e a cambiargli i permessi con sudo chmod 755 wview.
Alla fine si starta il demone con sudo /etc/init.d/wview start e con un bel ps xuaw | grep wview si vedono i processi in esecuzione:
thedog@gutsyS:/usr/local/wview-3.4.1# sudo ps xuaw | grep wview
root      1747  0.0  0.1   3056   540 ?        Ss   20:25   0:00 /usr/local/bin/radmrouted 1 /var/wview
root      1749  0.0  0.0   3056   284 ?        S    20:25   0:00 /usr/local/bin/radmrouted 1 /var/wview
root      1751  1.2  0.1   5648   988 ?        Ss   20:25   0:05 /usr/local/bin/wviewd
root      1752  0.0  0.0   5648   432 ?        S    20:25   0:00 /usr/local/bin/wviewd
root      1806  0.0  0.1   2972   748 pts/1    R+   20:32   0:00 grep wview

Purtroppo non ho l'hardware per provarlo, ma sia la compilazione che l'installazione funzionano!


Allora! Dog io purtroppo sono alle prime armi!! e sono un pochino utonto!
I pacchetti per le dipendenze io li ho cercati e trovati all.deb quindi li ho installati con dpkg --install tutti tranne radlib-2.7.1 che ho comunque scaricato e decompresso nella cartella root
quindi entrando con cd radlib-2.7.1 entro nella cartella ? quale comando devo dare?
./install e basta?o devo aggiungere qualcosa? se non aggiungo nulla mi dice:
root@ubuntus:~/radlib-2.7.1# ./install
-bash: ./install: No such file or directory
Perdonami Dog ma andiamo per gradi altrimenti non imparo!
Grazie!
.................\\\//..................
                / _ _ \
              (|(.)(.)|)
------.OOOo--()--oOOO.-------
Twitter: @kidysy

thedog75

  • Full Member
  • ***
  • Post: 374
    • Mostra profilo
    • p3x-989.ath.cx
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #12 il: Febbraio 08, 2008, 07:24:23 am »
Nnn ti preoccupare kidy, intanto ti consiglio di installare da /usr/local (non che cambi qualcosa ma ? solo per non incasinare /root con file che non centrano..)
decomprimi radlib-2.7.1 in /usr/local e ottieni /usr/local/radlib-2.7.1
cd /usr/local/radlib-2.7.1
./configure && make && make install

P.S. Le 2 & messe fra in comandi dicono solo alla bash di eseguire il comando successivo dopo aver terminato in modo positivo quello precedente; se vuoi li puoi dare anche in sequenza uno alla volta. :wink:
Vivo la vita un quarto di GHz alla volta, non mi importa di nient'altro... Su quelle onde sono libero!!
Senza liberta' di scelta non c'e' creativita', e senza creativita' non c'e' vita. (J.T. Kirk in "Star Trek")

kidy

  • Global Moderator
  • Hero Member
  • *****
  • Post: 1668
  • Kidy
    • Mostra profilo
    • E-mail
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #13 il: Febbraio 08, 2008, 04:01:43 pm »
Ok Dog ,credo di aver capito che io ho un problema con la mia linux box perch? continua con l'errore:
 -bash: ./install: No such file or directory
Tra le altre cose ilsever che sto gestendo ? a circa 60 km di distanza quindi questa sera metto su un nuovo serverino in locale(Cantina)monto la distro e riprovo!
Ma adesso che mi viene in mente io uso la Dapper,cambia qualcosa? non credo!
Ci sentiamo questa sera quando avr? montato il mulettino! :-)
.................\\\//..................
                / _ _ \
              (|(.)(.)|)
------.OOOo--()--oOOO.-------
Twitter: @kidysy

kidy

  • Global Moderator
  • Hero Member
  • *****
  • Post: 1668
  • Kidy
    • Mostra profilo
    • E-mail
Re: La parola magica "Compilare" in Ubuntu server
« Risposta #14 il: Febbraio 08, 2008, 09:31:52 pm »
Scusa Dog su quale ubuntu hai fatto le prove?
.................\\\//..................
                / _ _ \
              (|(.)(.)|)
------.OOOo--()--oOOO.-------
Twitter: @kidysy