diff options
-rw-r--r-- | Makefile | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -3,6 +3,7 @@ BINARIES += pci INCDIR += LDINC += $(addprefix -L ,$(LIBDIR)) LDFLAGS += +DESTDIR ?= /usr/local all: $(BINARIES) @@ -23,6 +24,12 @@ pci: cli.o libpcilib.so echo -e "LD \t$@" $(Q)$(CC) $(LDINC) $(LDFLAGS) $(CFLAGS) -L. -lpcilib -o $@ $< +install: pci + install -m 644 pcilib.h $(DESTDIR)/include + if [ -d $(DESTDIR)/lib64 ]; then install -m 755 libpcilib.so $(DESTDIR)/lib64; else install -m 755 libpcilib.so $(DESTDIR)/lib; fi + install -m 755 pci $(DESTDIR)/bin + ldconfig + clean: @echo -e "CLEAN \t$(shell pwd)" -$(Q)rm -f $(addprefix $(BINDIR)/,$(BINARIES)) |