Files
opkg-utils/Makefile
Ryan Barnett 74ccbee0f7 Makefile: separate manpages and utils install
The installation of opkg-build man page introduces a host dependency
on perl for the pod2man package to generate the man page.

To allow the opkg-utils scripts to be installed separately from the
manpages, break apart the install step into two install steps:
install-utils and install-docs

CC: Christian Hermann <mail@hermannch.dev>
Signed-off-by: Ryan Barnett <ryanbarnett3@gmail.com>
Signed-off-by: Alex Stewart <alex.stewart@ni.com>
2021-02-23 16:13:01 -06:00

45 lines
831 B
Makefile

UTILS = \
arfile.py \
opkg-build \
opkg-buildpackage \
opkg-compare-indexes \
opkg-diff \
opkg-extract-file \
opkg-feed \
opkg-list-fields \
opkg-make-index \
opkg-show-deps \
opkg-unbuild \
opkg.py \
update-alternatives
MANPAGES = opkg-build.1
DESTDIR =
PREFIX ?= /usr/local
bindir ?= $(PREFIX)/bin
mandir ?= $(PREFIX)/man
.SUFFIXES: .1
%.1: %
pod2man -r "" -c "opkg-utils Documentation" $< $@
all: $(UTILS) $(MANPAGES)
install-utils: $(UTILS)
install -d $(DESTDIR)$(bindir)
install -m 755 $(UTILS) $(DESTDIR)$(bindir)
install-docs: $(MANPAGES)
install -d $(DESTDIR)$(mandir)
for m in $(MANPAGES); \
do \
install -d $(DESTDIR)$(mandir)/man$${m##*.}; \
install -m 644 "$$m" $(DESTDIR)$(mandir)/man$${m##*.}; \
done
install: install-utils install-docs
.PHONY: install install-utils install-docs all