For Programmers: Free Programming Magazines  


Home > Archive > PERL Modules > December 2007 > Using Module::Build to XS









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Using Module::Build to XS
Raga

2007-12-18, 6:59 pm

Hi,

I have volunterred to maintain the LSF::Base and LSF::Batch modules on
CPAN , I am in the process of rewriting the module's Makefile.PL
(which uses the ExtUtils::MakeMaker) to use the Module::Build's
Build.PL process. Unfortunately I have not been very successful in
writing the Build.PL to do all the complies. Also I have not been able
to gather any information regarding the use of Module::Build to do XS
complies. Any inputs on where I can get this information would be
really helpful.

I have tried to write the Build.PL by using the following code snippet
but this was not able to create the shared object for Dynaloader to
load.

my $builder = Module::Build->new(
module_name => 'LSF::Base',
...
c_source => 'lib/',
include_dirs => [ $lsf_includedir ] ,
extra_linker_flags => $libs,
extra_compiler_flags => '-DPERL_POLLUTE',
create_makefile_pl => 'traditional'
);


Also any inputs on the Module::Build's equivalent of the below
Mafile.PL will be greatly appreciated.

WriteMakefile(
'NAME' => 'LSF::Base',
'VERSION_FROM' => 'Base.pm',
'LIBS' => [$libs ],
'DEFINE' => '-DPERL_POLLUTE',
'OBJECT' => '$(O_FILES)',
'INC' => "-I$lsf_includedir"
);

If this is a RTFM please do scream at me

Thanks
Raga
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com