xref: /openbmc/linux/tools/bpf/bpftool/Documentation/Makefile (revision 6724ed7f)
  • Home
  • History
  • Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1include ../../../scripts/Makefile.include
2include ../../../scripts/utilities.mak
3
4INSTALL ?= install
5RM ?= rm -f
6
7# Make the path relative to DESTDIR, not prefix
8ifndef DESTDIR
9prefix ?= /usr/local
10endif
11mandir ?= $(prefix)/share/man
12man8dir = $(mandir)/man8
13
14MAN8_RST = $(wildcard *.rst)
15
16_DOC_MAN8 = $(patsubst %.rst,%.8,$(MAN8_RST))
17DOC_MAN8 = $(addprefix $(OUTPUT),$(_DOC_MAN8))
18
19man: man8
20man8: $(DOC_MAN8)
21
22$(OUTPUT)%.8: %.rst
23	rst2man $< > $@
24
25clean:
26	$(call QUIET_CLEAN, Documentation) $(RM) $(DOC_MAN8)
27
28install: man
29	$(call QUIET_INSTALL, Documentation-man) \
30		$(INSTALL) -d -m 755 $(DESTDIR)$(man8dir); \
31		$(INSTALL) -m 644 $(DOC_MAN8) $(DESTDIR)$(man8dir);
32
33.PHONY: man man8 clean install
34.DEFAULT_GOAL := man
35

served by {OpenGrok

Last Index Update: Sat May 03 03:01:14 CDT 2025