pm

barely a pack manager
git clone git://z3bra.org/pm
Log | Files | Refs | README | LICENSE

makefile (607B)


      1 include config.mk
      2 
      3 pm: pm.o
      4 pm.o: pm.c config.h
      5 
      6 .c.o:
      7 	$(CC) $(CPPFLAGS) $< $(CFLAGS) -c -o $@
      8 .o:
      9 	$(LD) $< $(LDFLAGS) $(LIBS) -o $@
     10 
     11 config.h: config.def.h
     12 	cp $< $@
     13 
     14 clean:
     15 	rm -f pm *.o
     16 
     17 distclean: clean
     18 	rm config.h
     19 
     20 install: pm pm.1 pack.5
     21 	mkdir -p $(DESTDIR)$(PREFIX)/bin
     22 	mkdir -p $(DESTDIR)$(MANDIR)/man1
     23 	mkdir -p $(DESTDIR)$(MANDIR)/man5
     24 	cp pm $(DESTDIR)$(PREFIX)/bin/pm
     25 	cp pm.1 $(DESTDIR)$(MANDIR)/man1/
     26 	cp pack.5 $(DESTDIR)$(MANDIR)/man5/
     27 	chmod 755 $(DESTDIR)$(PREFIX)/bin/pm
     28 
     29 uninstall:
     30 	rm $(DESTDIR)$(PREFIX)/bin/pm
     31 	rm $(DESTDIR)$(MANDIR)/man1/pm.1
     32 	rm $(DESTDIR)$(MANDIR)/man5/pack.5