Re: Specifying man dir in installation

Andrew Janke <[email protected]> Sat, 06 Jun 2015 10:39:14 -0400
Newsgroups gmane.comp.tools.aap.devel
Message-ID <[email protected]>

On 6/6/15 8:10 AM, Bram Moolenaar wrote:
> Andrew -
>
>> On 5/28/15 9:27 PM, Bram Moolenaar wrote:
>>> Andrew Janke wrote:
>>>
>>>> Hi, A-A-P developers,
>>>>
>>>> I have a small bug report for the Aap installation process.
>>>>
>>>> As of 1.093, Aap's installation unconditionally puts its man pages in
>>>> man/ directly under $PREFIX. From main.aap:
>>>>
>>>>            mandir = $PREFIX/man/man1
>>>>
>>>> But some platforms, including OS X, have man under $PREFIX/share/man,
>>>> even when installing to /usr/local.
>>>>
>>>> Could we get an option in the Aap installation formula to allow users to
>>>> specify the location of the man directory underneath $PREFIX?
>>> I am no longer actively maintaining Aap.  But if someone can make a
>>> patch for this, I could include it.
>>>
>> Great. Here's a patch. It just adds a MANSUBDIR variable that lets you
>> relocate the `man` dir underneath prefix. It defaults to the current
>> behavior of using $PREFIX/man.
>>
>> Cheers,
>> Andrew
>>
>> diff --git a/main.aap b/main.aap
>> index 9bc4be3..7655e33 100755
>> --- a/main.aap
>> +++ b/main.aap
>> @@ -18,6 +18,8 @@ test all: testall
>>    # Install all docs by default.
>>    FULLDOCS ?= yes
>>
>> +# Location underneath PREFIX for man pages
>> +MANSUBDIR ?= man
>>
>>    fetch:
>>        @if not os.path.exists("_no.CVS"):
>> @@ -53,7 +55,7 @@ install:
>>           docdir = $dir/doc
>>           htmldocdir = $docdir$?HTMLDIR
>>           bindir = $PREFIX/bin
>> -       mandir = $PREFIX/man/man1
>> +       mandir = $PREFIX/$MANSUBDIR/man1
>>           sharedocdir = $PREFIX/share/doc
>>           sharedocdiraap = $sharedocdir/aap
>>           sharehtmldocdir = $sharedocdiraap$?HTMLDIR
> Thanks.  I also updated the "mandir" for uninstall.
>
> I have created Aap version 1.094.  It's been a long time since I
> uploaded a new release, but it seemed to work OK.  Please verify if you
> can install 1.094 properly.
>
> - Bram
>
Looks good. I grabbed the new 1.094 from the Sourceforge zip download. 
Works for me, including the
new MANSUBDIR feature. (Tested on OS X 10.9 and Debian 7.)

Thanks Bram!

Andrew

------------------------------------------------------------------------------