proncb has asked for the wisdom of the Perl Monks concerning the following question:

I am having trouble installing Math::Pari module. These are set of steps I did

I tried to substitute the cl with gcc which I obtained from GNU website. I copied gcc.exe to c:\WINNT\system32 and the executed 'perl Makefile.pl CC=gcc' Then 'pmake test VERBOSE_TEST=1', it failed again attempting to call the cl not gcc.

I also tried editing Makefile created after running 'perl Makefile.pl', and assgning gcc to the CC variable instead of cl. This did not work either since the syntax for the cl command in the Makefile is specific to the cl command eg. cl -l ...). The gcc - l would not work.

edited: Fri Jul 18 15:40:48 2003 by jeffa - formatting to make more readable

Title edit by tye

Replies are listed 'Best First'.
Re: Math::Pari
by PodMaster (Abbot) on Jul 18, 2003 at 16:07 UTC
Re: Math::Pari
by BrowserUk (Patriarch) on Jul 18, 2003 at 16:25 UTC

    PodMaster will correct me if I'm wrong on this, but if you didn't build the version of perl that you are using do do the "perl makefile.pl" step with the same compiler as you are trying to use to build the module, then the makefile produced will not work.

    If you have an AS version of perl installed, these are built using MS VC++ toolsets and libraries, and this information is retained in the configuration files that are shippped with AS perls.

    When you try to build a module and you perform the "perl makefile.pl" step, makefile.pl extracts the name of the compiler, linker, libraries and other info from that configuration and uses it when it generates the makefile for building the module. If you don't have the same set-up (compiler etc) as was used to build the version of perl you are running, then the makefile generated is useless.

    You either need to locate the binary version of the module you are trying to install in a PPM/PPD format or build a version of perl using the toolset you do have, and then use that to perform the "perl makefile.pl" step.

    I think I also saw mentioned somewhere that it was possible to modify the configuration to reflect the toolset that you have, but there are no guarentees that modules built using the modifed configuration will work correctly with a version of perl built using the original configuration.


    Examine what is said, not who speaks.
    "Efficiency is intelligent laziness." -David Dunham
    "When I'm working on a problem, I never think about beauty. I think only how to solve the problem. But when I have finished, if the solution is not beautiful, I know it is wrong." -Richard Buckminster Fuller