${INSTALL_DATA} problems

Aristedes Maniatis amaniatis at apache.org
Thu Sep 8 23:51:20 UTC 2016


On 9/09/2016 9:13am, Mark Linimon wrote:
> On Fri, Sep 09, 2016 at 08:29:12AM +1000, Aristedes Maniatis wrote:
>> Maybe the Makefile language will become clearer to me one day, but
>> I've been using FreeBSD since 4.0 and it hasn't clicked yet.
> 
> Don't worry, the FreeBSD ports framework does things with the Makefile
> language that was never intended by make's designers :-)
> 
> We do try to document things in the Porter's Handbook, but sometimes
> the only thing to do is wade into bsd.port.mk and friends and read the
> code.  (Not recomended for the faint of heart, though.)

I think the most useful thing that could be done is more examples. Even a list of ports which implement things in the recommended ways and do the full range of common things.

/var/poudriere/ports/default # grep -R {CP} * | wc -l
    1504

So me copying how mariadb101 does it (for example), gives me the wrong result. If I had a dozen "best practices" Makefiles I could copy them.


The second most useful thing would be to enhance portlint. Right now it feels like 95% of what it does is enforce some arbitrary ordering of keywords. But if it instead gave you hints "I see you are using {INSTALL_DATA} with a wildcard or directory, instead you should use {COPYTREE_SHARE}" then much time would be saved.


Cheers
Ari





-- 
-------------------------->
Aristedes Maniatis
GPG fingerprint CBFB 84B4 738D 4E87 5E5C  5EFA EF6A 7D2E 3E49 102A


More information about the freebsd-ports mailing list