Subject: Re: correct form for install target for pkg
To: Hubert Feyrer <>
From: Dan McMahill <>
List: tech-userlevel
Date: 05/07/1998 23:35:03
In message <9805070853.ZM4261@rrzc1a>, Hubert Feyrer writes:
>On May 6, 10:03pm, Dan McMahill wrote:
>> 1)  Is it safe to count on BSD_INSTALL_XXXX being defined and passed
>>     on to the environment that "make install" is being run in?
>Sure - that's what we have these definitions for. They are also used in emacs
>and some other pkg.

I've noticed that in the emacs pkg, it calls out INSTALL_PROGRAM while
I had to call out BSD_INSTALL_PROGRAM (in the Makefile for the source,
not the pkg Makefile).

>For PLIST, you'll have to list every single files, plus @dirrm statements for
>non-std directories.

>> 3)  There is no man page.  The manual comes with the distribution in LaTex
>>     form and is also available for download via FTP in postscript form.
>Don't depend on LaTeX, esp. if there is a pre-built documentation available
>already. Just make sure it gets downloaded and stuff it wherever it fits to.
so the distribution site for the source is laid out like this:


I have in my pkg Makefile:

DISTNAME=               fastcap-2.0-15Jul92
EXTRACT_SUFX=           .tar.Z

and it correctly downloads and extracts fastcap-2.0-15Jul92.tar.Z,
but I'm having problems with the others.

I tried:
DISTFILES=             fastcap-2.0-15Jul92.tar.Z \
                       postscript/ \
                       postscript/ \
EXTRACT_SUFX=           .tar.Z
CATEGORIES=             cad
DIST_SUBDIR=           fastcap

and it downloaded the 4 files and put them into /usr/pkgsrc/distfiles/fastcap
but when it went to the extract target it said something like
"couldn't open postscript/".  ie, make was looking in
/usr/pkgsrc/distfiles/fastcap/postscript/ while the file
was really

Any suggestions?

>Another side note: You may put that install-procedure into the pkg/Makefile's
>do-install target instead of patching it into the distfile's code. At least
>it's more simple, though the patch can be sent to the original author of the
>pkg, which is quite preferable, too. You decide. :)

hmmm, I tried putting stuff like

        ${BSD_INSTALL_PROGRAM} ./bin/fastcap ${PREFIX}/bin

in the pkg Makefile.  If i put it after the
.include "../../mk/"
then the do-install target was already defined in
If I put it before the .include, then ${BSD_INSTALL_PROGRAM}
ends up not being defined.  In fact if I just do


then I don't see any of the INSTALL_PROGRAM type variables

Am I missing something simple?