----- Original Message ----- From: "Mahmoud Mehyar" <mamod.meh...@gmail.com>
To: "Sisyphus" <sisyph...@optusnet.com.au>; <inline@perl.org>
Sent: Tuesday, October 19, 2010 4:33 PM
Subject: Re: Inline::C doesn't work anymore


Ok I got Inline working.

As Rob suggested I tried to overwrite my Active Perl install because it's
configuration was odd, and this fixed some of the problems but now when I
ask about Perl C compiler it gives me the full path
E:/xampp/perl/site/bin/gcc.exe instead of just 'gcc'

and surprisingly when I open Config_heavy.pl file I can't find that
anywhere, my Config_heavy says cc:'gcc' so why Perl gives compiler with full
path?? I guess Perl is using another file for detecting configurations, I
really couldn't find where is that

It's in E:/xampp/perl/lib/ActivePerl/Config.pm. For some reason, with perl-5.10 and later ActiveState have decided that 'perl -V:cc' should provide a full path name of the gcc executable (including the .exe extension).

This shouldn't really affect Inline - though I haven't checked with Inline-0.44 and earlier. When running 'perl Makefile' with Inline-0.45, you'll be hit with something like:

####################################
.
.
Config.pm indicates that your version of Perl was built with this C compiler:

   C:/home/rob/MINGW_~1/I686-P~1/bin/gcc.exe.exe

I cannot locate this compiler on your system.
.
.
Do you want to install Inline::C? [n]
##############################

Even though the claim has been made that the compiler cannot be found, if you enter y (instead of the suggested n), then Inline-0.45 should just go ahead and build fine anyway. It's just that the C/Makefile.PL *thinks* that the compiler can't be found - but Inline finds the compiler just fine.

This problem has been fixed in Inline-0.46 and 0.46_01 - and everything should work correctly there. (If it doesn't, please let me know.)

so I had to make some of my usual hacks
:P here is what I did maybe this can help someone, but in all this is not a
recommended method to get Inline working unless you're really really know
what you're doing and you used every method suggested by the Inline list who
really know what they are doing unlike me :))

Here is what I did

After installing ActivePerl Mingw package

ppm install Mingw

I downloaded strawberry zipped package (Not installer) then unpacked it,
make sure to download the same version of your Active Perl version, in my
situation it's Perl 5.10

I copied c folder from strawberry and placed it in the same folder where my
Perl folder resides

I copied strawberry/perl/lib/Core folder and placed it in my ActivePerl/lib folder, this will ask you to replace the current CORE folder just accept to
replace all

Then I opened strawberry/perl/lib/Config_heavy.pl file replaced all
C:/strawberry/Perl with my ActivePerl location, in my case it's
E:/xampp/Perl then saved Config_heavy and placed it in E:/xampp/Perl/lib,
this will ask you to overwrite the current Config_heavy.pl accept that and
you're done

Please remember to back up your Perl folder before doing this so if any odd behavior you can delete and place the backup again and try something else, I
always do that

Now after trying my Perl with Inline it works just fine plus every other
Module and script I wrote previously, so everything seems ok


It's hard to know whether this is going to give you other problems later on, or not.

I personally think it best to keep all aspects of Strawberry Perl and ActivePerl hidden from each other - especially so with perl-5.12.0 onwards, as they then use different versions (from different vendors) of the gcc compiler. With 5.10.1 and earlier at least they both used mingw.org's gcc-3.4.5 compiler.

Cheers,
Rob

Reply via email to