[Foomatic] Please add my driver for the Lexmark X125 to the database

Mark Roth markroth8 at yahoo.com
Thu Feb 5 21:10:55 PST 2004


Hi Till,

I'm in the process of trying my driver with Foomatic 3.0.1rc2 as you suggested.
 I've run into a couple of issues.

I'm running Red Hat 9.	I rpm -e foomatic and then built and installed the
packages you suggested.  I was having a bit of trouble with foomatic-db-engine.
 In particular I had to ln -s /usr/include/gnome-xml /usr/include/libxml and
manually add -lxml to the XML_LIBS in Makefile.  After I did this, I got
everything to build and install with no noticeable errors.  I'm using
libxml-1.8.17-8 so this might have something to do with it.

In any event, my main problem is that I installed my driver .xml files and I'm
having trouble with my opt/drv_x125-Device.xml option file.  The file looks
like this:

-----
<option type="enum" id="opt/drv_x125-Device">
  <!-- A multilingual <comments> block can appear here, too;
       it should be treated as documentation for the user. -->
  <arg_longname>
   <en>Device</en>
  </arg_longname>
  <arg_shortname>
   <en>Device</en><!-- backends only know <en> shortnames! -->
  </arg_shortname>
  <arg_execution>
   <arg_order>100</arg_order>
   <arg_spot>A</arg_spot>
   <arg_substitution />
   <arg_proto>%s</arg_proto>
  </arg_execution>
  <constraints>
     <constraint sense='true'>
      <driver>drv_x125</driver>
      <printer>printer/Lexmark-X125</printer><!-- Lexmark X125 -->
      <arg_defval>ev/drv_x125-dev_usb_lp0</arg_defval>
     </constraint>
  </constraints>
  <enum_vals>
   <enum_val id="ev/drv_x125-dev_usb_lp0">
    <ev_longname><en>/dev/usb/lp0</en></ev_longname>
    <ev_shortname><en>/dev/usb/lp0</en></ev_shortname>
    <ev_driverval>/dev/usb/lp0</ev_driverval>
   </enum_val>
   <!-- ... more options ... -->
  </enum_vals>
</option>
-----

This used to work in foomatic-2.0.2-15.1 but when I do this today, my driver
gets passed the string /dev/usb/lp0//dev/usb/lp0

I modified the default option as follows, just so I could see what is going on:

-----
   <enum_val id="ev/drv_x125-dev_usb_lp0">
    <ev_longname><en>/dev/usb/lp0a</en></ev_longname>
    <ev_shortname><en>/dev/usb/lp0b</en></ev_shortname>
    <ev_driverval>/dev/usb/lp0c</ev_driverval>
   </enum_val>
-----

I then get /dev/usb/lp0b//dev/usb/lp0a

Of course I'm expecting to just get /dev/usb/lp0c.

Now when I change the longname to something without slashes, like:

-----
   <enum_val id="ev/drv_x125-dev_usb_lp0">
    <ev_longname><en>foo</en></ev_longname>
    <ev_shortname><en>bar</en></ev_shortname>
    <ev_driverval>/dev/usb/lp0</ev_driverval>
   </enum_val>
-----

... then everything works.  I can even print!

Is this behavior correct?  Are there restrictions on the ev_longname and
ev_shortname options in terms of being able to have a slash there?  I'd really
like to have the long/short name match the value in ev_driverval.  I'm also
getting strange error messages from foomatic-config when configuring the queue,
like:

-----
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 348.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 350.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 348.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 350.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 348.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 350.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 348.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 350.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 2230.
Use of uninitialized value in split at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 2230.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3361.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3362.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3363.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3364.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3361.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3362.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3363.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3364.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3361.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3362.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3363.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3364.
Use of uninitialized value in concatenation (.) or string at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3366.
Use of uninitialized value in concatenation (.) or string at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3366.
Use of uninitialized value in concatenation (.) or string at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3366.
Use of uninitialized value in substitution (s///) at
/usr/lib/perl5/site_perl/5.8.0/Foomatic/DB.pm line 3381.
-----

Is this something to do with my version of libxml?  I'd like my choice to read
/dev/usb/lp0 and not 'foo' or 'bar'.  How can I fix this issue?

Thanks,
Mark



More information about the Printing-foomatic mailing list