public inbox for linux-man@vger.kernel.org
 help / color / mirror / Atom feed
* Makefile: Use standard variables and locations
@ 2021-03-20 21:03 Alejandro Colomar (man-pages)
  2021-03-25 22:06 ` Jakub Wilk
  0 siblings, 1 reply; 3+ messages in thread
From: Alejandro Colomar (man-pages) @ 2021-03-20 21:03 UTC (permalink / raw)
  To: Michael Kerrisk (man-pages); +Cc: linux-man

Hi Michael,

There are a few points I think we should fix in the Makefile:

- Use standard variables:
	* mandir (instead of MANDIR)
	* htmldir (instead of HTDIR)
	(see
<https://www.gnu.org/software/make/manual/html_node/Directory-Variables.html>)

- Use standard targets:
	* separate html into html and install-html
	* installdirs (instead of having 'mkdir -p'/'install -d' embedded in
targets)
	(see
<https://www.gnu.org/software/make/manual/html_node/Standard-Targets.html#Standard-Targets>)

- '?=' is not needed, I think.  When a user defines a variable in the
command line, that overwrites any definition in the Makefile.

- Is '|| exit $$?' really needed?  AFAIK, make exits on error.  Maybe
there's a corner case that make doesn't handle well and exit does,
though.  I don't know.

- Use $(INSTALL_DATA) instead of using install directly.

- Specify SHELL = /bin/sh


Any thoughts?

Cheers,

Alex

-- 
Alejandro Colomar
Linux man-pages comaintainer; https://www.kernel.org/doc/man-pages/
http://www.alejandro-colomar.es/

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-03-28 11:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-03-20 21:03 Makefile: Use standard variables and locations Alejandro Colomar (man-pages)
2021-03-25 22:06 ` Jakub Wilk
2021-03-28 11:57   ` Alejandro Colomar (man-pages)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox