Installation d'une imprimante MP Canon MP490 en ligne de commande

Pour discuter boîtiers, fixation, radiateurs, écrans LCD, water cooling... Enfin, tout ce que vous ne trouvez pas dans les autres rubriques !

Modérateur : Francois

Répondre
Avatar du membre
kalimeth
Messages : 11
Enregistré le : jeu. 4 juin 2015 23:04
Localisation : Cherbourg (50)

Installation d'une imprimante MP Canon MP490 en ligne de commande

Message par kalimeth » dim. 15 nov. 2020 23:04

Bonjour à tous,

J'ai décidé d'utiliser un Raspberry Pi 2 en serveur CUPS pour transformer ma vieille imprimante Canon Pixma MP490 en imprimante "Wifi".
J'utilise la version 20.04 d'Ubuntu server (en 32 bit me semble-t-il).

Le problème, c'est que même si c'est très formateur (et c'est un peu l'effet recherché), je galère à mort sans interface graphique.

J'ai réussi tant bien que mal à prendre la main en SSH, installer CUPS et au moment où je veux configurer une nouvelle imprimante (sur une page web ouverte sur l'ordinateur connecté en SSH), il me propose bien la MP490 connectée en USB au Raspi2 (usb://Canon/MP490%20series?serial=01C892&interface=1|Canon MP490 series).
En revanche, il ne me propose pas la marque Canon dans la liste de marque prédéfinie, je cherche donc à donner un fichier PPD mais je n'en trouve pas.

Pourtant, je sais que cette imprimante à déjà été reconnue en plug-and-play sur un portable tournant sur Lubuntu sans rien paramétrer (en la trouvant juste sur "imprimante"). De la même façon, le scanner fonctionnait sans rien faire avec l'application de scan simple de Lubuntu.

En tapant lsusb , je me suis bien assuré qu'elle était branchée et reconnue :

Code : Tout sélectionner

ubuntu@ubuntu:~$ lsusb  
Bus 001 Device 005: ID 04a9:173c Canon, Inc. PIXMA MP490
Bus 001 Device 003: ID 0424:ec00 Microchip Technology, Inc. (formerly SMSC) SMSC9512/9514 Fast Ethernet Adapter
Bus 001 Device 002: ID 0424:9514 Microchip Technology, Inc. (formerly SMSC) SMC9514 Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub 
ubuntu@ubuntu:~$ lpstat -s
no system default destination
matériel pour MP490 : usb://Canon/MP490%20series?serial=01C892
ubuntu@ubuntu:~$
Donc si j'ai bien compris, je n'ai pas d'imprimante installée, mais j'ai une imprimante disponible (usb://Canon/MP490%20series?serial=01C892) ?

J'ai essayé d'installer les drivers :

Code : Tout sélectionner

ubuntu@ubuntu:~/Drivers Canon/cnijfilter-mp490series-3.20-1-i386-deb$ sudo ./install.sh
==================================================

Canon Inkjet Printer Driver Ver.3.20-1 for Linux
Copyright CANON INC. 2001-2009 
All Rights Reserved.                                                   
                                                                                                                                                                   ================================================== 
Execution command = sudo dpkg -iG ./packages/cnijfilter-common_3.20-1_i386.deb
dpkg: erreur de traitement de l'archive ./packages/cnijfilter-common_3.20-1_i386.deb (--install) :
 l'architecture du paquet (i386) ne correspond pas à celle du système (armhf)
Des erreurs ont été rencontrées pendant l'exécution :
./packages/cnijfilter-common_3.20-1_i386.deb
ubuntu@ubuntu:~/Drivers Canon/cnijfilter-mp490series-3.20-1-i386-deb$  
Il semblerait que les drivers que j'ai trouvé soient spécifiques à une architecture i386.
Mon problème est peut-être qu'il va être difficile de trouver des drivers pour Raspberry (donc ARM).
C'est sûrement la raison pour laquelle l'imprimante n'était pas plug-and-play.

Si quelqu'un avait ne serait-ce que le début d'une réponse, ça m'intéresserait pas mal, merci d'avance.

Avatar du membre
kalimeth
Messages : 11
Enregistré le : jeu. 4 juin 2015 23:04
Localisation : Cherbourg (50)

Re: Installation d'une imprimante MP Canon MP490 en ligne de commande

Message par kalimeth » lun. 16 nov. 2020 09:56

En relisant plus attentivement le sujet déjà pré"sent sur le forum (viewtopic.php?f=50&t=4502&hilit=imprima ... n&start=10), je me suis aperçu que le problème avait déjà été soulevé en 2018.
J'ai donc essayé de compiler la dernière version du gutenprint, la 5.3.3 :

Code : Tout sélectionner

ubuntu@ubuntu:~/gutenprint-5.3.3$ sudo ./configure
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes 
checking whether make supports nested variables... yes                                                               
checking whether UID '0' is supported by ustar format... yes                                                         
checking whether GID '0' is supported by ustar format... yes                                                        
checking how to create a ustar tar archive... gnutar                                                                
checking whether make supports nested variables... (cached) yes                                                     
checking build system type... armv7l-unknown-linux-gnueabihf                                                        
checking host system type... armv7l-unknown-linux-gnueabihf                                                  
checking how to print strings... printf                                                                           
checking whether make supports the include directive... yes (GNU style)                    
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out 
checking for suffix of executables...                                                       
checking whether we are cross compiling... no                                                        
checking for suffix of object files... o                                                              
checking whether we are using the GNU C compiler... yes                                               
checking whether gcc accepts -g... yes                                                             
checking for gcc option to accept ISO C89... none needed                                  
checking whether gcc understands -c and -o together... yes                              
checking dependency style of gcc... gcc3                                                           
checking for a sed that does not truncate output... /usr/bin/sed                             
checking for grep that handles long lines and -e... /usr/bin/grep                                 
checking for egrep... /usr/bin/grep -E                                                       
checking for fgrep... /usr/bin/grep -F                                                             
checking for ld used by gcc... /usr/bin/ld                                                     
checking if the linker (/usr/bin/ld) is GNU ld... yes                                 
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B                            
checking the name lister (/usr/bin/nm -B) interface... BSD nm                               
checking whether ln -s works... yes                                                        
checking the maximum length of command line arguments... 1572864               
checking how to convert armv7l-unknown-linux-gnueabihf file names to armv7l-unknown-linux-gnueabihf format... func_convert_file_noop                                                                                                      checking how to convert armv7l-unknown-linux-gnueabihf file names to toolchain format... func_convert_file_noop  
checking for /usr/bin/ld option to reload object files... -r                                  
checking for objdump... objdump                                                                
checking how to recognize dependent libraries... pass_all                                            
checking for dlltool... no                                                              
checking how to associate runtime and link libraries... printf %s\n                            
checking for ar... ar                                                                                      
checking for archiver @FILE support... @                                                  
checking for strip... strip                                                                      
checking for ranlib... ranlib                                                                      
checking command to parse /usr/bin/nm -B output from gcc object... ok                    
checking for sysroot... no                                                                    
checking for a working dd... /usr/bin/dd                                                  
checking for mt... mt                                                                                  
checking if mt is a manifest tool... no                                              
checking how to run the C preprocessor... gcc -E                                               
checking for ANSI C header files... yes                                              
checking for sys/stat.h... yes                                                      
checking for string.h... yes                                                       
checking for memory.h... yes                                                              
checking for strings.h... yes                                                         
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... yes
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
./configure: line 9270: dlopen: command not found
checking whether to enable maintainer-specific portions of Makefiles... no
checking for cups-config... no
checking whether to whether to build CUPS driver... (automatic)
configure: error:                                                                                                                                                                                                                         ******* ERROR ******
You do not have the necessary software installed to build the CUPS driver.
This is most likely not what you want, as the resulting installation will
not be usable as part of a normal printing system.  If you are certain
that this is what you want, please run configure with --without-cups.
Otherwise, please read the README and install the necessary development
package, most likely named 'cups-devel', and re-run configure.                                                                                                                                                                                                                                                                                                 ubuntu@ubuntu:~/gutenprint-5.3.3$
J'ai des erreurs.
J'ai essayé aussi le autogen.sh :

Code : Tout sélectionner

ubuntu@ubuntu:~/gutenprint-5.3.3$ sudo ./autogen.sh
autoreconf: Entering directory `.'
autoreconf: running: autopoint --force
Copying file m4/codeset.m4
Copying file m4/gettext.m4
Copying file m4/glibc2.m4
Copying file m4/glibc21.m4
Copying file m4/iconv.m4
Copying file m4/intdiv0.m4
Copying file m4/intl.m4
Copying file m4/lib-link.m4
Copying file m4/lib-prefix.m4
Copying file m4/lock.m4
Copying file m4/longdouble.m4
Copying file m4/longlong.m4
Copying file m4/nls.m4
Copying file m4/po.m4
Copying file m4/printf-posix.m4
Copying file m4/progtest.m4
Copying file m4/size_max.m4
Copying file m4/stdint_h.m4
Copying file m4/uintmax_t.m4
Copying file m4/ulonglong.m4
Copying file m4/visibility.m4
Copying file m4/wchar_t.m4
Copying file m4/wint_t.m4
Copying file m4/xsize.m4
autoreconf: running: aclocal --force -I m4 -I m4local
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
autoreconf: configure.ac: tracing
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
autoreconf: running: libtoolize --copy --force
libtoolize: putting auxiliary files in AC_CONFIG_AUX_DIR, 'scripts'.
libtoolize: copying file 'scripts/ltmain.sh'
libtoolize: putting macros in AC_CONFIG_MACRO_DIRS, 'm4'.
libtoolize: copying file 'm4/libtool.m4'
libtoolize: copying file 'm4/ltoptions.m4'
libtoolize: copying file 'm4/ltsugar.m4'
libtoolize: copying file 'm4/ltversion.m4'
libtoolize: copying file 'm4/lt~obsolete.m4'
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
autoreconf: running: /usr/bin/autoconf --force
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
autoreconf: running: /usr/bin/autoheader --force
scripts/snapstamp: 20: [[: not found
scripts/snapstamp: 20: [[: not found
autoreconf: running: automake --add-missing --copy --force-missing
configure.ac:302: warning: The 'AM_PROG_MKDIR_P' macro is deprecated, and its use is discouraged.
configure.ac:302: You should use the Autoconf-provided 'AC_PROG_MKDIR_P' macro instead,
configure.ac:302: and use '$(MKDIR_P)' instead of '$(mkdir_p)'in your Makefile.am files.
configure.ac:200: installing 'scripts/compile'                                                                 
configure.ac:167: installing 'scripts/missing'
src/cups/Makefile.am: installing 'scripts/depcomp'
autoreconf: Leaving directory `.'
./autogen.sh: 1: ./scripts/autogen.sh: libtool: not found        

**Warning**: You should have `libtool' 1.5 or newer installed to
create a Gutenprint distribution.  Earlier versions of libtool do
not generate correct code for all platforms.
Get ftp://ftp.gnu.org/pub/gnu/libtool/libtool-1.5.tar.gz
(or a newer version if it is available)                         

***Warning***: You must have "Jade" version 1.2.1 or
newer installed to build the Gutenprint user's guide.
Get ftp://ftp.jclark.com/pub/jade/jade-1.2.1.tar.gz
(or a newer version if available)                       
                                                                                                                                                                                                                                                                                                       ***Warning***: You must have "dvips" installed to
build the Gutenprint user's guide.                                                                                                                                                                                                                                                                                                                             ***Warning***: You must have "jadetex" version 3.5 or                             
newer installed to build the Gutenprint user's guide.
Get ftp://prdownloads.sourceforge.net/jadetex/jadetex-3.5.tar.gz
(or a newer version if available)                                                         
                                                                                                                                                                                                                                                                     ***Warning***: You must have "db2html" installed to
build the Gutenprint user's guide.
This usually comes from packages named docbook-utils or docbook-toys.  
                                                                                                                                                                                                                                                                                        ***Warning***: You must have "db2pdf" installed to
build the Gutenprint user's guide.
This usually comes from packages named docbook-utils-pdf
or docbook-toys.                                                                   
                                                                                                                                                                                                                                                                            ***Warning***: You must have "sgmltools-lite" version 3.0.2
or newer installed to build the Gutenprint user's guide.
Get https://sourceforge.net/projects/sgmltools-lite/files/latest/download
(or a newer version if available)                  
                                                                                                                                                                                                                                                                                                            ***Warning***: You must have "convert" installed to
build the Gutenprint user's guide.
"convert" comes from the ImageMagick software package.
Go to http://imagemagick.sourceforge.net/http and get
the file ImageMagick-5.3.1.tar.gz
(or a newer version if available)              
                                                                                                                                                                                                                                                                                                                ***Warning***: You must have Docbook v4 installed to
build the Gutenprint user's guide.                                                                                                                                                                                                        ubuntu@ubuntu:~/gutenprint-5.3.3$  
Je pense qu'il me manque certains paquets, pour autant, je n'arrive pas à tous les télécharger :

Code : Tout sélectionner

ubuntu@ubuntu:~/gutenprint-5.3.3$ sudo apt install convert
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
E: Impossible de trouver le paquet convert
ubuntu@ubuntu:~/gutenprint-5.3.3$ sudo apt install sgmltools-lite
Lecture des listes de paquets... Fait
Construction de l'arbre des dépendances
Lecture des informations d'état... Fait
Aucune version du paquet sgmltools-lite n'est disponible, mais il existe dans la base
de données. Cela signifie en général que le paquet est manquant, qu'il est devenu obsolète
ou qu'il n'est disponible que sur une autre source                                                                                                                                                                                                                                                                                                      E: Le paquet « sgmltools-lite » n'a pas de version susceptible d'être installée    

Avatar du membre
kalimeth
Messages : 11
Enregistré le : jeu. 4 juin 2015 23:04
Localisation : Cherbourg (50)

Re: Installation d'une imprimante MP Canon MP490 en ligne de commande

Message par kalimeth » lun. 16 nov. 2020 19:22

Au cas où quelqu'un passerait par ici, aurait-il tenté de convertir un pilote i386 en ARM de cette façon ?
[url]https://unix.stackexchange.com/question ... s-on-armv7[/url]

Répondre

Retourner vers « Les accessoires du Raspberry Pi »