devstructure / blueprint

Reverse engineer server configuration
http://devstructure.com/
Other
2.15k stars 133 forks source link

Perl CPAN modules #123

Open StephenBrown2 opened 12 years ago

StephenBrown2 commented 12 years ago

It would be good to gather up Perl modules installed through CPAN (and thus not in the package list) in the creation of a blueprint.

It would be even better if those modules were then converted to the appropriate packages in the repositories, but that is probably out of scope and not what it's supposed to do.

tzz commented 11 years ago

It may be cleaner to use the autobundle functionality and just install from a tarball. But either way I'd like this too.

rcrowley commented 11 years ago

I would accept a patch to add CPAN support but don't have time to add it myself.

Hammit commented 10 years ago

This would be harder than you first think I'm guessing... CPAN doesn't have a single client. There are a number of ways to install CPAN modules. cpan, cpanplus, cpanminus, etc Build dirs could be anywhere (~/.cpan, ~/.cpanplus, user specified, etc)

It might be easier to parse any perl source looking for use and require statements but even that is no guarantee. i.e. eval()

Perl support would be a good addition, but beware :)

Converting CPAN modules to their package repo version would be a no-go, and this would be true for most languages I think...

  1. Package repositories usually contain older module versions to what would typically be installed through the client.
  2. Package repos typically introduce patches (for the specific distro) not found in the CPAN version.

There's almost no chance of changing the install method from CPAN to package repo without introducing a change to the installed code :|