There's more than one way to do things | |
PerlMonks |
Where to put the bits and pieces - Installing a complex CPAN distby Hercynium (Hermit) |
on Sep 18, 2008 at 20:50 UTC ( [id://712383]=perlquestion: print w/replies, xml ) | Need Help?? |
Hercynium has asked for the wisdom of the Perl Monks concerning the following question:
I'm working on re-doing the Module::Build scripts for a fairly complex set of perl modules, scripts and supporting config files, demo scripts, and documentation (more than just POD and HTML). Heck, I've even got some compiled C to throw into the mix! Installing the modules themselves is easy, along with the POD and utility scripts. However, there's a lot of other pieces that don't really fit in any of the typical categories and I'm not sure where I should put them. I've searched high and low for the "correct" answer but I just can't find one that satifies my need for "getting it right". So, there's the typical info in the Debian Perl Policy and Perl5 Wiki's Hints for Distributors but none of that seems to cover all the extras I've got here. If I try to categorize everything in this distro in a similar way to MB and EUMM, I would break it down like this:
Given the above list of installable elements, and the rules set out in various docs... I'm trying to figure out what the proper places to install the non-standard stuff (conf, demo, demo_conf, share) would be - for both distro-packaged and CPAN installations. I'm thinking I should do it like like this:
I've also considered putting the non-standard stuff into a $Config{siteprefixexp}/$distname/{etc,doc,demo,etc/demo} sort of organization. I'm not sure how *that* would go over with sysadmins, though it actually simplifies things for *me* quite a bit... The conundrum here is that I *really* want to do this properly and the paths shown above still just don't feel right. I really dislike hard-coding directory paths. Currently, I'm only concerned about *nix, but I'm trying to plan ahead a little for Windows as well. - Hence the use of File::Spec. SO... What's the best practice here? Is what I have OK? Can anybody suggest a CPAN dist that had to do the same thing? (so I can see how *they* solved it) UPDATE: I've started putting up some notes on my scratch-pad, which may someday evolve into a proper Meditation :)
Back to
Seekers of Perl Wisdom
|
|