rpaskudniak has asked for the wisdom of the Perl Monks concerning the following question:
Greetings.
It has been a long time since I had time on my hands to pursue more knowledge. Unfortunately, I have that time now. :-( That aside...
Some years ago I posted a module to CPAN, along with a command-line utility that would use that module. As per Sam Tregar's sound advice I started with h2xs and created the usual hierarchy. But it did not include a directory for script files that are not part of the module. So here is the directory structure with incriminating names changed.
drwxr-xr-x+ 1 RPaskudniak None 0 Nov 21 2013 blib drwxr-xr-x+ 1 RPaskudniak None 0 Nov 20 2013 lib -rw-r--r-- 1 RPaskudniak None 24074 Dec 11 2013 Makefile -rwxr-xr-x 1 RPaskudniak None 1297 Mar 3 2011 Makefile.PL -rwxr-xr-x 1 RPaskudniak None 172 Nov 20 2013 MANIFEST -rw-r--r-- 1 RPaskudniak None 568 Nov 20 2013 META.yml -rw-r--r-- 1 RPaskudniak None 500 Dec 11 2013 MYMETA.yml -rw-r--r-- 1 RPaskudniak None 0 Dec 11 2013 pm_to_blib -rwxr-xr-x 1 RPaskudniak None 15000 May 6 2012 README drwxr-xr-x+ 1 RPaskudniak None 0 Feb 5 2014 scripts <<<***>>> drwxr-xr-x+ 1 RPaskudniak None 0 Nov 20 2013 t
Note that scripts directory: h2xs did not create that; I manually created that. And somehow, when I ran the final make install, the utility program ended up in the right place, /usr/local/bin.
I have no recollection of how I got that to work. I likely asked someone but I just don't recall what I did right. I don't think I had to mess with the Makefile.
So my bottom line question is:
Is there an option to h2xs that makes allowances for a bin or scripts directory whence to place a stub for a Perl program related to the module? Or lacking such an option, is there an alternative to h2xs that does make such an allowance?
This humble memory challenged peasant begs a memory kick-start to get restarted; I'm planning a module that will need at least 5 utilities that I can think of.
This humble peasant (with some grand delusions) thanks y'all.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Creating a bin or script directory with h2xs
by bliako (Abbot) on Feb 22, 2019 at 10:20 UTC |