in reply to Re: Cannot find dependencies when creating packages on ActivePerl with PPM 4
in thread Cannot find dependencies when creating packages on ActivePerl with PPM 4

Thanks for the reply. I tried your tip about removing the dependency from the PPD, and it worked, although there are some drawnbacks, for sure.

Despite being a core module, I really would like to use the module version number for checking. That would help avoid some trouble when trying to use the module I create with old versions of Hash::Util.

Besides that, I had to remove the dependencies for Win32::OLE and Carp modules also until I receive no error message.

Since the PPD file is created based on the Makefile.pl I wrote, it's quite strange PPM cannot search the core modules as well.

I didn't have a chance to test PPM::Make, do you think this module is capable to solve those issues by itself?


Alceu Rodrigues de Freitas Junior
---------------------------------
"You have enemies? Good. That means you've stood up for something, sometime in your life." - Sir Winston Churchill
  • Comment on Re^2: Cannot find dependencies when creating packages on ActivePerl with PPM 4
  • Download Code

Replies are listed 'Best First'.
Re^3: Cannot find dependencies when creating packages on ActivePerl with PPM 4
by randyk (Parson) on Jan 22, 2007 at 17:55 UTC
    PPM::Make can help with this issue; it searches (via a remote SOAP server) for package names corresponding to module prerequisites, and if the package name is not found, or if it happens to be perl itself (which is the case for Hash::Util and Carp), it won't be listed as a DEPENDENCY in the ppd file. Furthermore, if the package is included in the additional non-core list of packages that the latest Win32 ActivePerl distribution provides (see the %ap_core hash of PPM::Make::Util for a list), this also won't be added as a DEPENDENCY - this is the case for Win32::OLE, which is provided by the libwin32 package, which is part of the Win32 ActivePerl distribution.

      Terrific... if you have a Internet connection available. ;-)

      I'm starting asking myself why ActiveState have such feature (?) when generating a PPD file from a makefile. It would be more interesting if the documented process worked instead forcing a programmer to look for a solution that solves the problem correctly.

      Thanks anyway, I look forward to try and use PPM::Make.

      Alceu Rodrigues de Freitas Junior
      ---------------------------------
      "You have enemies? Good. That means you've stood up for something, sometime in your life." - Sir Winston Churchill

        The generated ppd file is coming from Perl tools (ExtUtils::MakeMaker or Module::Build); these make a guess about the package the prerequisites are found in (based on the specified module name), but sometimes the guess is wrong (eg, Win32::OLE is in the libwin32 package, not a Win32-OLE package). Deciding with certainty what package is required requires, ultimately, an internet connection, in order to have access to the CPAN indices where this information resides.

        ActiveState, with ppm4, is moving away from specifying package names as prerequisites, and moving to a REQUIRE field, which can specify elements listed in the PROVIDE field (which can be module names). When this gets fully implemented, this problem of needing to map module names to package names will disappear. See this message for details.

        Thanks anyway, I look forward to try and use PPM::Make.

        My take on this is that PPM::Make will enable you to create a ppd file that works - but that ppd file will not contain the <DEPENDENCY> checks for the modules you specified ... and therefore you won't achieve your aim, anyway. PPM just currently doesn't have the capability to perform dependency checks on core and bundled modules - though that may change in the future.

        I could be wrong, however - in which case someone will hopefully correct me.

        Cheers,
        Rob