noice

small file browser
git clone git://git.2f30.org/noice.git
Log | Files | Refs | README | LICENSE

Makefile (912B)


      1 VERSION = 0.8
      2 
      3 PREFIX = /usr/local
      4 MANPREFIX = $(PREFIX)/man
      5 
      6 #CPPFLAGS = -DDEBUG
      7 #CFLAGS = -g
      8 LDLIBS = -lcurses
      9 
     10 DISTFILES = noice.c strlcat.c strlcpy.c util.h config.def.h\
     11     noice.1 Makefile README LICENSE
     12 OBJ = noice.o strlcat.o strlcpy.o
     13 BIN = noice
     14 
     15 all: $(BIN)
     16 
     17 $(BIN): $(OBJ)
     18 	$(CC) $(CFLAGS) -o $@ $(OBJ) $(LDFLAGS) $(LDLIBS)
     19 
     20 noice.o: util.h config.h
     21 strlcat.o: util.h
     22 strlcpy.o: util.h
     23 
     24 config.h:
     25 	cp config.def.h $@
     26 
     27 install: all
     28 	mkdir -p $(DESTDIR)$(PREFIX)/bin
     29 	cp -f $(BIN) $(DESTDIR)$(PREFIX)/bin
     30 	mkdir -p $(DESTDIR)$(MANPREFIX)/man1
     31 	cp -f $(BIN).1 $(DESTDIR)$(MANPREFIX)/man1
     32 
     33 uninstall:
     34 	rm -f $(DESTDIR)$(PREFIX)/bin/$(BIN)
     35 	rm -f $(DESTDIR)$(MANPREFIX)/man1/$(BIN).1
     36 
     37 dist:
     38 	mkdir -p noice-$(VERSION)
     39 	cp $(DISTFILES) noice-$(VERSION)
     40 	tar -cf noice-$(VERSION).tar noice-$(VERSION)
     41 	gzip noice-$(VERSION).tar
     42 	rm -rf noice-$(VERSION)
     43 
     44 clean:
     45 	rm -f $(BIN) $(OBJ) noice-$(VERSION).tar.gz