Hello all.  I'm having trouble convincing Inline::C to bind to a function
with a parameter type of "const gchar *".  Here's my module file:

  package Gnome::MIME;
  use Inline C        => 'DATA',
             NAME     => "Gnome::MIME",
             VERSION  => "0.01",
             LIBS     => `gnome-config gnome --libs`,
             INC      => `gnome-config gnome --cflags`,
             TYPEMAPS => 'typemap';

  1;

  __DATA__
  __C__
  #include <gnome.h>

  char * file_type (const gchar * filename) {
    return gnome_mime_type(filename);
  }

My typemap file contains:

  const gchar *       T_PV

When I build I get no functions bound.  If I remove the "const" from both
the Inlined code and my typemap then the function is bound.  I think this
points to a bug in the Inline::C parser, but I'm not sure.  Any ideas?

Thanks!
-sam


Reply via email to