Can someone point me to best practices for packaging up a CGI perl script and supporting files? I found this thread -- Packaging up a Complete Perl Program -- which asks how best to package a program (rather than a module). What about a perl program where the script is either going to go into ~/public_html/cgi-bin (or whatever the user's cgi directory is) -- *or* systemwide into /usr/lib/cgi-bin? Supporting executables that are not run from the webserver would go into ~/bin or /usr/bin; and where should documentation (other than built-in POD documentation) go for per-user installation?

Many CGI scripts are like this: either installed systemwide or per-user (blogging packages, for example). Is there a good systematic way to do this? Ideally the user would just make install and it would Just Work, but there probably needs to be some sort of decision, either presented to the user or in the make arguments, as to where the files are to be installed.


In reply to Best practices for packaging CGI scripts by ajkessel

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.