Hi Rob, Thank you! I've made the changes accordingly. The updated source is here https://sourceforge.net/projects/pdl-stats/
I've also added a couple simple tests for CDF (I somehow had missed it previously in the MANIFEST). The pop vs. unshift thing is very strange. Sure glad you caught it! No my Strawberry Perl didn't come with a fortran compiler. Thanks for the tip about ActivePerl. I use Windows mainly for entertainment so I haven't cared to have full-powered PDL on there. I really should fix it up now for the modules. Best, Maggie On Sun, Jul 12, 2009 at 10:23 PM, Sisyphus<[email protected]> wrote: > > ----- Original Message ----- From: "Maggie X" <[email protected]> > To: "Chris Marshall" <[email protected]> > Cc: "perldl" <[email protected]> > Sent: Monday, July 13, 2009 4:48 AM > Subject: Re: [Perldl] PDL-Stats > > > Thank you! The source is attached. > > ====================== > > Hi Maggie, > Just a couple of portability issues. > Firstly the following (line 31 from GSL/gsl_cdf.pd) won't work if > gsl/gsl_cdf.h is located somewhere other than /usr/include :-) > > open my $fh, '< /usr/include/gsl/gsl_cdf.h' or die "$!"; > > The only sure way I can think of establishing the location of that file is > to parse `gsl-config --cflags`. > > I also had to patch the Distr and GSL Makefile.PL's as follows: > > ############################### > --- makefile.PL_orig Mon Jul 13 11:11:17 2009 > +++ Makefile.PL Mon Jul 13 11:45:43 2009 > @@ -6,9 +6,11 @@ > %hash = pdlpp_stdargs($package); > > chomp( $PDL::Stats::libgsl ||= `gsl-config --libs` ); > + chomp( $PDL::Stats::cflags = `gsl-config --cflags` ); > > if ($PDL::Stats::libgsl) { > - push @{ $hash{'LIBS'} }, $PDL::Stats::libgsl; > + unshift @{ $hash{'LIBS'} }, $PDL::Stats::libgsl; > + $hash{'INC'} .= " $PDL::Stats::cflags"; > WriteMakefile( %hash ); > sub MY::postamble {pdlpp_postamble($package)}; > } > > ############################### > > Both my gsl libs and headers (on Win32) are not found by default. > Having to replace 'push' with 'unshift' is puzzling, and looks to me that it > might be a MakeMaker bug. For me, $hash{'LIBS'} is initally a reference to > an array that consists of an empty space - ie chr(32). If I push > $PDL::Stats::libgsl onto that array, then the libraries are still not found. > But if I unshift it into that array, then the libraries are found and > everything works fine. I do not currently understand what is going on here - > afaik, the leading space should not be causing any problem and 'push' should > work fine. > I think that $hash{'LIBS'} *should*, in my case, be a reference to an > *empty* array - but I don't yet see why the space should matter. > > Anyway, with those glitches attended to, everything builds and tests fine. > > Does Strawberry Perl ship with the g77 fortran compiler ? Originally, it > didn't - and I'm wondering whether that has been changed yet. > > With ActivePerl you can 'ppm install MinGW', and that does give you a g77 > fortran compiler (along with gcc and g++). > > Cheers, > Rob > _______________________________________________ Perldl mailing list [email protected] http://mailman.jach.hawaii.edu/mailman/listinfo/perldl
