perl.inline...Re: Inline::C - including an external file and nothing else by second axiom- March 30, 2008 Rob,I tested the solutions you suggested and got the expected output, but the two C functions are unable to call each other. If I put them both in a single file, then (predictably) they see each other.Patrick&39;s suggestion (scalar of cat of multiple files) did the trick. Thanks to you both.Andy----------------------------use Inline C => &39;srcmyCcode.c&39;;use Inline C => <<&39;EOC&39;;void again() printf("Hello...http://www.nntp.perl.org/group/perl.inline/2008/03/msg3625.html Re: Inline::C - including an external file and nothing else by Sisyphus- March 30, 2008 ----- Original Message ----- From: "second axiom" <secondaxiomyahoo.com>..> What I&39;m trying to accomplish seems to be a combination or modification of > current options, a concatenation of a source file and the Inline::C code > I have in the script:>> use Inline (C => &39;CmyCcode.c&39;, <<ENDC);> new C code here> ENDC>I ran the following script:----------------------------use warnings;use Inline C => &39;srcmyCcode.c&39;;use Inline C...http://www.nntp.perl.org/group/perl.inline/2008/03/msg3624.html Re: Inline::C - including an external file and nothing else by Patrick LeBoutillier- March 30, 2008 Hi,Actually, I think your code doesn&39;t need to be in a subdirectory. It&39;sjust that IIRC Inline looks for a slash (&39;&39;) to know if the specifiedscalar is a filename or the source code itself. If you use&39;.myCcode.c&39; it should work.But in your case, you should be able to just read in the 2 filesyourself and send the code directly to Inline::C like this:!usrbinperluse strict ;sub get_code my $code = &39;&39; ; for my $src (_) $code .= join(&39;&39;,...http://www.nntp.perl.org/group/perl.inline/2008/03/msg3623.html Re: Inline::C - including an external file and nothing else by second axiom- March 30, 2008 Sisyphus <sisyphus1optusnet.com.au> wrote: ----- Original Message ----- From: "second axiom" To: Sent: Sunday, March 30, 2008 3:56 PMSubject: Inline::C - including an external file and nothing else> Hello.>> I&39;m able to create Perl script that uses Inline C and also links to a > precompiled C library, but I&39;m trying to do something else that I think > should be equivalent:>> !usrbinperl -w> use Inline C => <> include > ENDC>...http://www.nntp.perl.org/group/perl.inline/2008/03/msg3622.html Re: Inline::C - including an external file and nothing else by Sisyphus- March 29, 2008 ----- Original Message ----- From: "second axiom" <secondaxiomyahoo.com>To: <inlineperl.org>Sent: Sunday, March 30, 2008 3:56 PMSubject: Inline::C - including an external file and nothing else> Hello.>> I&39;m able to create Perl script that uses Inline C and also links to a > precompiled C library, but I&39;m trying to do something else that I think > should be equivalent:>> !usrbinperl -w> use Inline C => <<ENDC;> include...http://www.nntp.perl.org/group/perl.inline/2008/03/msg3621.html Inline::C - including an external file and nothing else by second axiom- March 29, 2008 Hello.I&39;m able to create Perl script that uses Inline C and also links to a precompiled C library, but I&39;m trying to do something else that I think should be equivalent:!usrbinperl -wuse Inline C => <<ENDC;include <myCcode.c>ENDCtest(2); I.e., if I paste the contents of myCcode.c in place of the include, I get the expected results. I&39;m trying to get Inline to do that and ignore the fact that the code comes from a separate file, but it refuses to recognize the functions...http://www.nntp.perl.org/group/perl.inline/2008/03/msg3620.html Re: Inline::CPP on win32 bug by Sisyphus- March 29, 2008 ----- Original Message ----- From: "Edward Peschko" <horos11gmail.com>To: "Eric Wilhelm" <scratchcomputinggmail.com>; <inlineperl.org>Sent: Sunday, March 30, 2008 8:30 AMSubject: Re: Inline::CPP on win32 bug>I think the problem is that "perl.h" is included in an &39;extern C&39; block,> which then includes math.h, which has template code.> > If I comment out the template code in the main header included with vc++(> math.h), things...http://www.nntp.perl.org/group/perl.inline/2008/03/msg3619.html |