in reply to Re^3: Help with Inline C
in thread Help with Inline C

that seems to help. now I am just having compilation errors, a step in the right direction. I am a C newbie, so the mechanics of why everything is so is at this point beyond me.

couldnt I also do something like  gcc -c parser.c mycode.c then  use Inline C => Config => LIBS => '-lparser.o';
is this totally different than what is required?

Replies are listed 'Best First'.
Re^5: Help with Inline C
by syphilis (Archbishop) on Oct 15, 2007 at 22:54 UTC
    ... then use Inline C => Config => LIBS => '-lparser.o';

    I don't think that would work - but the following config option does:
    use Config; use Inline C => Config => LDDLFLAGS => $Config::Config{lddlflags} . ' /full/path/to/parser.o';
    Alternatively, once you've got 'parser.o', you could just go that one extra step and create 'libparser.a' with:
    ar cru libparser.a parser.o
    Then LIBS => '-L/full/path/to/lib -lparser' should also work fine.

    Cheers,
    Rob