Bienvenue sur eagle-usb.org

WikiEagle

InstallHwDb

PagePrincipale :: DerniersChangements :: DerniersCommentaires :: ParametresUtilisateur :: Vous êtes 18-97-14-91.crawl.commoncrawl.org

see DevPhp too

Install MySQL?

urpmi MySQL?

Install apache mod_perl

urpmi mod_perl


Configure MySQL?

Create database librehwdb
mysql # connect to mysql (think to change root password...)
create database librehwdb ;
SHOW DATABASES;
quit;

mysql librehwdb # connect to database librehwdb and create tables
source dbstruct.sql ;
SHOW TABLES;
exit ;

Install phpMyAdmin

urpmi phpMyAdmin
Un des paquetages suivants est nécessaire :
1- php-cli-4.3.10-4mdk.i586 : Command-line interface to PHP (to install)
2- php-cgi-4.3.10-4mdk.i586 : CGI interface to PHP (to install)
3- mod_php-4.3.10-2mdk.i586 : The PHP4 HTML-embedded scripting language for use with Apache (to install)
4- apache2-mod_php-2.0.53_4.3.10-1mdk.i586 : The PHP4 HTML-embedded scripting language for use with apache2 (to install)
Que choisissez-vous ? (1-4) 4
Pour satisfaire les dépendances, les 7 paquetages suivants vont être installés (10 Mo):
apache2-2.0.53-3mdk.i586
apache2-mod_php-2.0.53_4.3.10-1mdk.i586
apache2-modules-2.0.53-3mdk.i586
libphp_common432-4.3.10-4mdk.i586
php-ini-4.3.10-2mdk.noarch
php-mysql-4.3.10-5mdk.i586
phpMyAdmin-2.6.1-2mdk.noarch


Install hwDB-client

urpmi hwdb-clients

modify file /usr/share/hwdb/hwdb.pm
    my $hwdb = SOAP::Lite
        -> uri('http://hwdb.mandrakesoft.com/HW')
        -> proxy('http://hwdb.mandrakesoft.com/HW/hw.cgi')
        -> on_fault(sub { my($soap, $res) = @_;
                          die ref $res ? $res->faultstring : $soap->transport->status, "\n";
                      });

par
    my $hwdb = SOAP::Lite
        -> uri('http://localhost/hwdb/db')
        -> proxy('http://localhost/hwdb/db/hw.cgi')
        -> on_fault(sub { my($soap, $res) = @_;
                          die ref $res ? $res->faultstring : $soap->transport->status, "\n";
                      });


packages perl

This driver provides connectivity to PostgreSQL database servers
through the libdbi database independent abstraction layer.
urpmi libdbi-drivers-dbd-pgsql
    ftp://ftp.proxad.net/pub/Distributions_Linux/Mandrakelinux/devel/cooker/i586/media/contrib/libdbi-drivers-dbd-pgsql-0.7.1-1mdk.i586.rpm
installation de libdbi-drivers-dbd-pgsql-0.7.1-1mdk.i586.rpm depuis /var/cache/urpmi/rpms
Préparation ...                  #############################################
      1/1: libdbi-drivers-dbd-pgsql#############################################


Install hwDB-server

check it at http://cvs.mandrakesoft.com
http://cvs.mandriva.com/cgi-bin/cvsweb.cgi/hwdb/
http://cvs.mandriva.com/cgi-bin/cvsweb.cgi/soft/bugs/cgi-bin/HW/

http://cvs.mandriva.com/cgi-bin/viewvc.cgi/hwdb/
http://cvs.mandriva.com/cgi-bin/viewvc.cgi/soft/bugs/cgi-bin/HW/

http://svn.mandriva.com/cgi-bin/viewvc.cgi/soft/bugzilla/trunk/cgi-bin/HW/

http://cvs.mandriva.com/cgi-bin/viewvc.cgi/web/hcl/lib/HclApp/ for the web site http://cvs.mandriva.com/cgi-bin/viewvc.cgi/web/hcl/ for the home


cvs -d anoncvs@cvs.mandriva.com:/cooker co hwdb/db # password cvs
cvs -d anoncvs@cvs.mandriva.com:/cooker co soft/bugs/cgi-bin # password cvs

edit file db/auth.pl
sub connectdb {
    $dbh or $dbh = DBI->connect("DBI:mysql:database=librehwdb;host=localhost",
                                "root", " ",
                                {'RaiseError' => 1});
}


and edit file db/hwdb.pm
sub connectdb {
    $dbh or $dbh = DBI->connect("DBI:mysql:database=librehwdb;host=localhost",
                                "root", " ",
                                {'RaiseError' => 1});
}


ExecCGI pour apache perl

modify /etc/httpd/conf/commonhttpd.conf
<Directory /var/www/html/hwdb/db/>
Options +ExecCGI? -Includes -Indexes
SetHandler? cgi-script
<IfModule? mod_access.c>
Order allow,deny
Allow from all
</IfModule?>
</Directory>
pour éviter le "Options ExecCGI? is off in this directory"
=> c'est bon ça permet d'exécuter hwdb_add_adsl monlogin

Petite erreur restant

Failed to access class (hwdb::db): Can't locate hwdb/db.pm in @INC (@INC contains:) at (eval 92) line 3.

Uploading USB ADSL device «USB ADSL modem» (1110:9031)
=> bizarre je n'ai pas de db.pm sur le cvs de mandrakesoft, je mets quoi dedans ?!

google SOAP::Transport::HTTP::CGI SOAP::Transport::HTTP::CGI -> dispatch_to( me donne :
http://cookbook.soaplite.com/
http://www.oreilly.com/catalog/progwebsoap/chapter/ch03.html
http://www.majordojo.com/soaplite/docs/OldDocs/SOAP/Transport/HTTP.html
=> je pense qu'il me manque des choses (genre exposer les méthodes... d'où le HW que je n'ai pas sur le cvs de mandrakesoft :-( )



Hardware Compatibility List

http://cvs.mandriva.com/cgi-bin/cvsweb.cgi/web/hcl/
database model is available as a dia source : hcl-model-mandriva source

cvs -d anoncvs@cvs.mandriva.com:/cooker co web/hcl # password cvs

database model for hcl
source dia of database model for hcl
Il n'y a pas de commentaire sur cette page. [Afficher commentaires/formulaire]