> Not sure of the fine details of how you're going about this - so I built a > module (that works independent of Inline) based around the > grammar/t/04const.t code (in the Inline::CPP source distro). I've reproduced > the files I used below my sig. Hope there's something there that helps - > though it's fairly simplistic, and faik, I may have simplified away the very > issues that are confronting you :-)
:) I'm (again) trying to get a CPAN-style package that will build on a machine without Inline. Following your recommendation, I've made these files, using the outline from your prior email. More details: I want Inline::CPP, not for the class parsing, but so that I can use C++ classes as part of my procedural C code. Perhaps a bit cheezy, but there it is. Oh, one of those classes is Boost regex, among others. I made a foo.cpp file that has a function SV *foo( const char *a, const char *b, SV *c, const char *d ), which uses a foo.h file for other stuff. I'm including this from my foo.pl by using a bit of fancy footwork so that when I #include "$dirname/foo.cpp" gets the right file - this seems to work just fine. I ran the script and grabbed the Makefile.PL and the '.xs' file - there was no '.map' file. I then started adjusting the Makefile.PL and the .xs file, and creating MANIFEST, Foo.pm and test.pl: MANIFEST: ----------- Changes Makefile.PL README Referrals.pm test.pl referrals.h referrals.cpp ----------- Makefile.PL: ----------- use ExtUtils::MakeMaker; my %options = %{ { 'NAME' => 'Referrals', 'TYPEMAPS' => [], 'LIBS' => [ '-lstdc++ -L/home/y/lib -lboost_regex' ], 'CC' => 'g++', 'VERSION' => '0.06' } }; WriteMakefile(%options); # Remove the Makefile dependency. Causes problems on a few systems. sub MY::makefile { '' } ----------- ----------- ----------- ----------- ----------- ----------- ----------- -----------