dir2list

generate a list of files shuffled by directory
git clone anongit@rnpnr.xyz:dir2list.git
Log | Files | Refs | Feed | README | LICENSE

Makefile (625B)


      1 # dir2list - generates a list of files shuffled by directory
      2 .POSIX:
      3 
      4 include config.mk
      5 
      6 SRC = dir2list.c
      7 OBJ = $(SRC:.c=.o)
      8 
      9 all: dir2list
     10 
     11 config.h:
     12 	cp config.def.h config.h
     13 
     14 .c.o:
     15 	$(CC) $(CFLAGS) -c $<
     16 
     17 $(OBJ): config.h
     18 
     19 dir2list: $(OBJ)
     20 	$(CC) -o $@ $(OBJ) $(LDFLAGS)
     21 
     22 clean:
     23 	rm -f *.o dir2list
     24 
     25 options:
     26 	@echo "CFLAGS  = $(CFLAGS)"
     27 	@echo "LDFLAGS = $(LDFLAGS)"
     28 	@echo "CC      = $(CC)"
     29 
     30 install: all
     31 	mkdir -p $(DESTDIR)$(PREFIX)/bin
     32 	cp -f dir2list $(DESTDIR)$(PREFIX)/bin
     33 	chmod 755 $(DESTDIR)$(PREFIX)/bin/dir2list
     34 
     35 uninstall:
     36 	rm -f $(DESTDIR)$(PREFIX)/bin/dir2list
     37 
     38 .PHONY: all options clean install uninstall