in reply to Re: Re: Failing to Autogenerate config in Inline.PM
in thread Failing to Autogenerate config in Inline.PM

Well, it works for me under 5.6.1 if I create the .Inline directory first. This may be a 5.005 problem. Can you run the following (with appropriate paths):

use strict; use Inline (Config => DIRECTORY => '/home/ned/.Inline',); use Inline 'C'; greet('Ingy'); greet(42); __END__ __C__ void greet(char* name) { printf("Hello %s!\n", name); }

On my system, it writes a config file in /home/ned/.Inline/config that looks like:

version : 0.42 languages : % C : C Foo : Foo c : C foo : Foo types : % C : compiled Foo : interpreted modules : % C : Inline::C Foo : Inline::Foo suffixes : % C : so Foo : foo

Replies are listed 'Best First'.
Re: Re: Re: Re: Failing to Autogenerate config in Inline.PM
by sierrathedog04 (Hermit) on Jul 04, 2001 at 03:31 UTC
    Thank you very much BikeNomad. I ran your script, and I got the same error message as before, saying that the autogeneration of the config failed.

    It is reasonably apparent that I am dealing with either a 5.005 problem or a circa 1997 NCR MP-RAS Unix problem.

    I am not even certain that XS or Swig would work, assuming that I had the time and skills to coerce them to do so.

    Therefore: PLAN B. Instead of calling C from Perl, I will have Perl write its input to a special file. A C program called with backticks will read the input and print the output.

    Not the most elegant way to do things, but the best option now that the Inline.pm/MP-RAS/5.005 combination has proven to be a big problem.